wordpress php helper

Helper for including theme assets, stylesheets or javascript files: function theme_asset($filename) { return get_stylesheet_directory_uri() . ‘/’ . $filename; } function theme_css($filename) { $filename = theme_asset($filename); return “<link href='{$filename}’ rel=’stylesheet’ type=’text/css’>”; } function theme_js($filename) { $filename = theme_asset($filename); return “<script type=’text/javascript’ Read more…