Server IP : 103.119.228.120 / Your IP : 3.142.171.100 Web Server : Apache System : Linux v8.techscape8.com 3.10.0-1160.119.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Jul 15 12:09:18 UTC 2024 x86_64 User : nobody ( 99) PHP Version : 5.6.40 Disable Function : shell_exec,symlink,system,exec,proc_get_status,proc_nice,proc_terminate,define_syslog_variables,syslog,openlog,closelog,escapeshellcmd,passthru,ocinum cols,ini_alter,leak,listen,chgrp,apache_note,apache_setenv,debugger_on,debugger_off,ftp_exec,dl,dll,myshellexec,proc_open,socket_bind,proc_close,escapeshellarg,parse_ini_filepopen,fpassthru,exec,passthru,escapeshellarg,escapeshellcmd,proc_close,proc_open,ini_alter,popen,show_source,proc_nice,proc_terminate,proc_get_status,proc_close,pfsockopen,leak,apache_child_terminate,posix_kill,posix_mkfifo,posix_setpgid,posix_setsid,posix_setuid,dl,symlink,shell_exec,system,dl,passthru,escapeshellarg,escapeshellcmd,myshellexec,c99_buff_prepare,c99_sess_put,fpassthru,getdisfunc,fx29exec,fx29exec2,is_windows,disp_freespace,fx29sh_getupdate,fx29_buff_prepare,fx29_sess_put,fx29shexit,fx29fsearch,fx29ftpbrutecheck,fx29sh_tools,fx29sh_about,milw0rm,imagez,sh_name,myshellexec,checkproxyhost,dosyayicek,c99_buff_prepare,c99_sess_put,c99getsource,c99sh_getupdate,c99fsearch,c99shexit,view_perms,posix_getpwuid,posix_getgrgid,posix_kill,parse_perms,parsesort,view_perms_color,set_encoder_input,ls_setcheckboxall,ls_reverse_all,rsg_read,rsg_glob,selfURL,dispsecinfo,unix2DosTime,addFile,system,get_users,view_size,DirFiles,DirFilesWide,DirPrintHTMLHeaders,GetFilesTotal,GetTitles,GetTimeTotal,GetMatchesCount,GetFileMatchesCount,GetResultFiles,fs_copy_dir,fs_copy_obj,fs_move_dir,fs_move_obj,fs_rmdir,SearchText,getmicrotime MySQL : ON | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /var/softaculous/sitepad/editor/site-data/plugins/sitepad/js/ |
Upload File : |
/* SITEPAD http://sitepad.com/ (c) SitePad Team */ // Lets start pagelayer_add_action('pagelayer_setup_history', function(){ // Show the top bar pagelayer.$$(".pagelayer-iframe-top-bar").show(); pagelayer.$$(".pagelayer-iframe-holder").addClass("pagelayer-iframe-holder-with-bar"); // Move the bottom bar to the top bar var bottom = pagelayer.$$(".pagelayer-bottombar-holder").detach(); bottom.appendTo(pagelayer.$$(".sitepad-top-bar-right")); pagelayer.$$(".pagelayer-bottombar-row").remove(); pagelayer.$$(".pagelayer-mode-buttons-wrapper").addClass("sitepad-screen-mode-fix"); // Add the publish button pagelayer.$$(".pagelayer-bottombar-rightbuttons").prepend('<button data-tlite="Publish Changes" class="sitepad-publish-button pagelayer-primary-btn btn">Publish</button>'); sitepad_show_publish_button(pagelayer_post.post_status); // Show or hide publish button pagelayer_add_action('pagelayer_save_success', function(e, status){ sitepad_show_publish_button(status); if(!pagelayer_empty(pagelayer_active.el) && pagelayer_active.el.tag == 'pl_post_props'){ pagelayer.$$('.pagelayer-settings').click(); } }); // On click publish site pagelayer.$$(".sitepad-publish-button").click(function(){ pagelayer.post_status = 'publish'; pagelayer.$$('.pagelayer-update-button').click(); }); pagelayer.$$(".pagelayer-group-name-wordpress h5").html(sitepad_brand_sm+' Widgets'); // Append the form to the body sitepad_add_seo_form(); }); function sitepad_show_publish_button(status){ if(status == 'draft'){ pagelayer.$$(".sitepad-publish-button").show(); }else{ pagelayer.$$(".sitepad-publish-button").hide(); } } function sitepad_take_screenshot(){ jQuery(".pagelayer-add-widget-area").attr("data-html2canvas-ignore", 1); html2canvas(document.body, {height: jQuery(window).outerWidth()}).then(function(canvas){ var img = canvas.toDataURL("image/jpeg"); jQuery.ajax({ type: "POST", url: sitepad_ajax_url+'&action=sitepad_save_screenshot&postID='+pagelayer_postID, data: { image : img, sitepad_nonce: sitepad_ajax_nonce, post_name: pagelayer_post['post_name'], }, success: function(response, status, xhr){ //alert(response); }, error: function(errorThrown){ console.log(errorThrown); } }); }); } // Take screenshot on save pagelayer_add_action('pagelayer_save', function(){ // Only for pages if(pagelayer_post.post_type != 'page'){ return; } sitepad_take_screenshot(); }); // Hide the top bar pagelayer_add_action('pagelayer-leftbar-toggle', function(){ var show = true; // Is the leftbar toggle itself there ? if(pagelayer.$$('.pagelayer-leftbar-toggle').is(":visible")){ show = pagelayer.$$('.pagelayer-topbar-holder').is(":visible"); } if(show){ pagelayer.$$('.pagelayer-iframe-top-bar').show(); }else{ pagelayer.$$('.pagelayer-iframe-top-bar').hide(); } }); function sitepad_selectPage(selectObject){ change_page = selectObject.value; window.parent.location.href = change_page; } // Add SEO form function sitepad_add_seo_form(){ var seoModal = pagelayer.$$('#sitepad-seo-option-div'); // Save meta data seoModal.find('.meta-tags-submit').click(function(){ var form_data = seoModal.find("#sitepad_meta_form").serialize(); jQuery.ajax({ url: pagelayer_ajax_url+'&action=sitepad_save_meta_tags&postID='+pagelayer_postID+'&sitepad_nonce='+sitepad_ajax_nonce, type: "POST", data: form_data, success: function(data){ var obj = jQuery.parseJSON(data); if(obj['error']){ alert(obj['error']); }else{ alert("Meta Tags Successfully Updated!"); } }, error: function(data, errorThrown){ alert(errorThrown); }, }); }); // Close SEO form Modal seoModal.find('.meta-tags-close').click(function(){ seoModal.hide(); }); // Clear SEO form Modal seoModal.find('.meta-tags-clear').click(function(){ var form_data = seoModal.find("#sitepad_meta_form").serialize(); //jQuery("#div_loader").show(); jQuery.ajax({ url: pagelayer_ajax_url+'&action=sitepad_clear_meta_tags&postID='+pagelayer_postID+'&sitepad_nonce='+sitepad_ajax_nonce, type: "POST", data: form_data, success: function(data){ var obj = jQuery.parseJSON(data); if(obj['error']){ alert(obj['error']); }else{ seoModal.find('input, textarea').val(''); alert("Meta Tags Cleared Successfully!"); } }, error: function(data, errorThrown){ alert(errorThrown); }, }); }); // Open SEO form Modal pagelayer.$$('.sitepad-seo-option').click(function(){ seoModal.show(); }); }