Jump to content

Recommended Posts

Posted

Is it worth creating simple web sites in XHTML yet? I don't want to do anything fancy, but I use NVu which will create in XHTML no problem.

 

Does XHTML cause any problems for browsers at the moment?

 

I've also notice that if I use XHTML strict with NVu, it give new pages the .xhtml extension. Does this cause any problems?

 

I want to get with new technologies, but don't want the headache of being 'bleeding edge'.

 

Thanks.

Posted
i wouldnt really class xhtml as bleeding edge, its in its 6th year now and isnt majorly different from html. Mostly it just forces you to write tidy code, close all tags and use CSS properly. I would deffo look at using xhtml. As for the extension, i have never seen a site using the xhtml extension, i just save mine as .htm files.
Posted

Thanks to all of you. You've put my fears at ease. XHTML it is!

 

I knew XHTML was been out for a while, but thought that it still hadn't been widely adopted. I didn't want to end up with a site that only worked properly in Firefox, or something like that.

 

3wschools.com is agreat website and has been my main source of info so far in css and xhtml.

 

@daverage - I've been to tek-tips before, but hadn't seen your faq. It's good!

 

I went on a Web design course in 1997, learned to format pages in tables with HTML 4 (pretty new at the time), and to use tabs like to format the text.

 

I hadn't really touched web design since then. Having just got back into it recently has been a bit of a shock. Now I'm having to learn all over again.

Posted

If you need any advice, give me a shout OverWorked, im self taught xhtml/css (from w3schools and google).

 

A site I wrote for a friend was written in xhtml (it doesnt validate past my head tag becuase i forgot to add title tags for each page before i sent it to him)

 

Take a peek at the source and see how tidy it is compared to html4

Posted

Thanks, E1uSiV3

 

XHTML Strict - that's what I want to use. None of the 'transitional' stuff.

 

I'm taking the same path as you - w3schools and google. w3schools looks like a good site to start with.

Posted

To answer the original question, yes its always better to use XHTML than HTML as it should now be supported by all browsers. Using v1.0 is better than using v1.1 or greater as it will be more widely supported on the different platforms such as pdas and mobile phones.

 

.XHTML shouldn't cause any problems but I always just save mine as .htm or .html but thats mainly because I would forget to include the x when hyperlinking.

 

Don't think that Strict XHTML is always the answer, the more complex the site the less successful it will be. Strict doesn't allowed hyperlink targets and all sorts you would expect from basic HTML. I always write it in Transitional and then convert it to strict to run through a validator to see if its acceptable.

Posted
Strict doesn't allowed hyperlink targets and all sorts you would expect from basic HTML.

 

I was surprised at this, so had alook round and found this. I haven't tried it yet, but it looks like you can use targets with the id attribute. It's all good stuff.

Posted

A few pointers for you overworked, when using self closing brackets, include a space, for example, use:

Instead of:

Some browser compatibility issues arise otherwise.

 

Also, one that drove me nuts for ages, the dreaded [*] tag and internet explorer issue...

 

Internet explorer parses a carrige return after a closed tag in a document as a line break, so the following:

[*]this is a list item
[*]this is another list item

will produce a gap between each list item.

 

To get around this bug, move the > on the closing tag tothe next line, for example:

[*]this is a list item>[*]this is another list item

This nulls the carrige return bug and still renders correctly in other browsers.

 

I used this technique for the site i linked above to create the fully CSS driven menus.

 

Strict doesn't allowed hyperlink targets

 

Yes, this is very annoying and also well documented about, a lot of people were upset when this was omitted from the xhtml standard.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...