Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

Differences between ajax and non ajax in combobox 25 Jul 2013 20:18 #10579

  • VeCrea
  • VeCrea's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
  • Absolute JCook fan
  • Posts: 473
  • Thank you received: 100
Having receive no answer about the fact that ajax loading is not working in IE7, i'm trying to do this :
I detect user-agent, and if its iE8 or bellow, i want to use a combobox (brand->model) with model as the data and brand as the groupby without ajax, and if user-agent is above IE9, then i want to 'turn on' ajax loading. I tried this in many ways and didn't get it to work.
Any help would be appreciated.

Please Log in or Create an account to join the conversation.

Last edit: by VeCrea.

Differences between ajax and non ajax in combobox 27 Jul 2013 09:31 #10602

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
I know I must sort this out. For the moment I am still searching.
Coding is now a piece of cake

Please Log in or Create an account to join the conversation.

Differences between ajax and non ajax in combobox 27 Jul 2013 09:38 #10603

  • VeCrea
  • VeCrea's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
  • Absolute JCook fan
  • Posts: 473
  • Thank you received: 100
Could you at least tell me what are the differences in calling ajax or nonajax ? or what would the jdom call if i want to do some conditionnal display of either the ajax or either the non ajax combo ? because if i only change the xml file, the combo doesn't display anything anymore, but it seems the fields called in the model are the same, and called in the same way.

Please Log in or Create an account to join the conversation.

Differences between ajax and non ajax in combobox 27 Jul 2013 10:12 #10604

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
Yes, because the content of the combo list are prepared in the view file, and sent to the JForm field in the template.
Generate without Ajax, and :
1- keep the code wich is preparing the list (displayXxxx())
2- Keep the few line in the template (Dynamic initialization)
3- Keep the parameters in the XML file (dataKey, dataObject, ...)

Ajax call needs the ajaxContext property to show,
and the Vars sent to it (Dynamic init)


But in your case, it becomes tricky because impossible to switch XML paramters depending on condition. You may have to create 2 different fields with the same name. It is not very clean and could raise some issues.

How I would do :
Keep an ajax field for your XML,
and write the conditional normal combo with a hardcoded JDom call in the template (not using XML field)
This field should recieve : dataKey, dataObject, list, listKey, labelKey, (eventualy groupBy array)

Hope it helps.
Coding is now a piece of cake

Please Log in or Create an account to join the conversation.

Differences between ajax and non ajax in combobox 27 Jul 2013 11:19 #10605

  • VeCrea
  • VeCrea's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
  • Absolute JCook fan
  • Posts: 473
  • Thank you received: 100
Will try this out tonight.
Wouldn't it be possible to write to JDom calls, one for ajax and one without ajax, and not use the xml at all ?
The JDom calss would be placed in the view.html.php file or in the template view file (_form.php) ?
Could you please give me the two JDom calls so i'm sure i won't mess it up ? It's not used with the new version of Cook and i don't want to do try/errors for too much time, i need this to be done quick.
Thank you

Please Log in or Create an account to join the conversation.

Last edit: by VeCrea.

Differences between ajax and non ajax in combobox 27 Jul 2013 12:07 #10606

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
The project ?
And Table/Layout ?

So I can download it and help you.
Coding is now a piece of cake

Please Log in or Create an account to join the conversation.

Differences between ajax and non ajax in combobox 27 Jul 2013 14:23 #10609

  • VeCrea
  • VeCrea's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
  • Absolute JCook fan
  • Posts: 473
  • Thank you received: 100
Recyv3 > vhus > nouveau vhu

Thank you

Please Log in or Create an account to join the conversation.

Differences between ajax and non ajax in combobox 27 Jul 2013 23:09 #10612

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
sent you by email.
Coding is now a piece of cake

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.068 seconds

I have to say your builder is great! We use for another project in a week we have the system built. For the J!Boleto I convert to j3 in 2 weeks :)
Luiz Felipe Weber 

Get Started