• 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: Ajax search in rsform?

Ajax search in rsform? 12 years 8 months ago #18579

  • smol84
  • smol84's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
I want to include a ajax search for a field, similar to how its explained here:


Does anyone have any idea how to do this? I can't find a way to do this automatically in rsform, is there anywhere I can code this directly or use another method?

my example is:
I want users to type their car e.g. 2005 honda accord euro, instead of having multiple drop downs for year make and model, it would be easier for users to start typing and selecting a car from the ajax live search results. The selection can then be passed along with the rest of the form dataa
The administrator has disabled public write access.

Re: Ajax search in rsform? 12 years 8 months ago #18607

  • smol84
  • smol84's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
sorry the previous url didn't get attached

www.w3schools.com/php/php_ajax_livesearch.asp
The administrator has disabled public write access.

Re: Ajax search in rsform? 12 years 8 months ago #18684

  • smol84
  • smol84's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Any ideas guys?

Can anyone tell me where I can modify the code for the form? I'm happy to try myself but I need some direction. Thx!
The administrator has disabled public write access.

Re: Ajax search in rsform? 12 years 8 months ago #18685

  • alexp
  • alexp's Avatar
  • OFFLINE
  • RSJoomla! Official Staff
  • Posts: 2253
  • Thank you received: 180
Hello,

Implementing this would require a solid base of scripting knowledge. Here are some steps that could help you:

- within the search field, you will have to trigger the search Javascript function. Example: onchange="mySearchFunction();"

- create your search function within the CSS/Javascript area, Javascript section. Here you will actually need the AJAX implementation

- note that within the AJAX function you will have to make the PHP request. You can, for example, make the request within the same form, with the help of the Scripts called on form display area. Request URL example:

/index.php?option=com_rsform&formId=1&action=ajax

Within the Scripts called on form display area, the following script:
$action = JRequest::getWord('action');
if($action == 'ajax')
{
... your PHP script here ...
}
Please note: my help is not official customer support. To receive your support, submit a ticket by clicking here
Regards,
RSJoomla! Development Team
The administrator has disabled public write access.

Re: Ajax search in rsform? 12 years 6 months ago #19330

  • smol84
  • smol84's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
I'm having some trouble figuring out where to put the onchange code.. is it in the attributes of the text field? Whenever I try it wont refresh the values after each selection
The administrator has disabled public write access.

Re: Ajax search in rsform? 12 years 3 months ago #20913

  • dom2012
  • dom2012's Avatar
  • OFFLINE
  • Fresh Boarder
  • Posts: 14
  • Thank you received: 2
Hi,

Did you ever figure out how to do this?

I'm having the same problem.

Thanks,
Dom
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!