PHP Classes

OPTIONS display-values getting manipulated

Recommend this page to a friend!

      PHP Forms Class with HTML Generator and JavaScript Validation  >  PHP Forms Class with HTML Generator and JavaScript Validation package blog  >  Upcoming Visual HTML ...  >  All threads  >  OPTIONS display-values getting...  >  (Un) Subscribe thread alerts  
Subject:OPTIONS display-values getting...
Summary:Text prefixed to LABEL getting prefixed to OPTIONS display-value
Messages:3
Author:Form Class
Date:2007-04-10 20:06:36
Update:2007-04-10 21:10:43
 

  1. OPTIONS display-values getting...   Reply   Report abuse  
Picture of Form Class Form Class - 2007-04-10 20:06:36
Hi All,

I prefix '&nbsp;' to some inputs' LABELs for fine alignment with the labels of other inputs. I have a SELECT-type input and these space chars are getting prefixed to the display values of the OPTIONS (the text between <option></option> tags) although I'm not even prefixing the space char to this input's LABEL because none of the inputs on this page needs one. This is happening only with one input whose name is 'sort' while other similar inputs appearing after this input are rendering just fine. This is the first input on the page with a couple of BUTTON-type inputs above/before it and similar inputs after/below it:

[NAME] => sort
[ID] => sort
[TYPE] => select
[VALUE] => Modified
[OPTIONS] => Array
(
[Name] => Name
[Modified] => Modified
)
[STYLE] => width: 150px
[LABEL] => Sort
[ACCESSKEY] => O
[ValidateOptionalValue] =>


I'm using forms class released on 2007-4-2. My code does not manipulate the OPTIONS array in any way. If I comment the part that prefixes space char to the label, the input is rendered fine. What could be causing these space chars to make into (prefixed to) the display values of the OPTIONS?

TIA

  2. Re: OPTIONS display-values getting...   Reply   Report abuse  
Picture of Manuel Lemos Manuel Lemos - 2007-04-10 21:04:09 - In reply to message 1 from Form Class
I am not sure what you are asking.

Do you want to make the select options appear with a space before each option display value?

  3. Re: OPTIONS display-values getting...   Reply   Report abuse  
Picture of Form Class Form Class - 2007-04-10 21:10:43 - In reply to message 1 from Form Class
Please ignore this post. I debugged it and noticed it is happening due to passing data by reference.