Changeset 3401763
- Timestamp:
- 11/24/2025 10:56:06 AM (8 weeks ago)
- Location:
- scroll-popup/trunk
- Files:
-
- 2 added
- 2 deleted
- 3 edited
-
css/corner.css (deleted)
-
css/scroll-popup-admin-style.css (deleted)
-
js/admin-media.js (added)
-
js/color-picker.js (modified) (1 diff)
-
languages (added)
-
readme.txt (modified) (2 diffs)
-
tp-scroll-popup.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
scroll-popup/trunk/js/color-picker.js
r1473856 r3401763 1 jQuery(document).ready(function(jQuery) 2 { 1 // Minimal JS placeholder — currently no dynamic behavior required. 2 ( function( $ ) { 3 'use strict'; 4 // Future enhancements: responsive collapsing, copy path, etc. 3 5 4 5 jQuery('#kento_relatepost_bg, #kento_relatepost_font_color, #kento_relatepost_font_hover,#kento-popup-adsbg-color,#kento-popup-button-color,#kento-popup-button-text-color').wpColorPicker(); 6 7 8 9 10 }); 6 jQuery(document).ready(function($) { 7 $('#your-color-field, #your-color-field2, #your-color-field3').wpColorPicker(); 8 }); 9 10 } )( jQuery ); -
scroll-popup/trunk/readme.txt
r2502275 r3401763 2 2 Contributors: themepoints 3 3 Donate link: https://themepoints.com 4 Tags: manage ads, manage advertisements, Popup Ads Management, Publish popup advertisement, full screen popup, html popup, modal window, pop-up, popup, popup builder. Responsive popup.5 Requires at least: 3.86 Tested up to: 5.77 Stable tag: 1.0. 14 Tags: Popup, Advertisements, Popup Ads, modal window, popup 5 Requires at least: 4.0.0 6 Tested up to: 6.8 7 Stable tag: 1.0.2 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 74 74 == Changelog == 75 75 76 = 1.0.2 = 77 78 * Fix Security Issues. 79 * Fix Sanitization Issues. 80 * Fix CSS Issues. 81 * Added Image Uploader. 82 * Added New Color Option. 83 * Added New CSS. 84 * Update Options Page. 85 * Remove Unused CSS. 86 76 87 = 1.0.1 = 77 88 * Fix CSS Issues. 89 78 90 = 1.0 = 79 91 * Fix Auto Scroll Height Issues. 92 80 93 = 1.0 = 81 94 * Initial release -
scroll-popup/trunk/tp-scroll-popup.php
r2502275 r3401763 6 6 Author: Themepoints 7 7 Author URI: http://themepoints.com 8 Version:1.0.1 8 Version:1.0.2 9 License: GPLv2 or later 10 Text Domain: scroll-popup 11 Domain Path: /languages 9 12 */ 10 13 11 if ( ! defined( 'ABSPATH' ) ) 12 die( "Can't load this file directly" ); 13 14 define('TP_ADS_POPUP_PATH', WP_PLUGIN_URL . '/' . plugin_basename( dirname(__FILE__) ) . '/' ); 15 define('tp_ads_scroll_popup_plugin_dir', plugin_dir_path( __FILE__ ) ); 14 if ( ! defined( 'ABSPATH' ) ) { 15 exit; 16 } 17 18 // Define constants 19 if ( ! defined( 'SPFA_VERSION' ) ) { 20 define( 'SPFA_VERSION', '1.0.0' ); 21 } 22 if ( ! defined( 'SPFA_PLUGIN_FILE' ) ) { 23 define( 'SPFA_PLUGIN_FILE', __FILE__ ); 24 } 25 if ( ! defined( 'SPFA_PLUGIN_DIR' ) ) { 26 define( 'SPFA_PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); 27 } 28 if ( ! defined( 'SPFA_PLUGIN_URL' ) ) { 29 define( 'SPFA_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); 30 } 16 31 17 32 /*========================================================================== … … 19 34 ==========================================================================*/ 20 35 function tp_ads_scrollpopup_post_script(){ 21 wp_enqueue_script('jquery'); 22 wp_enqueue_script('corner-slider-js', plugins_url( '/js/jquery.cornerslider.js', __FILE__ ), array('jquery'), '1.0', false); 23 wp_enqueue_style('corner-style-css', TP_ADS_POPUP_PATH.'css/corner.css'); 24 wp_enqueue_style('corner-animate-css', TP_ADS_POPUP_PATH.'css/animate.css'); 25 wp_enqueue_style('corner-awesome-css', TP_ADS_POPUP_PATH.'css/font-awesome.min.css'); 26 wp_enqueue_style('wp-color-picker'); 27 wp_enqueue_script( 'corner_rp_color_picker', plugins_url('/js/color-picker.js', __FILE__ ), array( 'wp-color-picker' ), false, true ); 28 } 29 add_action('init', 'tp_ads_scrollpopup_post_script'); 30 36 37 wp_enqueue_script('jquery'); 38 wp_enqueue_media(); 39 40 wp_enqueue_style( 41 'spfa-animate', 42 SPFA_PLUGIN_URL . 'css/animate.css', 43 array(), 44 SPFA_VERSION 45 ); 46 47 wp_enqueue_style( 48 'spfa-fontawesome', 49 SPFA_PLUGIN_URL . 'css/font-awesome.min.css', 50 array(), 51 SPFA_VERSION 52 ); 53 54 wp_enqueue_script( 55 'spfa-cornerslider', 56 SPFA_PLUGIN_URL . 'js/jquery.cornerslider.js', 57 array( 'jquery' ), 58 SPFA_VERSION, 59 true 60 ); 61 } 62 add_action('wp_enqueue_scripts', 'tp_ads_scrollpopup_post_script'); 63 64 function tp_ads_scrollpopup_admin_scripts( $hook ) { 65 66 // Load jQuery (if needed) 67 wp_enqueue_script('jquery'); 68 69 wp_enqueue_media(); 70 71 wp_enqueue_script( 72 'spfa-admin-media', 73 SPFA_PLUGIN_URL . 'js/admin-media.js', 74 array('jquery'), 75 SPFA_VERSION, 76 true 77 ); 78 79 // Load WP built-in Color Picker CSS 80 wp_enqueue_style( 'wp-color-picker' ); 81 82 // Load WP built-in Color Picker JS 83 wp_enqueue_script( 'wp-color-picker' ); 84 85 // Load your custom color picker initializer 86 wp_enqueue_script( 87 'spfa-color-picker', 88 SPFA_PLUGIN_URL . 'js/color-picker.js', 89 array( 'wp-color-picker', 'jquery' ), 90 SPFA_VERSION, 91 true 92 ); 93 } 94 add_action( 'admin_enqueue_scripts', 'tp_ads_scrollpopup_admin_scripts' ); 31 95 32 96 /*========================================================================== … … 34 98 ==========================================================================*/ 35 99 function tp_ads_admin_styles_hook(){ 36 $tp_ads_popup_ads_bg_color = get_option( 'tp_ads_popup_ads_bg_color' ); 37 if(empty($tp_ads_popup_ads_bg_color)){ 38 $tp_ads_popup_ads_bg_color = "#18a3d9"; 39 } 40 $kento_popup_ads_button_color = get_option( 'kento_popup_ads_button_color' ); 41 if(empty($kento_popup_ads_button_color)) { 42 $kento_popup_ads_button_color = "#4b7a98"; 43 } 44 $kento_popup_ads_texts_color = get_option( 'kento_popup_ads_texts_color' ); 45 if(empty($kento_popup_ads_texts_color)) { 46 $kento_popup_ads_texts_color = "#ffffff"; 47 } 100 $tp_ads_popup_title_color = get_option( 'tp_ads_popup_title_color' ); 101 $tp_ads_popup_content_color = get_option( 'tp_ads_popup_content_color' ); 102 $tp_ads_popup_ads_bg_color = get_option( 'tp_ads_popup_ads_bg_color' ); 103 $kento_popup_ads_button_color = get_option( 'kento_popup_ads_button_color' ); 104 $kento_popup_ads_texts_color = get_option( 'kento_popup_ads_texts_color' ); 48 105 ?> 49 <style type="text/css"> 50 51 #corner-slider { 52 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 53 border: 4px solid #fff; 54 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 55 height: 400px; 56 overflow: hidden; 57 padding: 8px; 58 position: fixed; 59 width: 350px; 60 z-index: 10000; 61 } 62 #corner-slider.hidden{ 63 display:none; 64 } 65 #corner-slider .close { 66 background: #ddd none repeat scroll 0 0; 67 border-radius: 50px; 68 color: #000; 69 cursor: pointer; 70 display: inline-block; 71 font-size: 16px; 72 opacity: 0.6; 73 padding-left: 8px; 74 position: absolute; 75 right: 24px; 76 top: 12px; 77 width: 27px; 78 z-index: 1002; 79 } 80 .corner-header > h2 { 81 color: <?php echo $kento_popup_ads_texts_color; ?>; 82 font-family: Raleway,open sans; 83 font-weight: 600; 84 padding-bottom: 15px; 85 text-align: center; 86 font-size:16px; 87 } 88 #corner-slider span#download a h2 { 89 font-family: Raleway; 90 font-size: 20px; 91 font-weight: 600; 92 height: auto; 93 text-transform: uppercase; 94 width: 100%; 95 color:<?php echo $kento_popup_ads_texts_color; ?>; 96 } 97 #corner-slider span#download { 98 background: <?php echo $kento_popup_ads_button_color; ?>; 99 display: block; 100 margin: 28px auto 0; 101 text-align: center; 102 width: 250px; 103 } 104 #corner-slider span#download a h2 i { 105 margin-right: 18px; 106 } 107 #corner-slider span#download > a { 108 outline: medium none; 109 text-decoration: none; 110 } 111 #corner-slider span#content p { 112 color: <?php echo $kento_popup_ads_texts_color; ?>; 113 font-family: Raleway,open sans; 114 font-size: 13px; 115 font-weight: 500; 116 padding-top: 5px; 117 text-align: center; 118 } 119 120 #corner-slider > span { 121 display: block; 122 padding: 0 10px; 123 } 124 #corner-slider span#corner-thumb img { 125 height: auto; 126 width: 100%; 127 } 128 129 /*========== Mobile First Method ==========*/ 130 131 /* Custom, iPhone Retina */ 132 @media only screen and (min-width : 320px) { 133 #corner-slider { 134 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 135 border: 4px solid #fff; 136 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 137 height: 400px; 138 overflow: hidden; 139 padding: 8px; 140 position: fixed; 141 width: 300px; 142 z-index: 10000; 143 } 144 } 145 146 /* Extra Small Devices, Phones */ 147 @media only screen and (min-width : 480px) { 148 #corner-slider { 149 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 150 border: 4px solid #fff; 151 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 152 height: 400px; 153 overflow: hidden; 154 padding: 8px; 155 position: fixed; 156 width: 350px; 157 z-index: 10000; 158 } 159 160 } 161 162 /* Small Devices, Tablets */ 163 @media only screen and (min-width : 768px) { 164 #corner-slider { 165 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 166 border: 4px solid #fff; 167 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 168 height: 400px; 169 overflow: hidden; 170 padding: 8px; 171 position: fixed; 172 width: 350px; 173 z-index: 10000; 174 } 175 176 } 177 178 /* Medium Devices, Desktops */ 179 @media only screen and (min-width : 992px) { 180 #corner-slider { 181 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 182 border: 4px solid #fff; 183 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 184 height: 400px; 185 overflow: hidden; 186 padding: 8px; 187 position: fixed; 188 width: 350px; 189 z-index: 10000; 190 } 191 192 } 193 194 /* Large Devices, Wide Screens */ 195 @media only screen and (min-width : 1200px) { 196 #corner-slider { 197 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 198 border: 4px solid #fff; 199 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 200 height: 445px; 201 overflow: hidden; 202 padding: 8px; 203 position: fixed; 204 width: 350px; 205 z-index: 10000; 206 } 207 } 208 209 210 211 /*========== Non-Mobile First Method ==========*/ 212 213 /* Large Devices, Wide Screens */ 214 @media only screen and (max-width : 1200px) { 215 #corner-slider { 216 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 217 border: 4px solid #fff; 218 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 219 height: 445px; 220 overflow: hidden; 221 padding: 8px; 222 position: fixed; 223 width: 350px; 224 z-index: 10000; 225 } 226 #corner-slider span#download { 227 background: <?php echo $kento_popup_ads_button_color; ?>; 228 display: block; 229 margin: 28px auto 0; 230 text-align: center; 231 width: 250px; 232 } 233 } 234 235 /* Medium Devices, Desktops */ 236 @media only screen and (max-width : 992px) { 237 #corner-slider { 238 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 239 border: 4px solid #fff; 240 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 241 height: 400px; 242 overflow: hidden; 243 padding: 8px; 244 position: fixed; 245 width: 350px; 246 z-index: 10000; 247 } 248 #corner-slider span#download { 249 background: <?php echo $kento_popup_ads_button_color; ?>; 250 display: block; 251 margin: 28px auto 0; 252 text-align: center; 253 width: 250px; 254 } 255 256 } 257 258 /* Small Devices, Tablets */ 259 @media only screen and (max-width : 768px) { 260 #corner-slider { 261 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 262 border: 4px solid #fff; 263 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 264 height: 445px; 265 overflow: hidden; 266 padding: 8px; 267 position: fixed; 268 width: 350px; 269 z-index: 10000; 270 } 271 #corner-slider span#download { 272 background: <?php echo $kento_popup_ads_button_color; ?>; 273 display: block; 274 margin: 28px auto 0; 275 text-align: center; 276 width: 250px; 277 } 278 } 279 280 /* Extra Small Devices, Phones */ 281 @media only screen and (max-width : 480px) { 282 #corner-slider { 283 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 284 border: 4px solid #fff; 285 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 286 height: 400px; 287 overflow: hidden; 288 padding: 8px; 289 position: fixed; 290 width: 350px; 291 z-index: 10000; 292 } 293 #corner-slider span#download { 294 background: <?php echo $kento_popup_ads_button_color; ?>; 295 display: block; 296 margin: 28px auto 0; 297 text-align: center; 298 width: 250px; 299 } 300 } 301 302 /* Custom, iPhone Retina */ 303 @media only screen and (max-width : 320px) { 304 #corner-slider { 305 background: <?php echo $tp_ads_popup_ads_bg_color; ?>; 306 border: 4px solid #fff; 307 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 308 height: 400px; 309 overflow: hidden; 310 padding: 8px; 311 position: fixed; 312 width: 250px; 313 z-index: 10000; 314 } 315 #corner-slider span#download { 316 background: <?php echo $kento_popup_ads_button_color; ?>; 317 display: block; 318 margin: 28px auto 0; 319 text-align: center; 320 width: 210px; 321 } 322 } 323 </style> 106 107 <style type="text/css"> 108 #corner-slider { 109 background: <?php echo esc_attr($tp_ads_popup_ads_bg_color); ?>; 110 border: 4px solid #fff; 111 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 112 height: 400px; 113 overflow: hidden; 114 padding: 8px; 115 position: fixed; 116 width: 350px; 117 z-index: 10000; 118 } 119 #corner-slider.hidden{ 120 display:none; 121 } 122 #corner-slider .close { 123 background: #ddd none repeat scroll 0 0; 124 color: #000; 125 cursor: pointer; 126 display: inline-block; 127 font-size: 16px; 128 opacity: 0.6; 129 position: absolute; 130 right: 20px; 131 top: 15px; 132 border-radius: 15px; 133 padding: 4px 10px; 134 z-index: 1; 135 display: flex; 136 flex-wrap: wrap; 137 align-items: center; 138 justify-content: space-between; 139 } 140 .corner-header > h2 { 141 color: <?php echo esc_attr($tp_ads_popup_title_color); ?>; 142 font-weight: 600; 143 padding-bottom: 15px; 144 text-align: center; 145 font-size:16px; 146 } 147 #corner-slider span#download { 148 display: block; 149 margin-top: 15px; 150 text-align: center; 151 } 152 #corner-slider span#download a { 153 display: inline-block; 154 padding: 6px 15px; 155 font-size: 15px; 156 background: <?php echo esc_attr($kento_popup_ads_button_color); ?>; 157 color: <?php echo esc_attr($kento_popup_ads_texts_color); ?>; 158 text-decoration: none; 159 border-radius: 5px; 160 font-weight: 600; 161 } 162 #corner-slider span#content p { 163 color: <?php echo esc_attr($tp_ads_popup_content_color); ?>; 164 font-size: 15px; 165 font-weight: 500; 166 padding-top: 5px; 167 text-align: center; 168 } 169 #corner-slider > span { 170 display: block; 171 padding: 0 10px; 172 } 173 #corner-slider span#corner-thumb { 174 height: 250px; 175 } 176 #corner-slider span#corner-thumb img { 177 height: 100%; 178 width: 100%; 179 object-fit: cover; 180 } 181 182 /*========== Mobile First Method ==========*/ 183 184 /* Custom, iPhone Retina */ 185 @media only screen and (min-width : 320px) { 186 #corner-slider { 187 border: 4px solid #fff; 188 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 189 height: 400px; 190 overflow: hidden; 191 padding: 8px; 192 position: fixed; 193 width: 300px; 194 z-index: 10000; 195 } 196 } 197 198 /* Extra Small Devices, Phones */ 199 @media only screen and (min-width : 480px) { 200 #corner-slider { 201 border: 4px solid #fff; 202 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 203 height: 400px; 204 overflow: hidden; 205 padding: 8px; 206 position: fixed; 207 width: 350px; 208 z-index: 10000; 209 } 210 } 211 212 /* Small Devices, Tablets */ 213 @media only screen and (min-width : 768px) { 214 #corner-slider { 215 border: 4px solid #fff; 216 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 217 height: 400px; 218 overflow: hidden; 219 padding: 8px; 220 position: fixed; 221 width: 350px; 222 z-index: 10000; 223 } 224 } 225 226 /* Medium Devices, Desktops */ 227 @media only screen and (min-width : 992px) { 228 #corner-slider { 229 border: 4px solid #fff; 230 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 231 height: 400px; 232 overflow: hidden; 233 padding: 8px; 234 position: fixed; 235 width: 350px; 236 z-index: 10000; 237 } 238 } 239 240 /* Large Devices, Wide Screens */ 241 @media only screen and (min-width : 1200px) { 242 #corner-slider { 243 border: 4px solid #fff; 244 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 245 height: 445px; 246 overflow: hidden; 247 padding: 8px; 248 position: fixed; 249 width: 350px; 250 z-index: 10000; 251 } 252 } 253 254 /*========== Non-Mobile First Method ==========*/ 255 256 /* Large Devices, Wide Screens */ 257 @media only screen and (max-width : 1200px) { 258 #corner-slider { 259 border: 4px solid #fff; 260 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 261 height: 445px; 262 overflow: hidden; 263 padding: 8px; 264 position: fixed; 265 width: 350px; 266 z-index: 10000; 267 } 268 #corner-slider span#download { 269 display: block; 270 margin: 28px auto 0; 271 text-align: center; 272 width: 250px; 273 } 274 } 275 276 /* Medium Devices, Desktops */ 277 @media only screen and (max-width : 992px) { 278 #corner-slider { 279 border: 4px solid #fff; 280 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 281 height: 400px; 282 overflow: hidden; 283 padding: 8px; 284 position: fixed; 285 width: 350px; 286 z-index: 10000; 287 } 288 #corner-slider span#download { 289 display: block; 290 margin: 28px auto 0; 291 text-align: center; 292 width: 250px; 293 } 294 } 295 296 /* Small Devices, Tablets */ 297 @media only screen and (max-width : 768px) { 298 #corner-slider { 299 border: 4px solid #fff; 300 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 301 height: 445px; 302 overflow: hidden; 303 padding: 8px; 304 position: fixed; 305 width: 350px; 306 z-index: 10000; 307 } 308 #corner-slider span#download { 309 display: block; 310 margin: 28px auto 0; 311 text-align: center; 312 width: 250px; 313 } 314 } 315 316 /* Extra Small Devices, Phones */ 317 @media only screen and (max-width : 480px) { 318 #corner-slider { 319 border: 4px solid #fff; 320 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 321 height: 400px; 322 overflow: hidden; 323 padding: 8px; 324 position: fixed; 325 width: 350px; 326 z-index: 10000; 327 } 328 #corner-slider span#download { 329 display: block; 330 margin: 28px auto 0; 331 text-align: center; 332 width: 250px; 333 } 334 } 335 336 /* Custom, iPhone Retina */ 337 @media only screen and (max-width : 320px) { 338 #corner-slider { 339 border: 4px solid #fff; 340 box-shadow: 0 0 8px 0 rgba(50, 50, 50, 0.75); 341 height: 400px; 342 overflow: hidden; 343 padding: 8px; 344 position: fixed; 345 width: 250px; 346 z-index: 10000; 347 } 348 #corner-slider span#download { 349 display: block; 350 margin: 28px auto 0; 351 text-align: center; 352 width: 210px; 353 } 354 } 355 </style> 324 356 <?php 325 357 } 326 358 add_action('wp_head', 'tp_ads_admin_styles_hook'); 327 328 329 359 330 360 /*=============================================== 331 361 Scroll Popup Main Scripts 332 362 =================================================*/ 333 334 363 function tp_ads_scroll_popup_active_script(){ 335 $tp_ads_popup_adds_sidebar = get_option( 'tp_ads_popup_adds_sidebar' ); 336 if(empty($tp_ads_popup_adds_sidebar)) 337 { 338 $tp_ads_popup_adds_sidebar = "right"; 339 } 364 $tp_ads_popup_adds_sidebar = get_option( 'tp_ads_popup_adds_sidebar' ); 365 if(empty($tp_ads_popup_adds_sidebar)) { 366 $tp_ads_popup_adds_sidebar = "right"; 367 } 340 368 ?> 341 369 <script type="text/javascript"> … … 343 371 $("#corner-slider").cornerSlider({ 344 372 showAtScrollingHeight : 1000, 345 directionEffect : "<?php echo $tp_ads_popup_adds_sidebar; ?>",373 directionEffect : "<?php echo esc_attr($tp_ads_popup_adds_sidebar); ?>", 346 374 speedEffect : 300, 347 375 right : 20, … … 362 390 function tp_ads_scroll_popup_main_options(){ 363 391 364 $tp_ads_popup_adds_desc = get_option( 'tp_ads_popup_adds_desc' ); 365 $tp_ads_popup_screen_bg_img = get_option( 'tp_ads_popup_screen_bg_img' ); 366 $tp_ads_popup_ads_title = get_option( 'tp_ads_popup_ads_title' ); 367 if(empty($tp_ads_popup_ads_title)) 368 { 369 $tp_ads_popup_ads_title = "Your Ad Title Here...."; 370 } 371 392 $tp_ads_popup_ads_title = get_option( 'tp_ads_popup_ads_title' ); 393 $tp_ads_popup_screen_bg_img = get_option( 'tp_ads_popup_screen_bg_img' ); 394 $tp_ads_popup_adds_desc = get_option( 'tp_ads_popup_adds_desc' ); 372 395 $tp_ads_popup_purchase_btn = get_option( 'tp_ads_popup_purchase_btn' ); 373 if(empty($tp_ads_popup_purchase_btn)) 374 { 375 $tp_ads_popup_purchase_btn = "Purchase Now"; 376 } 396 if(empty($tp_ads_popup_purchase_btn)) { 397 $tp_ads_popup_purchase_btn = "Purchase Now"; 398 } 377 399 $tp_ads_popup_ads_button_link = get_option( 'tp_ads_popup_ads_button_link' ); 378 if(empty($tp_ads_popup_ads_button_link)) 379 { 380 $tp_ads_popup_ads_button_link = "yourdomain.com"; 381 } 400 if(empty($tp_ads_popup_ads_button_link)) { 401 $tp_ads_popup_ads_button_link = "example.com"; 402 } 382 403 $tp_ads_popup_adds_open_page = get_option( 'tp_ads_popup_adds_open_page' ); 383 if(empty($tp_ads_popup_adds_open_page)) 384 { 385 $tp_ads_popup_adds_open_page = "_self"; 386 } 404 if(empty($tp_ads_popup_adds_open_page)) { 405 $tp_ads_popup_adds_open_page = "_self"; 406 } 387 407 388 408 ?> 389 409 390 410 <div id="corner-slider"> 391 <span class="corner-header"><h2><?php echo $tp_ads_popup_ads_title;?></h2></span> 392 <span id="corner-thumb"><img src="<?php echo $tp_ads_popup_screen_bg_img;?>" alt="" /> 411 <span class="corner-header"> 412 <h2><?php echo esc_html( $tp_ads_popup_ads_title ); ?></h2> 413 </span> 414 <span id="corner-thumb"> 415 <img src="<?php echo esc_url( $tp_ads_popup_screen_bg_img ); ?>" alt="" /> 393 416 </span> 394 417 <span id="content"> 395 <p><?php echo $tp_ads_popup_adds_desc;?></p>418 <p><?php echo wp_kses_post( $tp_ads_popup_adds_desc ); ?></p> 396 419 </span> 397 420 <span id="download"> 398 <a target="<?php echo $tp_ads_popup_adds_open_page;?>" href="<?php echo $tp_ads_popup_ads_button_link;?>"><h2><?php echo $tp_ads_popup_purchase_btn;?></h2></a> 421 <a target="<?php echo esc_attr($tp_ads_popup_adds_open_page); ?>" href="<?php echo esc_url($tp_ads_popup_ads_button_link); ?>"> 422 <?php echo esc_html( $tp_ads_popup_purchase_btn ); ?> 423 </a> 399 424 </span> 400 425 </div> … … 404 429 add_action('wp_footer', 'tp_ads_scroll_popup_main_options'); 405 430 406 407 /*===============================================408 Scroll Popup Admin Enqueue Style409 =================================================*/410 411 function tp_ads_popup_admin_enqueue_script(){412 wp_enqueue_style( 'tp-admin-stylesheet', plugins_url('css/scroll-popup-admin-style.css', __FILE__) );413 }414 add_action('admin_enqueue_scripts', 'tp_ads_popup_admin_enqueue_script');415 416 417 function tp_ads_scroll_popup_load_fonts() {418 wp_register_style('krp_Rajdhani', 'http://fonts.googleapis.com/css?family=Rajdhani:500,600');419 wp_register_style('krp_Raleway', 'http://fonts.googleapis.com/css?family=Raleway:700,400');420 wp_register_style('krp_Open-Sans', 'http://fonts.googleapis.com/css?family=Open+Sans:400,700');421 wp_register_style('krp_Roboto', 'http://fonts.googleapis.com/css?family=Roboto:400,500,700');422 wp_register_style('krp_Roboto-condensed', 'http://fonts.googleapis.com/css?family=Roboto+Condensed:400,700');423 wp_register_style('krp_Oswald', 'http://fonts.googleapis.com/css?family=Oswald:400,700');424 wp_register_style('krp_droid-sans', 'http://fonts.googleapis.com/css?family=Droid+Sans');425 wp_register_style('krp_lato', 'http://fonts.googleapis.com/css?family=Lato:400,700');426 wp_register_style('krp_Montserrat', 'http://fonts.googleapis.com/css?family=Montserrat:400,700');427 428 wp_enqueue_style( 'krp_Montserrat');429 wp_enqueue_style( 'krp_lato');430 wp_enqueue_style( 'krp_droid-sans');431 wp_enqueue_style( 'krp_Oswald');432 wp_enqueue_style( 'krp_Roboto-condensed');433 wp_enqueue_style( 'krp_Roboto');434 wp_enqueue_style( 'krp_Open-Sans');435 wp_enqueue_style( 'krp_Rajdhani');436 wp_enqueue_style( 'krp_Raleway');437 }438 add_action('wp_print_styles', 'tp_ads_scroll_popup_load_fonts');439 440 431 /*=============================================== 441 432 Scroll Popup Option Register 442 433 =================================================*/ 443 434 function tp_ads_scroll_popup_option_init(){ 444 register_setting( 'tp_ads_scrollpopup_options_setting', 'tp_ads_popup_ads_title'); 445 register_setting( 'tp_ads_scrollpopup_options_setting', 'tp_ads_popup_adds_desc'); 446 register_setting( 'tp_ads_scrollpopup_options_setting', 'tp_ads_popup_screen_bg_img'); 447 register_setting( 'tp_ads_scrollpopup_options_setting', 'kento_scroll_popup_screen_content'); 448 register_setting( 'tp_ads_scrollpopup_options_setting', 'tp_ads_popup_adds_sidebar'); 449 register_setting( 'tp_ads_scrollpopup_options_setting', 'kento_popup_ads_texts_color'); 450 register_setting( 'tp_ads_scrollpopup_options_setting', 'kento_popup_ads_button_color'); 451 register_setting( 'tp_ads_scrollpopup_options_setting', 'tp_ads_popup_ads_bg_color'); 435 // Text field (title) 436 register_setting( 437 'tp_ads_scrollpopup_options_setting', 438 'tp_ads_popup_ads_title', 439 array( 440 'sanitize_callback' => 'sanitize_text_field', 441 ) 442 ); 443 444 // Color field (#FFFFFF, rgb(), etc.) 445 register_setting( 446 'tp_ads_scrollpopup_options_setting', 447 'tp_ads_popup_title_color', 448 array( 449 'sanitize_callback' => 'sanitize_hex_color', 450 ) 451 ); 452 453 // Description (textarea allowed) 454 register_setting( 455 'tp_ads_scrollpopup_options_setting', 456 'tp_ads_popup_adds_desc', 457 array( 458 'sanitize_callback' => 'sanitize_textarea_field', 459 ) 460 ); 461 462 // Content color 463 register_setting( 464 'tp_ads_scrollpopup_options_setting', 465 'tp_ads_popup_content_color', 466 array( 467 'sanitize_callback' => 'sanitize_hex_color', 468 ) 469 ); 470 471 // Image URL 472 register_setting( 473 'tp_ads_scrollpopup_options_setting', 474 'tp_ads_popup_screen_bg_img', 475 array( 476 'sanitize_callback' => 'esc_url_raw', 477 ) 478 ); 479 480 // This looks like a textarea field 481 register_setting( 482 'tp_ads_scrollpopup_options_setting', 483 'kento_scroll_popup_screen_content', 484 array( 485 'sanitize_callback' => 'sanitize_textarea_field', 486 ) 487 ); 488 489 // Sidebar selection (from dropdown) → sanitize_text_field is safe 490 register_setting( 491 'tp_ads_scrollpopup_options_setting', 492 'tp_ads_popup_adds_sidebar', 493 array( 494 'sanitize_callback' => 'sanitize_text_field', 495 ) 496 ); 497 498 // Text color 499 register_setting( 500 'tp_ads_scrollpopup_options_setting', 501 'kento_popup_ads_texts_color', 502 array( 503 'sanitize_callback' => 'sanitize_hex_color', 504 ) 505 ); 506 507 // Button color 508 register_setting( 509 'tp_ads_scrollpopup_options_setting', 510 'kento_popup_ads_button_color', 511 array( 512 'sanitize_callback' => 'sanitize_hex_color', 513 ) 514 ); 515 516 // Background color 517 register_setting( 518 'tp_ads_scrollpopup_options_setting', 519 'tp_ads_popup_ads_bg_color', 520 array( 521 'sanitize_callback' => 'sanitize_hex_color', 522 ) 523 ); 452 524 } 453 525 add_action('admin_init', 'tp_ads_scroll_popup_option_init' ); 454 526 455 /*=============================================== 456 Scroll Popup Option Page Settings 457 =================================================*/ 458 function tp_ads_scroll_popup_options_panel(){ 459 add_menu_page('plugins page title', 'Scroll Popup', 'manage_options', 'theme-options', 'tp_ads_scroll_popup_theme_func'); 460 add_submenu_page( 'theme-options', 'Support', 'Support', 'manage_options', 'theme-op-settings', 'tp_ads_scroll_popup_theme_func_settings'); 461 } 462 add_action('admin_menu', 'tp_ads_scroll_popup_options_panel'); 463 464 465 function tp_ads_scroll_popup_theme_func(){?> 466 <?php 467 468 if(empty($_POST['tp_ads_scrollpopup_options_hidden'])){ 469 $tp_ads_popup_ads_title = get_option( 'tp_ads_popup_ads_title' ); 470 $tp_ads_popup_adds_desc = get_option( 'tp_ads_popup_adds_desc' ); 471 $tp_ads_popup_screen_bg_img = get_option( 'tp_ads_popup_screen_bg_img' ); 472 $tp_ads_popup_purchase_btn = get_option( 'tp_ads_popup_purchase_btn' ); 473 $tp_ads_popup_adds_sidebar = get_option( 'tp_ads_popup_adds_sidebar' ); 474 $tp_ads_popup_ads_bg_color = get_option( 'tp_ads_popup_ads_bg_color' ); 475 $kento_popup_ads_texts_color = get_option( 'kento_popup_ads_texts_color' ); 476 $kento_popup_ads_button_color = get_option( 'kento_popup_ads_button_color' ); 477 $tp_ads_popup_ads_button_link = get_option( 'tp_ads_popup_ads_button_link' ); 478 $tp_ads_popup_adds_open_page = get_option( 'tp_ads_popup_adds_open_page' ); 479 } else { 480 if($_POST['tp_ads_scrollpopup_options_hidden'] == 'Y') { 481 //Form data sent 482 $tp_ads_popup_ads_title = $_POST['tp_ads_popup_ads_title']; 483 update_option('tp_ads_popup_ads_title', $tp_ads_popup_ads_title); 484 485 $tp_ads_popup_adds_desc = $_POST['tp_ads_popup_adds_desc']; 486 update_option('tp_ads_popup_adds_desc', $tp_ads_popup_adds_desc); 487 488 $tp_ads_popup_screen_bg_img = $_POST['tp_ads_popup_screen_bg_img']; 489 update_option('tp_ads_popup_screen_bg_img', $tp_ads_popup_screen_bg_img); 527 function spfa_register_admin_menu() { 528 529 // Main Menu Page 530 add_menu_page( 531 'Scroll Popup Ads', // Page title 532 'Scroll Popup Ads', // Menu title 533 'manage_options', // Capability 534 'spfa-main-page', // Menu slug 535 'tp_ads_scroll_popup_theme_func', // Callback function 536 'dashicons-megaphone', // Icon 537 30 // Position 538 ); 539 540 // Submenu Page 541 add_submenu_page( 542 'spfa-main-page', // Parent slug 543 'Popup Settings', // Page title 544 'Settings', // Submenu title 545 'manage_options', // Capability 546 'spfa-settings', // Menu slug 547 'tp_ads_scroll_popup_theme_func_settings' // Callback function 548 ); 549 } 550 add_action( 'admin_menu', 'spfa_register_admin_menu' ); 551 552 553 function tp_ads_scroll_popup_theme_func(){ 554 555 $tp_ads_popup_ads_title = get_option('tp_ads_popup_ads_title', esc_html__( 'Default Title', 'scroll-popup' )); 556 $tp_ads_popup_title_color = get_option('tp_ads_popup_title_color'); 557 $tp_ads_popup_adds_desc = get_option('tp_ads_popup_adds_desc'); 558 $tp_ads_popup_content_color = get_option('tp_ads_popup_content_color'); 559 $tp_ads_popup_screen_bg_img = get_option( 'tp_ads_popup_screen_bg_img', '' ); 560 $tp_ads_popup_purchase_btn = get_option( 'tp_ads_popup_purchase_btn' ); 561 $tp_ads_popup_adds_sidebar = get_option( 'tp_ads_popup_adds_sidebar' ); 562 $tp_ads_popup_ads_bg_color = get_option( 'tp_ads_popup_ads_bg_color' ); 563 $kento_popup_ads_texts_color = get_option( 'kento_popup_ads_texts_color' ); 564 $kento_popup_ads_button_color = get_option( 'kento_popup_ads_button_color' ); 565 $tp_ads_popup_ads_button_link = get_option( 'tp_ads_popup_ads_button_link' ); 566 $tp_ads_popup_adds_open_page = get_option( 'tp_ads_popup_adds_open_page' ); 567 568 ?> 569 570 571 <div class="wrap"> 572 <h1><?php echo esc_html__( 'Scroll Popup Ads – Main Settings', 'scroll-popup' ); ?></h1> 573 574 <form method="post" action="options.php"> 575 <input type="hidden" name="tp_ads_scrollpopup_options_hidden" value="Y"> 576 <?php 577 settings_fields( 'tp_ads_scrollpopup_options_setting' ); 578 do_settings_sections( 'tp_ads_scrollpopup_options_setting' ); 579 ?> 580 581 <table class="form-table"> 582 583 <tr valign="top"> 584 <th scope="row"> 585 <label for="tp_ads_popup_ads_title"><?php echo esc_html__( 'Ads Title', 'scroll-popup' ); ?></label> 586 </th> 587 588 <td style="vertical-align:middle;"> 589 <input 590 size="20" 591 name="tp_ads_popup_ads_title" 592 class="kento-ads-title" 593 type="text" 594 id="kento-ads-title" 595 value="<?php echo esc_attr($tp_ads_popup_ads_title); ?>" 596 /><br /> 597 598 <span style="font-size:12px;color:#22aa5d"> 599 <?php echo esc_html__( 'Insert your ads title.', 'scroll-popup' ); ?> 600 </span> 601 </td> 602 </tr> 603 604 <tr valign="top"> 605 <th scope="row"> 606 <label for="tp_ads_popup_title_color"> 607 <?php echo esc_html__( 'Title Color', 'scroll-popup' ); ?> 608 </label> 609 </th> 610 611 <td style="vertical-align:middle;"> 612 613 <input 614 type="text" 615 size="10" 616 name="tp_ads_popup_title_color" 617 id="your-color-field" 618 class="spfa-color-field" 619 value="<?php echo esc_attr( $tp_ads_popup_title_color ); ?>" 620 /> 621 <br /> 622 623 <span style="font-size:12px;color:#22aa5d"> 624 <?php echo esc_html__( 'Choose Title Color', 'scroll-popup' ); ?> 625 </span> 626 627 </td> 628 </tr> 629 630 <tr valign="top"> 631 <th scope="row"> 632 <label for="tp_ads_popup_screen_bg_img"> 633 <?php echo esc_html__( 'Ads Image', 'scroll-popup' ); ?> 634 </label> 635 </th> 636 637 <td style="vertical-align:middle;"> 638 <input 639 type="text" 640 name="tp_ads_popup_screen_bg_img" 641 id="tp_ads_popup_screen_bg_img" 642 size="45" 643 value="<?php echo esc_attr( $tp_ads_popup_screen_bg_img ); ?>" 644 /> 645 646 <br><br> 647 648 <button 649 class="button spfa-upload-btn" 650 data-target="tp_ads_popup_screen_bg_img" 651 data-preview="spfa-image-preview" 652 > 653 <?php echo esc_html__( 'Upload Image', 'scroll-popup' ); ?> 654 </button> 655 656 <button 657 class="button spfa-remove-btn" 658 data-target="tp_ads_popup_screen_bg_img" 659 data-preview="spfa-image-preview" 660 > 661 <?php echo esc_html__( 'Remove Image', 'scroll-popup' ); ?> 662 </button> 663 664 <div id="spfa-image-preview" style="margin-top:15px;"> 665 <?php if ( ! empty( $tp_ads_popup_screen_bg_img ) ) : ?> 666 <img src="<?php echo esc_url( $tp_ads_popup_screen_bg_img ); ?>" style="max-width:150px; height:auto;"> 667 <?php endif; ?> 668 </div> 669 670 </td> 671 </tr> 672 673 <tr valign="top"> 674 <th scope="row"> 675 <label for="tp_ads_popup_adds_desc"> 676 <?php echo esc_html__( 'Ads Description', 'scroll-popup' ); ?> 677 </label> 678 </th> 679 680 <td style="vertical-align:middle;"> 681 <textarea 682 name="tp_ads_popup_adds_desc" 683 class="kento-ads-description" 684 id="kento-ads-description" 685 rows="5" 686 cols="50" 687 ><?php echo esc_textarea( $tp_ads_popup_adds_desc ); ?></textarea> 688 <br /> 689 690 <span style="font-size:12px;color:#22aa5d"> 691 <?php echo esc_html__( 'Insert your ads description.', 'scroll-popup' ); ?> 692 </span> 693 694 </td> 695 </tr> 490 696 491 $tp_ads_popup_purchase_btn = $_POST['tp_ads_popup_purchase_btn']; 492 update_option('tp_ads_popup_purchase_btn', $tp_ads_popup_purchase_btn); 697 <tr valign="top"> 698 <th scope="row"> 699 <label for="tp_ads_popup_content_color"> 700 <?php echo esc_html__( 'Content Color', 'scroll-popup' ); ?> 701 </label> 702 </th> 703 704 <td style="vertical-align:middle;"> 705 <input 706 type="text" 707 size="10" 708 name="tp_ads_popup_content_color" 709 id="your-color-field" 710 class="spfa-color-field" 711 value="<?php echo esc_attr( $tp_ads_popup_content_color ); ?>" 712 /> 713 <br /> 714 715 <span style="font-size:12px;color:#22aa5d"> 716 <?php echo esc_html__( 'Choose Content Color', 'scroll-popup' ); ?> 717 </span> 718 719 </td> 720 </tr> 721 722 <tr valign="top"> 723 <th scope="row"> 724 <label for="tp_ads_popup_ads_bg_color"> 725 <?php echo esc_html__( 'Ads Background Color', 'scroll-popup' ); ?> 726 </label> 727 </th> 728 <td style="vertical-align:middle;"> 729 <input size='10' name='tp_ads_popup_ads_bg_color' class='tp_ads_popup_ads_bg_color' type='text' id="your-color-field" value='<?php echo esc_attr($tp_ads_popup_ads_bg_color); ?>' /><br /> 730 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Choose Ads Background color.', 'scroll-popup' ); ?></span> 731 </td> 732 </tr> 493 733 494 $tp_ads_popup_adds_sidebar = $_POST['tp_ads_popup_adds_sidebar']; 495 update_option('tp_ads_popup_adds_sidebar', $tp_ads_popup_adds_sidebar); 734 <tr valign="top"> 735 <th scope="row"> 736 <label for="tp_ads_popup_adds_sidebar"> 737 <?php echo esc_html__( 'Display Ads in corner', 'scroll-popup' ); ?> 738 </label> 739 </th> 740 <td style="vertical-align:middle;"> 741 <select name="tp_ads_popup_adds_sidebar"> 742 <option value="top" <?php if($tp_ads_popup_adds_sidebar=='top') echo "selected"; ?> ><?php echo esc_html__( 'Top', 'scroll-popup' ); ?></option> 743 <option value="left" <?php if($tp_ads_popup_adds_sidebar=='left') echo "selected"; ?> ><?php echo esc_html__( 'Left', 'scroll-popup' ); ?></option> 744 <option value="right" <?php if($tp_ads_popup_adds_sidebar=='right') echo "selected"; ?> ><?php echo esc_html__( 'Right', 'scroll-popup' ); ?></option> 745 <option value="bottom" <?php if($tp_ads_popup_adds_sidebar=='bottom') echo "selected"; ?> ><?php echo esc_html__( 'Bottom', 'scroll-popup' ); ?></option> 746 </select><br> 747 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Choose Which corner you want to show your ads.', 'scroll-popup' ); ?></span> 748 </td> 749 </tr> 496 750 497 $tp_ads_popup_ads_bg_color = $_POST['tp_ads_popup_ads_bg_color']; 498 update_option('tp_ads_popup_ads_bg_color', $tp_ads_popup_ads_bg_color); 751 <tr valign="top"> 752 <th scope="row"><label for="tp_ads_popup_purchase_btn"><?php echo esc_html__( 'Purchase Button Text', 'scroll-popup' ); ?></label></th> 753 <td style="vertical-align:middle;"> 754 <input placeholder="Purchase Now" size='45' name='tp_ads_popup_purchase_btn' class='kento-ads-btn' type='text' id="kento-ads-btn" value='<?php echo esc_attr($tp_ads_popup_purchase_btn); ?>' /><br /> 755 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Button Text', 'scroll-popup' ); ?></span> 756 </td> 757 </tr> 499 758 500 $kento_popup_ads_texts_color = $_POST['kento_popup_ads_texts_color'];501 update_option('kento_popup_ads_texts_color', $kento_popup_ads_texts_color);502 503 $kento_popup_ads_button_color = $_POST['kento_popup_ads_button_color'];504 update_option('kento_popup_ads_button_color', $kento_popup_ads_button_color);505 506 $tp_ads_popup_ads_button_link = $_POST['tp_ads_popup_ads_button_link'];507 update_option('tp_ads_popup_ads_button_link', $tp_ads_popup_ads_button_link);508 509 $tp_ads_popup_adds_open_page = $_POST['tp_ads_popup_adds_open_page'];510 update_option('tp_ads_popup_adds_open_page', $tp_ads_popup_adds_open_page);511 512 ?>513 <div class="updated"><p><strong><?php _e('Changes Saved.' ); ?></strong></p></div>514 <?php515 }516 }517 ?>518 519 520 <div class="wrap">521 <?php echo "<h2>".__('Scroll Popup Ads Settings')."</h2>";?>522 523 <form method="post" action="<?php echo str_replace( '%7E', '~', $_SERVER['REQUEST_URI']); ?>">524 <input type="hidden" name="tp_ads_scrollpopup_options_hidden" value="Y">525 <?php settings_fields( 'tp_ads_scrollpopup_options_setting' );526 do_settings_sections( 'tp_ads_scrollpopup_options_setting' );527 ?>528 <table class="form-table">529 530 759 <tr valign="top"> 531 <th scope="row"><label for="tp_ads_popup_ads_title">Ads Title</label></th> 760 <th scope="row"> 761 <label for="tp_ads_popup_ads_button_link"> 762 <?php echo esc_html__( 'Purchase Button Link', 'scroll-popup' ); ?> 763 </label> 764 </th> 532 765 <td style="vertical-align:middle;"> 533 <input size='20' name='tp_ads_popup_ads_title' class='kento-ads-title' type='text' id="kento-ads-title" value='<?php echo esc_attr($tp_ads_popup_ads_title); ?>' /><br />534 <span style="font-size:12px;color:#22aa5d"> insert your ads title.</span>766 <input placeholder="http://example.com" size='45' name='tp_ads_popup_ads_button_link' class='kento-ads-btn-link' type='text' id="kento-ads-btn-link" value='<?php echo esc_url($tp_ads_popup_ads_button_link); ?>' /><br /> 767 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Insert Link', 'scroll-popup' ); ?></span> 535 768 </td> 536 769 </tr> 537 770 538 771 <tr valign="top"> 539 <th scope="row">Ads Image URL: 540 </th> 772 <th scope="row"> 773 <label for="tp_ads_popup_adds_open_page"> 774 <?php echo esc_html__( 'Open Ads In', 'scroll-popup' ); ?> 775 </label> 776 </th> 541 777 <td style="vertical-align:middle;"> 542 <input type="text" name="tp_ads_popup_screen_bg_img" size="45" id="kento-scroll-screen-bg-img" value="<?php if ( isset( $tp_ads_popup_screen_bg_img ) ) echo $tp_ads_popup_screen_bg_img; ?>" /><br /> 543 <div id="kento-popup-screen-bg-img-preview"> 544 <?php 545 if(!empty($tp_ads_popup_screen_bg_img)) 546 { 547 ?> 548 <img src="" /> 549 <?php 550 } 551 ?> 552 </div> 778 <select name="tp_ads_popup_adds_open_page"> 779 <option value="_self" <?php if($tp_ads_popup_adds_open_page=='_self') echo "selected"; ?> ><?php echo esc_html__( 'Self Page', 'scroll-popup' ); ?></option> 780 <option value="_blank" <?php if($tp_ads_popup_adds_open_page=='_blank') echo "selected"; ?> ><?php echo esc_html__( 'New Page', 'scroll-popup' ); ?></option> 781 </select><br> 782 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Open your ads in self or new page', 'scroll-popup' ); ?></span> 553 783 </td> 554 </tr> 555 556 <script> 557 jQuery(document).ready(function(jQuery) 558 { 559 var tp_ads_popup_screen_bg_img = jQuery('#kento-scroll-screen-bg-img').val(); 560 jQuery('#kento-popup-screen-bg-img-preview img').attr("src",tp_ads_popup_screen_bg_img); 561 }); 562 </script> 784 </tr> 563 785 564 786 <tr valign="top"> 565 <th scope="row"><label for="tp_ads_popup_adds_desc">Ads Description</label></th> 787 <th scope="row"> 788 <label for="kento_popup_ads_button_color"> 789 <?php echo esc_html__( 'Button Background Color', 'scroll-popup' ); ?> 790 </label> 791 </th> 566 792 <td style="vertical-align:middle;"> 567 <textarea class="kento-popup-desc" name="tp_ads_popup_adds_desc" type="text" id="kento-popup-desc" cols="43" rows="5"><?php echo esc_textarea($tp_ads_popup_adds_desc); ?></textarea> 793 <input size='10' name='kento_popup_ads_button_color' class='kento_popup_ads_button_color' type='text' id="your-color-field2" value='<?php echo esc_attr($kento_popup_ads_button_color); ?>' /><br /> 794 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Choose button background color.', 'scroll-popup' ); ?></span> 568 795 </td> 569 796 </tr> 570 797 571 798 <tr valign="top"> 572 <th scope="row"><label for="tp_ads_popup_ads_bg_color">Ads Background Color</label></th> 799 <th scope="row"> 800 <label for="kento_popup_ads_texts_color"> 801 <?php echo esc_html__( 'Button Text Color', 'scroll-popup' ); ?> 802 </label> 803 </th> 573 804 <td style="vertical-align:middle;"> 574 <input size='10' name='tp_ads_popup_ads_bg_color' class='tp_ads_popup_ads_bg_color' type='text' id="kento-popup-adsbg-color" value='<?php echo $tp_ads_popup_ads_bg_color; ?>' /><br /> 575 <span style="font-size:12px;color:#22aa5d">select Ads Background color. default color: #18a3d9 .</span> 576 </td> 577 </tr> 578 579 <tr valign="top"> 580 <th scope="row"><label for="tp_ads_popup_adds_sidebar">Display Ads in corner</label></th> 581 <td style="vertical-align:middle;"> 582 <select name="tp_ads_popup_adds_sidebar"> 583 <option value="top" <?php if($tp_ads_popup_adds_sidebar=='top') echo "selected"; ?> >Top</option> 584 <option value="left" <?php if($tp_ads_popup_adds_sidebar=='left') echo "selected"; ?> >Left</option> 585 <option value="right" <?php if($tp_ads_popup_adds_sidebar=='right') echo "selected"; ?> >Right</option> 586 <option value="bottom" <?php if($tp_ads_popup_adds_sidebar=='bottom') echo "selected"; ?> >Bottom</option> 587 </select><br> 588 <span style="font-size:12px;color:#22aa5d">Select Which corner you want to show your ads.</span> 589 </td> 590 </tr> 591 592 <tr valign="top"> 593 <th scope="row"><label for="tp_ads_popup_purchase_btn">Purchase Button Text</label></th> 594 <td style="vertical-align:middle;"> 595 <input placeholder="Purchase Now" size='45' name='tp_ads_popup_purchase_btn' class='kento-ads-btn' type='text' id="kento-ads-btn" value='<?php echo esc_attr($tp_ads_popup_purchase_btn); ?>' /><br /> 596 <span style="font-size:12px;color:#22aa5d">insert your purchase button text. ex: Download Now, Purchase Now.</span> 597 </td> 598 </tr> 599 600 <tr valign="top"> 601 <th scope="row"><label for="tp_ads_popup_ads_button_link">Purchase Button Link</label></th> 602 <td style="vertical-align:middle;"> 603 <input placeholder="http://example.com" size='45' name='tp_ads_popup_ads_button_link' class='kento-ads-btn-link' type='text' id="kento-ads-btn-link" value='<?php echo esc_url($tp_ads_popup_ads_button_link); ?>' /><br /> 604 <span style="font-size:12px;color:#22aa5d">insert your purchase button link here...</span> 605 </td> 606 </tr> 607 608 <tr valign="top"> 609 <th scope="row"><label for="tp_ads_popup_adds_open_page">Open Ads In</label></th> 610 <td style="vertical-align:middle;"> 611 <select name="tp_ads_popup_adds_open_page"> 612 <option value="_self" <?php if($tp_ads_popup_adds_open_page=='_self') echo "selected"; ?> >_self</option> 613 <option value="_blank" <?php if($tp_ads_popup_adds_open_page=='_blank') echo "selected"; ?> >_blank</option> 614 </select><br> 615 <span style="font-size:12px;color:#22aa5d">Select Open your ads in self or new page.</span> 616 </td> 617 </tr> 618 619 <tr valign="top"> 620 <th scope="row"><label for="kento_popup_ads_button_color">Button Background Color</label></th> 621 <td style="vertical-align:middle;"> 622 <input size='10' name='kento_popup_ads_button_color' class='kento_popup_ads_button_color' type='text' id="kento-popup-button-color" value='<?php echo $kento_popup_ads_button_color; ?>' /><br /> 623 <span style="font-size:12px;color:#22aa5d">select Button Background color. default color: #18a3d9 .</span> 624 </td> 625 </tr> 626 627 <tr valign="top"> 628 <th scope="row"><label for="kento_popup_ads_texts_color">Font Color</label></th> 629 <td style="vertical-align:middle;"> 630 <input size='10' name='kento_popup_ads_texts_color' class='kento_popup_ads_texts_color' type='text' id="kento-popup-button-text-color" value='<?php echo $kento_popup_ads_texts_color; ?>' /><br /> 631 <span style="font-size:12px;color:#22aa5d">select Button text color. default color: #18a3d9 .</span> 805 <input size='10' name='kento_popup_ads_texts_color' class='kento_popup_ads_texts_color' type='text' id="your-color-field3" value='<?php echo esc_attr($kento_popup_ads_texts_color); ?>' /><br /> 806 <span style="font-size:12px;color:#22aa5d"><?php echo esc_html__( 'Choose button text color', 'scroll-popup' ); ?></span> 632 807 </td> 633 808 </tr> 634 809 635 810 </table> 636 <p class="submit"> 637 <input class="button button-primary" type="submit" name="Submit" value="<?php _e('Save Changes' ) ?>" /> 638 </p> 811 <?php submit_button( __( 'Save Settings', 'scroll-popup' ) ); ?> 639 812 </form> 640 813 </div> … … 642 815 } 643 816 644 function tp_ads_scroll_popup_theme_func_settings(){ ?>817 function tp_ads_scroll_popup_theme_func_settings(){ ?> 645 818 <div class="wrap"> 646 819 <div id="icon-options-general" class="icon32"><br></div> 647 < ?php echo "<h2>".__('Support')."</h2>";?>820 <h1><?php echo esc_html__( 'Support', 'scroll-popup' ); ?></h1> 648 821 649 822 <div class="map_helps"> 650 <h4 class="title"> Need Help?</h4>651 <div> if you need more help please feel free to join our forum and ask any question<br />652 <a href="http ://themepoints.com/questions-answer/" >Themepoints.com Questions & Answers</a><br /><br />823 <h4 class="title"><?php echo esc_html__( 'Need Help?', 'scroll-popup' ); ?></h4> 824 <div><?php echo esc_html__( 'if you need more help please feel free to join our forum and ask any question', 'scroll-popup' ); ?><br /> 825 <a href="https://www.themepoints.com/contact/" ><?php echo esc_html__( 'Themepoints.com', 'scroll-popup' ); ?></a><br /><br /> 653 826 </div> 654 827 </div> 655 828 656 829 <div class="more_plugins"> 657 <h4 class="title"> You May Also Like?</h4>830 <h4 class="title"><?php echo esc_html__( 'You May Also Like?', 'scroll-popup' ); ?></h4> 658 831 <ul></ul> 659 832 </div>
Note: See TracChangeset
for help on using the changeset viewer.