jrottman
Programmer
- Jun 17, 2005
- 47
I have 10 form fields that require this document code to be placed into them. Instead of having to write 10 seperate versions of this pop up how can I dynamically change the fieldname.
Here is an example of hte setup I have right now. What I need to do is change the fieldname in opener.document.formname.fieldname.value to what what ever fieldname of the review number is (IE fld_review1)
I can get it to bind over in firefox, but when I try using IE it does not bind it over.
Here is my code
Form page
<input name="fld_review1" type="text" size="30">
<a href="##" onClick="javascript
opUp('includes/admin/doccode.cfm')">
<input type="submit" name="Submit" value=">"></a> </td>
<td><div align="center">
<input type="checkbox" name="fld_rev1_cor" value="checkbox">
Pop up:
<cfquery name="qGetCodes" datasource="#dsn#">
select *
from tbl_agentPortal_codecats
order by fld_doctype ASC
</cfquery>
<form name="form1" method="post" action="">
<select name="codeDisplay" size="10" >
<cfoutput query="qGetCodes">
<option value="#fld_doctype#-#fld_docline#" onClick="opener.document.form3['#URL.formId#'].value = document.form1.codeDisplay.value; self.close();">
#fld_doctype#-#fld_docline# </option>
</cfoutput>
</select>
</form>
Here is an example of hte setup I have right now. What I need to do is change the fieldname in opener.document.formname.fieldname.value to what what ever fieldname of the review number is (IE fld_review1)
I can get it to bind over in firefox, but when I try using IE it does not bind it over.
Here is my code
Form page
<input name="fld_review1" type="text" size="30">
<a href="##" onClick="javascript
<input type="submit" name="Submit" value=">"></a> </td>
<td><div align="center">
<input type="checkbox" name="fld_rev1_cor" value="checkbox">
Pop up:
<cfquery name="qGetCodes" datasource="#dsn#">
select *
from tbl_agentPortal_codecats
order by fld_doctype ASC
</cfquery>
<form name="form1" method="post" action="">
<select name="codeDisplay" size="10" >
<cfoutput query="qGetCodes">
<option value="#fld_doctype#-#fld_docline#" onClick="opener.document.form3['#URL.formId#'].value = document.form1.codeDisplay.value; self.close();">
#fld_doctype#-#fld_docline# </option>
</cfoutput>
</select>
</form>