jQWidgets Forums

jQuery UI Widgets Forums General Discussions Ajax calls with credentials

This topic contains 5 replies, has 2 voices, and was last updated by  Peter Stoev 11 years, 9 months ago.

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
  • Ajax calls with credentials #32258

    petzi
    Participant

    Is there a possibility to pass the credentials through the dataadapter?
    Using xhrFields { withCredentials : true } does not work with the dataadapter.
    Overriding the loadServerData funcion leads to problems with date-fields. they are not recognized as date anymore but are treated like strings.

    Thanks in advance

    Ajax calls with credentials #32259

    Peter Stoev
    Keymaster

    Hi petzi,

    At present there is no such option in jqxDataAdapter and loadServerData will not recognize the dataFields because by using loadServerData you override the built-in logic with a custom one.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Ajax calls with credentials #32263

    petzi
    Participant

    Hi Peter,
    but how does the builtin logic recognize/parse the json-reply?
    Is there a possibility to call the builtin logic?
    I cannot find anything in your min-file.
    Regards
    Petzi

    Ajax calls with credentials #32266

    Peter Stoev
    Keymaster

    Hi Petzi,

    You can learn more about the built-in logic here: http://www.jqwidgets.com/jquery-widgets-documentation/documentation/jqxdataadapter/jquery-data-adapter.htm

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

    Ajax calls with credentials #32275

    petzi
    Participant

    Hi!
    I’ve read this article. Thats how I learned about the loadServerData-Function.
    But I don’t want to handle everything by myself.
    I tried to manipulate the jqXHR-Object in the beforeSend-function but this didn’t work.
    By the way: When I use loadServerData beforeSend is never called.
    Is there another way to pass the xhrFields to the ajax call?
    Regards
    Petzi

    Ajax calls with credentials #32280

    Peter Stoev
    Keymaster

    Hi Petzi,

    loadServerData completely override the jqxDataAdapter’s built-in logic which means that its callback functions will be most probably not called. In a previous post, I wrote you that the feature you are looking for is still not supported by jqxDataAdapter so you can go with an ordinary Ajax call and in case you want to load a widget through jqxDataAdapter, in your Ajax function’s success callback, fill the jqxDataAdapter.

    Best Regards,
    Peter Stoev

    jQWidgets Team
    http://www.jqwidgets.com

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.