barney0o0 Posted June 26, 2006 Share Posted June 26, 2006 Hey...i making a very simple content management system. Im making a form to update a record. Im not too sure how to do this in the Dreamweaver enviroment, however i want to give the user who updates the recordset the option to either enter a filename into a field or use a dropdown menu to select a filename (thats a dynamic list form a recordset).I have been thinking about 2 radio buttons....one that refers to the dropdown menu and one that refers to the maual insert field......however, how could i edit the script that if RadioA is clicked, send info from dropdown to 'filename' (in the recordset)or if RadioB is clicked, send info from manual input field to 'filename'....Ive has a search around and found something like ;[code]IF ($_POST['RadioA']=="on") { $fileplace=$_POST['dropdown']; //do whatever with this fileplace} ELSE IF ($_POST['RadioB']=="on") { $fileplace=$_POST['manualinputfield']; //upload new file}[/code]But im not to sure where to ad this to the usual dreamweaver update/insert record behaviour around the area of:[code]if ((isset($_POST["MM_insert"])) && ($_POST["MM_insert"] == "form1")) { $insertSQL = sprintf("INSERT INTO guest (FName, Sname, UserName, Email, Password) VALUES (%s, %s, %s, %s, %s)", GetSQLValueString($_POST['fname'], "text"), GetSQLValueString($_POST['surname'], "text"), GetSQLValueString($_POST['uname'], "text"), GetSQLValueString($_POST['mail'], "text"), GetSQLValueString($_POST['pass'], "text"));[/code]...i hope this makes sense!...thanks in advance Quote Link to comment 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.