Connecting Tech Pros Worldwide Forums | Help | Site Map

PHP generates tags automatically and does it incorrectly.

showandbeshown@gmail.com
Guest
 
Posts: n/a
#1: Dec 12 '07
Hi,

My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />

Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").

I do not know how to force my code NOT to write the hidden-input-tag
in this way. It is important to mention that this line is generated
automatically. In other words, in my php code I do not have a line
which is intended to write the above shown problematic line (I think
that php writes this line because I use session).

Thank you!

Guillaume BASSINET
Guest
 
Posts: n/a
#2: Dec 12 '07

re: PHP generates tags automatically and does it incorrectly.


showandbeshown@gmail.com a écrit :
Quote:
Hi,
>
My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").
>
I do not know how to force my code NOT to write the hidden-input-tag
in this way. It is important to mention that this line is generated
automatically. In other words, in my php code I do not have a line
which is intended to write the above shown problematic line (I think
that php writes this line because I use session).
>
Thank you!
why you do not use use $_SESSION['PHPSESSID'] ????
showandbeshown@gmail.com
Guest
 
Posts: n/a
#3: Dec 12 '07

re: PHP generates tags automatically and does it incorrectly.


On Dec 11, 9:25 pm, Guillaume BASSINET <kan...@gmail.comwrote:
Quote:
showandbesh...@gmail.com a écrit :
>
Quote:
Hi,
>
Quote:
My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
Quote:
Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").
>
Quote:
I do not know how to force my code NOT to write the hidden-input-tag
in this way. It is important to mention that this line is generated
automatically. In other words, in my php code I do not have a line
which is intended to write the above shown problematic line (I think
that php writes this line because I use session).
>
Quote:
Thank you!
>
why you do not use use $_SESSION['PHPSESSID'] ????
Because I do not know what is it. But if you think it can help me I
will learn it.
Guillaume BASSINET
Guest
 
Posts: n/a
#4: Dec 12 '07

re: PHP generates tags automatically and does it incorrectly.


showandbeshown@gmail.com a écrit :
Quote:
On Dec 11, 9:25 pm, Guillaume BASSINET <kan...@gmail.comwrote:
Quote:
>showandbesh...@gmail.com a écrit :
>>
Quote:
>>Hi,
>>My php code generates the following line:
>><input type="hidden" name="PHPSESSID"
>>value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>>Because of this line I cannot validate my page as HTML 4.01 strict
>>(since the input tag is ended with "/>").
>>I do not know how to force my code NOT to write the hidden-input-tag
>>in this way. It is important to mention that this line is generated
>>automatically. In other words, in my php code I do not have a line
>>which is intended to write the above shown problematic line (I think
>>that php writes this line because I use session).
>>Thank you!
>why you do not use use $_SESSION['PHPSESSID'] ????
>
Because I do not know what is it. But if you think it can help me I
will learn it.
can you send me your doctype?
and if you use /it's xhtml, not html strict
Zvonko Biskup
Guest
 
Posts: n/a
#5: Dec 12 '07

re: PHP generates tags automatically and does it incorrectly.



<showandbeshown@gmail.comwrote in message
news:cd0315ce-ba4c-4500-bbf8-e822071ccd6f@e25g2000prg.googlegroups.com...
Quote:
Hi,
>
My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").
Is it possible that you are using ampersand in your form.
Example:
if you are using this:
<form action="index.php?id=1&cat=2" method="POST">

use this:
<form action="index.php?id=1&amp;cat=2" method="POST">

If this doesn't help here is some other stuff to read:

http://www.w3.org/QA/2005/04/php-session

Best of luck,
Zvonko


Rik Wasmus
Guest
 
Posts: n/a
#6: Dec 12 '07

re: PHP generates tags automatically and does it incorrectly.


On Wed, 12 Dec 2007 03:15:19 +0100, <showandbeshown@gmail.comwrote:
Quote:
Hi,
>
My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").
>
I do not know how to force my code NOT to write the hidden-input-tag
in this way. It is important to mention that this line is generated
automatically. In other words, in my php code I do not have a line
which is intended to write the above shown problematic line (I think
that php writes this line because I use session).
ini_set('session.use_trans_sid',0);

--
Rik Wasmus
Michael Fesser
Guest
 
Posts: n/a
#7: Dec 12 '07

re: PHP generates tags automatically and does it incorrectly.


..oO(showandbeshown@gmail.com)
Quote:
>My php code generates the following line:
><input type="hidden" name="PHPSESSID"
>value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
>Because of this line I cannot validate my page as HTML 4.01 strict
>(since the input tag is ended with "/>").
>
>I do not know how to force my code NOT to write the hidden-input-tag
>in this way.
http://www.php.net/manual/en/ref.ses...-rewriter.tags

Micha
showandbeshown@gmail.com
Guest
 
Posts: n/a
#8: Dec 13 '07

re: PHP generates tags automatically and does it incorrectly.


On Dec 12, 6:39 am, "Rik Wasmus" <luiheidsgoe...@hotmail.comwrote:
Quote:
On Wed, 12 Dec 2007 03:15:19 +0100, <showandbesh...@gmail.comwrote:
Quote:
Hi,
>
Quote:
My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
Quote:
Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").
>
Quote:
I do not know how to force my code NOT to write the hidden-input-tag
in this way. It is important to mention that this line is generated
automatically. In other words, in my php code I do not have a line
which is intended to write the above shown problematic line (I think
that php writes this line because I use session).
>
ini_set('session.use_trans_sid',0);
>
--
Rik Wasmus
It means that my pages will not work if user's browser does not
support cookies?
showandbeshown@gmail.com
Guest
 
Posts: n/a
#9: Dec 13 '07

re: PHP generates tags automatically and does it incorrectly.


On Dec 12, 6:39 am, "Rik Wasmus" <luiheidsgoe...@hotmail.comwrote:
Quote:
On Wed, 12 Dec 2007 03:15:19 +0100, <showandbesh...@gmail.comwrote:
Quote:
Hi,
>
Quote:
My php code generates the following line:
<input type="hidden" name="PHPSESSID"
value="36e197f92bsd34df4a6a20dkajkf10b4e4" />
>
Quote:
Because of this line I cannot validate my page as HTML 4.01 strict
(since the input tag is ended with "/>").
>
Quote:
I do not know how to force my code NOT to write the hidden-input-tag
in this way. It is important to mention that this line is generated
automatically. In other words, in my php code I do not have a line
which is intended to write the above shown problematic line (I think
that php writes this line because I use session).
>
ini_set('session.use_trans_sid',0);
>
--
Rik Wasmus
I put ini_set('session.use_trans_sid',false); in the first line of my
php source. But it does not prevent php from the writing the SID in
the hidden variables. Why? From the other hand, the usage of
the .htaccess with the included "php_flag session.use_trans_sid off"
helps.
Closed Thread