Valid HTML Links

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
Post Reply
Russ
Power Poster
Power Poster
Posts: 813
Joined: Fri Nov 25, 2005 5:02 pm
Location: North West England

Valid HTML Links

Post by Russ »

Does any one know how you can put a 'Validate HTML' link in the template to provide a link on each page to to click and validate that page against the W3C validator?

Somehting like:
">Valid XHTML 1.0 Strict

Thanks in advance,
Russ
melix

Re: Valid HTML Links

Post by melix »

You could add the following to your template :

Code: Select all

<a title="Valid XHTML 1.0 STRICT - click to test" href="http://validator.w3.org/check?uri=http://{$smarty.server.HTTP_HOST}{$smarty.server.PHP_SELF}">Valid XHTML 1.0 Strict</a>
arl

Re: Valid HTML Links

Post by arl »

Or even easier: Valid XHTML 1.0 Strict

Allan
Russ
Power Poster
Power Poster
Posts: 813
Joined: Fri Nov 25, 2005 5:02 pm
Location: North West England

Re: Valid HTML Links

Post by Russ »

Thanks to you both for you quick replies  ;)

I presume there is the same sort of thing for validating CCS and Accessibility? Does anyone have the code?

Many thanks again,

Russ
westis

Re: Valid HTML Links

Post by westis »

Russ,

Look here for the validator for CSS: http://jigsaw.w3.org/css-validator/

There is also the WebXACT (formerly Bobby) validator: http://webxact.watchfire.com/
Russ
Power Poster
Power Poster
Posts: 813
Joined: Fri Nov 25, 2005 5:02 pm
Location: North West England

Re: Valid HTML Links

Post by Russ »

Thanks again :) I may be having one of those very dumb moments but I can't seem to get the CSS validator to work as a link on a page for that pages CSS ?

Russ
westis

Re: Valid HTML Links

Post by westis »

I haven't tried it myself, but it should be something like Valid CSS


EDIT: Hmm, actually forget that. It needs more paramaters to the link. Hope you'll be able to get it working. :)
Last edited by westis on Thu Dec 08, 2005 7:09 am, edited 1 time in total.
alby

Re: Valid HTML Links

Post by alby »

westis wrote: I haven't tried it myself, but it should be something like Valid CSS
"referer" is the URL address of page, for example (this page):
http://jigsaw.w3.org/css-validator/vali ... 372.0.html

Or better  ::):
http://jigsaw.w3.org/css-validator/check/referer

Alby
RussB

Re: Valid HTML Links

Post by RussB »

Thank you again for your replies, they both work fine now. It's a bit of a pity we can't do the same for accessibiity testing know that the automated Bobby tests site has changed into a site where you have to enter the url. (I realise that automated testing is only part of the story.)


Thanks again,

Russ
cyberman

Re: Valid HTML Links

Post by cyberman »

Please look here - there you get the code for including the bobbytest on your site  ;) ...
Russ
Power Poster
Power Poster
Posts: 813
Joined: Fri Nov 25, 2005 5:02 pm
Location: North West England

Re: Valid HTML Links

Post by Russ »

Thanks cyberman, with a bit of modification that will do nicely :)

Russ
Post Reply

Return to “Developers Discussion”