Re: How can I get just one row from selected column?
while($wiersz=mysql_fetch_array($wynik,MYSQL_ASSOC))
{
echo "<option value=$wiersz>$wiersz</option> <br />";
}
Try something like
$value = $wiersz[$kolumna];
echo "<option value='$value'>$value</option> <br />";
(remember to enclose the value parameter of the <option> tag in quotes, or
your XHTML code will be invalid)
To make sure it's valid, you should also use "htmlspecialchars"
function (if you use double-quotes around attribute values,
then you do not have to specify the second parameter for this function,
but if you use single-quotes - as in the example above - then you
should specify that "htmlspecialchars" should also escape single-quotes).
Hilarion
.
Relevant Pages
- Re: declaration of variable in for loop
... This is valid because the prototype for printf specifies that the first parameters is of type const char *. ... This is invalid because the prototype for printf does not specify the type of the second parameter, so the rules of C specify that no conversion takes place. ... (comp.lang.c) - Re: How should I specify size?
... > Hello, when using cin.getlinewith a char array, how should I specify the ... > size (the second parameter of getline)? ... (comp.lang.cpp) - Re: newbie: an invalid name was supplied
... debug1: An invalid name was supplied ... Configuration file does not specify default realm ... (comp.security.ssh) - Re: Passing an invalid date to INTEGER-OF-DATE
... > specify an invalid date for the argument? ... > The 1985 COBOL standard says that anything can happen ("the result of ... > I would be interested to know the results for various compilers. ... Our compiler goes nuts when an invalid field is passed to FUNCTION ... (comp.lang.cobol) - Re: List.GetListItems()- Get Additional columns data
... The second parameter is the name of the view to use for specifying default to the remaining parameters so option 1 is to ... The fourth paramter is the list of fields you want specified as an xmlNode so option 2 is to specify the fields you ... thses to the users, ... returning the values of only the selected columns. ... (microsoft.public.sharepoint.portalserver.development) |
|