<cfform>

This is qn.1

<cfloop from="1" to='4' index='i'>

<cfinput type="radio" name="radio1" value="a#i#" >

</cfloop>

This is qn.2

<cfloop from="1" to='4' index='i'>

<cfinput type="radio" name="radio2" value="b#i#" >

</cfloop>

This is qn.3

<cfloop from="1" to='4' index='i'>

<cfinput type="radio" name="radio3" value="c#i#" >

</cfloop>

<cfinput type="submit" value="submit" name="Submit">

</cfform>

<cfif isDefined('form.Submit')>

<cfstoredproc procedure="csp_ONF_GetAnswers" datasource="Platform" >

<cfprocparam cfsqltype="CF_SQL_INTEGER" value="#radio1#" type="in">

<cfprocparam cfsqltype="CF_SQL_INTEGER" value="#radio2#" type="in">

<cfprocparam cfsqltype="CF_SQL_INTEGER" value="#radio3#" type="in">

<cfprocresult name="Answer_Data">

<cfif Answer_Data.Answer gt 2>

<cflocation url="page3.cfm">

<cfelse>

<cflocation url="page4.cfm">

</cfif>

</cfif>
This is what is my form. And I need to display the steps on what page the
user is in and how many steps are left over to complete the feed back. I
totally have 4 pages but I need to display on 3 pages. It is displaying 4
steps and If I take one page name off from the page list it is displaying 3
steps but if the user visiting the page.. it is not displaying the page
highlited.
eg:
if I mentione <cfset pagelist="page1,page2,page3">
then if the conditions is false then it should go for page4 but it is not
rendering the steps. but it is displating 3 steps. if I add 4 pagenames then
total steps are 4 but it highkights the page in which user is using.
Actual steps should be 3 not 4.

Thanks
Pranathi

On Sun, Mar 1, 2009 at 9:43 PM, Rick Faircloth <[email protected]>wrote:

>
> So... what page you want to take the visitor to depends
> on what the answer is?
>
> -----Original Message-----
> From: Priya Koya [mailto:[email protected]]
> Sent: Sunday, March 01, 2009 9:38 PM
> To: cf-talk
> Subject: Re: Page steps list
>
>
>  I am calling a procedure to compare the answers ..
> if (answer >4)
> <cflocation url= "page3">
> else
> <cflocation url='page4'>
> This is wat is the condition on page2.
>
> I want to write a function in the .cfc so that I really dont have to
> mention
> on each any every page.
>
> Thanks,
> Pranitha.
>
> On Sun, Mar 1, 2009 at 9:29 PM, Azadi Saryev <[email protected]> wrote:
>
> >
> > still not clear what exactly determines which pages are to be
> > displayed and which one is not...
> > can you clarify that?
> >
> > >> If we are on page1 .... according to the condition it is redirected
> > to page2
> > or page3.
> >
> > what's this 'condition'???
> >
> > your 'procedure' just loops over your list of 4 page names and outputs
> > ALL of them - you just need to incorporate your 'condition' into the
> > loop to not display the page that should not be displayed.
> >
> > Azadi Saryev
> > Sabai-dee.com
> > http://www.sabai-dee.com/
> >
> >
> >
> > Pranathi Reddy wrote:
> > > Any ideas?
> > >
> > >
> > >> I have 4 pages in my application
> > >> Page1, Page2, page3 and page4
> > >>
> > >> I am trying to do something like this (saw in some post):
> > >>
> > >> <cfset pagelist = "Page1,Page2,Page3,Page4"> <cfoutput>  <table
> > >> align="center">
> > >>   <cfset stepCounter = 0>
> > >>  <cfloop list="#pagelist#" index="i">
> > >>   <cfset stepCounter = stepCounter +1>
> > >>   <cfif arguments.pagename EQ "#trim(i)#">
> > >>    <cfset styleclass = "HighLight">
> > >>   <cfelse>
> > >>    <cfset styleclass = "NoHighlight">
> > >>   </cfif>
> > >>   <tr>
> > >>     <td class="#styleclass#" nowrap>Step #stepCounter#: </td><td
> > >> class="#styleclass#" nowrap>#getContent('#arguments.PageID#',
> > >> '#i#').title#</td>
> > >>     </tr>
> > >>  </cfloop>
> > >>  </table>
> > >>  </cfoutput>
> > >>
> > >> I am trying to  display the list of the page rendering.
> > >> If we are on page1 .... according to the condition it is redirected
> > >> to
> > page2
> > >> or page3.
> > >>
> > >> The total number of steps should be only 3 and according to the
> > procedure
> > >> above it display's 4 steps.  It means that it should either be on
> > >> page2
> > or
> > >> page3 and not both.
> > >>
> > >> Thanks,
> > >> Pranathi.
> > >>
> > >> On Sun, Mar 1, 2009 at 5:37 PM, Rick Faircloth <
> > [email protected]>wrote:
> > >>
> > >>
> > >
> > >
> >
> >
>
>
>
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;207172674;29440083;f

Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:319980
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to