Adobe Dreamweaver Forums



Last 10 THreads :         Re: Screen readable output (section 508) (Last Post : Author care - Replies : 0 - Views : 1 )           »          Window Menu (Last Post : c-bread24 - Replies : 0 - Views : 1 )           »          Direct language translation (Last Post : sha661 - Replies : 7 - Views : 8 )           »          Flash Water Fountain Effect (Last Post : NedWebs - Replies : 1 - Views : 2 )           »          Problems handling xml data for tree control. (Last Post : gallaharsha - Replies : 1 - Views : 2 )           »          Anyone know why I can't refer to a label control(id="address") in the component I created? (Last Post : SujitG - Replies : 1 - Views : 2 )           »          Flash CS4 External Lirbrary (Last Post : Federico Rivas Corrales - Replies : 0 - Views : 1 )           »          Drop down menus not working in IE (Last Post : rdcartoon - Replies : 0 - Views : 1 )           »          Problem with Scene changes (Last Post : NedWebs - Replies : 1 - Views : 2 )           »          can't find java virtual machine (Last Post : MrCactu5 - Replies : 1 - Views : 2 )           »         


Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
User Info Statistics
Go Back   Adobe Dreamweaver Forums > Other Macromedia/Adobe Products > Cold Fusion
 
Tags: , , , , ,



Reply
  #1 (permalink)  
Old 07-22-2008, 11:11 AM
BurntPaper
 
Posts: n/a
Diggs:
Default dynamic data processing (concerning radio buttons)

hello again. first of all, whoever you are in my last topic, thank you for
helping me solve that checkbox problem. (forgot your username)

here's a new puzzle:
this puzzle involved 2 pages, editMODS.cfm and editMODS2.cfm. in
editMODS.cfm, there are 2 rows of radio buttons, one row for edit, one row for
delete. but only one out of all can be checked at a time. once the user has
selected whether he want to edit/delete that module, he will submit the value
for editMODS2.cfm to process. editMODS2.cfm's responsibility is to check what
the value submitted by editMODS.cfm is, then choose which page to redirect to.
when the page is chosen, editMODS2.cfm should then pass the value passed by
editMODS.cfm to that chosen page so that the chosen page can work its magic.

editMODS.cfm
===========
<cfquery datasource="fypdatabase" name="listMODS">
SELECT *
FROM moduleTABLE
ORDER BY courseID
</cfquery>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>
<form id="form1" name="form1" method="post" action="editMODS2.cfm">
<table width="318" border="0" cellpadding="4" cellspacing="3">
<tr>
<td colspan="3" align="center">Edit / Delete Modules</td>
</tr>

<tr>
<td align="left" valign="top">&nbsp;</td>
<td align="center" valign="top">Edit</td>
<td align="center" valign="top">Delete</td>
</tr>
<cfloop query="listMODS">
<tr>
<td width="192" align="left" valign="top">
<cfoutput>#listMODS.moduleNAME# (#listMODS.moduleCODE#)</cfoutput> </td>
<td width="45" align="center" valign="top">
<cfoutput><input type="radio" name="radio" id="radio"
value="E#listMODS.moduleID#" /></cfoutput> </td>
<td width="45" align="center" valign="top">
<cfoutput><input type="radio" name="radio" id="radio"
value="D#listMODS.moduleID#" /></cfoutput> </td>
</tr></cfloop>
<tr>
<td height="3" colspan="3" align="center" valign="middle"></td>
</tr>
<tr>
<td colspan="3" align="center" valign="middle"><input type="submit"
name="button" id="button" value="Submit" /></td>
</tr>
</table>
</form>

</body>
</html>

+++++++++++++++++++++

editMODS2.cfm (all those cfoutputs are there for faster testing of the
checking function)
============
<cfquery datasource="fypdatabase" name="listMODS">
SELECT *
FROM moduleTABLE
ORDER BY courseID
</cfquery>

<cfif #form.radio# is "E#listMODS.moduleID#">
<cfoutput>rw</cfoutput>

<cfelseif #form.radio# is "D#listMODS.moduleID#">
<cfoutput>sd</cfoutput>

<cfelse>
<cfoutput>ec</cfoutput>
</cfif>

as a bonus, it will be greatly appreciated if anyone can enlighten me on value
passing too.



Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 07-23-2008, 09:25 AM
BurntPaper
 
Posts: n/a
Diggs:
Default Re: dynamic data processing (concerning radio buttons)

hi. this post is to inform that the first part of the puzzle has been solved using CONTAIN instead of IS in editMODS2.cfm.

the second part about value passing is still open.
Reply With Quote
  #3 (permalink)  
Old 07-23-2008, 02:20 PM
Dan Bracuk
 
Posts: n/a
Diggs:
Default Re: dynamic data processing (concerning radio buttons)

The easiest way to pass the value is to make it a session variable instead.
Reply With Quote


Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



© Camley Interactive (camley.info) 2008 - all logos and images are copywrite their respective owners.
Proud member of the Camley Interactive Network
All times are GMT. The time now is 01:36 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
Inactive Reminders By Mished.co.uk