1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

AJAX Request with CallBack Function

Discussion in 'XenForo Development Discussions' started by Hoffi, Aug 13, 2014.

  1. Hoffi

    Hoffi Well-Known Member

    I want to call a JavaScript Function, after the AJAX Request returns the HTML.

    But, I want to hook into a default XenForo AJAX Request.

    Example:

    If you vote on a poll, you voze via AJAX and the JSON that returns contains HTML that is rendered into the DOM.

    Is it possible to inject a JavaScript Function in the JSON that is called after the HTML is rendered?
     
  2. Hoffi

    Hoffi Well-Known Member

    Okay, update.

    I added JS and CSS Files inside the Template, and inside the JSON there are now these items inside the js and css keys.

    But it seems, that they are not loaded.

    Is this a bug, or must I do something else that they would be loaded?

    I use Chrome 36, and also testet in IE11
     

Share This Page