Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm trying to modify the css meta tag and make use of a CDN url - and other things.

What I have tried (as a quick test) is :

function change_stylesheet_loc($uri)
{
    $uri = str_replace('example.com', 'cdn.example.com', $uri);
    return $uri;
}
add_filter('stylesheet_uri', 'change_stylesheet_loc', 20000); 

I've also tried :

add_filter('the_content', 'change_stylesheet_loc', 20000);

Nothing I'm doing is working. How can I modify the css meta tag data?

share|improve this question
    
Why the down votes? –  Dave Jan 12 '13 at 18:21
add comment

1 Answer 1

Don't do that, use wp_enqueu_style with wp_register_style and wp_deregister_style

http://codex.wordpress.org/Function_Reference/wp_enqueue_style
http://codex.wordpress.org/Function_Reference/wp_register_style

Also a $priority of 20k..why would you pick such an arbitrary number.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.