branding




Web Building >> Web design & build

 |  Print Topic Pages: 1
wbmkk
regular


Reg'd: Tue
Posts: 218
Loc: Whitley Bay, UK
CSS TAG ORDER PROBLEMS
      #440158 - Thu Oct 15 2009 11:14 AM

Hi

I am currently learning HTML and CSS and have come up with a problem

I was putting attributes to a classes, including top-margin and overflow

Initially I just put them at the bottom of the class attribute list, ie just before the closing }

They didn't work, so I stuck them on the first two lines, after the opening {

Everything works

So, there must be a set order for CSS tags to be put ...

Is this true and if so, where could I find a list of this ?

Mann thanks !!!


Post Extras: Print Post   Remind Me!   Notify Moderator  
ianm
regular


Reg'd: Fri
Posts: 371
Loc: Colchester
Re: CSS TAG ORDER PROBLEMS [Re: wbmkk]
      #440181 - Thu Oct 15 2009 03:53 PM

In theory you can have them in any order you like, if 2 of them clash that could cause a problem but when things dont work always check the css does validate http://jigsaw.w3.org/css-validator/#validate_by_input or if you post your html and css maybe someone can see the issue.

Cheers


Post Extras: Print Post   Remind Me!   Notify Moderator  
wbmkk
regular


Reg'd: Tue
Posts: 218
Loc: Whitley Bay, UK
Re: CSS TAG ORDER PROBLEMS [Re: ianm]
      #440352 - Sun Oct 18 2009 02:56 PM

I found the problem

I had missed out a semicolon at the end and it was affecting both lines

I fixed that problem, then tried again, putting the properties in different orders and it worked every time

Regards !


Post Extras: Print Post   Remind Me!   Notify Moderator  
Dunx
regular


Reg'd: Tue
Posts: 169
Re: CSS TAG ORDER PROBLEMS [Re: wbmkk]
      #440931 - Tue Oct 27 2009 12:38 PM

Quote:


...
I had missed out a semicolon at the end and it was affecting both lines
...





That is so easy to do. You do not need the semi-colon on the end of the last attribute in the list, but I always put one there in case I add something later, saves a lot of head scratching.

All the best - Duncan

--------------------
bolitho
council house exchange


Post Extras: Print Post   Remind Me!   Notify Moderator  
Pages: 1

Rate this topic

Jump to


Extra information
0 registered and 6 anonymous users are browsing this forum.

Moderator:  putasolutions, Joe_London, greysts, bricat, Hello_There, John_McKenna, Mouse, TheFatControlleR 


Print Topic

Forum Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is disabled
      Mark-up is enabled

Rating:
Topic views: 0

Contact Us | Privacy statement Main website



Search

© Copyright IPC Media Limited 2009, All rights reserved