Sales Question?
Welcome, Guest

How to concatenate a phrase from Select-list
(1 viewing) (1) Guest
  • Page:
  • 1

TOPIC: How to concatenate a phrase from Select-list

How to concatenate a phrase from Select-list 1 year ago #73492

Hi,

I was doing tests to try to create an educational form to create sentences. This, taking words from different "Select-List" concatenating all in a "Hidden-field." To be reviewed after the save.

Can anyone help me to copy the selected values ??of 4 different "Select-List" and that when saving, be all concatenated into a "Hidden-Field" or "Text-Field."

I hope someone can help, I'll be very grateful.

Greetings.

PD: Sorry for my poor English.
  • Alegonzero
  • OFFLINE
  • Fresh Boarder
  • Posts: 1
  • Karma: 0

Re: How to concatenate a phrase from Select-list 1 year ago #73613

Hello,

Add a textfield probably set it to read-only (you can change it later to hidden but it is easier for testing to use a textelement first) and give it the name - not title - "text". Add two select lists with the names "select1" and "select2".

In the advanced tab for each select list, go to the Actionscript section, and then put a custom action on each select list:

To do that, go to the select-list element => advanced tab => Actionscript => click "custom" => check the "change" checkbox => click "create code framework".

Right after "case 'change':" put this:

1. for selectlist1:

ff_getElementByName('text').value=element.value+ff_getElementByName('select2').value;

2. for selectlist2:

ff_getElementByName('text').value=ff_getElementByName('select1').value+element.value;


If you need to add a blank space it would look like this:

ff_getElementByName('text').value=ff_getElementByName('select1').value+' '+element.value;


I hope this helps.

Regards,
Syno
  • Syno
  • OFFLINE
  • Administrator
  • Posts: 2227
  • Karma: 0
===============================================
Satisfied?
Consider a membership!
===============================================
Like us on Facebook
===============================================
Follow us on Twitter
===============================================
  • Page:
  • 1
Moderators: TheMuffinMan, ForumSupport
Time to create page: 0.36 seconds

Flatrate Membership: Professional Subscription

Get lifetime access to all of our products and 1 year of professional support -- for just $199 USD. No limits on domains!. Includes all of our current and future Joomla!® extensions, WordPress® plugins and Joomla!® templates.

Get it from here

Recurring Customer Discount - 50% Off!

Get a 50% discount on our Professional Subscription if you have been purchasing a subscription from us in the past -- no matter when. The Professional Subscription includes all of our current and future Joomla!® extensions, WordPress® plugins and Joomla!® templates.

How to receive the discount:

  • Purchase a basic 1-Year Subscription from here.
  • Send us a quick email to This email address is being protected from spambots. You need JavaScript enabled to view it. with your username and proof of your old purchase.
  • We will then upgrade your account to the Professional Subscription.

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our 1-Year Basic or Professional Subscription plans.

How to receive the discount:

  • Send us a quick email to This email address is being protected from spambots. You need JavaScript enabled to view it. with a proof of purchase (for example a paypal receipt).
  • Await payment instructions and enjoy your membership!

About

Crosstec GmbH & Co. KG

Hohenzollernring 57

50672 Cologne, Germany

Imprint