Done !
| Server IP : 54.36.91.62 / Your IP : 216.73.216.38 Web Server : Apache System : Linux webm008.cluster127.gra.hosting.ovh.net 6.18.42-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Wed Aug 5 15:59:48 CEST 2026 x86_64 User : awaywithxm ( 25098) PHP Version : 7.0.33 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/awaywithxm/www/wp-content/plugins/post-grid/assets/admin/js/ |
Upload File : |
jQuery(document).ready(function($){
$(document).on('click','.import-layout',function(){
_this = this;
post_id = $(this).attr('post_id');
$(_this).addClass('updating-message');
$.ajax({
type: 'POST',
context: _this,
url:post_grid_ajax.post_grid_ajaxurl,
data: {
"action" : "post_grid_ajax_fetch_block_hub_by_id",
"post_grid_ajax_nonce" : post_grid_ajax.ajax_nonce,
"post_id" : post_id,
},
success: function( response ) {
var data = JSON.parse( response );
is_saved = data['is_saved'];
console.log(data);
if(is_saved == 'yes'){
$(this).addClass('saved');
$(this).text('Saved');
}else{
$(this).addClass('saved');
$(this).text('Not Saved');
}
$(_this).removeClass('updating-message');
}
});
})
$(document).on('mouseover','.block-thumb',function(){
imgHeight = $(this).children('img').height();
wrapHeight = $(this).height();
if (imgHeight > wrapHeight) {
var animationOffset = wrapHeight - imgHeight;
var speed = 2000;
$(this).children('img').animate({
"marginTop": animationOffset + "px"
}, speed);
}
})
$(document).on('mouseout','.block-thumb',function(){
imgHeight = $(this).children('img').height();
wrapHeight = $(this).height();
//console.log(wrapHeight);
//console.log(imgHeight);
if (imgHeight > wrapHeight) {
animationOffset = 0;
var speed = 1000;
$(this).children('img').animate({
"marginTop": animationOffset + "px"
}, speed);
}
})
});