Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- * sets up the object with the AJAX url and security nonce, also retrieves language properties
- */
- setup: function(url, nonce, pluginUrl, userId, callbackFn, skipLoadGlobals) {
- if(!PI.ajaxSetup) {
- // create custom widgets
- initPICustom();
- PI.globals.pluginUrl = pluginUrl;
- PI.userId = userId;
- this.url = url;
- this.nonce = nonce;
- if(!skipLoadGlobals) {
- this.loadGlobalData(callbackFn);
- }
- else {
- callbackFn();
- }
- }
- else {
- alert('Ajax setup function already called');
- }
- },
- getUserOldestResultYear: function(userId, callbackFn) {
- jQuery.ajax({
- type: "post",
- url: PI.Ajax.url
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement