Forums

Multiple selections

intextino 09 May, 2011
Hi...

I'm working on a tourism site (ChronoForms 4 RC 1.8 and Joomla 1.6.3) and I need a form to submit content with multiple selection boxes.
I have, for example:
beach, mountain, city, national park
So I need to select more than one (Cancun is: city, beach)
How do I do that? I'm getting a NULL field, no matter if I select 1 or 3 checkboxes or if I use [] after the name tag. I've read about the Handle Arrays but, where do I put that?, in OnLoad or OnSubmit? And How?

And, next: I would like to show those entries in the _content table, using the main _categories table.

Any ideas?
GreyHead 09 May, 2011
Hi intextino,

Please take a Form Backup using the icon in the Forms Manager and post it here (as a zipped file) or PM or email it to me and I'll take a closer look.

You can use the Submit Article action to add form results to a Joomla! article.

Bob
Max_admin 10 May, 2011
Hi intextino,

You may use a "Checkbox group" for that, and you need to use the wizard in "advanced mode" and drag the "handle arrays" action in the "on submit" and make sure its before the "DB Save"

Regards,
Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
intextino 10 May, 2011
Hi Bob and Max...
Thanks a lot for the advices! I'd managed to store everything (including multiple selections) into a new table with several custom fields.
Now I have some other questions:
How do I give users the ability to choose from a regular Joomla category before submitting the form and how do I show the results as regular Joomla content. I saw the Submit Article plugin but I don't know how to add the new fields or how to force it to read my custom table.
Should I manually hack the _content table to add my custom fields, or just link both tables?

Thanks again...
GreyHead 13 May, 2011
Hi intextino,

First off **never** hack the Joomla! core tables; that can have all kinds of unwanted side-effects unless you know ewxactly what you are doing. And even then upgrading can get messy.

You can create a drop-down from the Categories list to select the category for your article. I think that there is even a Joomla! built-in method to create the list.

To check the NULL result turn on Form Debug to see exactly what is being submitted.

NB You can't associate an article with more than one category.

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

VPS & Email Hosting 20% discount
hostinger