ChronoEngine.com homepage

Forums

Please write a review for the extension you are using on the Joomla extensions directory before posting a new question as we are being spammed by many negative reviews.

Thank you for your support!

Select an option with ajax content

webcrea 24 Jul, 2020
Hi,

I try to select an option with the result of an ajax request.
All my test :
document.getElementByName('add_result').option[value="' + items['result'] + '"].attr('selected', true);
jQuery('#add_result option[value="' + items['result'] + '"]').attr('selected', true);
add_result.val(items['result']);
jQuery("#add_result").children("option").val(items['result']);
The selector named and his id is add_result
the var defined as :
add_result = jQuery("#add_result");
Do you ahev any idea
Thanks
Chris
Max_admin 25 Jul, 2020
if you are trying to select an option:
$("#select_id").find("option[value="+value goes here+"]").prop("selected", true);
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
webcrea 25 Jul, 2020
Thanks Max,

But no, it doesn't.
I'm going to change the method. Create a new form to manage results.

regards
webcrea 10 Nov, 2020
UP UP UP

Hello Max,

Sorry but I NEED to change select with ajax request.
How can I do it?

It's very important.

I don't understand why the select is hidden. Why this div after?
It should be easier to have only a simple select???

Thanks for your help
Max_admin 21 Nov, 2020
Sorry but I NEED to change select with ajax request.
Reload it!
Max
ChronoForms developer...
Did you try ChronoMyAdmin for managing your Joomla database tables ?
This topic is locked and no more replies can be posted.

2Checkout.com

2CheckOut.com Inc. (Ohio, USA) is an authorized retailer for goods and services provided by ChronoEngine.com