Jump to content

Is it OK to have 2 declerations of the same CSS file?


OM2

Recommended Posts

Is it OK to have 2 declerations of the same CSS file?

 

I have PHP code that gives the location of the CSS file on my server online.

 

That gives me a problem: when I'm editing on my PC, I have no idea what I'm doing because I can't see the CSS.

 

So, I came up with the bright idea of declaring the CSS file twice:

<link href="myStyles.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $myStyles ?>" rel="stylesheet" type="text/css" />

 

Erm: it seems to be working fine.

 

When viewing on the server, both lines above are valid.

 

I assume that the second decleration over writes the first.

 

AND, before anyone says: no, it's not good enough for me to just have the first line. Yes, it will work fine when viewed on my server. But, for what I'm doing, I *have* to have the PHP!

 

Thanks.

 

 

OM

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.