Version Description
(10 Nov 2020) =
- Added: Rest api to show the headless output #1026
- Added: Article body and Article Section properties to webpage schema #1147
- Added: bookformat and inlanguage properties to Book Schema #1143
- Added: Separate folder (schema-and-structured-data-for-wp) in uploads to store all resized images by this plugin. #807
- Added: A notice box has been added, if logo is not set. #1165
- Added: Compatibility with Meta Tag Manager ( https://wordpress.org/plugins/meta-tag-manager/ )
- Fixed: Warning Error: The text tag script type=application/ld+json contains html comments, which is disallowed #1140
- Fixed: Woocommerce category schema has an issue when reviews collection is present #1182
- Fixed: Excessive number of queries at each page load in admin pages #1227
- Fixed: Issue with the image size when user inserting recipe by using WP recipe maker plugin. #1159
Download this release
Release Info
Developer | magazine3 |
Plugin | Schema & Structured Data for WP & AMP |
Version | 1.9.54 |
Comparing to | |
See all releases |
Code changes from version 1.9.53 to 1.9.54
- admin_section/add-schema/add_new.php +23 -22
- admin_section/ajax-selectbox.php +5 -5
- admin_section/common-function.php +173 -121
- admin_section/fields-generator.php +14 -14
- admin_section/images/polylang.png +0 -0
- admin_section/js/main-script.js +18 -0
- admin_section/js/main-script.min.js +1 -1
- admin_section/newsletter.php +2 -2
- admin_section/plugin-installer/install.php +56 -56
- admin_section/settings.php +293 -225
- admin_section/structure_admin.php +44 -43
- admin_section/tracking/class-saswp-plugin-usage-tracker.php +1 -1
- core/3rd-party/aqua_resizer.php +28 -0
- core/array-list/compatibility-list.php +12 -0
- core/array-list/pro_extensions.php +6 -1
- core/array-list/schema-properties.php +32 -0
- modules/gutenberg/includes/class-gutenberg.php +2 -2
- modules/gutenberg/includes/render.php +33 -33
- modules/rating-box/backend.php +15 -15
- modules/rating-box/frontend.php +4 -4
- modules/reviews/comments.php +1 -1
- modules/reviews/reviews_admin.php +4 -4
- modules/reviews/reviews_collection.php +27 -27
- modules/reviews/reviews_form.php +4 -4
- modules/reviews/reviews_service.php +17 -17
- modules/reviews/reviews_setup.php +137 -118
- modules/reviews/reviews_widget.php +5 -5
- output/compatibility.php +6 -0
- output/function.php +39 -30
- output/markup.php +4 -0
- output/rest-api/api-service.php +35 -0
- output/rest-api/api.php +69 -0
- output/service.php +15 -2
- readme.txt +15 -1
- structured-data-for-wp.php +9 -3
- view/common.php +5 -5
- view/help.php +1 -1
- view/paywall.php +5 -5
- view/post_specific.php +11 -11
- view/schema_type.php +61 -61
admin_section/add-schema/add_new.php
CHANGED
@@ -24,25 +24,26 @@ add_action( 'wp_ajax_saswp_add_new_save_steps_data', 'saswp_add_new_save_steps_d
|
|
24 |
|
25 |
$saswp_add_data_type_config = array(
|
26 |
'installer_dir' => 'admin_section',
|
27 |
-
'plugin_title' =>
|
28 |
'start_steps' => 1,
|
29 |
'total_steps' => 3,
|
30 |
'installerpage' => 'saswp_add_new_data_type',
|
31 |
'dev_mode' => false,
|
32 |
'steps' => array(
|
33 |
1=>array(
|
34 |
-
|
35 |
-
'
|
|
|
36 |
|
37 |
),
|
38 |
2=>array(
|
39 |
-
'title'=>
|
40 |
-
'description'=>
|
41 |
|
42 |
),
|
43 |
3=>array(
|
44 |
-
'title'=>
|
45 |
-
'description'=>
|
46 |
'fields'=>'',
|
47 |
),
|
48 |
|
@@ -137,7 +138,7 @@ $saswp_add_data_type_config = array(
|
|
137 |
ob_start();
|
138 |
saswp_add_new_header(); ?>
|
139 |
<div class="merlin__wrapper">
|
140 |
-
<div class="saswp_install_wizard"><?php esc_html_e('ADD NEW SCHEMA'
|
141 |
<div class="merlin__content merlin__content--<?php echo esc_attr( strtolower( $title ) ); ?>">
|
142 |
<?php
|
143 |
// Content Handlers.
|
@@ -155,7 +156,7 @@ $saswp_add_data_type_config = array(
|
|
155 |
|
156 |
</div>
|
157 |
|
158 |
-
<?php echo sprintf( '<a class="return-to-dashboard" href="%s">%s</a>', esc_url( admin_url( 'edit.php?post_type=saswp' ) ),
|
159 |
|
160 |
</div>
|
161 |
|
@@ -245,10 +246,10 @@ $saswp_add_data_type_config = array(
|
|
245 |
<footer class="merlin__content__footer">
|
246 |
<?php saswp_add_new_skip_button(); ?>
|
247 |
|
248 |
-
<a id="skip" href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
249 |
|
250 |
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
251 |
-
<span class="merlin__button--loading__text"><?php echo
|
252 |
</a>
|
253 |
|
254 |
<?php wp_nonce_field( 'saswp_add_new_nonce' ); ?>
|
@@ -316,10 +317,10 @@ $saswp_add_data_type_config = array(
|
|
316 |
<footer class="merlin__content__footer">
|
317 |
<?php saswp_add_new_skip_button(); ?>
|
318 |
|
319 |
-
<a id="skip" href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
320 |
|
321 |
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
322 |
-
<span class="merlin__button--loading__text"><?php echo
|
323 |
</a>
|
324 |
|
325 |
<?php wp_nonce_field( 'saswp_add_new_nonce' ); ?>
|
@@ -361,10 +362,10 @@ $saswp_add_data_type_config = array(
|
|
361 |
<footer class="merlin__content__footer">
|
362 |
<?php saswp_add_new_skip_button(); ?>
|
363 |
|
364 |
-
<a id="skip" href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
365 |
|
366 |
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
367 |
-
<span class="merlin__button--loading__text"><?php echo
|
368 |
</a>
|
369 |
|
370 |
<?php wp_nonce_field( 'saswp_add_new_nonce' ); ?>
|
@@ -490,7 +491,7 @@ $saswp_add_data_type_config = array(
|
|
490 |
|
491 |
function saswp_add_new_skip_button(){
|
492 |
?>
|
493 |
-
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip"><?php echo
|
494 |
<?php
|
495 |
}
|
496 |
|
@@ -517,7 +518,7 @@ $saswp_add_data_type_config = array(
|
|
517 |
|
518 |
<div class="saswp_branding"></div>
|
519 |
|
520 |
-
<h1><?php echo
|
521 |
|
522 |
</div>
|
523 |
|
@@ -533,7 +534,7 @@ $saswp_add_data_type_config = array(
|
|
533 |
}
|
534 |
?>
|
535 |
|
536 |
-
<a href="<?php echo $lets_go; ?>" class="merlin__button merlin__button--blue merlin__button--fullwidth merlin__button--popin"><?php echo
|
537 |
|
538 |
|
539 |
<ul class="merlin__drawer merlin__drawer--extras">
|
@@ -614,12 +615,12 @@ $saswp_add_data_type_config = array(
|
|
614 |
function saswp_add_new_makesvg( $args = array() ){
|
615 |
// Make sure $args are an array.
|
616 |
if ( empty( $args ) ) {
|
617 |
-
return __( 'Please define default parameters in the form of an array.'
|
618 |
}
|
619 |
|
620 |
// Define an icon.
|
621 |
if ( false === array_key_exists( 'icon', $args ) ) {
|
622 |
-
return __( 'Please define an SVG icon filename.'
|
623 |
}
|
624 |
|
625 |
// Set defaults.
|
@@ -653,12 +654,12 @@ $saswp_add_data_type_config = array(
|
|
653 |
|
654 |
// If there is a title, display it.
|
655 |
if ( $args['title'] ) {
|
656 |
-
$svg .= '<title>' .
|
657 |
}
|
658 |
|
659 |
// If there is a description, display it.
|
660 |
if ( $args['desc'] ) {
|
661 |
-
$svg .= '<desc>' .
|
662 |
}
|
663 |
|
664 |
$svg .= '<use xlink:href="#icon-' . esc_html( $args['icon'] ) . '"></use>';
|
24 |
|
25 |
$saswp_add_data_type_config = array(
|
26 |
'installer_dir' => 'admin_section',
|
27 |
+
'plugin_title' => saswp_t_string( ucfirst( 'Schema & Structured Data for WP' )),
|
28 |
'start_steps' => 1,
|
29 |
'total_steps' => 3,
|
30 |
'installerpage' => 'saswp_add_new_data_type',
|
31 |
'dev_mode' => false,
|
32 |
'steps' => array(
|
33 |
1=>array(
|
34 |
+
|
35 |
+
'title'=>saswp_t_string('Select Schema'),
|
36 |
+
'description'=>saswp_t_string('Where would you like to enable the schema?'),
|
37 |
|
38 |
),
|
39 |
2=>array(
|
40 |
+
'title'=>saswp_t_string('Placement'),
|
41 |
+
'description'=>saswp_t_string('Where would you like this to be displayed?'),
|
42 |
|
43 |
),
|
44 |
3=>array(
|
45 |
+
'title'=>saswp_t_string('Enjoy'),
|
46 |
+
'description'=>saswp_t_string('Navigate to '),
|
47 |
'fields'=>'',
|
48 |
),
|
49 |
|
138 |
ob_start();
|
139 |
saswp_add_new_header(); ?>
|
140 |
<div class="merlin__wrapper">
|
141 |
+
<div class="saswp_install_wizard"><?php esc_html_e('ADD NEW SCHEMA'); ?></div>
|
142 |
<div class="merlin__content merlin__content--<?php echo esc_attr( strtolower( $title ) ); ?>">
|
143 |
<?php
|
144 |
// Content Handlers.
|
156 |
|
157 |
</div>
|
158 |
|
159 |
+
<?php echo sprintf( '<a class="return-to-dashboard" href="%s">%s</a>', esc_url( admin_url( 'edit.php?post_type=saswp' ) ), saswp_t_string( 'Return to dashboard' ) ); ?>
|
160 |
|
161 |
</div>
|
162 |
|
246 |
<footer class="merlin__content__footer">
|
247 |
<?php saswp_add_new_skip_button(); ?>
|
248 |
|
249 |
+
<a id="skip" href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
250 |
|
251 |
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
252 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_add_new_loading_spinner(); ?>
|
253 |
</a>
|
254 |
|
255 |
<?php wp_nonce_field( 'saswp_add_new_nonce' ); ?>
|
317 |
<footer class="merlin__content__footer">
|
318 |
<?php saswp_add_new_skip_button(); ?>
|
319 |
|
320 |
+
<a id="skip" href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
321 |
|
322 |
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
323 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_add_new_loading_spinner(); ?>
|
324 |
</a>
|
325 |
|
326 |
<?php wp_nonce_field( 'saswp_add_new_nonce' ); ?>
|
362 |
<footer class="merlin__content__footer">
|
363 |
<?php saswp_add_new_skip_button(); ?>
|
364 |
|
365 |
+
<a id="skip" href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
366 |
|
367 |
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
368 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_add_new_loading_spinner(); ?>
|
369 |
</a>
|
370 |
|
371 |
<?php wp_nonce_field( 'saswp_add_new_nonce' ); ?>
|
491 |
|
492 |
function saswp_add_new_skip_button(){
|
493 |
?>
|
494 |
+
<a href="<?php echo esc_url( saswp_add_new_step_next_link() ); ?>" class="merlin__button merlin__button--skip"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
495 |
<?php
|
496 |
}
|
497 |
|
518 |
|
519 |
<div class="saswp_branding"></div>
|
520 |
|
521 |
+
<h1><?php echo saswp_t_string( 'Schema Added Successfully. Have fun!' ); ?></h1>
|
522 |
|
523 |
</div>
|
524 |
|
534 |
}
|
535 |
?>
|
536 |
|
537 |
+
<a href="<?php echo $lets_go; ?>" class="merlin__button merlin__button--blue merlin__button--fullwidth merlin__button--popin"><?php echo saswp_t_string( 'Let\'s Go' ); ?></a>
|
538 |
|
539 |
|
540 |
<ul class="merlin__drawer merlin__drawer--extras">
|
615 |
function saswp_add_new_makesvg( $args = array() ){
|
616 |
// Make sure $args are an array.
|
617 |
if ( empty( $args ) ) {
|
618 |
+
return __( 'Please define default parameters in the form of an array.' );
|
619 |
}
|
620 |
|
621 |
// Define an icon.
|
622 |
if ( false === array_key_exists( 'icon', $args ) ) {
|
623 |
+
return __( 'Please define an SVG icon filename.' );
|
624 |
}
|
625 |
|
626 |
// Set defaults.
|
654 |
|
655 |
// If there is a title, display it.
|
656 |
if ( $args['title'] ) {
|
657 |
+
$svg .= '<title>' . saswp_t_string( $args['title'] ) . '</title>';
|
658 |
}
|
659 |
|
660 |
// If there is a description, display it.
|
661 |
if ( $args['desc'] ) {
|
662 |
+
$svg .= '<desc>' . saswp_t_string( $args['desc'] ) . '</desc>';
|
663 |
}
|
664 |
|
665 |
$svg .= '<use xlink:href="#icon-' . esc_html( $args['icon'] ) . '"></use>';
|
admin_section/ajax-selectbox.php
CHANGED
@@ -64,12 +64,12 @@ function saswp_ajax_select_creator($data = '', $saved_data= '', $current_number
|
|
64 |
$output = '<select data-type="'.esc_attr($response).'" class="widefat ajax-output saswp-select2" name="data_group_array[group-'.esc_attr($current_group_number).'][data_array]['. esc_attr($current_number) .'][key_3]">';
|
65 |
|
66 |
foreach ($choices as $value) {
|
67 |
-
$output .= '<option value="' . esc_attr($value['id']) .'"> ' .
|
68 |
}
|
69 |
|
70 |
if($saved_choices){
|
71 |
foreach($saved_choices as $value){
|
72 |
-
$output .= '<option value="' . esc_attr($value['id']) .'" selected> ' .
|
73 |
}
|
74 |
}
|
75 |
|
@@ -174,17 +174,17 @@ function saswp_create_ajax_select_taxonomy($selectedParentValue = '',$selectedVa
|
|
174 |
$saved_choices = saswp_get_condition_list($selectedParentValue, '', $selectedValue);
|
175 |
}
|
176 |
|
177 |
-
$choices = '<option value="all">'.
|
178 |
|
179 |
if(!empty($taxonomies)){
|
180 |
|
181 |
foreach($taxonomies as $taxonomy) {
|
182 |
-
$choices .= '<option value="'.esc_attr($taxonomy['id']).'">'.
|
183 |
}
|
184 |
|
185 |
if($saved_choices){
|
186 |
foreach($saved_choices as $value){
|
187 |
-
$choices .= '<option value="' . esc_attr($value['id']) .'" selected> ' .
|
188 |
}
|
189 |
}
|
190 |
|
64 |
$output = '<select data-type="'.esc_attr($response).'" class="widefat ajax-output saswp-select2" name="data_group_array[group-'.esc_attr($current_group_number).'][data_array]['. esc_attr($current_number) .'][key_3]">';
|
65 |
|
66 |
foreach ($choices as $value) {
|
67 |
+
$output .= '<option value="' . esc_attr($value['id']) .'"> ' . saswp_t_string($value['text']) .'</option>';
|
68 |
}
|
69 |
|
70 |
if($saved_choices){
|
71 |
foreach($saved_choices as $value){
|
72 |
+
$output .= '<option value="' . esc_attr($value['id']) .'" selected> ' . saswp_t_string($value['text']) .'</option>';
|
73 |
}
|
74 |
}
|
75 |
|
174 |
$saved_choices = saswp_get_condition_list($selectedParentValue, '', $selectedValue);
|
175 |
}
|
176 |
|
177 |
+
$choices = '<option value="all">'.saswp_t_string('All').'</option>';
|
178 |
|
179 |
if(!empty($taxonomies)){
|
180 |
|
181 |
foreach($taxonomies as $taxonomy) {
|
182 |
+
$choices .= '<option value="'.esc_attr($taxonomy['id']).'">'.saswp_t_string($taxonomy['text']).'</option>';
|
183 |
}
|
184 |
|
185 |
if($saved_choices){
|
186 |
foreach($saved_choices as $value){
|
187 |
+
$choices .= '<option value="' . esc_attr($value['id']) .'" selected> ' . saswp_t_string($value['text']) .'</option>';
|
188 |
}
|
189 |
}
|
190 |
|
admin_section/common-function.php
CHANGED
@@ -2131,6 +2131,30 @@ if ( ! defined('ABSPATH') ) exit;
|
|
2131 |
}
|
2132 |
|
2133 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2134 |
|
2135 |
}
|
2136 |
|
@@ -2265,7 +2289,7 @@ if ( ! defined('ABSPATH') ) exit;
|
|
2265 |
if(saswp_remove_warnings($sd_data, 'saswp-slimseo', 'saswp_string') == 1){
|
2266 |
|
2267 |
|
2268 |
-
$slim_seo = get_post_meta(
|
2269 |
|
2270 |
if(isset($slim_seo['title']) && $slim_seo['title'] != ''){
|
2271 |
$title = $slim_seo['title'];
|
@@ -2646,7 +2670,7 @@ function saswp_get_taxonomy_term_list(){
|
|
2646 |
return;
|
2647 |
}
|
2648 |
|
2649 |
-
$choices = array('all' =>
|
2650 |
$taxonomies = saswp_post_taxonomy_generator();
|
2651 |
$choices = array_merge($choices, $taxonomies);
|
2652 |
echo wp_json_encode($choices);
|
@@ -2803,15 +2827,15 @@ function saswp_admin_notice(){
|
|
2803 |
|
2804 |
$setup_notice = '<div class="updated notice message notice notice-alt saswp-setup-notice">'
|
2805 |
. '<p>'
|
2806 |
-
. '<strong>'.
|
2807 |
-
.' - '.
|
2808 |
. '</p>'
|
2809 |
. '<p>'
|
2810 |
. '<a class="button button-primary" href="'.esc_url(admin_url( 'plugins.php?page=saswp-setup-wizard' ).'&_saswp_nonce='.$nonce).'">'
|
2811 |
-
.
|
2812 |
. '</a> '
|
2813 |
.'<a class="button saswp-skip-button">'
|
2814 |
-
.
|
2815 |
. '</a>'
|
2816 |
. '</p>'
|
2817 |
. '</div>';
|
@@ -2836,24 +2860,38 @@ function saswp_admin_notice(){
|
|
2836 |
?>
|
2837 |
<div class="updated notice message notice notice-alt saswp-feedback-notice">
|
2838 |
<p><span class="dashicons dashicons-thumbs-up"></span>
|
2839 |
-
<?php echo
|
2840 |
-
<a class="saswp-revws-lnk" target="_blank" href="https://wordpress.org/plugins/schema-and-structured-data-for-wp/#reviews"> <?php echo
|
2841 |
</p>
|
2842 |
<div class="saswp-update-notice-btns">
|
2843 |
-
<a class="saswp-feedback-remindme"><?php echo
|
2844 |
-
<a class="saswp-feedback-no-thanks"><?php echo
|
2845 |
</div>
|
2846 |
</div>
|
2847 |
<?php
|
2848 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2849 |
|
|
|
|
|
2850 |
if(isset($sd_data['sd_default_image']['url']) && $sd_data['sd_default_image']['url'] == '' && ($screen_id =='saswp_page_structured_data_options' ||$screen_id == 'plugins' || $screen_id =='edit-saswp' || $screen_id == 'saswp')){
|
2851 |
|
2852 |
?>
|
2853 |
<div class="updated notice is-dismissible message notice notice-alt saswp-feedback-notice">
|
2854 |
<p>
|
2855 |
-
<span><?php echo
|
2856 |
-
 <a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options&tab=general#saswp-default-container' ) ); ?>"> <?php echo
|
2857 |
</p>
|
2858 |
</div>
|
2859 |
|
@@ -2866,7 +2904,7 @@ function saswp_admin_notice(){
|
|
2866 |
?>
|
2867 |
<div class="updated notice is-dismissible message">
|
2868 |
<p>
|
2869 |
-
<span><?php echo
|
2870 |
</p>
|
2871 |
</div>
|
2872 |
|
@@ -2882,9 +2920,9 @@ function saswp_admin_notice(){
|
|
2882 |
?>
|
2883 |
<div class="updated notice message notice notice-alt saswp-feedback-notice">
|
2884 |
<p>
|
2885 |
-
<?php echo
|
2886 |
-
 <a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options&tab=amp' ) ); ?>"> <?php echo
|
2887 |
-
<a notice-type="amp_enable" class="saswp-revws-lnk saswp-dismiss-notices"> <?php echo
|
2888 |
</p>
|
2889 |
</div>
|
2890 |
<?php
|
@@ -2941,110 +2979,112 @@ function saswp_remove_anonymous_object_filter_or_action( $tag, $class, $method,
|
|
2941 |
function saswp_get_field_note($pname){
|
2942 |
|
2943 |
$notes = array(
|
2944 |
-
'
|
2945 |
-
'
|
2946 |
-
'
|
2947 |
-
'
|
2948 |
-
'
|
2949 |
-
'
|
2950 |
-
'
|
2951 |
-
'
|
2952 |
-
'
|
2953 |
-
'
|
2954 |
-
'
|
2955 |
-
'
|
2956 |
-
'
|
2957 |
-
'
|
2958 |
-
'
|
2959 |
-
'
|
2960 |
-
'
|
2961 |
-
'
|
2962 |
-
'
|
2963 |
-
'
|
2964 |
-
'
|
2965 |
-
'
|
2966 |
-
'
|
2967 |
-
'
|
2968 |
-
'
|
2969 |
-
'
|
2970 |
-
'
|
2971 |
-
'
|
2972 |
-
'
|
2973 |
-
'
|
2974 |
-
'
|
2975 |
-
'
|
2976 |
-
'
|
2977 |
-
'
|
2978 |
-
'
|
2979 |
-
'
|
2980 |
-
'
|
2981 |
-
'
|
2982 |
-
'
|
2983 |
-
'
|
2984 |
-
'
|
2985 |
-
'
|
2986 |
-
'
|
2987 |
-
'
|
2988 |
-
'
|
2989 |
-
'
|
2990 |
-
'
|
2991 |
-
'
|
2992 |
-
'
|
2993 |
-
'
|
2994 |
-
'
|
2995 |
-
'
|
2996 |
-
'
|
2997 |
-
'
|
2998 |
-
'
|
2999 |
-
'
|
3000 |
-
'
|
3001 |
-
'
|
3002 |
-
'
|
3003 |
-
'
|
3004 |
-
'
|
3005 |
-
'
|
3006 |
-
'
|
3007 |
-
'
|
3008 |
-
'
|
3009 |
-
'
|
3010 |
-
'
|
3011 |
-
'
|
3012 |
-
'
|
3013 |
-
'
|
3014 |
-
'
|
3015 |
-
'
|
3016 |
-
'
|
3017 |
-
'
|
3018 |
-
'
|
3019 |
-
'
|
3020 |
-
'
|
3021 |
-
'
|
3022 |
-
'
|
3023 |
-
'
|
3024 |
-
'
|
3025 |
-
'
|
3026 |
-
'
|
3027 |
-
'
|
3028 |
-
'
|
3029 |
-
'
|
3030 |
-
'
|
3031 |
-
'
|
3032 |
-
'
|
3033 |
-
'
|
3034 |
-
'
|
3035 |
-
'
|
3036 |
-
'
|
3037 |
-
'
|
3038 |
-
'
|
3039 |
-
'
|
3040 |
-
'
|
3041 |
-
'
|
3042 |
-
'
|
3043 |
-
'
|
3044 |
-
'
|
3045 |
-
'
|
3046 |
-
'
|
3047 |
-
'
|
|
|
|
|
3048 |
|
3049 |
);
|
3050 |
|
@@ -3707,7 +3747,7 @@ function saswp_get_condition_list($condition, $search = '', $saved_data = ''){
|
|
3707 |
|
3708 |
if( is_multisite() ){
|
3709 |
|
3710 |
-
$choices['super_admin'] =
|
3711 |
|
3712 |
}
|
3713 |
|
@@ -3933,4 +3973,16 @@ function saswp_explode_comma_seprated ($data, $type) {
|
|
3933 |
}
|
3934 |
|
3935 |
return $response;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3936 |
}
|
2131 |
}
|
2132 |
|
2133 |
}
|
2134 |
+
|
2135 |
+
if( isset($sd_data['saswp-metatagmanager']) && $sd_data['saswp-metatagmanager'] == 1 && class_exists('Meta_Tag_Manager') ){
|
2136 |
+
|
2137 |
+
$post_meta = get_post_meta($post->ID, 'mtm_data', true);
|
2138 |
+
|
2139 |
+
if(is_array($post_meta)){
|
2140 |
+
|
2141 |
+
$meta_tag = array_column($post_meta, 'value');
|
2142 |
+
|
2143 |
+
$key = array_search("description",$meta_tag);
|
2144 |
+
|
2145 |
+
if(array_key_exists($key, $post_meta)){
|
2146 |
+
|
2147 |
+
$c_excerpt = $post_meta[$key]['content'];
|
2148 |
+
|
2149 |
+
if($c_excerpt){
|
2150 |
+
$excerpt = $c_excerpt;
|
2151 |
+
}
|
2152 |
+
|
2153 |
+
}
|
2154 |
+
|
2155 |
+
}
|
2156 |
+
|
2157 |
+
}
|
2158 |
|
2159 |
}
|
2160 |
|
2289 |
if(saswp_remove_warnings($sd_data, 'saswp-slimseo', 'saswp_string') == 1){
|
2290 |
|
2291 |
|
2292 |
+
$slim_seo = get_post_meta( get_the_ID(), 'slim_seo', true );
|
2293 |
|
2294 |
if(isset($slim_seo['title']) && $slim_seo['title'] != ''){
|
2295 |
$title = $slim_seo['title'];
|
2670 |
return;
|
2671 |
}
|
2672 |
|
2673 |
+
$choices = array('all' => saswp_t_string('All'));
|
2674 |
$taxonomies = saswp_post_taxonomy_generator();
|
2675 |
$choices = array_merge($choices, $taxonomies);
|
2676 |
echo wp_json_encode($choices);
|
2827 |
|
2828 |
$setup_notice = '<div class="updated notice message notice notice-alt saswp-setup-notice">'
|
2829 |
. '<p>'
|
2830 |
+
. '<strong>'.saswp_t_string('Welcome to Schema & Structured Data For WP').'</strong>'
|
2831 |
+
.' - '.saswp_t_string('You are almost ready :)')
|
2832 |
. '</p>'
|
2833 |
. '<p>'
|
2834 |
. '<a class="button button-primary" href="'.esc_url(admin_url( 'plugins.php?page=saswp-setup-wizard' ).'&_saswp_nonce='.$nonce).'">'
|
2835 |
+
. saswp_t_string('Run the Setup Wizard')
|
2836 |
. '</a> '
|
2837 |
.'<a class="button saswp-skip-button">'
|
2838 |
+
. saswp_t_string('Skip Setup')
|
2839 |
. '</a>'
|
2840 |
. '</p>'
|
2841 |
. '</div>';
|
2860 |
?>
|
2861 |
<div class="updated notice message notice notice-alt saswp-feedback-notice">
|
2862 |
<p><span class="dashicons dashicons-thumbs-up"></span>
|
2863 |
+
<?php echo saswp_t_string('You have been using the Schema & Structured Data for WP & AMP for some time. Now, Do you like it? If Yes.') ?>
|
2864 |
+
<a class="saswp-revws-lnk" target="_blank" href="https://wordpress.org/plugins/schema-and-structured-data-for-wp/#reviews"> <?php echo saswp_t_string('Rate Plugin') ?></a>
|
2865 |
</p>
|
2866 |
<div class="saswp-update-notice-btns">
|
2867 |
+
<a class="saswp-feedback-remindme"><?php echo saswp_t_string('Remind Me Later') ?></a>
|
2868 |
+
<a class="saswp-feedback-no-thanks"><?php echo saswp_t_string('No Thanks') ?></a>
|
2869 |
</div>
|
2870 |
</div>
|
2871 |
<?php
|
2872 |
}
|
2873 |
+
|
2874 |
+
if(isset($sd_data['sd_logo']['url']) && $sd_data['sd_logo']['url'] == '' && ($screen_id =='saswp_page_structured_data_options' ||$screen_id == 'plugins' || $screen_id =='edit-saswp' || $screen_id == 'saswp')){
|
2875 |
+
|
2876 |
+
?>
|
2877 |
+
<div class="updated notice is-dismissible message notice notice-alt saswp-feedback-notice">
|
2878 |
+
<p>
|
2879 |
+
<span><?php echo saswp_t_string('Please setup Logo to avoid structured data validation issue.') ?> </span>
|
2880 |
+
 <a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options&tab=general#saswp-knowledge-container' ) ); ?>"> <?php echo saswp_t_string('Please Setup') ?></a>
|
2881 |
+
</p>
|
2882 |
+
</div>
|
2883 |
+
|
2884 |
+
<?php
|
2885 |
|
2886 |
+
}
|
2887 |
+
|
2888 |
if(isset($sd_data['sd_default_image']['url']) && $sd_data['sd_default_image']['url'] == '' && ($screen_id =='saswp_page_structured_data_options' ||$screen_id == 'plugins' || $screen_id =='edit-saswp' || $screen_id == 'saswp')){
|
2889 |
|
2890 |
?>
|
2891 |
<div class="updated notice is-dismissible message notice notice-alt saswp-feedback-notice">
|
2892 |
<p>
|
2893 |
+
<span><?php echo saswp_t_string('You have not set up default image in Schema & Structured Data For WP.') ?> </span>
|
2894 |
+
 <a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options&tab=general#saswp-default-container' ) ); ?>"> <?php echo saswp_t_string('Please Setup') ?></a>
|
2895 |
</p>
|
2896 |
</div>
|
2897 |
|
2904 |
?>
|
2905 |
<div class="updated notice is-dismissible message">
|
2906 |
<p>
|
2907 |
+
<span><?php echo saswp_t_string('You use Stars Rating plugin and has enabled Stars Rating option in Schema & Structured Data For WP & AMP. Use any one option for better comment form.') ?> </span>
|
2908 |
</p>
|
2909 |
</div>
|
2910 |
|
2920 |
?>
|
2921 |
<div class="updated notice message notice notice-alt saswp-feedback-notice">
|
2922 |
<p>
|
2923 |
+
<?php echo saswp_t_string('You have disabled schema on AMP.') ?>
|
2924 |
+
 <a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options&tab=amp' ) ); ?>"> <?php echo saswp_t_string('Enable it') ?></a>
|
2925 |
+
<a notice-type="amp_enable" class="saswp-revws-lnk saswp-dismiss-notices"> <?php echo saswp_t_string('Dismiss') ?></a>
|
2926 |
</p>
|
2927 |
</div>
|
2928 |
<?php
|
2979 |
function saswp_get_field_note($pname){
|
2980 |
|
2981 |
$notes = array(
|
2982 |
+
'polylang' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/polylang/">Polylang</a>',
|
2983 |
+
'wpdiscuz' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wpdiscuz/">Comments – wpDiscuz</a>',
|
2984 |
+
'rannarecipe' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/ranna-food-recipe-wordpress-theme/25157340">Ranna - Food & Recipe</a>',
|
2985 |
+
'easy_recipe' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/easyrecipe/">EasyRecipe</a>',
|
2986 |
+
'total_recipe_generator' => saswp_t_string('Requires').' <a target="_blank" href="https://codecanyon.net/item/total-recipe-generator-wordpress-recipe-maker-with-schema-and-nutrition-facts-elementor-addon/21445400/">Total Recipe Generator</a>',
|
2987 |
+
'yet_another_stars_rating' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/yet-another-stars-rating/">Yet Another Stars Rating</a>',
|
2988 |
+
'wp_customer_reviews' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-customer-reviews">WP Customer Reviews</a>',
|
2989 |
+
'wordpress_news' => saswp_t_string('Requires').' <a target="_blank" href="#">Wordpress News</a>',
|
2990 |
+
'strong_testimonials' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/strong-testimonials">Strong Testimonials</a>',
|
2991 |
+
'wp_event_aggregator' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-event-aggregator/">WP Event Aggregator</a>',
|
2992 |
+
'stachethemes_event_calendar' => saswp_t_string('Requires').' <a target="_blank" href="http://stachethemes.com/">Stachethemes Event Calendar</a>',
|
2993 |
+
'timetable_event' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/mp-timetable">Timetable and Event Schedule by MotoPress</a>',
|
2994 |
+
'all_in_one_event_calendar' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/all-in-one-event-calendar/">All In One Event Calendar</a>',
|
2995 |
+
'xo_event_calendar' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/xo-event-calendar/">XO Event Calendar</a>',
|
2996 |
+
'calendarize_it' => saswp_t_string('Requires').' <a target="_blank" href="https://codecanyon.net/item/calendarize-it-for-wordpress/2568439">Calendarize it! for WordPress</a>',
|
2997 |
+
'events_schedule' => saswp_t_string('Requires').' <a target="_blank" href="https://codecanyon.net/item/events-schedule-wordpress-plugin/14907462">Events Schedule - WordPress Events Calendar Plugin</a>',
|
2998 |
+
'woo_event_manager' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/mage-eventpress/">WooCommerce Event Manager</a>',
|
2999 |
+
'vs_event_list' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/very-simple-event-list/">Very Simple Event List</a>',
|
3000 |
+
'event_on' => saswp_t_string('Event On').' <a target="_blank" href="https://www.myeventon.com/">Event On</a>',
|
3001 |
+
'wordlift' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wordlift/">WordLift</a>',
|
3002 |
+
'ampforwp' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/accelerated-mobile-pages/">AMP for WP</a>',
|
3003 |
+
'quickandeasyfaq' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/quick-and-easy-faqs/">Quick and Easy FAQs</a>',
|
3004 |
+
'accordionfaq' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/responsive-accordion-and-collapse">Accordion FAQ</a>',
|
3005 |
+
'webfaq10' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/faq-wd/">10WebFAQ</a>',
|
3006 |
+
'ultimatefaqs' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/ultimate-faqs/">Ultimate FAQs</a>',
|
3007 |
+
'easyaccordion' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/easy-accordion-free/">Easy Accordion</a>',
|
3008 |
+
'wpresponsivefaq' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/sp-faq">WP responsive FAQ with category plugin</a>',
|
3009 |
+
'arconixfaq' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/arconix-faq/">Arconix FAQ</a>',
|
3010 |
+
'faqconcertina' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/faq-concertina/">FAQ Concertina</a>',
|
3011 |
+
'masteraccordion' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-awesome-faq/">Master Accordion</a>',
|
3012 |
+
'wpfaqschemamarkup' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-faq-schema-markup-for-seo/">WP FAQ Schema Markup for SEO</a>',
|
3013 |
+
'faqschemaforpost' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/faq-schema-for-pages-and-posts/">FAQ Schema For Pages And Posts</a>',
|
3014 |
+
'accordion' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/accordions">Accordion By PickPlugins</a>',
|
3015 |
+
'easyfaqs' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/easy-faqs/">Easy FAQs</a>',
|
3016 |
+
'html5responsivefaq' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/html5-responsive-faq/">HTML5 Responsive FAQ</a>',
|
3017 |
+
'helpiefaq' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/helpie-faq/">Helpie FAQ – WordPress FAQ Accordion Plugin</a>',
|
3018 |
+
'ampbyautomatic' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/amp/">AMP</a>',
|
3019 |
+
'simplejobboard' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/simple-job-board/">Simple Job Board</a>',
|
3020 |
+
'wpjobmanager' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-job-manager/">WP Job Manager</a>',
|
3021 |
+
'wpjobopenings' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-job-openings/">WP Job Openings</a>',
|
3022 |
+
'schemaforfaqs' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/faq-schema-markup-faq-structured-data/">FAQ Schema Markup</a>',
|
3023 |
+
'betteramp' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/kk-star-ratings/">Better AMP</a>',
|
3024 |
+
'wpamp' => saswp_t_string('Requires').' <a target="_blank" href="https://codecanyon.net/item/wp-amp-accelerated-mobile-pages-for-wordpress-and-woocommerce/16278608">WP AMP</a>',
|
3025 |
+
'ampwp' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/amp-wp/">AMP WP</a>',
|
3026 |
+
'kk_star_ratings' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/kk-star-ratings/">kk Star Rating</a>',
|
3027 |
+
'simple_author_box' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/simple-author-box//">Simple Author Box</a>',
|
3028 |
+
'wp_post_ratings' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-postratings/">WP-PostRatings</a>',
|
3029 |
+
'bb_press' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/bbpress/">bbPress</a>',
|
3030 |
+
'woocommerce' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/woocommerce/">Woocommerce</a>',
|
3031 |
+
'cooked' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/cooked/">Cooked</a>',
|
3032 |
+
'the_events_calendar' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/the-events-calendar/">The Events Calendar</a>',
|
3033 |
+
'yoast_seo' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wordpress-seo/">Yoast SEO</a>',
|
3034 |
+
'metatagmanager' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/meta-tag-manager/">Meta Tag Manager</a>',
|
3035 |
+
'slimseo' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/slim-seo/">Slim SEO</a>',
|
3036 |
+
'rank_math' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/seo-by-rank-math/">WordPress SEO Plugin – Rank Math</a>',
|
3037 |
+
'dw_qna' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/dw-question-answer/">DW Question Answer</a>',
|
3038 |
+
'sabaidiscuss' => saswp_t_string('Requires').' <a target="_blank" href="https://sabaidiscuss.com">SabaiDiscuss</a>',
|
3039 |
+
'smart_crawl' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/smartcrawl-seo/">SmartCrawl Seo</a>',
|
3040 |
+
'the_seo_framework' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/autodescription/">The Seo Framework</a>',
|
3041 |
+
'seo_press' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-seopress/">SEOPress</a>',
|
3042 |
+
'aiosp' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/all-in-one-seo-pack/">All in One SEO Pack</a>',
|
3043 |
+
'squirrly_seo' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/squirrly-seo/">Squirrly SEO</a>',
|
3044 |
+
'wp_recipe_maker' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-recipe-maker/">WP Recipe Maker</a>',
|
3045 |
+
'wpzoom' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/recipe-card-blocks-by-wpzoom">Recipe Card Blocks by WPZOOM</a>',
|
3046 |
+
'video_thumbnails' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/video-thumbnails/">Video Thumbnails</a>',
|
3047 |
+
'featured_video_plus' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/featured-video-plus/">Featured Video Plus</a>',
|
3048 |
+
'yotpo' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/yotpo-social-reviews-for-woocommerce/">Yotpo: Product & Photo Reviews for WooCommerce</a>',
|
3049 |
+
'starsrating' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/stars-rating">Stars Rating</a>',
|
3050 |
+
'ultimate_blocks' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/ultimate-blocks">Ultimate Blocks – Gutenberg Blocks Plugin</a>',
|
3051 |
+
'wptastyrecipe' => saswp_t_string('Requires').' <a target="_blank" href="https://www.wptasty.com">WP Tasty Recipe</a>',
|
3052 |
+
'recipress' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/recipress">ReciPress</a>',
|
3053 |
+
'wp_ultimate_recipe' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-ultimate-recipe/">WP Ultimate Recipe</a>',
|
3054 |
+
'learn_press' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/learnpress/">Learn Press</a>',
|
3055 |
+
'learn_dash' => saswp_t_string('Requires').' <a target="_blank" href="https://www.learndash.com/pricing-and-purchase/">Learn Dash</a>',
|
3056 |
+
'lifter_lms' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/lifterlms/">LifterLMS</a>',
|
3057 |
+
'senseilms' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/sensei-lms/">Sensei LMS</a>',
|
3058 |
+
'wplms' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/wplms-learning-management-system/6780226">WPLMS</a>',
|
3059 |
+
'wp_event_manager' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-event-manager/">WP Event Manager</a>',
|
3060 |
+
'events_manager' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/events-manager/">Events Manager</a>',
|
3061 |
+
'event_calendar_wd' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/event-calendar-wd/">Event Calendar WD</a>',
|
3062 |
+
'event_organiser' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/event-organiser/">Event Organiser</a>',
|
3063 |
+
'modern_events_calendar' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/modern-events-calendar-lite/">Modern Events Calendar Lite</a>',
|
3064 |
+
'flex_mls_idx' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/flexmls-idx/">FlexMLS IDX</a>',
|
3065 |
+
'woocommerce_membership' => saswp_t_string('Requires').' <a target="_blank" href="https://woocommerce.com/products/woocommerce-memberships">Woocommerce Membership</a>',
|
3066 |
+
'woocommerce_bookings' => saswp_t_string('Requires').' <a target="_blank" href="https://woocommerce.com/products/woocommerce-bookings">Woocommerce Bookings</a>',
|
3067 |
+
'extra' => saswp_t_string('Requires').' <a target="_blank" href="https://www.elegantthemes.com/gallery/extra/">Extra Theme</a>',
|
3068 |
+
'homeland' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/homeland-responsive-real-estate-theme-for-wordpress/6518965">Homeland</a>',
|
3069 |
+
'ratency' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/ratency-review-magazine-theme/21303977">Ratency - Review & Magazine Theme</a>',
|
3070 |
+
'wpresidence' => saswp_t_string('Requires').' <a target="_blank" href="https://wpresidence.net/">WP Residence</a>',
|
3071 |
+
'reviews' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/reviews-products-and-services-review-wp-theme/13004739?s_rank=4">Reviews - Products And Services Review WP Theme</a>',
|
3072 |
+
'realhomes' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/real-homes-wordpress-real-estate-theme/5373914">RealHomes</a>',
|
3073 |
+
'myhome' => saswp_t_string('Requires').' <a target="_blank" href="https://myhometheme.net/">My Home Theme</a>',
|
3074 |
+
'realestate_5' => saswp_t_string('Requires').' <a target="_blank" href="https://myhometheme.net/">WP Pro Realstate 5</a>',
|
3075 |
+
'geodirectory' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/geodirectory/">GeoDirectory – Business Directory</a>',
|
3076 |
+
'classipress' => saswp_t_string('Requires').' <a target="_blank" href="https://www.appthemes.com/themes/classipress/">ClassiPress</a>',
|
3077 |
+
'taqyeem' => saswp_t_string('Requires').' <a target="_blank" href="https://codecanyon.net/item/taqyeem-wordpress-review-plugin/4558799">Taqyeem</a>',
|
3078 |
+
'wp_product_review' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/wp-product-review/">WP Product Review</a>',
|
3079 |
+
'stamped' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/stampedio-product-reviews">Stamped.io Product Reviews & UGC for WooCommerce</a>',
|
3080 |
+
'soledad' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/soledad-multiconcept-blogmagazine-wp-theme/12945398">Soledad Theme</a>',
|
3081 |
+
'zip_recipes' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/zip-recipes/">Zip Recipes</a>',
|
3082 |
+
'mediavine_create' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/mediavine-create/">Create by Mediavine</a>',
|
3083 |
+
'ht_recipes' => saswp_t_string('Requires').' <a target="_blank" href="https://themeforest.net/item/culinier-food-recipe-wordpress-theme/11088564/">HT-Recipes</a>',
|
3084 |
+
'easy_testimonials' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/easy-testimonials">Easy Testimonials</a>',
|
3085 |
+
'bne_testimonials' => saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/bne-testimonials/">BNE Testimonials</a>',
|
3086 |
+
'testimonial_pro' => saswp_t_string('Requires').' <a target="_blank" href="https://shapedplugin.com/plugin/testimonial-pro/">Testimonial Pro</a>',
|
3087 |
+
'tevolution_events' => saswp_t_string('Requires').' <a target="_blank" href="https://templatic.com/wordpress-plugins/tevolution/">Tevolution Events</a>'
|
3088 |
|
3089 |
);
|
3090 |
|
3747 |
|
3748 |
if( is_multisite() ){
|
3749 |
|
3750 |
+
$choices['super_admin'] = saswp_t_string('Super Admin');
|
3751 |
|
3752 |
}
|
3753 |
|
3973 |
}
|
3974 |
|
3975 |
return $response;
|
3976 |
+
}
|
3977 |
+
|
3978 |
+
function saswp_t_string($string){
|
3979 |
+
|
3980 |
+
$settings = saswp_defaultSettings();
|
3981 |
+
|
3982 |
+
if(function_exists('pll__') && (isset($settings['saswp-polylang']) && $settings['saswp-polylang'] == 1) ){
|
3983 |
+
return pll__($string);
|
3984 |
+
}else{
|
3985 |
+
return esc_html__( $string , 'schema-and-structured-data-for-wp');
|
3986 |
+
}
|
3987 |
+
|
3988 |
}
|
admin_section/fields-generator.php
CHANGED
@@ -104,11 +104,11 @@ class saswp_fields_generator {
|
|
104 |
}
|
105 |
if($tooltip_message){
|
106 |
|
107 |
-
$label = '<label class="saswp-tooltip" for="' . esc_attr($meta_field['id']) . '">' .
|
108 |
|
109 |
}else{
|
110 |
|
111 |
-
$label = '<label class="saswp-tooltip" for="' . esc_attr($meta_field['id']) . '">' .
|
112 |
|
113 |
}
|
114 |
|
@@ -216,7 +216,7 @@ class saswp_fields_generator {
|
|
216 |
'<option %s value="%s">%s</option>',
|
217 |
$settings_meta_field == $key ? 'selected' : '',
|
218 |
$key,
|
219 |
-
|
220 |
);
|
221 |
}
|
222 |
$input .= '</select>';
|
@@ -241,7 +241,7 @@ class saswp_fields_generator {
|
|
241 |
'<option %s value="%s">%s (Default)</option>',
|
242 |
'selected',
|
243 |
$key,
|
244 |
-
|
245 |
);
|
246 |
|
247 |
}else{
|
@@ -249,7 +249,7 @@ class saswp_fields_generator {
|
|
249 |
'<option %s value="%s">%s</option>',
|
250 |
in_array($key, $settings_meta_field) ? 'selected' : '',
|
251 |
$key,
|
252 |
-
|
253 |
);
|
254 |
|
255 |
}
|
@@ -532,11 +532,11 @@ class saswp_fields_generator {
|
|
532 |
$blocks_fields = apply_filters('saswp_modify_blocks_field', '<input class="saswp-g-blocks-field" name="sd_data[saswp_reviews_location_blocks][]" type="number" min="5" step="5" placeholder="5" value="5" disabled="disabled">', isset($rv_blocks[$i])? $rv_blocks[$i]: 5);
|
533 |
|
534 |
$location .= '<tr>'
|
535 |
-
. '<td style="width:12%;"><strong>'.
|
536 |
. '<td style="width:20%;"><input class="saswp-g-location-field" name="sd_data[saswp_reviews_location_name][]" type="text" value="'. esc_attr($rvl).'"></td>'
|
537 |
-
. '<td style="width:10%;"><strong>'.
|
538 |
. '<td style="width:10%;">'.$blocks_fields.'</td>'
|
539 |
-
. '<td style="width:10%;"><a class="button button-default saswp-fetch-g-reviews">'.
|
540 |
. '<td style="width:10%;"><a type="button" class="saswp-remove-review-item button">x</a></td>'
|
541 |
. '<td style="width:10%;"><p class="saswp-rv-fetched-msg"></p></td>'
|
542 |
. '</tr>';
|
@@ -551,8 +551,8 @@ class saswp_fields_generator {
|
|
551 |
. $location
|
552 |
. '</table>'
|
553 |
. '<div>'
|
554 |
-
. '<a class="button button-default saswp-add-g-location-btn">'.
|
555 |
-
. '<p><a target="_blank" href="https://developers.google.com/maps/documentation/javascript/examples/places-placeid-finder">'.
|
556 |
. '</div>'
|
557 |
. '</div>';
|
558 |
|
@@ -565,13 +565,13 @@ class saswp_fields_generator {
|
|
565 |
$reviews = '<div class="saswp-s-approved-reviews-settings saswp-knowledge-label">'
|
566 |
. '<table class="saswp-s-reviews-settings-table" style="width:100%">'
|
567 |
. '<tr>'
|
568 |
-
. '<td style="width:12%;"><strong>'.
|
569 |
. '<td style="width:10%;"><input class="saswp-g-location-field" id="saswp_s_approved_site_id" name="sd_data[saswp_s_approved_site_id]" type="text" value="'.$settings['saswp_s_approved_site_id'].'"></td>'
|
570 |
-
. '<td style="width:10%;"><strong>'.
|
571 |
. '<td style="width:20%;"><input class="saswp-g-blocks-field" id="saswp_s_approved_token" name="sd_data[saswp_s_approved_token]" type="text" value="'.$settings['saswp_s_approved_token'].'"></td>'
|
572 |
-
. '<td style="width:5%;"><strong>'.
|
573 |
. '<td style="width:15%;"><input class="saswp-g-blocks-field" id="saswp_s_approved_reviews" name="sd_data[saswp_s_approved_reviews]" type="number" min="1" max="500" value="'.$settings['saswp_s_approved_reviews'].'"></td>'
|
574 |
-
. '<td style="width:10%;"><a class="button button-default saswp-fetch-s-approved-reviews">'.
|
575 |
. '<td style="width:10%;"><p class="saswp-rv-fetched-msg"></p></td>'
|
576 |
. '</tr>'
|
577 |
. '</table>'
|
104 |
}
|
105 |
if($tooltip_message){
|
106 |
|
107 |
+
$label = '<label class="saswp-tooltip" for="' . esc_attr($meta_field['id']) . '">' . saswp_t_string( $meta_field['label'] ).' <span class="saswp-tooltiptext">'.saswp_t_string($tooltip_message).'</span></label>';
|
108 |
|
109 |
}else{
|
110 |
|
111 |
+
$label = '<label class="saswp-tooltip" for="' . esc_attr($meta_field['id']) . '">' . saswp_t_string( $meta_field['label'] ).' <span class="saswp-tooltiptext"></span></label>';
|
112 |
|
113 |
}
|
114 |
|
216 |
'<option %s value="%s">%s</option>',
|
217 |
$settings_meta_field == $key ? 'selected' : '',
|
218 |
$key,
|
219 |
+
saswp_t_string( $value )
|
220 |
);
|
221 |
}
|
222 |
$input .= '</select>';
|
241 |
'<option %s value="%s">%s (Default)</option>',
|
242 |
'selected',
|
243 |
$key,
|
244 |
+
saswp_t_string( $value )
|
245 |
);
|
246 |
|
247 |
}else{
|
249 |
'<option %s value="%s">%s</option>',
|
250 |
in_array($key, $settings_meta_field) ? 'selected' : '',
|
251 |
$key,
|
252 |
+
saswp_t_string( $value )
|
253 |
);
|
254 |
|
255 |
}
|
532 |
$blocks_fields = apply_filters('saswp_modify_blocks_field', '<input class="saswp-g-blocks-field" name="sd_data[saswp_reviews_location_blocks][]" type="number" min="5" step="5" placeholder="5" value="5" disabled="disabled">', isset($rv_blocks[$i])? $rv_blocks[$i]: 5);
|
533 |
|
534 |
$location .= '<tr>'
|
535 |
+
. '<td style="width:12%;"><strong>'.saswp_t_string( 'Place Id' ).'</strong></td>'
|
536 |
. '<td style="width:20%;"><input class="saswp-g-location-field" name="sd_data[saswp_reviews_location_name][]" type="text" value="'. esc_attr($rvl).'"></td>'
|
537 |
+
. '<td style="width:10%;"><strong>'.saswp_t_string( 'Reviews' ).'</strong></td>'
|
538 |
. '<td style="width:10%;">'.$blocks_fields.'</td>'
|
539 |
+
. '<td style="width:10%;"><a class="button button-default saswp-fetch-g-reviews">'.saswp_t_string( 'Fetch' ).'</a></td>'
|
540 |
. '<td style="width:10%;"><a type="button" class="saswp-remove-review-item button">x</a></td>'
|
541 |
. '<td style="width:10%;"><p class="saswp-rv-fetched-msg"></p></td>'
|
542 |
. '</tr>';
|
551 |
. $location
|
552 |
. '</table>'
|
553 |
. '<div>'
|
554 |
+
. '<a class="button button-default saswp-add-g-location-btn">'.saswp_t_string( 'Add Location' ).'</a>'
|
555 |
+
. '<p><a target="_blank" href="https://developers.google.com/maps/documentation/javascript/examples/places-placeid-finder">'.saswp_t_string( 'Place ID Finder' ).'</a></p>'
|
556 |
. '</div>'
|
557 |
. '</div>';
|
558 |
|
565 |
$reviews = '<div class="saswp-s-approved-reviews-settings saswp-knowledge-label">'
|
566 |
. '<table class="saswp-s-reviews-settings-table" style="width:100%">'
|
567 |
. '<tr>'
|
568 |
+
. '<td style="width:12%;"><strong>'.saswp_t_string( 'Site Id' ).'</strong></td>'
|
569 |
. '<td style="width:10%;"><input class="saswp-g-location-field" id="saswp_s_approved_site_id" name="sd_data[saswp_s_approved_site_id]" type="text" value="'.$settings['saswp_s_approved_site_id'].'"></td>'
|
570 |
+
. '<td style="width:10%;"><strong>'.saswp_t_string( 'Token' ).'</strong></td>'
|
571 |
. '<td style="width:20%;"><input class="saswp-g-blocks-field" id="saswp_s_approved_token" name="sd_data[saswp_s_approved_token]" type="text" value="'.$settings['saswp_s_approved_token'].'"></td>'
|
572 |
+
. '<td style="width:5%;"><strong>'.saswp_t_string( 'Reviews' ).'</strong></td>'
|
573 |
. '<td style="width:15%;"><input class="saswp-g-blocks-field" id="saswp_s_approved_reviews" name="sd_data[saswp_s_approved_reviews]" type="number" min="1" max="500" value="'.$settings['saswp_s_approved_reviews'].'"></td>'
|
574 |
+
. '<td style="width:10%;"><a class="button button-default saswp-fetch-s-approved-reviews">'.saswp_t_string( 'Fetch' ).'</a></td>'
|
575 |
. '<td style="width:10%;"><p class="saswp-rv-fetched-msg"></p></td>'
|
576 |
. '</tr>'
|
577 |
. '</table>'
|
admin_section/images/polylang.png
ADDED
Binary file
|
admin_section/js/main-script.js
CHANGED
@@ -1051,6 +1051,24 @@ jQuery(document).ready(function($){
|
|
1051 |
}
|
1052 |
break;
|
1053 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1054 |
case 'saswp-slimseo-checkbox':
|
1055 |
saswp_compatibliy_notes(current, id);
|
1056 |
if ($(this).is(':checked')) {
|
1051 |
}
|
1052 |
break;
|
1053 |
|
1054 |
+
case 'saswp-polylang-checkbox':
|
1055 |
+
saswp_compatibliy_notes(current, id);
|
1056 |
+
if ($(this).is(':checked')) {
|
1057 |
+
$("#saswp-polylang").val(1);
|
1058 |
+
}else{
|
1059 |
+
$("#saswp-polylang").val(0);
|
1060 |
+
}
|
1061 |
+
break;
|
1062 |
+
|
1063 |
+
case 'saswp-metatagmanager-checkbox':
|
1064 |
+
saswp_compatibliy_notes(current, id);
|
1065 |
+
if ($(this).is(':checked')) {
|
1066 |
+
$("#saswp-metatagmanager").val(1);
|
1067 |
+
}else{
|
1068 |
+
$("#saswp-metatagmanager").val(0);
|
1069 |
+
}
|
1070 |
+
break;
|
1071 |
+
|
1072 |
case 'saswp-slimseo-checkbox':
|
1073 |
saswp_compatibliy_notes(current, id);
|
1074 |
if ($(this).is(':checked')) {
|
admin_section/js/main-script.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
var saswp_attached_rv=[],saswp_attached_col=[];jQuery(document).ready(function(s){if(s(document).on("click",".saswp-dismiss-notices",function(){var a=s(this),e=s(this).attr("notice-type");e&&s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_dismiss_notices",notice_type:e,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){"t"==s.status&&a.parent().parent().hide()},error:function(s){console.log(s)}})}),saswp_select2(),s(".saswp-upgrade-to-pro").parent().attr({href:"https://structured-data-for-wp.com/pricing/",target:"_blank"}),s(document).on("click",".saswp-attach-reviews",function(){s(".saswp-enable-append-reviews").is(":checked")?(tb_show(saswp_localize_data.translable_txt.attach_review,"#TB_inline??width=615&height=400&inlineId=saswp-embed-code-div"),s(document).find("#TB_window").width(600).height(415).css({top:"200px","margin-top":"0px"}),s(".saswp-attached-rv-count").show()):s(".saswp-attached-rv-count").hide()}),s(".close-attached-reviews-popup").on("click",function(){s("#TB_closeWindowButton").trigger("click")}),s("#saswp_attahced_reviews").val()&&(saswp_attached_rv=JSON.parse(s("#saswp_attahced_reviews").val())),s("#saswp_attached_collection").val()&&(saswp_attached_col=JSON.parse(s("#saswp_attached_collection").val())),s(document).on("click",".saswp-attach-rv-checkbox",function(){var a;a=parseInt(s(this).parent().attr("data-id"));var e=s(this).parent().attr("data-type");s(this).is(":checked")?("review"==e&&saswp_attached_rv.push(a),"collection"==e&&saswp_attached_col.push(a)):("review"==e&&saswp_attached_rv.splice(saswp_attached_rv.indexOf(a),1),"collection"==e&&saswp_attached_col.splice(saswp_attached_col.indexOf(a),1));var t=saswp_attached_rv.length,i=saswp_attached_col.length,p="";t>0&&(p+=t+" Reviews, "),i>0&&(p+=i+" Collection"),p||(p=0),s(".saswp-attached-rv-count").text("Attached "+p),s("#saswp_attahced_reviews").val(JSON.stringify(saswp_attached_rv)),s("#saswp_attached_collection").val(JSON.stringify(saswp_attached_col))}),s(".saswp-load-more-rv").on("click",function(a){var e=s(this).attr("data-type"),t=s(".saswp-add-rv-loop[data-type="+e+"]").length,i=t/10+1;s("#saswp-add-rv-automatic .spinner").addClass("is-active"),a.preventDefault(),s.get(ajaxurl,{action:"saswp_get_reviews_on_load",data_type:e,offset:t,paged:i,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){if("t"==a.status){var t="";a.result&&(s.each(a.result,function(s,a){var i="";"review"==e&&saswp_attached_rv.includes(parseInt(a.saswp_review_id))&&(i="checked"),"collection"==e&&saswp_attached_col.includes(parseInt(a.saswp_review_id))&&(i="checked"),t+='<div class="saswp-add-rv-loop" data-type="'+e+'" data-id="'+a.saswp_review_id+'">',"review"==e&&(t+='<input class="saswp-attach-rv-checkbox" type="checkbox" '+i+"> <strong> "+a.saswp_reviewer_name+" ( Rating - "+a.saswp_review_rating+' ) <span class="saswp-g-plus"><img src="'+a.saswp_review_platform_icon+'"/></span></strong>'),"collection"==e&&(t+='<input class="saswp-attach-rv-checkbox" type="checkbox" '+i+"> <strong> "+a.saswp_reviewer_name+" </strong>"),t+="</div>"}),s(".saswp-add-rv-automatic-list[data-type="+e+"]").append(t)),a.message&&(s(".saswp-rv-not-found[data-type="+e+"]").removeClass("saswp_hide"),s(".saswp-load-more-rv[data-type="+e+"]").addClass("saswp_hide"))}else alert(a.message);s("#saswp-add-rv-automatic .spinner").removeClass("is-active")},"json")}),s(".saswp-modify-schema-toggle").click(function(a){a.preventDefault(),s(".saswp-modify-container").slideToggle("300");var e=s("#saswp_enable_custom_field"),t=e.val();e.val("1"===t?"0":"1"),s(".saswp-enable-modify-schema-output").change()}),s(".saswp-enable-itemlist").change(function(){s(this).is(":checked")?(s("#saswp_item_list_tags").show(),s(".saspw-item-list-note").show(),"custom"==s("#saswp_item_list_tags").val()?s("#saswp_item_list_custom").show():s("#saswp_item_list_custom").hide()):(s(".saspw-item-list-note").hide(),s("#saswp_item_list_tags").hide(),s("#saswp_item_list_custom").hide())}),s("#saswp_item_list_tags").change(function(){"custom"==s(this).val()?s("#saswp_item_list_custom").show():s("#saswp_item_list_custom").hide()}),s(document).on("click",".saswp-add-g-location-btn",function(a){var e="";e=s("#saswp_google_place_api_key").length?'<input class="saswp-g-blocks-field" name="sd_data[saswp_reviews_location_blocks][]" type="number" min="5" step="5" placeholder="5" disabled="disabled">':'<input class="saswp-g-blocks-field" name="sd_data[saswp_reviews_location_blocks][]" type="number" min="10" step="10" placeholder="10">',a.preventDefault();var t="";(t+='<tr><td style="width:12%;"><strong>'+saswp_localize_data.translable_txt.place_id+'</strong></td><td style="width:20%;"><input class="saswp-g-location-field" name="sd_data[saswp_reviews_location_name][]" type="text" value=""></td><td style="width:10%;"><strong>'+saswp_localize_data.translable_txt.reviews+'</strong></td><td style="width:10%;">'+e+'</td><td style="width:10%;"><a class="button button-default saswp-fetch-g-reviews">'+saswp_localize_data.translable_txt.fetch+'</a></td><td style="width:10%;"><a type="button" class="saswp-remove-review-item button">x</a></td><td style="width:10%;"><p class="saswp-rv-fetched-msg"></p></td></tr>')&&s(".saswp-g-reviews-settings-table").append(t)}),s(document).on("click",".saswp-fetch-g-reviews",function(){var a=s(this),e="free";a.addClass("updating-message");var t=s(this).parent().parent().find(".saswp-g-location-field").val(),i=s(this).parent().parent().find(".saswp-g-blocks-field").val(),p=s("#saswp_google_place_api_key").val(),c=s("#reviews_addon_license_key").val(),o=s("#reviews_addon_license_key_status").val();if("premium"==(e=s("#saswp_google_place_api_key").length?"free":"premium")){if(!(i>0))return alert(saswp_localize_data.translable_txt.blocks_zero),a.removeClass("updating-message"),!1;if(0!=i%10)return a.parent().parent().find(".saswp-rv-fetched-msg").text(saswp_localize_data.translable_txt.step_in),a.parent().parent().find(".saswp-rv-fetched-msg").css("color","#988f1b"),a.removeClass("updating-message"),!1}""!=t&&(c||p)?s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_fetch_google_reviews",reviews_api_status:o,reviews_api:c,location:t,blocks:i,g_api:p,premium_status:e,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){"t"==s.status?(a.parent().parent().find(".saswp-rv-fetched-msg").text(saswp_localize_data.translable_txt.success),a.parent().parent().find(".saswp-rv-fetched-msg").css("color","green")):(a.parent().parent().find(".saswp-rv-fetched-msg").text(s.message),a.parent().parent().find(".saswp-rv-fetched-msg").css("color","#988f1b")),a.removeClass("updating-message")},error:function(s){console.log(s)}}):(""==t&&alert(saswp_localize_data.translable_txt.enter_place_id),""==p&&alert(saswp_localize_data.translable_txt.enter_api_key),""==c&&alert(saswp_localize_data.translable_txt.enter_rv_api_key),a.removeClass("updating-message"))}),saswp_localize_data.do_tour){var a,e="<h3>"+saswp_localize_data.translable_txt.using_schema+"</h3>";e+="<p>"+saswp_localize_data.translable_txt.do_you_want+" <b>"+saswp_localize_data.translable_txt.sd_update+"</b> "+saswp_localize_data.translable_txt.before_others+"</p>",e+='<style type="text/css">',e+=".wp-pointer-buttons{ padding:0; overflow: hidden; }",e+=".wp-pointer-content .button-secondary{ left: -25px;background: transparent;top: 5px; border: 0;position: relative; padding: 0; box-shadow: none;margin: 0;color: #0085ba;} .wp-pointer-content .button-primary{ display:none} #saswp_mc_embed_signup{background:#fff; clear:left; font:14px Helvetica,Arial,sans-serif; }",e+="</style>",e+='<div id="saswp_mc_embed_signup">',e+='<form method="POST" accept-charset="utf-8" id="saswp-news-letter-form">',e+='<div id="saswp_mc_embed_signup_scroll">',e+='<div class="saswp-mc-field-group" style=" margin-left: 15px; width: 195px; float: left;">',e+='<input type="text" name="saswp_subscriber_name" class="form-control" placeholder="Name" hidden value="'+saswp_localize_data.current_user_name+'" style="display:none">',e+='<input type="text" value="'+saswp_localize_data.current_user_email+'" name="saswp_subscriber_email" class="form-control" placeholder="Email*" style=" width: 180px; padding: 6px 5px;">',e+='<input type="text" name="saswp_subscriber_website" class="form-control" placeholder="Website" hidden style=" display:none; width: 168px; padding: 6px 5px;" value="'+saswp_localize_data.get_home_url+'">',e+='<input type="hidden" name="ml-submit" value="1" />',e+="</div>",e+='<div id="mce-responses">',e+="</div>",e+='<div style="position: absolute; left: -5000px;" aria-hidden="true"><input type="text" name="b_a631df13442f19caede5a5baf_c9a71edce6" tabindex="-1" value=""></div>',e+='<input type="submit" value="Subscribe" name="subscribe" id="pointer-close" class="button mc-newsletter-sent" style=" background: #0085ba; border-color: #006799; padding: 0px 16px; text-shadow: 0 -1px 1px #006799,1px 0 1px #006799,0 1px 1px #006799,-1px 0 1px #006799; height: 30px; margin-top: 1px; color: #fff; box-shadow: 0 1px 0 #006799;">',e+='<p id="saswp-news-letter-status"></p>',e+="</div>",e+="</form>",e+="</div>",s(document).on("submit","#saswp-news-letter-form",function(a){a.preventDefault();var e=s(this),t=e.find('input[name="saswp_subscriber_name"]').val(),i=e.find('input[name="saswp_subscriber_email"]').val();website=e.find('input[name="saswp_subscriber_website"]').val(),s.post(saswp_localize_data.ajax_url,{action:"saswp_subscribe_to_news_letter",saswp_security_nonce:saswp_localize_data.saswp_security_nonce,name:t,email:i,website:website},function(a){a?"Some fields are missing."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):"Invalid email address."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):"Invalid list ID."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):"Already subscribed."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):(s("#saswp-news-letter-status").text("You're subscribed!"),s("#saswp-news-letter-status").css("color","green")):alert("Sorry, unable to subscribe. Please try again later!")})});var t={content:e,position:{edge:"top",align:"left"}};a=function(){s(saswp_localize_data.displayID).pointer(t).pointer("open"),saswp_localize_data.button2&&(jQuery("#pointer-close").after('<a id="pointer-primary" class="button-primary">'+saswp_localize_data.button2+"</a>"),jQuery("#pointer-primary").click(function(){saswp_localize_data.function_name}),jQuery("#pointer-close").click(function(){s.post(saswp_localize_data.ajax_url,{pointer:"saswp_subscribe_pointer",action:"dismiss-wp-pointer"})}))},(t=s.extend(t,{buttons:function(s,a){return button=jQuery('<a id="pointer-close" class="button-secondary">'+saswp_localize_data.button1+"</a>"),button_2=jQuery("#pointer-close.button"),button.bind("click.pointer",function(){a.element.pointer("close")}),button_2.on("click",function(){setTimeout(function(){a.element.pointer("close")},3e3)}),button},close:function(){s.post(saswp_localize_data.ajax_url,{pointer:"saswp_subscribe_pointer",action:"dismiss-wp-pointer"})},show:function(s,a){a.pointer.css({left:"170px",top:"160px"})}})).position&&t.position.defer_loading?s(window).bind("load.wp-pointers",a):a()}if(s(".saswp-tabs a").click(function(a){var e=s(this).attr("href"),t=getParameterByName("tab",e);return t||(t="general"),s(this).siblings().removeClass("nav-tab-active"),s(this).addClass("nav-tab-active"),s(".form-wrap").find(".saswp-"+t).siblings().hide(),s(".form-wrap .saswp-"+t).show(),window.history.pushState("","",e),!1}),s(".saswp-schame-type-select").select2(),s(".saswp-schame-type-select").change(function(a){a.preventDefault(),s(".saswp-custom-fields-table").html("");var e=s(this).val();s(".saswp-option-table-class tr").each(function(a,e){a>0&&s(this).hide()}),"TechArticle"==e||"Article"==e||"Blogposting"==e||"NewsArticle"==e||"WebPage"==e?s(".saswp-enable-speakable").parent().parent().show():s(".saswp-enable-speakable").parent().parent().hide(),"Book"==e||"Course"==e||"Organization"==e||"CreativeWorkSeries"==e||"MobileApplication"==e||"ImageObject"==e||"HowTo"==e||"MusicPlaylist"==e||"MusicAlbum"==e||"Recipe"==e||"TVSeries"==e||"SoftwareApplication"==e||"Event"==e||"VideoGame"==e||"Service"==e||"AudioObject"==e||"VideoObject"==e||"local_business"==e||"Product"==e||"Review"==e?s(".saswp-enable-append-reviews").parent().parent().show():s(".saswp-enable-append-reviews").parent().parent().hide(),"VideoObject"==e?s(".saswp-enable-markup-class").parent().parent().show():s(".saswp-enable-markup-class").parent().parent().hide(),"local_business"==e&&(s(".saswp-option-table-class tr").eq(1).show(),s(".saswp-business-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1),s(".select-post-type").val("show_globally").trigger("change")),"Service"==e&&(s(".saswp-service-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)),"Event"==e&&(s(".saswp-event-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)),"Review"==e&&(s(".saswp-review-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1),s(".saswp-item-reivewed-list").change()),"ItemList"==e?(s(".saswp-schema-modify-section").hide(),s(".saswp-itemlist-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1),s(".saswp-itemlist-item-type-list").change()):s(".saswp-schema-modify-section").show(),saswp_enable_rating_review(),s(".saswp-manual-modification").html(""),s(".saswp-static-container .spinner").addClass("is-active"),s.get(ajaxurl,{action:"saswp_get_manual_fields_on_ajax",schema_type:e,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){s(".saswp-static-container .spinner").removeClass("is-active"),s(".saswp-manual-modification").append(a),saswp_schema_datepicker(),saswp_schema_timepicker(),saswp_item_reviewed_call()}),"HowTo"==e||"local_business"==e||"FAQ"==e?s(".saswp-enable-modify-schema").show():(s(".saswp-enable-modify-schema-output").val("automatic"),s(".saswp-enable-modify-schema-output").change(),s(".saswp-enable-modify-schema").hide())}),s("#saswp_business_type").select2(),s(".saswp-local-sub-type-2").select2(),s("#saswp_business_type").change(function(){var a=s(this).val(),e=s(".saswp-schame-type-select").val();s(".saswp-option-table-class tr").each(function(a,e){a>1&&(s(this).hide(),s(this).find(".saswp-local-sub-type-2").attr("disabled",!0))}),"TechArticle"==e||"Article"==e||"Blogposting"==e||"NewsArticle"==e||"WebPage"==e?s(".saswp-enable-speakable").parent().parent().show():s(".saswp-enable-speakable").parent().parent().hide(),"Book"==e||"Course"==e||"Organization"==e||"CreativeWorkSeries"==e||"MobileApplication"==e||"ImageObject"==e||"HowTo"==e||"MusicPlaylist"==e||"MusicAlbum"==e||"Recipe"==e||"TVSeries"==e||"SoftwareApplication"==e||"Event"==e||"VideoGame"==e||"Service"==e||"AudioObject"==e||"VideoObject"==e||"local_business"==e||"Product"==e||"Review"==e?s(".saswp-enable-append-reviews").parent().parent().show():s(".saswp-enable-append-reviews").parent().parent().hide(),"VideoObject"==e?s(".saswp-enable-markup-class").parent().parent().show():s(".saswp-enable-markup-class").parent().parent().hide(),"local_business"==e&&(s(".saswp-"+a+"-tr").show(),s(".saswp-business-text-field-tr").show(),s(".saswp-"+a+"-tr").find("select").attr("disabled",!1)),"Review"==e&&(s(".saswp-review-text-field-tr").show(),s(".saswp-review-text-field-tr").find("select").attr("disabled",!1)),"ItemList"==e?(s(".saswp-schema-modify-section").hide(),s(".saswp-itemlist-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)):s(".saswp-schema-modify-section").show(),"Event"==e&&(s(".saswp-event-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)),saswp_enable_rating_review()}).change(),s(".saswp-checkbox").change(function(){var a=s(this).attr("id"),e=s(this);switch(a){case"saswp-the-seo-framework-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-the-seo-framework").val(1):s("#saswp-the-seo-framework").val(0);break;case"saswp-seo-press-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-seo-press").val(1):s("#saswp-seo-press").val(0);break;case"saswp-aiosp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-aiosp").val(1):s("#saswp-aiosp").val(0);break;case"saswp-smart-crawl-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-smart-crawl").val(1):s("#saswp-smart-crawl").val(0);break;case"saswp-squirrly-seo-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-squirrly-seo").val(1):s("#saswp-squirrly-seo").val(0);break;case"saswp-wp-recipe-maker-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-recipe-maker").val(1):s("#saswp-wp-recipe-maker").val(0);break;case"saswp-wpzoom-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpzoom").val(1):s("#saswp-wpzoom").val(0);break;case"saswp-yotpo-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-yotpo").val(1):s("#saswp-yotpo").val(0);break;case"saswp-ultimate-blocks-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ultimate-blocks").val(1):s("#saswp-ultimate-blocks").val(0);break;case"saswp-starsrating-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-starsrating").val(1):s("#saswp-starsrating").val(0);break;case"saswp-wptastyrecipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wptastyrecipe").val(1):s("#saswp-wptastyrecipe").val(0);break;case"saswp-recipress-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-recipress").val(1):s("#saswp-recipress").val(0);break;case"saswp-wp-ultimate-recipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-ultimate-recipe").val(1):s("#saswp-wp-ultimate-recipe").val(0);break;case"saswp-zip-recipes-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-zip-recipes").val(1):s("#saswp-zip-recipes").val(0);break;case"saswp-mediavine-create-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-mediavine-create").val(1):s("#saswp-mediavine-create").val(0);break;case"saswp-ht-recipes-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ht-recipes").val(1):s("#saswp-ht-recipes").val(0);break;case"saswp-wpsso-core-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpsso-core").val(1):s("#saswp-wpsso-core").val(0);break;case"saswp-for-wordpress-checkbox":s(this).is(":checked")?s("#saswp-for-wordpress").val(1):s("#saswp-for-wordpress").val(0);break;case"saswp-for-amp-checkbox":s(this).is(":checked")?s("#saswp-for-amp").val(1):s("#saswp-for-amp").val(0);break;case"saswp_kb_contact_1_checkbox":s(this).is(":checked")?(s("#saswp_kb_contact_1").val(1),s("#saswp_kb_telephone, #saswp_contact_type").parent().parent("li").removeClass("saswp-display-none")):(s("#saswp_kb_contact_1").val(0),s("#saswp_kb_telephone, #saswp_contact_type").parent().parent("li").addClass("saswp-display-none"));break;case"saswp-logo-dimensions-check":s(this).is(":checked")?(s("#saswp-logo-dimensions").val(1),s("#saswp-logo-width, #saswp-logo-height").parent().parent("li").show()):(s("#saswp-logo-dimensions").val(0),s("#saswp-logo-width, #saswp-logo-height").parent().parent("li").hide());break;case"saswp_archive_schema_checkbox":s(this).is(":checked")?(s("#saswp_archive_schema").val(1),s(".saswp_archive_schema_type_class").parent().parent().show()):(s("#saswp_archive_schema").val(0),s(".saswp_archive_schema_type_class").parent().parent().hide());break;case"saswp_website_schema_checkbox":s(this).is(":checked")?(s("#saswp_website_schema").val(1),s("#saswp_search_box_schema").parent().parent().show()):(s("#saswp_website_schema").val(0),s("#saswp_search_box_schema").parent().parent().hide());break;case"saswp_search_box_schema_checkbox":s(this).is(":checked")?s("#saswp_search_box_schema").val(1):s("#saswp_search_box_schema").val(0);break;case"saswp_breadcrumb_schema_checkbox":s(this).is(":checked")?s("#saswp_breadcrumb_schema").val(1):s("#saswp_breadcrumb_schema").val(0);break;case"saswp_comments_schema_checkbox":s(this).is(":checked")?s("#saswp_comments_schema").val(1):s("#saswp_comments_schema").val(0);break;case"saswp-compativility-checkbox":s(this).is(":checked")?s("#saswp-flexmlx-compativility").val(1):s("#saswp-flexmlx-compativility").val(0);break;case"saswp-review-module-checkbox":s(this).is(":checked")?s("#saswp-review-module").val(1):s("#saswp-review-module").val(0);break;case"saswp-stars-rating-checkbox":s(this).is(":checked")?(s(".saswp-stars-post-table").removeClass("saswp_hide"),s("#saswp-stars-rating").val(1)):(s(".saswp-stars-post-table").addClass("saswp_hide"),s("#saswp-stars-rating").val(0));break;case"saswp-kk-star-raring-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-kk-star-raring").val(1):s("#saswp-kk-star-raring").val(0);break;case"saswp-wpdiscuz-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpdiscuz").val(1):s("#saswp-wpdiscuz").val(0);break;case"saswp-yet-another-stars-rating-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-yet-another-stars-rating").val(1):s("#saswp-yet-another-stars-rating").val(0);break;case"saswp-simple-author-box-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-simple-author-box").val(1):s("#saswp-simple-author-box").val(0);break;case"saswp-woocommerce-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-woocommerce").val(1):s("#saswp-woocommerce").val(0);break;case"saswp-default-review-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp_default_review").val(1):s("#saswp_default_review").val(0);break;case"saswp-extra-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-extra").val(1):s("#saswp-extra").val(0);break;case"saswp-soledad-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-soledad").val(1):s("#saswp-soledad").val(0);break;case"saswp-wp-theme-reviews-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-theme-reviews").val(1):s("#saswp-wp-theme-reviews").val(0);break;case"saswp-dw-question-answer-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-dw-question-answer").val(1):s("#saswp-dw-question-answer").val(0);break;case"saswp-wp-job-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-job-manager").val(1):s("#saswp-wp-job-manager").val(0);break;case"saswp-yoast-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-yoast").val(1):s("#saswp-yoast").val(0);break;case"saswp-slimseo-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-slimseo").val(1):s("#saswp-slimseo").val(0);break;case"saswp-rankmath-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-rankmath").val(1):s("#saswp-rankmath").val(0);break;case"saswp-taqyeem-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-taqyeem").val(1):s("#saswp-taqyeem").val(0);break;case"saswp-video-thumbnails-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-video-thumbnails").val(1):s("#saswp-video-thumbnails").val(0);break;case"saswp-featured-video-plus-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-featured-video-plus").val(1):s("#saswp-featured-video-plus").val(0);break;case"saswp-wp-product-review-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-product-review").val(1):s("#saswp-wp-product-review").val(0);break;case"saswp-the-events-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-the-events-calendar").val(1):s("#saswp-the-events-calendar").val(0);break;case"saswp-homeland-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-homeland").val(1):s("#saswp-homeland").val(0);break;case"saswp-ratency-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ratency").val(1):s("#saswp-ratency").val(0);break;case"saswp-wpresidence-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpresidence").val(1):s("#saswp-wpresidence").val(0);break;case"saswp-myhome-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-myhome").val(1):s("#saswp-myhome").val(0);break;case"saswp-realestate-5-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-realestate-5").val(1):s("#saswp-realestate-5").val(0);break;case"saswp-stamped-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-stamped").val(1):s("#saswp-stamped").val(0);break;case"saswp-sabaidiscuss-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-sabaidiscuss").val(1):s("#saswp-sabaidiscuss").val(0);break;case"saswp-geodirectory-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-geodirectory").val(1):s("#saswp-geodirectory").val(0);break;case"saswp-classipress-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-classipress").val(1):s("#saswp-classipress").val(0);break;case"saswp-realhomes-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-realhomes").val(1):s("#saswp-realhomes").val(0);break;case"saswp-learn-press-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-learn-press").val(1):s("#saswp-learn-press").val(0);break;case"saswp-wplms-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wplms").val(1):s("#saswp-wplms").val(0);break;case"saswp-learn-dash-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-learn-dash").val(1):s("#saswp-learn-dash").val(0);break;case"saswp-lifter-lms-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-lifter-lms").val(1):s("#saswp-lifter-lms").val(0);break;case"saswp-senseilms-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-senseilms").val(1):s("#saswp-senseilms").val(0);break;case"saswp-wp-event-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-event-manager").val(1):s("#saswp-wp-event-manager").val(0);break;case"saswp-events-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-events-manager").val(1):s("#saswp-events-manager").val(0);break;case"saswp-event-calendar-wd-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-event-calendar-wd").val(1):s("#saswp-event-calendar-wd").val(0);break;case"saswp-event-organiser-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-event-organiser").val(1):s("#saswp-event-organiser").val(0);break;case"saswp-modern-events-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-modern-events-calendar").val(1):s("#saswp-modern-events-calendar").val(0);break;case"saswp-woocommerce-booking-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?(s("#saswp-woocommerce-booking").val(1),s("#saswp-woocommerce-booking-main").val(1)):(s("#saswp-woocommerce-booking").val(0),s("#saswp-woocommerce-booking-main").val(0));break;case"saswp-woocommerce-booking-main-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?(s("#saswp-woocommerce-booking-main").val(1),s("#saswp-woocommerce-booking").val(1)):(s("#saswp-woocommerce-booking-main").val(0),s("#saswp-woocommerce-booking").val(0));break;case"saswp-woocommerce-membership-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-woocommerce-membership").val(1):s("#saswp-woocommerce-membership").val(0);break;case"saswp-defragment-checkbox":s(this).is(":checked")?s("#saswp-defragment").val(1):s("#saswp-defragment").val(0);break;case"saswp-cooked-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-cooked").val(1):s("#saswp-cooked").val(0);break;case"saswp-flexmlx-compativility-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-flexmlx-compativility").val(1):s("#saswp-flexmlx-compativility").val(0);break;case"saswp-shopper-approved-review-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?(s("#saswp-shopper-approved-review").val(1),s(".saswp-s-reviews-settings-table").parent().parent().parent().show()):(s("#saswp-shopper-approved-review").val(0),s(".saswp-s-reviews-settings-table").parent().parent().parent().hide());break;case"saswp-google-review-checkbox":s(this).is(":checked")?(s("#saswp-google-review").val(1),s("#saswp-google-rv-free-checkbox").length?(s("#saswp-google-review-free").parent().parent().show(),s("#saswp-google-rv-free-checkbox").is(":checked")?s("#saswp_google_place_api_key").parent().parent().show():s("#saswp_google_place_api_key").parent().parent().hide()):s("#saswp_google_place_api_key").parent().parent().show(),s(".saswp-g-reviews-settings-table").parent().parent().parent().show()):(s("#saswp-google-review").val(0),s("#saswp_google_place_api_key").parent().parent().hide(),s(".saswp-g-reviews-settings-table").parent().parent().parent().hide(),s("#saswp-google-rv-free-checkbox").length&&s("#saswp-google-review-free").parent().parent().hide());break;case"saswp-google-rv-free-checkbox":s("#saswp-google-review-checkbox").is(":checked")&&s(this).is(":checked")?(s("#saswp-google-review-free").val(1),s("#saswp_google_place_api_key").parent().parent().show()):(s("#saswp-google-review-free").val(0),s("#saswp_google_place_api_key").parent().parent().hide());break;case"saswp-markup-footer-checkbox":s(this).is(":checked")?s("#saswp-markup-footer").val(1):s("#saswp-markup-footer").val(0);break;case"saswp-pretty-print-checkbox":s(this).is(":checked")?s("#saswp-pretty-print").val(1):s("#saswp-pretty-print").val(0);break;case"saswp-wppostratings-raring-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wppostratings-raring").val(1):s("#saswp-wppostratings-raring").val(0);break;case"saswp-bbpress-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-bbpress").val(1):s("#saswp-bbpress").val(0);break;case"saswp-microdata-cleanup-checkbox":s(this).is(":checked")?s("#saswp-microdata-cleanup").val(1):s("#saswp-microdata-cleanup").val(0);break;case"saswp-other-images-checkbox":s(this).is(":checked")?s("#saswp-other-images").val(1):s("#saswp-other-images").val(0);break;case"saswp-rss-feed-image-checkbox":s(this).is(":checked")?s("#saswp-rss-feed-image").val(1):s("#saswp-rss-feed-image").val(0);break;case"saswp-multiple-size-image-checkbox":s(this).is(":checked")?s("#saswp-multiple-size-image").val(1):s("#saswp-multiple-size-image").val(0);break;case"saswp-easy-testimonials-checkbox":s(this).is(":checked")?s("#saswp-easy-testimonials").val(1):s("#saswp-easy-testimonials").val(0);break;case"saswp-testimonial-pro-checkbox":s(this).is(":checked")?s("#saswp-testimonial-pro").val(1):s("#saswp-testimonial-pro").val(0);break;case"saswp-bne-testimonials-checkbox":s(this).is(":checked")?s("#saswp-bne-testimonials").val(1):s("#saswp-bne-testimonials").val(0);break;case"saswp-ampforwp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ampforwp").val(1):s("#saswp-ampforwp").val(0);break;case"saswp-ampbyautomatic-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ampbyautomatic").val(1):s("#saswp-ampbyautomatic").val(0);break;case"saswp-rannarecipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-rannarecipe").val(1):s("#saswp-rannarecipe").val(0);break;case"saswp-quickandeasyfaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-quickandeasyfaq").val(1):s("#saswp-quickandeasyfaq").val(0);break;case"saswp-ultimatefaqs-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ultimatefaqs").val(1):s("#saswp-ultimatefaqs").val(0);break;case"saswp-arconixfaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-arconixfaq").val(1):s("#saswp-arconixfaq").val(0);break;case"saswp-faqconcertina-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-faqconcertina").val(1):s("#saswp-faqconcertina").val(0);break;case"saswp-wpjobmanager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpjobmanager").val(1):s("#saswp-wpjobmanager").val(0);break;case"saswp-simplejobboard-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-simplejobboard").val(1):s("#saswp-simplejobboard").val(0);break;case"saswp-wpjobopenings-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpjobopenings").val(1):s("#saswp-wpjobopenings").val(0);break;case"saswp-webfaq10-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-webfaq10").val(1):s("#saswp-webfaq10").val(0);break;case"saswp-wpfaqschemamarkup-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpfaqschemamarkup").val(1):s("#saswp-wpfaqschemamarkup").val(0);break;case"saswp-faqschemaforpost-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-faqschemaforpost").val(1):s("#saswp-faqschemaforpost").val(0);break;case"saswp-masteraccordion-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-masteraccordion").val(1):s("#saswp-masteraccordion").val(0);break;case"saswp-easyfaqs-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-easyfaqs").val(1):s("#saswp-easyfaqs").val(0);break;case"saswp-accordion-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-accordion").val(1):s("#saswp-accordion").val(0);break;case"saswp-html5responsivefaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-html5responsivefaq").val(1):s("#saswp-html5responsivefaq").val(0);break;case"saswp-wpresponsivefaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpresponsivefaq").val(1):s("#saswp-wpresponsivefaq").val(0);break;case"saswp-easyaccordion-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-easyaccordion").val(1):s("#saswp-easyaccordion").val(0);break;case"saswp-helpiefaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-helpiefaq").val(1):s("#saswp-helpiefaq").val(0);break;case"saswp-accordionfaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-accordionfaq").val(1):s("#saswp-accordionfaq").val(0);break;case"saswp-schemaforfaqs-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-schemaforfaqs").val(1):s("#saswp-schemaforfaqs").val(0);break;case"saswp-wp-customer-reviews-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-customer-reviews").val(1):s("#saswp-wp-customer-reviews").val(0);break;case"saswp-total-recipe-generator-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-total-recipe-generator").val(1):s("#saswp-total-recipe-generator").val(0);break;case"saswp-wordpress-news-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wordpress-news").val(1):s("#saswp-wordpress-news").val(0);break;case"saswp-ampwp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ampwp").val(1):s("#saswp-ampwp").val(0);break;case"saswp-wp-event-aggregator-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-event-aggregator").val(1):s("#saswp-wp-event-aggregator").val(0);break;case"saswp-timetable-event-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-timetable-event").val(1):s("#saswp-timetable-event").val(0);break;case"saswp-xo-event-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-xo-event-calendar").val(1):s("#saswp-xo-event-calendar").val(0);break;case"saswp-vs-event-list-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-vs-event-list").val(1):s("#saswp-vs-event-list").val(0);break;case"saswp-calendarize-it-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-calendarize-it").val(1):s("#saswp-calendarize-it").val(0);break;case"saswp-events-schedule-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-events-schedule").val(1):s("#saswp-events-schedule").val(0);break;case"saswp-woo-event-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-woo-event-manager").val(1):s("#saswp-woo-event-manager").val(0);break;case"saswp-stachethemes-event-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-stachethemes-event-calendar").val(1):s("#saswp-stachethemes-event-calendar").val(0);break;case"saswp-all-in-one-event-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-all-in-one-event-calendar").val(1):s("#saswp-all-in-one-event-calendar").val(0);break;case"saswp-event-on-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-event-on").val(1):s("#saswp-event-on").val(0);break;case"saswp-easy-recipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-easy-recipe").val(1):s("#saswp-easy-recipe").val(0);break;case"saswp-tevolution-events-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-tevolution-events").val(1):s("#saswp-tevolution-events").val(0);break;case"saswp-strong-testimonials-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-strong-testimonials").val(1):s("#saswp-strong-testimonials").val(0);break;case"saswp-wordlift-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wordlift").val(1):s("#saswp-wordlift").val(0);break;case"saswp-betteramp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-betteramp").val(1):s("#saswp-betteramp").val(0);break;case"saswp-wpamp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpamp").val(1):s("#saswp-wpamp").val(0)}}).change(),s("#saswp_kb_type").change(function(){var a=s(this).val();s(".saswp_org_fields, .saswp_person_fields").parent().parent().addClass("saswp_hide"),s(".saswp_kg_logo").parent().parent().parent().addClass("saswp_hide"),s("#sd-person-image").parent().parent().parent().addClass("saswp_hide"),"Organization"==a&&(s(".saswp_org_fields").parent().parent().removeClass("saswp_hide"),s(".saswp_person_fields").parent().parent().addClass("saswp_hide"),s(".saswp_kg_logo").parent().parent().parent().removeClass("saswp_hide"),s("#sd-person-image").parent().parent().parent().addClass("saswp_hide")),"Person"==a&&(s(".saswp_org_fields").parent().parent().addClass("saswp_hide"),s(".saswp_person_fields").parent().parent().removeClass("saswp_hide"),s(".saswp_kg_logo").parent().parent().parent().removeClass("saswp_hide"),s("#sd-person-image").parent().parent().parent().removeClass("saswp_hide"))}).change(),s(document).on("click","input[data-id=media]",function(a){a.preventDefault();var e=s(this),t=e.attr("id").replace("_button",""),i=wp.media({title:"Application Icon",button:{text:"Select Icon"},multiple:!1,library:{type:"image"}}).on("select",function(){var a=i.state().get("selection").first().toJSON();s("#"+t).val(a.url),s("input[data-id='"+t+"_id']").val(a.id),s("input[data-id='"+t+"_height']").val(a.height),s("input[data-id='"+t+"_width']").val(a.width),s("input[data-id='"+t+"_thumbnail']").val(a.url),"sd_default_image_button"===e.attr("id")&&(s("#sd_default_image_width").val(a.width),s("#sd_default_image_height").val(a.height));var p="";"saswp_image_div_"+t=="saswp_image_div_sd_default_image"&&a.height<1200&&(p='<p class="saswp_warning">Image size is smaller than recommended size</p>'),s(".saswp_image_div_"+t).html('<div class="saswp_image_thumbnail"><img class="saswp_image_prev" src="'+a.url+'"/><a data-id="'+t+'" href="#" class="saswp_prev_close">X</a></div>'+p)}).open()}),s(document).on("click",".saswp_prev_close",function(a){a.preventDefault();var e=s(this).attr("data-id");s(this).parent().remove(),s("#"+e).val(""),s("input[data-id='"+e+"_id']").val(""),s("input[data-id='"+e+"_height']").val(""),s("input[data-id='"+e+"_width']").val(""),s("input[data-id='"+e+"_thumbnail']").val(""),"sd_default_image"===e&&(s("#sd_default_image_width").val(""),s("#sd_default_image_height").val(""))}),s(document).on("click",".saswp-modify-schema",function(a){a.preventDefault();var e=s(this).attr("schema-id"),t=s(this);t.addClass("updating-message"),s.get(ajaxurl,{action:"saswp_modify_schema_post_enable",schema_id:e,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){s(".saswp-post-specific-wrapper[data-id="+e+"] .saswp-post-specific-setting").after(a),s(".saswp_modify_this_schema_hidden_"+e).val(1),s(".saswp-ps-toggle[schema-id="+e+"]").removeClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().removeClass("saswp_hide"),s(".saswp-modify-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),t.removeClass("updating-message"),saswp_schema_datepicker(),saswp_schema_timepicker(),saswp_enable_rating_review(),saswp_item_reviewed_call()})}),s(document).on("click",".saswp-restore-schema",function(a){a.preventDefault();var e=s(this).attr("schema-id"),t=s(this);t.addClass("updating-message"),s.post(ajaxurl,{action:"saswp_modify_schema_post_restore",schema_id:e,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){t.removeClass("updating-message"),"t"==a.status?(s(".saswp_modify_this_schema_hidden_"+e).val(0),s(".saswp-restore-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),s(".saswp-modify-schema[schema-id="+e+"]").parent().removeClass("saswp_hide"),s(".saswp-ps-toggle[schema-id="+e+"]").remove()):alert("Something went wrong")},"json")}),s(document).on("change",".saswp-schema-type-toggle",function(a){var e=s(this).attr("data-schema-id"),t=s(this).attr("data-post-id"),i=s(".saswp_modify_this_schema_hidden_"+e).val();if(s(this).is(":checked")){var p=0;s(".saswp-ps-toggle[schema-id="+e+"]").addClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),s(".saswp-modify-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),s("#saswp_custom_schema_field[schema-id="+e+"]").parent().addClass("saswp_hide")}else{s("#saswp_custom_schema_field[schema-id="+e+"]").parent().removeClass("saswp_hide"),1==i?(s(".saswp-ps-toggle[schema-id="+e+"]").removeClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().removeClass("saswp_hide")):(s(".saswp-modify-schema[schema-id="+e+"]").parent().removeClass("saswp_hide"),s(".saswp-ps-toggle[schema-id="+e+"]").addClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().addClass("saswp_hide"));p=1}s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_enable_disable_schema_on_post",status:p,schema_id:e,post_id:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){},error:function(s){console.log(s)}})}),s(document).on("click",".saswp-reset-data",function(a){a.preventDefault(),1==confirm("Are you sure?")&&s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_reset_all_settings",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){setTimeout(function(){location.reload()},1e3)},error:function(s){console.log(s)}})}),s(document).on("click",".saswp_license_activation",function(a){a.preventDefault();var e=s(this);e.addClass("updating-message");var t=s(this).attr("license-status"),i=s(this).attr("add-on"),p=s("#"+i+"_addon_license_key").val();t&&i&&p?s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_license_status_check",license_key:p,license_status:t,add_on:i,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(a){s("#"+i+"_addon_license_key_status").val(a.status),"active"==a.status?(s(".saswp-"+i+"-dashicons").addClass("dashicons-yes"),s(".saswp-"+i+"-dashicons").removeClass("dashicons-no-alt"),s(".saswp-"+i+"-dashicons").css("color","green"),s(".saswp_license_activation[add-on='"+i+"']").attr("license-status","inactive"),s(".saswp_license_activation[add-on='"+i+"']").text("Deactivate"),s(".saswp_license_status_msg[add-on='"+i+"']").text("Activated"),s(".saswp_license_status_msg[add-on='"+i+"']").css("color","green"),s(".saswp_license_status_msg[add-on='"+i+"']").text(a.message)):(s(".saswp-"+i+"-dashicons").addClass("dashicons-no-alt"),s(".saswp-"+i+"-dashicons").removeClass("dashicons-yes"),s(".saswp-"+i+"-dashicons").css("color","red"),s(".saswp_license_activation[add-on='"+i+"']").attr("license-status","active"),s(".saswp_license_activation[add-on='"+i+"']").text("Activate"),s(".saswp_license_status_msg[add-on='"+i+"']").css("color","red"),s(".saswp_license_status_msg[add-on='"+i+"']").text(a.message)),e.removeClass("updating-message")},error:function(s){console.log(s)}}):(alert("Please enter value license key"),e.removeClass("updating-message"))}),s(".saswp-send-query").on("click",function(a){a.preventDefault();var e=s("#saswp_query_message").val(),t=s("#saswp_query_email").val(),i=s("#saswp_query_premium_cus").val();console.log(saswpIsEmail(t)),""!=s.trim(e)&&i&&""!=s.trim(t)&&1==saswpIsEmail(t)?s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_send_query_message",premium_cus:i,message:e,email:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(a){"t"==a.status?(s(".saswp-query-success").show(),s(".saswp-query-error").hide()):(s(".saswp-query-success").hide(),s(".saswp-query-error").show())},error:function(s){console.log(s)}}):""==s.trim(e)&&""==i&&""==s.trim(t)?alert("Please enter the message, email and select customer type"):(""==i&&alert("Select Customer type"),""==s.trim(e)&&alert("Please enter the message"),""==s.trim(t)&&alert("Please enter the email"),0==saswpIsEmail(t)&&alert("Please enter a valid email"))}),s(".saswp-import-plugins").on("click",function(a){a.preventDefault();var e=s(this);e.addClass("updating-message");var t=s(this).attr("data-id");s.get(ajaxurl,{action:"saswp_import_plugin_data",plugin_name:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){"t"==a.status?(s(e).parent().find(".saswp-imported-message").text(a.message),s(e).parent().find(".saswp-imported-message").removeClass("saswp-error"),setTimeout(function(){location.reload()},2e3)):(s(e).parent().find(".saswp-imported-message").addClass("saswp-error"),s(e).parent().find(".saswp-imported-message").text(a.message)),e.removeClass("updating-message")},"json")}),s(".saswp-feedback-no-thanks").on("click",function(a){a.preventDefault(),s.get(ajaxurl,{action:"saswp_feeback_no_thanks",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){"t"==a.status&&s(".saswp-feedback-notice").hide()},"json")}),s(".saswp-feedback-remindme").on("click",function(a){a.preventDefault(),s.get(ajaxurl,{action:"saswp_feeback_remindme",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){"t"==a.status&&s(".saswp-feedback-notice").hide()},"json")}),s(document).on("change",".saswp-local-business-type-select",function(a){a.preventDefault();var e=s(this),t=s(this).val();s.get(ajaxurl,{action:"saswp_get_sub_business_ajax",business_type:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){if("t"==a.status){s(".saswp-local-business-name-select").parents("tr").remove();var t=e.parents(".saswp-post-specific-wrapper").attr("data-id"),i='<tr><th><label for="saswp_business_name_'+t+'">Sub Business Type</label></th>';i+='<td><select class="saswp-local-business-name-select" id="saswp_business_name_'+t+'" name="saswp_business_name_'+t+'">',s.each(a.result,function(s,a){i+='<option value="'+s+'">'+a+"</option>"}),i+="</select></td>",i+="</tr>",e.parents(".form-table tr:first").after(i)}else s(".saswp-local-business-name-select").parents("tr").remove()},"json")}),saswp_item_reviewed_call(),jQuery(".saswp-local-schema-time-picker").timepicker({timeFormat:"H:i:s"}),s(document).on("click",".saswp-add-custom-schema",function(a){a.preventDefault(),s(".saswp-add-custom-schema-field").removeClass("saswp_hide"),s(this).hide()}),s(document).on("click",".saswp-delete-custom-schema",function(a){a.preventDefault(),s("#saswp_custom_schema_field").val(""),s(".saswp-add-custom-schema-field").addClass("saswp_hide"),s(".saswp-add-custom-schema").show()}),saswp_schema_datepicker(),saswp_schema_timepicker(),saswp_reviews_datepicker(),s(document).on("click",".saswp-add-more-item",function(a){a.preventDefault();s(".saswp-review-item-list-table").append('<tr class="saswp-review-item-tr"><td>Review Item Feature</td><td><input type="text" name="saswp-review-item-feature[]"></td><td>Rating</td><td><input step="0.1" min="0" max="5" type="number" name="saswp-review-item-star-rating[]"></td><td><a type="button" class="saswp-remove-review-item button">x</a></td></tr>')}),s(document).on("click",".saswp-remove-review-item",function(a){a.preventDefault(),s(this).parent().parent("tr").remove()}),s(document).on("focusout",".saswp-review-item-tr input[type=number]",function(a){a.preventDefault();var e=0,t=s(".saswp-review-item-tr input[type=number]").length;s(".saswp-review-item-tr input[type=number]").each(function(a,t){""==s(t).val()?e+=parseFloat(0):e+=parseFloat(s(t).val())});var i=e/t;s("#saswp-review-item-over-all").val(i)}),s("#saswp-review-location").change(function(){var a=s(this).val();s(".saswp-review-shortcode").addClass("saswp_hide"),3==a&&s(".saswp-review-shortcode").removeClass("saswp_hide")}).change(),s("#saswp-review-item-enable").change(function(){s(this).is(":checked")?s(".saswp-review-fields").show():s(".saswp-review-fields").hide()}).change(),s(document).on("click",".saswp-restore-post-schema",function(a){a.preventDefault();var e=s(this);if(e.addClass("updating-message"),s(".saswp-post-specific-schema-ids").val())var t=JSON.parse(s(".saswp-post-specific-schema-ids").val());s.post(ajaxurl,{action:"saswp_restore_schema",schema_ids:t,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(s){"t"==s.status?setTimeout(function(){location.reload()},1e3):(alert(s.msg),setTimeout(function(){location.reload()},1e3)),e.removeClass("updating-message")},"json")}),s(document).on("click","div.saswp-tab ul.saswp-tab-nav a",function(a){a.preventDefault();var e=s(this).attr("data-id");s(".saswp-post-specific-wrapper").hide(),s("#"+e).show(),s("div.saswp-tab ul.saswp-tab-nav a").removeClass("selected"),s("div.saswp-tab ul.saswp-tab-nav li").removeClass("selected"),s(this).addClass("selected"),s(this).parent().addClass("selected"),saswp_enable_rating_review()}),s("#saswp-global-tabs a:first").addClass("saswp-global-selected"),s(".saswp-global-container").hide(),"#saswp-default-container"==window.location.hash?s(".saswp-global-container:eq(2)").show():s(".saswp-global-container:first").show(),s("#saswp-global-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-global-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-global-container").hide(),s("#"+a).show())}),s("#saswp-tools-tabs a:first").addClass("saswp-global-selected"),s(".saswp-tools-container").hide(),s(".saswp-tools-container:first").show(),s("#saswp-tools-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-tools-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-tools-container").hide(),s("#"+a).show())}),s("#saswp-review-tabs a:first").addClass("saswp-global-selected"),s(".saswp-review-container").hide(),s(".saswp-review-container:first").show(),s("#saswp-review-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-review-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-review-container").hide(),s("#"+a).show())}),s("#saswp-compatibility-tabs a:first").addClass("saswp-global-selected"),s(".saswp-compatibility-container").hide(),s(".saswp-compatibility-container:first").show(),s("#saswp-compatibility-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-compatibility-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-compatibility-container").hide(),s("#"+a).show())}),s('a[href="'+saswp_localize_data.new_url_selector+'"]').attr("href",saswp_localize_data.new_url_href),s(".saswp-enable-modify-schema-output").on("change",function(){s(".saswp-static-container").addClass("saswp_hide"),s(".saswp-dynamic-container").addClass("saswp_hide"),"manual"==s(this).val()&&(s(".saswp-static-container").removeClass("saswp_hide"),s(".saswp-dynamic-container").addClass("saswp_hide")),"automatic"==s(this).val()&&(s(".saswp-static-container").addClass("saswp_hide"),s(".saswp-dynamic-container").removeClass("saswp_hide"))}),s(document).on("change",".saswp-custom-fields-name",function(){var a="text",e=s(this).parent().parent("tr"),t=s(this).val();-1==t.indexOf("_image")&&-1==t.indexOf("_logo")||(a="image");var i=s(this).parent().parent("tr").find("td:eq(1)");saswp_get_meta_list(null,a,null,i,t,e)}),s(document).on("click",".saswp-skip-button",function(a){a.preventDefault(),s(this).parent().parent().hide(),s.post(ajaxurl,{action:"saswp_skip_wizard",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(s){},"json")}),s(document).on("click",".saswp_add_schema_fields_on_fly",function(a){a.preventDefault();var e=s(this);e.addClass("updating-message");var t=s(this).attr("data-id"),i=s(this).attr("fields_type"),p=s(this).attr("div_type"),c=s(this).attr("itemlist_sub_type"),o=s("saswp_specific_"+t+" , .saswp-"+p+"-table-div").length,n=s("saswp_specific_"+t+" , .saswp-"+p+"-table-div:nth-child("+o+")").attr("data-id");(n=++n)||(n=0),saswp_get_post_specific_schema_fields(e,n,i,p,t,i+"_",c)}),s(document).on("click",".saswp-table-close",function(){s(this).parent().remove()}),s(document).on("click",".saswp-rmv-modify_row",function(a){a.preventDefault(),s(this).parent().parent().remove()}),s(document).on("change",".saswp-custom-meta-list",function(){var a=s(this),e=s("select#schema_type option:selected").val(),t=s(this).val(),i=s(this).parent().parent("tr").find(".saswp-custom-fields-name").val(),p="",c=e.toLowerCase()+"_"+i,o="saswp_fixed_image["+i+"]";"manual_text"==t?(p+='<td><input type="text" name="saswp_fixed_text['+i+']"></td>',p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2()):"taxonomy_term"==t?saswp_taxonomy_term.taxonomy?(p+=saswp_taxonomy_term_html(saswp_taxonomy_term.taxonomy,i),a.parent().parent("tr").find("td:gt(1)").remove(),a.parent().parent("tr").append(p),saswpCustomSelect2()):s.get(ajaxurl,{action:"saswp_get_taxonomy_term_list",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(s){s&&(saswp_taxonomy_term.taxonomy=s,p+=saswp_taxonomy_term_html(s,i),a.parent().parent("tr").find("td:gt(1)").remove(),a.parent().parent("tr").append(p),saswpCustomSelect2())},"json"):"custom_field"==t?(p+='<td><select class="saswp-custom-fields-select2" name="saswp_custom_meta_field['+i+']">',p+="</select></td>",p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2()):"fixed_image"==t?(p+="<td>",p+="<fieldset>",p+='<input data-id="media" style="width: 30%;" class="button" id="'+c+'_button" name="'+c+'_button" type="button" value="Upload" />',p+='<input type="hidden" data-id="'+c+'_height" class="upload-height" name="'+o+'[height]" id="'+c+'_height" value="">',p+='<input type="hidden" data-id="'+c+'_width" class="upload-width" name="'+o+'[width]" id="'+c+'_width" value="">',p+='<input type="hidden" data-id="'+c+'_thumbnail" class="upload-thumbnail" name="'+o+'[thumbnail]" id="'+c+'_thumbnail" value="">',p+='<div class="saswp_image_div_'+c+'">',p+="</div>",p+="</fieldset>",p+="</td>",p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2()):(p+="<td></td>",p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2())}),s(document).on("change",".saswp-item-reivewed-list",function(){s(".saswp-custom-fields-table").html(""),saswp_meta_list_fields=[];var a=s(this),e=s("select#schema_type option:selected").val();saswp_item_reviewed_ajax(e,a,"manual")}),s(document).on("click",".saswp-add-custom-fields",function(){var a=s(this);a.addClass("updating-message");var e=s("select#schema_type option:selected").val(),t="",i=null;"Review"==e&&(t=s("select.saswp-item-reivewed-list option:selected").val(),i="saswp_review_name");var p=s("#post_ID").val();""!=e&&(saswp_meta_list_fields[e]?saswp_get_meta_list(a,"text",saswp_meta_list_fields[e],null,i,null):s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_get_schema_type_fields",post_id:p,schema_type:e,schema_subtype:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){saswp_meta_list_fields[e]=s,saswp_get_meta_list(a,"text",saswp_meta_list_fields[e],null,i,null)},error:function(s){console.log(s)}}))}),saswpCustomSelect2(),saswp_enable_rating_review(),s('a[href="'+saswp_localize_data.collection_post_add_url+'"]').attr("href",saswp_localize_data.collection_post_add_new_url),s(document).on("click",".saswp_coonect_google_place",function(){var a=s("#saswp_google_place_id").val(),e=s("#saswp_language_list").val(),t=s("#saswp_googel_api").val();""!=a&&s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_connect_google_place",place_id:a,language:e,google_api:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){console.log(s.status)},error:function(s){console.log(s)}})}),s(document).on("click",".saswp-add-social-links",function(){s(".saswp-social-links-table").append('<tr><td><input type="text" placeholder="https://www.facebook.com/profile" name="sd_data[saswp_social_links][]" value=""></td><td><a class="button button-default saswp-rmv-modify_row">X</a></td></tr>')}),s(document).on("click",".saswp-show-accept-rv-popup",function(){tb_show("Reviews Form","#TB_inline??width=600&height=400&inlineId=saswp-accept-reviews-popup"),s(document).find("#TB_window").width(600).height(400).css({top:"100px","margin-top":"0px"})}),("saswp_reviews"==saswp_localize_data.post_type||"saswp-collections"==saswp_localize_data.post_type)&&"edit.php"==saswp_localize_data.page_now){var i='<div class="saswp-custom-post-tab">';i+='<div style="display:none;" id="saswp-accept-reviews-popup">',i+='<div class="saswp-accept-rv-container">',i+="<p>Use Below shortcode to show reviews form in your website. Using this you can accept reviews from your website directly</p>",i+='<div class="saswp-show-form-on-tab"><strong>Simple Form</strong> <input value="[saswp-reviews-form]" type="text" readonly></div>',i+='<div class="saswp-show-form-on-tab"><strong>Show form on button tap</strong> <input value="[saswp-reviews-form onbutton="1"]" type="text" readonly></div>',i+="</div>",i+="</div>",i+='<h2 class="nav-tab-wrapper">',i+="<a href="+saswp_localize_data.reviews_page_url+' class="nav-tab '+(saswp_localize_data.current_url==saswp_localize_data.reviews_page_url?"saswp-global-selected":"")+'">Reviews</a>',i+="<a href="+saswp_localize_data.collections_page_url+' class="nav-tab '+(saswp_localize_data.current_url==saswp_localize_data.collections_page_url?"saswp-global-selected":"")+'">Collections</a>',i+='<a class="nav-tab saswp-show-accept-rv-popup">Accept Reviews</a>',i+="</h2>",i+="</div>",jQuery(jQuery(".wrap")).prepend(i)}"saswp"==saswp_localize_data.post_type&&"edit.php"==saswp_localize_data.page_now&&jQuery(jQuery(".wrap a")[0]).after("<a href='"+saswp_localize_data.saswp_settings_url+"' id='' class='page-title-action'>Settings</a>"),"undefined"!=typeof saswp_reviews_data&&(console.log(saswp_reviews_data.rating_val),s(".saswp-rating-div").rateYo({spacing:"5px",rating:saswp_reviews_data.rating_val,readOnly:saswp_reviews_data.readonly,onSet:function(a,e){s(this).next().next().val(a)}}).on("rateyo.change",function(a,e){var t=e.rating;s(this).next().text(t)})),s("#sd-person-phone-number, #saswp_kb_telephone").focusout(function(){var a=s(this);a.parent().find(".saswp-phone-validation").remove();var e=s(this).val();/^\+([0-9]{1,3})\)?[-. ]?([0-9]{2,4})[-. ]?([0-9]{2,4})[-. ]?([0-9]{2,4})$/.test(e)?a.parent().find(".saswp-phone-validation").remove():a.after('<span style="color:red;" class="saswp-phone-validation">Invalid Phone Number</span>')}),saswpCollectionSlider(),s(document).on("click",".saswp-grid-page",function(a){a.preventDefault(),saswp_grid_page=s(this).attr("data-id"),saswp_on_collection_design_change()}),s("#saswp-coll-pagination").change(function(){saswp_grid_page=1,s("#saswp-coll-per-page").parent().addClass("saswp_hide_imp"),s(this).is(":checked")&&s("#saswp-coll-per-page").parent().removeClass("saswp_hide_imp"),saswp_on_collection_design_change()}),s(".saswp-accordion").click(function(){s(this).toggleClass("active"),s(this).next(".saswp-accordion-panel").slideToggle(200)}),s(document).on("click",".saswp-opn-cls-btn",function(){s("#saswp-reviews-cntn").toggle(),s("#saswp-reviews-cntn").is(":visible")?(s(".saswp-onclick-show").css("display","flex"),s(".saswp-onclick-hide").hide(),s(".saswp-open-class").css("width","500px")):(s(".saswp-onclick-show").css("display","none"),s(".saswp-onclick-hide").show(),s(".saswp-open-class").css("width","300px"))}),s(".saswp-collection-display-method").change(function(){"shortcode"==s(this).val()?s(".saswp-collection-shortcode").removeClass("saswp_hide"):s(".saswp-collection-shortcode").addClass("saswp_hide")}).change(),s(document).on("click",".saswp-remove-platform",function(a){a.preventDefault();var e=s(this).attr("platform-id");saswp_collection.splice(e,1),s(this).parent().remove(),saswp_on_collection_design_change()}),s(".saswp-number-change").bind("keyup mouseup",function(){saswp_on_collection_design_change()}),s(".saswp-coll-settings-options").change(function(){saswp_grid_page=1;var a=s(".saswp-collection-desing").val();s(".saswp-coll-options").addClass("saswp_hide"),s(".saswp-collection-lp").css("height","auto"),"grid"==a&&s(".saswp-grid-options").removeClass("saswp_hide"),"gallery"==a&&s(".saswp-slider-options").removeClass("saswp_hide"),"fomo"==a&&(s(".saswp-fomo-options").removeClass("saswp_hide"),s(".saswp-collection-lp").css("height","31px")),"popup"==a&&s(".saswp-collection-lp").css("height","31px"),saswp_on_collection_design_change()}).change(),s(".saswp-add-to-collection").on("click",function(a){a.preventDefault();var e=s(this),t=s("#saswp-plaftorm-list").val(),i=s("#saswp-review-count").val();t&&i>0?(e.addClass("updating-message"),saswp_get_collection_data(i,t,e)):alert("Enter Count")});var p,c,o=s("#saswp_collection_id").val();o&&(s(".spinner").addClass("is-active"),s.get(ajaxurl,{action:"saswp_get_collection_platforms",collection_id:o,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){if(a.status){var e=a.message;s.each(e,function(s,a){saswp_get_collection_data(a,s,null)})}s(".spinner").removeClass("is-active")},"json")),(p=document.createElement("div")).style.cssText="position:absolute; background:black; color:white; padding:4px 6px;z-index:10000;border-radius:2px; font-size:12px;box-shadow:3px 3px 3px rgba(0,0,0,.4);opacity:0;transition:opacity 0.3s",p.innerHTML="Copied!",document.body.appendChild(p);var n=document.getElementById("motivatebox");n&&n.addEventListener("mouseup",function(s){var a=(s=s||event).target||s.srcElement;"motivate"==a.className&&(!function(s){var a=document.createRange();a.selectNodeContents(s);var e=window.getSelection();e.removeAllRanges(),e.addRange(a)}(a),function(){var s;try{s=document.execCommand("copy")}catch(a){s=!1}return s}()&&function(s){var a=s||event;clearTimeout(c),p.style.left=a.pageX-10+"px",p.style.top=a.pageY+15+"px",p.style.opacity=1,c=setTimeout(function(){p.style.opacity=0},500)}(s))},!1)});
|
1 |
+
var saswp_attached_rv=[],saswp_attached_col=[];jQuery(document).ready(function(s){if(s(document).on("click",".saswp-dismiss-notices",function(){var a=s(this),e=s(this).attr("notice-type");e&&s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_dismiss_notices",notice_type:e,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){"t"==s.status&&a.parent().parent().hide()},error:function(s){console.log(s)}})}),saswp_select2(),s(".saswp-upgrade-to-pro").parent().attr({href:"https://structured-data-for-wp.com/pricing/",target:"_blank"}),s(document).on("click",".saswp-attach-reviews",function(){s(".saswp-enable-append-reviews").is(":checked")?(tb_show(saswp_localize_data.translable_txt.attach_review,"#TB_inline??width=615&height=400&inlineId=saswp-embed-code-div"),s(document).find("#TB_window").width(600).height(415).css({top:"200px","margin-top":"0px"}),s(".saswp-attached-rv-count").show()):s(".saswp-attached-rv-count").hide()}),s(".close-attached-reviews-popup").on("click",function(){s("#TB_closeWindowButton").trigger("click")}),s("#saswp_attahced_reviews").val()&&(saswp_attached_rv=JSON.parse(s("#saswp_attahced_reviews").val())),s("#saswp_attached_collection").val()&&(saswp_attached_col=JSON.parse(s("#saswp_attached_collection").val())),s(document).on("click",".saswp-attach-rv-checkbox",function(){var a;a=parseInt(s(this).parent().attr("data-id"));var e=s(this).parent().attr("data-type");s(this).is(":checked")?("review"==e&&saswp_attached_rv.push(a),"collection"==e&&saswp_attached_col.push(a)):("review"==e&&saswp_attached_rv.splice(saswp_attached_rv.indexOf(a),1),"collection"==e&&saswp_attached_col.splice(saswp_attached_col.indexOf(a),1));var t=saswp_attached_rv.length,i=saswp_attached_col.length,p="";t>0&&(p+=t+" Reviews, "),i>0&&(p+=i+" Collection"),p||(p=0),s(".saswp-attached-rv-count").text("Attached "+p),s("#saswp_attahced_reviews").val(JSON.stringify(saswp_attached_rv)),s("#saswp_attached_collection").val(JSON.stringify(saswp_attached_col))}),s(".saswp-load-more-rv").on("click",function(a){var e=s(this).attr("data-type"),t=s(".saswp-add-rv-loop[data-type="+e+"]").length,i=t/10+1;s("#saswp-add-rv-automatic .spinner").addClass("is-active"),a.preventDefault(),s.get(ajaxurl,{action:"saswp_get_reviews_on_load",data_type:e,offset:t,paged:i,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){if("t"==a.status){var t="";a.result&&(s.each(a.result,function(s,a){var i="";"review"==e&&saswp_attached_rv.includes(parseInt(a.saswp_review_id))&&(i="checked"),"collection"==e&&saswp_attached_col.includes(parseInt(a.saswp_review_id))&&(i="checked"),t+='<div class="saswp-add-rv-loop" data-type="'+e+'" data-id="'+a.saswp_review_id+'">',"review"==e&&(t+='<input class="saswp-attach-rv-checkbox" type="checkbox" '+i+"> <strong> "+a.saswp_reviewer_name+" ( Rating - "+a.saswp_review_rating+' ) <span class="saswp-g-plus"><img src="'+a.saswp_review_platform_icon+'"/></span></strong>'),"collection"==e&&(t+='<input class="saswp-attach-rv-checkbox" type="checkbox" '+i+"> <strong> "+a.saswp_reviewer_name+" </strong>"),t+="</div>"}),s(".saswp-add-rv-automatic-list[data-type="+e+"]").append(t)),a.message&&(s(".saswp-rv-not-found[data-type="+e+"]").removeClass("saswp_hide"),s(".saswp-load-more-rv[data-type="+e+"]").addClass("saswp_hide"))}else alert(a.message);s("#saswp-add-rv-automatic .spinner").removeClass("is-active")},"json")}),s(".saswp-modify-schema-toggle").click(function(a){a.preventDefault(),s(".saswp-modify-container").slideToggle("300");var e=s("#saswp_enable_custom_field"),t=e.val();e.val("1"===t?"0":"1"),s(".saswp-enable-modify-schema-output").change()}),s(".saswp-enable-itemlist").change(function(){s(this).is(":checked")?(s("#saswp_item_list_tags").show(),s(".saspw-item-list-note").show(),"custom"==s("#saswp_item_list_tags").val()?s("#saswp_item_list_custom").show():s("#saswp_item_list_custom").hide()):(s(".saspw-item-list-note").hide(),s("#saswp_item_list_tags").hide(),s("#saswp_item_list_custom").hide())}),s("#saswp_item_list_tags").change(function(){"custom"==s(this).val()?s("#saswp_item_list_custom").show():s("#saswp_item_list_custom").hide()}),s(document).on("click",".saswp-add-g-location-btn",function(a){var e="";e=s("#saswp_google_place_api_key").length?'<input class="saswp-g-blocks-field" name="sd_data[saswp_reviews_location_blocks][]" type="number" min="5" step="5" placeholder="5" disabled="disabled">':'<input class="saswp-g-blocks-field" name="sd_data[saswp_reviews_location_blocks][]" type="number" min="10" step="10" placeholder="10">',a.preventDefault();var t="";(t+='<tr><td style="width:12%;"><strong>'+saswp_localize_data.translable_txt.place_id+'</strong></td><td style="width:20%;"><input class="saswp-g-location-field" name="sd_data[saswp_reviews_location_name][]" type="text" value=""></td><td style="width:10%;"><strong>'+saswp_localize_data.translable_txt.reviews+'</strong></td><td style="width:10%;">'+e+'</td><td style="width:10%;"><a class="button button-default saswp-fetch-g-reviews">'+saswp_localize_data.translable_txt.fetch+'</a></td><td style="width:10%;"><a type="button" class="saswp-remove-review-item button">x</a></td><td style="width:10%;"><p class="saswp-rv-fetched-msg"></p></td></tr>')&&s(".saswp-g-reviews-settings-table").append(t)}),s(document).on("click",".saswp-fetch-g-reviews",function(){var a=s(this),e="free";a.addClass("updating-message");var t=s(this).parent().parent().find(".saswp-g-location-field").val(),i=s(this).parent().parent().find(".saswp-g-blocks-field").val(),p=s("#saswp_google_place_api_key").val(),c=s("#reviews_addon_license_key").val(),o=s("#reviews_addon_license_key_status").val();if("premium"==(e=s("#saswp_google_place_api_key").length?"free":"premium")){if(!(i>0))return alert(saswp_localize_data.translable_txt.blocks_zero),a.removeClass("updating-message"),!1;if(0!=i%10)return a.parent().parent().find(".saswp-rv-fetched-msg").text(saswp_localize_data.translable_txt.step_in),a.parent().parent().find(".saswp-rv-fetched-msg").css("color","#988f1b"),a.removeClass("updating-message"),!1}""!=t&&(c||p)?s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_fetch_google_reviews",reviews_api_status:o,reviews_api:c,location:t,blocks:i,g_api:p,premium_status:e,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){"t"==s.status?(a.parent().parent().find(".saswp-rv-fetched-msg").text(saswp_localize_data.translable_txt.success),a.parent().parent().find(".saswp-rv-fetched-msg").css("color","green")):(a.parent().parent().find(".saswp-rv-fetched-msg").text(s.message),a.parent().parent().find(".saswp-rv-fetched-msg").css("color","#988f1b")),a.removeClass("updating-message")},error:function(s){console.log(s)}}):(""==t&&alert(saswp_localize_data.translable_txt.enter_place_id),""==p&&alert(saswp_localize_data.translable_txt.enter_api_key),""==c&&alert(saswp_localize_data.translable_txt.enter_rv_api_key),a.removeClass("updating-message"))}),saswp_localize_data.do_tour){var a,e="<h3>"+saswp_localize_data.translable_txt.using_schema+"</h3>";e+="<p>"+saswp_localize_data.translable_txt.do_you_want+" <b>"+saswp_localize_data.translable_txt.sd_update+"</b> "+saswp_localize_data.translable_txt.before_others+"</p>",e+='<style type="text/css">',e+=".wp-pointer-buttons{ padding:0; overflow: hidden; }",e+=".wp-pointer-content .button-secondary{ left: -25px;background: transparent;top: 5px; border: 0;position: relative; padding: 0; box-shadow: none;margin: 0;color: #0085ba;} .wp-pointer-content .button-primary{ display:none} #saswp_mc_embed_signup{background:#fff; clear:left; font:14px Helvetica,Arial,sans-serif; }",e+="</style>",e+='<div id="saswp_mc_embed_signup">',e+='<form method="POST" accept-charset="utf-8" id="saswp-news-letter-form">',e+='<div id="saswp_mc_embed_signup_scroll">',e+='<div class="saswp-mc-field-group" style=" margin-left: 15px; width: 195px; float: left;">',e+='<input type="text" name="saswp_subscriber_name" class="form-control" placeholder="Name" hidden value="'+saswp_localize_data.current_user_name+'" style="display:none">',e+='<input type="text" value="'+saswp_localize_data.current_user_email+'" name="saswp_subscriber_email" class="form-control" placeholder="Email*" style=" width: 180px; padding: 6px 5px;">',e+='<input type="text" name="saswp_subscriber_website" class="form-control" placeholder="Website" hidden style=" display:none; width: 168px; padding: 6px 5px;" value="'+saswp_localize_data.get_home_url+'">',e+='<input type="hidden" name="ml-submit" value="1" />',e+="</div>",e+='<div id="mce-responses">',e+="</div>",e+='<div style="position: absolute; left: -5000px;" aria-hidden="true"><input type="text" name="b_a631df13442f19caede5a5baf_c9a71edce6" tabindex="-1" value=""></div>',e+='<input type="submit" value="Subscribe" name="subscribe" id="pointer-close" class="button mc-newsletter-sent" style=" background: #0085ba; border-color: #006799; padding: 0px 16px; text-shadow: 0 -1px 1px #006799,1px 0 1px #006799,0 1px 1px #006799,-1px 0 1px #006799; height: 30px; margin-top: 1px; color: #fff; box-shadow: 0 1px 0 #006799;">',e+='<p id="saswp-news-letter-status"></p>',e+="</div>",e+="</form>",e+="</div>",s(document).on("submit","#saswp-news-letter-form",function(a){a.preventDefault();var e=s(this),t=e.find('input[name="saswp_subscriber_name"]').val(),i=e.find('input[name="saswp_subscriber_email"]').val();website=e.find('input[name="saswp_subscriber_website"]').val(),s.post(saswp_localize_data.ajax_url,{action:"saswp_subscribe_to_news_letter",saswp_security_nonce:saswp_localize_data.saswp_security_nonce,name:t,email:i,website:website},function(a){a?"Some fields are missing."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):"Invalid email address."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):"Invalid list ID."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):"Already subscribed."==a?(s("#saswp-news-letter-status").text(""),s("#saswp-news-letter-status").css("color","red")):(s("#saswp-news-letter-status").text("You're subscribed!"),s("#saswp-news-letter-status").css("color","green")):alert("Sorry, unable to subscribe. Please try again later!")})});var t={content:e,position:{edge:"top",align:"left"}};a=function(){s(saswp_localize_data.displayID).pointer(t).pointer("open"),saswp_localize_data.button2&&(jQuery("#pointer-close").after('<a id="pointer-primary" class="button-primary">'+saswp_localize_data.button2+"</a>"),jQuery("#pointer-primary").click(function(){saswp_localize_data.function_name}),jQuery("#pointer-close").click(function(){s.post(saswp_localize_data.ajax_url,{pointer:"saswp_subscribe_pointer",action:"dismiss-wp-pointer"})}))},(t=s.extend(t,{buttons:function(s,a){return button=jQuery('<a id="pointer-close" class="button-secondary">'+saswp_localize_data.button1+"</a>"),button_2=jQuery("#pointer-close.button"),button.bind("click.pointer",function(){a.element.pointer("close")}),button_2.on("click",function(){setTimeout(function(){a.element.pointer("close")},3e3)}),button},close:function(){s.post(saswp_localize_data.ajax_url,{pointer:"saswp_subscribe_pointer",action:"dismiss-wp-pointer"})},show:function(s,a){a.pointer.css({left:"170px",top:"160px"})}})).position&&t.position.defer_loading?s(window).bind("load.wp-pointers",a):a()}if(s(".saswp-tabs a").click(function(a){var e=s(this).attr("href"),t=getParameterByName("tab",e);return t||(t="general"),s(this).siblings().removeClass("nav-tab-active"),s(this).addClass("nav-tab-active"),s(".form-wrap").find(".saswp-"+t).siblings().hide(),s(".form-wrap .saswp-"+t).show(),window.history.pushState("","",e),!1}),s(".saswp-schame-type-select").select2(),s(".saswp-schame-type-select").change(function(a){a.preventDefault(),s(".saswp-custom-fields-table").html("");var e=s(this).val();s(".saswp-option-table-class tr").each(function(a,e){a>0&&s(this).hide()}),"TechArticle"==e||"Article"==e||"Blogposting"==e||"NewsArticle"==e||"WebPage"==e?s(".saswp-enable-speakable").parent().parent().show():s(".saswp-enable-speakable").parent().parent().hide(),"Book"==e||"Course"==e||"Organization"==e||"CreativeWorkSeries"==e||"MobileApplication"==e||"ImageObject"==e||"HowTo"==e||"MusicPlaylist"==e||"MusicAlbum"==e||"Recipe"==e||"TVSeries"==e||"SoftwareApplication"==e||"Event"==e||"VideoGame"==e||"Service"==e||"AudioObject"==e||"VideoObject"==e||"local_business"==e||"Product"==e||"Review"==e?s(".saswp-enable-append-reviews").parent().parent().show():s(".saswp-enable-append-reviews").parent().parent().hide(),"VideoObject"==e?s(".saswp-enable-markup-class").parent().parent().show():s(".saswp-enable-markup-class").parent().parent().hide(),"local_business"==e&&(s(".saswp-option-table-class tr").eq(1).show(),s(".saswp-business-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1),s(".select-post-type").val("show_globally").trigger("change")),"Service"==e&&(s(".saswp-service-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)),"Event"==e&&(s(".saswp-event-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)),"Review"==e&&(s(".saswp-review-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1),s(".saswp-item-reivewed-list").change()),"ItemList"==e?(s(".saswp-schema-modify-section").hide(),s(".saswp-itemlist-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1),s(".saswp-itemlist-item-type-list").change()):s(".saswp-schema-modify-section").show(),saswp_enable_rating_review(),s(".saswp-manual-modification").html(""),s(".saswp-static-container .spinner").addClass("is-active"),s.get(ajaxurl,{action:"saswp_get_manual_fields_on_ajax",schema_type:e,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){s(".saswp-static-container .spinner").removeClass("is-active"),s(".saswp-manual-modification").append(a),saswp_schema_datepicker(),saswp_schema_timepicker(),saswp_item_reviewed_call()}),"HowTo"==e||"local_business"==e||"FAQ"==e?s(".saswp-enable-modify-schema").show():(s(".saswp-enable-modify-schema-output").val("automatic"),s(".saswp-enable-modify-schema-output").change(),s(".saswp-enable-modify-schema").hide())}),s("#saswp_business_type").select2(),s(".saswp-local-sub-type-2").select2(),s("#saswp_business_type").change(function(){var a=s(this).val(),e=s(".saswp-schame-type-select").val();s(".saswp-option-table-class tr").each(function(a,e){a>1&&(s(this).hide(),s(this).find(".saswp-local-sub-type-2").attr("disabled",!0))}),"TechArticle"==e||"Article"==e||"Blogposting"==e||"NewsArticle"==e||"WebPage"==e?s(".saswp-enable-speakable").parent().parent().show():s(".saswp-enable-speakable").parent().parent().hide(),"Book"==e||"Course"==e||"Organization"==e||"CreativeWorkSeries"==e||"MobileApplication"==e||"ImageObject"==e||"HowTo"==e||"MusicPlaylist"==e||"MusicAlbum"==e||"Recipe"==e||"TVSeries"==e||"SoftwareApplication"==e||"Event"==e||"VideoGame"==e||"Service"==e||"AudioObject"==e||"VideoObject"==e||"local_business"==e||"Product"==e||"Review"==e?s(".saswp-enable-append-reviews").parent().parent().show():s(".saswp-enable-append-reviews").parent().parent().hide(),"VideoObject"==e?s(".saswp-enable-markup-class").parent().parent().show():s(".saswp-enable-markup-class").parent().parent().hide(),"local_business"==e&&(s(".saswp-"+a+"-tr").show(),s(".saswp-business-text-field-tr").show(),s(".saswp-"+a+"-tr").find("select").attr("disabled",!1)),"Review"==e&&(s(".saswp-review-text-field-tr").show(),s(".saswp-review-text-field-tr").find("select").attr("disabled",!1)),"ItemList"==e?(s(".saswp-schema-modify-section").hide(),s(".saswp-itemlist-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)):s(".saswp-schema-modify-section").show(),"Event"==e&&(s(".saswp-event-text-field-tr").show(),s(".saswp-option-table-class tr").find("select").attr("disabled",!1)),saswp_enable_rating_review()}).change(),s(".saswp-checkbox").change(function(){var a=s(this).attr("id"),e=s(this);switch(a){case"saswp-the-seo-framework-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-the-seo-framework").val(1):s("#saswp-the-seo-framework").val(0);break;case"saswp-seo-press-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-seo-press").val(1):s("#saswp-seo-press").val(0);break;case"saswp-aiosp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-aiosp").val(1):s("#saswp-aiosp").val(0);break;case"saswp-smart-crawl-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-smart-crawl").val(1):s("#saswp-smart-crawl").val(0);break;case"saswp-squirrly-seo-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-squirrly-seo").val(1):s("#saswp-squirrly-seo").val(0);break;case"saswp-wp-recipe-maker-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-recipe-maker").val(1):s("#saswp-wp-recipe-maker").val(0);break;case"saswp-wpzoom-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpzoom").val(1):s("#saswp-wpzoom").val(0);break;case"saswp-yotpo-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-yotpo").val(1):s("#saswp-yotpo").val(0);break;case"saswp-ultimate-blocks-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ultimate-blocks").val(1):s("#saswp-ultimate-blocks").val(0);break;case"saswp-starsrating-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-starsrating").val(1):s("#saswp-starsrating").val(0);break;case"saswp-wptastyrecipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wptastyrecipe").val(1):s("#saswp-wptastyrecipe").val(0);break;case"saswp-recipress-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-recipress").val(1):s("#saswp-recipress").val(0);break;case"saswp-wp-ultimate-recipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-ultimate-recipe").val(1):s("#saswp-wp-ultimate-recipe").val(0);break;case"saswp-zip-recipes-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-zip-recipes").val(1):s("#saswp-zip-recipes").val(0);break;case"saswp-mediavine-create-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-mediavine-create").val(1):s("#saswp-mediavine-create").val(0);break;case"saswp-ht-recipes-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ht-recipes").val(1):s("#saswp-ht-recipes").val(0);break;case"saswp-wpsso-core-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpsso-core").val(1):s("#saswp-wpsso-core").val(0);break;case"saswp-for-wordpress-checkbox":s(this).is(":checked")?s("#saswp-for-wordpress").val(1):s("#saswp-for-wordpress").val(0);break;case"saswp-for-amp-checkbox":s(this).is(":checked")?s("#saswp-for-amp").val(1):s("#saswp-for-amp").val(0);break;case"saswp_kb_contact_1_checkbox":s(this).is(":checked")?(s("#saswp_kb_contact_1").val(1),s("#saswp_kb_telephone, #saswp_contact_type").parent().parent("li").removeClass("saswp-display-none")):(s("#saswp_kb_contact_1").val(0),s("#saswp_kb_telephone, #saswp_contact_type").parent().parent("li").addClass("saswp-display-none"));break;case"saswp-logo-dimensions-check":s(this).is(":checked")?(s("#saswp-logo-dimensions").val(1),s("#saswp-logo-width, #saswp-logo-height").parent().parent("li").show()):(s("#saswp-logo-dimensions").val(0),s("#saswp-logo-width, #saswp-logo-height").parent().parent("li").hide());break;case"saswp_archive_schema_checkbox":s(this).is(":checked")?(s("#saswp_archive_schema").val(1),s(".saswp_archive_schema_type_class").parent().parent().show()):(s("#saswp_archive_schema").val(0),s(".saswp_archive_schema_type_class").parent().parent().hide());break;case"saswp_website_schema_checkbox":s(this).is(":checked")?(s("#saswp_website_schema").val(1),s("#saswp_search_box_schema").parent().parent().show()):(s("#saswp_website_schema").val(0),s("#saswp_search_box_schema").parent().parent().hide());break;case"saswp_search_box_schema_checkbox":s(this).is(":checked")?s("#saswp_search_box_schema").val(1):s("#saswp_search_box_schema").val(0);break;case"saswp_breadcrumb_schema_checkbox":s(this).is(":checked")?s("#saswp_breadcrumb_schema").val(1):s("#saswp_breadcrumb_schema").val(0);break;case"saswp_comments_schema_checkbox":s(this).is(":checked")?s("#saswp_comments_schema").val(1):s("#saswp_comments_schema").val(0);break;case"saswp-compativility-checkbox":s(this).is(":checked")?s("#saswp-flexmlx-compativility").val(1):s("#saswp-flexmlx-compativility").val(0);break;case"saswp-review-module-checkbox":s(this).is(":checked")?s("#saswp-review-module").val(1):s("#saswp-review-module").val(0);break;case"saswp-stars-rating-checkbox":s(this).is(":checked")?(s(".saswp-stars-post-table").removeClass("saswp_hide"),s("#saswp-stars-rating").val(1)):(s(".saswp-stars-post-table").addClass("saswp_hide"),s("#saswp-stars-rating").val(0));break;case"saswp-kk-star-raring-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-kk-star-raring").val(1):s("#saswp-kk-star-raring").val(0);break;case"saswp-wpdiscuz-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpdiscuz").val(1):s("#saswp-wpdiscuz").val(0);break;case"saswp-yet-another-stars-rating-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-yet-another-stars-rating").val(1):s("#saswp-yet-another-stars-rating").val(0);break;case"saswp-simple-author-box-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-simple-author-box").val(1):s("#saswp-simple-author-box").val(0);break;case"saswp-woocommerce-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-woocommerce").val(1):s("#saswp-woocommerce").val(0);break;case"saswp-default-review-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp_default_review").val(1):s("#saswp_default_review").val(0);break;case"saswp-extra-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-extra").val(1):s("#saswp-extra").val(0);break;case"saswp-soledad-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-soledad").val(1):s("#saswp-soledad").val(0);break;case"saswp-wp-theme-reviews-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-theme-reviews").val(1):s("#saswp-wp-theme-reviews").val(0);break;case"saswp-dw-question-answer-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-dw-question-answer").val(1):s("#saswp-dw-question-answer").val(0);break;case"saswp-wp-job-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-job-manager").val(1):s("#saswp-wp-job-manager").val(0);break;case"saswp-yoast-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-yoast").val(1):s("#saswp-yoast").val(0);break;case"saswp-polylang-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-polylang").val(1):s("#saswp-polylang").val(0);break;case"saswp-metatagmanager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-metatagmanager").val(1):s("#saswp-metatagmanager").val(0);break;case"saswp-slimseo-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-slimseo").val(1):s("#saswp-slimseo").val(0);break;case"saswp-rankmath-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-rankmath").val(1):s("#saswp-rankmath").val(0);break;case"saswp-taqyeem-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-taqyeem").val(1):s("#saswp-taqyeem").val(0);break;case"saswp-video-thumbnails-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-video-thumbnails").val(1):s("#saswp-video-thumbnails").val(0);break;case"saswp-featured-video-plus-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-featured-video-plus").val(1):s("#saswp-featured-video-plus").val(0);break;case"saswp-wp-product-review-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-product-review").val(1):s("#saswp-wp-product-review").val(0);break;case"saswp-the-events-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-the-events-calendar").val(1):s("#saswp-the-events-calendar").val(0);break;case"saswp-homeland-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-homeland").val(1):s("#saswp-homeland").val(0);break;case"saswp-ratency-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ratency").val(1):s("#saswp-ratency").val(0);break;case"saswp-wpresidence-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpresidence").val(1):s("#saswp-wpresidence").val(0);break;case"saswp-myhome-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-myhome").val(1):s("#saswp-myhome").val(0);break;case"saswp-realestate-5-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-realestate-5").val(1):s("#saswp-realestate-5").val(0);break;case"saswp-stamped-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-stamped").val(1):s("#saswp-stamped").val(0);break;case"saswp-sabaidiscuss-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-sabaidiscuss").val(1):s("#saswp-sabaidiscuss").val(0);break;case"saswp-geodirectory-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-geodirectory").val(1):s("#saswp-geodirectory").val(0);break;case"saswp-classipress-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-classipress").val(1):s("#saswp-classipress").val(0);break;case"saswp-realhomes-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-realhomes").val(1):s("#saswp-realhomes").val(0);break;case"saswp-learn-press-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-learn-press").val(1):s("#saswp-learn-press").val(0);break;case"saswp-wplms-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wplms").val(1):s("#saswp-wplms").val(0);break;case"saswp-learn-dash-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-learn-dash").val(1):s("#saswp-learn-dash").val(0);break;case"saswp-lifter-lms-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-lifter-lms").val(1):s("#saswp-lifter-lms").val(0);break;case"saswp-senseilms-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-senseilms").val(1):s("#saswp-senseilms").val(0);break;case"saswp-wp-event-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-event-manager").val(1):s("#saswp-wp-event-manager").val(0);break;case"saswp-events-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-events-manager").val(1):s("#saswp-events-manager").val(0);break;case"saswp-event-calendar-wd-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-event-calendar-wd").val(1):s("#saswp-event-calendar-wd").val(0);break;case"saswp-event-organiser-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-event-organiser").val(1):s("#saswp-event-organiser").val(0);break;case"saswp-modern-events-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-modern-events-calendar").val(1):s("#saswp-modern-events-calendar").val(0);break;case"saswp-woocommerce-booking-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?(s("#saswp-woocommerce-booking").val(1),s("#saswp-woocommerce-booking-main").val(1)):(s("#saswp-woocommerce-booking").val(0),s("#saswp-woocommerce-booking-main").val(0));break;case"saswp-woocommerce-booking-main-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?(s("#saswp-woocommerce-booking-main").val(1),s("#saswp-woocommerce-booking").val(1)):(s("#saswp-woocommerce-booking-main").val(0),s("#saswp-woocommerce-booking").val(0));break;case"saswp-woocommerce-membership-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-woocommerce-membership").val(1):s("#saswp-woocommerce-membership").val(0);break;case"saswp-defragment-checkbox":s(this).is(":checked")?s("#saswp-defragment").val(1):s("#saswp-defragment").val(0);break;case"saswp-cooked-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-cooked").val(1):s("#saswp-cooked").val(0);break;case"saswp-flexmlx-compativility-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-flexmlx-compativility").val(1):s("#saswp-flexmlx-compativility").val(0);break;case"saswp-shopper-approved-review-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?(s("#saswp-shopper-approved-review").val(1),s(".saswp-s-reviews-settings-table").parent().parent().parent().show()):(s("#saswp-shopper-approved-review").val(0),s(".saswp-s-reviews-settings-table").parent().parent().parent().hide());break;case"saswp-google-review-checkbox":s(this).is(":checked")?(s("#saswp-google-review").val(1),s("#saswp-google-rv-free-checkbox").length?(s("#saswp-google-review-free").parent().parent().show(),s("#saswp-google-rv-free-checkbox").is(":checked")?s("#saswp_google_place_api_key").parent().parent().show():s("#saswp_google_place_api_key").parent().parent().hide()):s("#saswp_google_place_api_key").parent().parent().show(),s(".saswp-g-reviews-settings-table").parent().parent().parent().show()):(s("#saswp-google-review").val(0),s("#saswp_google_place_api_key").parent().parent().hide(),s(".saswp-g-reviews-settings-table").parent().parent().parent().hide(),s("#saswp-google-rv-free-checkbox").length&&s("#saswp-google-review-free").parent().parent().hide());break;case"saswp-google-rv-free-checkbox":s("#saswp-google-review-checkbox").is(":checked")&&s(this).is(":checked")?(s("#saswp-google-review-free").val(1),s("#saswp_google_place_api_key").parent().parent().show()):(s("#saswp-google-review-free").val(0),s("#saswp_google_place_api_key").parent().parent().hide());break;case"saswp-markup-footer-checkbox":s(this).is(":checked")?s("#saswp-markup-footer").val(1):s("#saswp-markup-footer").val(0);break;case"saswp-pretty-print-checkbox":s(this).is(":checked")?s("#saswp-pretty-print").val(1):s("#saswp-pretty-print").val(0);break;case"saswp-wppostratings-raring-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wppostratings-raring").val(1):s("#saswp-wppostratings-raring").val(0);break;case"saswp-bbpress-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-bbpress").val(1):s("#saswp-bbpress").val(0);break;case"saswp-microdata-cleanup-checkbox":s(this).is(":checked")?s("#saswp-microdata-cleanup").val(1):s("#saswp-microdata-cleanup").val(0);break;case"saswp-other-images-checkbox":s(this).is(":checked")?s("#saswp-other-images").val(1):s("#saswp-other-images").val(0);break;case"saswp-rss-feed-image-checkbox":s(this).is(":checked")?s("#saswp-rss-feed-image").val(1):s("#saswp-rss-feed-image").val(0);break;case"saswp-multiple-size-image-checkbox":s(this).is(":checked")?s("#saswp-multiple-size-image").val(1):s("#saswp-multiple-size-image").val(0);break;case"saswp-easy-testimonials-checkbox":s(this).is(":checked")?s("#saswp-easy-testimonials").val(1):s("#saswp-easy-testimonials").val(0);break;case"saswp-testimonial-pro-checkbox":s(this).is(":checked")?s("#saswp-testimonial-pro").val(1):s("#saswp-testimonial-pro").val(0);break;case"saswp-bne-testimonials-checkbox":s(this).is(":checked")?s("#saswp-bne-testimonials").val(1):s("#saswp-bne-testimonials").val(0);break;case"saswp-ampforwp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ampforwp").val(1):s("#saswp-ampforwp").val(0);break;case"saswp-ampbyautomatic-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ampbyautomatic").val(1):s("#saswp-ampbyautomatic").val(0);break;case"saswp-rannarecipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-rannarecipe").val(1):s("#saswp-rannarecipe").val(0);break;case"saswp-quickandeasyfaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-quickandeasyfaq").val(1):s("#saswp-quickandeasyfaq").val(0);break;case"saswp-ultimatefaqs-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ultimatefaqs").val(1):s("#saswp-ultimatefaqs").val(0);break;case"saswp-arconixfaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-arconixfaq").val(1):s("#saswp-arconixfaq").val(0);break;case"saswp-faqconcertina-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-faqconcertina").val(1):s("#saswp-faqconcertina").val(0);break;case"saswp-wpjobmanager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpjobmanager").val(1):s("#saswp-wpjobmanager").val(0);break;case"saswp-simplejobboard-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-simplejobboard").val(1):s("#saswp-simplejobboard").val(0);break;case"saswp-wpjobopenings-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpjobopenings").val(1):s("#saswp-wpjobopenings").val(0);break;case"saswp-webfaq10-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-webfaq10").val(1):s("#saswp-webfaq10").val(0);break;case"saswp-wpfaqschemamarkup-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpfaqschemamarkup").val(1):s("#saswp-wpfaqschemamarkup").val(0);break;case"saswp-faqschemaforpost-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-faqschemaforpost").val(1):s("#saswp-faqschemaforpost").val(0);break;case"saswp-masteraccordion-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-masteraccordion").val(1):s("#saswp-masteraccordion").val(0);break;case"saswp-easyfaqs-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-easyfaqs").val(1):s("#saswp-easyfaqs").val(0);break;case"saswp-accordion-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-accordion").val(1):s("#saswp-accordion").val(0);break;case"saswp-html5responsivefaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-html5responsivefaq").val(1):s("#saswp-html5responsivefaq").val(0);break;case"saswp-wpresponsivefaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpresponsivefaq").val(1):s("#saswp-wpresponsivefaq").val(0);break;case"saswp-easyaccordion-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-easyaccordion").val(1):s("#saswp-easyaccordion").val(0);break;case"saswp-helpiefaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-helpiefaq").val(1):s("#saswp-helpiefaq").val(0);break;case"saswp-accordionfaq-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-accordionfaq").val(1):s("#saswp-accordionfaq").val(0);break;case"saswp-schemaforfaqs-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-schemaforfaqs").val(1):s("#saswp-schemaforfaqs").val(0);break;case"saswp-wp-customer-reviews-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-customer-reviews").val(1):s("#saswp-wp-customer-reviews").val(0);break;case"saswp-total-recipe-generator-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-total-recipe-generator").val(1):s("#saswp-total-recipe-generator").val(0);break;case"saswp-wordpress-news-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wordpress-news").val(1):s("#saswp-wordpress-news").val(0);break;case"saswp-ampwp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-ampwp").val(1):s("#saswp-ampwp").val(0);break;case"saswp-wp-event-aggregator-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wp-event-aggregator").val(1):s("#saswp-wp-event-aggregator").val(0);break;case"saswp-timetable-event-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-timetable-event").val(1):s("#saswp-timetable-event").val(0);break;case"saswp-xo-event-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-xo-event-calendar").val(1):s("#saswp-xo-event-calendar").val(0);break;case"saswp-vs-event-list-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-vs-event-list").val(1):s("#saswp-vs-event-list").val(0);break;case"saswp-calendarize-it-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-calendarize-it").val(1):s("#saswp-calendarize-it").val(0);break;case"saswp-events-schedule-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-events-schedule").val(1):s("#saswp-events-schedule").val(0);break;case"saswp-woo-event-manager-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-woo-event-manager").val(1):s("#saswp-woo-event-manager").val(0);break;case"saswp-stachethemes-event-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-stachethemes-event-calendar").val(1):s("#saswp-stachethemes-event-calendar").val(0);break;case"saswp-all-in-one-event-calendar-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-all-in-one-event-calendar").val(1):s("#saswp-all-in-one-event-calendar").val(0);break;case"saswp-event-on-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-event-on").val(1):s("#saswp-event-on").val(0);break;case"saswp-easy-recipe-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-easy-recipe").val(1):s("#saswp-easy-recipe").val(0);break;case"saswp-tevolution-events-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-tevolution-events").val(1):s("#saswp-tevolution-events").val(0);break;case"saswp-strong-testimonials-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-strong-testimonials").val(1):s("#saswp-strong-testimonials").val(0);break;case"saswp-wordlift-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wordlift").val(1):s("#saswp-wordlift").val(0);break;case"saswp-betteramp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-betteramp").val(1):s("#saswp-betteramp").val(0);break;case"saswp-wpamp-checkbox":saswp_compatibliy_notes(e,a),s(this).is(":checked")?s("#saswp-wpamp").val(1):s("#saswp-wpamp").val(0)}}).change(),s("#saswp_kb_type").change(function(){var a=s(this).val();s(".saswp_org_fields, .saswp_person_fields").parent().parent().addClass("saswp_hide"),s(".saswp_kg_logo").parent().parent().parent().addClass("saswp_hide"),s("#sd-person-image").parent().parent().parent().addClass("saswp_hide"),"Organization"==a&&(s(".saswp_org_fields").parent().parent().removeClass("saswp_hide"),s(".saswp_person_fields").parent().parent().addClass("saswp_hide"),s(".saswp_kg_logo").parent().parent().parent().removeClass("saswp_hide"),s("#sd-person-image").parent().parent().parent().addClass("saswp_hide")),"Person"==a&&(s(".saswp_org_fields").parent().parent().addClass("saswp_hide"),s(".saswp_person_fields").parent().parent().removeClass("saswp_hide"),s(".saswp_kg_logo").parent().parent().parent().removeClass("saswp_hide"),s("#sd-person-image").parent().parent().parent().removeClass("saswp_hide"))}).change(),s(document).on("click","input[data-id=media]",function(a){a.preventDefault();var e=s(this),t=e.attr("id").replace("_button",""),i=wp.media({title:"Application Icon",button:{text:"Select Icon"},multiple:!1,library:{type:"image"}}).on("select",function(){var a=i.state().get("selection").first().toJSON();s("#"+t).val(a.url),s("input[data-id='"+t+"_id']").val(a.id),s("input[data-id='"+t+"_height']").val(a.height),s("input[data-id='"+t+"_width']").val(a.width),s("input[data-id='"+t+"_thumbnail']").val(a.url),"sd_default_image_button"===e.attr("id")&&(s("#sd_default_image_width").val(a.width),s("#sd_default_image_height").val(a.height));var p="";"saswp_image_div_"+t=="saswp_image_div_sd_default_image"&&a.height<1200&&(p='<p class="saswp_warning">Image size is smaller than recommended size</p>'),s(".saswp_image_div_"+t).html('<div class="saswp_image_thumbnail"><img class="saswp_image_prev" src="'+a.url+'"/><a data-id="'+t+'" href="#" class="saswp_prev_close">X</a></div>'+p)}).open()}),s(document).on("click",".saswp_prev_close",function(a){a.preventDefault();var e=s(this).attr("data-id");s(this).parent().remove(),s("#"+e).val(""),s("input[data-id='"+e+"_id']").val(""),s("input[data-id='"+e+"_height']").val(""),s("input[data-id='"+e+"_width']").val(""),s("input[data-id='"+e+"_thumbnail']").val(""),"sd_default_image"===e&&(s("#sd_default_image_width").val(""),s("#sd_default_image_height").val(""))}),s(document).on("click",".saswp-modify-schema",function(a){a.preventDefault();var e=s(this).attr("schema-id"),t=s(this);t.addClass("updating-message"),s.get(ajaxurl,{action:"saswp_modify_schema_post_enable",schema_id:e,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){s(".saswp-post-specific-wrapper[data-id="+e+"] .saswp-post-specific-setting").after(a),s(".saswp_modify_this_schema_hidden_"+e).val(1),s(".saswp-ps-toggle[schema-id="+e+"]").removeClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().removeClass("saswp_hide"),s(".saswp-modify-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),t.removeClass("updating-message"),saswp_schema_datepicker(),saswp_schema_timepicker(),saswp_enable_rating_review(),saswp_item_reviewed_call()})}),s(document).on("click",".saswp-restore-schema",function(a){a.preventDefault();var e=s(this).attr("schema-id"),t=s(this);t.addClass("updating-message"),s.post(ajaxurl,{action:"saswp_modify_schema_post_restore",schema_id:e,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){t.removeClass("updating-message"),"t"==a.status?(s(".saswp_modify_this_schema_hidden_"+e).val(0),s(".saswp-restore-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),s(".saswp-modify-schema[schema-id="+e+"]").parent().removeClass("saswp_hide"),s(".saswp-ps-toggle[schema-id="+e+"]").remove()):alert("Something went wrong")},"json")}),s(document).on("change",".saswp-schema-type-toggle",function(a){var e=s(this).attr("data-schema-id"),t=s(this).attr("data-post-id"),i=s(".saswp_modify_this_schema_hidden_"+e).val();if(s(this).is(":checked")){var p=0;s(".saswp-ps-toggle[schema-id="+e+"]").addClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),s(".saswp-modify-schema[schema-id="+e+"]").parent().addClass("saswp_hide"),s("#saswp_custom_schema_field[schema-id="+e+"]").parent().addClass("saswp_hide")}else{s("#saswp_custom_schema_field[schema-id="+e+"]").parent().removeClass("saswp_hide"),1==i?(s(".saswp-ps-toggle[schema-id="+e+"]").removeClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().removeClass("saswp_hide")):(s(".saswp-modify-schema[schema-id="+e+"]").parent().removeClass("saswp_hide"),s(".saswp-ps-toggle[schema-id="+e+"]").addClass("saswp_hide"),s(".saswp-restore-schema[schema-id="+e+"]").parent().addClass("saswp_hide"));p=1}s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_enable_disable_schema_on_post",status:p,schema_id:e,post_id:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){},error:function(s){console.log(s)}})}),s(document).on("click",".saswp-reset-data",function(a){a.preventDefault(),1==confirm("Are you sure?")&&s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_reset_all_settings",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){setTimeout(function(){location.reload()},1e3)},error:function(s){console.log(s)}})}),s(document).on("click",".saswp_license_activation",function(a){a.preventDefault();var e=s(this);e.addClass("updating-message");var t=s(this).attr("license-status"),i=s(this).attr("add-on"),p=s("#"+i+"_addon_license_key").val();t&&i&&p?s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_license_status_check",license_key:p,license_status:t,add_on:i,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(a){s("#"+i+"_addon_license_key_status").val(a.status),"active"==a.status?(s(".saswp-"+i+"-dashicons").addClass("dashicons-yes"),s(".saswp-"+i+"-dashicons").removeClass("dashicons-no-alt"),s(".saswp-"+i+"-dashicons").css("color","green"),s(".saswp_license_activation[add-on='"+i+"']").attr("license-status","inactive"),s(".saswp_license_activation[add-on='"+i+"']").text("Deactivate"),s(".saswp_license_status_msg[add-on='"+i+"']").text("Activated"),s(".saswp_license_status_msg[add-on='"+i+"']").css("color","green"),s(".saswp_license_status_msg[add-on='"+i+"']").text(a.message)):(s(".saswp-"+i+"-dashicons").addClass("dashicons-no-alt"),s(".saswp-"+i+"-dashicons").removeClass("dashicons-yes"),s(".saswp-"+i+"-dashicons").css("color","red"),s(".saswp_license_activation[add-on='"+i+"']").attr("license-status","active"),s(".saswp_license_activation[add-on='"+i+"']").text("Activate"),s(".saswp_license_status_msg[add-on='"+i+"']").css("color","red"),s(".saswp_license_status_msg[add-on='"+i+"']").text(a.message)),e.removeClass("updating-message")},error:function(s){console.log(s)}}):(alert("Please enter value license key"),e.removeClass("updating-message"))}),s(".saswp-send-query").on("click",function(a){a.preventDefault();var e=s("#saswp_query_message").val(),t=s("#saswp_query_email").val(),i=s("#saswp_query_premium_cus").val();console.log(saswpIsEmail(t)),""!=s.trim(e)&&i&&""!=s.trim(t)&&1==saswpIsEmail(t)?s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_send_query_message",premium_cus:i,message:e,email:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(a){"t"==a.status?(s(".saswp-query-success").show(),s(".saswp-query-error").hide()):(s(".saswp-query-success").hide(),s(".saswp-query-error").show())},error:function(s){console.log(s)}}):""==s.trim(e)&&""==i&&""==s.trim(t)?alert("Please enter the message, email and select customer type"):(""==i&&alert("Select Customer type"),""==s.trim(e)&&alert("Please enter the message"),""==s.trim(t)&&alert("Please enter the email"),0==saswpIsEmail(t)&&alert("Please enter a valid email"))}),s(".saswp-import-plugins").on("click",function(a){a.preventDefault();var e=s(this);e.addClass("updating-message");var t=s(this).attr("data-id");s.get(ajaxurl,{action:"saswp_import_plugin_data",plugin_name:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){"t"==a.status?(s(e).parent().find(".saswp-imported-message").text(a.message),s(e).parent().find(".saswp-imported-message").removeClass("saswp-error"),setTimeout(function(){location.reload()},2e3)):(s(e).parent().find(".saswp-imported-message").addClass("saswp-error"),s(e).parent().find(".saswp-imported-message").text(a.message)),e.removeClass("updating-message")},"json")}),s(".saswp-feedback-no-thanks").on("click",function(a){a.preventDefault(),s.get(ajaxurl,{action:"saswp_feeback_no_thanks",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){"t"==a.status&&s(".saswp-feedback-notice").hide()},"json")}),s(".saswp-feedback-remindme").on("click",function(a){a.preventDefault(),s.get(ajaxurl,{action:"saswp_feeback_remindme",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){"t"==a.status&&s(".saswp-feedback-notice").hide()},"json")}),s(document).on("change",".saswp-local-business-type-select",function(a){a.preventDefault();var e=s(this),t=s(this).val();s.get(ajaxurl,{action:"saswp_get_sub_business_ajax",business_type:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){if("t"==a.status){s(".saswp-local-business-name-select").parents("tr").remove();var t=e.parents(".saswp-post-specific-wrapper").attr("data-id"),i='<tr><th><label for="saswp_business_name_'+t+'">Sub Business Type</label></th>';i+='<td><select class="saswp-local-business-name-select" id="saswp_business_name_'+t+'" name="saswp_business_name_'+t+'">',s.each(a.result,function(s,a){i+='<option value="'+s+'">'+a+"</option>"}),i+="</select></td>",i+="</tr>",e.parents(".form-table tr:first").after(i)}else s(".saswp-local-business-name-select").parents("tr").remove()},"json")}),saswp_item_reviewed_call(),jQuery(".saswp-local-schema-time-picker").timepicker({timeFormat:"H:i:s"}),s(document).on("click",".saswp-add-custom-schema",function(a){a.preventDefault(),s(".saswp-add-custom-schema-field").removeClass("saswp_hide"),s(this).hide()}),s(document).on("click",".saswp-delete-custom-schema",function(a){a.preventDefault(),s("#saswp_custom_schema_field").val(""),s(".saswp-add-custom-schema-field").addClass("saswp_hide"),s(".saswp-add-custom-schema").show()}),saswp_schema_datepicker(),saswp_schema_timepicker(),saswp_reviews_datepicker(),s(document).on("click",".saswp-add-more-item",function(a){a.preventDefault();s(".saswp-review-item-list-table").append('<tr class="saswp-review-item-tr"><td>Review Item Feature</td><td><input type="text" name="saswp-review-item-feature[]"></td><td>Rating</td><td><input step="0.1" min="0" max="5" type="number" name="saswp-review-item-star-rating[]"></td><td><a type="button" class="saswp-remove-review-item button">x</a></td></tr>')}),s(document).on("click",".saswp-remove-review-item",function(a){a.preventDefault(),s(this).parent().parent("tr").remove()}),s(document).on("focusout",".saswp-review-item-tr input[type=number]",function(a){a.preventDefault();var e=0,t=s(".saswp-review-item-tr input[type=number]").length;s(".saswp-review-item-tr input[type=number]").each(function(a,t){""==s(t).val()?e+=parseFloat(0):e+=parseFloat(s(t).val())});var i=e/t;s("#saswp-review-item-over-all").val(i)}),s("#saswp-review-location").change(function(){var a=s(this).val();s(".saswp-review-shortcode").addClass("saswp_hide"),3==a&&s(".saswp-review-shortcode").removeClass("saswp_hide")}).change(),s("#saswp-review-item-enable").change(function(){s(this).is(":checked")?s(".saswp-review-fields").show():s(".saswp-review-fields").hide()}).change(),s(document).on("click",".saswp-restore-post-schema",function(a){a.preventDefault();var e=s(this);if(e.addClass("updating-message"),s(".saswp-post-specific-schema-ids").val())var t=JSON.parse(s(".saswp-post-specific-schema-ids").val());s.post(ajaxurl,{action:"saswp_restore_schema",schema_ids:t,post_id:saswp_localize_data.post_id,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(s){"t"==s.status?setTimeout(function(){location.reload()},1e3):(alert(s.msg),setTimeout(function(){location.reload()},1e3)),e.removeClass("updating-message")},"json")}),s(document).on("click","div.saswp-tab ul.saswp-tab-nav a",function(a){a.preventDefault();var e=s(this).attr("data-id");s(".saswp-post-specific-wrapper").hide(),s("#"+e).show(),s("div.saswp-tab ul.saswp-tab-nav a").removeClass("selected"),s("div.saswp-tab ul.saswp-tab-nav li").removeClass("selected"),s(this).addClass("selected"),s(this).parent().addClass("selected"),saswp_enable_rating_review()}),s("#saswp-global-tabs a:first").addClass("saswp-global-selected"),s(".saswp-global-container").hide(),"#saswp-default-container"==window.location.hash?s(".saswp-global-container:eq(2)").show():s(".saswp-global-container:first").show(),s("#saswp-global-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-global-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-global-container").hide(),s("#"+a).show())}),s("#saswp-tools-tabs a:first").addClass("saswp-global-selected"),s(".saswp-tools-container").hide(),s(".saswp-tools-container:first").show(),s("#saswp-tools-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-tools-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-tools-container").hide(),s("#"+a).show())}),s("#saswp-review-tabs a:first").addClass("saswp-global-selected"),s(".saswp-review-container").hide(),s(".saswp-review-container:first").show(),s("#saswp-review-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-review-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-review-container").hide(),s("#"+a).show())}),s("#saswp-compatibility-tabs a:first").addClass("saswp-global-selected"),s(".saswp-compatibility-container").hide(),s(".saswp-compatibility-container:first").show(),s("#saswp-compatibility-tabs a").click(function(){var a=s(this).attr("data-id");s(this).hasClass("saswp-global-selected")||(s("#saswp-compatibility-tabs a").removeClass("saswp-global-selected"),s(this).addClass("saswp-global-selected"),s(".saswp-compatibility-container").hide(),s("#"+a).show())}),s('a[href="'+saswp_localize_data.new_url_selector+'"]').attr("href",saswp_localize_data.new_url_href),s(".saswp-enable-modify-schema-output").on("change",function(){s(".saswp-static-container").addClass("saswp_hide"),s(".saswp-dynamic-container").addClass("saswp_hide"),"manual"==s(this).val()&&(s(".saswp-static-container").removeClass("saswp_hide"),s(".saswp-dynamic-container").addClass("saswp_hide")),"automatic"==s(this).val()&&(s(".saswp-static-container").addClass("saswp_hide"),s(".saswp-dynamic-container").removeClass("saswp_hide"))}),s(document).on("change",".saswp-custom-fields-name",function(){var a="text",e=s(this).parent().parent("tr"),t=s(this).val();-1==t.indexOf("_image")&&-1==t.indexOf("_logo")||(a="image");var i=s(this).parent().parent("tr").find("td:eq(1)");saswp_get_meta_list(null,a,null,i,t,e)}),s(document).on("click",".saswp-skip-button",function(a){a.preventDefault(),s(this).parent().parent().hide(),s.post(ajaxurl,{action:"saswp_skip_wizard",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(s){},"json")}),s(document).on("click",".saswp_add_schema_fields_on_fly",function(a){a.preventDefault();var e=s(this);e.addClass("updating-message");var t=s(this).attr("data-id"),i=s(this).attr("fields_type"),p=s(this).attr("div_type"),c=s(this).attr("itemlist_sub_type"),o=s("saswp_specific_"+t+" , .saswp-"+p+"-table-div").length,l=s("saswp_specific_"+t+" , .saswp-"+p+"-table-div:nth-child("+o+")").attr("data-id");(l=++l)||(l=0),saswp_get_post_specific_schema_fields(e,l,i,p,t,i+"_",c)}),s(document).on("click",".saswp-table-close",function(){s(this).parent().remove()}),s(document).on("click",".saswp-rmv-modify_row",function(a){a.preventDefault(),s(this).parent().parent().remove()}),s(document).on("change",".saswp-custom-meta-list",function(){var a=s(this),e=s("select#schema_type option:selected").val(),t=s(this).val(),i=s(this).parent().parent("tr").find(".saswp-custom-fields-name").val(),p="",c=e.toLowerCase()+"_"+i,o="saswp_fixed_image["+i+"]";"manual_text"==t?(p+='<td><input type="text" name="saswp_fixed_text['+i+']"></td>',p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2()):"taxonomy_term"==t?saswp_taxonomy_term.taxonomy?(p+=saswp_taxonomy_term_html(saswp_taxonomy_term.taxonomy,i),a.parent().parent("tr").find("td:gt(1)").remove(),a.parent().parent("tr").append(p),saswpCustomSelect2()):s.get(ajaxurl,{action:"saswp_get_taxonomy_term_list",saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(s){s&&(saswp_taxonomy_term.taxonomy=s,p+=saswp_taxonomy_term_html(s,i),a.parent().parent("tr").find("td:gt(1)").remove(),a.parent().parent("tr").append(p),saswpCustomSelect2())},"json"):"custom_field"==t?(p+='<td><select class="saswp-custom-fields-select2" name="saswp_custom_meta_field['+i+']">',p+="</select></td>",p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2()):"fixed_image"==t?(p+="<td>",p+="<fieldset>",p+='<input data-id="media" style="width: 30%;" class="button" id="'+c+'_button" name="'+c+'_button" type="button" value="Upload" />',p+='<input type="hidden" data-id="'+c+'_height" class="upload-height" name="'+o+'[height]" id="'+c+'_height" value="">',p+='<input type="hidden" data-id="'+c+'_width" class="upload-width" name="'+o+'[width]" id="'+c+'_width" value="">',p+='<input type="hidden" data-id="'+c+'_thumbnail" class="upload-thumbnail" name="'+o+'[thumbnail]" id="'+c+'_thumbnail" value="">',p+='<div class="saswp_image_div_'+c+'">',p+="</div>",p+="</fieldset>",p+="</td>",p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2()):(p+="<td></td>",p+='<td><a class="button button-default saswp-rmv-modify_row">X</a></td>',s(this).parent().parent("tr").find("td:gt(1)").remove(),s(this).parent().parent("tr").append(p),saswpCustomSelect2())}),s(document).on("change",".saswp-item-reivewed-list",function(){s(".saswp-custom-fields-table").html(""),saswp_meta_list_fields=[];var a=s(this),e=s("select#schema_type option:selected").val();saswp_item_reviewed_ajax(e,a,"manual")}),s(document).on("click",".saswp-add-custom-fields",function(){var a=s(this);a.addClass("updating-message");var e=s("select#schema_type option:selected").val(),t="",i=null;"Review"==e&&(t=s("select.saswp-item-reivewed-list option:selected").val(),i="saswp_review_name");var p=s("#post_ID").val();""!=e&&(saswp_meta_list_fields[e]?saswp_get_meta_list(a,"text",saswp_meta_list_fields[e],null,i,null):s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_get_schema_type_fields",post_id:p,schema_type:e,schema_subtype:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){saswp_meta_list_fields[e]=s,saswp_get_meta_list(a,"text",saswp_meta_list_fields[e],null,i,null)},error:function(s){console.log(s)}}))}),saswpCustomSelect2(),saswp_enable_rating_review(),s('a[href="'+saswp_localize_data.collection_post_add_url+'"]').attr("href",saswp_localize_data.collection_post_add_new_url),s(document).on("click",".saswp_coonect_google_place",function(){var a=s("#saswp_google_place_id").val(),e=s("#saswp_language_list").val(),t=s("#saswp_googel_api").val();""!=a&&s.ajax({type:"POST",url:ajaxurl,dataType:"json",data:{action:"saswp_connect_google_place",place_id:a,language:e,google_api:t,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},success:function(s){console.log(s.status)},error:function(s){console.log(s)}})}),s(document).on("click",".saswp-add-social-links",function(){s(".saswp-social-links-table").append('<tr><td><input type="text" placeholder="https://www.facebook.com/profile" name="sd_data[saswp_social_links][]" value=""></td><td><a class="button button-default saswp-rmv-modify_row">X</a></td></tr>')}),s(document).on("click",".saswp-show-accept-rv-popup",function(){tb_show("Reviews Form","#TB_inline??width=600&height=400&inlineId=saswp-accept-reviews-popup"),s(document).find("#TB_window").width(600).height(400).css({top:"100px","margin-top":"0px"})}),("saswp_reviews"==saswp_localize_data.post_type||"saswp-collections"==saswp_localize_data.post_type)&&"edit.php"==saswp_localize_data.page_now){var i='<div class="saswp-custom-post-tab">';i+='<div style="display:none;" id="saswp-accept-reviews-popup">',i+='<div class="saswp-accept-rv-container">',i+="<p>Use Below shortcode to show reviews form in your website. Using this you can accept reviews from your website directly</p>",i+='<div class="saswp-show-form-on-tab"><strong>Simple Form</strong> <input value="[saswp-reviews-form]" type="text" readonly></div>',i+='<div class="saswp-show-form-on-tab"><strong>Show form on button tap</strong> <input value="[saswp-reviews-form onbutton="1"]" type="text" readonly></div>',i+="</div>",i+="</div>",i+='<h2 class="nav-tab-wrapper">',i+="<a href="+saswp_localize_data.reviews_page_url+' class="nav-tab '+(saswp_localize_data.current_url==saswp_localize_data.reviews_page_url?"saswp-global-selected":"")+'">Reviews</a>',i+="<a href="+saswp_localize_data.collections_page_url+' class="nav-tab '+(saswp_localize_data.current_url==saswp_localize_data.collections_page_url?"saswp-global-selected":"")+'">Collections</a>',i+='<a class="nav-tab saswp-show-accept-rv-popup">Accept Reviews</a>',i+="</h2>",i+="</div>",jQuery(jQuery(".wrap")).prepend(i)}"saswp"==saswp_localize_data.post_type&&"edit.php"==saswp_localize_data.page_now&&jQuery(jQuery(".wrap a")[0]).after("<a href='"+saswp_localize_data.saswp_settings_url+"' id='' class='page-title-action'>Settings</a>"),"undefined"!=typeof saswp_reviews_data&&(console.log(saswp_reviews_data.rating_val),s(".saswp-rating-div").rateYo({spacing:"5px",rating:saswp_reviews_data.rating_val,readOnly:saswp_reviews_data.readonly,onSet:function(a,e){s(this).next().next().val(a)}}).on("rateyo.change",function(a,e){var t=e.rating;s(this).next().text(t)})),s("#sd-person-phone-number, #saswp_kb_telephone").focusout(function(){var a=s(this);a.parent().find(".saswp-phone-validation").remove();var e=s(this).val();/^\+([0-9]{1,3})\)?[-. ]?([0-9]{2,4})[-. ]?([0-9]{2,4})[-. ]?([0-9]{2,4})$/.test(e)?a.parent().find(".saswp-phone-validation").remove():a.after('<span style="color:red;" class="saswp-phone-validation">Invalid Phone Number</span>')}),saswpCollectionSlider(),s(document).on("click",".saswp-grid-page",function(a){a.preventDefault(),saswp_grid_page=s(this).attr("data-id"),saswp_on_collection_design_change()}),s("#saswp-coll-pagination").change(function(){saswp_grid_page=1,s("#saswp-coll-per-page").parent().addClass("saswp_hide_imp"),s(this).is(":checked")&&s("#saswp-coll-per-page").parent().removeClass("saswp_hide_imp"),saswp_on_collection_design_change()}),s(".saswp-accordion").click(function(){s(this).toggleClass("active"),s(this).next(".saswp-accordion-panel").slideToggle(200)}),s(document).on("click",".saswp-opn-cls-btn",function(){s("#saswp-reviews-cntn").toggle(),s("#saswp-reviews-cntn").is(":visible")?(s(".saswp-onclick-show").css("display","flex"),s(".saswp-onclick-hide").hide(),s(".saswp-open-class").css("width","500px")):(s(".saswp-onclick-show").css("display","none"),s(".saswp-onclick-hide").show(),s(".saswp-open-class").css("width","300px"))}),s(".saswp-collection-display-method").change(function(){"shortcode"==s(this).val()?s(".saswp-collection-shortcode").removeClass("saswp_hide"):s(".saswp-collection-shortcode").addClass("saswp_hide")}).change(),s(document).on("click",".saswp-remove-platform",function(a){a.preventDefault();var e=s(this).attr("platform-id");saswp_collection.splice(e,1),s(this).parent().remove(),saswp_on_collection_design_change()}),s(".saswp-number-change").bind("keyup mouseup",function(){saswp_on_collection_design_change()}),s(".saswp-coll-settings-options").change(function(){saswp_grid_page=1;var a=s(".saswp-collection-desing").val();s(".saswp-coll-options").addClass("saswp_hide"),s(".saswp-collection-lp").css("height","auto"),"grid"==a&&s(".saswp-grid-options").removeClass("saswp_hide"),"gallery"==a&&s(".saswp-slider-options").removeClass("saswp_hide"),"fomo"==a&&(s(".saswp-fomo-options").removeClass("saswp_hide"),s(".saswp-collection-lp").css("height","31px")),"popup"==a&&s(".saswp-collection-lp").css("height","31px"),saswp_on_collection_design_change()}).change(),s(".saswp-add-to-collection").on("click",function(a){a.preventDefault();var e=s(this),t=s("#saswp-plaftorm-list").val(),i=s("#saswp-review-count").val();t&&i>0?(e.addClass("updating-message"),saswp_get_collection_data(i,t,e)):alert("Enter Count")});var p,c,o=s("#saswp_collection_id").val();o&&(s(".spinner").addClass("is-active"),s.get(ajaxurl,{action:"saswp_get_collection_platforms",collection_id:o,saswp_security_nonce:saswp_localize_data.saswp_security_nonce},function(a){if(a.status){var e=a.message;s.each(e,function(s,a){saswp_get_collection_data(a,s,null)})}s(".spinner").removeClass("is-active")},"json")),(p=document.createElement("div")).style.cssText="position:absolute; background:black; color:white; padding:4px 6px;z-index:10000;border-radius:2px; font-size:12px;box-shadow:3px 3px 3px rgba(0,0,0,.4);opacity:0;transition:opacity 0.3s",p.innerHTML="Copied!",document.body.appendChild(p);var l=document.getElementById("motivatebox");l&&l.addEventListener("mouseup",function(s){var a=(s=s||event).target||s.srcElement;"motivate"==a.className&&(!function(s){var a=document.createRange();a.selectNodeContents(s);var e=window.getSelection();e.removeAllRanges(),e.addRange(a)}(a),function(){var s;try{s=document.execCommand("copy")}catch(a){s=!1}return s}()&&function(s){var a=s||event;clearTimeout(c),p.style.left=a.pageX-10+"px",p.style.top=a.pageY+15+"px",p.style.opacity=1,c=setTimeout(function(){p.style.opacity=0},500)}(s))},!1)});
|
admin_section/newsletter.php
CHANGED
@@ -48,7 +48,7 @@ class saswp_ads_newsletter {
|
|
48 |
echo $response;
|
49 |
|
50 |
}else{
|
51 |
-
echo
|
52 |
}
|
53 |
|
54 |
wp_die();
|
@@ -77,7 +77,7 @@ class saswp_ads_newsletter {
|
|
77 |
$object['current_user_email'] = $current_user->user_email;
|
78 |
$object['current_user_name'] = $current_user->display_name;
|
79 |
$object['displayID'] = '#menu-posts-saswp';
|
80 |
-
$object['button1'] =
|
81 |
$object['button2'] = false;
|
82 |
$object['function_name'] = '';
|
83 |
}
|
48 |
echo $response;
|
49 |
|
50 |
}else{
|
51 |
+
echo saswp_t_string('Email id required');
|
52 |
}
|
53 |
|
54 |
wp_die();
|
77 |
$object['current_user_email'] = $current_user->user_email;
|
78 |
$object['current_user_name'] = $current_user->display_name;
|
79 |
$object['displayID'] = '#menu-posts-saswp';
|
80 |
+
$object['button1'] = saswp_t_string('No Thanks');
|
81 |
$object['button2'] = false;
|
82 |
$object['function_name'] = '';
|
83 |
}
|
admin_section/plugin-installer/install.php
CHANGED
@@ -19,35 +19,35 @@
|
|
19 |
global $saswp_installer_config;
|
20 |
$saswp_installer_config = array(
|
21 |
'installer_dir' => 'plugin-installer',
|
22 |
-
'plugin_title' =>
|
23 |
'start_steps' => 1,
|
24 |
'total_steps' => 5,
|
25 |
'installerpage' => 'saswp-setup-wizard',
|
26 |
'dev_mode' => false,
|
27 |
'steps' => array(
|
28 |
1=>array(
|
29 |
-
'title'=>
|
30 |
'fields'=>'',
|
31 |
-
'description'=>
|
32 |
),
|
33 |
2=>array(
|
34 |
-
'title'=>
|
35 |
-
'description'=>
|
36 |
'fields'=>saswp_general_setting_fields_callback()
|
37 |
),
|
38 |
3=>array(
|
39 |
-
'title'=>
|
40 |
-
'description'=>
|
41 |
'fields'=>saswp_social_profile_fields_callback(),
|
42 |
),
|
43 |
4=>array(
|
44 |
-
'title'=>
|
45 |
-
'description'=>
|
46 |
'fields'=>saswp_select_schema_fields_callback(),
|
47 |
),
|
48 |
5=>array(
|
49 |
-
'title'=>
|
50 |
-
'description'=>
|
51 |
'fields'=>'',
|
52 |
),
|
53 |
),
|
@@ -117,7 +117,7 @@
|
|
117 |
ob_start();
|
118 |
saswp_install_header(); ?>
|
119 |
<div class="merlin__wrapper">
|
120 |
-
<div class="saswp_install_wizard"><?php esc_html_e('Schema and Structured Data Installation Wizard'
|
121 |
<div class="merlin__content merlin__content--<?php echo esc_attr( strtolower( $title ) ); ?>">
|
122 |
<?php
|
123 |
// Content Handlers.
|
@@ -135,7 +135,7 @@
|
|
135 |
|
136 |
</div>
|
137 |
|
138 |
-
<?php echo sprintf( '<a class="return-to-dashboard" href="%s">%s</a>', esc_url( admin_url( 'admin.php?page=structured_data_options' ) ),
|
139 |
|
140 |
</div>
|
141 |
|
@@ -172,14 +172,14 @@
|
|
172 |
|
173 |
<h1><?php echo $stepDetails['title']; ?></h1>
|
174 |
|
175 |
-
<p><?php echo
|
176 |
|
177 |
</div>
|
178 |
|
179 |
<footer class="merlin__content__footer">
|
180 |
-
<a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options' ) ); ?>" class="merlin__button merlin__button--skip"><?php echo
|
181 |
|
182 |
-
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next merlin__button--proceed merlin__button--colorchange"><?php echo
|
183 |
<?php wp_nonce_field( 'saswp_install_nonce' ); ?>
|
184 |
</footer>
|
185 |
<?php
|
@@ -219,10 +219,10 @@
|
|
219 |
<footer class="merlin__content__footer">
|
220 |
<?php saswp_skip_button(); ?>
|
221 |
|
222 |
-
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
223 |
|
224 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
225 |
-
<span class="merlin__button--loading__text"><?php echo
|
226 |
</a>
|
227 |
|
228 |
<?php wp_nonce_field( 'saswp_install_nonce' ); ?>
|
@@ -263,10 +263,10 @@
|
|
263 |
<footer class="merlin__content__footer">
|
264 |
<?php saswp_skip_button(); ?>
|
265 |
|
266 |
-
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
267 |
|
268 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
269 |
-
<span class="merlin__button--loading__text"><?php echo
|
270 |
</a>
|
271 |
|
272 |
|
@@ -306,10 +306,10 @@
|
|
306 |
<footer class="merlin__content__footer">
|
307 |
<?php saswp_skip_button(); ?>
|
308 |
|
309 |
-
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
310 |
|
311 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
312 |
-
<span class="merlin__button--loading__text"><?php echo
|
313 |
</a>
|
314 |
|
315 |
|
@@ -349,10 +349,10 @@
|
|
349 |
<footer class="merlin__content__footer">
|
350 |
<?php saswp_skip_button(); ?>
|
351 |
|
352 |
-
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo
|
353 |
|
354 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
355 |
-
<span class="merlin__button--loading__text"><?php echo
|
356 |
</a>
|
357 |
|
358 |
<?php wp_nonce_field( 'saswp_install_nonce' ); ?>
|
@@ -435,7 +435,7 @@
|
|
435 |
wp_send_json(
|
436 |
array(
|
437 |
'done' => 1,
|
438 |
-
'message' =>
|
439 |
)
|
440 |
);
|
441 |
}
|
@@ -443,7 +443,7 @@
|
|
443 |
|
444 |
function saswp_skip_button(){
|
445 |
?>
|
446 |
-
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip"><?php echo
|
447 |
<?php
|
448 |
}
|
449 |
function saswp_finish_page() {
|
@@ -468,15 +468,15 @@
|
|
468 |
|
469 |
<div class="saswp_branding"></div>
|
470 |
|
471 |
-
<h1><?php echo
|
472 |
|
473 |
-
<p><?php echo
|
474 |
|
475 |
</div>
|
476 |
|
477 |
<footer class="merlin__content__footer merlin__content__footer--fullwidth">
|
478 |
|
479 |
-
<a href="<?php echo esc_url( admin_url( 'edit.php?post_type=saswp&page=structured_data_options' ) ); ?>" class="merlin__button merlin__button--blue merlin__button--fullwidth merlin__button--popin"><?php echo
|
480 |
|
481 |
<ul class="merlin__drawer merlin__drawer--extras">
|
482 |
|
@@ -555,12 +555,12 @@
|
|
555 |
function saswp_makesvg( $args = array() ){
|
556 |
// Make sure $args are an array.
|
557 |
if ( empty( $args ) ) {
|
558 |
-
return __( 'Please define default parameters in the form of an array.'
|
559 |
}
|
560 |
|
561 |
// Define an icon.
|
562 |
if ( false === array_key_exists( 'icon', $args ) ) {
|
563 |
-
return __( 'Please define an SVG icon filename.'
|
564 |
}
|
565 |
|
566 |
// Set defaults.
|
@@ -594,12 +594,12 @@
|
|
594 |
|
595 |
// If there is a title, display it.
|
596 |
if ( $args['title'] ) {
|
597 |
-
$svg .= '<title>' .
|
598 |
}
|
599 |
|
600 |
// If there is a description, display it.
|
601 |
if ( $args['desc'] ) {
|
602 |
-
$svg .= '<desc>' .
|
603 |
}
|
604 |
|
605 |
$svg .= '<use xlink:href="#icon-' . esc_html( $args['icon'] ) . '"></use>';
|
@@ -700,9 +700,9 @@ function saswp_general_setting_fields_callback(){
|
|
700 |
if($about_page){
|
701 |
|
702 |
$about_page = '<li class="saswp_fields">
|
703 |
-
<label>'.
|
704 |
<select name="sd_data[sd_about_page]" id="sd_about_page-select">
|
705 |
-
<option value="">'.
|
706 |
'.$about_page.'
|
707 |
</select>
|
708 |
</li>';
|
@@ -711,18 +711,18 @@ function saswp_general_setting_fields_callback(){
|
|
711 |
if($contact_page){
|
712 |
|
713 |
$contact_page = '<li class="saswp_fields">
|
714 |
-
<label>'.
|
715 |
<select name="sd_data[sd_contact_page]" id="sd_contact_page-select">
|
716 |
-
<option value="">'.
|
717 |
'.$contact_page.'
|
718 |
</select>
|
719 |
</li>';
|
720 |
}
|
721 |
$returnHtml = '<li class="saswp_fields">
|
722 |
-
<label>'.
|
723 |
<select name="sd_data[saswp_kb_type]">
|
724 |
-
<option value="Organization" '.($saswp_kb_type=='Organization'? 'selected' : '').'>'.
|
725 |
-
<option value="Person" '.($saswp_kb_type=='Person'? 'selected' : '').'>'.
|
726 |
</select>
|
727 |
</li>
|
728 |
'.$about_page.'
|
@@ -744,23 +744,23 @@ function saswp_social_profile_fields_callback(){
|
|
744 |
$returnHtml = '
|
745 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
746 |
<input type="checkbox" name="sd_data[saswp-facebook-enable]" id="saswp-facebook-enable" class="checkbox" value="1" '.($sd_facebook!=''? 'checked': '').'>
|
747 |
-
<label for="saswp-facebook-enable"><i></i><span>'.
|
748 |
-
<input type="text" name="sd_data[sd_facebook]" value="'.esc_url($sd_facebook).'" placeholder="'.
|
749 |
</li>
|
750 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
751 |
<input type="checkbox" name="sd_data[saswp-twitter-enable]" id="saswp-twitter-enable" class="checkbox" value="1" '.($sd_twitter!=''? 'checked': '').'>
|
752 |
-
<label for="saswp-twitter-enable"><i></i><span>'.
|
753 |
-
<input type="text" name="sd_data[sd_twitter]" value="'.esc_url($sd_twitter).'" placeholder="'.
|
754 |
</li>
|
755 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
756 |
<input type="checkbox" name="sd_data[saswp-linkedin-enable]" id="saswp-linkedin-enable" class="checkbox" value="1" '.($sd_linkedin!=''? 'checked': '').'>
|
757 |
-
<label for="saswp-linkedin-enable"><i></i><span>'.
|
758 |
-
<input type="text" name="sd_data[sd_linkedin]" value="'.esc_url($sd_linkedin).'" placeholder="'.
|
759 |
</li>
|
760 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
761 |
<input type="checkbox" name="sd_data[saswp-instagram-enable]" id="saswp-instagram-enable" class="checkbox" value="1" '.($sd_instagram!=''? 'checked': '').'>
|
762 |
-
<label for="saswp-instagram-enable"><i></i><span>'.
|
763 |
-
<input type="text" name="sd_data[sd_instagram]" value="'.esc_url($sd_instagram).'" placeholder="'.
|
764 |
</li>';
|
765 |
return $returnHtml;
|
766 |
}
|
@@ -784,14 +784,14 @@ function saswp_select_schema_fields_callback(){
|
|
784 |
<input type="hidden" name="sd_data_create__post_schema['.esc_attr($key).'][posttype]" class="checkbox" value="'.esc_attr($key).'" >
|
785 |
|
786 |
<select id="schema_type" name="sd_data_create__post_schema['.$key.'][schema_type]">
|
787 |
-
<option value="">'.
|
788 |
-
<option value="BlogPosting">'.
|
789 |
-
<option value="NewsArticle">'.
|
790 |
-
<option value="WebPage">'.
|
791 |
-
<option value="Article">'.
|
792 |
-
<option value="Recipe">'.
|
793 |
-
<option value="Product">'.
|
794 |
-
<option value="VideoObject">'.
|
795 |
</select>
|
796 |
</li>';
|
797 |
}
|
19 |
global $saswp_installer_config;
|
20 |
$saswp_installer_config = array(
|
21 |
'installer_dir' => 'plugin-installer',
|
22 |
+
'plugin_title' => saswp_t_string( ucfirst( 'Schema & Structured Data for WP' )),
|
23 |
'start_steps' => 1,
|
24 |
'total_steps' => 5,
|
25 |
'installerpage' => 'saswp-setup-wizard',
|
26 |
'dev_mode' => false,
|
27 |
'steps' => array(
|
28 |
1=>array(
|
29 |
+
'title'=>saswp_t_string('Welcome'),
|
30 |
'fields'=>'',
|
31 |
+
'description'=>saswp_t_string('This wizard will set up AMP on your website, install plugin, and import content. It is optional & should take only a few minutes.'),
|
32 |
),
|
33 |
2=>array(
|
34 |
+
'title'=>saswp_t_string('General Settings'),
|
35 |
+
'description'=>saswp_t_string(''),
|
36 |
'fields'=>saswp_general_setting_fields_callback()
|
37 |
),
|
38 |
3=>array(
|
39 |
+
'title'=>saswp_t_string('Social Profiles'),
|
40 |
+
'description'=>saswp_t_string('Would you like to setup Social Profiles?'),
|
41 |
'fields'=>saswp_social_profile_fields_callback(),
|
42 |
),
|
43 |
4=>array(
|
44 |
+
'title'=>saswp_t_string('Select Schema'),
|
45 |
+
'description'=>saswp_t_string('Where would you like to enable the schema?'),
|
46 |
'fields'=>saswp_select_schema_fields_callback(),
|
47 |
),
|
48 |
5=>array(
|
49 |
+
'title'=>saswp_t_string('Enjoy'),
|
50 |
+
'description'=>saswp_t_string('Navigate to '),
|
51 |
'fields'=>'',
|
52 |
),
|
53 |
),
|
117 |
ob_start();
|
118 |
saswp_install_header(); ?>
|
119 |
<div class="merlin__wrapper">
|
120 |
+
<div class="saswp_install_wizard"><?php esc_html_e('Schema and Structured Data Installation Wizard'); ?></div>
|
121 |
<div class="merlin__content merlin__content--<?php echo esc_attr( strtolower( $title ) ); ?>">
|
122 |
<?php
|
123 |
// Content Handlers.
|
135 |
|
136 |
</div>
|
137 |
|
138 |
+
<?php echo sprintf( '<a class="return-to-dashboard" href="%s">%s</a>', esc_url( admin_url( 'admin.php?page=structured_data_options' ) ), saswp_t_string( 'Return to dashboard' ) ); ?>
|
139 |
|
140 |
</div>
|
141 |
|
172 |
|
173 |
<h1><?php echo $stepDetails['title']; ?></h1>
|
174 |
|
175 |
+
<p><?php echo saswp_t_string( 'This Installation Wizard helps you to setup the necessary options for schema & structured data. It is optional & should take only a few minutes.' ); ?></p>
|
176 |
|
177 |
</div>
|
178 |
|
179 |
<footer class="merlin__content__footer">
|
180 |
+
<a href="<?php echo esc_url( admin_url( 'admin.php?page=structured_data_options' ) ); ?>" class="merlin__button merlin__button--skip"><?php echo saswp_t_string( 'Cancel' ); ?></a>
|
181 |
|
182 |
+
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next merlin__button--proceed merlin__button--colorchange"><?php echo saswp_t_string( 'Start' ); ?></a>
|
183 |
<?php wp_nonce_field( 'saswp_install_nonce' ); ?>
|
184 |
</footer>
|
185 |
<?php
|
219 |
<footer class="merlin__content__footer">
|
220 |
<?php saswp_skip_button(); ?>
|
221 |
|
222 |
+
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
223 |
|
224 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
225 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_loading_spinner(); ?>
|
226 |
</a>
|
227 |
|
228 |
<?php wp_nonce_field( 'saswp_install_nonce' ); ?>
|
263 |
<footer class="merlin__content__footer">
|
264 |
<?php saswp_skip_button(); ?>
|
265 |
|
266 |
+
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
267 |
|
268 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
269 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_loading_spinner(); ?>
|
270 |
</a>
|
271 |
|
272 |
|
306 |
<footer class="merlin__content__footer">
|
307 |
<?php saswp_skip_button(); ?>
|
308 |
|
309 |
+
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
310 |
|
311 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
312 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_loading_spinner(); ?>
|
313 |
</a>
|
314 |
|
315 |
|
349 |
<footer class="merlin__content__footer">
|
350 |
<?php saswp_skip_button(); ?>
|
351 |
|
352 |
+
<a id="skip" href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip merlin__button--proceed"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
353 |
|
354 |
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--next button-next" data-callback="save_logo">
|
355 |
+
<span class="merlin__button--loading__text"><?php echo saswp_t_string( 'Next' ); ?></span><?php echo saswp_loading_spinner(); ?>
|
356 |
</a>
|
357 |
|
358 |
<?php wp_nonce_field( 'saswp_install_nonce' ); ?>
|
435 |
wp_send_json(
|
436 |
array(
|
437 |
'done' => 1,
|
438 |
+
'message' => saswp_t_string( 'Stored Successfully' ),
|
439 |
)
|
440 |
);
|
441 |
}
|
443 |
|
444 |
function saswp_skip_button(){
|
445 |
?>
|
446 |
+
<a href="<?php echo esc_url( saswp_step_next_link() ); ?>" class="merlin__button merlin__button--skip"><?php echo saswp_t_string( 'Skip' ); ?></a>
|
447 |
<?php
|
448 |
}
|
449 |
function saswp_finish_page() {
|
468 |
|
469 |
<div class="saswp_branding"></div>
|
470 |
|
471 |
+
<h1><?php echo saswp_t_string( 'Setup Done. Have fun!' ); ?></h1>
|
472 |
|
473 |
+
<p><?php echo saswp_t_string( 'Basic Setup has been done. Navigate to plugin options panel to access all the options.' ); ?></p>
|
474 |
|
475 |
</div>
|
476 |
|
477 |
<footer class="merlin__content__footer merlin__content__footer--fullwidth">
|
478 |
|
479 |
+
<a href="<?php echo esc_url( admin_url( 'edit.php?post_type=saswp&page=structured_data_options' ) ); ?>" class="merlin__button merlin__button--blue merlin__button--fullwidth merlin__button--popin"><?php echo saswp_t_string( 'Let\'s Go' ); ?></a>
|
480 |
|
481 |
<ul class="merlin__drawer merlin__drawer--extras">
|
482 |
|
555 |
function saswp_makesvg( $args = array() ){
|
556 |
// Make sure $args are an array.
|
557 |
if ( empty( $args ) ) {
|
558 |
+
return __( 'Please define default parameters in the form of an array.' );
|
559 |
}
|
560 |
|
561 |
// Define an icon.
|
562 |
if ( false === array_key_exists( 'icon', $args ) ) {
|
563 |
+
return __( 'Please define an SVG icon filename.' );
|
564 |
}
|
565 |
|
566 |
// Set defaults.
|
594 |
|
595 |
// If there is a title, display it.
|
596 |
if ( $args['title'] ) {
|
597 |
+
$svg .= '<title>' . saswp_t_string( $args['title'] ) . '</title>';
|
598 |
}
|
599 |
|
600 |
// If there is a description, display it.
|
601 |
if ( $args['desc'] ) {
|
602 |
+
$svg .= '<desc>' . saswp_t_string( $args['desc'] ) . '</desc>';
|
603 |
}
|
604 |
|
605 |
$svg .= '<use xlink:href="#icon-' . esc_html( $args['icon'] ) . '"></use>';
|
700 |
if($about_page){
|
701 |
|
702 |
$about_page = '<li class="saswp_fields">
|
703 |
+
<label>'.saswp_t_string('About').'</label>
|
704 |
<select name="sd_data[sd_about_page]" id="sd_about_page-select">
|
705 |
+
<option value="">'.saswp_t_string( 'Select an item' ).'</option>
|
706 |
'.$about_page.'
|
707 |
</select>
|
708 |
</li>';
|
711 |
if($contact_page){
|
712 |
|
713 |
$contact_page = '<li class="saswp_fields">
|
714 |
+
<label>'.saswp_t_string('Contact').'</label>
|
715 |
<select name="sd_data[sd_contact_page]" id="sd_contact_page-select">
|
716 |
+
<option value="">'.saswp_t_string( 'Select an item' ).'</option>
|
717 |
'.$contact_page.'
|
718 |
</select>
|
719 |
</li>';
|
720 |
}
|
721 |
$returnHtml = '<li class="saswp_fields">
|
722 |
+
<label>'.saswp_t_string('Data Type').'</label>
|
723 |
<select name="sd_data[saswp_kb_type]">
|
724 |
+
<option value="Organization" '.($saswp_kb_type=='Organization'? 'selected' : '').'>'.saswp_t_string('Organization').'</option>
|
725 |
+
<option value="Person" '.($saswp_kb_type=='Person'? 'selected' : '').'>'.saswp_t_string('Person').'</option>
|
726 |
</select>
|
727 |
</li>
|
728 |
'.$about_page.'
|
744 |
$returnHtml = '
|
745 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
746 |
<input type="checkbox" name="sd_data[saswp-facebook-enable]" id="saswp-facebook-enable" class="checkbox" value="1" '.($sd_facebook!=''? 'checked': '').'>
|
747 |
+
<label for="saswp-facebook-enable"><i></i><span>'.saswp_t_string('Facebook').'</span></label>
|
748 |
+
<input type="text" name="sd_data[sd_facebook]" value="'.esc_url($sd_facebook).'" placeholder="'.saswp_t_string('Enter Facebook Page UR').'">
|
749 |
</li>
|
750 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
751 |
<input type="checkbox" name="sd_data[saswp-twitter-enable]" id="saswp-twitter-enable" class="checkbox" value="1" '.($sd_twitter!=''? 'checked': '').'>
|
752 |
+
<label for="saswp-twitter-enable"><i></i><span>'.saswp_t_string('Twitter').'</span></label>
|
753 |
+
<input type="text" name="sd_data[sd_twitter]" value="'.esc_url($sd_twitter).'" placeholder="'.saswp_t_string('Enter Twitter Page UR').'">
|
754 |
</li>
|
755 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
756 |
<input type="checkbox" name="sd_data[saswp-linkedin-enable]" id="saswp-linkedin-enable" class="checkbox" value="1" '.($sd_linkedin!=''? 'checked': '').'>
|
757 |
+
<label for="saswp-linkedin-enable"><i></i><span>'.saswp_t_string('Linkedin').'</span></label>
|
758 |
+
<input type="text" name="sd_data[sd_linkedin]" value="'.esc_url($sd_linkedin).'" placeholder="'.saswp_t_string('Enter Linkedin Page UR').'">
|
759 |
</li>
|
760 |
<li class="merlin__drawer--import-content__list-item status saswp-social-fields">
|
761 |
<input type="checkbox" name="sd_data[saswp-instagram-enable]" id="saswp-instagram-enable" class="checkbox" value="1" '.($sd_instagram!=''? 'checked': '').'>
|
762 |
+
<label for="saswp-instagram-enable"><i></i><span>'.saswp_t_string('Instagram').'</span></label>
|
763 |
+
<input type="text" name="sd_data[sd_instagram]" value="'.esc_url($sd_instagram).'" placeholder="'.saswp_t_string('Enter Linkedin Page UR').'">
|
764 |
</li>';
|
765 |
return $returnHtml;
|
766 |
}
|
784 |
<input type="hidden" name="sd_data_create__post_schema['.esc_attr($key).'][posttype]" class="checkbox" value="'.esc_attr($key).'" >
|
785 |
|
786 |
<select id="schema_type" name="sd_data_create__post_schema['.$key.'][schema_type]">
|
787 |
+
<option value="">'.saswp_t_string('Select Schema Type').'</option>
|
788 |
+
<option value="BlogPosting">'.saswp_t_string('BlogPosting').'</option>
|
789 |
+
<option value="NewsArticle">'.saswp_t_string('NewsArticl').'e</option>
|
790 |
+
<option value="WebPage">'.saswp_t_string('WebPage').'</option>
|
791 |
+
<option value="Article">'.saswp_t_string('Article').'</option>
|
792 |
+
<option value="Recipe">'.saswp_t_string('Recipe').'</option>
|
793 |
+
<option value="Product">'.saswp_t_string('Product').'</option>
|
794 |
+
<option value="VideoObject">'.saswp_t_string('VideoObject').'</option>
|
795 |
</select>
|
796 |
</li>';
|
797 |
}
|
admin_section/settings.php
CHANGED
@@ -23,9 +23,9 @@ function saswp_plugin_action_links( $links ) {
|
|
23 |
|
24 |
if(is_array($links)){
|
25 |
|
26 |
-
$links[] = '<a href="' . esc_url( admin_url( 'edit.php?post_type=saswp&page=structured_data_options' ) ) . '">' .
|
27 |
-
$links[] = '<a href="'. esc_url( admin_url( 'plugins.php?page=saswp-setup-wizard' ).'&_saswp_nonce='.$nonce).'">' .
|
28 |
-
$links[] = '<a target="_blank" href="http://structured-data-for-wp.com/docs/">' .
|
29 |
|
30 |
}
|
31 |
|
@@ -65,15 +65,15 @@ function saswp_ext_installed_status(){
|
|
65 |
function saswp_add_menu_links() {
|
66 |
|
67 |
add_submenu_page( 'edit.php?post_type=saswp',
|
68 |
-
|
69 |
-
|
70 |
saswp_current_user_can(),
|
71 |
'structured_data_options',
|
72 |
'saswp_admin_interface_render'
|
73 |
);
|
74 |
|
75 |
if(!saswp_ext_installed_status()){
|
76 |
-
add_submenu_page( 'edit.php?post_type=saswp',
|
77 |
}
|
78 |
|
79 |
}
|
@@ -105,29 +105,29 @@ function saswp_admin_interface_render(){
|
|
105 |
?>
|
106 |
<div class="saswp-settings-container">
|
107 |
<div class="wrap saswp-settings-form saswp-settings-first-div" style="<?php echo( saswp_ext_installed_status()? 'width:100%;':''); ?>">
|
108 |
-
<h1 class="wp-heading-inline"> <?php echo
|
109 |
<div>
|
110 |
<h2 class="nav-tab-wrapper saswp-tabs">
|
111 |
|
112 |
<?php
|
113 |
|
114 |
-
echo '<a href="' . esc_url(saswp_admin_link('general')) . '" class="nav-tab ' . esc_attr( $tab == 'general' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
115 |
|
116 |
-
echo '<a href="' . esc_url(saswp_admin_link('amp')) . '" class="nav-tab ' . esc_attr( $tab == 'amp' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
117 |
|
118 |
-
echo '<a href="' . esc_url(saswp_admin_link('review')) . '" class="nav-tab ' . esc_attr( $tab == 'review' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
119 |
|
120 |
-
echo '<a href="' . esc_url(saswp_admin_link('compatibility')) . '" class="nav-tab ' . esc_attr( $tab == 'compatibility' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
121 |
|
122 |
-
echo '<a href="' . esc_url(saswp_admin_link('email_schema')) . '" class="nav-tab ' . esc_attr( $tab == 'email_schema' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
123 |
|
124 |
-
echo '<a href="' . esc_url(saswp_admin_link('tools')) . '" class="nav-tab ' . esc_attr( $tab == 'tools' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
125 |
|
126 |
-
echo '<a href="' . esc_url(saswp_admin_link('premium_features')) . '" class="nav-tab ' . esc_attr( $tab == 'premium_features' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
127 |
|
128 |
-
echo '<a href="' . esc_url(saswp_admin_link('services')) . '" class="nav-tab ' . esc_attr( $tab == 'services' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
129 |
|
130 |
-
echo '<a href="' . esc_url(saswp_admin_link('support')) . '" class="nav-tab ' . esc_attr( $tab == 'support' ? 'nav-tab-active' : '') . '"><span class=""></span> ' .
|
131 |
?>
|
132 |
|
133 |
</h2>
|
@@ -144,7 +144,7 @@ function saswp_admin_interface_render(){
|
|
144 |
|
145 |
echo '<div id="saswp-global-tabs" style="margin-top: 10px;">';
|
146 |
|
147 |
-
echo '<a data-id="saswp-general-container">'.
|
148 |
|
149 |
echo'</div> ';
|
150 |
|
@@ -161,7 +161,7 @@ function saswp_admin_interface_render(){
|
|
161 |
|
162 |
echo '<div id="saswp-review-tabs" style="margin-top: 10px;">';
|
163 |
|
164 |
-
echo '<a data-id="saswp-review-reviews-container">'.
|
165 |
|
166 |
echo'</div> ';
|
167 |
|
@@ -174,7 +174,7 @@ function saswp_admin_interface_render(){
|
|
174 |
|
175 |
echo '<div id="saswp-compatibility-tabs" style="margin-top: 10px;">';
|
176 |
|
177 |
-
echo '<a data-id="saswp-active-compatibility-container">'.
|
178 |
|
179 |
echo'</div> ';
|
180 |
|
@@ -190,7 +190,7 @@ function saswp_admin_interface_render(){
|
|
190 |
|
191 |
echo '<div id="saswp-tools-tabs" style="margin-top: 10px;">';
|
192 |
|
193 |
-
echo '<a data-id="saswp-tools-advanced-container">'.
|
194 |
|
195 |
echo'</div> ';
|
196 |
// Status
|
@@ -218,7 +218,7 @@ function saswp_admin_interface_render(){
|
|
218 |
<div class="button-wrapper">
|
219 |
<?php
|
220 |
// Output save settings button
|
221 |
-
submit_button(
|
222 |
?>
|
223 |
</div>
|
224 |
<input type="hidden" name="sd_data[sd_initial_wizard_status]" value="1">
|
@@ -227,23 +227,23 @@ function saswp_admin_interface_render(){
|
|
227 |
<div class="saswp-settings-second-div">
|
228 |
<!-- <a target="_blank" href="http://structured-data-for-wp.com/pricing/">
|
229 |
<div class="saswp-upgrade-pro promo-cpn">
|
230 |
-
<h2><?php echo
|
231 |
-
<span><?php echo
|
232 |
<div class="saswp-promo">
|
233 |
-
<span class="prm-txt"><?php echo
|
234 |
-
<span class="prm-cpn"><?php echo
|
235 |
</div>
|
236 |
</div>
|
237 |
</a>-->
|
238 |
<?php if(!saswp_ext_installed_status()) { ?>
|
239 |
<div class="saswp-upgrade-pro">
|
240 |
-
<h2><?php echo
|
241 |
<ul>
|
242 |
-
<li><?php echo
|
243 |
-
<li><?php echo
|
244 |
-
<li><?php echo
|
245 |
</ul>
|
246 |
-
<a target="_blank" href="http://structured-data-for-wp.com/pricing/"><?php echo
|
247 |
</div>
|
248 |
<?php } ?>
|
249 |
</div>
|
@@ -398,7 +398,38 @@ function saswp_handle_file_upload($option){
|
|
398 |
function saswp_premium_features_callback(){ ?>
|
399 |
<div class="saswp-pre-ftrs-wrap">
|
400 |
<ul class="saswp-features-blocks">
|
401 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
402 |
<li>
|
403 |
|
404 |
<?php
|
@@ -419,8 +450,8 @@ function saswp_premium_features_callback(){ ?>
|
|
419 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/customer-review.png">
|
420 |
</div>
|
421 |
<div class="saswp-ele-tlt">
|
422 |
-
<h3><?php echo
|
423 |
-
<p><?php echo
|
424 |
</div>
|
425 |
</div>
|
426 |
<div class="saswp-sts-btn">
|
@@ -450,8 +481,8 @@ function saswp_premium_features_callback(){ ?>
|
|
450 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/jobposting.png">
|
451 |
</div>
|
452 |
<div class="saswp-ele-tlt">
|
453 |
-
<h3><?php echo
|
454 |
-
<p><?php echo
|
455 |
</div>
|
456 |
</div>
|
457 |
<div class="saswp-sts-btn">
|
@@ -481,8 +512,8 @@ function saswp_premium_features_callback(){ ?>
|
|
481 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/faq.png">
|
482 |
</div>
|
483 |
<div class="saswp-ele-tlt">
|
484 |
-
<h3><?php echo
|
485 |
-
<p><?php echo
|
486 |
</div>
|
487 |
</div>
|
488 |
<div class="saswp-sts-btn">
|
@@ -513,8 +544,8 @@ function saswp_premium_features_callback(){ ?>
|
|
513 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/question.png">
|
514 |
</div>
|
515 |
<div class="saswp-ele-tlt">
|
516 |
-
<h3><?php echo
|
517 |
-
<p><?php echo
|
518 |
</div>
|
519 |
</div>
|
520 |
<div class="saswp-sts-btn">
|
@@ -544,8 +575,8 @@ function saswp_premium_features_callback(){ ?>
|
|
544 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/recipe.png">
|
545 |
</div>
|
546 |
<div class="saswp-ele-tlt">
|
547 |
-
<h3><?php echo
|
548 |
-
<p><?php echo
|
549 |
</div>
|
550 |
</div>
|
551 |
<div class="saswp-sts-btn">
|
@@ -575,8 +606,8 @@ function saswp_premium_features_callback(){ ?>
|
|
575 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/event.png">
|
576 |
</div>
|
577 |
<div class="saswp-ele-tlt">
|
578 |
-
<h3><?php echo
|
579 |
-
<p><?php echo
|
580 |
</div>
|
581 |
</div>
|
582 |
<div class="saswp-sts-btn">
|
@@ -605,8 +636,8 @@ function saswp_premium_features_callback(){ ?>
|
|
605 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/course.png">
|
606 |
</div>
|
607 |
<div class="saswp-ele-tlt">
|
608 |
-
<h3><?php echo
|
609 |
-
<p><?php echo
|
610 |
</div>
|
611 |
</div>
|
612 |
<div class="saswp-sts-btn">
|
@@ -631,8 +662,8 @@ function saswp_premium_features_callback(){ ?>
|
|
631 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/woocommerce-icon.png">
|
632 |
</div>
|
633 |
<div class="saswp-ele-tlt">
|
634 |
-
<h3><?php echo
|
635 |
-
<p><?php echo
|
636 |
</div>
|
637 |
</div>
|
638 |
<div class="saswp-sts-btn">
|
@@ -661,8 +692,8 @@ function saswp_premium_features_callback(){ ?>
|
|
661 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/real-estate-schema-wp.png">
|
662 |
</div>
|
663 |
<div class="saswp-ele-tlt">
|
664 |
-
<h3><?php echo
|
665 |
-
<p><?php echo
|
666 |
</div>
|
667 |
</div>
|
668 |
<div class="saswp-sts-btn">
|
@@ -687,13 +718,13 @@ function saswp_services_callback(){ ?>
|
|
687 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/support-1.png">
|
688 |
</div>
|
689 |
<div class="saswp-ele-tlt">
|
690 |
-
<h3><?php echo
|
691 |
-
<p><?php echo
|
692 |
</div>
|
693 |
</div>
|
694 |
<a target="_blank" href="https://structured-data-for-wp.com/priority-support//">
|
695 |
<div class="saswp-sts-btn">
|
696 |
-
<span class="saswp-d-btn"><?php echo
|
697 |
</div>
|
698 |
</a>
|
699 |
|
@@ -704,13 +735,13 @@ function saswp_services_callback(){ ?>
|
|
704 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/news.png">
|
705 |
</div>
|
706 |
<div class="saswp-ele-tlt">
|
707 |
-
<h3><?php echo
|
708 |
-
<p><?php echo
|
709 |
</div>
|
710 |
</div>
|
711 |
<a target="_blank" href="http://structured-data-for-wp.com/services/google-news-schema-setup/">
|
712 |
<div class="saswp-sts-btn">
|
713 |
-
<span class="saswp-d-btn"><?php echo
|
714 |
</div>
|
715 |
</a>
|
716 |
|
@@ -721,13 +752,13 @@ function saswp_services_callback(){ ?>
|
|
721 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/schema-setup-icon.png">
|
722 |
</div>
|
723 |
<div class="saswp-ele-tlt">
|
724 |
-
<h3><?php echo
|
725 |
-
<p><?php echo
|
726 |
</div>
|
727 |
</div>
|
728 |
<a target="_blank" href="http://structured-data-for-wp.com/services/structured-data-setup-error-clean-up/">
|
729 |
<div class="saswp-sts-btn">
|
730 |
-
<span class="saswp-d-btn"><?php echo
|
731 |
</div>
|
732 |
</a>
|
733 |
|
@@ -767,7 +798,7 @@ function saswp_amp_page_callback(){
|
|
767 |
$non_amp_enable_field['attributes'] = array(
|
768 |
'disabled' => 'disabled'
|
769 |
);
|
770 |
-
$non_amp_enable_field['note'] =
|
771 |
$settings['saswp-for-amp'] = 0;
|
772 |
|
773 |
}
|
@@ -788,9 +819,9 @@ function saswp_amp_page_callback(){
|
|
788 |
)
|
789 |
);
|
790 |
echo '<div class="saswp-heading">';
|
791 |
-
echo '<h2>'.
|
792 |
echo '</div>';
|
793 |
-
echo '<p>'.
|
794 |
|
795 |
$field_objs->saswp_field_generator($meta_fields, $settings);
|
796 |
}
|
@@ -899,12 +930,12 @@ function saswp_general_page_callback(){
|
|
899 |
<div class="saswp-settings-list">
|
900 |
|
901 |
<div class="saswp-heading">
|
902 |
-
<h2><?php echo
|
903 |
</div>
|
904 |
-
<p><?php echo
|
905 |
<ul><li><div class="saswp-about-contact-page-tooltip"><label class="saswp-tooltip">
|
906 |
-
<?php echo
|
907 |
-
<span class="saswp-tooltiptext"><?php echo
|
908 |
</label>
|
909 |
</div>
|
910 |
<div>
|
@@ -926,7 +957,7 @@ function saswp_general_page_callback(){
|
|
926 |
}
|
927 |
if($saved_choices){
|
928 |
foreach($saved_choices as $value){
|
929 |
-
$html_str .= '<option value="' . esc_attr($value['id']) .'" selected> ' .
|
930 |
}
|
931 |
}
|
932 |
|
@@ -940,8 +971,8 @@ function saswp_general_page_callback(){
|
|
940 |
</li>
|
941 |
<li><div class="saswp-about-contact-page-tooltip">
|
942 |
<label class="saswp-tooltip">
|
943 |
-
<?php echo
|
944 |
-
<span class="saswp-tooltiptext"><?php echo
|
945 |
</label>
|
946 |
</div>
|
947 |
<div>
|
@@ -963,7 +994,7 @@ function saswp_general_page_callback(){
|
|
963 |
}
|
964 |
if($saved_choices){
|
965 |
foreach($saved_choices as $value){
|
966 |
-
$html_str .= '<option value="' . esc_attr($value['id']) .'" selected> ' .
|
967 |
}
|
968 |
}
|
969 |
|
@@ -1154,17 +1185,17 @@ function saswp_general_page_callback(){
|
|
1154 |
);
|
1155 |
|
1156 |
echo '<div class="saswp-heading">';
|
1157 |
-
echo '<h2>'.
|
1158 |
echo '</div>';
|
1159 |
-
echo '<p>'.
|
1160 |
echo '<div class="saswp-knowledge-base">';
|
1161 |
$field_objs->saswp_field_generator($meta_fields, $settings);
|
1162 |
echo '</div>';
|
1163 |
|
1164 |
//social
|
1165 |
-
echo '<h2>'.
|
1166 |
echo '<div class="saswp-social-fileds">';
|
1167 |
-
echo '<p>'.
|
1168 |
echo '<div class="saswp-social-links">';
|
1169 |
echo '<table class="saswp-social-links-table">';
|
1170 |
if(isset($settings['saswp_social_links']) && !empty($settings['saswp_social_links'])){
|
@@ -1207,7 +1238,7 @@ function saswp_general_page_callback(){
|
|
1207 |
'name' => 'sd_data[sd_default_image_height]',
|
1208 |
'class' => 'regular-text',
|
1209 |
'type' => 'text',
|
1210 |
-
'note' =>
|
1211 |
)
|
1212 |
|
1213 |
);
|
@@ -1231,9 +1262,9 @@ function saswp_general_page_callback(){
|
|
1231 |
}
|
1232 |
|
1233 |
echo '<div class="saswp-heading">';
|
1234 |
-
echo '<h2>'.
|
1235 |
echo '</div>';
|
1236 |
-
echo '<p>'.
|
1237 |
echo '<div class="saswp-schema-type-fields">';
|
1238 |
$field_objs->saswp_field_generator($meta_fields_default, $settings);
|
1239 |
echo '</div>';
|
@@ -1441,82 +1472,82 @@ function saswp_import_callback(){
|
|
1441 |
<div class="saswp-tools-container" id="saswp-tools-advanced-container">
|
1442 |
|
1443 |
<?php
|
1444 |
-
echo '<h2>'.
|
1445 |
$field_objs->saswp_field_generator($meta_fields, $settings);
|
1446 |
-
echo '<h2>'.
|
1447 |
?>
|
1448 |
<ul>
|
1449 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1450 |
<p class="saswp-imported-message"></p>
|
1451 |
-
<?php echo '<p>'.
|
1452 |
</div>
|
1453 |
</li>
|
1454 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1455 |
<p class="saswp-imported-message"></p>
|
1456 |
-
<?php echo '<p>'.
|
1457 |
</div>
|
1458 |
</li>
|
1459 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1460 |
<p class="saswp-imported-message"></p>
|
1461 |
-
<?php echo '<p>'.
|
1462 |
</div>
|
1463 |
</li>
|
1464 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1465 |
<p class="saswp-imported-message"></p>
|
1466 |
-
<?php echo '<p>'.
|
1467 |
</div>
|
1468 |
</li>
|
1469 |
|
1470 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1471 |
<p class="saswp-imported-message"></p>
|
1472 |
-
<?php echo '<p>'.
|
1473 |
</div>
|
1474 |
</li>
|
1475 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1476 |
<p class="saswp-imported-message"></p>
|
1477 |
-
<?php echo '<p>'.
|
1478 |
</div>
|
1479 |
</li>
|
1480 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1481 |
<p class="saswp-imported-message"></p>
|
1482 |
-
<?php echo '<p>'.
|
1483 |
</div>
|
1484 |
</li>
|
1485 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1486 |
<p class="saswp-imported-message"></p>
|
1487 |
-
<?php echo '<p>'.
|
1488 |
</div>
|
1489 |
</li>
|
1490 |
|
1491 |
-
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo
|
1492 |
<p class="saswp-imported-message"></p>
|
1493 |
-
<?php echo '<p>'.
|
1494 |
</div>
|
1495 |
</li>
|
1496 |
|
1497 |
</ul>
|
1498 |
<?php
|
1499 |
-
echo '<h2>'.
|
1500 |
$url = wp_nonce_url(admin_url('admin-ajax.php?action=saswp_export_all_settings_and_schema'), '_wpnonce');
|
1501 |
?>
|
1502 |
<ul>
|
1503 |
<li>
|
1504 |
-
<div class="saswp-tools-field-title"><div class="saswp-tooltip"><strong><?php echo
|
1505 |
</div>
|
1506 |
</li>
|
1507 |
<li>
|
1508 |
-
<div class="saswp-tools-field-title"><div class="saswp-tooltip"><strong><?php echo
|
1509 |
</div>
|
1510 |
</li>
|
1511 |
</ul>
|
1512 |
<?php
|
1513 |
-
echo '<h2>'.
|
1514 |
?>
|
1515 |
<ul>
|
1516 |
<li>
|
1517 |
<div class="saswp-tools-field-title">
|
1518 |
-
<div class="saswp-tooltip"><strong><?php echo
|
1519 |
-
<p><?php echo
|
1520 |
</div>
|
1521 |
</li>
|
1522 |
|
@@ -1525,8 +1556,8 @@ function saswp_import_callback(){
|
|
1525 |
<ul>
|
1526 |
<li>
|
1527 |
<div class="">
|
1528 |
-
<div class="saswp-tooltip"><strong><?php echo
|
1529 |
-
<p><?php echo
|
1530 |
</div>
|
1531 |
</li>
|
1532 |
|
@@ -1536,7 +1567,7 @@ function saswp_import_callback(){
|
|
1536 |
<li>
|
1537 |
<div class="saswp-tools-field-title">
|
1538 |
|
1539 |
-
<div class="saswp-tooltip"><strong><?php echo
|
1540 |
|
1541 |
<?php
|
1542 |
|
@@ -1550,7 +1581,7 @@ function saswp_import_callback(){
|
|
1550 |
'plugin' => $plugin,
|
1551 |
'plugin_action' => 'no'
|
1552 |
) );
|
1553 |
-
echo '<a href="'. esc_url_raw( $track_url ).'" class="button-secondary">'.
|
1554 |
|
1555 |
}else{
|
1556 |
|
@@ -1559,14 +1590,14 @@ function saswp_import_callback(){
|
|
1559 |
'plugin_action' => 'yes'
|
1560 |
));
|
1561 |
|
1562 |
-
echo '<a href="'. esc_url_raw( $track_url ).'" class="button-secondary">'.
|
1563 |
|
1564 |
}
|
1565 |
|
1566 |
?>
|
1567 |
|
1568 |
-
<p><?php echo
|
1569 |
-
<a target="_blank" href="https://structured-data-for-wp.com/docs/article/usage-data-tracking/"><?php echo
|
1570 |
</p>
|
1571 |
</div>
|
1572 |
</li>
|
@@ -1583,6 +1614,12 @@ function saswp_import_callback(){
|
|
1583 |
|
1584 |
}
|
1585 |
|
|
|
|
|
|
|
|
|
|
|
|
|
1586 |
if(is_plugin_active('jobposting-schema-compatibility/jobposting-schema-compatibility.php')){
|
1587 |
|
1588 |
$add_on[] = 'Jobposting';
|
@@ -1622,7 +1659,7 @@ function saswp_import_callback(){
|
|
1622 |
|
1623 |
if(!empty($add_on)){
|
1624 |
|
1625 |
-
echo '<h2>'.
|
1626 |
|
1627 |
echo '<ul>';
|
1628 |
|
@@ -1659,7 +1696,7 @@ function saswp_import_callback(){
|
|
1659 |
</div>
|
1660 |
<div class="saswp-tools-container" id="saswp-tools-translation-container">
|
1661 |
<?php
|
1662 |
-
echo '<h2>'.
|
1663 |
|
1664 |
global $translation_labels;
|
1665 |
|
@@ -1712,14 +1749,14 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1712 |
if($label == true && $on == 'Cooked'){
|
1713 |
|
1714 |
$response.= '<div class="" style="display:inline-block">';
|
1715 |
-
$response.= '<strong>'.
|
1716 |
$response.= '</div>';
|
1717 |
|
1718 |
}
|
1719 |
if($label == true && $on == 'Woocommerce'){
|
1720 |
|
1721 |
$response.= '<div class="" style="display:inline-block">';
|
1722 |
-
$response.= '<strong>'.
|
1723 |
$response.= '</div>';
|
1724 |
|
1725 |
}
|
@@ -1727,7 +1764,7 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1727 |
if($label == true && $on == 'Res'){
|
1728 |
|
1729 |
$response.= '<div class="" style="display:inline-block">';
|
1730 |
-
$response.= '<strong>'.
|
1731 |
$response.= '</div>';
|
1732 |
|
1733 |
}
|
@@ -1735,7 +1772,7 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1735 |
if($label == true && $on == 'Jobposting'){
|
1736 |
|
1737 |
$response.= '<div class="" style="display:inline-block">';
|
1738 |
-
$response.= '<strong>'.
|
1739 |
$response.= '</div>';
|
1740 |
|
1741 |
}
|
@@ -1743,14 +1780,14 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1743 |
if($label == true && $on == 'Cs'){
|
1744 |
|
1745 |
$response.= '<div class="" style="display:inline-block">';
|
1746 |
-
$response.= '<strong>'.
|
1747 |
$response.= '</div>';
|
1748 |
|
1749 |
}
|
1750 |
if($label == true && $on == 'Es'){
|
1751 |
|
1752 |
$response.= '<div class="" style="display:inline-block">';
|
1753 |
-
$response.= '<strong>'.
|
1754 |
$response.= '</div>';
|
1755 |
|
1756 |
}
|
@@ -1758,7 +1795,7 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1758 |
if($label == true && $on == 'qanda'){
|
1759 |
|
1760 |
$response.= '<div class="" style="display:inline-block">';
|
1761 |
-
$response.= '<strong>'.
|
1762 |
$response.= '</div>';
|
1763 |
|
1764 |
}
|
@@ -1766,7 +1803,7 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1766 |
if($label == true && $on == 'Rs'){
|
1767 |
|
1768 |
$response.= '<div class="" style="display:inline-block">';
|
1769 |
-
$response.= '<strong>'.
|
1770 |
$response.= '</div>';
|
1771 |
|
1772 |
}
|
@@ -1787,11 +1824,11 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1787 |
|
1788 |
if($license_status == 'active'){
|
1789 |
|
1790 |
-
$response.= '<a license-status="inactive" add-on="'.strtolower($on).'" class="button button-default saswp_license_activation">'.
|
1791 |
|
1792 |
}else{
|
1793 |
|
1794 |
-
$response.= '<a license-status="active" add-on="'.strtolower($on).'" class="button button-default saswp_license_activation">'.
|
1795 |
|
1796 |
}
|
1797 |
|
@@ -1800,7 +1837,7 @@ function saswp_get_license_section_html($on, $license_key, $license_status, $lic
|
|
1800 |
$response.= '<p style="color:red;" add-on="'.strtolower($on).'" class="saswp_license_status_msg">'.$license_status_msg.'</p>';
|
1801 |
}
|
1802 |
|
1803 |
-
$response.= '<p>'.
|
1804 |
|
1805 |
$response.= '</div>';
|
1806 |
|
@@ -1870,9 +1907,9 @@ function saswp_review_page_callback(){
|
|
1870 |
|
1871 |
?>
|
1872 |
<div class="saswp-quick-links-div">
|
1873 |
-
<h4><?php echo
|
1874 |
-
<p><a href="<?php echo admin_url('edit.php?post_type=saswp_reviews'); ?>"><?php echo
|
1875 |
-
<p><a target="_blank" href="https://structured-data-for-wp.com/docs/article/how-to-display-reviews-with-collection-feature/"><?php echo
|
1876 |
</div>
|
1877 |
|
1878 |
</div>
|
@@ -1935,13 +1972,13 @@ function saswp_email_schema_callback(){
|
|
1935 |
|
1936 |
if(!is_plugin_active('woocommerce/woocommerce.php') || !is_plugin_active('woocommerce-bookings/woocommerce-bookings.php')){
|
1937 |
|
1938 |
-
$woocommerce['note'] =
|
1939 |
|
1940 |
}
|
1941 |
|
1942 |
if(!is_plugin_active('woocommerce-compatibility-for-schema/woocommerce-compatibility-for-schema.php')){
|
1943 |
|
1944 |
-
$woocommerce['note'] =
|
1945 |
|
1946 |
}
|
1947 |
|
@@ -1996,6 +2033,19 @@ function saswp_compatibility_page_callback(){
|
|
1996 |
)
|
1997 |
);
|
1998 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1999 |
$simplejobboard = array(
|
2000 |
'label' => 'Simple Job Board',
|
2001 |
'id' => 'saswp-simplejobboard-checkbox',
|
@@ -3167,6 +3217,18 @@ function saswp_compatibility_page_callback(){
|
|
3167 |
'name' => 'sd_data[saswp-yoast]',
|
3168 |
)
|
3169 |
);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3170 |
$slimseo = array(
|
3171 |
'label' => 'Slim SEO',
|
3172 |
'id' => 'saswp-slimseo-checkbox',
|
@@ -3269,100 +3331,104 @@ function saswp_compatibility_page_callback(){
|
|
3269 |
|
3270 |
if(!is_plugin_active('woocommerce-compatibility-for-schema/woocommerce-compatibility-for-schema.php')){
|
3271 |
|
3272 |
-
$woocommerce_bok['note'] =
|
3273 |
|
3274 |
}
|
3275 |
|
3276 |
if(!is_plugin_active('cooked-compatibility-for-schema/cooked-compatibility-for-schema.php')){
|
3277 |
|
3278 |
-
$cooked['note'] =
|
3279 |
|
3280 |
}
|
3281 |
|
3282 |
if(!is_plugin_active('real-estate-schema/real-estate-schema.php')){
|
3283 |
|
3284 |
-
$homeland_theme['note'] =
|
3285 |
-
$real_homes['note'] =
|
3286 |
-
$wpresidence['note'] =
|
3287 |
-
$myhome['note'] =
|
3288 |
-
$realestate_5['note'] =
|
3289 |
-
$geo_directory['note'] =
|
3290 |
|
3291 |
}
|
3292 |
|
3293 |
if(!is_plugin_active('course-schema-for-saswp/course-schema-for-saswp.php')){
|
3294 |
|
3295 |
-
$learn_press['note'] =
|
3296 |
-
$learn_dash['note'] =
|
3297 |
-
$lifter_lms['note'] =
|
3298 |
-
$wplms['note'] =
|
3299 |
-
$senseilms['note'] =
|
3300 |
|
3301 |
}
|
3302 |
|
3303 |
if(!is_plugin_active('jobposting-schema-compatibility/jobposting-schema-compatibility.php')){
|
3304 |
|
3305 |
-
$simplejobboard['note'] =
|
3306 |
-
$wpjobopenings['note'] =
|
3307 |
-
$wpjobmanager['note'] =
|
3308 |
|
3309 |
}
|
3310 |
|
3311 |
if(!is_plugin_active('faq-schema-compatibility/faq-schema-compatibility.php')){
|
3312 |
|
3313 |
-
$quickandeasyfaq['note'] =
|
3314 |
-
$accordionfaq['note'] =
|
3315 |
-
$helpiefaq['note'] =
|
3316 |
-
$ultimatefaqs['note'] =
|
3317 |
-
$arconixfaq['note'] =
|
3318 |
-
$wpresponsivefaq['note'] =
|
3319 |
-
$easyaccordion['note'] =
|
3320 |
-
$html5responsivefaq['note'] =
|
3321 |
-
$faqconcertina['note'] =
|
3322 |
-
$accordion['note'] =
|
3323 |
-
$easyfaqs['note'] =
|
3324 |
-
$masteraccordion['note'] =
|
3325 |
-
$wpfaqschemamarkup['note'] =
|
3326 |
-
$faqschemaforpost['note'] =
|
3327 |
-
$webfaq10['note'] =
|
3328 |
|
3329 |
}
|
|
|
|
|
|
|
|
|
3330 |
if(!is_plugin_active('qanda-schema-for-saswp/qanda-schema-for-saswp.php')){
|
3331 |
|
3332 |
-
$sabaidiscuss['note'] =
|
3333 |
}
|
3334 |
|
3335 |
if(!is_plugin_active('event-schema-for-saswp/event-schema-for-saswp.php')){
|
3336 |
|
3337 |
-
$the_events_calendar['note'] =
|
3338 |
-
$events_calendar_wd['note'] =
|
3339 |
-
$wp_event_manager['note'] =
|
3340 |
-
$events_manager['note'] =
|
3341 |
-
$event_organiser['note'] =
|
3342 |
-
$modern_events_calendar['note'] =
|
3343 |
-
$tevolution_events['note'] =
|
3344 |
-
$wp_event_aggregator['note'] =
|
3345 |
-
$stachethemes_events['note'] =
|
3346 |
-
$timetable_event['note'] =
|
3347 |
-
$xo_event_calendar['note'] =
|
3348 |
-
$events_schedule['note'] =
|
3349 |
-
$calendarize_it['note'] =
|
3350 |
-
$woo_event_manager['note'] =
|
3351 |
-
$vs_event_list['note'] =
|
3352 |
-
$all_in_one_event_calendar['note'] =
|
3353 |
-
$event_on['note'] =
|
3354 |
|
3355 |
}
|
3356 |
|
3357 |
if(!is_plugin_active('recipe-schema-for-saswp/recipe-schema-for-saswp.php')){
|
3358 |
|
3359 |
-
$zip_recipes['note'] =
|
3360 |
-
$wp_ultimate_recipe['note'] =
|
3361 |
-
$mediavine_create['note'] =
|
3362 |
-
$ht_recipes['note'] =
|
3363 |
-
$easyrecipe['note'] =
|
3364 |
-
$total_recipe_generator['note'] =
|
3365 |
-
$ranna_recipe['note'] =
|
3366 |
|
3367 |
}
|
3368 |
|
@@ -3395,6 +3461,8 @@ function saswp_compatibility_page_callback(){
|
|
3395 |
$dwquestiton,
|
3396 |
$sabaidiscuss,
|
3397 |
$yoast,
|
|
|
|
|
3398 |
$slimseo,
|
3399 |
$smart_crawl,
|
3400 |
$seo_press,
|
@@ -3559,7 +3627,7 @@ function saswp_compatibility_page_callback(){
|
|
3559 |
if ( is_plugin_active('flexmls-idx/flexmls_connect.php') && isset($settings['saswp-flexmlx-compativility']) && $settings['saswp-flexmlx-compativility'] == 1) {
|
3560 |
|
3561 |
echo '<div class="saswp-seller-div">';
|
3562 |
-
echo '<strong>'.
|
3563 |
|
3564 |
$field_objs->saswp_field_generator($flex_mlx_extra_fields, $settings);
|
3565 |
|
@@ -3614,7 +3682,7 @@ function saswp_support_page_callback(){
|
|
3614 |
|
3615 |
?>
|
3616 |
<div class="saswp_support_div">
|
3617 |
-
<strong><?php echo
|
3618 |
|
3619 |
<ul>
|
3620 |
<li>
|
@@ -3622,39 +3690,39 @@ function saswp_support_page_callback(){
|
|
3622 |
</li>
|
3623 |
<li>
|
3624 |
<div><textarea rows="5" cols="60" id="saswp_query_message" name="saswp_query_message" placeholder="Write your query"></textarea></div>
|
3625 |
-
<span class="saswp-query-success saswp_hide"><?php echo
|
3626 |
-
<span class="saswp-query-error saswp_hide"><?php echo
|
3627 |
</li>
|
3628 |
<li>
|
3629 |
-
<strong><?php echo
|
3630 |
<select id="saswp_query_premium_cus" name="saswp_query_premium_cus">
|
3631 |
-
<option value=""><?php echo
|
3632 |
-
<option value="yes"><?php echo
|
3633 |
-
<option value="no"><?php echo
|
3634 |
</select>
|
3635 |
</li>
|
3636 |
-
<li><button class="button saswp-send-query"><?php echo
|
3637 |
</ul>
|
3638 |
|
3639 |
</div>
|
3640 |
<?php
|
3641 |
|
3642 |
-
echo '<h1>'.
|
3643 |
<br>
|
3644 |
-
<h3>1Q) '.
|
3645 |
-
<p class="saswp_qanda_p">A) '.
|
3646 |
|
3647 |
-
<h3>2Q) '.
|
3648 |
-
<p class="saswp_qanda_p">A) '.
|
3649 |
|
3650 |
-
<h3>3Q) '.
|
3651 |
<p class="saswp_qanda_p">A) To check the code, the first step we need to take is to copy the code of a page or post then visit the <a href="https://search.google.com/structured-data/testing-tool" target="_blank">Structured data testing tool</a> by clicking on code snippet. Once we paste the snippet we can run the test.</p>
|
3652 |
|
3653 |
-
<h3> 4Q) '.
|
3654 |
-
<p class="saswp_qanda_p"> A) '.
|
3655 |
|
3656 |
-
<h3>5Q) '.
|
3657 |
-
<p class="saswp_qanda_p">A) '.
|
3658 |
}
|
3659 |
|
3660 |
/**
|
@@ -3665,26 +3733,26 @@ function saswp_enqueue_style_js( $hook ) {
|
|
3665 |
global $saswp_metaboxes;
|
3666 |
|
3667 |
$translable_txt = array(
|
3668 |
-
'attach_review' =>
|
3669 |
-
'place_id' =>
|
3670 |
-
'reviews' =>
|
3671 |
-
'fetch' =>
|
3672 |
-
'step_in' =>
|
3673 |
-
'blocks_zero' =>
|
3674 |
-
'success' =>
|
3675 |
-
'enter_place_id' =>
|
3676 |
-
'enter_api_key' =>
|
3677 |
-
'enter_rv_api_key' =>
|
3678 |
-
'using_schema' =>
|
3679 |
-
'do_you_want' =>
|
3680 |
-
'sd_update' =>
|
3681 |
-
'before_others' =>
|
3682 |
-
'fill_email' =>
|
3683 |
-
'invalid_email' =>
|
3684 |
-
'list_id_invalid' =>
|
3685 |
-
'already_subsribed' =>
|
3686 |
-
'subsribed' =>
|
3687 |
-
'try_again' =>
|
3688 |
);
|
3689 |
|
3690 |
$post_type = '';
|
@@ -3720,9 +3788,9 @@ function saswp_enqueue_style_js( $hook ) {
|
|
3720 |
'page_now' => $hook,
|
3721 |
'saswp_settings_url' => esc_url(admin_url('edit.php?post_type=saswp&page=structured_data_options')),
|
3722 |
'saswp_schema_types' => $all_schema_array,
|
3723 |
-
'trans_based_on' => saswp_label_text('translation-based-on'),
|
3724 |
-
'trans_reviews' => saswp_label_text('translation-reviews'),
|
3725 |
-
'trans_self' => saswp_label_text('translation-self'),
|
3726 |
'translable_txt' => $translable_txt
|
3727 |
);
|
3728 |
|
23 |
|
24 |
if(is_array($links)){
|
25 |
|
26 |
+
$links[] = '<a href="' . esc_url( admin_url( 'edit.php?post_type=saswp&page=structured_data_options' ) ) . '">' . saswp_t_string( 'Settings' ) . '</a>';
|
27 |
+
$links[] = '<a href="'. esc_url( admin_url( 'plugins.php?page=saswp-setup-wizard' ).'&_saswp_nonce='.$nonce).'">' . saswp_t_string( 'Setup Wizard' ) . '</a>';
|
28 |
+
$links[] = '<a target="_blank" href="http://structured-data-for-wp.com/docs/">' . saswp_t_string( 'Documentation' ) . '</a>';
|
29 |
|
30 |
}
|
31 |
|
65 |
function saswp_add_menu_links() {
|
66 |
|
67 |
add_submenu_page( 'edit.php?post_type=saswp',
|
68 |
+
saswp_t_string( 'Schema & Structured Data For Wp' ),
|
69 |
+
saswp_t_string( 'Settings' ),
|
70 |
saswp_current_user_can(),
|
71 |
'structured_data_options',
|
72 |
'saswp_admin_interface_render'
|
73 |
);
|
74 |
|
75 |
if(!saswp_ext_installed_status()){
|
76 |
+
add_submenu_page( 'edit.php?post_type=saswp', saswp_t_string( 'Schema & Structured Data For Wp' ), '<span class="saswp-upgrade-to-pro" style="color:#fff176;">'.saswp_t_string( 'Upgrade To Premium' ).'</span>', 'manage_options', 'structured_data_premium', 'saswp_premium_interface_render' );
|
77 |
}
|
78 |
|
79 |
}
|
105 |
?>
|
106 |
<div class="saswp-settings-container">
|
107 |
<div class="wrap saswp-settings-form saswp-settings-first-div" style="<?php echo( saswp_ext_installed_status()? 'width:100%;':''); ?>">
|
108 |
+
<h1 class="wp-heading-inline"> <?php echo saswp_t_string( 'Schema & Structured Data For WP' ); ?> <a href="<?php echo esc_url( admin_url( 'edit.php?post_type=saswp' ) ); ?>" class="page-title-action"><?php echo saswp_t_string( 'Schema Types' ); ?></a></h1><br>
|
109 |
<div>
|
110 |
<h2 class="nav-tab-wrapper saswp-tabs">
|
111 |
|
112 |
<?php
|
113 |
|
114 |
+
echo '<a href="' . esc_url(saswp_admin_link('general')) . '" class="nav-tab ' . esc_attr( $tab == 'general' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Global') . '</a>';
|
115 |
|
116 |
+
echo '<a href="' . esc_url(saswp_admin_link('amp')) . '" class="nav-tab ' . esc_attr( $tab == 'amp' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('AMP') . '</a>';
|
117 |
|
118 |
+
echo '<a href="' . esc_url(saswp_admin_link('review')) . '" class="nav-tab ' . esc_attr( $tab == 'review' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Review') . '</a>';
|
119 |
|
120 |
+
echo '<a href="' . esc_url(saswp_admin_link('compatibility')) . '" class="nav-tab ' . esc_attr( $tab == 'compatibility' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Compatibility') . '</a>';
|
121 |
|
122 |
+
echo '<a href="' . esc_url(saswp_admin_link('email_schema')) . '" class="nav-tab ' . esc_attr( $tab == 'email_schema' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Email Schema') . '</a>';
|
123 |
|
124 |
+
echo '<a href="' . esc_url(saswp_admin_link('tools')) . '" class="nav-tab ' . esc_attr( $tab == 'tools' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Advanced') . '</a>';
|
125 |
|
126 |
+
echo '<a href="' . esc_url(saswp_admin_link('premium_features')) . '" class="nav-tab ' . esc_attr( $tab == 'premium_features' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Premium Features') . '</a>';
|
127 |
|
128 |
+
echo '<a href="' . esc_url(saswp_admin_link('services')) . '" class="nav-tab ' . esc_attr( $tab == 'services' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Services') . '</a>';
|
129 |
|
130 |
+
echo '<a href="' . esc_url(saswp_admin_link('support')) . '" class="nav-tab ' . esc_attr( $tab == 'support' ? 'nav-tab-active' : '') . '"><span class=""></span> ' . saswp_t_string('Support') . '</a>';
|
131 |
?>
|
132 |
|
133 |
</h2>
|
144 |
|
145 |
echo '<div id="saswp-global-tabs" style="margin-top: 10px;">';
|
146 |
|
147 |
+
echo '<a data-id="saswp-general-container">'.saswp_t_string('General Settings').'</a> | <a data-id="saswp-knowledge-container">'.saswp_t_string('Knowledge Graph').'</a> | <a data-id="saswp-default-container" >'.saswp_t_string('Default Data').'</a>';
|
148 |
|
149 |
echo'</div> ';
|
150 |
|
161 |
|
162 |
echo '<div id="saswp-review-tabs" style="margin-top: 10px;">';
|
163 |
|
164 |
+
echo '<a data-id="saswp-review-reviews-container">'.saswp_t_string('Reviews Module').'</a> | <a data-id="saswp-review-rating-container">'.saswp_t_string('Rating Module').'</a>';
|
165 |
|
166 |
echo'</div> ';
|
167 |
|
174 |
|
175 |
echo '<div id="saswp-compatibility-tabs" style="margin-top: 10px;">';
|
176 |
|
177 |
+
echo '<a data-id="saswp-active-compatibility-container">'.saswp_t_string('Active').'</a> | <a data-id="saswp-inactive-compatibility-container">'.saswp_t_string('InActive').'</a>';
|
178 |
|
179 |
echo'</div> ';
|
180 |
|
190 |
|
191 |
echo '<div id="saswp-tools-tabs" style="margin-top: 10px;">';
|
192 |
|
193 |
+
echo '<a data-id="saswp-tools-advanced-container">'.saswp_t_string('Advanced').'</a> | <a data-id="saswp-tools-translation-container">'.saswp_t_string('Translation Panel').'</a>';
|
194 |
|
195 |
echo'</div> ';
|
196 |
// Status
|
218 |
<div class="button-wrapper">
|
219 |
<?php
|
220 |
// Output save settings button
|
221 |
+
submit_button( saswp_t_string('Save Settings') );
|
222 |
?>
|
223 |
</div>
|
224 |
<input type="hidden" name="sd_data[sd_initial_wizard_status]" value="1">
|
227 |
<div class="saswp-settings-second-div">
|
228 |
<!-- <a target="_blank" href="http://structured-data-for-wp.com/pricing/">
|
229 |
<div class="saswp-upgrade-pro promo-cpn">
|
230 |
+
<h2><?php echo saswp_t_string('50% OFF on PRO') ?></h2>
|
231 |
+
<span><?php echo saswp_t_string('Limited Time Offer for this festive season') ?></span>
|
232 |
<div class="saswp-promo">
|
233 |
+
<span class="prm-txt"><?php echo saswp_t_string('Promo:') ?></span>
|
234 |
+
<span class="prm-cpn"><?php echo saswp_t_string('BFCM2019') ?></span>
|
235 |
</div>
|
236 |
</div>
|
237 |
</a>-->
|
238 |
<?php if(!saswp_ext_installed_status()) { ?>
|
239 |
<div class="saswp-upgrade-pro">
|
240 |
+
<h2><?php echo saswp_t_string('Upgrade to Pro!') ?></h2>
|
241 |
<ul>
|
242 |
+
<li><?php echo saswp_t_string('Premium features') ?></li>
|
243 |
+
<li><?php echo saswp_t_string('Dedicated Schema Support') ?></li>
|
244 |
+
<li><?php echo saswp_t_string('Active Development') ?></li>
|
245 |
</ul>
|
246 |
+
<a target="_blank" href="http://structured-data-for-wp.com/pricing/"><?php echo saswp_t_string('UPGRADE') ?></a>
|
247 |
</div>
|
248 |
<?php } ?>
|
249 |
</div>
|
398 |
function saswp_premium_features_callback(){ ?>
|
399 |
<div class="saswp-pre-ftrs-wrap">
|
400 |
<ul class="saswp-features-blocks">
|
401 |
+
|
402 |
+
<li>
|
403 |
+
|
404 |
+
<?php
|
405 |
+
|
406 |
+
$cooked_active_text = '';
|
407 |
+
|
408 |
+
if(is_plugin_active('polylang-compatibility-for-saswp/polylang-compatibility-for-saswp.php')){
|
409 |
+
$cooked_active_text = '<label class="saswp-sts-txt">Status :<span style="color:green;">Active</span></label>';
|
410 |
+
}else{
|
411 |
+
$cooked_active_text .='<label class="saswp-sts-txt">Status :<span>Inactive</span></label>';
|
412 |
+
$cooked_active_text .='<a target="_blank" href="http://structured-data-for-wp.com/extensions/"><span class="saswp-d-btn">Download</span></a>';
|
413 |
+
}
|
414 |
+
|
415 |
+
?>
|
416 |
+
|
417 |
+
<div class="saswp-features-ele">
|
418 |
+
<div class="saswp-ele-ic" style="background: #509207;">
|
419 |
+
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/polylang.png">
|
420 |
+
</div>
|
421 |
+
<div class="saswp-ele-tlt">
|
422 |
+
<h3><?php echo saswp_t_string('Polylang Compatibility for SASWP') ?></h3>
|
423 |
+
<p><?php echo saswp_t_string('It adds all the static labels from this plugin to Polylang Strings Translations dashboard where user can translate it') ?></p>
|
424 |
+
</div>
|
425 |
+
</div>
|
426 |
+
<div class="saswp-sts-btn">
|
427 |
+
|
428 |
+
<?php echo $cooked_active_text; ?>
|
429 |
+
|
430 |
+
</div>
|
431 |
+
</li>
|
432 |
+
|
433 |
<li>
|
434 |
|
435 |
<?php
|
450 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/customer-review.png">
|
451 |
</div>
|
452 |
<div class="saswp-ele-tlt">
|
453 |
+
<h3><?php echo saswp_t_string('Reviews for Schema') ?></h3>
|
454 |
+
<p><?php echo saswp_t_string('Fetch reviews from 75+ platforms with a single click with proper structured data so you can get the stars in your search engine rankings. It also works for the AMP.') ?></p>
|
455 |
</div>
|
456 |
</div>
|
457 |
<div class="saswp-sts-btn">
|
481 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/jobposting.png">
|
482 |
</div>
|
483 |
<div class="saswp-ele-tlt">
|
484 |
+
<h3><?php echo saswp_t_string('JobPosting Schema Compatibility') ?></h3>
|
485 |
+
<p><?php echo saswp_t_string(' JobPosting Schema Compatibility extension is the number one solution to enhance your JOBs website with the right structured data.') ?></p>
|
486 |
</div>
|
487 |
</div>
|
488 |
<div class="saswp-sts-btn">
|
512 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/faq.png">
|
513 |
</div>
|
514 |
<div class="saswp-ele-tlt">
|
515 |
+
<h3><?php echo saswp_t_string('FAQ Schema Compatibility') ?></h3>
|
516 |
+
<p><?php echo saswp_t_string(' FAQ Schema Compatibility extension is the number one solution to enhance your FAQs website with the right structured data.') ?></p>
|
517 |
</div>
|
518 |
</div>
|
519 |
<div class="saswp-sts-btn">
|
544 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/question.png">
|
545 |
</div>
|
546 |
<div class="saswp-ele-tlt">
|
547 |
+
<h3><?php echo saswp_t_string('Q&A Schema Compatibility') ?></h3>
|
548 |
+
<p><?php echo saswp_t_string(' extension is the number one solution to enhance your discussion forum website with the right structured data.') ?></p>
|
549 |
</div>
|
550 |
</div>
|
551 |
<div class="saswp-sts-btn">
|
575 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/recipe.png">
|
576 |
</div>
|
577 |
<div class="saswp-ele-tlt">
|
578 |
+
<h3><?php echo saswp_t_string('Recipe Schema') ?></h3>
|
579 |
+
<p><?php echo saswp_t_string('Recipe Schema extension is the number one solution to enhance your recipe website with the right structured data.') ?></p>
|
580 |
</div>
|
581 |
</div>
|
582 |
<div class="saswp-sts-btn">
|
606 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/event.png">
|
607 |
</div>
|
608 |
<div class="saswp-ele-tlt">
|
609 |
+
<h3><?php echo saswp_t_string('Event Schema') ?></h3>
|
610 |
+
<p><?php echo saswp_t_string('Event Schema extension is the number one solution to enhance your event website with the right structured data.') ?></p>
|
611 |
</div>
|
612 |
</div>
|
613 |
<div class="saswp-sts-btn">
|
636 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/course.png">
|
637 |
</div>
|
638 |
<div class="saswp-ele-tlt">
|
639 |
+
<h3><?php echo saswp_t_string('Course Schema') ?></h3>
|
640 |
+
<p><?php echo saswp_t_string('Course Schema extension is the number one solution to enhance your course offering website with the right structured data.') ?></p>
|
641 |
</div>
|
642 |
</div>
|
643 |
<div class="saswp-sts-btn">
|
662 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/woocommerce-icon.png">
|
663 |
</div>
|
664 |
<div class="saswp-ele-tlt">
|
665 |
+
<h3><?php echo saswp_t_string('WooCommerce Compatibility for Schema') ?></h3>
|
666 |
+
<p><?php echo saswp_t_string('WooCommerce Compatibility extension is the number one solution to enhance your store with the right structured data.') ?></p>
|
667 |
</div>
|
668 |
</div>
|
669 |
<div class="saswp-sts-btn">
|
692 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/real-estate-schema-wp.png">
|
693 |
</div>
|
694 |
<div class="saswp-ele-tlt">
|
695 |
+
<h3><?php echo saswp_t_string('Real Estate Schema') ?></h3>
|
696 |
+
<p><?php echo saswp_t_string('Real Estate Schema extension is the number one solution to enhance your real estate website with the right structured data.') ?></p>
|
697 |
</div>
|
698 |
</div>
|
699 |
<div class="saswp-sts-btn">
|
718 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/support-1.png">
|
719 |
</div>
|
720 |
<div class="saswp-ele-tlt">
|
721 |
+
<h3><?php echo saswp_t_string('Priority Support') ?></h3>
|
722 |
+
<p><?php echo saswp_t_string('We get more than 100 technical queries a day but the Priority support plan will help you skip that and get the help from a dedicated team.') ?></p>
|
723 |
</div>
|
724 |
</div>
|
725 |
<a target="_blank" href="https://structured-data-for-wp.com/priority-support//">
|
726 |
<div class="saswp-sts-btn">
|
727 |
+
<span class="saswp-d-btn"><?php echo saswp_t_string('Try it') ?></span>
|
728 |
</div>
|
729 |
</a>
|
730 |
|
735 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/news.png">
|
736 |
</div>
|
737 |
<div class="saswp-ele-tlt">
|
738 |
+
<h3><?php echo saswp_t_string('Google News Schema Setup') ?></h3>
|
739 |
+
<p><?php echo saswp_t_string('Get quick approval to Google News with our service. Our structured data experts will set up the Google News schema properly on your website.') ?></p>
|
740 |
</div>
|
741 |
</div>
|
742 |
<a target="_blank" href="http://structured-data-for-wp.com/services/google-news-schema-setup/">
|
743 |
<div class="saswp-sts-btn">
|
744 |
+
<span class="saswp-d-btn"><?php echo saswp_t_string('Try it') ?></span>
|
745 |
</div>
|
746 |
</a>
|
747 |
|
752 |
<img src="<?php echo SASWP_PLUGIN_URL; ?>/admin_section/images/schema-setup-icon.png">
|
753 |
</div>
|
754 |
<div class="saswp-ele-tlt">
|
755 |
+
<h3><?php echo saswp_t_string('Structured Data Setup & Error Clean Up') ?></h3>
|
756 |
+
<p><?php echo saswp_t_string('We will help you setup Schema and Structured data on your website as per your requirements and as per recommendation by our expert developers.') ?></p>
|
757 |
</div>
|
758 |
</div>
|
759 |
<a target="_blank" href="http://structured-data-for-wp.com/services/structured-data-setup-error-clean-up/">
|
760 |
<div class="saswp-sts-btn">
|
761 |
+
<span class="saswp-d-btn"><?php echo saswp_t_string('Try it') ?></span>
|
762 |
</div>
|
763 |
</a>
|
764 |
|
798 |
$non_amp_enable_field['attributes'] = array(
|
799 |
'disabled' => 'disabled'
|
800 |
);
|
801 |
+
$non_amp_enable_field['note'] = saswp_t_string('Requires'). ' <a target="_blank" href="https://wordpress.org/plugins/accelerated-mobile-pages/">AMP for WP</a> or <a target="_blank" href="https://wordpress.org/plugins/amp/">AMP</a> or <a target="_blank" href="https://wordpress.org/plugins/better-amp/">Better AMP</a> or <a target="_blank" href="https://codecanyon.net/item/wp-amp-accelerated-mobile-pages-for-wordpress-and-woocommerce/16278608">WP AMP</a>';
|
802 |
$settings['saswp-for-amp'] = 0;
|
803 |
|
804 |
}
|
819 |
)
|
820 |
);
|
821 |
echo '<div class="saswp-heading">';
|
822 |
+
echo '<h2>'.saswp_t_string('Enable On').'</h2>';
|
823 |
echo '</div>';
|
824 |
+
echo '<p>'.saswp_t_string('Using this option, one can hide and show schema markup on AMP and Non AMP').'</p>';
|
825 |
|
826 |
$field_objs->saswp_field_generator($meta_fields, $settings);
|
827 |
}
|
930 |
<div class="saswp-settings-list">
|
931 |
|
932 |
<div class="saswp-heading">
|
933 |
+
<h2><?php echo saswp_t_string('General Settings'); ?></h2>
|
934 |
</div>
|
935 |
+
<p><?php echo saswp_t_string('This is a global schema settings, to display about, contact, website, archive, breadcrumbs, comments and site navigation schema type.') ?> <a target="_blank" href="http://structured-data-for-wp.com/docs/article/what-is-general-settings-in-schema/"><?php echo saswp_t_string('Learn More') ?></a></p>
|
936 |
<ul><li><div class="saswp-about-contact-page-tooltip"><label class="saswp-tooltip">
|
937 |
+
<?php echo saswp_t_string('About') ?>
|
938 |
+
<span class="saswp-tooltiptext"><?php echo saswp_t_string('Set the about page of of your website') ?></span>
|
939 |
</label>
|
940 |
</div>
|
941 |
<div>
|
957 |
}
|
958 |
if($saved_choices){
|
959 |
foreach($saved_choices as $value){
|
960 |
+
$html_str .= '<option value="' . esc_attr($value['id']) .'" selected> ' . saswp_t_string($value['text']) .'</option>';
|
961 |
}
|
962 |
}
|
963 |
|
971 |
</li>
|
972 |
<li><div class="saswp-about-contact-page-tooltip">
|
973 |
<label class="saswp-tooltip">
|
974 |
+
<?php echo saswp_t_string('Contact') ?>
|
975 |
+
<span class="saswp-tooltiptext"><?php echo saswp_t_string('Set the contact us page of your website') ?></span>
|
976 |
</label>
|
977 |
</div>
|
978 |
<div>
|
994 |
}
|
995 |
if($saved_choices){
|
996 |
foreach($saved_choices as $value){
|
997 |
+
$html_str .= '<option value="' . esc_attr($value['id']) .'" selected> ' . saswp_t_string($value['text']) .'</option>';
|
998 |
}
|
999 |
}
|
1000 |
|
1185 |
);
|
1186 |
|
1187 |
echo '<div class="saswp-heading">';
|
1188 |
+
echo '<h2>'.saswp_t_string('Knowledge Graph').'</h2>';
|
1189 |
echo '</div>';
|
1190 |
+
echo '<p>'.saswp_t_string('The Knowledge Graph is a knowledge base used by Google and its services to enhance its search engine\'s results.').' <a target="_blank" href="http://structured-data-for-wp.com/docs/article/how-to-setup-knowledge-graph-in-schema-in-wordpress/">'.saswp_t_string('Learn More').'</a> </p>';
|
1191 |
echo '<div class="saswp-knowledge-base">';
|
1192 |
$field_objs->saswp_field_generator($meta_fields, $settings);
|
1193 |
echo '</div>';
|
1194 |
|
1195 |
//social
|
1196 |
+
echo '<h2>'.saswp_t_string( 'Social Profile' ).'</h2>';
|
1197 |
echo '<div class="saswp-social-fileds">';
|
1198 |
+
echo '<p>'.saswp_t_string('Add your social profile, Google will automatically crawl it in Knowledge Graph').' <a target="_blank" href="https://structured-data-for-wp.com/docs/">'.saswp_t_string('Learn More').'</a></p>';
|
1199 |
echo '<div class="saswp-social-links">';
|
1200 |
echo '<table class="saswp-social-links-table">';
|
1201 |
if(isset($settings['saswp_social_links']) && !empty($settings['saswp_social_links'])){
|
1238 |
'name' => 'sd_data[sd_default_image_height]',
|
1239 |
'class' => 'regular-text',
|
1240 |
'type' => 'text',
|
1241 |
+
'note' => saswp_t_string('According to google validation tool, Image size must be greater than or equal to 1200*728')
|
1242 |
)
|
1243 |
|
1244 |
);
|
1262 |
}
|
1263 |
|
1264 |
echo '<div class="saswp-heading">';
|
1265 |
+
echo '<h2>'.saswp_t_string('Default Data').'</h2>';
|
1266 |
echo '</div>';
|
1267 |
+
echo '<p>'.saswp_t_string('If schema markup doest not have image, it adds this image to validate schema markup.').' <a target="_blank" href="http://structured-data-for-wp.com/docs/article/how-to-set-up-the-default-structured-data-values/">'.saswp_t_string('Learn More').'</a></p>';
|
1268 |
echo '<div class="saswp-schema-type-fields">';
|
1269 |
$field_objs->saswp_field_generator($meta_fields_default, $settings);
|
1270 |
echo '</div>';
|
1472 |
<div class="saswp-tools-container" id="saswp-tools-advanced-container">
|
1473 |
|
1474 |
<?php
|
1475 |
+
echo '<h2>'.saswp_t_string('Advanced Settings').'</h2>';
|
1476 |
$field_objs->saswp_field_generator($meta_fields, $settings);
|
1477 |
+
echo '<h2>'.saswp_t_string('Migration').'</h2>';
|
1478 |
?>
|
1479 |
<ul>
|
1480 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('Schema Plugin'); ?></strong></div><button data-id="schema" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1481 |
<p class="saswp-imported-message"></p>
|
1482 |
+
<?php echo '<p>'.saswp_t_string($schema_message).'</p>'; ?>
|
1483 |
</div>
|
1484 |
</li>
|
1485 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('Schema Pro'); ?></strong></div><button data-id="schema_pro" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1486 |
<p class="saswp-imported-message"></p>
|
1487 |
+
<?php echo '<p>'.saswp_t_string($schema_pro_message).'</p>'; ?>
|
1488 |
</div>
|
1489 |
</li>
|
1490 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('WP SEO Schema'); ?></strong></div><button data-id="wp_seo_schema" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1491 |
<p class="saswp-imported-message"></p>
|
1492 |
+
<?php echo '<p>'.saswp_t_string($wp_seo_schema_message).'</p>'; ?>
|
1493 |
</div>
|
1494 |
</li>
|
1495 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('SEO Pressor'); ?></strong></div><button data-id="seo_pressor" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1496 |
<p class="saswp-imported-message"></p>
|
1497 |
+
<?php echo '<p>'.saswp_t_string($seo_pressor_message).'</p>'; ?>
|
1498 |
</div>
|
1499 |
</li>
|
1500 |
|
1501 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('WPSSO Core'); ?></strong></div><button data-id="wpsso_core" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1502 |
<p class="saswp-imported-message"></p>
|
1503 |
+
<?php echo '<p>'.saswp_t_string($wpsso_core_message).'</p>'; ?>
|
1504 |
</div>
|
1505 |
</li>
|
1506 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('Schema – All In One Schema Rich Snippets'); ?></strong></div><button data-id="aiors" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1507 |
<p class="saswp-imported-message"></p>
|
1508 |
+
<?php echo '<p>'.saswp_t_string($aiors_message).'</p>'; ?>
|
1509 |
</div>
|
1510 |
</li>
|
1511 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('WP Customer Reviews'); ?></strong></div><button data-id="wp_custom_rv" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1512 |
<p class="saswp-imported-message"></p>
|
1513 |
+
<?php echo '<p>'.saswp_t_string($wp_custom_rv_message).'</p>'; ?>
|
1514 |
</div>
|
1515 |
</li>
|
1516 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the reviews can be imported from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('Stars Rating'); ?></strong></div><button data-id="starsrating" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1517 |
<p class="saswp-imported-message"></p>
|
1518 |
+
<?php echo '<p>'.saswp_t_string($starsrating_message).'</p>'; ?>
|
1519 |
</div>
|
1520 |
</li>
|
1521 |
|
1522 |
+
<li><div class="saswp-tools-field-title"><div class="saswp-tooltip"><span class="saswp-tooltiptext"><?php echo saswp_t_string('All the settings and data you can import from this plugin when you click start importing') ?></span><strong><?php echo saswp_t_string('FAQ Schema Markup – FAQ Structured Data'); ?></strong></div><button data-id="schema_for_faqs" class="button saswp-import-plugins"><?php echo saswp_t_string('Import'); ?></button>
|
1523 |
<p class="saswp-imported-message"></p>
|
1524 |
+
<?php echo '<p>'.saswp_t_string($schema_for_faqs_message).'</p>'; ?>
|
1525 |
</div>
|
1526 |
</li>
|
1527 |
|
1528 |
</ul>
|
1529 |
<?php
|
1530 |
+
echo '<h2>'.saswp_t_string('Import / Export').'</h2>';
|
1531 |
$url = wp_nonce_url(admin_url('admin-ajax.php?action=saswp_export_all_settings_and_schema'), '_wpnonce');
|
1532 |
?>
|
1533 |
<ul>
|
1534 |
<li>
|
1535 |
+
<div class="saswp-tools-field-title"><div class="saswp-tooltip"><strong><?php echo saswp_t_string('Export All Settings & Schema'); ?></strong></div><a href="<?php echo esc_url($url); ?>"class="button saswp-export-data"><?php echo saswp_t_string('Export'); ?></a>
|
1536 |
</div>
|
1537 |
</li>
|
1538 |
<li>
|
1539 |
+
<div class="saswp-tools-field-title"><div class="saswp-tooltip"><strong><?php echo saswp_t_string('Import All Settings & Schema'); ?></strong></div><input type="file" name="saswp_import_backup" id="saswp_import_backup">
|
1540 |
</div>
|
1541 |
</li>
|
1542 |
</ul>
|
1543 |
<?php
|
1544 |
+
echo '<h2>'.saswp_t_string('Reset').'</h2>';
|
1545 |
?>
|
1546 |
<ul>
|
1547 |
<li>
|
1548 |
<div class="saswp-tools-field-title">
|
1549 |
+
<div class="saswp-tooltip"><strong><?php echo saswp_t_string('Reset Settings'); ?></strong></div><a href="#"class="button saswp-reset-data"><?php echo saswp_t_string('Reset'); ?></a>
|
1550 |
+
<p><?php echo saswp_t_string('This will reset your settings and schema types'); ?></p>
|
1551 |
</div>
|
1552 |
</li>
|
1553 |
|
1556 |
<ul>
|
1557 |
<li>
|
1558 |
<div class="">
|
1559 |
+
<div class="saswp-tooltip"><strong><?php echo saswp_t_string('Remove Data On Uninstall'); ?></strong></div><input type="checkbox" id="saswp_rmv_data_on_uninstall" name="sd_data[saswp_rmv_data_on_uninstall]" <?php echo (isset($sd_data['saswp_rmv_data_on_uninstall'])? 'checked': ''); ?>>
|
1560 |
+
<p><?php echo saswp_t_string('This will remove all of its data when the plugin is deleted'); ?></p>
|
1561 |
</div>
|
1562 |
</li>
|
1563 |
|
1567 |
<li>
|
1568 |
<div class="saswp-tools-field-title">
|
1569 |
|
1570 |
+
<div class="saswp-tooltip"><strong><?php echo saswp_t_string('Data Tracking'); ?></strong></div>
|
1571 |
|
1572 |
<?php
|
1573 |
|
1581 |
'plugin' => $plugin,
|
1582 |
'plugin_action' => 'no'
|
1583 |
) );
|
1584 |
+
echo '<a href="'. esc_url_raw( $track_url ).'" class="button-secondary">'.saswp_t_string( 'Disallow' ).'</a>';
|
1585 |
|
1586 |
}else{
|
1587 |
|
1590 |
'plugin_action' => 'yes'
|
1591 |
));
|
1592 |
|
1593 |
+
echo '<a href="'. esc_url_raw( $track_url ).'" class="button-secondary">'.saswp_t_string( 'Allow' ).'</a>';
|
1594 |
|
1595 |
}
|
1596 |
|
1597 |
?>
|
1598 |
|
1599 |
+
<p><?php echo saswp_t_string('We guarantee no sensitive data is collected'); ?>
|
1600 |
+
<a target="_blank" href="https://structured-data-for-wp.com/docs/article/usage-data-tracking/"><?php echo saswp_t_string('Learn more'); ?></a>
|
1601 |
</p>
|
1602 |
</div>
|
1603 |
</li>
|
1614 |
|
1615 |
}
|
1616 |
|
1617 |
+
if(is_plugin_active('polylang-compatibility-for-saswp/polylang-compatibility-for-saswp.php')){
|
1618 |
+
|
1619 |
+
$add_on[] = 'Polylang';
|
1620 |
+
|
1621 |
+
}
|
1622 |
+
|
1623 |
if(is_plugin_active('jobposting-schema-compatibility/jobposting-schema-compatibility.php')){
|
1624 |
|
1625 |
$add_on[] = 'Jobposting';
|
1659 |
|
1660 |
if(!empty($add_on)){
|
1661 |
|
1662 |
+
echo '<h2>'.saswp_t_string('License').'</h2>';
|
1663 |
|
1664 |
echo '<ul>';
|
1665 |
|
1696 |
</div>
|
1697 |
<div class="saswp-tools-container" id="saswp-tools-translation-container">
|
1698 |
<?php
|
1699 |
+
echo '<h2>'.saswp_t_string('Translation Panel').'</h2>';
|
1700 |
|
1701 |
global $translation_labels;
|
1702 |
|
1749 |
if($label == true && $on == 'Cooked'){
|
1750 |
|
1751 |
$response.= '<div class="" style="display:inline-block">';
|
1752 |
+
$response.= '<strong>'.saswp_t_string(''.$on.' Compatibility For Schema').'</strong>';
|
1753 |
$response.= '</div>';
|
1754 |
|
1755 |
}
|
1756 |
if($label == true && $on == 'Woocommerce'){
|
1757 |
|
1758 |
$response.= '<div class="" style="display:inline-block">';
|
1759 |
+
$response.= '<strong>'.saswp_t_string(''.$on.' Compatibility For Schema').'</strong>';
|
1760 |
$response.= '</div>';
|
1761 |
|
1762 |
}
|
1764 |
if($label == true && $on == 'Res'){
|
1765 |
|
1766 |
$response.= '<div class="" style="display:inline-block">';
|
1767 |
+
$response.= '<strong>'.saswp_t_string('Real Estate Schema').'</strong>';
|
1768 |
$response.= '</div>';
|
1769 |
|
1770 |
}
|
1772 |
if($label == true && $on == 'Jobposting'){
|
1773 |
|
1774 |
$response.= '<div class="" style="display:inline-block">';
|
1775 |
+
$response.= '<strong>'.saswp_t_string('JobPosting Schema Compatibility').'</strong>';
|
1776 |
$response.= '</div>';
|
1777 |
|
1778 |
}
|
1780 |
if($label == true && $on == 'Cs'){
|
1781 |
|
1782 |
$response.= '<div class="" style="display:inline-block">';
|
1783 |
+
$response.= '<strong>'.saswp_t_string('Course Schema').'</strong>';
|
1784 |
$response.= '</div>';
|
1785 |
|
1786 |
}
|
1787 |
if($label == true && $on == 'Es'){
|
1788 |
|
1789 |
$response.= '<div class="" style="display:inline-block">';
|
1790 |
+
$response.= '<strong>'.saswp_t_string('Event Schema').'</strong>';
|
1791 |
$response.= '</div>';
|
1792 |
|
1793 |
}
|
1795 |
if($label == true && $on == 'qanda'){
|
1796 |
|
1797 |
$response.= '<div class="" style="display:inline-block">';
|
1798 |
+
$response.= '<strong>'.saswp_t_string('Q&A Schema').'</strong>';
|
1799 |
$response.= '</div>';
|
1800 |
|
1801 |
}
|
1803 |
if($label == true && $on == 'Rs'){
|
1804 |
|
1805 |
$response.= '<div class="" style="display:inline-block">';
|
1806 |
+
$response.= '<strong>'.saswp_t_string('Recipe Schema').'</strong>';
|
1807 |
$response.= '</div>';
|
1808 |
|
1809 |
}
|
1824 |
|
1825 |
if($license_status == 'active'){
|
1826 |
|
1827 |
+
$response.= '<a license-status="inactive" add-on="'.strtolower($on).'" class="button button-default saswp_license_activation">'.saswp_t_string('Deactivate').'</a>'.$limits_html;
|
1828 |
|
1829 |
}else{
|
1830 |
|
1831 |
+
$response.= '<a license-status="active" add-on="'.strtolower($on).'" class="button button-default saswp_license_activation">'.saswp_t_string('Activate').'</a>'.$limits_html;
|
1832 |
|
1833 |
}
|
1834 |
|
1837 |
$response.= '<p style="color:red;" add-on="'.strtolower($on).'" class="saswp_license_status_msg">'.$license_status_msg.'</p>';
|
1838 |
}
|
1839 |
|
1840 |
+
$response.= '<p>'.saswp_t_string('Enter your '.$on.' addon license key to activate updates & support.').'</p>';
|
1841 |
|
1842 |
$response.= '</div>';
|
1843 |
|
1907 |
|
1908 |
?>
|
1909 |
<div class="saswp-quick-links-div">
|
1910 |
+
<h4><?php echo saswp_t_string('Quick Links'); ?></h4>
|
1911 |
+
<p><a href="<?php echo admin_url('edit.php?post_type=saswp_reviews'); ?>"><?php echo saswp_t_string('View Current Reviews'); ?></a></p>
|
1912 |
+
<p><a target="_blank" href="https://structured-data-for-wp.com/docs/article/how-to-display-reviews-with-collection-feature/"><?php echo saswp_t_string('How to show reviews on the website'); ?></a></p>
|
1913 |
</div>
|
1914 |
|
1915 |
</div>
|
1972 |
|
1973 |
if(!is_plugin_active('woocommerce/woocommerce.php') || !is_plugin_active('woocommerce-bookings/woocommerce-bookings.php')){
|
1974 |
|
1975 |
+
$woocommerce['note'] = saswp_t_string('Requires').' <a target="_blank" href="https://wordpress.org/plugins/woocommerce/">Woocommerce</a>';
|
1976 |
|
1977 |
}
|
1978 |
|
1979 |
if(!is_plugin_active('woocommerce-compatibility-for-schema/woocommerce-compatibility-for-schema.php')){
|
1980 |
|
1981 |
+
$woocommerce['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="http://structured-data-for-wp.com/woocommerce-compatibility-for-schema/">WooCommerce Addon</a>';
|
1982 |
|
1983 |
}
|
1984 |
|
2033 |
)
|
2034 |
);
|
2035 |
|
2036 |
+
$polylang = array(
|
2037 |
+
'label' => 'Polylang',
|
2038 |
+
'id' => 'saswp-polylang-checkbox',
|
2039 |
+
'name' => 'saswp-polylang-checkbox',
|
2040 |
+
'type' => 'checkbox',
|
2041 |
+
'class' => 'checkbox saswp-checkbox',
|
2042 |
+
'note' => saswp_get_field_note('polylang'),
|
2043 |
+
'hidden' => array(
|
2044 |
+
'id' => 'saswp-polylang',
|
2045 |
+
'name' => 'sd_data[saswp-polylang]',
|
2046 |
+
)
|
2047 |
+
);
|
2048 |
+
|
2049 |
$simplejobboard = array(
|
2050 |
'label' => 'Simple Job Board',
|
2051 |
'id' => 'saswp-simplejobboard-checkbox',
|
3217 |
'name' => 'sd_data[saswp-yoast]',
|
3218 |
)
|
3219 |
);
|
3220 |
+
$metatagmanager = array(
|
3221 |
+
'label' => 'Meta Tag Manager',
|
3222 |
+
'id' => 'saswp-metatagmanager-checkbox',
|
3223 |
+
'name' => 'saswp-metatagmanager-checkbox',
|
3224 |
+
'type' => 'checkbox',
|
3225 |
+
'note' => saswp_get_field_note('metatagmanager'),
|
3226 |
+
'class' => 'checkbox saswp-checkbox',
|
3227 |
+
'hidden' => array(
|
3228 |
+
'id' => 'saswp-metatagmanager',
|
3229 |
+
'name' => 'sd_data[saswp-metatagmanager]',
|
3230 |
+
)
|
3231 |
+
);
|
3232 |
$slimseo = array(
|
3233 |
'label' => 'Slim SEO',
|
3234 |
'id' => 'saswp-slimseo-checkbox',
|
3331 |
|
3332 |
if(!is_plugin_active('woocommerce-compatibility-for-schema/woocommerce-compatibility-for-schema.php')){
|
3333 |
|
3334 |
+
$woocommerce_bok['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="http://structured-data-for-wp.com/woocommerce-compatibility-for-schema/">Woocommerce Addon</a>';
|
3335 |
|
3336 |
}
|
3337 |
|
3338 |
if(!is_plugin_active('cooked-compatibility-for-schema/cooked-compatibility-for-schema.php')){
|
3339 |
|
3340 |
+
$cooked['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="http://structured-data-for-wp.com/cooked-compatibility-for-schema/">Cooked Addon</a>';
|
3341 |
|
3342 |
}
|
3343 |
|
3344 |
if(!is_plugin_active('real-estate-schema/real-estate-schema.php')){
|
3345 |
|
3346 |
+
$homeland_theme['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/extensions/">Real Estate Schema Addon</a>';
|
3347 |
+
$real_homes['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/extensions/">Real Estate Schema Addon</a>';
|
3348 |
+
$wpresidence['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/extensions/">Real Estate Schema Addon</a>';
|
3349 |
+
$myhome['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/extensions/">Real Estate Schema Addon</a>';
|
3350 |
+
$realestate_5['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/extensions/">Real Estate Schema Addon</a>';
|
3351 |
+
$geo_directory['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/extensions/">Real Estate Schema Addon</a>';
|
3352 |
|
3353 |
}
|
3354 |
|
3355 |
if(!is_plugin_active('course-schema-for-saswp/course-schema-for-saswp.php')){
|
3356 |
|
3357 |
+
$learn_press['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/course-schema/">Course Schema Addon</a>';
|
3358 |
+
$learn_dash['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/course-schema/">Course Schema Addon</a>';
|
3359 |
+
$lifter_lms['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/course-schema/">Course Schema Addon</a>';
|
3360 |
+
$wplms['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/course-schema/">Course Schema Addon</a>';
|
3361 |
+
$senseilms['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/course-schema/">Course Schema Addon</a>';
|
3362 |
|
3363 |
}
|
3364 |
|
3365 |
if(!is_plugin_active('jobposting-schema-compatibility/jobposting-schema-compatibility.php')){
|
3366 |
|
3367 |
+
$simplejobboard['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/jobposting-schema/">JobPosting Schema Compatibility Addon</a>';
|
3368 |
+
$wpjobopenings['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/jobposting-schema/">JobPosting Schema Compatibility Addon</a>';
|
3369 |
+
$wpjobmanager['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/jobposting-schema/">JobPosting Schema Compatibility Addon</a>';
|
3370 |
|
3371 |
}
|
3372 |
|
3373 |
if(!is_plugin_active('faq-schema-compatibility/faq-schema-compatibility.php')){
|
3374 |
|
3375 |
+
$quickandeasyfaq['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3376 |
+
$accordionfaq['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3377 |
+
$helpiefaq['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3378 |
+
$ultimatefaqs['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3379 |
+
$arconixfaq['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3380 |
+
$wpresponsivefaq['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3381 |
+
$easyaccordion['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3382 |
+
$html5responsivefaq['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3383 |
+
$faqconcertina['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3384 |
+
$accordion['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3385 |
+
$easyfaqs['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3386 |
+
$masteraccordion['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3387 |
+
$wpfaqschemamarkup['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3388 |
+
$faqschemaforpost['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3389 |
+
$webfaq10['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/faq-schema/">FAQ Schema Compatibility Addon</a>';
|
3390 |
|
3391 |
}
|
3392 |
+
if(!is_plugin_active('polylang-compatibility-for-saswp/polylang-compatibility-for-saswp.php')){
|
3393 |
+
|
3394 |
+
$polylang['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/polylang-compatibility-for-saswp/">Polylang Compatibility For SASWP Addon</a>';
|
3395 |
+
}
|
3396 |
if(!is_plugin_active('qanda-schema-for-saswp/qanda-schema-for-saswp.php')){
|
3397 |
|
3398 |
+
$sabaidiscuss['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/qanda-schema/">Q&A Schema Compatibility Addon</a>';
|
3399 |
}
|
3400 |
|
3401 |
if(!is_plugin_active('event-schema-for-saswp/event-schema-for-saswp.php')){
|
3402 |
|
3403 |
+
$the_events_calendar['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3404 |
+
$events_calendar_wd['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3405 |
+
$wp_event_manager['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3406 |
+
$events_manager['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3407 |
+
$event_organiser['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3408 |
+
$modern_events_calendar['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3409 |
+
$tevolution_events['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3410 |
+
$wp_event_aggregator['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3411 |
+
$stachethemes_events['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3412 |
+
$timetable_event['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3413 |
+
$xo_event_calendar['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3414 |
+
$events_schedule['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3415 |
+
$calendarize_it['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3416 |
+
$woo_event_manager['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3417 |
+
$vs_event_list['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3418 |
+
$all_in_one_event_calendar['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3419 |
+
$event_on['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Event Schema Addon</a>';
|
3420 |
|
3421 |
}
|
3422 |
|
3423 |
if(!is_plugin_active('recipe-schema-for-saswp/recipe-schema-for-saswp.php')){
|
3424 |
|
3425 |
+
$zip_recipes['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/recipe-schema/">Recipe Schema Addon</a>';
|
3426 |
+
$wp_ultimate_recipe['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/recipe-schema/">Recipe Schema Addon</a>';
|
3427 |
+
$mediavine_create['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/recipe-schema/">Recipe Schema Addon</a>';
|
3428 |
+
$ht_recipes['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/recipe-schema/">Recipe Schema Addon</a>';
|
3429 |
+
$easyrecipe['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Recipe Schema Addon</a>';
|
3430 |
+
$total_recipe_generator['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Recipe Schema Addon</a>';
|
3431 |
+
$ranna_recipe['note'] = saswp_t_string('This feature requires').' <a target="_blank" href="https://structured-data-for-wp.com/event-schema/">Recipe Schema Addon</a>';
|
3432 |
|
3433 |
}
|
3434 |
|
3461 |
$dwquestiton,
|
3462 |
$sabaidiscuss,
|
3463 |
$yoast,
|
3464 |
+
$polylang,
|
3465 |
+
$metatagmanager,
|
3466 |
$slimseo,
|
3467 |
$smart_crawl,
|
3468 |
$seo_press,
|
3627 |
if ( is_plugin_active('flexmls-idx/flexmls_connect.php') && isset($settings['saswp-flexmlx-compativility']) && $settings['saswp-flexmlx-compativility'] == 1) {
|
3628 |
|
3629 |
echo '<div class="saswp-seller-div">';
|
3630 |
+
echo '<strong>'.saswp_t_string('Real estate agent info :').'</strong>';
|
3631 |
|
3632 |
$field_objs->saswp_field_generator($flex_mlx_extra_fields, $settings);
|
3633 |
|
3682 |
|
3683 |
?>
|
3684 |
<div class="saswp_support_div">
|
3685 |
+
<strong><?php echo saswp_t_string('If you have any query, please write the query in below box or email us at') ?> <a href="mailto:team@ampforwp.com">team@ampforwp.com</a>. <?php echo saswp_t_string('We will reply to your email address shortly') ?></strong>
|
3686 |
|
3687 |
<ul>
|
3688 |
<li>
|
3690 |
</li>
|
3691 |
<li>
|
3692 |
<div><textarea rows="5" cols="60" id="saswp_query_message" name="saswp_query_message" placeholder="Write your query"></textarea></div>
|
3693 |
+
<span class="saswp-query-success saswp_hide"><?php echo saswp_t_string('Message sent successfully, Please wait we will get back to you shortly'); ?></span>
|
3694 |
+
<span class="saswp-query-error saswp_hide"><?php echo saswp_t_string('Message not sent. please check your network connection'); ?></span>
|
3695 |
</li>
|
3696 |
<li>
|
3697 |
+
<strong><?php echo saswp_t_string('Are you a premium customer ?'); ?></strong>
|
3698 |
<select id="saswp_query_premium_cus" name="saswp_query_premium_cus">
|
3699 |
+
<option value=""><?php echo saswp_t_string('Select'); ?></option>
|
3700 |
+
<option value="yes"><?php echo saswp_t_string('Yes'); ?></option>
|
3701 |
+
<option value="no"><?php echo saswp_t_string('No'); ?></option>
|
3702 |
</select>
|
3703 |
</li>
|
3704 |
+
<li><button class="button saswp-send-query"><?php echo saswp_t_string('Send Message'); ?></button></li>
|
3705 |
</ul>
|
3706 |
|
3707 |
</div>
|
3708 |
<?php
|
3709 |
|
3710 |
+
echo '<h1>'.saswp_t_string( 'Frequently Asked Questions.' ).'</h1>
|
3711 |
<br>
|
3712 |
+
<h3>1Q) '.saswp_t_string( 'Is there a Documentation Available?' ).'</h3>
|
3713 |
+
<p class="saswp_qanda_p">A) '.saswp_t_string( 'The Documentation is always updated and available at ' ).'<a href="http://structured-data-for-wp.com/docs/" target="_blank"><strong>http://structured-data-for-wp.com/docs/</strong></a></p>
|
3714 |
|
3715 |
+
<h3>2Q) '.saswp_t_string( 'How can I setup the Schema and Structured data for individual pages and posts?' ).'</h3>
|
3716 |
+
<p class="saswp_qanda_p">A) '.saswp_t_string( 'Just with one click on the Structured data option, you will find an add new options window in the structured data option panel. Secondly, you need to write the name of the title where, if you would like to set the individual Page/Post then you can set the Page/Post type equal to the Page/Post(Name).' ).'</p>
|
3717 |
|
3718 |
+
<h3>3Q) '.saswp_t_string( 'How can I check the code whether the structured data is working or not?' ).'</h3>
|
3719 |
<p class="saswp_qanda_p">A) To check the code, the first step we need to take is to copy the code of a page or post then visit the <a href="https://search.google.com/structured-data/testing-tool" target="_blank">Structured data testing tool</a> by clicking on code snippet. Once we paste the snippet we can run the test.</p>
|
3720 |
|
3721 |
+
<h3> 4Q) '.saswp_t_string( 'How can I check whether the pages or posts are valid or not?' ).'</h3>
|
3722 |
+
<p class="saswp_qanda_p"> A) '.saswp_t_string( 'To check the page and post validation, please visit the' ).' <a href="https://search.google.com/structured-data/testing-tool" target="_blank">'.saswp_t_string( 'Structured data testing tool' ).'</a> '.saswp_t_string( 'and paste the link of your website.' ).' '.saswp_t_string( 'Once we click on run test we can see the result whether the page or post is a valid one or not.' ).'</p>
|
3723 |
|
3724 |
+
<h3>5Q) '.saswp_t_string( 'Where should users contact if they faced any issues?' ).'</h3>
|
3725 |
+
<p class="saswp_qanda_p">A) '.saswp_t_string( 'We always welcome all our users to share their issues and get them fixed just with one click to the link' ).' team@ampforwp.com or <a href="https://ampforwp.com/support/" target="_blank">'.saswp_t_string( 'Support link' ).'</a></p><br>';
|
3726 |
}
|
3727 |
|
3728 |
/**
|
3733 |
global $saswp_metaboxes;
|
3734 |
|
3735 |
$translable_txt = array(
|
3736 |
+
'attach_review' => saswp_t_string( 'Attach reviews to this schema type' ),
|
3737 |
+
'place_id' => saswp_t_string( 'Place ID' ),
|
3738 |
+
'reviews' => saswp_t_string( 'Reviews' ),
|
3739 |
+
'fetch' => saswp_t_string( 'Fetch' ),
|
3740 |
+
'step_in' => saswp_t_string( 'Reviews count should be in step of 10' ),
|
3741 |
+
'blocks_zero' => saswp_t_string( 'Blocks value is zero' ),
|
3742 |
+
'success' => saswp_t_string( 'Success' ),
|
3743 |
+
'enter_place_id' => saswp_t_string( 'Please enter place id' ),
|
3744 |
+
'enter_api_key' => saswp_t_string( 'Please enter api key' ),
|
3745 |
+
'enter_rv_api_key' => saswp_t_string( 'Please enter reviews api key' ),
|
3746 |
+
'using_schema' => saswp_t_string( 'Thanks for using Structured Data!' ),
|
3747 |
+
'do_you_want' => saswp_t_string( 'Do you want the latest on ' ),
|
3748 |
+
'sd_update' => saswp_t_string( 'Structured Data update' ),
|
3749 |
+
'before_others' => saswp_t_string( ' before others and some best resources on monetization in a single email? - Free just for users of Structured Data!' ),
|
3750 |
+
'fill_email' => saswp_t_string( 'Please fill in your name and email.' ),
|
3751 |
+
'invalid_email' => saswp_t_string( 'Your email address is invalid.' ),
|
3752 |
+
'list_id_invalid' => saswp_t_string( 'Your list ID is invalid.' ),
|
3753 |
+
'already_subsribed' => saswp_t_string( 'You\'re already subscribed!' ),
|
3754 |
+
'subsribed' => saswp_t_string( 'Please enter reviews api key' ),
|
3755 |
+
'try_again' => saswp_t_string( 'Please enter reviews api key' )
|
3756 |
);
|
3757 |
|
3758 |
$post_type = '';
|
3788 |
'page_now' => $hook,
|
3789 |
'saswp_settings_url' => esc_url(admin_url('edit.php?post_type=saswp&page=structured_data_options')),
|
3790 |
'saswp_schema_types' => $all_schema_array,
|
3791 |
+
'trans_based_on' => saswp_t_string(saswp_label_text('translation-based-on')),
|
3792 |
+
'trans_reviews' => saswp_t_string(saswp_label_text('translation-reviews')),
|
3793 |
+
'trans_self' => saswp_t_string(saswp_label_text('translation-self')),
|
3794 |
'translable_txt' => $translable_txt
|
3795 |
);
|
3796 |
|
admin_section/structure_admin.php
CHANGED
@@ -691,16 +691,16 @@ if(is_admin()){
|
|
691 |
function saswp_create_post_type() {
|
692 |
|
693 |
$nonce = wp_create_nonce( 'saswp_install_wizard_nonce' );
|
694 |
-
$not_found_button = '<div><span class="dashicons dashicons-thumbs-up"></span>'.
|
695 |
|
696 |
$saswp = array(
|
697 |
'labels' => array(
|
698 |
-
'name' =>
|
699 |
-
'singular_name' =>
|
700 |
-
'add_new' =>
|
701 |
'add_new_item' => '',
|
702 |
-
'edit_item' =>
|
703 |
-
'all_items' =>
|
704 |
'not_found' => $not_found_button
|
705 |
),
|
706 |
'public' => true,
|
@@ -756,31 +756,31 @@ if(is_admin()){
|
|
756 |
<?php
|
757 |
// Type Select
|
758 |
$choices = array(
|
759 |
-
|
760 |
-
'post_type' =>
|
761 |
-
'show_globally' =>
|
762 |
-
'user_type' =>
|
763 |
-
'homepage' =>
|
764 |
),
|
765 |
-
|
766 |
-
'post' =>
|
767 |
-
'post_category' =>
|
768 |
-
'post_format' =>
|
769 |
),
|
770 |
-
|
771 |
-
'page' =>
|
772 |
-
'page_template' =>
|
773 |
),
|
774 |
-
|
775 |
-
'ef_taxonomy' =>
|
776 |
-
'date' =>
|
777 |
|
778 |
)
|
779 |
);
|
780 |
|
781 |
$comparison = array(
|
782 |
-
'equal' =>
|
783 |
-
'not_equal' =>
|
784 |
);
|
785 |
|
786 |
$total_group_fields = count( $data_group_array ); ?>
|
@@ -813,13 +813,13 @@ if(is_admin()){
|
|
813 |
|
814 |
if($selected_val_key_1 == 'date'){
|
815 |
$comparison = array(
|
816 |
-
'before_published' =>
|
817 |
-
'after_published' =>
|
818 |
);
|
819 |
}else{
|
820 |
$comparison = array(
|
821 |
-
'equal' =>
|
822 |
-
'not_equal' =>
|
823 |
);
|
824 |
}
|
825 |
|
@@ -832,7 +832,7 @@ if(is_admin()){
|
|
832 |
<optgroup label="<?php echo esc_attr($choice_key);?>">
|
833 |
<?php
|
834 |
foreach ($choice_value as $sub_key => $sub_value) { ?>
|
835 |
-
<option class="pt-child" value="<?php echo esc_attr( $sub_key );?>" <?php selected( $selected_val_key_1, $sub_key );?> > <?php echo
|
836 |
<?php
|
837 |
}
|
838 |
?> </optgroup > <?php
|
@@ -847,7 +847,7 @@ if(is_admin()){
|
|
847 |
$selcomp = 'selected';
|
848 |
}
|
849 |
?>
|
850 |
-
<option class="pt-child" value="<?php echo esc_attr( $key );?>" <?php echo esc_attr($selcomp); ?> > <?php echo
|
851 |
<?php
|
852 |
} ?>
|
853 |
</select>
|
@@ -864,7 +864,7 @@ if(is_admin()){
|
|
864 |
</td>
|
865 |
|
866 |
<td class="widefat structured-clone" style="width:3.5%; <?php if ( $selected_val_key_1 =='show_globally' ) { echo 'display:none;'; } ?>">
|
867 |
-
<span> <button class="saswp-placement-button" type="button"> <?php echo
|
868 |
|
869 |
<td class="widefat structured-delete" style="width:3.5%; <?php if ( $selected_val_key_1 =='show_globally' ) { echo 'display:none;'; } ?>">
|
870 |
<button class="saswp-placement-button" type="button"><span class="dashicons dashicons-trash"></span> </button></td>
|
@@ -877,7 +877,7 @@ if(is_admin()){
|
|
877 |
<?php } ?>
|
878 |
|
879 |
|
880 |
-
<a style="margin-left: 8px; margin-bottom: 8px;" class="button saswp-placement-or-group saswp-placement-button" href="#"><?php echo
|
881 |
</div>
|
882 |
<?php
|
883 |
}
|
@@ -1170,8 +1170,8 @@ function saswp_custom_breadcrumbs() {
|
|
1170 |
|
1171 |
foreach($cat_parents as $parents) {
|
1172 |
|
1173 |
-
$cat_display .= '<li class="item-cat">'.
|
1174 |
-
$cat_display .= '<li class="separator"> ' .
|
1175 |
|
1176 |
}
|
1177 |
|
@@ -1245,8 +1245,8 @@ function saswp_custom_breadcrumbs() {
|
|
1245 |
|
1246 |
foreach ( $anc as $ancestor ) {
|
1247 |
|
1248 |
-
$parents .= '<li class="item-parent item-parent-' . esc_attr($ancestor) . '"><a class="bread-parent bread-parent-' . esc_attr($ancestor) . '" href="' . esc_url(get_permalink($ancestor)) . '" title="' . esc_attr(@get_the_title($ancestor)) . '">' .
|
1249 |
-
$parents .= '<li class="separator separator-' . esc_attr($ancestor) . '"> ' .
|
1250 |
$variables1_titles[] = @get_the_title($ancestor);
|
1251 |
$variables2_links[] = get_permalink($ancestor);
|
1252 |
$breadcrumb_url = get_permalink($ancestor);
|
@@ -1358,12 +1358,12 @@ function saswp_custom_column_set( $column, $post_id ) {
|
|
1358 |
}
|
1359 |
if($enabled){
|
1360 |
|
1361 |
-
echo '<div><strong>'.
|
1362 |
|
1363 |
}
|
1364 |
if($exclude){
|
1365 |
|
1366 |
-
echo '<div><strong>'.
|
1367 |
|
1368 |
}
|
1369 |
}
|
@@ -1388,8 +1388,8 @@ function saswp_custom_columns($columns) {
|
|
1388 |
unset($columns);
|
1389 |
$columns['cb'] = $cb;
|
1390 |
$columns['title'] = $title;
|
1391 |
-
$columns['saswp_schema_type'] = '<a>'.
|
1392 |
-
$columns['saswp_target_location'] = '<a>'.
|
1393 |
|
1394 |
return $columns;
|
1395 |
}
|
@@ -1568,11 +1568,11 @@ function saswp_import_plugin_data(){
|
|
1568 |
}
|
1569 |
if($result){
|
1570 |
|
1571 |
-
echo json_encode(array('status'=>'t', 'message'=>
|
1572 |
|
1573 |
}else{
|
1574 |
|
1575 |
-
echo json_encode(array('status'=>'f', 'message'=>
|
1576 |
|
1577 |
}
|
1578 |
wp_die();
|
@@ -1645,8 +1645,9 @@ add_action('wp_ajax_saswp_feeback_remindme', 'saswp_feeback_remindme');
|
|
1645 |
|
1646 |
function saswp_license_status($add_on, $license_status, $license_key){
|
1647 |
|
1648 |
-
$item_name = array(
|
1649 |
-
'
|
|
|
1650 |
'woocommerce' => 'Woocommerce compatibility for Schema',
|
1651 |
'reviews' => 'Reviews for schema',
|
1652 |
'res' => 'Real Estate Schema',
|
691 |
function saswp_create_post_type() {
|
692 |
|
693 |
$nonce = wp_create_nonce( 'saswp_install_wizard_nonce' );
|
694 |
+
$not_found_button = '<div><span class="dashicons dashicons-thumbs-up"></span>'.saswp_t_string("Thank you for using Schema & Structured Data For WP plugin!").' <a href="'.esc_url(admin_url( 'plugins.php?page=saswp-setup-wizard' ).'&_saswp_nonce='.$nonce).'">'.saswp_t_string("Start Quick Setup?").'</a></div>';
|
695 |
|
696 |
$saswp = array(
|
697 |
'labels' => array(
|
698 |
+
'name' => saswp_t_string( 'Structured Data' ),
|
699 |
+
'singular_name' => saswp_t_string( 'Structured Data' ),
|
700 |
+
'add_new' => saswp_t_string( 'Add Schema Type' ),
|
701 |
'add_new_item' => '',
|
702 |
+
'edit_item' => saswp_t_string( 'Edit Schema Type'),
|
703 |
+
'all_items' => saswp_t_string( 'Schema Types' ),
|
704 |
'not_found' => $not_found_button
|
705 |
),
|
706 |
'public' => true,
|
756 |
<?php
|
757 |
// Type Select
|
758 |
$choices = array(
|
759 |
+
saswp_t_string("Basic") => array(
|
760 |
+
'post_type' => saswp_t_string("Post Type"),
|
761 |
+
'show_globally' => saswp_t_string("Show Globally"),
|
762 |
+
'user_type' => saswp_t_string("Logged in User Type"),
|
763 |
+
'homepage' => saswp_t_string("Homepage"),
|
764 |
),
|
765 |
+
saswp_t_string("Post") => array(
|
766 |
+
'post' => saswp_t_string("Post"),
|
767 |
+
'post_category' => saswp_t_string("Post Category"),
|
768 |
+
'post_format' => saswp_t_string("Post Format"),
|
769 |
),
|
770 |
+
saswp_t_string("Page") => array(
|
771 |
+
'page' => saswp_t_string("Page"),
|
772 |
+
'page_template' => saswp_t_string("Page Template"),
|
773 |
),
|
774 |
+
saswp_t_string("Other") => array(
|
775 |
+
'ef_taxonomy' => saswp_t_string("Taxonomy (Tag)"),
|
776 |
+
'date' => saswp_t_string("Date"),
|
777 |
|
778 |
)
|
779 |
);
|
780 |
|
781 |
$comparison = array(
|
782 |
+
'equal' => saswp_t_string( 'Equal to'),
|
783 |
+
'not_equal' => saswp_t_string( 'Not Equal to (Exclude)'),
|
784 |
);
|
785 |
|
786 |
$total_group_fields = count( $data_group_array ); ?>
|
813 |
|
814 |
if($selected_val_key_1 == 'date'){
|
815 |
$comparison = array(
|
816 |
+
'before_published' => saswp_t_string( 'Before Published'),
|
817 |
+
'after_published' => saswp_t_string( 'After Published'),
|
818 |
);
|
819 |
}else{
|
820 |
$comparison = array(
|
821 |
+
'equal' => saswp_t_string( 'Equal to'),
|
822 |
+
'not_equal' => saswp_t_string( 'Not Equal to (Exclude)'),
|
823 |
);
|
824 |
}
|
825 |
|
832 |
<optgroup label="<?php echo esc_attr($choice_key);?>">
|
833 |
<?php
|
834 |
foreach ($choice_value as $sub_key => $sub_value) { ?>
|
835 |
+
<option class="pt-child" value="<?php echo esc_attr( $sub_key );?>" <?php selected( $selected_val_key_1, $sub_key );?> > <?php echo saswp_t_string($sub_value);?> </option>
|
836 |
<?php
|
837 |
}
|
838 |
?> </optgroup > <?php
|
847 |
$selcomp = 'selected';
|
848 |
}
|
849 |
?>
|
850 |
+
<option class="pt-child" value="<?php echo esc_attr( $key );?>" <?php echo esc_attr($selcomp); ?> > <?php echo saswp_t_string($value);?> </option>
|
851 |
<?php
|
852 |
} ?>
|
853 |
</select>
|
864 |
</td>
|
865 |
|
866 |
<td class="widefat structured-clone" style="width:3.5%; <?php if ( $selected_val_key_1 =='show_globally' ) { echo 'display:none;'; } ?>">
|
867 |
+
<span> <button class="saswp-placement-button" type="button"> <?php echo saswp_t_string('And' );?> </button> </span> </td>
|
868 |
|
869 |
<td class="widefat structured-delete" style="width:3.5%; <?php if ( $selected_val_key_1 =='show_globally' ) { echo 'display:none;'; } ?>">
|
870 |
<button class="saswp-placement-button" type="button"><span class="dashicons dashicons-trash"></span> </button></td>
|
877 |
<?php } ?>
|
878 |
|
879 |
|
880 |
+
<a style="margin-left: 8px; margin-bottom: 8px;" class="button saswp-placement-or-group saswp-placement-button" href="#"><?php echo saswp_t_string('Or'); ?></a>
|
881 |
</div>
|
882 |
<?php
|
883 |
}
|
1170 |
|
1171 |
foreach($cat_parents as $parents) {
|
1172 |
|
1173 |
+
$cat_display .= '<li class="item-cat">'.saswp_t_string( $parents ).'</li>';
|
1174 |
+
$cat_display .= '<li class="separator"> ' . saswp_t_string( $separator ) . ' </li>';
|
1175 |
|
1176 |
}
|
1177 |
|
1245 |
|
1246 |
foreach ( $anc as $ancestor ) {
|
1247 |
|
1248 |
+
$parents .= '<li class="item-parent item-parent-' . esc_attr($ancestor) . '"><a class="bread-parent bread-parent-' . esc_attr($ancestor) . '" href="' . esc_url(get_permalink($ancestor)) . '" title="' . esc_attr(@get_the_title($ancestor)) . '">' . saswp_t_string(@get_the_title($ancestor) ) . '</a></li>';
|
1249 |
+
$parents .= '<li class="separator separator-' . esc_attr($ancestor) . '"> ' . saswp_t_string($separator ) . ' </li>';
|
1250 |
$variables1_titles[] = @get_the_title($ancestor);
|
1251 |
$variables2_links[] = get_permalink($ancestor);
|
1252 |
$breadcrumb_url = get_permalink($ancestor);
|
1358 |
}
|
1359 |
if($enabled){
|
1360 |
|
1361 |
+
echo '<div><strong>'.saswp_t_string( 'Enable on: ' ).'</strong> '.esc_attr($enabled).'</div>';
|
1362 |
|
1363 |
}
|
1364 |
if($exclude){
|
1365 |
|
1366 |
+
echo '<div><strong>'.saswp_t_string( 'Exclude from: ' ).'</strong>'.esc_attr($exclude).'</div>';
|
1367 |
|
1368 |
}
|
1369 |
}
|
1388 |
unset($columns);
|
1389 |
$columns['cb'] = $cb;
|
1390 |
$columns['title'] = $title;
|
1391 |
+
$columns['saswp_schema_type'] = '<a>'.saswp_t_string( 'Schema Type' ).'<a>';
|
1392 |
+
$columns['saswp_target_location'] = '<a>'.saswp_t_string( 'Target Location' ).'<a>';
|
1393 |
|
1394 |
return $columns;
|
1395 |
}
|
1568 |
}
|
1569 |
if($result){
|
1570 |
|
1571 |
+
echo json_encode(array('status'=>'t', 'message'=>saswp_t_string('Data has been imported succeessfully')));
|
1572 |
|
1573 |
}else{
|
1574 |
|
1575 |
+
echo json_encode(array('status'=>'f', 'message'=>saswp_t_string('Plugin data is not available or it is not activated')));
|
1576 |
|
1577 |
}
|
1578 |
wp_die();
|
1645 |
|
1646 |
function saswp_license_status($add_on, $license_status, $license_key){
|
1647 |
|
1648 |
+
$item_name = array(
|
1649 |
+
'jobposting' => 'JobPosting Schema Compatibility',
|
1650 |
+
'polylang' => 'Polylang Compatibility For SASWP',
|
1651 |
'woocommerce' => 'Woocommerce compatibility for Schema',
|
1652 |
'reviews' => 'Reviews for schema',
|
1653 |
'res' => 'Real Estate Schema',
|
admin_section/tracking/class-saswp-plugin-usage-tracker.php
CHANGED
@@ -728,7 +728,7 @@ if( ! class_exists( 'SASWP_Plugin_Usage_Tracker') ) {
|
|
728 |
|
729 |
<div class="notice notice-info updated put-dismiss-notice">
|
730 |
<p><?php echo '<strong>Love using Schema & Structured Data for WP & AMP?</strong>'; ?></p>
|
731 |
-
<p><?php echo esc_html( $notice_text ); ?> <a href="https://structured-data-for-wp.com/docs/article/usage-data-tracking/" target="_blank"><?php echo
|
732 |
<p>
|
733 |
<a href="<?php echo esc_url( $url_yes ); ?>" class="button-primary"><?php echo _e( 'Sure! I\'d love to help', 'singularity' ); ?></a>
|
734 |
<a href="<?php echo esc_url( $url_no ); ?>" class="button-secondary"><?php echo _e( 'No thanks', 'singularity' ); ?></a>
|
728 |
|
729 |
<div class="notice notice-info updated put-dismiss-notice">
|
730 |
<p><?php echo '<strong>Love using Schema & Structured Data for WP & AMP?</strong>'; ?></p>
|
731 |
+
<p><?php echo esc_html( $notice_text ); ?> <a href="https://structured-data-for-wp.com/docs/article/usage-data-tracking/" target="_blank"><?php echo saswp_t_string( 'Learn more.' ); ?></a></p>
|
732 |
<p>
|
733 |
<a href="<?php echo esc_url( $url_yes ); ?>" class="button-primary"><?php echo _e( 'Sure! I\'d love to help', 'singularity' ); ?></a>
|
734 |
<a href="<?php echo esc_url( $url_no ); ?>" class="button-secondary"><?php echo _e( 'No thanks', 'singularity' ); ?></a>
|
core/3rd-party/aqua_resizer.php
CHANGED
@@ -94,6 +94,27 @@ if(!class_exists('Aq_Resize')) {
|
|
94 |
$upload_dir = $upload_info['basedir'];
|
95 |
$upload_url = $upload_info['baseurl'];
|
96 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
97 |
$http_prefix = "http://";
|
98 |
$https_prefix = "https://";
|
99 |
$relative_prefix = "//"; // The protocol-relative URL
|
@@ -287,6 +308,13 @@ if(!function_exists('saswp_aq_resize')) {
|
|
287 |
* need to change any code in your own WP themes. Usage is still the same :)
|
288 |
*/
|
289 |
function saswp_aq_resize( $url, $width = null, $height = null, $crop = null, $single = true, $upscale = false ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
290 |
/* WPML Fix */
|
291 |
if ( defined( 'ICL_SITEPRESS_VERSION' ) ){
|
292 |
global $sitepress;
|
94 |
$upload_dir = $upload_info['basedir'];
|
95 |
$upload_url = $upload_info['baseurl'];
|
96 |
|
97 |
+
//Creating custom folder in uploads and save resizable images. Starts here
|
98 |
+
$upload_main_url = $upload_info['url'];
|
99 |
+
$make_new_dir = $upload_dir . '/schema-and-structured-data-for-wp';
|
100 |
+
|
101 |
+
if (! is_dir($make_new_dir)) {
|
102 |
+
mkdir( $make_new_dir, 0700 );
|
103 |
+
}
|
104 |
+
|
105 |
+
if(is_dir($make_new_dir)){
|
106 |
+
|
107 |
+
$old_url = $url;
|
108 |
+
$explod_url = @explode('/', $url);
|
109 |
+
$new_url = end($explod_url);
|
110 |
+
$url = $upload_url.'/schema-and-structured-data-for-wp/'.$new_url;
|
111 |
+
$new_url = $make_new_dir.'/'.$new_url;
|
112 |
+
|
113 |
+
@copy($old_url, $new_url);
|
114 |
+
|
115 |
+
}
|
116 |
+
//Creating custom folder in uploads and save resizable images. Ends here
|
117 |
+
|
118 |
$http_prefix = "http://";
|
119 |
$https_prefix = "https://";
|
120 |
$relative_prefix = "//"; // The protocol-relative URL
|
308 |
* need to change any code in your own WP themes. Usage is still the same :)
|
309 |
*/
|
310 |
function saswp_aq_resize( $url, $width = null, $height = null, $crop = null, $single = true, $upscale = false ) {
|
311 |
+
|
312 |
+
$stop_resize = apply_filters('saswp_stop_image_resizer', false );
|
313 |
+
|
314 |
+
if($stop_resize){
|
315 |
+
return array();
|
316 |
+
}
|
317 |
+
|
318 |
/* WPML Fix */
|
319 |
if ( defined( 'ICL_SITEPRESS_VERSION' ) ){
|
320 |
global $sitepress;
|
core/array-list/compatibility-list.php
CHANGED
@@ -4,6 +4,12 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
4 |
|
5 |
return array(
|
6 |
'plugins' => array(
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
'wpjobmanager' => array(
|
8 |
'name' => 'WP Job Manager',
|
9 |
'free' => 'wp-job-manager/wp-job-manager.php',
|
@@ -422,6 +428,12 @@ return array(
|
|
422 |
'opt_name' => 'saswp-yoast',
|
423 |
'part_in' => 'free',
|
424 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
425 |
'slimseo' => array(
|
426 |
'name' => 'Slim Seo',
|
427 |
'free' => 'slim-seo/slim-seo.php',
|
4 |
|
5 |
return array(
|
6 |
'plugins' => array(
|
7 |
+
'polylang' => array(
|
8 |
+
'name' => 'Polylang',
|
9 |
+
'free' => 'polylang/polylang.php',
|
10 |
+
'opt_name' => 'saswp-polylang',
|
11 |
+
'part_in' => 'pro',
|
12 |
+
),
|
13 |
'wpjobmanager' => array(
|
14 |
'name' => 'WP Job Manager',
|
15 |
'free' => 'wp-job-manager/wp-job-manager.php',
|
428 |
'opt_name' => 'saswp-yoast',
|
429 |
'part_in' => 'free',
|
430 |
),
|
431 |
+
'metatagmanager' => array(
|
432 |
+
'name' => 'Meta Tag Manager',
|
433 |
+
'free' => 'meta-tag-manager/meta-tag-manager.php',
|
434 |
+
'opt_name' => 'saswp-metatagmanager',
|
435 |
+
'part_in' => 'free',
|
436 |
+
),
|
437 |
'slimseo' => array(
|
438 |
'name' => 'Slim Seo',
|
439 |
'free' => 'slim-seo/slim-seo.php',
|
core/array-list/pro_extensions.php
CHANGED
@@ -4,7 +4,12 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
4 |
|
5 |
return array(
|
6 |
array(
|
7 |
-
'key' => '
|
|
|
|
|
|
|
|
|
|
|
8 |
'name' => 'SASWP Pro Extension Manager',
|
9 |
'path' => 'saswp-pro-extension-manager/saswp-pro-extension-manager.php',
|
10 |
),
|
4 |
|
5 |
return array(
|
6 |
array(
|
7 |
+
'key' => 'polylang_compatibility_for_saswp',
|
8 |
+
'name' => 'Polylang Compatibility For SASWP',
|
9 |
+
'path' => 'polylang-compatibility-for-saswp/polylang-compatibility-for-saswp.php',
|
10 |
+
),
|
11 |
+
array(
|
12 |
+
'key' => 'saswp_pro_extension_manager',
|
13 |
'name' => 'SASWP Pro Extension Manager',
|
14 |
'path' => 'saswp-pro-extension-manager/saswp-pro-extension-manager.php',
|
15 |
),
|
core/array-list/schema-properties.php
CHANGED
@@ -589,6 +589,18 @@ function saswp_get_fields_by_schema_type( $schema_id = null, $condition = null,
|
|
589 |
'type' => 'textarea',
|
590 |
'default' => get_the_excerpt()
|
591 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
592 |
array(
|
593 |
'label' => 'Keywords',
|
594 |
'id' => 'saswp_webpage_keywords_'.$schema_id,
|
@@ -5151,6 +5163,26 @@ function saswp_get_fields_by_schema_type( $schema_id = null, $condition = null,
|
|
5151 |
'id' => 'saswp_book_no_of_page_'.$schema_id,
|
5152 |
'type' => 'text',
|
5153 |
),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5154 |
array(
|
5155 |
'label' => 'Publisher',
|
5156 |
'id' => 'saswp_book_publisher_'.$schema_id,
|
589 |
'type' => 'textarea',
|
590 |
'default' => get_the_excerpt()
|
591 |
),
|
592 |
+
array(
|
593 |
+
'label' => 'Webpage Section',
|
594 |
+
'id' => 'saswp_webpage_section_'.$schema_id,
|
595 |
+
'type' => 'textarea',
|
596 |
+
'default' => get_the_excerpt()
|
597 |
+
),
|
598 |
+
array(
|
599 |
+
'label' => 'Webpage Body',
|
600 |
+
'id' => 'saswp_webpage_body_'.$schema_id,
|
601 |
+
'type' => 'textarea',
|
602 |
+
'default' => is_object($post) ? wp_strip_all_tags(strip_shortcodes($post->post_content)) : ''
|
603 |
+
),
|
604 |
array(
|
605 |
'label' => 'Keywords',
|
606 |
'id' => 'saswp_webpage_keywords_'.$schema_id,
|
5163 |
'id' => 'saswp_book_no_of_page_'.$schema_id,
|
5164 |
'type' => 'text',
|
5165 |
),
|
5166 |
+
array(
|
5167 |
+
'label' => 'Book Format',
|
5168 |
+
'id' => 'saswp_book_format_'.$schema_id,
|
5169 |
+
'type' => 'select',
|
5170 |
+
'options' => array(
|
5171 |
+
'AudiobookFormat' => 'AudiobookFormat',
|
5172 |
+
'EBook' => 'EBook',
|
5173 |
+
'GraphicNovel' => 'GraphicNovel',
|
5174 |
+
'Hardcover' => 'Hardcover',
|
5175 |
+
'Paperback' => 'Paperback'
|
5176 |
+
)
|
5177 |
+
),
|
5178 |
+
array(
|
5179 |
+
'label' => 'In Language',
|
5180 |
+
'id' => 'saswp_book_inlanguage_'.$schema_id,
|
5181 |
+
'type' => 'text',
|
5182 |
+
'attributes' => array(
|
5183 |
+
'placeholder' => 'English'
|
5184 |
+
),
|
5185 |
+
),
|
5186 |
array(
|
5187 |
'label' => 'Publisher',
|
5188 |
'id' => 'saswp_book_publisher_'.$schema_id,
|
modules/gutenberg/includes/class-gutenberg.php
CHANGED
@@ -516,7 +516,7 @@ class SASWP_Gutenberg {
|
|
516 |
|
517 |
if(!empty($attributes['tools'])){
|
518 |
|
519 |
-
echo '<h5>'.saswp_label_text('translation-tools').'</h5>';
|
520 |
|
521 |
echo '<ul>';
|
522 |
foreach($attributes['tools'] as $val){
|
@@ -535,7 +535,7 @@ class SASWP_Gutenberg {
|
|
535 |
|
536 |
if(!empty($attributes['materials'])){
|
537 |
|
538 |
-
echo '<h5>'.saswp_label_text('translation-materials').'</h5>';
|
539 |
|
540 |
echo '<ul>';
|
541 |
foreach($attributes['materials'] as $val){
|
516 |
|
517 |
if(!empty($attributes['tools'])){
|
518 |
|
519 |
+
echo '<h5>'.saswp_t_string(saswp_label_text('translation-tools')).'</h5>';
|
520 |
|
521 |
echo '<ul>';
|
522 |
foreach($attributes['tools'] as $val){
|
535 |
|
536 |
if(!empty($attributes['materials'])){
|
537 |
|
538 |
+
echo '<h5>'.saswp_t_string(saswp_label_text('translation-materials')).'</h5>';
|
539 |
|
540 |
echo '<ul>';
|
541 |
foreach($attributes['materials'] as $val){
|
modules/gutenberg/includes/render.php
CHANGED
@@ -12,9 +12,9 @@ class SASWP_Gutenberg_Render {
|
|
12 |
|
13 |
$question = '<div class="saswp-qanda-block-question">
|
14 |
<h3>'.esc_html($attributes['question_name']).'</h3>
|
15 |
-
<span class="saswp-qand-date">'.esc_html($attributes['question_date_created']).' '.esc_html($attributes['question_time_created']).' '.
|
16 |
<p>'.esc_html($attributes['question_text']).'</p>
|
17 |
-
'.
|
18 |
</div>';
|
19 |
|
20 |
if(isset($attributes['accepted_answers']) && !empty($attributes['accepted_answers'])){
|
@@ -26,7 +26,7 @@ class SASWP_Gutenberg_Render {
|
|
26 |
<p>'.esc_html($answer['text']).'</p>
|
27 |
</a>
|
28 |
<span class="saswp-qand-date">'.esc_html($answer['date_created']).' '.esc_html($answer['time_created']).' by <strong>'.esc_html($answer['author']).'</strong></span>
|
29 |
-
<br> '.
|
30 |
|
31 |
</li>';
|
32 |
|
@@ -43,7 +43,7 @@ class SASWP_Gutenberg_Render {
|
|
43 |
<p>'.esc_html($answer['text']).'</p>
|
44 |
</a>
|
45 |
<span class="saswp-qand-date">'.esc_html($answer['date_created']).' '.esc_html($answer['time_created']).' by <strong>'.esc_html($answer['author']).'</strong></span>
|
46 |
-
<br> '.
|
47 |
</li>';
|
48 |
}
|
49 |
|
@@ -51,8 +51,8 @@ class SASWP_Gutenberg_Render {
|
|
51 |
//Escaping has been done above for all below html
|
52 |
$response = '<div class="saswp-qanda-block-html">
|
53 |
'.$question.'
|
54 |
-
<div class="saswp-qanda-block-answer"><h3>'.
|
55 |
-
<div class="saswp-qanda-block-answer"><h3>'.
|
56 |
</div>';
|
57 |
|
58 |
return $response;
|
@@ -68,9 +68,9 @@ class SASWP_Gutenberg_Render {
|
|
68 |
foreach($attributes['organizers'] as $org){
|
69 |
|
70 |
$org_html .= '<div class="saswp-event-organiser"><span>'.esc_html($org['name']).'</span><br>';
|
71 |
-
$org_html .= '<strong>'.
|
72 |
-
$org_html .= '<strong>'.
|
73 |
-
$org_html .= '<strong>'.
|
74 |
|
75 |
}
|
76 |
|
@@ -81,8 +81,8 @@ class SASWP_Gutenberg_Render {
|
|
81 |
foreach($attributes['performers'] as $org){
|
82 |
|
83 |
$performer_html .= '<div class="saswp-event-organiser"><span>'.esc_html($org['name']).'</span><br>';
|
84 |
-
$performer_html .= '<strong>'.
|
85 |
-
$performer_html .= '<strong>'.
|
86 |
|
87 |
}
|
88 |
|
@@ -92,7 +92,7 @@ class SASWP_Gutenberg_Render {
|
|
92 |
|
93 |
if(isset($attributes['event_status']) && $attributes['event_status'] == 'EventRescheduled' && isset($attributes['previous_date'])){
|
94 |
|
95 |
-
$previous_date = '<strong>'.
|
96 |
. (!isset($attributes['all_day']) ? '<span> ,'.esc_html($attributes['previous_time']).'</span><br>' : '<br>');
|
97 |
|
98 |
}
|
@@ -100,21 +100,21 @@ class SASWP_Gutenberg_Render {
|
|
100 |
$response .= '<div class="saswp-event-wrapper">'
|
101 |
. (isset($attributes['description']) ? '<p>'.$attributes['description'].'</p>' : '')
|
102 |
. '<div class="saswp-event-dates">'
|
103 |
-
. '<h5>'.
|
104 |
-
. '<strong>'.
|
105 |
. (!isset($attributes['all_day']) ? '<span> ,'.esc_html($attributes['start_time']).'</span><br>' : '<br>')
|
106 |
-
. '<strong>'.
|
107 |
. (!isset($attributes['all_day']) ? '<span> ,'.esc_html($attributes['end_time']).'</span><br>' : '<br>')
|
108 |
. $previous_date
|
109 |
-
. ($attributes['website'] ? '<strong>'.
|
110 |
-
. ($attributes['price'] ? '<strong>'.
|
111 |
-
. ($attributes['attendance_mode'] ? '<strong>'.
|
112 |
-
. ($attributes['event_status'] ? '<strong>'.
|
113 |
-
. (isset($attributes['all_day']) ? '<div>'.
|
114 |
. '</div>'
|
115 |
|
116 |
. '<div class="saswp-event-venue-details">'
|
117 |
-
. (($attributes['venue_name'] || $attributes['venue_address']) ? '<h5>'.
|
118 |
. ($attributes['venue_name'] ? '<span>'.esc_html($attributes['venue_name']).'</span><br><br>' : '')
|
119 |
. ($attributes['venue_address'] ? '<span>'.esc_html($attributes['venue_address']).'</span>, ': '')
|
120 |
. ($attributes['venue_city'] ? '<span>'.esc_html($attributes['venue_city']).'</span>, <br>': '')
|
@@ -122,15 +122,15 @@ class SASWP_Gutenberg_Render {
|
|
122 |
. ($attributes['venue_postal_code'] ? '<span>'.esc_html($attributes['venue_postal_code']).'</span>, ': '')
|
123 |
. ($attributes['venue_country'] ? '<span>'.esc_html($attributes['venue_country']).'</span><br>': '');
|
124 |
if($attributes['venue_phone']){
|
125 |
-
$response.= '<strong>'.
|
126 |
}
|
127 |
$response.= '</div>'
|
128 |
. '<div class="saswp-event-organizers-details">'
|
129 |
-
. '<h5>'.
|
130 |
. $org_html
|
131 |
. '</div>'
|
132 |
. '<div class="saswp-event-performers-details">'
|
133 |
-
. '<h5>'.
|
134 |
. $performer_html
|
135 |
. '</div>'
|
136 |
. '</div>';
|
@@ -173,13 +173,13 @@ class SASWP_Gutenberg_Render {
|
|
173 |
$response.= '<p class="saswp-job-company-name">';
|
174 |
|
175 |
if($attributes['company_website']){
|
176 |
-
$response .= '<a target="_blank" class="saswp-job-company-website" href="'.esc_url($attributes['company_website']).'"><span class="dashicons dashicons-admin-links"></span> '.
|
177 |
}
|
178 |
if($attributes['company_twitter']){
|
179 |
-
$response .= '<a target="_blank" class="saswp-job-company-twitter" href="'.esc_url($attributes['company_twitter']).'"><span class="dashicons dashicons-twitter"></span> '.
|
180 |
}
|
181 |
if($attributes['company_facebook']){
|
182 |
-
$response .= '<a target="_blank" class="saswp-job-company-facebook" href="'.esc_url($attributes['company_facebook']).'"><span class="dashicons dashicons-facebook-alt"></span>'.
|
183 |
}
|
184 |
|
185 |
$response .= '<strong>'.esc_html($attributes['company_name']).'</strong>'
|
@@ -187,7 +187,7 @@ class SASWP_Gutenberg_Render {
|
|
187 |
. '<p class="saswp-job-company-tagline">'.esc_html($attributes['company_tagline']).'</p>';
|
188 |
|
189 |
if($attributes['base_salary']){
|
190 |
-
$response .= '<p><strong>'.
|
191 |
}
|
192 |
|
193 |
$response.= '</div>'
|
@@ -198,7 +198,7 @@ class SASWP_Gutenberg_Render {
|
|
198 |
. '<div class="saswp-job-application-details">';
|
199 |
|
200 |
if($attributes['app_email_or_website']){
|
201 |
-
$response.=
|
202 |
. '<a href="mailto:'.esc_attr($attributes['app_email_or_website']).'">'.esc_attr($attributes['app_email_or_website']).'</a>';
|
203 |
}
|
204 |
|
@@ -220,16 +220,16 @@ class SASWP_Gutenberg_Render {
|
|
220 |
foreach($attributes['courses'] as $course){
|
221 |
|
222 |
$response .= '<div class="saswp-course-loop">'
|
223 |
-
. '<h3 class="saswp-course-detail">'.
|
224 |
. '<h5>'.esc_html($course['name']).'</h5>'
|
225 |
. '<p>';
|
226 |
if($course['image_url']){
|
227 |
$response .='<img src="'.esc_url($course['image_url']).'">';
|
228 |
}
|
229 |
$response .= ''.esc_html($course['description']).'</p>'
|
230 |
-
. '<h5>'.
|
231 |
-
. '<div><strong>'.
|
232 |
-
. '<div><strong>'.
|
233 |
. '</div>';
|
234 |
|
235 |
}
|
12 |
|
13 |
$question = '<div class="saswp-qanda-block-question">
|
14 |
<h3>'.esc_html($attributes['question_name']).'</h3>
|
15 |
+
<span class="saswp-qand-date">'.esc_html($attributes['question_date_created']).' '.esc_html($attributes['question_time_created']).' '.saswp_t_string( 'by' ).' '.esc_html($attributes['question_author']).'</span>
|
16 |
<p>'.esc_html($attributes['question_text']).'</p>
|
17 |
+
'. saswp_t_string( 'Vote' ).' <span class="dashicons dashicons-thumbs-up"></span> ('.esc_html($attributes['question_up_vote']).')
|
18 |
</div>';
|
19 |
|
20 |
if(isset($attributes['accepted_answers']) && !empty($attributes['accepted_answers'])){
|
26 |
<p>'.esc_html($answer['text']).'</p>
|
27 |
</a>
|
28 |
<span class="saswp-qand-date">'.esc_html($answer['date_created']).' '.esc_html($answer['time_created']).' by <strong>'.esc_html($answer['author']).'</strong></span>
|
29 |
+
<br> '. saswp_t_string( 'Vote' ).' <span class="dashicons dashicons-thumbs-up"></span> ('.esc_html($answer['vote']).')
|
30 |
|
31 |
</li>';
|
32 |
|
43 |
<p>'.esc_html($answer['text']).'</p>
|
44 |
</a>
|
45 |
<span class="saswp-qand-date">'.esc_html($answer['date_created']).' '.esc_html($answer['time_created']).' by <strong>'.esc_html($answer['author']).'</strong></span>
|
46 |
+
<br> '. saswp_t_string( 'Vote' ).' <span class="dashicons dashicons-thumbs-up"></span> ('.esc_html($answer['vote']).')
|
47 |
</li>';
|
48 |
}
|
49 |
|
51 |
//Escaping has been done above for all below html
|
52 |
$response = '<div class="saswp-qanda-block-html">
|
53 |
'.$question.'
|
54 |
+
<div class="saswp-qanda-block-answer"><h3>'. saswp_t_string( 'Accepted Answers' ).'</h3>'.$accepted_answers.'</div>
|
55 |
+
<div class="saswp-qanda-block-answer"><h3>'. saswp_t_string( 'Suggested Answers' ) .'</h3>'.$suggested_answers.'</div>
|
56 |
</div>';
|
57 |
|
58 |
return $response;
|
68 |
foreach($attributes['organizers'] as $org){
|
69 |
|
70 |
$org_html .= '<div class="saswp-event-organiser"><span>'.esc_html($org['name']).'</span><br>';
|
71 |
+
$org_html .= '<strong>'.saswp_t_string('Phone').' : </strong><span>'.esc_html($org['phone']).'</span><br>';
|
72 |
+
$org_html .= '<strong>'.saswp_t_string('Email').' : </strong><span>'.esc_html($org['email']).'</span><br>';
|
73 |
+
$org_html .= '<strong>'.saswp_t_string('Website').' : </strong> <span>'.esc_html($org['website']).'</span></div>';
|
74 |
|
75 |
}
|
76 |
|
81 |
foreach($attributes['performers'] as $org){
|
82 |
|
83 |
$performer_html .= '<div class="saswp-event-organiser"><span>'.esc_html($org['name']).'</span><br>';
|
84 |
+
$performer_html .= '<strong>'.saswp_t_string('URL').' : </strong><span><a href="'.esc_url($org['url']).'">'.esc_url($org['url']).'</a></span><br>';
|
85 |
+
$performer_html .= '<strong>'.saswp_t_string('Email').' : </strong><span>'.esc_html($org['email']).'</span><br>';
|
86 |
|
87 |
}
|
88 |
|
92 |
|
93 |
if(isset($attributes['event_status']) && $attributes['event_status'] == 'EventRescheduled' && isset($attributes['previous_date'])){
|
94 |
|
95 |
+
$previous_date = '<strong>'.saswp_t_string('Previous Date').' : </strong> <span>'.esc_html($attributes['previous_date']).'</span>'
|
96 |
. (!isset($attributes['all_day']) ? '<span> ,'.esc_html($attributes['previous_time']).'</span><br>' : '<br>');
|
97 |
|
98 |
}
|
100 |
$response .= '<div class="saswp-event-wrapper">'
|
101 |
. (isset($attributes['description']) ? '<p>'.$attributes['description'].'</p>' : '')
|
102 |
. '<div class="saswp-event-dates">'
|
103 |
+
. '<h5>'.saswp_t_string('Event Details').'</h5>'
|
104 |
+
. '<strong>'.saswp_t_string('Start Date').' : </strong> <span>'.esc_html($attributes['start_date']).'</span>'
|
105 |
. (!isset($attributes['all_day']) ? '<span> ,'.esc_html($attributes['start_time']).'</span><br>' : '<br>')
|
106 |
+
. '<strong>'.saswp_t_string('End Date').' : </strong> <span>'.esc_html($attributes['end_date']).'</span>'
|
107 |
. (!isset($attributes['all_day']) ? '<span> ,'.esc_html($attributes['end_time']).'</span><br>' : '<br>')
|
108 |
. $previous_date
|
109 |
+
. ($attributes['website'] ? '<strong>'.saswp_t_string('Website').' : </strong> <span><a href="'.esc_url($attributes['website']).'">'.esc_url($attributes['website']).'</a></span><br>' : '')
|
110 |
+
. ($attributes['price'] ? '<strong>'.saswp_t_string('Price').' : </strong> <span>'.esc_html($attributes['price']).' '. (isset($attributes['currency_code']) ? esc_html($attributes['currency_code']) : 'USD').'</span><br>' : '')
|
111 |
+
. ($attributes['attendance_mode'] ? '<strong>'.saswp_t_string('Attendance Mode').' : </strong> <span>'.esc_html($attributes['attendance_mode']).'</span><br>' : '')
|
112 |
+
. ($attributes['event_status'] ? '<strong>'.saswp_t_string('Status').' : </strong> <span>'.esc_html($attributes['event_status']).'</span>' : '')
|
113 |
+
. (isset($attributes['all_day']) ? '<div>'.saswp_t_string('This event is all day').'</div>' : '')
|
114 |
. '</div>'
|
115 |
|
116 |
. '<div class="saswp-event-venue-details">'
|
117 |
+
. (($attributes['venue_name'] || $attributes['venue_address']) ? '<h5>'.saswp_t_string('Venue').'</h5>' : '')
|
118 |
. ($attributes['venue_name'] ? '<span>'.esc_html($attributes['venue_name']).'</span><br><br>' : '')
|
119 |
. ($attributes['venue_address'] ? '<span>'.esc_html($attributes['venue_address']).'</span>, ': '')
|
120 |
. ($attributes['venue_city'] ? '<span>'.esc_html($attributes['venue_city']).'</span>, <br>': '')
|
122 |
. ($attributes['venue_postal_code'] ? '<span>'.esc_html($attributes['venue_postal_code']).'</span>, ': '')
|
123 |
. ($attributes['venue_country'] ? '<span>'.esc_html($attributes['venue_country']).'</span><br>': '');
|
124 |
if($attributes['venue_phone']){
|
125 |
+
$response.= '<strong>'.saswp_t_string('Phone').' : </strong><span>'.esc_html($attributes['venue_phone']).'</span>';
|
126 |
}
|
127 |
$response.= '</div>'
|
128 |
. '<div class="saswp-event-organizers-details">'
|
129 |
+
. '<h5>'.saswp_t_string('Organizers').'</h5>'
|
130 |
. $org_html
|
131 |
. '</div>'
|
132 |
. '<div class="saswp-event-performers-details">'
|
133 |
+
. '<h5>'.saswp_t_string('Performers').'</h5>'
|
134 |
. $performer_html
|
135 |
. '</div>'
|
136 |
. '</div>';
|
173 |
$response.= '<p class="saswp-job-company-name">';
|
174 |
|
175 |
if($attributes['company_website']){
|
176 |
+
$response .= '<a target="_blank" class="saswp-job-company-website" href="'.esc_url($attributes['company_website']).'"><span class="dashicons dashicons-admin-links"></span> '.saswp_t_string('Website').'</a>';
|
177 |
}
|
178 |
if($attributes['company_twitter']){
|
179 |
+
$response .= '<a target="_blank" class="saswp-job-company-twitter" href="'.esc_url($attributes['company_twitter']).'"><span class="dashicons dashicons-twitter"></span> '.saswp_t_string('Twitter').'</a>';
|
180 |
}
|
181 |
if($attributes['company_facebook']){
|
182 |
+
$response .= '<a target="_blank" class="saswp-job-company-facebook" href="'.esc_url($attributes['company_facebook']).'"><span class="dashicons dashicons-facebook-alt"></span>'.saswp_t_string('Facebook').'</a>';
|
183 |
}
|
184 |
|
185 |
$response .= '<strong>'.esc_html($attributes['company_name']).'</strong>'
|
187 |
. '<p class="saswp-job-company-tagline">'.esc_html($attributes['company_tagline']).'</p>';
|
188 |
|
189 |
if($attributes['base_salary']){
|
190 |
+
$response .= '<p><strong>'.saswp_t_string('Base Salary').': </strong> <span>'.esc_html($attributes['base_salary']).' '.esc_html($attributes['currency_code']).' '.saswp_t_string('per').' '.esc_html($attributes['unit_text']).'</span> <p>';
|
191 |
}
|
192 |
|
193 |
$response.= '</div>'
|
198 |
. '<div class="saswp-job-application-details">';
|
199 |
|
200 |
if($attributes['app_email_or_website']){
|
201 |
+
$response.= saswp_t_string('To apply for this job').' <strong>'.esc_html($attributes['app_email_or_website']).'</strong> '
|
202 |
. '<a href="mailto:'.esc_attr($attributes['app_email_or_website']).'">'.esc_attr($attributes['app_email_or_website']).'</a>';
|
203 |
}
|
204 |
|
220 |
foreach($attributes['courses'] as $course){
|
221 |
|
222 |
$response .= '<div class="saswp-course-loop">'
|
223 |
+
. '<h3 class="saswp-course-detail">'.saswp_t_string('Course Details').'</h3>'
|
224 |
. '<h5>'.esc_html($course['name']).'</h5>'
|
225 |
. '<p>';
|
226 |
if($course['image_url']){
|
227 |
$response .='<img src="'.esc_url($course['image_url']).'">';
|
228 |
}
|
229 |
$response .= ''.esc_html($course['description']).'</p>'
|
230 |
+
. '<h5>'.saswp_t_string('Provider Details').'</h5>'
|
231 |
+
. '<div><strong>'.saswp_t_string('Provider Name').'</strong> : '. esc_html($course['provider_name']). '</div>'
|
232 |
+
. '<div><strong>'.saswp_t_string('Provider Website').'</strong> : '. '<a href="'.esc_url($course['provider_website']).'">'.esc_url($course['provider_website']).'</a></div>'
|
233 |
. '</div>';
|
234 |
|
235 |
}
|
modules/rating-box/backend.php
CHANGED
@@ -48,7 +48,7 @@ class saswp_rating_box_backend {
|
|
48 |
|
49 |
add_meta_box(
|
50 |
'saswp_rating_box',
|
51 |
-
|
52 |
array( $this, 'saswp_meta_box_callback' ),
|
53 |
$single_screen,
|
54 |
'advanced',
|
@@ -90,23 +90,23 @@ class saswp_rating_box_backend {
|
|
90 |
|
91 |
?>
|
92 |
<div>
|
93 |
-
<div class="saswp-enable-review-on-post"><label><?php echo
|
94 |
|
95 |
<div class="saswp-review-fields">
|
96 |
<div class="saswp-review-item">
|
97 |
<table class="saswp-review-tables">
|
98 |
<tr>
|
99 |
-
<td><label><?php echo
|
100 |
<td><div class="saswp-field"><input type="text" id="saswp-review-item-title" name="saswp-review-item-title" value="<?php if ( isset( $saswp_review_details['saswp-review-item-title'] ) && ( ! empty( $saswp_review_details['saswp-review-item-title'] ) ) ) echo esc_attr( $saswp_review_details['saswp-review-item-title'] ); ?>"></div></td>
|
101 |
</tr>
|
102 |
<tr>
|
103 |
-
<td><label><?php echo
|
104 |
<td>
|
105 |
<div class="saswp-field">
|
106 |
<select id="saswp-review-location" name="saswp-review-location">
|
107 |
-
<option value="1" <?php if ( isset( $saswp_review_details['saswp-review-location'] ) && ( $saswp_review_details['saswp-review-location'] == 1 ) ) echo 'selected'; ?>><?php echo
|
108 |
-
<option value="2" <?php if ( isset( $saswp_review_details['saswp-review-location'] ) && ( $saswp_review_details['saswp-review-location'] == 2 ) ) echo 'selected'; ?>><?php echo
|
109 |
-
<option value="3" <?php if ( isset( $saswp_review_details['saswp-review-location'] ) && ( $saswp_review_details['saswp-review-location'] == 3 ) ) echo 'selected'; ?>><?php echo
|
110 |
</select>
|
111 |
<input class="saswp-review-shortcode" type="text" value="<?php echo '[saswp-review id="review"]'; ?>" readonly>
|
112 |
</div>
|
@@ -125,9 +125,9 @@ class saswp_rating_box_backend {
|
|
125 |
for ($i=0; $i<count($saswp_review_item_feature); $i++){
|
126 |
?>
|
127 |
<tr class="saswp-review-item-tr">
|
128 |
-
<td><?php echo
|
129 |
<td><input type="text" name="saswp-review-item-feature[]" value="<?php echo esc_attr($saswp_review_item_feature[$i]); ?>"></td>
|
130 |
-
<td><?php echo
|
131 |
<td><input step="0.1" min="0" max="5" type="number" name="saswp-review-item-star-rating[]" value="<?php echo esc_attr($saswp_review_item_star_rating[$i]); ?>"></td>
|
132 |
<td><a type="button" class="saswp-remove-review-item button">x</a></td>
|
133 |
</tr>
|
@@ -137,13 +137,13 @@ class saswp_rating_box_backend {
|
|
137 |
}
|
138 |
?>
|
139 |
</table>
|
140 |
-
<div class="saswp-over-all-raring"><label><?php echo
|
141 |
-
<div><a class="button saswp-add-more-item"><?php echo
|
142 |
</div>
|
143 |
|
144 |
<div class="saswp-review-description">
|
145 |
-
<div><label><?php echo
|
146 |
-
<div class="saswp-wp-ediot-desc"><label><?php echo
|
147 |
<?php
|
148 |
$content = get_post_meta( $post->ID, 'saswp-review-item-description', true );
|
149 |
wp_editor( $content, 'saswp-review-item-description', array('textarea_rows'=> '5', 'media_buttons' => FALSE,) );
|
@@ -152,7 +152,7 @@ class saswp_rating_box_backend {
|
|
152 |
|
153 |
<div class="saswp-review-pros-and-cons">
|
154 |
<div class="saswp-props">
|
155 |
-
<div class="saswp-wp-ediot-desc"><label><?php echo
|
156 |
<?php
|
157 |
$content = get_post_meta( $post->ID, 'saswp-review-item-props', true );
|
158 |
wp_editor( $content, 'saswp-review-item-props',
|
@@ -170,7 +170,7 @@ class saswp_rating_box_backend {
|
|
170 |
?>
|
171 |
</div>
|
172 |
<div class="saswp-cons">
|
173 |
-
<div class="saswp-wp-ediot-desc"><label><?php echo
|
174 |
<?php
|
175 |
$content = get_post_meta( $post->ID, 'saswp-review-item-cons', true );
|
176 |
wp_editor( $content,
|
48 |
|
49 |
add_meta_box(
|
50 |
'saswp_rating_box',
|
51 |
+
saswp_t_string( 'Rating Box' ),
|
52 |
array( $this, 'saswp_meta_box_callback' ),
|
53 |
$single_screen,
|
54 |
'advanced',
|
90 |
|
91 |
?>
|
92 |
<div>
|
93 |
+
<div class="saswp-enable-review-on-post"><label><?php echo saswp_t_string('Enable/Disable'); ?> <input type="checkbox" id="saswp-review-item-enable" name="saswp-review-item-enable" <?php echo (isset( $saswp_review_details['saswp-review-item-enable'] ) && $saswp_review_details['saswp-review-item-enable'] == 1 ? 'checked="checked"' : ''); ?> value="1"></label></div>
|
94 |
|
95 |
<div class="saswp-review-fields">
|
96 |
<div class="saswp-review-item">
|
97 |
<table class="saswp-review-tables">
|
98 |
<tr>
|
99 |
+
<td><label><?php echo saswp_t_string('Review Title'); ?></label></td>
|
100 |
<td><div class="saswp-field"><input type="text" id="saswp-review-item-title" name="saswp-review-item-title" value="<?php if ( isset( $saswp_review_details['saswp-review-item-title'] ) && ( ! empty( $saswp_review_details['saswp-review-item-title'] ) ) ) echo esc_attr( $saswp_review_details['saswp-review-item-title'] ); ?>"></div></td>
|
101 |
</tr>
|
102 |
<tr>
|
103 |
+
<td><label><?php echo saswp_t_string('Review Location'); ?></label></td>
|
104 |
<td>
|
105 |
<div class="saswp-field">
|
106 |
<select id="saswp-review-location" name="saswp-review-location">
|
107 |
+
<option value="1" <?php if ( isset( $saswp_review_details['saswp-review-location'] ) && ( $saswp_review_details['saswp-review-location'] == 1 ) ) echo 'selected'; ?>><?php echo saswp_t_string('After The Content'); ?></option>
|
108 |
+
<option value="2" <?php if ( isset( $saswp_review_details['saswp-review-location'] ) && ( $saswp_review_details['saswp-review-location'] == 2 ) ) echo 'selected'; ?>><?php echo saswp_t_string('Before The Content'); ?></option>
|
109 |
+
<option value="3" <?php if ( isset( $saswp_review_details['saswp-review-location'] ) && ( $saswp_review_details['saswp-review-location'] == 3 ) ) echo 'selected'; ?>><?php echo saswp_t_string('Custom (Use ShortCode)'); ?></option>
|
110 |
</select>
|
111 |
<input class="saswp-review-shortcode" type="text" value="<?php echo '[saswp-review id="review"]'; ?>" readonly>
|
112 |
</div>
|
125 |
for ($i=0; $i<count($saswp_review_item_feature); $i++){
|
126 |
?>
|
127 |
<tr class="saswp-review-item-tr">
|
128 |
+
<td><?php echo saswp_t_string('Review Item Feature'); ?></td>
|
129 |
<td><input type="text" name="saswp-review-item-feature[]" value="<?php echo esc_attr($saswp_review_item_feature[$i]); ?>"></td>
|
130 |
+
<td><?php echo saswp_t_string('Rating'); ?></td>
|
131 |
<td><input step="0.1" min="0" max="5" type="number" name="saswp-review-item-star-rating[]" value="<?php echo esc_attr($saswp_review_item_star_rating[$i]); ?>"></td>
|
132 |
<td><a type="button" class="saswp-remove-review-item button">x</a></td>
|
133 |
</tr>
|
137 |
}
|
138 |
?>
|
139 |
</table>
|
140 |
+
<div class="saswp-over-all-raring"><label><?php echo saswp_t_string('Over All Rating'); ?></label><input type="text" id="saswp-review-item-over-all" name="saswp-review-item-over-all" value="<?php if ( isset( $saswp_review_details['saswp-review-item-over-all'] ) && ( ! empty( $saswp_review_details['saswp-review-item-over-all'] ) ) ) echo esc_attr( $saswp_review_details['saswp-review-item-over-all'] ); ?>" readonly></div>
|
141 |
+
<div><a class="button saswp-add-more-item"><?php echo saswp_t_string('Add Item'); ?></a></div>
|
142 |
</div>
|
143 |
|
144 |
<div class="saswp-review-description">
|
145 |
+
<div><label><?php echo saswp_t_string('Summary Title'); ?></label> <input type="text" id="saswp-review-item-description-title" name="saswp-review-item-description-title" value="<?php if ( isset( $saswp_review_details['saswp-review-item-description-title'] ) && ( ! empty( $saswp_review_details['saswp-review-item-description-title'] ) ) ) echo esc_attr( $saswp_review_details['saswp-review-item-description-title'] ); ?>"></div>
|
146 |
+
<div class="saswp-wp-ediot-desc"><label><?php echo saswp_t_string('Description'); ?></label></div>
|
147 |
<?php
|
148 |
$content = get_post_meta( $post->ID, 'saswp-review-item-description', true );
|
149 |
wp_editor( $content, 'saswp-review-item-description', array('textarea_rows'=> '5', 'media_buttons' => FALSE,) );
|
152 |
|
153 |
<div class="saswp-review-pros-and-cons">
|
154 |
<div class="saswp-props">
|
155 |
+
<div class="saswp-wp-ediot-desc"><label><?php echo saswp_t_string('Pros'); ?></label></div>
|
156 |
<?php
|
157 |
$content = get_post_meta( $post->ID, 'saswp-review-item-props', true );
|
158 |
wp_editor( $content, 'saswp-review-item-props',
|
170 |
?>
|
171 |
</div>
|
172 |
<div class="saswp-cons">
|
173 |
+
<div class="saswp-wp-ediot-desc"><label><?php echo saswp_t_string('Cons'); ?></label></div>
|
174 |
<?php
|
175 |
$content = get_post_meta( $post->ID, 'saswp-review-item-cons', true );
|
176 |
wp_editor( $content,
|
modules/rating-box/frontend.php
CHANGED
@@ -182,11 +182,11 @@ Class saswp_rating_box_frontend{
|
|
182 |
$boxdata .='
|
183 |
<div class="saswp-pc-wrap">
|
184 |
<div class="saswp-lst">
|
185 |
-
<span>'.saswp_label_text('translation-pros').'</span><br>
|
186 |
'.wpautop( stripslashes ( $saswp_review_props ) ).'
|
187 |
</div>
|
188 |
<div class="saswp-lst">
|
189 |
-
<span>'.saswp_label_text('translation-cons').'</span><br>
|
190 |
'.wpautop( stripslashes ( $saswp_review_cons ) ).'
|
191 |
</div>
|
192 |
</div>';
|
@@ -198,7 +198,7 @@ Class saswp_rating_box_frontend{
|
|
198 |
$boxdata.='<table class="saswp-rvw">
|
199 |
<tbody>
|
200 |
<div class="saswp-rvw-hd">
|
201 |
-
<span>'.saswp_label_text('translation-review-overview').'</span>
|
202 |
</div>';
|
203 |
|
204 |
if(isset($saswp_review_item_feature)){
|
@@ -215,7 +215,7 @@ Class saswp_rating_box_frontend{
|
|
215 |
}
|
216 |
$boxdata.='<tr>
|
217 |
<td class="saswp-rvw-sm">
|
218 |
-
<span>'.
|
219 |
<div class="rvw-dsc">
|
220 |
'.wpautop( stripslashes ( $saswp_review_description ) ).'
|
221 |
</div>
|
182 |
$boxdata .='
|
183 |
<div class="saswp-pc-wrap">
|
184 |
<div class="saswp-lst">
|
185 |
+
<span>'.saswp_t_string(saswp_label_text('translation-pros')).'</span><br>
|
186 |
'.wpautop( stripslashes ( $saswp_review_props ) ).'
|
187 |
</div>
|
188 |
<div class="saswp-lst">
|
189 |
+
<span>'.saswp_t_string(saswp_label_text('translation-cons')).'</span><br>
|
190 |
'.wpautop( stripslashes ( $saswp_review_cons ) ).'
|
191 |
</div>
|
192 |
</div>';
|
198 |
$boxdata.='<table class="saswp-rvw">
|
199 |
<tbody>
|
200 |
<div class="saswp-rvw-hd">
|
201 |
+
<span>'.saswp_t_string(saswp_label_text('translation-review-overview')).'</span>
|
202 |
</div>';
|
203 |
|
204 |
if(isset($saswp_review_item_feature)){
|
215 |
}
|
216 |
$boxdata.='<tr>
|
217 |
<td class="saswp-rvw-sm">
|
218 |
+
<span>'.saswp_t_string('SUMMARY').'</span>
|
219 |
<div class="rvw-dsc">
|
220 |
'.wpautop( stripslashes ( $saswp_review_description ) ).'
|
221 |
</div>
|
modules/reviews/comments.php
CHANGED
@@ -171,7 +171,7 @@ function saswp_comment_rating_display_average_rating() {
|
|
171 |
$average = $average_rate['average'];
|
172 |
$count = $average_rate['count'];
|
173 |
|
174 |
-
$custom_content = '<div class="saswp-average-rating">'.
|
175 |
|
176 |
echo $custom_content;
|
177 |
|
171 |
$average = $average_rate['average'];
|
172 |
$count = $average_rate['count'];
|
173 |
|
174 |
+
$custom_content = '<div class="saswp-average-rating">'.saswp_t_string('Average').' '. saswp_get_rating_html_by_value($average).' '.esc_html($average).' '. saswp_t_string('Based On') .' '.esc_html($count).'</div>';
|
175 |
|
176 |
echo $custom_content;
|
177 |
|
modules/reviews/reviews_admin.php
CHANGED
@@ -87,7 +87,7 @@ class saswp_reviews_admin {
|
|
87 |
|
88 |
add_meta_box(
|
89 |
'saswp_review_content',
|
90 |
-
|
91 |
array( $this, 'saswp_meta_box_callback' ),
|
92 |
$single_screen,
|
93 |
'normal',
|
@@ -124,7 +124,7 @@ class saswp_reviews_admin {
|
|
124 |
if(isset($meta_field['label'])){
|
125 |
$label = $meta_field['label'];
|
126 |
}
|
127 |
-
$label = '<label for="' . esc_attr($meta_field['id']) . '">' .
|
128 |
$meta_value = get_post_meta( $post->ID, $meta_field['id'], true );
|
129 |
|
130 |
if ( empty( $meta_value ) ) {
|
@@ -159,12 +159,12 @@ class saswp_reviews_admin {
|
|
159 |
'<option %s value="%s">%s</option>',
|
160 |
$meta_value == $key ? 'selected' : '',
|
161 |
$key,
|
162 |
-
|
163 |
);
|
164 |
}
|
165 |
$input .= '</select>';
|
166 |
|
167 |
-
|
168 |
case 'textarea':
|
169 |
$input = sprintf(
|
170 |
'<textarea class="saswp_textarea" id="%s" name="%s" rows="5">%s</textarea>',
|
87 |
|
88 |
add_meta_box(
|
89 |
'saswp_review_content',
|
90 |
+
saswp_t_string( 'Review Content' ),
|
91 |
array( $this, 'saswp_meta_box_callback' ),
|
92 |
$single_screen,
|
93 |
'normal',
|
124 |
if(isset($meta_field['label'])){
|
125 |
$label = $meta_field['label'];
|
126 |
}
|
127 |
+
$label = '<label for="' . esc_attr($meta_field['id']) . '">' . saswp_t_string( $label ) . '</label>';
|
128 |
$meta_value = get_post_meta( $post->ID, $meta_field['id'], true );
|
129 |
|
130 |
if ( empty( $meta_value ) ) {
|
159 |
'<option %s value="%s">%s</option>',
|
160 |
$meta_value == $key ? 'selected' : '',
|
161 |
$key,
|
162 |
+
saswp_t_string($value)
|
163 |
);
|
164 |
}
|
165 |
$input .= '</select>';
|
166 |
|
167 |
+
break;
|
168 |
case 'textarea':
|
169 |
$input = sprintf(
|
170 |
'<textarea class="saswp_textarea" id="%s" name="%s" rows="5">%s</textarea>',
|
modules/reviews/reviews_collection.php
CHANGED
@@ -55,8 +55,8 @@ class SASWP_Reviews_Collection {
|
|
55 |
public function saswp_add_collection_menu_links(){
|
56 |
|
57 |
add_submenu_page( 'edit.php?post_type=saswp',
|
58 |
-
|
59 |
-
|
60 |
saswp_current_user_can(),
|
61 |
'collection',
|
62 |
array($this, 'saswp_admin_collection_interface_render'));
|
@@ -143,10 +143,10 @@ class SASWP_Reviews_Collection {
|
|
143 |
|
144 |
$collections = array(
|
145 |
'labels' => array(
|
146 |
-
'name' =>
|
147 |
-
'add_new' =>
|
148 |
-
'add_new_item' =>
|
149 |
-
'edit_item' =>
|
150 |
),
|
151 |
'public' => true,
|
152 |
'has_archive' => true,
|
@@ -479,7 +479,7 @@ class SASWP_Reviews_Collection {
|
|
479 |
<div class="saswp-collection-settings">
|
480 |
<ul>
|
481 |
<li>
|
482 |
-
<a class="saswp-accordion"><?php echo
|
483 |
<div class="saswp-accordion-panel">
|
484 |
<?php $platforms = saswp_get_terms_as_array();
|
485 |
if($platforms){
|
@@ -513,7 +513,7 @@ class SASWP_Reviews_Collection {
|
|
513 |
|
514 |
} ?>
|
515 |
<input type="number" id="saswp-review-count" name="saswp-review-count" min="0" value="5">
|
516 |
-
<a class="button button-default saswp-add-to-collection"><?php echo
|
517 |
</div>
|
518 |
<div class="saswp-platform-added-list">
|
519 |
|
@@ -524,49 +524,49 @@ class SASWP_Reviews_Collection {
|
|
524 |
</div>
|
525 |
</li>
|
526 |
<li>
|
527 |
-
<a class="saswp-accordion"><?php echo
|
528 |
<div class="saswp-accordion-panel">
|
529 |
<div class="saswp-dp-dsg">
|
530 |
-
<lable><?php echo
|
531 |
<select name="saswp_collection_design" class="saswp-collection-desing saswp-coll-settings-options">
|
532 |
<?php
|
533 |
foreach($coll_desing as $key => $val){
|
534 |
|
535 |
-
echo '<option value="'.esc_attr($key).'" '.($post_meta['saswp_collection_design'][0] == $key ? 'selected':'').' >'.
|
536 |
}
|
537 |
?>
|
538 |
</select>
|
539 |
</div>
|
540 |
<div class="saswp-dp-dsg saswp-coll-options saswp-grid-options saswp-dp-dtm">
|
541 |
-
<label><?php echo
|
542 |
<input type="number" id="saswp-collection-cols" name="saswp_collection_cols" min="1" value="<?php echo (isset($post_meta['saswp_collection_cols'][0]) ? $post_meta['saswp_collection_cols'][0] : '2' ); ?>" class="saswp-number-change saswp-coll-settings-options saswp-coll-options saswp-grid-options">
|
543 |
</div>
|
544 |
|
545 |
<div class="saswp-dp-dsg saswp-coll-options saswp-grid-options saswp-dp-dtm">
|
546 |
-
<span><?php echo
|
547 |
<span><input name="saswp_collection_pagination" type="checkbox" id="saswp-coll-pagination" class="saswp-coll-settings-options" value="1" <?php echo (isset($post_meta['saswp_collection_pagination'][0]) && $post_meta['saswp_collection_pagination'][0] == 1 ? 'checked' : '' ); ?>></span>
|
548 |
</div>
|
549 |
|
550 |
<div class="saswp-dp-dsg saswp-coll-options saswp-grid-options saswp-dp-dtm saswp_hide_imp">
|
551 |
-
<label><?php echo
|
552 |
<input name="saswp_collection_per_page" type="number" min="1" id="saswp-coll-per-page" class="saswp-coll-settings-options" value="<?php echo (isset($post_meta['saswp_collection_per_page'][0]) ? $post_meta['saswp_collection_per_page'][0] : '10' ); ?>">
|
553 |
</div>
|
554 |
|
555 |
<div class="saswp-dp-dsg saswp-dp-dtm saswp-slider-options saswp-coll-options">
|
556 |
-
<label><?php echo
|
557 |
<select name="saswp_collection_gallery_type" id="saswp_collection_gallery_type" class="saswp-slider-type saswp-slider-options saswp_hide saswp-coll-settings-options saswp-coll-options">
|
558 |
-
<option value="slider" <?php echo (isset($post_meta['saswp_collection_gallery_type'][0]) && $post_meta['saswp_collection_gallery_type'][0] == 'slider' ? 'selected' : '' ); ?>><?php echo
|
559 |
-
<option value="carousel" <?php echo (isset($post_meta['saswp_collection_gallery_type'][0]) && $post_meta['saswp_collection_gallery_type'][0] == 'carousel' ? 'selected' : '' ); ?>><?php echo
|
560 |
</select>
|
561 |
</div>
|
562 |
<div class="saswp-slider-display saswp-slider-options saswp_hide saswp-coll-settings-options saswp-coll-options">
|
563 |
-
<span><input type="checkbox" id="saswp_gallery_arrow" name="saswp_gallery_arrow" value="1" <?php echo (isset($post_meta['saswp_gallery_arrow'][0]) && $post_meta['saswp_gallery_arrow'][0] == 1 ? 'checked' : '' ); ?>> <?php echo
|
564 |
-
<span><input type="checkbox" id="saswp_gallery_dots" name="saswp_gallery_dots" value="1" <?php echo (isset($post_meta['saswp_gallery_dots'][0]) && $post_meta['saswp_gallery_dots'][0] == 1 ? 'checked' : '' ); ?>> <?php echo
|
565 |
</div>
|
566 |
|
567 |
<div class="saswp-fomo-options saswp_hide saswp-coll-options">
|
568 |
<div class="saswp-dp-dsg saswp-dp-dtm">
|
569 |
-
<span><?php echo
|
570 |
</span>
|
571 |
<input type="number" id="saswp_fomo_interval" name="saswp_fomo_interval" class="saswp-number-change" min="1" value="<?php echo (isset($post_meta['saswp_fomo_interval'][0]) ? $post_meta['saswp_fomo_interval'][0] : '3' ); ?>">
|
572 |
</div>
|
@@ -575,14 +575,14 @@ class SASWP_Reviews_Collection {
|
|
575 |
</li>
|
576 |
<li>
|
577 |
|
578 |
-
<a class="saswp-accordion"><?php echo
|
579 |
<div class="saswp-accordion-panel">
|
580 |
<div class="saswp-dp-dsg">
|
581 |
-
<lable><?php echo
|
582 |
<select name="saswp_collection_sorting" class="saswp-collection-sorting saswp-coll-settings-options">
|
583 |
<?php
|
584 |
foreach($coll_sorting as $key => $val){
|
585 |
-
echo '<option value="'.esc_attr($key).'" '.($post_meta['saswp_collection_sorting'][0] == $key ? 'selected':'').' >'.
|
586 |
|
587 |
}
|
588 |
|
@@ -592,15 +592,15 @@ class SASWP_Reviews_Collection {
|
|
592 |
</div>
|
593 |
</li>
|
594 |
<li>
|
595 |
-
<a class="saswp-accordion"><?php echo
|
596 |
<div class="saswp-accordion-panel">
|
597 |
<div class="saswp-dp-dsg">
|
598 |
-
<label><?php echo
|
599 |
<select class="saswp-collection-display-method" name="saswp_collection_display_type">
|
600 |
<?php
|
601 |
foreach($coll_display_type as $key => $val){
|
602 |
|
603 |
-
echo '<option value="'.esc_attr($key).'" '.($post_meta['saswp_collection_display_type'][0] == $key ? 'selected':'').' >'.
|
604 |
}
|
605 |
?>
|
606 |
</select>
|
@@ -617,7 +617,7 @@ class SASWP_Reviews_Collection {
|
|
617 |
</ul>
|
618 |
<div class="saswp-sv-btn">
|
619 |
<button type="submit" class="button button-primary" >
|
620 |
-
<?php echo
|
621 |
</button>
|
622 |
</div>
|
623 |
</div><!-- /.saswp-collection-body -->
|
55 |
public function saswp_add_collection_menu_links(){
|
56 |
|
57 |
add_submenu_page( 'edit.php?post_type=saswp',
|
58 |
+
saswp_t_string( 'Structured Data' ),
|
59 |
+
saswp_t_string( '' ),
|
60 |
saswp_current_user_can(),
|
61 |
'collection',
|
62 |
array($this, 'saswp_admin_collection_interface_render'));
|
143 |
|
144 |
$collections = array(
|
145 |
'labels' => array(
|
146 |
+
'name' => saswp_t_string( 'Collections' ),
|
147 |
+
'add_new' => saswp_t_string( 'Add Collection' ),
|
148 |
+
'add_new_item' => saswp_t_string( 'Edit Collection' ),
|
149 |
+
'edit_item' => saswp_t_string( 'Edit Collection'),
|
150 |
),
|
151 |
'public' => true,
|
152 |
'has_archive' => true,
|
479 |
<div class="saswp-collection-settings">
|
480 |
<ul>
|
481 |
<li>
|
482 |
+
<a class="saswp-accordion"><?php echo saswp_t_string('Reviews Source'); ?></a>
|
483 |
<div class="saswp-accordion-panel">
|
484 |
<?php $platforms = saswp_get_terms_as_array();
|
485 |
if($platforms){
|
513 |
|
514 |
} ?>
|
515 |
<input type="number" id="saswp-review-count" name="saswp-review-count" min="0" value="5">
|
516 |
+
<a class="button button-default saswp-add-to-collection"><?php echo saswp_t_string('Add'); ?></a>
|
517 |
</div>
|
518 |
<div class="saswp-platform-added-list">
|
519 |
|
524 |
</div>
|
525 |
</li>
|
526 |
<li>
|
527 |
+
<a class="saswp-accordion"><?php echo saswp_t_string('Presentation'); ?></a>
|
528 |
<div class="saswp-accordion-panel">
|
529 |
<div class="saswp-dp-dsg">
|
530 |
+
<lable><?php echo saswp_t_string('Design'); ?></lable>
|
531 |
<select name="saswp_collection_design" class="saswp-collection-desing saswp-coll-settings-options">
|
532 |
<?php
|
533 |
foreach($coll_desing as $key => $val){
|
534 |
|
535 |
+
echo '<option value="'.esc_attr($key).'" '.($post_meta['saswp_collection_design'][0] == $key ? 'selected':'').' >'.saswp_t_string( $val ).'</option>';
|
536 |
}
|
537 |
?>
|
538 |
</select>
|
539 |
</div>
|
540 |
<div class="saswp-dp-dsg saswp-coll-options saswp-grid-options saswp-dp-dtm">
|
541 |
+
<label><?php echo saswp_t_string( 'Columns' ); ?></label>
|
542 |
<input type="number" id="saswp-collection-cols" name="saswp_collection_cols" min="1" value="<?php echo (isset($post_meta['saswp_collection_cols'][0]) ? $post_meta['saswp_collection_cols'][0] : '2' ); ?>" class="saswp-number-change saswp-coll-settings-options saswp-coll-options saswp-grid-options">
|
543 |
</div>
|
544 |
|
545 |
<div class="saswp-dp-dsg saswp-coll-options saswp-grid-options saswp-dp-dtm">
|
546 |
+
<span><?php echo saswp_t_string( 'Pagination' ); ?></span>
|
547 |
<span><input name="saswp_collection_pagination" type="checkbox" id="saswp-coll-pagination" class="saswp-coll-settings-options" value="1" <?php echo (isset($post_meta['saswp_collection_pagination'][0]) && $post_meta['saswp_collection_pagination'][0] == 1 ? 'checked' : '' ); ?>></span>
|
548 |
</div>
|
549 |
|
550 |
<div class="saswp-dp-dsg saswp-coll-options saswp-grid-options saswp-dp-dtm saswp_hide_imp">
|
551 |
+
<label><?php echo saswp_t_string( 'Per Page' ); ?></label>
|
552 |
<input name="saswp_collection_per_page" type="number" min="1" id="saswp-coll-per-page" class="saswp-coll-settings-options" value="<?php echo (isset($post_meta['saswp_collection_per_page'][0]) ? $post_meta['saswp_collection_per_page'][0] : '10' ); ?>">
|
553 |
</div>
|
554 |
|
555 |
<div class="saswp-dp-dsg saswp-dp-dtm saswp-slider-options saswp-coll-options">
|
556 |
+
<label><?php echo saswp_t_string( 'Slider Type' ); ?></label>
|
557 |
<select name="saswp_collection_gallery_type" id="saswp_collection_gallery_type" class="saswp-slider-type saswp-slider-options saswp_hide saswp-coll-settings-options saswp-coll-options">
|
558 |
+
<option value="slider" <?php echo (isset($post_meta['saswp_collection_gallery_type'][0]) && $post_meta['saswp_collection_gallery_type'][0] == 'slider' ? 'selected' : '' ); ?>><?php echo saswp_t_string( 'Slider' ); ?></option>
|
559 |
+
<option value="carousel" <?php echo (isset($post_meta['saswp_collection_gallery_type'][0]) && $post_meta['saswp_collection_gallery_type'][0] == 'carousel' ? 'selected' : '' ); ?>><?php echo saswp_t_string( 'Carousel' ); ?></option>
|
560 |
</select>
|
561 |
</div>
|
562 |
<div class="saswp-slider-display saswp-slider-options saswp_hide saswp-coll-settings-options saswp-coll-options">
|
563 |
+
<span><input type="checkbox" id="saswp_gallery_arrow" name="saswp_gallery_arrow" value="1" <?php echo (isset($post_meta['saswp_gallery_arrow'][0]) && $post_meta['saswp_gallery_arrow'][0] == 1 ? 'checked' : '' ); ?>> <?php echo saswp_t_string('Arrows'); ?></span>
|
564 |
+
<span><input type="checkbox" id="saswp_gallery_dots" name="saswp_gallery_dots" value="1" <?php echo (isset($post_meta['saswp_gallery_dots'][0]) && $post_meta['saswp_gallery_dots'][0] == 1 ? 'checked' : '' ); ?>> <?php echo saswp_t_string('Dots'); ?></span>
|
565 |
</div>
|
566 |
|
567 |
<div class="saswp-fomo-options saswp_hide saswp-coll-options">
|
568 |
<div class="saswp-dp-dsg saswp-dp-dtm">
|
569 |
+
<span><?php echo saswp_t_string('Delay Time In Sec'); ?>
|
570 |
</span>
|
571 |
<input type="number" id="saswp_fomo_interval" name="saswp_fomo_interval" class="saswp-number-change" min="1" value="<?php echo (isset($post_meta['saswp_fomo_interval'][0]) ? $post_meta['saswp_fomo_interval'][0] : '3' ); ?>">
|
572 |
</div>
|
575 |
</li>
|
576 |
<li>
|
577 |
|
578 |
+
<a class="saswp-accordion"><?php echo saswp_t_string('Filter'); ?></a>
|
579 |
<div class="saswp-accordion-panel">
|
580 |
<div class="saswp-dp-dsg">
|
581 |
+
<lable><?php echo saswp_t_string('Sorting'); ?></lable>
|
582 |
<select name="saswp_collection_sorting" class="saswp-collection-sorting saswp-coll-settings-options">
|
583 |
<?php
|
584 |
foreach($coll_sorting as $key => $val){
|
585 |
+
echo '<option value="'.esc_attr($key).'" '.($post_meta['saswp_collection_sorting'][0] == $key ? 'selected':'').' >'.saswp_t_string( $val ).'</option>';
|
586 |
|
587 |
}
|
588 |
|
592 |
</div>
|
593 |
</li>
|
594 |
<li>
|
595 |
+
<a class="saswp-accordion"><?php echo saswp_t_string('Display'); ?></a>
|
596 |
<div class="saswp-accordion-panel">
|
597 |
<div class="saswp-dp-dsg">
|
598 |
+
<label><?php echo saswp_t_string( 'Display Type' ); ?></label>
|
599 |
<select class="saswp-collection-display-method" name="saswp_collection_display_type">
|
600 |
<?php
|
601 |
foreach($coll_display_type as $key => $val){
|
602 |
|
603 |
+
echo '<option value="'.esc_attr($key).'" '.($post_meta['saswp_collection_display_type'][0] == $key ? 'selected':'').' >'.saswp_t_string( $val ).'</option>';
|
604 |
}
|
605 |
?>
|
606 |
</select>
|
617 |
</ul>
|
618 |
<div class="saswp-sv-btn">
|
619 |
<button type="submit" class="button button-primary" >
|
620 |
+
<?php echo saswp_t_string('Save Menu'); ?>
|
621 |
</button>
|
622 |
</div>
|
623 |
</div><!-- /.saswp-collection-body -->
|
modules/reviews/reviews_form.php
CHANGED
@@ -216,7 +216,7 @@ class SASWP_Reviews_Form {
|
|
216 |
if(!$is_amp){
|
217 |
|
218 |
if($on_button){
|
219 |
-
$form .= '<div class="saswp-rv-form-btn"><a href="#" class="button button-default">'.saswp_label_text('translation-review-form').'</a></div>';
|
220 |
}
|
221 |
|
222 |
$rating_html = '<div class="saswp-rating-container"><div class="saswp-rating-front-div"></div><div class="saswp-rateyo-counter"></div><input type="hidden" name="saswp_review_rating" value="5"></div>';
|
@@ -227,7 +227,7 @@ class SASWP_Reviews_Form {
|
|
227 |
add_action( 'amp_post_template_data', array($this, 'saswp_reviews_form_amp_script'));
|
228 |
|
229 |
if($on_button){
|
230 |
-
$form .= '<div class="saswp-rv-form-btn"><a href="#" class="button button-default" on="tap:AMP.setState({ saswp_review_form_toggle: !saswp_review_form_toggle })" role="button" tabindex="1">'.saswp_label_text('translation-review-form').'</a></div>';
|
231 |
}
|
232 |
|
233 |
$form .= '<form action-xhr="'.esc_url( admin_url('admin-post.php') ).'" method="post" class="saswp-review-submission-form '.($on_button ? "saswp_hide" : "").'" [class]="saswp_review_form_toggle ? \'saswp-review-submission-form\' : \'saswp_hide saswp-review-submission-form\' ">';
|
@@ -249,12 +249,12 @@ class SASWP_Reviews_Form {
|
|
249 |
. '<div class="saswp-form-tbl">'
|
250 |
|
251 |
. '<div class="saswp-form-fld">'
|
252 |
-
. '<span>'.saswp_label_text('translation-name').'</span>'
|
253 |
. '<input type="text" name="saswp_reviewer_name" required>'
|
254 |
. '</div>'
|
255 |
|
256 |
. '<div class="saswp-form-fld">'
|
257 |
-
. '<span>'.saswp_label_text('translation-comment').'</span>'
|
258 |
. '<textarea name="saswp_review_text"></textarea>'
|
259 |
. '</div>'
|
260 |
|
216 |
if(!$is_amp){
|
217 |
|
218 |
if($on_button){
|
219 |
+
$form .= '<div class="saswp-rv-form-btn"><a href="#" class="button button-default">'.saswp_t_string(saswp_label_text('translation-review-form')).'</a></div>';
|
220 |
}
|
221 |
|
222 |
$rating_html = '<div class="saswp-rating-container"><div class="saswp-rating-front-div"></div><div class="saswp-rateyo-counter"></div><input type="hidden" name="saswp_review_rating" value="5"></div>';
|
227 |
add_action( 'amp_post_template_data', array($this, 'saswp_reviews_form_amp_script'));
|
228 |
|
229 |
if($on_button){
|
230 |
+
$form .= '<div class="saswp-rv-form-btn"><a href="#" class="button button-default" on="tap:AMP.setState({ saswp_review_form_toggle: !saswp_review_form_toggle })" role="button" tabindex="1">'.saswp_t_string(saswp_label_text('translation-review-form')).'</a></div>';
|
231 |
}
|
232 |
|
233 |
$form .= '<form action-xhr="'.esc_url( admin_url('admin-post.php') ).'" method="post" class="saswp-review-submission-form '.($on_button ? "saswp_hide" : "").'" [class]="saswp_review_form_toggle ? \'saswp-review-submission-form\' : \'saswp_hide saswp-review-submission-form\' ">';
|
249 |
. '<div class="saswp-form-tbl">'
|
250 |
|
251 |
. '<div class="saswp-form-fld">'
|
252 |
+
. '<span>'.saswp_t_string(saswp_label_text('translation-name')).'</span>'
|
253 |
. '<input type="text" name="saswp_reviewer_name" required>'
|
254 |
. '</div>'
|
255 |
|
256 |
. '<div class="saswp-form-fld">'
|
257 |
+
. '<span>'.saswp_t_string(saswp_label_text('translation-comment')).'</span>'
|
258 |
. '<textarea name="saswp_review_text"></textarea>'
|
259 |
. '</div>'
|
260 |
|
modules/reviews/reviews_service.php
CHANGED
@@ -331,24 +331,24 @@ class saswp_reviews_service {
|
|
331 |
|
332 |
$rv_limits = get_option('reviews_addon_reviews_limits');
|
333 |
|
334 |
-
$result['message'] =
|
335 |
|
336 |
update_option('reviews_addon_reviews_limits', intval($result['message']));
|
337 |
}
|
338 |
|
339 |
}else{
|
340 |
$result['status'] = false;
|
341 |
-
$result['message'] =
|
342 |
}
|
343 |
|
344 |
}else{
|
345 |
$result['status'] = false;
|
346 |
-
$result['message'] =
|
347 |
}
|
348 |
|
349 |
}else{
|
350 |
$result['status'] = false;
|
351 |
-
$result['message'] =
|
352 |
}
|
353 |
|
354 |
|
@@ -375,7 +375,7 @@ class saswp_reviews_service {
|
|
375 |
|
376 |
}else{
|
377 |
|
378 |
-
echo json_encode(array('status' => false, 'message' =>
|
379 |
|
380 |
}
|
381 |
|
@@ -523,16 +523,16 @@ class saswp_reviews_service {
|
|
523 |
$response = $this->saswp_save_free_reviews_data($result['result'], $place_id);
|
524 |
|
525 |
if($response){
|
526 |
-
return array('status' => true, 'message' =>
|
527 |
}else{
|
528 |
-
return array('status' => false, 'message' =>
|
529 |
}
|
530 |
|
531 |
}else{
|
532 |
if($result['error_message']){
|
533 |
return array('status' => false, 'message' => $result['error_message']);
|
534 |
}else{
|
535 |
-
return array('status' => false, 'message' =>
|
536 |
}
|
537 |
}
|
538 |
|
@@ -1053,7 +1053,7 @@ class saswp_reviews_service {
|
|
1053 |
$platform_name = $value['saswp_review_platform_name'];
|
1054 |
|
1055 |
if($platform_name == 'Self'){
|
1056 |
-
$platform_name = saswp_label_text('translation-self');
|
1057 |
}
|
1058 |
|
1059 |
$platform_icon = $value['saswp_review_platform_icon'];
|
@@ -1086,7 +1086,7 @@ class saswp_reviews_service {
|
|
1086 |
$html .= '</span>';
|
1087 |
$html .= '</div>';
|
1088 |
$html .= '<span class="saswp-r3-brv">';
|
1089 |
-
$html .= saswp_label_text('translation-based-on').' '.esc_attr($review_count).' '.saswp_label_text('translation-reviews');
|
1090 |
$html .= '</span>';
|
1091 |
$html .= '</div>';
|
1092 |
$html .= '</a>';
|
@@ -1114,7 +1114,7 @@ class saswp_reviews_service {
|
|
1114 |
|
1115 |
$platform_name = $value['saswp_review_platform_name'];
|
1116 |
if($platform_name == 'Self'){
|
1117 |
-
$platform_name = saswp_label_text('translation-self');
|
1118 |
}
|
1119 |
$platform_icon = $value['saswp_review_platform_icon'];
|
1120 |
$sum_of_rating += $value['saswp_review_rating'];
|
@@ -1146,7 +1146,7 @@ class saswp_reviews_service {
|
|
1146 |
$html .= '</span>';
|
1147 |
$html .= '</div>';
|
1148 |
$html .= '<span class="saswp-r3-brv">';
|
1149 |
-
$html .= saswp_label_text('translation-based-on').' '.esc_attr($review_count).' '.saswp_label_text('translation-reviews');
|
1150 |
$html .= '</span>';
|
1151 |
$html .= '</div>';
|
1152 |
$html .= '</a>';
|
@@ -1217,11 +1217,11 @@ class saswp_reviews_service {
|
|
1217 |
$html .= '<span>';
|
1218 |
$html .= saswp_get_rating_html_by_value($average_rating);
|
1219 |
$html .= '</span>';
|
1220 |
-
$html .= '<span class="saswp-r4-rnm">'.esc_attr(number_format ($average_rating, 1)).' from '.esc_attr($review_count).' '.
|
1221 |
$html .= '</div>';
|
1222 |
|
1223 |
$html .= '<div class="saswp-onclick-show">';
|
1224 |
-
$html .= '<span>'.
|
1225 |
$html .= '<span class="saswp-mines"></span>';
|
1226 |
$html .= '</div>';
|
1227 |
|
@@ -1234,7 +1234,7 @@ class saswp_reviews_service {
|
|
1234 |
$html .= '<span>';
|
1235 |
$html .= saswp_get_rating_html_by_value($average_rating);
|
1236 |
$html .= '</span>';
|
1237 |
-
$html .= '<span class="saswp-r4-rnm">'. esc_attr(number_format ($average_rating, 1)).' from '. esc_attr($review_count).' '.
|
1238 |
$html .= '</li>';
|
1239 |
$html .= $html_list;
|
1240 |
$html .= '</ul>';
|
@@ -1253,10 +1253,10 @@ class saswp_reviews_service {
|
|
1253 |
$html .= '<span>';
|
1254 |
$html .= saswp_get_rating_html_by_value($average_rating);
|
1255 |
$html .= '</span>';
|
1256 |
-
$html .= '<span class="saswp-r4-rnm">'.esc_attr(number_format($average_rating, 1) ).' from '.esc_attr($review_count).' '.
|
1257 |
$html .= '</div>';
|
1258 |
$html .= '<div class="saswp-onclick-show">';
|
1259 |
-
$html .= '<span>'.
|
1260 |
$html .= '<span class="saswp-mines"></span>';
|
1261 |
$html .= '</div>';
|
1262 |
$html .= '</div>';
|
331 |
|
332 |
$rv_limits = get_option('reviews_addon_reviews_limits');
|
333 |
|
334 |
+
$result['message'] = saswp_t_string('Reviews fetched').' : '. ($rv_limits - $result['message'] ). ', '.saswp_t_string('Remains Limit').' : '.$result['message'];
|
335 |
|
336 |
update_option('reviews_addon_reviews_limits', intval($result['message']));
|
337 |
}
|
338 |
|
339 |
}else{
|
340 |
$result['status'] = false;
|
341 |
+
$result['message'] = saswp_t_string( 'Reviews for schema plugin is not activated' );
|
342 |
}
|
343 |
|
344 |
}else{
|
345 |
$result['status'] = false;
|
346 |
+
$result['message'] = saswp_t_string( 'User is not register' );
|
347 |
}
|
348 |
|
349 |
}else{
|
350 |
$result['status'] = false;
|
351 |
+
$result['message'] = saswp_t_string( 'License key is not active' );
|
352 |
}
|
353 |
|
354 |
|
375 |
|
376 |
}else{
|
377 |
|
378 |
+
echo json_encode(array('status' => false, 'message' => saswp_t_string( 'Place id is empty' )));
|
379 |
|
380 |
}
|
381 |
|
523 |
$response = $this->saswp_save_free_reviews_data($result['result'], $place_id);
|
524 |
|
525 |
if($response){
|
526 |
+
return array('status' => true, 'message' => saswp_t_string( 'Fetched Successfully' ));
|
527 |
}else{
|
528 |
+
return array('status' => false, 'message' => saswp_t_string( 'Not fetched' ));
|
529 |
}
|
530 |
|
531 |
}else{
|
532 |
if($result['error_message']){
|
533 |
return array('status' => false, 'message' => $result['error_message']);
|
534 |
}else{
|
535 |
+
return array('status' => false, 'message' => saswp_t_string( 'Something went wrong' ));
|
536 |
}
|
537 |
}
|
538 |
|
1053 |
$platform_name = $value['saswp_review_platform_name'];
|
1054 |
|
1055 |
if($platform_name == 'Self'){
|
1056 |
+
$platform_name = saswp_t_string(saswp_label_text('translation-self'));
|
1057 |
}
|
1058 |
|
1059 |
$platform_icon = $value['saswp_review_platform_icon'];
|
1086 |
$html .= '</span>';
|
1087 |
$html .= '</div>';
|
1088 |
$html .= '<span class="saswp-r3-brv">';
|
1089 |
+
$html .= saswp_t_string(saswp_label_text('translation-based-on')).' '.esc_attr($review_count).' '.saswp_t_string(saswp_label_text('translation-reviews'));
|
1090 |
$html .= '</span>';
|
1091 |
$html .= '</div>';
|
1092 |
$html .= '</a>';
|
1114 |
|
1115 |
$platform_name = $value['saswp_review_platform_name'];
|
1116 |
if($platform_name == 'Self'){
|
1117 |
+
$platform_name = saswp_t_string(saswp_label_text('translation-self'));
|
1118 |
}
|
1119 |
$platform_icon = $value['saswp_review_platform_icon'];
|
1120 |
$sum_of_rating += $value['saswp_review_rating'];
|
1146 |
$html .= '</span>';
|
1147 |
$html .= '</div>';
|
1148 |
$html .= '<span class="saswp-r3-brv">';
|
1149 |
+
$html .= saswp_t_string(saswp_label_text('translation-based-on')).' '.esc_attr($review_count).' '.saswp_t_string(saswp_label_text('translation-reviews'));
|
1150 |
$html .= '</span>';
|
1151 |
$html .= '</div>';
|
1152 |
$html .= '</a>';
|
1217 |
$html .= '<span>';
|
1218 |
$html .= saswp_get_rating_html_by_value($average_rating);
|
1219 |
$html .= '</span>';
|
1220 |
+
$html .= '<span class="saswp-r4-rnm">'.esc_attr(number_format ($average_rating, 1)).' from '.esc_attr($review_count).' '.saswp_t_string('reviews').'</span>';
|
1221 |
$html .= '</div>';
|
1222 |
|
1223 |
$html .= '<div class="saswp-onclick-show">';
|
1224 |
+
$html .= '<span>'.saswp_t_string('Ratings and reviews').'</span>';
|
1225 |
$html .= '<span class="saswp-mines"></span>';
|
1226 |
$html .= '</div>';
|
1227 |
|
1234 |
$html .= '<span>';
|
1235 |
$html .= saswp_get_rating_html_by_value($average_rating);
|
1236 |
$html .= '</span>';
|
1237 |
+
$html .= '<span class="saswp-r4-rnm">'. esc_attr(number_format ($average_rating, 1)).' from '. esc_attr($review_count).' '.saswp_t_string('reviews').'</span>';
|
1238 |
$html .= '</li>';
|
1239 |
$html .= $html_list;
|
1240 |
$html .= '</ul>';
|
1253 |
$html .= '<span>';
|
1254 |
$html .= saswp_get_rating_html_by_value($average_rating);
|
1255 |
$html .= '</span>';
|
1256 |
+
$html .= '<span class="saswp-r4-rnm">'.esc_attr(number_format($average_rating, 1) ).' from '.esc_attr($review_count).' '.saswp_t_string('reviews').'</span>';
|
1257 |
$html .= '</div>';
|
1258 |
$html .= '<div class="saswp-onclick-show">';
|
1259 |
+
$html .= '<span>'.saswp_t_string('Ratings and reviews').'</span>';
|
1260 |
$html .= '<span class="saswp-mines"></span>';
|
1261 |
$html .= '</div>';
|
1262 |
$html .= '</div>';
|
modules/reviews/reviews_setup.php
CHANGED
@@ -28,20 +28,20 @@ function saswp_register_saswp_reviews_location() {
|
|
28 |
|
29 |
$post_type = array(
|
30 |
'labels' => array(
|
31 |
-
'name'
|
32 |
-
'add_new'
|
33 |
-
'add_new_item'
|
34 |
-
|
35 |
),
|
36 |
-
'public'
|
37 |
-
'has_archive'
|
38 |
'exclude_from_search' => true,
|
39 |
'publicly_queryable' => false,
|
40 |
-
// 'show_in_menu'
|
41 |
'show_ui' => false,
|
42 |
-
|
43 |
'show_admin_column' => true,
|
44 |
-
|
45 |
);
|
46 |
|
47 |
if(saswp_current_user_allowed()){
|
@@ -66,10 +66,10 @@ function saswp_register_saswp_reviews() {
|
|
66 |
|
67 |
$post_type = array(
|
68 |
'labels' => array(
|
69 |
-
'name' =>
|
70 |
-
'add_new' =>
|
71 |
-
'add_new_item' =>
|
72 |
-
'edit_item' =>
|
73 |
),
|
74 |
'public' => true,
|
75 |
'has_archive' => false,
|
@@ -112,7 +112,7 @@ function saswp_collection_custom_columns($columns) {
|
|
112 |
|
113 |
unset($columns['date']);
|
114 |
|
115 |
-
$columns['saswp_collection_shortcode'] = '<a>'.
|
116 |
|
117 |
return $columns;
|
118 |
|
@@ -196,13 +196,13 @@ function saswp_reviews_custom_columns($columns) {
|
|
196 |
unset($columns);
|
197 |
|
198 |
$columns['cb'] = '<input type="checkbox" />';
|
199 |
-
$columns['saswp_reviewer_image'] = '<a>'.
|
200 |
-
$columns['title'] =
|
201 |
-
$columns['saswp_review_rating'] = '<a>'.
|
202 |
-
$columns['saswp_review_platform'] = '<a>'.
|
203 |
-
$columns['saswp_review_date'] = '<a>'.
|
204 |
-
$columns['saswp_review_place_id'] = '<a>'.
|
205 |
-
$columns['saswp_review_shortcode'] = '<a>'.
|
206 |
|
207 |
return $columns;
|
208 |
}
|
@@ -321,104 +321,123 @@ function saswp_create_platform_custom_taxonomy() {
|
|
321 |
}
|
322 |
|
323 |
function saswp_insert_platform_terms(){
|
|
|
|
|
|
|
|
|
324 |
|
325 |
-
$
|
326 |
-
|
327 |
-
|
328 |
-
|
329 |
-
|
330 |
-
|
331 |
-
|
332 |
-
|
333 |
-
|
334 |
-
|
335 |
-
|
336 |
-
|
337 |
-
|
338 |
-
|
339 |
-
|
340 |
-
|
341 |
-
|
342 |
-
|
343 |
-
|
344 |
-
|
345 |
-
|
346 |
-
|
347 |
-
|
348 |
-
|
349 |
-
|
350 |
-
|
351 |
-
|
352 |
-
|
353 |
-
|
354 |
-
|
355 |
-
|
356 |
-
|
357 |
-
|
358 |
-
|
359 |
-
|
360 |
-
|
361 |
-
|
362 |
-
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
|
376 |
-
|
377 |
-
|
378 |
-
|
379 |
-
|
380 |
-
|
381 |
-
|
382 |
-
|
383 |
-
|
384 |
-
|
385 |
-
|
386 |
-
|
387 |
-
|
388 |
-
|
389 |
-
|
390 |
-
|
391 |
-
|
392 |
-
|
393 |
-
|
394 |
-
|
395 |
-
|
396 |
-
|
397 |
-
|
398 |
-
|
399 |
-
|
400 |
-
|
401 |
-
|
402 |
-
|
403 |
-
|
404 |
-
|
405 |
-
|
406 |
-
|
407 |
-
|
408 |
-
|
409 |
-
|
410 |
-
|
411 |
-
|
412 |
-
|
413 |
-
|
414 |
-
|
415 |
-
|
416 |
-
|
417 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
418 |
|
419 |
-
}
|
420 |
-
|
421 |
-
}
|
422 |
}
|
423 |
|
424 |
function saswp_get_terms_as_array(){
|
@@ -454,7 +473,7 @@ function saswp_reviews_filter() {
|
|
454 |
$current_plugin = esc_attr($_GET['slug']); // Check if option has been selected
|
455 |
} ?>
|
456 |
<select name="slug" id="slug">
|
457 |
-
<option value="all" <?php selected( 'all', $current_plugin ); ?>><?php esc_html_e( 'All'
|
458 |
<?php foreach( $plugins as $key=>$value ) { ?>
|
459 |
<option value="<?php echo esc_attr( $key ); ?>" <?php selected( $key, $current_plugin ); ?>><?php echo esc_attr( $value ); ?></option>
|
460 |
<?php } ?>
|
28 |
|
29 |
$post_type = array(
|
30 |
'labels' => array(
|
31 |
+
'name' => saswp_t_string( 'Location' ),
|
32 |
+
'add_new' => saswp_t_string( 'Add Location' ),
|
33 |
+
'add_new_item' => saswp_t_string( 'Edit Location' ),
|
34 |
+
'edit_item' => saswp_t_string( 'Edit Location'),
|
35 |
),
|
36 |
+
'public' => false,
|
37 |
+
'has_archive' => false,
|
38 |
'exclude_from_search' => true,
|
39 |
'publicly_queryable' => false,
|
40 |
+
// 'show_in_menu' => 'edit.php?post_type=saswp',
|
41 |
'show_ui' => false,
|
42 |
+
'show_in_nav_menus' => false,
|
43 |
'show_admin_column' => true,
|
44 |
+
'rewrite' => false,
|
45 |
);
|
46 |
|
47 |
if(saswp_current_user_allowed()){
|
66 |
|
67 |
$post_type = array(
|
68 |
'labels' => array(
|
69 |
+
'name' => saswp_t_string( 'Reviews' ),
|
70 |
+
'add_new' => saswp_t_string( 'Add Review' ),
|
71 |
+
'add_new_item' => saswp_t_string( 'Edit Review' ),
|
72 |
+
'edit_item' => saswp_t_string( 'Edit Review'),
|
73 |
),
|
74 |
'public' => true,
|
75 |
'has_archive' => false,
|
112 |
|
113 |
unset($columns['date']);
|
114 |
|
115 |
+
$columns['saswp_collection_shortcode'] = '<a>'.saswp_t_string( 'Shortcode' ).'<a>';
|
116 |
|
117 |
return $columns;
|
118 |
|
196 |
unset($columns);
|
197 |
|
198 |
$columns['cb'] = '<input type="checkbox" />';
|
199 |
+
$columns['saswp_reviewer_image'] = '<a>'.saswp_t_string( 'Image' ).'<a>';
|
200 |
+
$columns['title'] = saswp_t_string( 'Title' );
|
201 |
+
$columns['saswp_review_rating'] = '<a>'.saswp_t_string( 'Rating' ).'<a>';
|
202 |
+
$columns['saswp_review_platform'] = '<a>'.saswp_t_string( 'Platform' ).'<a>';
|
203 |
+
$columns['saswp_review_date'] = '<a>'.saswp_t_string( 'Review Date' ).'<a>';
|
204 |
+
$columns['saswp_review_place_id'] = '<a>'.saswp_t_string( 'Place ID/Reviewed To' ).'<a>';
|
205 |
+
$columns['saswp_review_shortcode'] = '<a>'.saswp_t_string( 'Shortcode' ).'<a>';
|
206 |
|
207 |
return $columns;
|
208 |
}
|
321 |
}
|
322 |
|
323 |
function saswp_insert_platform_terms(){
|
324 |
+
|
325 |
+
$term_ids = array();
|
326 |
+
|
327 |
+
$platform_inserted = get_transient('saswp_platform_inserted');
|
328 |
|
329 |
+
if($platform_inserted != 79){
|
330 |
+
|
331 |
+
$term_array = array(
|
332 |
+
'Self',
|
333 |
+
'Agoda',
|
334 |
+
'Avvo',
|
335 |
+
'Angies List',
|
336 |
+
'Apple AppStore',
|
337 |
+
'Expedia',
|
338 |
+
'Facebook',
|
339 |
+
'Google',
|
340 |
+
'TripAdvisor',
|
341 |
+
'Yelp',
|
342 |
+
'Zillow',
|
343 |
+
'Zomato',
|
344 |
+
'Airbnb',
|
345 |
+
'AliExpress',
|
346 |
+
'AlternativeTo',
|
347 |
+
'Amazon',
|
348 |
+
'BBB',
|
349 |
+
'BestBuy',
|
350 |
+
'Booking.com',
|
351 |
+
'Capterra',
|
352 |
+
'CarGurus',
|
353 |
+
'Cars.com',
|
354 |
+
'Citysearch',
|
355 |
+
'Classpass',
|
356 |
+
'Consumer Affairs',
|
357 |
+
'Clutch',
|
358 |
+
'CreditKarma',
|
359 |
+
'CustomerLobby',
|
360 |
+
'DealerRater',
|
361 |
+
'Ebay',
|
362 |
+
'Edmunds',
|
363 |
+
'Etsy',
|
364 |
+
'Foursquare',
|
365 |
+
'Flipkart',
|
366 |
+
'G2Crowd',
|
367 |
+
'Gearbest',
|
368 |
+
'Gartner',
|
369 |
+
'Glassdoor',
|
370 |
+
'Healthgrades',
|
371 |
+
'HomeAdvisor',
|
372 |
+
'Homestars',
|
373 |
+
'Houzz',
|
374 |
+
'Hotels.com',
|
375 |
+
'HungerStation',
|
376 |
+
'Indeed',
|
377 |
+
'IMDB',
|
378 |
+
'Insider Pages',
|
379 |
+
'Jet',
|
380 |
+
'Judge.me',
|
381 |
+
'Lawyers.com',
|
382 |
+
'Lending Tree',
|
383 |
+
'Martindale',
|
384 |
+
'Newegg',
|
385 |
+
'OpenRice',
|
386 |
+
'Opentable',
|
387 |
+
'ProductHunt',
|
388 |
+
'Playstore',
|
389 |
+
'RateMDs',
|
390 |
+
'ReserveOut',
|
391 |
+
'Rotten Tomatoes',
|
392 |
+
'Sitejabber',
|
393 |
+
'Siftery',
|
394 |
+
'Steam',
|
395 |
+
'SoftwareAdvice',
|
396 |
+
'Shopper Approved',
|
397 |
+
'Talabat',
|
398 |
+
'The Knot',
|
399 |
+
'Thumbtack',
|
400 |
+
'Trulia',
|
401 |
+
'TrustedShops',
|
402 |
+
'Trustpilot',
|
403 |
+
'TrustRadius',
|
404 |
+
'Vitals',
|
405 |
+
'Walmart',
|
406 |
+
'WeddingWire',
|
407 |
+
'Wish',
|
408 |
+
'Yell',
|
409 |
+
'YellowPages',
|
410 |
+
'ZocDoc'
|
411 |
+
);
|
412 |
+
|
413 |
+
foreach($term_array as $term){
|
414 |
+
|
415 |
+
$term_id = term_exists( $term, 'platform' );
|
416 |
+
|
417 |
+
if(!$term_id){
|
418 |
+
|
419 |
+
$result = wp_insert_term( $term, 'platform', array('slug' => $term) );
|
420 |
+
|
421 |
+
if(!is_wp_error($result)){
|
422 |
+
$term_ids[] = $result;
|
423 |
+
}
|
424 |
+
|
425 |
+
}else{
|
426 |
+
|
427 |
+
if(isset($term_id['term_id'])){
|
428 |
+
$term_ids[] = $term_id['term_id'];
|
429 |
+
}
|
430 |
+
|
431 |
+
}
|
432 |
+
|
433 |
+
}
|
434 |
+
|
435 |
+
if(count($term_ids) == 79){
|
436 |
+
set_transient('saswp_platform_inserted', 79, 24*7*HOUR_IN_SECONDS );
|
437 |
+
}
|
438 |
+
|
439 |
+
}
|
440 |
|
|
|
|
|
|
|
441 |
}
|
442 |
|
443 |
function saswp_get_terms_as_array(){
|
473 |
$current_plugin = esc_attr($_GET['slug']); // Check if option has been selected
|
474 |
} ?>
|
475 |
<select name="slug" id="slug">
|
476 |
+
<option value="all" <?php selected( 'all', $current_plugin ); ?>><?php esc_html_e( 'All' ); ?></option>
|
477 |
<?php foreach( $plugins as $key=>$value ) { ?>
|
478 |
<option value="<?php echo esc_attr( $key ); ?>" <?php selected( $key, $current_plugin ); ?>><?php echo esc_attr( $value ); ?></option>
|
479 |
<?php } ?>
|
modules/reviews/reviews_widget.php
CHANGED
@@ -33,8 +33,8 @@ class Saswp_Reviews_Widget extends WP_Widget {
|
|
33 |
|
34 |
parent::__construct(
|
35 |
'saswp_google_review_widget', // Base ID
|
36 |
-
|
37 |
-
array( 'description' =>
|
38 |
);
|
39 |
}
|
40 |
|
@@ -80,11 +80,11 @@ class Saswp_Reviews_Widget extends WP_Widget {
|
|
80 |
public function form( $instance ) {
|
81 |
|
82 |
|
83 |
-
$title = ! empty( $instance['title'] ) ? $instance['title'] :
|
84 |
-
$ads = ! empty( $instance['g_review'] ) ? $instance['g_review'] :
|
85 |
<p>
|
86 |
<label for="<?php echo esc_attr( $this->get_field_id( 'g_review' ) ); ?>">
|
87 |
-
<?php esc_attr_e( 'Reviews :'
|
88 |
</label>
|
89 |
<input id="<?php echo esc_attr( $this->get_field_id( 'g_review' )); ?>" name="<?php echo esc_attr( $this->get_field_name( 'g_review' ) ); ?>" type="text" placeholder="review count" value="<?php echo (isset($instance['g_review']) ? $instance['g_review'] : 5); ?>">
|
90 |
</p>
|
33 |
|
34 |
parent::__construct(
|
35 |
'saswp_google_review_widget', // Base ID
|
36 |
+
saswp_t_string( 'Reviews' ), // Name
|
37 |
+
array( 'description' => saswp_t_string( 'Widget to display Reviews' ), ) // Args
|
38 |
);
|
39 |
}
|
40 |
|
80 |
public function form( $instance ) {
|
81 |
|
82 |
|
83 |
+
$title = ! empty( $instance['title'] ) ? $instance['title'] : saswp_t_string( 'Review Title' );
|
84 |
+
$ads = ! empty( $instance['g_review'] ) ? $instance['g_review'] : saswp_t_string( 'review list to be display' );?>
|
85 |
<p>
|
86 |
<label for="<?php echo esc_attr( $this->get_field_id( 'g_review' ) ); ?>">
|
87 |
+
<?php esc_attr_e( 'Reviews :' ); ?>
|
88 |
</label>
|
89 |
<input id="<?php echo esc_attr( $this->get_field_id( 'g_review' )); ?>" name="<?php echo esc_attr( $this->get_field_name( 'g_review' ) ); ?>" type="text" placeholder="review count" value="<?php echo (isset($instance['g_review']) ? $instance['g_review'] : 5); ?>">
|
90 |
</p>
|
output/compatibility.php
CHANGED
@@ -435,6 +435,9 @@ class saswp_output_compatibility{
|
|
435 |
public function yoast_seo_on_activation(){
|
436 |
$this->saswp_update_option_on_compatibility_activation('saswp-yoast');
|
437 |
}
|
|
|
|
|
|
|
438 |
public function slimseo_on_activation(){
|
439 |
$this->saswp_update_option_on_compatibility_activation('saswp-slimseo');
|
440 |
}
|
@@ -603,6 +606,9 @@ class saswp_output_compatibility{
|
|
603 |
public function helpiefaq_on_activation(){
|
604 |
$this->saswp_update_option_on_compatibility_activation('saswp-helpiefaq');
|
605 |
}
|
|
|
|
|
|
|
606 |
public function total_recipe_generator_on_activation(){
|
607 |
$this->saswp_update_option_on_compatibility_activation('saswp-total-recipe-generator');
|
608 |
}
|
435 |
public function yoast_seo_on_activation(){
|
436 |
$this->saswp_update_option_on_compatibility_activation('saswp-yoast');
|
437 |
}
|
438 |
+
public function metatagmanager_on_activation(){
|
439 |
+
$this->saswp_update_option_on_compatibility_activation('metatagmanager');
|
440 |
+
}
|
441 |
public function slimseo_on_activation(){
|
442 |
$this->saswp_update_option_on_compatibility_activation('saswp-slimseo');
|
443 |
}
|
606 |
public function helpiefaq_on_activation(){
|
607 |
$this->saswp_update_option_on_compatibility_activation('saswp-helpiefaq');
|
608 |
}
|
609 |
+
public function polylang_on_activation(){
|
610 |
+
$this->saswp_update_option_on_compatibility_activation('saswp-polylang');
|
611 |
+
}
|
612 |
public function total_recipe_generator_on_activation(){
|
613 |
$this->saswp_update_option_on_compatibility_activation('saswp-total-recipe-generator');
|
614 |
}
|
output/function.php
CHANGED
@@ -677,7 +677,7 @@ function saswp_paywall_data_for_login($content){
|
|
677 |
|
678 |
$redirect = home_url( $wp->request );
|
679 |
$breakedContent = explode("<!--more-->", $content);
|
680 |
-
$content = $breakedContent[0].'<a href="'.esc_url(wp_login_url( $redirect )) .'">'.
|
681 |
|
682 |
}elseif(strpos($content, '<!--more-->')!==false && is_user_logged_in()){
|
683 |
|
@@ -704,7 +704,7 @@ function saswp_memberpress_form_update($form){
|
|
704 |
},11);
|
705 |
global $wp;
|
706 |
$redirect = home_url( $wp->request );
|
707 |
-
$form = '<a class="amp-mem-login" href="'.esc_url(wp_login_url( $redirect )) .'">'.
|
708 |
}
|
709 |
|
710 |
return $form;
|
@@ -1501,7 +1501,7 @@ function saswp_global_option(){
|
|
1501 |
*/
|
1502 |
function saswp_get_the_tags(){
|
1503 |
|
1504 |
-
global $post;
|
1505 |
$tag_str = '';
|
1506 |
|
1507 |
if(is_object($post)){
|
@@ -1520,6 +1520,25 @@ function saswp_get_the_tags(){
|
|
1520 |
|
1521 |
|
1522 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1523 |
return $tag_str;
|
1524 |
|
1525 |
}
|
@@ -1608,7 +1627,9 @@ function saswp_get_ids_from_content_by_type($type){
|
|
1608 |
* @since version 1.9.3
|
1609 |
*/
|
1610 |
function saswp_wp_recipe_schema_json($recipe){
|
1611 |
-
|
|
|
|
|
1612 |
if ( 'food' === $recipe->type() ) {
|
1613 |
$metadata = WPRM_Metadata::get_food_metadata( $recipe );
|
1614 |
} elseif ( 'howto' === $recipe->type() ) {
|
@@ -1616,39 +1637,27 @@ function saswp_wp_recipe_schema_json($recipe){
|
|
1616 |
} else {
|
1617 |
$metadata = array();
|
1618 |
}
|
1619 |
-
|
1620 |
-
if(isset($metadata['image']) &&
|
1621 |
-
|
1622 |
-
$image_list = array();
|
1623 |
-
|
1624 |
-
foreach($metadata['image'] as $image_url){
|
1625 |
-
|
1626 |
-
$image_size = @getimagesize($image_url);
|
1627 |
-
|
1628 |
-
if($image_size[0] < 1200 && $image_size[1] < 720){
|
1629 |
-
|
1630 |
-
$image_details = @saswp_aq_resize( $image_url, 1200, 720, true, false, true );
|
1631 |
-
|
1632 |
-
if($image_details){
|
1633 |
|
1634 |
-
|
1635 |
-
$image['url'] = esc_url($image_details[0]);
|
1636 |
-
$image['width'] = esc_attr($image_details[1]);
|
1637 |
-
$image['height'] = esc_attr($image_details[2]);
|
1638 |
|
1639 |
-
|
1640 |
-
|
1641 |
-
|
1642 |
-
|
|
|
|
|
|
|
1643 |
|
|
|
|
|
1644 |
}
|
1645 |
|
1646 |
-
if($image_list){
|
1647 |
-
$metadata['image'] = $image_list;
|
1648 |
-
}
|
1649 |
-
|
1650 |
}
|
1651 |
|
|
|
|
|
1652 |
if(isset($metadata['video'])){
|
1653 |
|
1654 |
if(!$metadata['video']['description']){
|
677 |
|
678 |
$redirect = home_url( $wp->request );
|
679 |
$breakedContent = explode("<!--more-->", $content);
|
680 |
+
$content = $breakedContent[0].'<a href="'.esc_url(wp_login_url( $redirect )) .'">'.saswp_t_string( 'Login' ).'</a>';
|
681 |
|
682 |
}elseif(strpos($content, '<!--more-->')!==false && is_user_logged_in()){
|
683 |
|
704 |
},11);
|
705 |
global $wp;
|
706 |
$redirect = home_url( $wp->request );
|
707 |
+
$form = '<a class="amp-mem-login" href="'.esc_url(wp_login_url( $redirect )) .'">'.saswp_t_string( 'Login' ).'</a>';
|
708 |
}
|
709 |
|
710 |
return $form;
|
1501 |
*/
|
1502 |
function saswp_get_the_tags(){
|
1503 |
|
1504 |
+
global $post, $sd_data;
|
1505 |
$tag_str = '';
|
1506 |
|
1507 |
if(is_object($post)){
|
1520 |
|
1521 |
|
1522 |
}
|
1523 |
+
|
1524 |
+
|
1525 |
+
if( isset($sd_data['saswp-metatagmanager']) && $sd_data['saswp-metatagmanager'] == 1 && class_exists('Meta_Tag_Manager') ){
|
1526 |
+
|
1527 |
+
$post_meta = get_post_meta(get_the_ID(), 'mtm_data', true);
|
1528 |
+
|
1529 |
+
if(is_array($post_meta)){
|
1530 |
+
|
1531 |
+
$meta_tag = array_column($post_meta, 'value');
|
1532 |
+
$key = array_search("keywords",$meta_tag);
|
1533 |
+
|
1534 |
+
if(array_key_exists($key, $post_meta)){
|
1535 |
+
$tag_str = $post_meta[$key]['content'];
|
1536 |
+
}
|
1537 |
+
|
1538 |
+
}
|
1539 |
+
|
1540 |
+
}
|
1541 |
+
|
1542 |
return $tag_str;
|
1543 |
|
1544 |
}
|
1627 |
* @since version 1.9.3
|
1628 |
*/
|
1629 |
function saswp_wp_recipe_schema_json($recipe){
|
1630 |
+
|
1631 |
+
global $saswp_featured_image;
|
1632 |
+
|
1633 |
if ( 'food' === $recipe->type() ) {
|
1634 |
$metadata = WPRM_Metadata::get_food_metadata( $recipe );
|
1635 |
} elseif ( 'howto' === $recipe->type() ) {
|
1637 |
} else {
|
1638 |
$metadata = array();
|
1639 |
}
|
1640 |
+
|
1641 |
+
if( isset($metadata['image'][0]) && $metadata['image'][0] != '' ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1642 |
|
1643 |
+
$image_size = @getimagesize($metadata['image'][0]);
|
|
|
|
|
|
|
1644 |
|
1645 |
+
if( !empty($image_size) ) {
|
1646 |
+
|
1647 |
+
$image_arr = array();
|
1648 |
+
|
1649 |
+
$image_arr[0] = $metadata['image'][0];
|
1650 |
+
$image_arr[1] = $image_size[0];
|
1651 |
+
$image_arr[2] = $image_size[1];
|
1652 |
|
1653 |
+
$saswp_featured_image = $image_arr;
|
1654 |
+
|
1655 |
}
|
1656 |
|
|
|
|
|
|
|
|
|
1657 |
}
|
1658 |
|
1659 |
+
unset($metadata['image']);
|
1660 |
+
|
1661 |
if(isset($metadata['video'])){
|
1662 |
|
1663 |
if(!$metadata['video']['description']){
|
output/markup.php
CHANGED
@@ -124,6 +124,8 @@ function saswp_book_schema_markup($schema_id, $schema_post_id, $all_post_meta){
|
|
124 |
|
125 |
$input1['datePublished'] = isset($all_post_meta['saswp_book_date_published_'.$schema_id])?date('Y-m-d\TH:i:s\Z',strtotime($all_post_meta['saswp_book_date_published_'.$schema_id][0])):'';
|
126 |
$input1['isbn'] = saswp_remove_warnings($all_post_meta, 'saswp_book_isbn_'.$schema_id, 'saswp_array');
|
|
|
|
|
127 |
$input1['numberOfPages'] = saswp_remove_warnings($all_post_meta, 'saswp_book_no_of_page_'.$schema_id, 'saswp_array');
|
128 |
$input1['publisher'] = saswp_remove_warnings($all_post_meta, 'saswp_book_publisher_'.$schema_id, 'saswp_array');
|
129 |
|
@@ -3069,6 +3071,8 @@ function saswp_webpage_schema_markup($schema_id, $schema_post_id, $all_post_meta
|
|
3069 |
'headline' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_headline_'.$schema_id, 'saswp_array'),
|
3070 |
'description' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_description_'.$schema_id, 'saswp_array'),
|
3071 |
'keywords' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_keywords_'.$schema_id, 'saswp_array'),
|
|
|
|
|
3072 |
'datePublished' => isset($all_post_meta['saswp_webpage_date_published_'.$schema_id])? saswp_format_date_time($all_post_meta['saswp_webpage_date_published_'.$schema_id][0], get_post_time('h:i:s')) :'',
|
3073 |
'dateModified' => isset($all_post_meta['saswp_webpage_date_modified_'.$schema_id])? saswp_format_date_time($all_post_meta['saswp_webpage_date_modified_'.$schema_id][0], get_the_modified_time('h:i:s')) :'',
|
3074 |
'publisher' => array(
|
124 |
|
125 |
$input1['datePublished'] = isset($all_post_meta['saswp_book_date_published_'.$schema_id])?date('Y-m-d\TH:i:s\Z',strtotime($all_post_meta['saswp_book_date_published_'.$schema_id][0])):'';
|
126 |
$input1['isbn'] = saswp_remove_warnings($all_post_meta, 'saswp_book_isbn_'.$schema_id, 'saswp_array');
|
127 |
+
$input1['inLanguage'] = saswp_remove_warnings($all_post_meta, 'saswp_book_inlanguage_'.$schema_id, 'saswp_array');
|
128 |
+
$input1['bookFormat'] = saswp_remove_warnings($all_post_meta, 'saswp_book_format_'.$schema_id, 'saswp_array');
|
129 |
$input1['numberOfPages'] = saswp_remove_warnings($all_post_meta, 'saswp_book_no_of_page_'.$schema_id, 'saswp_array');
|
130 |
$input1['publisher'] = saswp_remove_warnings($all_post_meta, 'saswp_book_publisher_'.$schema_id, 'saswp_array');
|
131 |
|
3071 |
'headline' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_headline_'.$schema_id, 'saswp_array'),
|
3072 |
'description' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_description_'.$schema_id, 'saswp_array'),
|
3073 |
'keywords' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_keywords_'.$schema_id, 'saswp_array'),
|
3074 |
+
'articleSection' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_section_'.$schema_id, 'saswp_array'),
|
3075 |
+
'articleBody' => saswp_remove_warnings($all_post_meta, 'saswp_webpage_body_'.$schema_id, 'saswp_array'),
|
3076 |
'datePublished' => isset($all_post_meta['saswp_webpage_date_published_'.$schema_id])? saswp_format_date_time($all_post_meta['saswp_webpage_date_published_'.$schema_id][0], get_post_time('h:i:s')) :'',
|
3077 |
'dateModified' => isset($all_post_meta['saswp_webpage_date_modified_'.$schema_id])? saswp_format_date_time($all_post_meta['saswp_webpage_date_modified_'.$schema_id][0], get_the_modified_time('h:i:s')) :'',
|
3078 |
'publisher' => array(
|
output/rest-api/api-service.php
ADDED
@@ -0,0 +1,35 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
// Exit if accessed directly.
|
3 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
4 |
+
|
5 |
+
class SASWP_Output_Rest_Api_Service {
|
6 |
+
|
7 |
+
public function get_schema($post_id) {
|
8 |
+
|
9 |
+
$response = array();
|
10 |
+
|
11 |
+
if( $post_id ){
|
12 |
+
|
13 |
+
$permalink = get_permalink($post_id);
|
14 |
+
|
15 |
+
$result = wp_remote_get($permalink);
|
16 |
+
|
17 |
+
if(isset($result['body'])){
|
18 |
+
|
19 |
+
$regex = '/<script type\=\"application\/ld\+json\" class\=\"saswp\-schema\-markup\-output\"\>(.*?)<\/script>/s';
|
20 |
+
|
21 |
+
preg_match( $regex, $result['body'], $match);
|
22 |
+
|
23 |
+
if(isset($match[1])){
|
24 |
+
$response = json_decode($match[1], true);
|
25 |
+
}
|
26 |
+
|
27 |
+
}
|
28 |
+
|
29 |
+
}
|
30 |
+
|
31 |
+
return $response;
|
32 |
+
|
33 |
+
}
|
34 |
+
|
35 |
+
}
|
output/rest-api/api.php
ADDED
@@ -0,0 +1,69 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
// Exit if accessed directly.
|
3 |
+
if ( ! defined( 'ABSPATH' ) ) exit;
|
4 |
+
|
5 |
+
class SASWP_Output_Rest_Api {
|
6 |
+
|
7 |
+
private static $instance;
|
8 |
+
private $api_service = null;
|
9 |
+
|
10 |
+
private function __construct() {
|
11 |
+
|
12 |
+
if($this->api_service == null){
|
13 |
+
require_once SASWP_PLUGIN_DIR_PATH.'output/rest-api/api-service.php';
|
14 |
+
$this->api_service = new SASWP_Output_Rest_Api_Service();
|
15 |
+
}
|
16 |
+
|
17 |
+
add_action( 'rest_api_init', array($this, 'registerRoute'));
|
18 |
+
|
19 |
+
}
|
20 |
+
|
21 |
+
public static function getInstance() {
|
22 |
+
|
23 |
+
if ( null == self::$instance ) {
|
24 |
+
self::$instance = new self;
|
25 |
+
}
|
26 |
+
return self::$instance;
|
27 |
+
}
|
28 |
+
|
29 |
+
public function registerRoute(){
|
30 |
+
|
31 |
+
register_rest_route( 'saswp-output', 'posts/(?P<id>\d+)', array(
|
32 |
+
'methods' => 'GET',
|
33 |
+
'callback' => array($this, 'json_ld'),
|
34 |
+
'permission_callback' => function(){
|
35 |
+
return true;
|
36 |
+
}
|
37 |
+
));
|
38 |
+
|
39 |
+
}
|
40 |
+
|
41 |
+
public function json_ld($request){
|
42 |
+
|
43 |
+
$response = array();
|
44 |
+
$post_id = null;
|
45 |
+
|
46 |
+
$parameters = $request->get_params();
|
47 |
+
|
48 |
+
if(isset($parameters['id'])){
|
49 |
+
$post_id = $parameters['id'];
|
50 |
+
}else{
|
51 |
+
return array('status' => 'f', 'message' => 'post_id is required');
|
52 |
+
}
|
53 |
+
|
54 |
+
$response = $this->api_service->get_schema($post_id);
|
55 |
+
|
56 |
+
if($response){
|
57 |
+
return array('status' => 't', 'json_ld' => $response);
|
58 |
+
}else{
|
59 |
+
return array('status' => 'f', 'json_ld' => array());
|
60 |
+
}
|
61 |
+
|
62 |
+
return $response;
|
63 |
+
|
64 |
+
}
|
65 |
+
|
66 |
+
}
|
67 |
+
if(class_exists('SASWP_Output_Rest_Api')){
|
68 |
+
SASWP_Output_Rest_Api::getInstance();
|
69 |
+
}
|
output/service.php
CHANGED
@@ -464,6 +464,12 @@ Class saswp_output_service{
|
|
464 |
}
|
465 |
|
466 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
467 |
if(isset($custom_fields['saswp_book_isbn'])){
|
468 |
$input1['isbn'] = $custom_fields['saswp_book_isbn'];
|
469 |
}
|
@@ -1525,6 +1531,13 @@ Class saswp_output_service{
|
|
1525 |
if(isset($custom_fields['saswp_webpage_headline'])){
|
1526 |
$input1['mainEntity']['headline'] = $custom_fields['saswp_webpage_headline'];
|
1527 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1528 |
|
1529 |
if(isset($custom_fields['saswp_webpage_date_published'])){
|
1530 |
$input1['mainEntity']['datePublished'] = $custom_fields['saswp_webpage_date_published'];
|
@@ -4121,8 +4134,8 @@ Class saswp_output_service{
|
|
4121 |
'mainEntityOfPage' => saswp_get_permalink(),
|
4122 |
'headline' => saswp_get_the_title(),
|
4123 |
'description' => saswp_get_the_excerpt(),
|
4124 |
-
|
4125 |
-
|
4126 |
'datePublished' => esc_html($date),
|
4127 |
'dateModified' => esc_html($modified_date),
|
4128 |
'author' => saswp_get_author_details(),
|
464 |
}
|
465 |
|
466 |
}
|
467 |
+
if(isset($custom_fields['saswp_book_inlanguage'])){
|
468 |
+
$input1['inLanguage'] = $custom_fields['saswp_book_inlanguage'];
|
469 |
+
}
|
470 |
+
if(isset($custom_fields['saswp_book_format'])){
|
471 |
+
$input1['bookFormat'] = $custom_fields['saswp_book_format'];
|
472 |
+
}
|
473 |
if(isset($custom_fields['saswp_book_isbn'])){
|
474 |
$input1['isbn'] = $custom_fields['saswp_book_isbn'];
|
475 |
}
|
1531 |
if(isset($custom_fields['saswp_webpage_headline'])){
|
1532 |
$input1['mainEntity']['headline'] = $custom_fields['saswp_webpage_headline'];
|
1533 |
}
|
1534 |
+
|
1535 |
+
if(isset($custom_fields['saswp_webpage_section'])){
|
1536 |
+
$input1['mainEntity']['articleSection'] = $custom_fields['saswp_webpage_section'];
|
1537 |
+
}
|
1538 |
+
if(isset($custom_fields['saswp_webpage_body'])){
|
1539 |
+
$input1['mainEntity']['articleBody'] = $custom_fields['saswp_webpage_body'];
|
1540 |
+
}
|
1541 |
|
1542 |
if(isset($custom_fields['saswp_webpage_date_published'])){
|
1543 |
$input1['mainEntity']['datePublished'] = $custom_fields['saswp_webpage_date_published'];
|
4134 |
'mainEntityOfPage' => saswp_get_permalink(),
|
4135 |
'headline' => saswp_get_the_title(),
|
4136 |
'description' => saswp_get_the_excerpt(),
|
4137 |
+
'articleBody' => saswp_get_the_content(),
|
4138 |
+
'keywords' => saswp_get_the_tags(),
|
4139 |
'datePublished' => esc_html($date),
|
4140 |
'dateModified' => esc_html($modified_date),
|
4141 |
'author' => saswp_get_author_details(),
|
readme.txt
CHANGED
@@ -3,7 +3,7 @@ Contributors: magazine3
|
|
3 |
Tags: Schema, Structured Data, Google Snippets, Rich Snippets, Schema.org, SEO, AMP
|
4 |
Requires at least: 3.0
|
5 |
Tested up to: 5.5
|
6 |
-
Stable tag: 1.9.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -120,6 +120,20 @@ You can contact us from [here](http://structured-data-for-wp.com/contact-us/)
|
|
120 |
|
121 |
== Changelog ==
|
122 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
123 |
= 1.9.53 (02 Nov 2020) =
|
124 |
|
125 |
* Added: Support for "low price" and "high price" properties of the product schema #1133
|
3 |
Tags: Schema, Structured Data, Google Snippets, Rich Snippets, Schema.org, SEO, AMP
|
4 |
Requires at least: 3.0
|
5 |
Tested up to: 5.5
|
6 |
+
Stable tag: 1.9.54
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
120 |
|
121 |
== Changelog ==
|
122 |
|
123 |
+
= 1.9.54 (10 Nov 2020) =
|
124 |
+
|
125 |
+
* Added: Rest api to show the headless output #1026
|
126 |
+
* Added: Article body and Article Section properties to webpage schema #1147
|
127 |
+
* Added: bookformat and inlanguage properties to Book Schema #1143
|
128 |
+
* Added: Separate folder (schema-and-structured-data-for-wp) in uploads to store all resized images by this plugin. #807
|
129 |
+
* Added: A notice box has been added, if logo is not set. #1165
|
130 |
+
* Added: Compatibility with Meta Tag Manager ( https://wordpress.org/plugins/meta-tag-manager/ )
|
131 |
+
* Fixed: Warning Error: The text tag script type=application/ld+json contains html comments, which is disallowed #1140
|
132 |
+
* Fixed: Woocommerce category schema has an issue when reviews collection is present #1182
|
133 |
+
* Fixed: Excessive number of queries at each page load in admin pages #1227
|
134 |
+
* Fixed: Issue with the image size when user inserting recipe by using WP recipe maker plugin. #1159
|
135 |
+
|
136 |
+
|
137 |
= 1.9.53 (02 Nov 2020) =
|
138 |
|
139 |
* Added: Support for "low price" and "high price" properties of the product schema #1133
|
structured-data-for-wp.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/*
|
3 |
Plugin Name: Schema & Structured Data for WP & AMP
|
4 |
Description: Schema & Structured Data adds Google Rich Snippets markup according to Schema.org guidelines to structure your site for SEO. (AMP Compatible)
|
5 |
-
Version: 1.9.
|
6 |
Text Domain: schema-and-structured-data-for-wp
|
7 |
Domain Path: /languages
|
8 |
Author: Magazine3
|
@@ -13,7 +13,7 @@ License: GPL2
|
|
13 |
// Exit if accessed directly.
|
14 |
if ( ! defined( 'ABSPATH' ) ) exit;
|
15 |
|
16 |
-
define('SASWP_VERSION', '1.9.
|
17 |
define('SASWP_DIR_NAME_FILE', __FILE__ );
|
18 |
define('SASWP_DIR_NAME', dirname( __FILE__ ));
|
19 |
define('SASWP_DIR_URI', plugin_dir_url(__FILE__));
|
@@ -87,6 +87,11 @@ require_once SASWP_DIR_NAME.'/modules/rating-box/backend.php';
|
|
87 |
require_once SASWP_DIR_NAME.'/modules/rating-box/frontend.php';
|
88 |
require_once SASWP_DIR_NAME.'/output/service.php';
|
89 |
require_once SASWP_DIR_NAME.'/output/compatibility.php';
|
|
|
|
|
|
|
|
|
|
|
90 |
//Loading Reviews files
|
91 |
require_once SASWP_DIR_NAME.'/modules/divi-builder/extension.php';
|
92 |
require_once SASWP_DIR_NAME.'/modules/reviews/reviews_admin.php';
|
@@ -119,7 +124,8 @@ function saswp_add_plugin_meta_links($meta_fields, $file) {
|
|
119 |
|
120 |
$forum_url = "https://structured-data-for-wp.com/contact-us/";
|
121 |
|
122 |
-
$meta_fields[] = "<a href='" . esc_url($forum_url) . "' target='_blank'>" .
|
|
|
123 |
}
|
124 |
|
125 |
return $meta_fields;
|
2 |
/*
|
3 |
Plugin Name: Schema & Structured Data for WP & AMP
|
4 |
Description: Schema & Structured Data adds Google Rich Snippets markup according to Schema.org guidelines to structure your site for SEO. (AMP Compatible)
|
5 |
+
Version: 1.9.54
|
6 |
Text Domain: schema-and-structured-data-for-wp
|
7 |
Domain Path: /languages
|
8 |
Author: Magazine3
|
13 |
// Exit if accessed directly.
|
14 |
if ( ! defined( 'ABSPATH' ) ) exit;
|
15 |
|
16 |
+
define('SASWP_VERSION', '1.9.54');
|
17 |
define('SASWP_DIR_NAME_FILE', __FILE__ );
|
18 |
define('SASWP_DIR_NAME', dirname( __FILE__ ));
|
19 |
define('SASWP_DIR_URI', plugin_dir_url(__FILE__));
|
87 |
require_once SASWP_DIR_NAME.'/modules/rating-box/frontend.php';
|
88 |
require_once SASWP_DIR_NAME.'/output/service.php';
|
89 |
require_once SASWP_DIR_NAME.'/output/compatibility.php';
|
90 |
+
|
91 |
+
//Loading api files
|
92 |
+
|
93 |
+
require_once SASWP_PLUGIN_DIR_PATH.'output/rest-api/api.php';
|
94 |
+
|
95 |
//Loading Reviews files
|
96 |
require_once SASWP_DIR_NAME.'/modules/divi-builder/extension.php';
|
97 |
require_once SASWP_DIR_NAME.'/modules/reviews/reviews_admin.php';
|
124 |
|
125 |
$forum_url = "https://structured-data-for-wp.com/contact-us/";
|
126 |
|
127 |
+
$meta_fields[] = "<a href='" . esc_url($forum_url) . "' target='_blank'>" . saswp_t_string( 'Technical Support' ) . "</a>";
|
128 |
+
|
129 |
}
|
130 |
|
131 |
return $meta_fields;
|
view/common.php
CHANGED
@@ -75,7 +75,7 @@ class saswp_view_common_class {
|
|
75 |
foreach ( $meta_fields as $meta_field ) {
|
76 |
|
77 |
|
78 |
-
$label = '<label for="' . $meta_field['name'] . '">' .
|
79 |
|
80 |
switch ( $meta_field['type'] ) {
|
81 |
|
@@ -132,7 +132,7 @@ class saswp_view_common_class {
|
|
132 |
'<option %s value="%s">%s</option>',
|
133 |
$data[$meta_field['name']] === $meta_field_value ? 'selected' : '',
|
134 |
$meta_field_value,
|
135 |
-
|
136 |
);
|
137 |
}
|
138 |
$input .= '</select>';
|
@@ -257,7 +257,7 @@ class saswp_view_common_class {
|
|
257 |
|
258 |
}
|
259 |
|
260 |
-
$tabs_fields .= '<a itemlist_sub_type="'.esc_attr($itemlist_sub_type).'" data-id="'.esc_attr($schema_id).'" div_type="'.$key.'" fields_type="'.$value.'" class="button saswp_add_schema_fields_on_fly saswp-'.$key.'">'.
|
261 |
$tabs_fields .= '</div>';
|
262 |
|
263 |
}
|
@@ -289,7 +289,7 @@ class saswp_view_common_class {
|
|
289 |
$input = '';
|
290 |
$attributes = '';
|
291 |
|
292 |
-
$label = '<label for="' . esc_attr($meta_field['id']) . '">' .
|
293 |
$meta_value = get_post_meta( $post_id, $meta_field['id'], true );
|
294 |
|
295 |
if ( empty( $meta_value ) && isset($meta_field['default'])) {
|
@@ -432,7 +432,7 @@ class saswp_view_common_class {
|
|
432 |
'<option %s value="%s">%s</option>',
|
433 |
$meta_value === $meta_field_value ? 'selected' : '',
|
434 |
$meta_field_value,
|
435 |
-
|
436 |
);
|
437 |
}
|
438 |
$input .= '</select>';
|
75 |
foreach ( $meta_fields as $meta_field ) {
|
76 |
|
77 |
|
78 |
+
$label = '<label for="' . $meta_field['name'] . '">' . saswp_t_string( $meta_field['label'] ) . '</label>';
|
79 |
|
80 |
switch ( $meta_field['type'] ) {
|
81 |
|
132 |
'<option %s value="%s">%s</option>',
|
133 |
$data[$meta_field['name']] === $meta_field_value ? 'selected' : '',
|
134 |
$meta_field_value,
|
135 |
+
saswp_t_string($value )
|
136 |
);
|
137 |
}
|
138 |
$input .= '</select>';
|
257 |
|
258 |
}
|
259 |
|
260 |
+
$tabs_fields .= '<a itemlist_sub_type="'.esc_attr($itemlist_sub_type).'" data-id="'.esc_attr($schema_id).'" div_type="'.$key.'" fields_type="'.$value.'" class="button saswp_add_schema_fields_on_fly saswp-'.$key.'">'.saswp_t_string( 'Add '.$btn_text ).'</a>';
|
261 |
$tabs_fields .= '</div>';
|
262 |
|
263 |
}
|
289 |
$input = '';
|
290 |
$attributes = '';
|
291 |
|
292 |
+
$label = '<label for="' . esc_attr($meta_field['id']) . '">' . saswp_t_string( $meta_field['label'] ). '</label>';
|
293 |
$meta_value = get_post_meta( $post_id, $meta_field['id'], true );
|
294 |
|
295 |
if ( empty( $meta_value ) && isset($meta_field['default'])) {
|
432 |
'<option %s value="%s">%s</option>',
|
433 |
$meta_value === $meta_field_value ? 'selected' : '',
|
434 |
$meta_field_value,
|
435 |
+
saswp_t_string($value )
|
436 |
);
|
437 |
}
|
438 |
$input .= '</select>';
|
view/help.php
CHANGED
@@ -18,7 +18,7 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
18 |
*/
|
19 |
function saswp_help_meta_box_cb(){
|
20 |
|
21 |
-
echo '<a href="'.esc_url(admin_url('admin.php?page=structured_data_options&tab=support')).'">'.
|
22 |
}
|
23 |
|
24 |
/**
|
18 |
*/
|
19 |
function saswp_help_meta_box_cb(){
|
20 |
|
21 |
+
echo '<a href="'.esc_url(admin_url('admin.php?page=structured_data_options&tab=support')).'">'.saswp_t_string('Need Help').'</a>';
|
22 |
}
|
23 |
|
24 |
/**
|
view/paywall.php
CHANGED
@@ -37,22 +37,22 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
37 |
<table class="option-table-class saswp-paywall-table-class">
|
38 |
<tbody>
|
39 |
<tr>
|
40 |
-
<td><label for="notAccessibleForFree"><?php echo
|
41 |
<td><input type="checkbox" id="notAccessibleForFree" name="notAccessibleForFree" value="1" <?php if(isset($schema_options['notAccessibleForFree']) && $schema_options['notAccessibleForFree']==1){echo 'checked'; }?>>
|
42 |
</td>
|
43 |
</tr>
|
44 |
<tr <?php if(!isset($schema_options['notAccessibleForFree']) || $schema_options['notAccessibleForFree']!=1){echo 'style="display:none"'; }?>>
|
45 |
-
<td><label for="isAccessibleForFree"><?php echo
|
46 |
<td>
|
47 |
<select name="isAccessibleForFree" id="isAccessibleForFree">
|
48 |
-
<option value="False" <?php if( isset($schema_options['isAccessibleForFree']) && $schema_options['isAccessibleForFree']=='False'){echo 'selected'; }?>><?php echo
|
49 |
-
<option value="True" <?php if( isset($schema_options['isAccessibleForFree']) && $schema_options['isAccessibleForFree']=='True'){echo 'selected'; }?>><?php echo
|
50 |
</select>
|
51 |
</td>
|
52 |
</tr>
|
53 |
<tr <?php if(!isset($schema_options['notAccessibleForFree']) || $schema_options['notAccessibleForFree']!=1){echo 'style="display:none"'; }?>>
|
54 |
<td>
|
55 |
-
<label for="paywall_class_name"><?php echo
|
56 |
</td>
|
57 |
<td><input type="text" id="paywall_class_name" name="paywall_class_name" value="<?php if( isset($schema_options['paywall_class_name']) ){echo esc_attr($schema_options['paywall_class_name']); }?>"></td>
|
58 |
</tr>
|
37 |
<table class="option-table-class saswp-paywall-table-class">
|
38 |
<tbody>
|
39 |
<tr>
|
40 |
+
<td><label for="notAccessibleForFree"><?php echo saswp_t_string( 'Paywall' ) ?></label></td>
|
41 |
<td><input type="checkbox" id="notAccessibleForFree" name="notAccessibleForFree" value="1" <?php if(isset($schema_options['notAccessibleForFree']) && $schema_options['notAccessibleForFree']==1){echo 'checked'; }?>>
|
42 |
</td>
|
43 |
</tr>
|
44 |
<tr <?php if(!isset($schema_options['notAccessibleForFree']) || $schema_options['notAccessibleForFree']!=1){echo 'style="display:none"'; }?>>
|
45 |
+
<td><label for="isAccessibleForFree"><?php echo saswp_t_string( 'Is accessible for free' ) ?></label></td>
|
46 |
<td>
|
47 |
<select name="isAccessibleForFree" id="isAccessibleForFree">
|
48 |
+
<option value="False" <?php if( isset($schema_options['isAccessibleForFree']) && $schema_options['isAccessibleForFree']=='False'){echo 'selected'; }?>><?php echo saswp_t_string( 'False' ); ?></option>
|
49 |
+
<option value="True" <?php if( isset($schema_options['isAccessibleForFree']) && $schema_options['isAccessibleForFree']=='True'){echo 'selected'; }?>><?php echo saswp_t_string( 'True' ); ?></option>
|
50 |
</select>
|
51 |
</td>
|
52 |
</tr>
|
53 |
<tr <?php if(!isset($schema_options['notAccessibleForFree']) || $schema_options['notAccessibleForFree']!=1){echo 'style="display:none"'; }?>>
|
54 |
<td>
|
55 |
+
<label for="paywall_class_name"><?php echo saswp_t_string( 'Enter the class name of paywall section' ); ?></label>
|
56 |
</td>
|
57 |
<td><input type="text" id="paywall_class_name" name="paywall_class_name" value="<?php if( isset($schema_options['paywall_class_name']) ){echo esc_attr($schema_options['paywall_class_name']); }?>"></td>
|
58 |
</tr>
|
view/post_specific.php
CHANGED
@@ -84,7 +84,7 @@ class saswp_post_specific {
|
|
84 |
$result = delete_post_meta($post_id, $field['id']);
|
85 |
}
|
86 |
}
|
87 |
-
echo json_encode(array('status'=> 't', 'msg'=>
|
88 |
wp_die();
|
89 |
|
90 |
}
|
@@ -280,7 +280,7 @@ class saswp_post_specific {
|
|
280 |
|
281 |
add_meta_box(
|
282 |
'saswp_post_specific',
|
283 |
-
|
284 |
array( $this, 'saswp_post_meta_box_callback' ),
|
285 |
$single_screen,
|
286 |
'advanced',
|
@@ -351,7 +351,7 @@ class saswp_post_specific {
|
|
351 |
$schema_enable = get_post_meta($post->ID, 'saswp_enable_disable_schema', true);
|
352 |
$custom_markp = get_post_meta($post->ID, 'saswp_custom_schema_field', true);
|
353 |
$disable_btn.= '<div class="saswp-disable-btn-container">'
|
354 |
-
. '<span class="saswp-disable-label">'.
|
355 |
. '<label class="saswp-switch">'
|
356 |
. '<input type="checkbox" class="saswp-schema-type-toggle" value="1" data-schema-id="custom" data-post-id="'.esc_attr($post->ID).'" '.( (isset($schema_enable['custom']) && $schema_enable['custom'] == 0) ? 'checked' : '' ).'>'
|
357 |
. '<span class="saswp-slider"></span>'
|
@@ -362,7 +362,7 @@ class saswp_post_specific {
|
|
362 |
$cus_schema .= '<div class="'.((isset($schema_enable['custom']) && $schema_enable['custom'] == 0) ? 'saswp_hide' : '').'"><textarea style="margin-left:5px;" placeholder="JSON-LD" schema-id="custom" id="saswp_custom_schema_field" name="saswp_custom_schema_field" rows="5" cols="95">'
|
363 |
. $custom_markp
|
364 |
. '</textarea>';
|
365 |
-
$cus_schema .= '<span><strong>'.
|
366 |
$cus_schema .= '</div>';
|
367 |
$cus_schema .= $disable_btn;
|
368 |
$cus_schema .= '</div>';
|
@@ -445,7 +445,7 @@ class saswp_post_specific {
|
|
445 |
$setting_options .= '<div class="saswp-ps-text '.( ($modify_this || $modified ) ? '' : 'saswp_hide').'">';
|
446 |
}
|
447 |
|
448 |
-
$setting_options .= '<a class="button button-default saswp-restore-schema button" schema-id="'.esc_attr($schema->ID).'">'.
|
449 |
$setting_options .= '</div>';
|
450 |
|
451 |
if(!empty($disabled)){
|
@@ -463,15 +463,15 @@ class saswp_post_specific {
|
|
463 |
$schema_type_txt = 'Q&A';
|
464 |
}
|
465 |
|
466 |
-
$setting_options .= '<span>'.
|
467 |
-
$setting_options .= '<a class="button button-default saswp-modify-schema button" schema-id="'.esc_attr($schema->ID).'">'.
|
468 |
$setting_options .= '</div>';
|
469 |
|
470 |
$setting_options.= '</div>';
|
471 |
$setting_options.= '</div>';
|
472 |
|
473 |
$btn_in_loop = '<div class="saswp-disable-btn-container">'
|
474 |
-
. '<span class="saswp-disable-label">'.
|
475 |
. '<label class="saswp-switch">'
|
476 |
. '<input type="checkbox" class="saswp-schema-type-toggle" value="1" data-schema-id="'.esc_attr($schema->ID).'" data-post-id="'.esc_attr($post->ID).'" '.$disabled.'>'
|
477 |
. '<span class="saswp-slider"></span>'
|
@@ -512,7 +512,7 @@ class saswp_post_specific {
|
|
512 |
$response_html .= $tabs;
|
513 |
|
514 |
$response_html .='<li>'
|
515 |
-
. '<a class="saswp-tab-links" data-id="saswp_specific_custom">'.
|
516 |
. '</li>';
|
517 |
$response_html .= '</ul>';
|
518 |
$response_html .= '</div>';
|
@@ -529,10 +529,10 @@ class saswp_post_specific {
|
|
529 |
|
530 |
|
531 |
$response_html .= '<div class="saswp-tab saswp-post-specific-tab-wrapper">';
|
532 |
-
$response_html .= '<div><a href="'.esc_url( admin_url( 'edit.php?post_type=saswp' ) ).'" class="button button-default saswp-setup-schema-btn">'.
|
533 |
$response_html .= '<ul class="saswp-tab-nav">';
|
534 |
$response_html .= '<li class="selected">'
|
535 |
-
. '<a class="saswp-tab-links" data-id="saswp_specific_custom">'.
|
536 |
. '</li>';
|
537 |
$response_html .= '</ul>';
|
538 |
$response_html .= '</div>';
|
84 |
$result = delete_post_meta($post_id, $field['id']);
|
85 |
}
|
86 |
}
|
87 |
+
echo json_encode(array('status'=> 't', 'msg'=>saswp_t_string( 'Schema has been restored' )));
|
88 |
wp_die();
|
89 |
|
90 |
}
|
280 |
|
281 |
add_meta_box(
|
282 |
'saswp_post_specific',
|
283 |
+
saswp_t_string( 'Schema & Structured Data on this post' ),
|
284 |
array( $this, 'saswp_post_meta_box_callback' ),
|
285 |
$single_screen,
|
286 |
'advanced',
|
351 |
$schema_enable = get_post_meta($post->ID, 'saswp_enable_disable_schema', true);
|
352 |
$custom_markp = get_post_meta($post->ID, 'saswp_custom_schema_field', true);
|
353 |
$disable_btn.= '<div class="saswp-disable-btn-container">'
|
354 |
+
. '<span class="saswp-disable-label">'.saswp_t_string( 'Disable custom schema on this page' ).'</span>'
|
355 |
. '<label class="saswp-switch">'
|
356 |
. '<input type="checkbox" class="saswp-schema-type-toggle" value="1" data-schema-id="custom" data-post-id="'.esc_attr($post->ID).'" '.( (isset($schema_enable['custom']) && $schema_enable['custom'] == 0) ? 'checked' : '' ).'>'
|
357 |
. '<span class="saswp-slider"></span>'
|
362 |
$cus_schema .= '<div class="'.((isset($schema_enable['custom']) && $schema_enable['custom'] == 0) ? 'saswp_hide' : '').'"><textarea style="margin-left:5px;" placeholder="JSON-LD" schema-id="custom" id="saswp_custom_schema_field" name="saswp_custom_schema_field" rows="5" cols="95">'
|
363 |
. $custom_markp
|
364 |
. '</textarea>';
|
365 |
+
$cus_schema .= '<span><strong>'.saswp_t_string( 'Note' ).': </strong>'.saswp_t_string( 'Please enter the valid Json-ld. Whatever you enter will be added in page source' ).'</span>';
|
366 |
$cus_schema .= '</div>';
|
367 |
$cus_schema .= $disable_btn;
|
368 |
$cus_schema .= '</div>';
|
445 |
$setting_options .= '<div class="saswp-ps-text '.( ($modify_this || $modified ) ? '' : 'saswp_hide').'">';
|
446 |
}
|
447 |
|
448 |
+
$setting_options .= '<a class="button button-default saswp-restore-schema button" schema-id="'.esc_attr($schema->ID).'">'.saswp_t_string( 'Restore to Auto Fetch' ).'</a>';
|
449 |
$setting_options .= '</div>';
|
450 |
|
451 |
if(!empty($disabled)){
|
463 |
$schema_type_txt = 'Q&A';
|
464 |
}
|
465 |
|
466 |
+
$setting_options .= '<span>'.saswp_t_string( $schema_type_txt.' schema is fetched automatically' ).'</span><br><br>';
|
467 |
+
$setting_options .= '<a class="button button-default saswp-modify-schema button" schema-id="'.esc_attr($schema->ID).'">'.saswp_t_string( 'Modify '.$schema_type.' Schema Output' ).'</a>';
|
468 |
$setting_options .= '</div>';
|
469 |
|
470 |
$setting_options.= '</div>';
|
471 |
$setting_options.= '</div>';
|
472 |
|
473 |
$btn_in_loop = '<div class="saswp-disable-btn-container">'
|
474 |
+
. '<span class="saswp-disable-label">'.saswp_t_string( 'Disable '.$schema_type_txt.' on this page' ).'</span>'
|
475 |
. '<label class="saswp-switch">'
|
476 |
. '<input type="checkbox" class="saswp-schema-type-toggle" value="1" data-schema-id="'.esc_attr($schema->ID).'" data-post-id="'.esc_attr($post->ID).'" '.$disabled.'>'
|
477 |
. '<span class="saswp-slider"></span>'
|
512 |
$response_html .= $tabs;
|
513 |
|
514 |
$response_html .='<li>'
|
515 |
+
. '<a class="saswp-tab-links" data-id="saswp_specific_custom">'.saswp_t_string( 'Custom Schema' ).'</a>'
|
516 |
. '</li>';
|
517 |
$response_html .= '</ul>';
|
518 |
$response_html .= '</div>';
|
529 |
|
530 |
|
531 |
$response_html .= '<div class="saswp-tab saswp-post-specific-tab-wrapper">';
|
532 |
+
$response_html .= '<div><a href="'.esc_url( admin_url( 'edit.php?post_type=saswp' ) ).'" class="button button-default saswp-setup-schema-btn">'.saswp_t_string( 'Setup Schema' ).'</div>';
|
533 |
$response_html .= '<ul class="saswp-tab-nav">';
|
534 |
$response_html .= '<li class="selected">'
|
535 |
+
. '<a class="saswp-tab-links" data-id="saswp_specific_custom">'.saswp_t_string( 'Custom Schema' ).'</a>'
|
536 |
. '</li>';
|
537 |
$response_html .= '</ul>';
|
538 |
$response_html .= '</div>';
|
view/schema_type.php
CHANGED
@@ -31,7 +31,7 @@ function saswp_add_all_meta_boxes() {
|
|
31 |
|
32 |
add_meta_box(
|
33 |
'saswp_schema_type',
|
34 |
-
|
35 |
'saswp_schema_type_meta_box_callback',
|
36 |
'saswp',
|
37 |
'normal',
|
@@ -39,7 +39,7 @@ function saswp_add_all_meta_boxes() {
|
|
39 |
);
|
40 |
|
41 |
add_meta_box( 'saswp_help_meta_box',
|
42 |
-
|
43 |
'saswp_help_meta_box_cb',
|
44 |
'saswp',
|
45 |
'side', 'low'
|
@@ -47,7 +47,7 @@ function saswp_add_all_meta_boxes() {
|
|
47 |
|
48 |
add_meta_box(
|
49 |
'saswp_schema_options',
|
50 |
-
|
51 |
'saswp_schema_options_meta_box_callback',
|
52 |
'saswp',
|
53 |
'normal',
|
@@ -55,21 +55,21 @@ function saswp_add_all_meta_boxes() {
|
|
55 |
);
|
56 |
add_meta_box(
|
57 |
'saswp_amp_select',
|
58 |
-
|
59 |
'saswp_select_callback', 'saswp',
|
60 |
'normal',
|
61 |
'high'
|
62 |
);
|
63 |
add_meta_box(
|
64 |
'saswp_reviews_form',
|
65 |
-
|
66 |
'saswp_reviews_form_shortcode_metabox', 'saswp_reviews',
|
67 |
'side',
|
68 |
'low'
|
69 |
);
|
70 |
add_meta_box(
|
71 |
'saswp_submitdiv',
|
72 |
-
|
73 |
'post_submit_meta_box',
|
74 |
array('saswp', 'saswp_reviews'),
|
75 |
'side',
|
@@ -248,7 +248,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
248 |
|
249 |
<table class="option-table-class saswp-option-table-class">
|
250 |
<tr>
|
251 |
-
<td><label for="schema_type"><?php echo
|
252 |
<td><select class="saswp-schame-type-select" id="schema_type" name="schema_type">
|
253 |
<?php
|
254 |
|
@@ -270,7 +270,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
270 |
$sel = 'selected';
|
271 |
}
|
272 |
|
273 |
-
$option_html.= "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
274 |
|
275 |
}
|
276 |
|
@@ -287,7 +287,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
287 |
</tr>
|
288 |
<tr class="saswp-business-type-tr" <?php echo $style_business_type; ?>>
|
289 |
<td>
|
290 |
-
<?php echo
|
291 |
</td>
|
292 |
<td>
|
293 |
<select id="saswp_business_type" name="saswp_business_type">
|
@@ -298,7 +298,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
298 |
if($business_type==$key){
|
299 |
$sel = 'selected';
|
300 |
}
|
301 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
302 |
}
|
303 |
?>
|
304 |
</select>
|
@@ -307,7 +307,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
307 |
|
308 |
<tr class="saswp-event-text-field-tr" <?php echo $style_business_type; ?>>
|
309 |
<td>
|
310 |
-
<?php echo
|
311 |
</td>
|
312 |
<td>
|
313 |
<select id="saswp_event_type" name="saswp_event_type">
|
@@ -318,7 +318,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
318 |
if($event_type==$key){
|
319 |
$sel = 'selected';
|
320 |
}
|
321 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
322 |
}
|
323 |
?>
|
324 |
</select>
|
@@ -326,7 +326,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
326 |
</tr>
|
327 |
|
328 |
<tr class="saswp-automotivebusiness-tr" <?php if(!array_key_exists($business_name, $all_automotive_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
329 |
-
<td><?php echo
|
330 |
<td>
|
331 |
<select class="saswp-local-sub-type-2" id="saswp_automotive" name="saswp_business_name">
|
332 |
|
@@ -336,7 +336,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
336 |
if($business_name==$key){
|
337 |
$sel = 'selected';
|
338 |
}
|
339 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
340 |
}
|
341 |
?>
|
342 |
|
@@ -345,7 +345,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
345 |
|
346 |
</tr>
|
347 |
<tr class="saswp-emergencyservice-tr" <?php if(!array_key_exists($business_name, $all_emergency_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
348 |
-
<td><?php echo
|
349 |
<td>
|
350 |
<select class="saswp-local-sub-type-2" id="saswp_emergency_service" name="saswp_business_name">
|
351 |
<?php
|
@@ -355,14 +355,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
355 |
if($business_name==$key){
|
356 |
$sel = 'selected';
|
357 |
}
|
358 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
359 |
}
|
360 |
?>
|
361 |
</select>
|
362 |
</td>
|
363 |
</tr>
|
364 |
<tr class="saswp-entertainmentbusiness-tr" <?php if(!array_key_exists($business_name, $all_entertainment_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
365 |
-
<td><?php echo
|
366 |
<td>
|
367 |
<select class="saswp-local-sub-type-2" id="saswp_entertainment" name="saswp_business_name">
|
368 |
<?php
|
@@ -372,7 +372,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
372 |
if($business_name == $key){
|
373 |
$sel = 'selected';
|
374 |
}
|
375 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
376 |
}
|
377 |
?>
|
378 |
</select>
|
@@ -380,7 +380,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
380 |
</tr>
|
381 |
|
382 |
<tr class="saswp-medicalbusiness-tr" <?php if(!array_key_exists($business_name, $all_medical_business_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
383 |
-
<td><?php echo
|
384 |
<td>
|
385 |
<select class="saswp-local-sub-type-2" id="saswp_medicalbusiness" name="saswp_business_name">
|
386 |
<?php
|
@@ -390,7 +390,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
390 |
if($business_name == $key){
|
391 |
$sel = 'selected';
|
392 |
}
|
393 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
394 |
}
|
395 |
?>
|
396 |
</select>
|
@@ -398,7 +398,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
398 |
</tr>
|
399 |
|
400 |
<tr class="saswp-financialservice-tr" <?php if(!array_key_exists($business_name, $all_financial_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
401 |
-
<td><?php echo
|
402 |
<td>
|
403 |
<select class="saswp-local-sub-type-2" id="saswp_financial_service" name="saswp_business_name">
|
404 |
<?php
|
@@ -407,14 +407,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
407 |
if($business_name == $key){
|
408 |
$sel = 'selected';
|
409 |
}
|
410 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
411 |
}
|
412 |
?>
|
413 |
</select>
|
414 |
</td>
|
415 |
</tr>
|
416 |
<tr class="saswp-foodestablishment-tr" <?php if(!array_key_exists($business_name, $all_food_establishment_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
417 |
-
<td><?php echo
|
418 |
<td>
|
419 |
<select class="saswp-local-sub-type-2" id="saswp_food_establishment" name="saswp_business_name">
|
420 |
<?php
|
@@ -423,14 +423,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
423 |
if($business_name==$key){
|
424 |
$sel = 'selected';
|
425 |
}
|
426 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
427 |
}
|
428 |
?>
|
429 |
</select>
|
430 |
</td>
|
431 |
</tr>
|
432 |
<tr class="saswp-healthandbeautybusiness-tr" <?php if(!array_key_exists($business_name, $all_health_and_beauty_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
433 |
-
<td><?php echo
|
434 |
<td>
|
435 |
<select class="saswp-local-sub-type-2" id="saswp_health_and_beauty" name="saswp_business_name">
|
436 |
<?php
|
@@ -441,14 +441,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
441 |
if($business_name==$key){
|
442 |
$sel = 'selected';
|
443 |
}
|
444 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
445 |
}
|
446 |
?>
|
447 |
</select>
|
448 |
</td>
|
449 |
</tr>
|
450 |
<tr class="saswp-homeandconstructionbusiness-tr" <?php if(!array_key_exists($business_name, $all_home_and_construction_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
451 |
-
<td><?php echo
|
452 |
<td>
|
453 |
<select class="saswp-local-sub-type-2" id="saswp_home_and_construction" name="saswp_business_name">
|
454 |
<?php
|
@@ -458,14 +458,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
458 |
if($business_name==$key){
|
459 |
$sel = 'selected';
|
460 |
}
|
461 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
462 |
}
|
463 |
?>
|
464 |
</select>
|
465 |
</td>
|
466 |
</tr>
|
467 |
<tr class="saswp-legalservice-tr" <?php if(!array_key_exists($business_name, $all_legal_service_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
468 |
-
<td><?php echo
|
469 |
<td>
|
470 |
<select class="saswp-local-sub-type-2" id="saswp_legal_service" name="saswp_business_name">
|
471 |
<?php
|
@@ -475,14 +475,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
475 |
if($business_name==$key){
|
476 |
$sel = 'selected';
|
477 |
}
|
478 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
479 |
}
|
480 |
?>
|
481 |
</select>
|
482 |
</td>
|
483 |
</tr>
|
484 |
<tr class="saswp-lodgingbusiness-tr" <?php if(!array_key_exists($business_name, $all_lodging_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
485 |
-
<td><?php echo
|
486 |
<td>
|
487 |
<select class="saswp-local-sub-type-2" id="saswp_lodging" name="saswp_business_name">
|
488 |
<?php
|
@@ -492,14 +492,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
492 |
if($business_name==$key){
|
493 |
$sel = 'selected';
|
494 |
}
|
495 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
496 |
}
|
497 |
?>
|
498 |
</select>
|
499 |
</td>
|
500 |
</tr>
|
501 |
<tr class="saswp-sportsactivitylocation-tr" <?php if(!array_key_exists($business_name, $all_sports_activity_location)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
502 |
-
<td><?php echo
|
503 |
<td>
|
504 |
<select class="saswp-local-sub-type-2" id="saswp_sports_activity_location" name="saswp_business_name">
|
505 |
<?php
|
@@ -509,14 +509,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
509 |
if($business_name==$key){
|
510 |
$sel = 'selected';
|
511 |
}
|
512 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
513 |
}
|
514 |
?>
|
515 |
</select>
|
516 |
</td>
|
517 |
</tr>
|
518 |
<tr class="saswp-store-tr" <?php if(!array_key_exists($business_name, $all_store)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
519 |
-
<td><?php echo
|
520 |
<td>
|
521 |
<select class="saswp-local-sub-type-2" id="saswp_store" name="saswp_business_name">
|
522 |
<?php
|
@@ -527,7 +527,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
527 |
if($business_name==$key){
|
528 |
$sel = 'selected';
|
529 |
}
|
530 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
531 |
}
|
532 |
?>
|
533 |
</select>
|
@@ -536,7 +536,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
536 |
|
537 |
<!-- ItemList Schema type starts here -->
|
538 |
<tr class="saswp-itemlist-text-field-tr" <?php echo $style_review_name; ?>>
|
539 |
-
<td><?php echo
|
540 |
<td>
|
541 |
|
542 |
<select data-id="<?php if(is_object($post)){ echo esc_attr($post->ID); } ?>" name="saswp_itemlist_item_type" class="saswp-itemlist-item-type-list">
|
@@ -548,7 +548,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
548 |
if($item == $key){
|
549 |
$sel = 'selected';
|
550 |
}
|
551 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
552 |
}
|
553 |
?>
|
554 |
</select>
|
@@ -558,7 +558,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
558 |
|
559 |
<!-- Review Schema type starts here -->
|
560 |
<tr class="saswp-review-text-field-tr" <?php echo $style_review_name; ?>>
|
561 |
-
<td><?php echo
|
562 |
<td>
|
563 |
|
564 |
<select data-id="<?php if(is_object($post)){ echo esc_attr($post->ID); } ?>" name="saswp_review_item_reviewed_<?php echo $post->ID; ?>" class="saswp-item-reivewed-list">
|
@@ -570,7 +570,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
570 |
if($item == $key){
|
571 |
$sel = 'selected';
|
572 |
}
|
573 |
-
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".
|
574 |
}
|
575 |
?>
|
576 |
</select>
|
@@ -581,7 +581,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
581 |
|
582 |
<tr>
|
583 |
<td>
|
584 |
-
<label for="saswp-itemlist"><?php echo
|
585 |
</td>
|
586 |
<td>
|
587 |
<div class="saswp-enable-speakable">
|
@@ -621,7 +621,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
621 |
<input type="text" id="saswp_item_list_custom" name="saswp_item_list_custom" placeholder="classname" value="<?php echo esc_attr($item_list_custom); ?>" class="<?php if($item_list_enable == 1 && $item_list_tags == 'custom'){echo ''; }else{ echo 'saswp_hide'; } ?>">
|
622 |
|
623 |
</div>
|
624 |
-
<p class="saspw-item-list-note <?php if($item_list_enable == 1){echo ''; }else{ echo 'saswp_hide'; } ?>"><?php echo
|
625 |
</div>
|
626 |
|
627 |
</td>
|
@@ -630,7 +630,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
630 |
|
631 |
<tr>
|
632 |
<td>
|
633 |
-
<label for="saswp-speakable"><?php echo
|
634 |
</td>
|
635 |
<td>
|
636 |
<input class="saswp-enable-speakable" type="checkbox" name="saswp_enable_speakable_schema" value="1" <?php if(isset($speakable) && $speakable == 1){echo 'checked'; }else{ echo ''; } ?>>
|
@@ -639,7 +639,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
639 |
|
640 |
<tr>
|
641 |
<td>
|
642 |
-
<label for="saswp-enable-markup"><?php echo
|
643 |
</td>
|
644 |
<td>
|
645 |
<input id="saswp-enable-markup" class="saswp-enable-markup-class" type="checkbox" name="saswp_enable_videoobject" value="1" <?php if(isset($enable_videoobject) && $enable_videoobject == 1){echo 'checked'; }else{ echo ''; } ?> >
|
@@ -648,7 +648,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
648 |
|
649 |
<tr>
|
650 |
<td>
|
651 |
-
<label for="saswp-append-reviews"><?php echo
|
652 |
</td>
|
653 |
<td>
|
654 |
|
@@ -696,19 +696,19 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
696 |
?>
|
697 |
</a>
|
698 |
<div style="display:none;" id="saswp-embed-code-div">
|
699 |
-
<div class="saswp-add-rv-title"><?php echo
|
700 |
<div class="saswp-thick-box-container">
|
701 |
|
702 |
<div class="saswp-add-rv-popup" id="saswp-global-tabs">
|
703 |
<h2 class="nav-tab-wrapper">
|
704 |
-
<a class="nav-tab" data-id="saswp-add-rv-automatic"><?php echo
|
705 |
-
<a class="nav-tab" data-id="saswp-add-rv-collection"><?php echo
|
706 |
-
<a class="nav-tab" data-id="saswp-add-rv-manual"><?php echo
|
707 |
</h2>
|
708 |
</div>
|
709 |
|
710 |
<div class="saswp-global-container" id="saswp-add-rv-automatic">
|
711 |
-
<div class="saswp-add-rv-note"><strong><?php echo
|
712 |
<div data-type="review" class="saswp-add-rv-automatic-list">
|
713 |
|
714 |
<?php
|
@@ -743,14 +743,14 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
743 |
echo '<input id="saswp_attahced_reviews" type="hidden" name="saswp_attahced_reviews" value="'. esc_attr($attached_rv_json).'">';
|
744 |
?>
|
745 |
|
746 |
-
<div class="saswp-rv-not-found saswp_hide" data-type="review"><?php echo
|
747 |
<span class="spinner" data-type="review"></span>
|
748 |
-
<div><a class="saswp-load-more-rv" data-type="review"><?php echo
|
749 |
|
750 |
</div>
|
751 |
|
752 |
<div class="saswp-global-container" id="saswp-add-rv-collection">
|
753 |
-
<div class="saswp-add-rv-note"><strong>Note:</strong> <span><?php echo
|
754 |
<div data-type="collection" class="saswp-add-rv-automatic-list">
|
755 |
|
756 |
<?php
|
@@ -784,18 +784,18 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
784 |
echo '<input id="saswp_attached_collection" type="hidden" name="saswp_attached_collection" value="'. esc_attr($attached_col_json).'">';
|
785 |
?>
|
786 |
|
787 |
-
<div class="saswp-rv-not-found saswp_hide" data-type="collection"><?php echo
|
788 |
<span class="spinner" data-type="collection"></span>
|
789 |
-
<div><a class="saswp-load-more-rv" data-type="collection"><?php echo
|
790 |
|
791 |
</div>
|
792 |
|
793 |
<div class="saswp-global-container" id="saswp-add-rv-manual">
|
794 |
-
<p> <?php echo
|
795 |
<strong>[saswp-reviews]</strong><br>OR<br>
|
796 |
<strong>[saswp-reviews-collection id="your collection id"]</strong>
|
797 |
</div>
|
798 |
-
<a class="button button-default close-attached-reviews-popup"><?php echo
|
799 |
</div>
|
800 |
|
801 |
</div>
|
@@ -814,7 +814,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
814 |
<table class="option-table-class saswp_modify_schema_checkbox">
|
815 |
<tr>
|
816 |
<td>
|
817 |
-
<a class="button button-default saswp-modify-schema-toggle"><?php echo
|
818 |
<input type="hidden" name="saswp_enable_custom_field" id="saswp_enable_custom_field" value="<?php echo isset($schema_options['enable_custom_field']) ? $schema_options['enable_custom_field']:'0'; ?>">
|
819 |
</td>
|
820 |
</tr>
|
@@ -832,7 +832,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
832 |
echo '<div class="saswp-enable-modify-schema saswp_hide">';
|
833 |
}
|
834 |
|
835 |
-
echo '<strong>'.
|
836 |
echo '<select name="saswp_modify_method" class="saswp-enable-modify-schema-output">';
|
837 |
|
838 |
$method_option = array(
|
@@ -987,7 +987,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
987 |
echo '<td><input type="text" name="saswp_fixed_text['.esc_attr($fieldkey).']" value="'.(isset($fixed_text[$fieldkey]) ? esc_html($fixed_text[$fieldkey]) :'').'"></td>';
|
988 |
}else if($fieldval == 'taxonomy_term'){
|
989 |
|
990 |
-
$choices = array('all' =>
|
991 |
$taxonomies = saswp_post_taxonomy_generator();
|
992 |
$choices = array_merge($choices, $taxonomies);
|
993 |
|
@@ -1058,7 +1058,7 @@ function saswp_schema_type_meta_box_callback( $post) {
|
|
1058 |
|
1059 |
</table>
|
1060 |
<table class="option-table-class">
|
1061 |
-
<tr><td><a class="button button-primary saswp-add-custom-fields"><?php echo
|
1062 |
</table>
|
1063 |
|
1064 |
</div>
|
31 |
|
32 |
add_meta_box(
|
33 |
'saswp_schema_type',
|
34 |
+
saswp_t_string( 'Schema Type' ),
|
35 |
'saswp_schema_type_meta_box_callback',
|
36 |
'saswp',
|
37 |
'normal',
|
39 |
);
|
40 |
|
41 |
add_meta_box( 'saswp_help_meta_box',
|
42 |
+
saswp_t_string('Help' ),
|
43 |
'saswp_help_meta_box_cb',
|
44 |
'saswp',
|
45 |
'side', 'low'
|
47 |
|
48 |
add_meta_box(
|
49 |
'saswp_schema_options',
|
50 |
+
saswp_t_string( 'Advance Schema Options' ),
|
51 |
'saswp_schema_options_meta_box_callback',
|
52 |
'saswp',
|
53 |
'normal',
|
55 |
);
|
56 |
add_meta_box(
|
57 |
'saswp_amp_select',
|
58 |
+
saswp_t_string( 'Placement' ),
|
59 |
'saswp_select_callback', 'saswp',
|
60 |
'normal',
|
61 |
'high'
|
62 |
);
|
63 |
add_meta_box(
|
64 |
'saswp_reviews_form',
|
65 |
+
saswp_t_string( 'Reviews form Shortcode' ),
|
66 |
'saswp_reviews_form_shortcode_metabox', 'saswp_reviews',
|
67 |
'side',
|
68 |
'low'
|
69 |
);
|
70 |
add_meta_box(
|
71 |
'saswp_submitdiv',
|
72 |
+
saswp_t_string( 'Publish' ),
|
73 |
'post_submit_meta_box',
|
74 |
array('saswp', 'saswp_reviews'),
|
75 |
'side',
|
248 |
|
249 |
<table class="option-table-class saswp-option-table-class">
|
250 |
<tr>
|
251 |
+
<td><label for="schema_type"><?php echo saswp_t_string( 'Schema Type' );?></label></td>
|
252 |
<td><select class="saswp-schame-type-select" id="schema_type" name="schema_type">
|
253 |
<?php
|
254 |
|
270 |
$sel = 'selected';
|
271 |
}
|
272 |
|
273 |
+
$option_html.= "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
274 |
|
275 |
}
|
276 |
|
287 |
</tr>
|
288 |
<tr class="saswp-business-type-tr" <?php echo $style_business_type; ?>>
|
289 |
<td>
|
290 |
+
<?php echo saswp_t_string('Business Type' ); ?>
|
291 |
</td>
|
292 |
<td>
|
293 |
<select id="saswp_business_type" name="saswp_business_type">
|
298 |
if($business_type==$key){
|
299 |
$sel = 'selected';
|
300 |
}
|
301 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
302 |
}
|
303 |
?>
|
304 |
</select>
|
307 |
|
308 |
<tr class="saswp-event-text-field-tr" <?php echo $style_business_type; ?>>
|
309 |
<td>
|
310 |
+
<?php echo saswp_t_string('Event Type' ); ?>
|
311 |
</td>
|
312 |
<td>
|
313 |
<select id="saswp_event_type" name="saswp_event_type">
|
318 |
if($event_type==$key){
|
319 |
$sel = 'selected';
|
320 |
}
|
321 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
322 |
}
|
323 |
?>
|
324 |
</select>
|
326 |
</tr>
|
327 |
|
328 |
<tr class="saswp-automotivebusiness-tr" <?php if(!array_key_exists($business_name, $all_automotive_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
329 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
330 |
<td>
|
331 |
<select class="saswp-local-sub-type-2" id="saswp_automotive" name="saswp_business_name">
|
332 |
|
336 |
if($business_name==$key){
|
337 |
$sel = 'selected';
|
338 |
}
|
339 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
340 |
}
|
341 |
?>
|
342 |
|
345 |
|
346 |
</tr>
|
347 |
<tr class="saswp-emergencyservice-tr" <?php if(!array_key_exists($business_name, $all_emergency_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
348 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
349 |
<td>
|
350 |
<select class="saswp-local-sub-type-2" id="saswp_emergency_service" name="saswp_business_name">
|
351 |
<?php
|
355 |
if($business_name==$key){
|
356 |
$sel = 'selected';
|
357 |
}
|
358 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
359 |
}
|
360 |
?>
|
361 |
</select>
|
362 |
</td>
|
363 |
</tr>
|
364 |
<tr class="saswp-entertainmentbusiness-tr" <?php if(!array_key_exists($business_name, $all_entertainment_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
365 |
+
<td><?php echo saswp_t_string('Sub Business Type'); ?></td>
|
366 |
<td>
|
367 |
<select class="saswp-local-sub-type-2" id="saswp_entertainment" name="saswp_business_name">
|
368 |
<?php
|
372 |
if($business_name == $key){
|
373 |
$sel = 'selected';
|
374 |
}
|
375 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
376 |
}
|
377 |
?>
|
378 |
</select>
|
380 |
</tr>
|
381 |
|
382 |
<tr class="saswp-medicalbusiness-tr" <?php if(!array_key_exists($business_name, $all_medical_business_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
383 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
384 |
<td>
|
385 |
<select class="saswp-local-sub-type-2" id="saswp_medicalbusiness" name="saswp_business_name">
|
386 |
<?php
|
390 |
if($business_name == $key){
|
391 |
$sel = 'selected';
|
392 |
}
|
393 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
394 |
}
|
395 |
?>
|
396 |
</select>
|
398 |
</tr>
|
399 |
|
400 |
<tr class="saswp-financialservice-tr" <?php if(!array_key_exists($business_name, $all_financial_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
401 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
402 |
<td>
|
403 |
<select class="saswp-local-sub-type-2" id="saswp_financial_service" name="saswp_business_name">
|
404 |
<?php
|
407 |
if($business_name == $key){
|
408 |
$sel = 'selected';
|
409 |
}
|
410 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
411 |
}
|
412 |
?>
|
413 |
</select>
|
414 |
</td>
|
415 |
</tr>
|
416 |
<tr class="saswp-foodestablishment-tr" <?php if(!array_key_exists($business_name, $all_food_establishment_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
417 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
418 |
<td>
|
419 |
<select class="saswp-local-sub-type-2" id="saswp_food_establishment" name="saswp_business_name">
|
420 |
<?php
|
423 |
if($business_name==$key){
|
424 |
$sel = 'selected';
|
425 |
}
|
426 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
427 |
}
|
428 |
?>
|
429 |
</select>
|
430 |
</td>
|
431 |
</tr>
|
432 |
<tr class="saswp-healthandbeautybusiness-tr" <?php if(!array_key_exists($business_name, $all_health_and_beauty_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
433 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
434 |
<td>
|
435 |
<select class="saswp-local-sub-type-2" id="saswp_health_and_beauty" name="saswp_business_name">
|
436 |
<?php
|
441 |
if($business_name==$key){
|
442 |
$sel = 'selected';
|
443 |
}
|
444 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
445 |
}
|
446 |
?>
|
447 |
</select>
|
448 |
</td>
|
449 |
</tr>
|
450 |
<tr class="saswp-homeandconstructionbusiness-tr" <?php if(!array_key_exists($business_name, $all_home_and_construction_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
451 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
452 |
<td>
|
453 |
<select class="saswp-local-sub-type-2" id="saswp_home_and_construction" name="saswp_business_name">
|
454 |
<?php
|
458 |
if($business_name==$key){
|
459 |
$sel = 'selected';
|
460 |
}
|
461 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
462 |
}
|
463 |
?>
|
464 |
</select>
|
465 |
</td>
|
466 |
</tr>
|
467 |
<tr class="saswp-legalservice-tr" <?php if(!array_key_exists($business_name, $all_legal_service_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
468 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
469 |
<td>
|
470 |
<select class="saswp-local-sub-type-2" id="saswp_legal_service" name="saswp_business_name">
|
471 |
<?php
|
475 |
if($business_name==$key){
|
476 |
$sel = 'selected';
|
477 |
}
|
478 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
479 |
}
|
480 |
?>
|
481 |
</select>
|
482 |
</td>
|
483 |
</tr>
|
484 |
<tr class="saswp-lodgingbusiness-tr" <?php if(!array_key_exists($business_name, $all_lodging_array)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
485 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
486 |
<td>
|
487 |
<select class="saswp-local-sub-type-2" id="saswp_lodging" name="saswp_business_name">
|
488 |
<?php
|
492 |
if($business_name==$key){
|
493 |
$sel = 'selected';
|
494 |
}
|
495 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
496 |
}
|
497 |
?>
|
498 |
</select>
|
499 |
</td>
|
500 |
</tr>
|
501 |
<tr class="saswp-sportsactivitylocation-tr" <?php if(!array_key_exists($business_name, $all_sports_activity_location)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
502 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
503 |
<td>
|
504 |
<select class="saswp-local-sub-type-2" id="saswp_sports_activity_location" name="saswp_business_name">
|
505 |
<?php
|
509 |
if($business_name==$key){
|
510 |
$sel = 'selected';
|
511 |
}
|
512 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
513 |
}
|
514 |
?>
|
515 |
</select>
|
516 |
</td>
|
517 |
</tr>
|
518 |
<tr class="saswp-store-tr" <?php if(!array_key_exists($business_name, $all_store)){ echo 'style="display:none;"';}else{ echo $style_business_name;} ?>>
|
519 |
+
<td><?php echo saswp_t_string('Sub Business Type' ); ?></td>
|
520 |
<td>
|
521 |
<select class="saswp-local-sub-type-2" id="saswp_store" name="saswp_business_name">
|
522 |
<?php
|
527 |
if($business_name==$key){
|
528 |
$sel = 'selected';
|
529 |
}
|
530 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
531 |
}
|
532 |
?>
|
533 |
</select>
|
536 |
|
537 |
<!-- ItemList Schema type starts here -->
|
538 |
<tr class="saswp-itemlist-text-field-tr" <?php echo $style_review_name; ?>>
|
539 |
+
<td><?php echo saswp_t_string('Item Type' ); ?></td>
|
540 |
<td>
|
541 |
|
542 |
<select data-id="<?php if(is_object($post)){ echo esc_attr($post->ID); } ?>" name="saswp_itemlist_item_type" class="saswp-itemlist-item-type-list">
|
548 |
if($item == $key){
|
549 |
$sel = 'selected';
|
550 |
}
|
551 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
552 |
}
|
553 |
?>
|
554 |
</select>
|
558 |
|
559 |
<!-- Review Schema type starts here -->
|
560 |
<tr class="saswp-review-text-field-tr" <?php echo $style_review_name; ?>>
|
561 |
+
<td><?php echo saswp_t_string('Item Reviewed Type' ); ?></td>
|
562 |
<td>
|
563 |
|
564 |
<select data-id="<?php if(is_object($post)){ echo esc_attr($post->ID); } ?>" name="saswp_review_item_reviewed_<?php echo $post->ID; ?>" class="saswp-item-reivewed-list">
|
570 |
if($item == $key){
|
571 |
$sel = 'selected';
|
572 |
}
|
573 |
+
echo "<option value='".esc_attr($key)."' ".esc_attr($sel).">".saswp_t_string($value )."</option>";
|
574 |
}
|
575 |
?>
|
576 |
</select>
|
581 |
|
582 |
<tr>
|
583 |
<td>
|
584 |
+
<label for="saswp-itemlist"><?php echo saswp_t_string( 'ItemList ' );?></label>
|
585 |
</td>
|
586 |
<td>
|
587 |
<div class="saswp-enable-speakable">
|
621 |
<input type="text" id="saswp_item_list_custom" name="saswp_item_list_custom" placeholder="classname" value="<?php echo esc_attr($item_list_custom); ?>" class="<?php if($item_list_enable == 1 && $item_list_tags == 'custom'){echo ''; }else{ echo 'saswp_hide'; } ?>">
|
622 |
|
623 |
</div>
|
624 |
+
<p class="saspw-item-list-note <?php if($item_list_enable == 1){echo ''; }else{ echo 'saswp_hide'; } ?>"><?php echo saswp_t_string( 'It will collect all the data from selected tag to a itemlist' );?></p>
|
625 |
</div>
|
626 |
|
627 |
</td>
|
630 |
|
631 |
<tr>
|
632 |
<td>
|
633 |
+
<label for="saswp-speakable"><?php echo saswp_t_string( 'Speakable' );?></label>
|
634 |
</td>
|
635 |
<td>
|
636 |
<input class="saswp-enable-speakable" type="checkbox" name="saswp_enable_speakable_schema" value="1" <?php if(isset($speakable) && $speakable == 1){echo 'checked'; }else{ echo ''; } ?>>
|
639 |
|
640 |
<tr>
|
641 |
<td>
|
642 |
+
<label for="saswp-enable-markup"><?php echo saswp_t_string( 'Show Json-LD, Only if video is available' );?></label>
|
643 |
</td>
|
644 |
<td>
|
645 |
<input id="saswp-enable-markup" class="saswp-enable-markup-class" type="checkbox" name="saswp_enable_videoobject" value="1" <?php if(isset($enable_videoobject) && $enable_videoobject == 1){echo 'checked'; }else{ echo ''; } ?> >
|
648 |
|
649 |
<tr>
|
650 |
<td>
|
651 |
+
<label for="saswp-append-reviews"><?php echo saswp_t_string('Add Reviews' );?></label>
|
652 |
</td>
|
653 |
<td>
|
654 |
|
696 |
?>
|
697 |
</a>
|
698 |
<div style="display:none;" id="saswp-embed-code-div">
|
699 |
+
<div class="saswp-add-rv-title"><?php echo saswp_t_string('Get reviews attached to the schema type with three different method.' );?> <a target="_blank" href="https://structured-data-for-wp.com/docs/article/how-to-append-fetched-reviews-in-schema-markup/"><?php echo saswp_t_string('Learn More...' );?></a></div>
|
700 |
<div class="saswp-thick-box-container">
|
701 |
|
702 |
<div class="saswp-add-rv-popup" id="saswp-global-tabs">
|
703 |
<h2 class="nav-tab-wrapper">
|
704 |
+
<a class="nav-tab" data-id="saswp-add-rv-automatic"><?php echo saswp_t_string( 'Reviews' );?></a>
|
705 |
+
<a class="nav-tab" data-id="saswp-add-rv-collection"><?php echo saswp_t_string( 'Collection' );?></a>
|
706 |
+
<a class="nav-tab" data-id="saswp-add-rv-manual"><?php echo saswp_t_string( 'Shortcode' );?></a>
|
707 |
</h2>
|
708 |
</div>
|
709 |
|
710 |
<div class="saswp-global-container" id="saswp-add-rv-automatic">
|
711 |
+
<div class="saswp-add-rv-note"><strong><?php echo saswp_t_string( 'Note:' );?></strong> <span><?php echo saswp_t_string( 'The attached reviews will only be added in Json-ld' );?></span> </div>
|
712 |
<div data-type="review" class="saswp-add-rv-automatic-list">
|
713 |
|
714 |
<?php
|
743 |
echo '<input id="saswp_attahced_reviews" type="hidden" name="saswp_attahced_reviews" value="'. esc_attr($attached_rv_json).'">';
|
744 |
?>
|
745 |
|
746 |
+
<div class="saswp-rv-not-found saswp_hide" data-type="review"><?php echo saswp_t_string( 'Reviews not found' );?></div>
|
747 |
<span class="spinner" data-type="review"></span>
|
748 |
+
<div><a class="saswp-load-more-rv" data-type="review"><?php echo saswp_t_string( 'Load More...' );?></a></div>
|
749 |
|
750 |
</div>
|
751 |
|
752 |
<div class="saswp-global-container" id="saswp-add-rv-collection">
|
753 |
+
<div class="saswp-add-rv-note"><strong>Note:</strong> <span><?php echo saswp_t_string( 'The attached collection will only be added in Json-ld' );?></span> </div>
|
754 |
<div data-type="collection" class="saswp-add-rv-automatic-list">
|
755 |
|
756 |
<?php
|
784 |
echo '<input id="saswp_attached_collection" type="hidden" name="saswp_attached_collection" value="'. esc_attr($attached_col_json).'">';
|
785 |
?>
|
786 |
|
787 |
+
<div class="saswp-rv-not-found saswp_hide" data-type="collection"><?php echo saswp_t_string( 'Reviews not found' );?></div>
|
788 |
<span class="spinner" data-type="collection"></span>
|
789 |
+
<div><a class="saswp-load-more-rv" data-type="collection"><?php echo saswp_t_string( 'Load More...' );?></a></div>
|
790 |
|
791 |
</div>
|
792 |
|
793 |
<div class="saswp-global-container" id="saswp-add-rv-manual">
|
794 |
+
<p> <?php echo saswp_t_string('Output reviews in front and its schema markup in source by using below shortcode' );?> </p>
|
795 |
<strong>[saswp-reviews]</strong><br>OR<br>
|
796 |
<strong>[saswp-reviews-collection id="your collection id"]</strong>
|
797 |
</div>
|
798 |
+
<a class="button button-default close-attached-reviews-popup"><?php echo saswp_t_string( 'OK' );?></a>
|
799 |
</div>
|
800 |
|
801 |
</div>
|
814 |
<table class="option-table-class saswp_modify_schema_checkbox">
|
815 |
<tr>
|
816 |
<td>
|
817 |
+
<a class="button button-default saswp-modify-schema-toggle"><?php echo saswp_t_string( 'Modify Schema Output' ) ?></a>
|
818 |
<input type="hidden" name="saswp_enable_custom_field" id="saswp_enable_custom_field" value="<?php echo isset($schema_options['enable_custom_field']) ? $schema_options['enable_custom_field']:'0'; ?>">
|
819 |
</td>
|
820 |
</tr>
|
832 |
echo '<div class="saswp-enable-modify-schema saswp_hide">';
|
833 |
}
|
834 |
|
835 |
+
echo '<strong>'.saswp_t_string( 'Choose Method' ).'</strong>';
|
836 |
echo '<select name="saswp_modify_method" class="saswp-enable-modify-schema-output">';
|
837 |
|
838 |
$method_option = array(
|
987 |
echo '<td><input type="text" name="saswp_fixed_text['.esc_attr($fieldkey).']" value="'.(isset($fixed_text[$fieldkey]) ? esc_html($fixed_text[$fieldkey]) :'').'"></td>';
|
988 |
}else if($fieldval == 'taxonomy_term'){
|
989 |
|
990 |
+
$choices = array('all' => saswp_t_string('All'));
|
991 |
$taxonomies = saswp_post_taxonomy_generator();
|
992 |
$choices = array_merge($choices, $taxonomies);
|
993 |
|
1058 |
|
1059 |
</table>
|
1060 |
<table class="option-table-class">
|
1061 |
+
<tr><td><a class="button button-primary saswp-add-custom-fields"><?php echo saswp_t_string( 'Add Property' ); ?></a></td><td></td></tr>
|
1062 |
</table>
|
1063 |
|
1064 |
</div>
|