views:

11

answers:

1

I am using wordpress and am trying to link to the stylesheet:

<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />

It is not recognizing that link tag, because I think the bloginfo('stylesheet_url') part is not working correctly.

Where can I set the location of the stylesheet url in wordpress?

+1  A: 

This is what should be specified:

<link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" />

You are specifying correctly, make sure that you have put the CSS file in the root of your theme folder and the CSS file is named style.css

Sarfraz
I did and I named it style.css. That's why I'm confused.
zeckdude
@zeckdude: That is weird, the only difference is that i have not specified `media="screen"`.
Sarfraz
Where is the name of the css file specified or does it always have to be named style.css?
zeckdude
Well it has to be style.css
Sarfraz
Also make sure that you have `<?php wp_head(); ?>` in the header.php file and `<?php get_header(); ?>` in index.php file or other files.
Sarfraz
Thank you. I got it!
zeckdude
@zeckdude: That is good news :)
Sarfraz