Session variable seemingly altering unrelated html text
Posted: Sun Apr 08, 2012 10:21 am
The code is rather lengthy to post, and all I am really interested in is if anyone has ever encountered this issue. Thus, no code is posted in this message. If need be, it can be posted after further discussion.
Anyway, I have separated my html and php for a project. I have an html option element with an id of "gender" and a php session variable that gets set called { ["FORMDATA"]["gender"] }. When the php outputs the html file, the id "gender" becomes the assignment of the session variable (in this case, either "F" or "M"). There is absolutely no rewrite to this portion of the html for this to occur. Additionally, if I change the session variable to {["FORMDATA"]["Gender"]}, the html id remains intact, but the option's text label ("Gender:") is now altered (either "F:" or "M:"). All other session variables have not created any issues, but these variables are not equivalent to any of the html text (i.e. the html "mstatus" is referenced as a php session variable "mStatus"). Obviously, or perhaps not, if I change the session variable to "GENDER", none of the html text is altered.
So, I am merely wondering if this is a known issue/bug, some basic rule that I have overlooked, or just a randomly odd occurrence. Thanks in advance.
Anyway, I have separated my html and php for a project. I have an html option element with an id of "gender" and a php session variable that gets set called { ["FORMDATA"]["gender"] }. When the php outputs the html file, the id "gender" becomes the assignment of the session variable (in this case, either "F" or "M"). There is absolutely no rewrite to this portion of the html for this to occur. Additionally, if I change the session variable to {["FORMDATA"]["Gender"]}, the html id remains intact, but the option's text label ("Gender:") is now altered (either "F:" or "M:"). All other session variables have not created any issues, but these variables are not equivalent to any of the html text (i.e. the html "mstatus" is referenced as a php session variable "mStatus"). Obviously, or perhaps not, if I change the session variable to "GENDER", none of the html text is altered.
So, I am merely wondering if this is a known issue/bug, some basic rule that I have overlooked, or just a randomly odd occurrence. Thanks in advance.