| 1 |
<?php |
| 2 |
if ( ! defined( 'ABSPATH' ) ) |
| 3 |
exit; |
| 4 |
?> |
| 5 |
<style> |
| 6 |
a.xyz_header_link:hover{text-decoration:underline;} |
| 7 |
.xyz_header_link{text-decoration:none;} |
| 8 |
</style> |
| 9 |
|
| 10 |
<?php |
| 11 |
if(isset($_POST['xyz_ips_pre_ads'])){ |
| 12 |
$xyz_ips_pre_ads = intval($_POST['xyz_ips_pre_ads']); |
| 13 |
update_option('xyz_ips_premium_version_ads',$xyz_ips_pre_ads); |
| 14 |
} |
| 15 |
|
| 16 |
/* |
| 17 |
if(get_option('xyz_ips_premium_version_ads')==1){ |
| 18 |
|
| 19 |
?> |
| 20 |
<div id="xyz-ips-premium"> |
| 21 |
|
| 22 |
<div style="float: left; padding: 0 5px"> |
| 23 |
<h2 style="vertical-align: middle;"> |
| 24 |
<a target="_blank" href="https://xyzscripts.com/wordpress-plugins/xyz-wp-insert-code-snippet/details">Fully Featured XYZ WP Insert Code Snippet Premium Plugin</a> - Just 19 USD |
| 25 |
</h2> |
| 26 |
</div> |
| 27 |
<div style="float: left; margin-top: 3px"> |
| 28 |
<a target="_blank" |
| 29 |
href="https://xyzscripts.com/members/product/purchase/XYZWPICSPRE"><img |
| 30 |
src="<?php echo plugins_url("images/orange_buynow.png",XYZ_INSERT_PHP_PLUGIN_FILE); ?>"> |
| 31 |
</a> |
| 32 |
</div> |
| 33 |
<div style="float: left; padding: 0 5px"> |
| 34 |
<h2 style="vertical-align: middle;text-shadow: 1px 1px 1px #686868"> |
| 35 |
( <a href="<?php echo admin_url('admin.php?page=insert-php-code-snippet-about');?>">Compare Features</a> ) |
| 36 |
</h2> |
| 37 |
</div> |
| 38 |
</div> |
| 39 |
<?php |
| 40 |
} |
| 41 |
*/ |
| 42 |
|
| 43 |
if($_POST && isset($_POST['xyz_ips_credit'])) |
| 44 |
{ |
| 45 |
if (! isset( $_REQUEST['_wpnonce'] )|| ! wp_verify_nonce( $_REQUEST['_wpnonce'],'ips-psetting_')){ |
| 46 |
wp_nonce_ays( 'ips-psetting_' ); |
| 47 |
exit; |
| 48 |
} |
| 49 |
$xyz_ips_credit_link=sanitize_text_field($_POST['xyz_ips_credit']); |
| 50 |
update_option('xyz_credit_link', $xyz_ips_credit_link); |
| 51 |
} |
| 52 |
|
| 53 |
|
| 54 |
if(!$_POST && isset($_GET['ips_blink'])&&isset($_GET['ips_blink'])=='en'){ |
| 55 |
if (! isset( $_REQUEST['_wpnonce'] ) || ! wp_verify_nonce( $_REQUEST['_wpnonce'],'ips-blk')){ |
| 56 |
wp_nonce_ays( 'ips-blk'); |
| 57 |
exit; |
| 58 |
} |
| 59 |
update_option('xyz_credit_link',"ips"); |
| 60 |
?> |
| 61 |
<div class="xyz_ips_system_notice_area_style1" id="xyz_ips_system_notice_area"> |
| 62 |
Thank you for enabling backlink. |
| 63 |
<span id="xyz_ips_system_notice_area_dismiss">Dismiss</span> |
| 64 |
</div> |
| 65 |
|
| 66 |
<style type="text/css"> |
| 67 |
.xyz_blink{ |
| 68 |
display:none !important; |
| 69 |
} |
| 70 |
</style> |
| 71 |
<?php |
| 72 |
} |
| 73 |
|
| 74 |
if((get_option('xyz_credit_link')=="0")&&(get_option('xyz_ips_credit_dismiss')=="0")){ |
| 75 |
?> |
| 76 |
<div style="float:left;background-color: #FFECB3;border-radius:5px;padding: 0px 5px;margin-top: 10px;border: 1px solid #E0AB1B" id="xyz_ips_backlink_div"> |
| 77 |
|
| 78 |
Please do a favour by enabling backlink to our site. <a id="xyz_ips_backlink" style="cursor: pointer;" >Okay, Enable</a>. <a id="xyz_ips_dismiss" style="cursor: pointer;" >Dismiss</a>. |
| 79 |
<script type="text/javascript"> |
| 80 |
jQuery(document).ready(function() { |
| 81 |
jQuery('#xyz_ips_backlink').click(function(){ |
| 82 |
xyz_filter_blink(1) |
| 83 |
}); |
| 84 |
|
| 85 |
jQuery('#xyz_ips_dismiss').click(function(){ |
| 86 |
xyz_filter_blink(-1) |
| 87 |
}); |
| 88 |
|
| 89 |
function xyz_filter_blink(stat){ |
| 90 |
|
| 91 |
<?php $ajax_fltr_nonce = wp_create_nonce( "xyz-ips-blink" );?> |
| 92 |
var dataString = { |
| 93 |
action: 'ips_backlink', |
| 94 |
security:'<?php echo $ajax_fltr_nonce; ?>', |
| 95 |
enable: stat |
| 96 |
}; |
| 97 |
|
| 98 |
jQuery.post(ajaxurl, dataString, function(response) { |
| 99 |
|
| 100 |
if(response==1){ |
| 101 |
jQuery("#xyz_ips_backlink_div").html('Thank you for enabling backlink!'); |
| 102 |
jQuery("#xyz_ips_backlink_div").css('background-color', '#D8E8DA'); |
| 103 |
jQuery("#xyz_ips_backlink_div").css('border', '1px solid #0F801C'); |
| 104 |
jQuery("select[id=xyz_ips_credit] option[value=ips]").attr("selected", true); |
| 105 |
} |
| 106 |
|
| 107 |
if(response==-1){ |
| 108 |
jQuery("#xyz_ips_backlink_div").remove(); |
| 109 |
|
| 110 |
} |
| 111 |
|
| 112 |
}); |
| 113 |
} |
| 114 |
}); |
| 115 |
|
| 116 |
</script> |
| 117 |
</div> |
| 118 |
<?php |
| 119 |
} |
| 120 |
?> |
| 121 |
|
| 122 |
<style> |
| 123 |
#text {margin:50px auto; width:500px} |
| 124 |
.hotspot {color:#900; padding-bottom:1px; border-bottom:1px dotted #900; cursor:pointer} |
| 125 |
|
| 126 |
#tt {position:absolute; display:block; } |
| 127 |
#tttop {display:block; height:5px; margin-left:5px;} |
| 128 |
#ttcont {display:block; padding:2px 10px 3px 7px; margin-left:-400px; background:#666; color:#FFF} |
| 129 |
#ttbot {display:block; height:5px; margin-left:5px; } |
| 130 |
</style> |
| 131 |
|
| 132 |
|
| 133 |
|
| 134 |
|
| 135 |
|
| 136 |
<div style="margin-top: 10px"> |
| 137 |
<table style="float:right; "> |
| 138 |
<tr> |
| 139 |
<td style="float:right;" > |
| 140 |
<a class="xyz_header_link" style="margin-left:8px;margin-right:12px;" target="_blank" href="http://xyzscripts.com/donate/5">Donate</a> |
| 141 |
</td> |
| 142 |
<td style="float:right;"> |
| 143 |
<a class="xyz_header_link" style="margin-left:8px;" target="_blank" href="http://help.xyzscripts.com/docs/insert-php-code-snippet/faq/">FAQ</a> |
| 144 |
</td> |
| 145 |
<td style="float:right;"> |
| 146 |
<a class="xyz_header_link" style="margin-left:8px;" target="_blank" href="http://help.xyzscripts.com/docs/insert-php-code-snippet/">Readme</a> |
| 147 |
</td> |
| 148 |
<td style="float:right;"> |
| 149 |
<a class="xyz_header_link" style="margin-left:8px;" target="_blank" href="https://xyzscripts.com/wordpress-plugins/insert-php-code-snippet/details">About</a> |
| 150 |
</td> |
| 151 |
<td style="float:right;"> |
| 152 |
<a class="xyz_header_link" target="_blank" href="https://xyzscripts.com">XYZScripts</a> |
| 153 |
</td> |
| 154 |
|
| 155 |
</tr> |
| 156 |
</table> |
| 157 |
</div> |
| 158 |
|
| 159 |
<div style="clear: both"></div> |
| 160 |
|