Forums

Multiform error. Next form fails to open

lcbarker 06 Oct, 2013
I'm using v 4.0.1 on Joomla 3.1.

I have 3 forms, each of which is embedded in a separate article using <p>{chronoforms}xxx form name xxx{/chronoforms}</p>.

The first form - Speaker_Login_2014 - is called from a menu. It includes a Show Form action with these parameters:
Show Form -> Action -> Load Form
Show Form -> Form Name -> Speaker_Biographical_2014

The second form - Speaker_Biographical_2014 - is called from the Show Form action of the first form. It loads correctly. It includes a Show Form action with these parameters:
Show Form -> Action -> Load Form
Show Form -> Form Name -> Speaker_Workshop_Info_2014

The third form - Speaker_Workshop_Info_2014 - is meant to be called from the Show Form action of the second form. But it does not load correctly. Instead, the second form opens up the first form again so the user is presented with the Login form instead of the workshop detail form.

Can anyone see what I'm missing or doing incorrectly?

Thanks for your help.

Les
GreyHead 07 Oct, 2013
Hi Les,

First, you will have a problem with some versions of IE if you include your form inside <p> tags; it is illegal HTML and IE will ignore it. Use <div> tags instead.

Second, what are you trying to achieve here? It's not common to use Show Form actions?

My best guess is that there is a problem with either SEF URLs or Menu Items (or both) that is redirecting the URL for the third form.

Bob
lcbarker 07 Oct, 2013
Thanks for replying.

I've changed the <p> tags for the <div> tags. Didn't make any difference in processing.

What am I trying to do? Always a good question.🙂

This is for collecting speaker information for a conference. I want:
- a login form - this provides a captcha for a screened access with registration of login details of the speaker;
- a biographical form - for collecting various pieces of information regarding the speaker for promotion etc;
- a workshop details form - for collecting all the details about the workshop.

Each speaker may do either just 1 workshop or several workshops. So I need to create a separate form for the workshop info so that after collecting the bio information and the first workshop information they have the opportunity to submit details for another workshop. That would require another record and so a reappearance of an empty workshop form.

This is still in localhost development. Before I placed the forms into articles I could proceed through all the forms properly -- 1 -> 2 -> 3. But then when I put each of them into separate pages that changed -- 1 -> 2 -> 1. (I've rebuilt the third article but it hasn't made any difference.)

If ShowForm is not common to use in this circumstance, what would you suggest?

Thanks

Les
GreyHead 08 Oct, 2013
Hi Les,

The structure sounds fine. In general, if the form is the main content of the page then I wouldn't use the Plug-in in an article but add any extra content to the form and use the form page URL.

If Show Form is the last action in the On Submit event then it should be OK, but use the ReDirect Form Action option, not the Load Form options. I think that is intended to let you load one form inside another which isn't what you need here.

Personally I tend to use the ReDirect User action or just code the redirect in PHP but that's probably because I got into the habit before the Show Forms action was added.

Bob
lcbarker 09 Oct, 2013
Hi Bob,

Thanks for your thoughts. After tinkering around a while this is what I settled on.

A Show Thanks message indicating that a new page will open in a moment.

A Custom Code action to redirect the viewer to the next form. I probably picked the code up from you in one of the many forum articles I read.🙂

<?php
$doc = &JFactory::getDocument();
$doc->addCustomTag('<meta http-equiv="refresh" content="1;url=http://localhost/familyconnectionsc/index.php?option=com_content&view=article&id=23&catid=13&Itemid=106" />');
?>


It may be clumsy but it does work for now.

Thanks for your help.

Les
This topic is locked and no more replies can be posted.