renzomassaro Posted April 5, 2007 Share Posted April 5, 2007 Hello, I have a script that shows data from a field in mine mysql database. These data in the mysql database are word documents that i've imported. What I want is that when i choose 1 from the list the document is opened, is this possible? and if yes, how? This is my script of my dropdownlist so far <? mysql_connect('localhost','root',''); mysql_select_db("helpdesk"); ?> Document: <select name="Document<? echo $i; ?>"><option selected value="">Selecteer document</option> <? $SQL = "select naam from documentatie order by naam"; $SQLResult = mysql_query($SQL) or die("Error with query: $SQL"); while($SQLData = mysql_fetch_array($SQLResult)) { $naam = $SQLData["naam"]; if ($naam !="") { print "<option value=\"$naam\">"; print $naam; print "</option>"; } } ?> </select> Link to comment https://forums.phpfreaks.com/topic/45738-open-word-document-from-mysql-database-via-dropdown-menu/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.