Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Jul 2010
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    problem creating a drop down menu and submit

    The code below is a download form,, the number after the P= are the index idents for each file to be downloaded..
    The destination_folder is set for C:\temp as default location.

    the code below works as needed for one file,,however i need to create a drop down list which will show all file names,and automatically throw the right ident for that file after the P=.
    sounds simple enough but there are other sections that are tied to this form so the solution has to use the CFForm_1(this) else i'll have to redo all the other sections as well. as well as javascript
    if anyone has a quick and clean way to do this i'd be very appreciative. i've pulled my hair out trying to find examples using this config and none are even close..or don't have a drop down menu
    Code:
    <form name="CFForm_1" 
    action="http://www.XXX.cfm?p=6D6F615CC&rt=2&st=2" method="POST" onsubmit="CFForm_1(this)">
    
    <input name="destination_folder" id="destination_folder" type="text" value="C:\Temp" 
    maxlength="200"  size="60"  />
    												
    <input type="Submit" value="Resume">
    thanks in advance, Rick

  • #2
    New to the CF scene
    Join Date
    Jul 2010
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    OK , after pondering abit i finally got it to work with the drop down list...however now i have a new problem lol
    it no longer will download to the c:\temp folder or any folder you type in.
    .it defaults to c:\
    below is the changes i made.
    This isn't exactly what i wanted, but it's close to the point that i don't have to alter a whole lotta things in order to make it work with the rest of the code
    Code:
     i forgot to mention in the first posting that the whole link should 
    end up like this 
    e.g http://www.something.com/something.cfm?p=6D6F615C&rt=2&st=2&destination_folder=directory
    Code:
    <form>
    <select name="menu">
    <option value="http://www.something.com/something.cfm?p=6D6F615C&rt=2&st=2">DownLoad_1
    </option>
    <option value="http://www.something.com/something.cfm?p=C0F4D7FC&rt=2&st=2">DownLoad_2
    </option>
    </select> 
    
    <td valign="top"><input name="destination_folder" 
    id="destination_folder" type="text" value="C:\Temp" maxlength="200"  size="60"/>
    
    <input type="Button" onClick="location=this.form.menu.options[this.form.menu.selectedIndex].value
    ;"  value="Continue">
    </form>
    Last edited by RRice; 07-25-2010 at 11:06 AM. Reason: typo's

  • #3
    New to the CF scene
    Join Date
    Jul 2010
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    <form>
    <select name="menu">
    <option value="http://www.something.com/something.cfm?p=6D6F615C&rt=2&st=2">DownLoad_1
    </option>
    <option value="http://www.something.com/something.cfm?p=C0F4D7FC&rt=2&st=2& I can't get destination_Folder value to end up here when I click Continue">DownLoad_2
    </option>
    </select>

    <td valign="top"><input name="destination_folder"
    id="destination_folder" type="text" value="C:\Temp" maxlength="200" size="60"/>

    <input type="Button" onClick="location=this.form.menu.options[this.form.menu.selectedIndex].value
    ;" value="Continue">
    </form>


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •