validation problems

  • Thread starter King of Red Lions
  • Start date
B

brucie

In alt.html King of Red Lions said:
http://validator.w3.org/check?uri=h...atically)&doctype=(detect+automatically)&ss=1
... these all errors to do with the links but there is one problem, when
I look at the source of my site I don't even have that code they are
more like <a href="index.php?page=links>links</a>

you need to change all the '&' to '&amp;'. as php is generating the '&'s
you need to tell php its a bad little boy and needs to stop it before it
goes blind and its giggly bits fall off.

ini_set("arg_separator.output", "&amp;");

simple test:

<?
$original=ini_get("arg_separator.output");
ini_set("arg_separator.output", "&amp;");
$new=ini_get("arg_separator.output");
echo 'original= '.$original.' new= '.$new;
?>

viewing source should show:

original= & new= &amp;

ini_set
http://www.php.net/manual/sv/function.ini-set.php

How to change configuration settings
http://www.php.net/manual/en/configuration.changes.php

or you could just ignore the errors
 
D

Deryck

King of Red Lions said:
Hi I have tried validating my page and it comes up with this ...

http://validator.w3.org/check?uri=h...atically)&doctype=(detect+automatically)&ss=1

... these all errors to do with the links but there is one problem, when I
look at the source of my site I don't even have that code they are more
like <a href="index.php?page=links>links</a>

Any help would be much appreciated.

Replace the & characters in the links with &amp;

If they are not in your HTML then you must be using some sort of server side
include technology that is doing that and you should fix it there.

Also, update your javascript <script> tags.

Deryck

HTH

Deryck
 
N

Neal

you need to tell php its a bad little boy and needs to stop it before it
goes blind and its giggly bits fall off.

I think this is sound advice, but a follow-up question:

Where do we find PHP's "giggly bits"? Or, more to the point, would we
*want* to?
 
B

brucie

In alt.html Neal said:
Where do we find PHP's "giggly bits"?
php.ini

Or, more to the point, would we *want* to?

you need to on install so php will do its php thing
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top