• 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!

TOPIC: how can i populate field2 based on field1 ??

how can i populate field2 based on field1 ?? 16 years 7 months ago #4636

  • nettemor
  • nettemor's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 33
Hi,
I'm new to RSForm and first of all i'll have to say thank you for a very well done product :)

I have a form where user is to fill in a postal number in field1.
Field2 should now be automatic populated with the corresponding postal-area (have to do a select from another databasetable based on postal number user filled in)
Field2 should not be able to be entered, only displayed.

How do i do this?

Hope anyone can help me on my way here :)<br><br>Post edited by: jeanette.hustad, at: 2008/09/12 15:28
The administrator has disabled public write access.

Re:how can i populate field2 based on field1 ?? 16 years 7 months ago #4642

  • dragonjc
  • dragonjc's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 151
Maybe one solution is this :
First create your selectlist with code.
Into special attributes, insert the javascript code on a change or exit field action (of your choise, just learn javascript) and for action = write :
javascript:location.reload()

Into second field, in manage, write a code (learn knowledgbase from rsform pro) with your request.
This code will not be execute on first load, but will execute on reload.

I don't know if it is fonctionned, but maybe it is.

Second solution is this :
Into your manage form, create a select list for select country.
Add a hide field.
Into process, write your request. It will be execute on submit action. User will not see the result of request but is it reallly necessary ?
Component RS SHow Form in build
The administrator has disabled public write access.

Re:how can i populate field2 based on field1 ?? 16 years 7 months ago #4647

  • nettemor
  • nettemor's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 33
I cannot use a select list, i need to use a normal textfield. This is cause i want the user to enter the postal code (i cannot fill a selectlist with all postal codes cause it will take to much time and the list will be to long).
Is it possible to do some coding (f.ex. if i can fetch a \"on change\" action) in a normal textfield, and if i can where is the place to do it ?
The administrator has disabled public write access.

Re:how can i populate field2 based on field1 ?? 16 years 7 months ago #4653

  • dragonjc
  • dragonjc's Avatar
  • OFFLINE
  • Expert Boarder
  • Posts: 151
That doesn't matter i have write select field because i think you will do it like this. But i'ts the same think.
Component RS SHow Form in build
The administrator has disabled public write access.
  • 1

Read this first!

We do not monitor these forums. The forum is provided to exchange information and experience with other users ONLY. Forum responses are not guaranteed.

However, please submit a ticket if you have an active subscription and wish to receive support. Our ticketing system is the only way of getting in touch with RSJoomla! and receiving the official RSJoomla! Customer Support.

For more information, the Support Policy is located here.

Thank you!