runnerjp Posted May 24, 2008 Share Posted May 24, 2008 would it be possible to have a drop down select box with the data from my runningclubs.txt as i have about 200 running clubs to do and it would take ages to put them into a db and i also think its pointless adding them all into a db as only some will be used Quote Link to comment https://forums.phpfreaks.com/topic/107053-solved-drop-down-bix-with-php/ Share on other sites More sharing options...
minidak03 Posted May 24, 2008 Share Posted May 24, 2008 If your data in the text file is seperate on each line you can do this $lines = file('textfile.txt'); echo '<select>'; foreach($lines as $line) { echo '<option>'.$line.'</option>'; } echo '</select>'; Quote Link to comment https://forums.phpfreaks.com/topic/107053-solved-drop-down-bix-with-php/#findComment-548794 Share on other sites More sharing options...
runnerjp Posted May 24, 2008 Author Share Posted May 24, 2008 wow that was so simple lol ty Quote Link to comment https://forums.phpfreaks.com/topic/107053-solved-drop-down-bix-with-php/#findComment-548881 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.