How do you make a .css file that...

  • HKt0p5
  • Graduate
  • Graduate
  • User avatar
  • Joined: Mar 19, 2008
  • Posts: 134
  • Loc: Bulgaria
  • Status: Offline

Post March 26th, 2008, 10:26 am

Can it be made a .css file that is uploaded in the main dir and applies to all pages, instead of adding the style thing on each one?
  • Anonymous
  • Bot
  • No Avatar
  • Joined: 25 Feb 2008
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post March 26th, 2008, 10:26 am

  • dyfrin
  • Proficient
  • Proficient
  • User avatar
  • Joined: May 10, 2006
  • Posts: 499
  • Loc: WI
  • Status: Offline

Post March 26th, 2008, 11:02 am

with php/asp you can.
or apache with mod_rewrite you can do something like:

Code: [ Select ]
RewriteCond %{HTTP_USER_AGENT} ^Mozilla/(.*)MSIE
RewriteRule (.*)style.css$ $1style_ie.css [L]

RewriteCond %{HTTP_USER_AGENT} ^Mozilla/(.*)Firefox
RewriteRule (.*)style.css$ $1style_ff.css [L]
  1. RewriteCond %{HTTP_USER_AGENT} ^Mozilla/(.*)MSIE
  2. RewriteRule (.*)style.css$ $1style_ie.css [L]
  3. RewriteCond %{HTTP_USER_AGENT} ^Mozilla/(.*)Firefox
  4. RewriteRule (.*)style.css$ $1style_ff.css [L]
dyfrin.com
  • joebert
  • Sledgehammer
  • Genius
  • No Avatar
  • Joined: Feb 10, 2004
  • Posts: 13455
  • Loc: Florida
  • Status: Offline

Post March 26th, 2008, 12:02 pm

Unless you use a complicated output filter, you're going to have to put something in each page.
Strong with this one, the sudo is.
  • HKt0p5
  • Graduate
  • Graduate
  • User avatar
  • Joined: Mar 19, 2008
  • Posts: 134
  • Loc: Bulgaria
  • Status: Offline

Post March 27th, 2008, 12:58 pm

I wonder how that would work for divs and plain text links. Hmm.. ohwell, thankies!

Post Information

  • Total Posts in this topic: 4 posts
  • Users browsing this forum: No registered users and 152 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 2011 Unmelted, LLC. Ozzu® is a registered trademark of Unmelted, LLC.