phpfingers
01-24-2004, 01:56 PM
im having probs
im using dreamweaver4,php4 and mysql.
what i want is to show the url's in the listbox this is what i have show far
<select name="track2edit"size="1"> **********
(1)<?PHP
(2)while ($c_array=mysql_fetch_array($result))
(3) {
(4) $artist= $c_array['totart_names'];
(5) $user= $c_array['spare3'];
(6) $artistlink="<a href=audmp3.php?cart=$artist
target='_self'>$artist</a><BR>";
(7) print '<option value="'.$user.'">'.$thelink.'</option>';
(8) }
(9)?>
</select> **********
what happens here is
it looks for the artist and user name in the mysql DB
then store them as URI (url) in the $artistlink varible
then show them as a link in the listbox or menubox (scrollable)
then keep doing the whole block again till $c_array is negative
what happens in reality is
it does find all the data and place them in the box
BUT the data appears as normal text instead of a clickable link
so i think in line 6 in the above code is at fault BUT
here comes the big catch
if you remove the lines with the stars (remove the list box) and re-run the code
you will see the the names from the database, once echoed to the screen is now clickable urls.
but i really need in list the box as i want the results of hundreds of artist names in a maintainable scrollable area
i hope you understood my theory
thanks
PhpFingers
im using dreamweaver4,php4 and mysql.
what i want is to show the url's in the listbox this is what i have show far
<select name="track2edit"size="1"> **********
(1)<?PHP
(2)while ($c_array=mysql_fetch_array($result))
(3) {
(4) $artist= $c_array['totart_names'];
(5) $user= $c_array['spare3'];
(6) $artistlink="<a href=audmp3.php?cart=$artist
target='_self'>$artist</a><BR>";
(7) print '<option value="'.$user.'">'.$thelink.'</option>';
(8) }
(9)?>
</select> **********
what happens here is
it looks for the artist and user name in the mysql DB
then store them as URI (url) in the $artistlink varible
then show them as a link in the listbox or menubox (scrollable)
then keep doing the whole block again till $c_array is negative
what happens in reality is
it does find all the data and place them in the box
BUT the data appears as normal text instead of a clickable link
so i think in line 6 in the above code is at fault BUT
here comes the big catch
if you remove the lines with the stars (remove the list box) and re-run the code
you will see the the names from the database, once echoed to the screen is now clickable urls.
but i really need in list the box as i want the results of hundreds of artist names in a maintainable scrollable area
i hope you understood my theory
thanks
PhpFingers