Hello, i am all new to this kind of stuff and i didnt find any topic yet about it because i do not really know how to call this problem. So if there are any solutions yet i am sorry for opening a new topic.
I want a dropdown navigation, that read its content out of an array.
thats what i got so far and it works.
[CODE]<?
echo ‘<SELECT name=bild>’;
foreach ($zahl_array as $key => $value)
{
echo ‘<OPTION value=’.$value.’> ‘.$value.”;
}
echo ‘</select>’;
?>
$zahl_array is reading the array content out of a .txt file.
Now the problem is that i want something to happen when you change/click on one link in the dropdown.
Above this code, there is a table with an randomly generated Image.
[CODE]
$zahl_array = file(‘zahl.txt’);
$num = rand(0, count($zahl_array) – 1);
$zahl = $zahl_array[$num];
…html…<img src=”/images/<? echo $zahl; ?>.jpg”>…html…
Now if the user chooses one link in the dropdown it should change the Image above to the one that the user choosed.
Sry for bad english i am from germany