Jump to content


Photo

CSS override


  • Please log in to reply
4 replies to this topic

#1 jonsmth948

jonsmth948

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 29 January 2013 - 03:38 PM

In Wordpress. I have 2 css files one name style.css and the other called custom.css

How do you unset a style by typing a line of code.

Example in what I'm trying to accomplish.

Custom.css
body { 'remove all styles for the body tag'}


defalt.css
body {background:blue; font: Helvetica;}

#2 Jessica

Jessica

    This is not my name.

  • Gurus
  • 8,982 posts
  • LocationDallas, TX
  • Age:26

Posted 29 January 2013 - 03:54 PM

Moving to CSS forum.
My goal in replying to posts is to help you become a better programmer, including learning how to debug your own code and research problems. For that reason, rather than posting the solution, I reply with tips and hints on how to find the solution yourself. See below for useful links when you get stuck.

How to Get Good Help: How to Ask Questions | Don't be a help vampire
Debugging Your Code: Debugging your SQL | What does a php function do? | What does a term mean? | Don't see any errors?
Things You Should Do: Normalize Your Data | use print_r() or var_dump()
Lulz: "Functions should not have side effects." - trq

Please take a look at my new PHP/Web Dev blog: The Web Mason - Thanks!!

#3 kicken

kicken

    Wiser? Not exactly.

  • Gurus
  • 2,651 posts
  • LocationBonita, FL

Posted 29 January 2013 - 05:43 PM

There isn't any way (afaik) to simply remove a style definition from one rule inside another, you can only override it's value.  You'd just have to override it and reset it to it's "default" value.

Recycle your old CD's, don't trash them!
Did I help you out?  Feeling generous? I accept tips via Paypal or Bitcoin @ 14mDxaob8Jgdg52scDbvf3uaeR61tB2yC7

#4 jonsmth948

jonsmth948

    Newbie

  • Members
  • Pip
  • 5 posts

Posted 30 January 2013 - 04:56 PM

How do you override it to a default value?

#5 Jessica

Jessica

    This is not my name.

  • Gurus
  • 8,982 posts
  • LocationDallas, TX
  • Age:26

Posted 30 January 2013 - 04:59 PM

You have to look up what the default value is in the documentation, then set it to that.
For example, the default value for text-decoration for an a is underline. 
My goal in replying to posts is to help you become a better programmer, including learning how to debug your own code and research problems. For that reason, rather than posting the solution, I reply with tips and hints on how to find the solution yourself. See below for useful links when you get stuck.

How to Get Good Help: How to Ask Questions | Don't be a help vampire
Debugging Your Code: Debugging your SQL | What does a php function do? | What does a term mean? | Don't see any errors?
Things You Should Do: Normalize Your Data | use print_r() or var_dump()
Lulz: "Functions should not have side effects." - trq

Please take a look at my new PHP/Web Dev blog: The Web Mason - Thanks!!




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

Cheap Linux VPS from $5
SSD Storage, 30 day Guarantee
1 TB of BW, 100% Network Uptime

AlphaBit.com