As the title says, how can I make & not fail.
Ive tried this
// Set & settings
ini_set('arg_separator.input','&');
ini_set('arg_separator.output','&');
bit it doesnt work.
& failing xhtml strict
Started by tiki, Nov 13 2005 10:27 PM
7 replies to this topic
#1
Posted 13 November 2005 - 10:27 PM
#2
Posted 13 November 2005 - 10:38 PM
Did you try changing to transitional?
#3
Posted 13 November 2005 - 10:57 PM
Ive used that code before to pass xhtml strict and it worked, I dono why its not now.
Nope, I tend to stay to strict only.
Nope, I tend to stay to strict only.
#4
Posted 14 November 2005 - 05:22 PM
For your url's you don't need to do the ini_set().
I'm assuming you believe that would change all of your &'s automatically, which it won't.
You have to either run str_replace('&', '&', $the_code) on all of your code (ob_start would probably make it easier), or type & everywhere you want the amperstand to be, and validate.
Note: If you use it in the href attribute of an <a> tag, don't worry, the browser will automatically traslate it to &
I'm assuming you believe that would change all of your &'s automatically, which it won't.
You have to either run str_replace('&', '&', $the_code) on all of your code (ob_start would probably make it easier), or type & everywhere you want the amperstand to be, and validate.
Note: If you use it in the href attribute of an <a> tag, don't worry, the browser will automatically traslate it to &
#5
Posted 14 November 2005 - 06:40 PM
The & isnt part of the php code
its jsut on eof my links like <a href="index.php?page=lol&view=2">
So thats how its used, ive tried ampersand in the links but it dont work. ill try the replace
its jsut on eof my links like <a href="index.php?page=lol&view=2">
So thats how its used, ive tried ampersand in the links but it dont work. ill try the replace
#6
Posted 14 November 2005 - 10:00 PM
How about, I change the urls with .htaccess since thats what im planning to do in the first place.
Do you know .htaccess?
Do you know .htaccess?
#7
Posted 14 November 2005 - 10:57 PM
tiki, on Nov 14 2005, 10:00 PM, said:
How about, I change the urls with .htaccess since thats what im planning to do in the first place.
Do you know .htaccess?
Do you know .htaccess?
RewriteEngine On RewriteRule ^page/(.*)/([0-9]*)/ /index.php?page=$1&view=$2
That is how I would do your page that you have in your coding that you gave.
There should be other ways, but thats just something simple.
#8
Posted 15 November 2005 - 12:16 AM
THanks I got some pages working, and no more &'s
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
