Version Description
- New: Added a new option to Reapeat Ad After nth Paragraph #118
- New: Added a URL of the site so it's easier to help user #78
- Fix: Incorrect stying and wrong tab opening #130
- Fix: WPadmin toolbar has an invalid attribute in the AMP #129
- Fix: Align and Margin are not working in AMP #131
Download this release
Release Info
Developer | wpquads |
Plugin | AdSense Plugin WP QUADS |
Version | 2.0.7 |
Comparing to | |
See all releases |
Code changes from version 2.0.6 to 2.0.7
- admin/assets/js/dist/adminscript.js +17 -7
- admin/assets/js/dist/style.css +19 -1
- admin/assets/js/src/components/ads/targeting/QuadsAdTargeting.jsx +1 -1
- admin/assets/js/src/components/ads/targeting/QuadsAdTargeting.scss +14 -0
- admin/assets/js/src/components/common/advance-position/QuadsAdvancePosition.jsx +11 -3
- admin/assets/js/src/components/common/advance-position/QuadsAdvancePosition.scss +6 -0
- admin/assets/js/src/components/common/layout/QuadsLayout.jsx +2 -2
- admin/assets/js/src/style/common.scss +1 -1
- admin/includes/rest-api.php +1 -1
- includes/admin/plugins.php +1 -1
- includes/admin/settings/register-settings.php +1 -1
- includes/frontend-checks.php +1 -3
- includes/scripts.php +9 -4
- includes/template-functions.php +9 -4
- package.json +1 -1
- quick-adsense-reloaded.php +2 -2
- readme.txt +8 -1
admin/assets/js/dist/adminscript.js
CHANGED
@@ -60992,9 +60992,9 @@ var QuadsLayout = /*#__PURE__*/function (_Component) {
|
|
60992 |
onChange: this.props.adFormChangeHandler
|
60993 |
}, /*#__PURE__*/_react["default"].createElement("option", {
|
60994 |
value: "above"
|
60995 |
-
}, __('Above
|
60996 |
value: "below"
|
60997 |
-
}, __('Below
|
60998 |
onChange: this.props.adFormChangeHandler,
|
60999 |
type: "text",
|
61000 |
className: "small-text",
|
@@ -61098,7 +61098,9 @@ var QuadsAdTargeting = /*#__PURE__*/function (_Component) {
|
|
61098 |
className: "quads-panel"
|
61099 |
}, /*#__PURE__*/_react["default"].createElement("div", {
|
61100 |
className: "quads-panel-body"
|
61101 |
-
}, /*#__PURE__*/_react["default"].createElement("table", null, /*#__PURE__*/_react["default"].createElement("tbody", null, /*#__PURE__*/_react["default"].createElement("tr",
|
|
|
|
|
61102 |
parentState: this.props.parentState,
|
61103 |
adFormChangeHandler: this.props.adFormChangeHandler
|
61104 |
})))))))), post_meta.position != 'ad_shortcode' ? /*#__PURE__*/_react["default"].createElement(_QuadsVisibility["default"], {
|
@@ -63267,21 +63269,29 @@ var QuadsAdvancePosition = /*#__PURE__*/function (_Component) {
|
|
63267 |
name: "image_number",
|
63268 |
value: post_meta.image_number,
|
63269 |
type: "number"
|
63270 |
-
}) : ''), /*#__PURE__*/_react["default"].createElement("div", null, post_meta.position == 'after_paragraph' ? /*#__PURE__*/_react["default"].createElement("label", null, post_meta.position == 'after_paragraph' ? /*#__PURE__*/_react["default"].createElement("input", {
|
63271 |
min: "1",
|
63272 |
onChange: this.props.adFormChangeHandler,
|
63273 |
name: "paragraph_number",
|
63274 |
value: post_meta.paragraph_number,
|
63275 |
type: "number"
|
63276 |
-
}) : '', /*#__PURE__*/_react["default"].createElement("
|
|
|
|
|
63277 |
id: "enable_on_end_of_post",
|
63278 |
checked: post_meta.enable_on_end_of_post,
|
63279 |
name: "enable_on_end_of_post",
|
63280 |
onChange: this.props.adFormChangeHandler,
|
63281 |
type: "checkbox"
|
|
|
|
|
|
|
|
|
|
|
|
|
63282 |
}), /*#__PURE__*/_react["default"].createElement("label", {
|
63283 |
-
"for": "
|
63284 |
-
},
|
63285 |
checked: post_meta.image_caption,
|
63286 |
name: "image_caption",
|
63287 |
onChange: this.props.adFormChangeHandler,
|
60992 |
onChange: this.props.adFormChangeHandler
|
60993 |
}, /*#__PURE__*/_react["default"].createElement("option", {
|
60994 |
value: "above"
|
60995 |
+
}, __('Above Ad', 'quick-adsense-reloaded')), /*#__PURE__*/_react["default"].createElement("option", {
|
60996 |
value: "below"
|
60997 |
+
}, __('Below Ad', 'quick-adsense-reloaded'))))) : null, post_meta.ad_label_check ? /*#__PURE__*/_react["default"].createElement("tr", null, /*#__PURE__*/_react["default"].createElement("td", null, /*#__PURE__*/_react["default"].createElement("label", null, __('Ad Label Text', 'quick-adsense-reloaded'))), /*#__PURE__*/_react["default"].createElement("td", null, /*#__PURE__*/_react["default"].createElement("input", {
|
60998 |
onChange: this.props.adFormChangeHandler,
|
60999 |
type: "text",
|
61000 |
className: "small-text",
|
61098 |
className: "quads-panel"
|
61099 |
}, /*#__PURE__*/_react["default"].createElement("div", {
|
61100 |
className: "quads-panel-body"
|
61101 |
+
}, /*#__PURE__*/_react["default"].createElement("table", null, /*#__PURE__*/_react["default"].createElement("tbody", null, /*#__PURE__*/_react["default"].createElement("tr", {
|
61102 |
+
className: "quads-tr-position"
|
61103 |
+
}, /*#__PURE__*/_react["default"].createElement("td", null, /*#__PURE__*/_react["default"].createElement("label", null, __('Where will the AD appear?', 'quick-adsense-reloaded'))), /*#__PURE__*/_react["default"].createElement("td", null, /*#__PURE__*/_react["default"].createElement(_QuadsAdvancePosition["default"], {
|
61104 |
parentState: this.props.parentState,
|
61105 |
adFormChangeHandler: this.props.adFormChangeHandler
|
61106 |
})))))))), post_meta.position != 'ad_shortcode' ? /*#__PURE__*/_react["default"].createElement(_QuadsVisibility["default"], {
|
63269 |
name: "image_number",
|
63270 |
value: post_meta.image_number,
|
63271 |
type: "number"
|
63272 |
+
}) : ''), /*#__PURE__*/_react["default"].createElement("div", null, post_meta.position == 'after_paragraph' ? /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("label", null, post_meta.position == 'after_paragraph' ? /*#__PURE__*/_react["default"].createElement("input", {
|
63273 |
min: "1",
|
63274 |
onChange: this.props.adFormChangeHandler,
|
63275 |
name: "paragraph_number",
|
63276 |
value: post_meta.paragraph_number,
|
63277 |
type: "number"
|
63278 |
+
}) : ''), /*#__PURE__*/_react["default"].createElement("label", {
|
63279 |
+
"for": "enable_on_end_of_post"
|
63280 |
+
}, /*#__PURE__*/_react["default"].createElement("input", {
|
63281 |
id: "enable_on_end_of_post",
|
63282 |
checked: post_meta.enable_on_end_of_post,
|
63283 |
name: "enable_on_end_of_post",
|
63284 |
onChange: this.props.adFormChangeHandler,
|
63285 |
type: "checkbox"
|
63286 |
+
}), __('to', 'quick-adsense-reloaded'), " ", /*#__PURE__*/_react["default"].createElement("strong", null, __('End of Post', 'quick-adsense-reloaded')), " ", __('if fewer paragraphs', 'quick-adsense-reloaded'))), /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement("input", {
|
63287 |
+
id: "repeat_paragraph",
|
63288 |
+
checked: post_meta.repeat_paragraph,
|
63289 |
+
name: "repeat_paragraph",
|
63290 |
+
onChange: this.props.adFormChangeHandler,
|
63291 |
+
type: "checkbox"
|
63292 |
}), /*#__PURE__*/_react["default"].createElement("label", {
|
63293 |
+
"for": "repeat_paragraph"
|
63294 |
+
}, " ", __('Display After Every ', 'quick-adsense-reloaded'), post_meta.paragraph_number))) : '', post_meta.position == 'after_image' ? /*#__PURE__*/_react["default"].createElement("label", null, /*#__PURE__*/_react["default"].createElement("input", {
|
63295 |
checked: post_meta.image_caption,
|
63296 |
name: "image_caption",
|
63297 |
onChange: this.props.adFormChangeHandler,
|
admin/assets/js/dist/style.css
CHANGED
@@ -211,6 +211,18 @@ and open the template in the editor.
|
|
211 |
padding: 5px;
|
212 |
border-radius: 4px;
|
213 |
cursor: pointer; }
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
214 |
.quads-user-targeting table td {
|
215 |
width: 25%; }
|
216 |
|
@@ -253,6 +265,12 @@ and open the template in the editor.
|
|
253 |
|
254 |
#post_shortcode_php {
|
255 |
width: 380px; }
|
|
|
|
|
|
|
|
|
|
|
|
|
256 |
/*
|
257 |
To change this license header, choose License Headers in Project Properties.
|
258 |
To change this template file, choose Tools | Templates
|
@@ -443,7 +461,7 @@ and open the template in the editor.
|
|
443 |
font-family: inherit;
|
444 |
background-color: transparent;
|
445 |
width: 225px;
|
446 |
-
height:
|
447 |
padding: 7px 10px 7px 20px;
|
448 |
font-size: 18px;
|
449 |
border-radius: 0;
|
211 |
padding: 5px;
|
212 |
border-radius: 4px;
|
213 |
cursor: pointer; }
|
214 |
+
|
215 |
+
.quads-panel-body tr.quads-tr-position {
|
216 |
+
display: inline-flex; }
|
217 |
+
|
218 |
+
.quads-panel-body td:nth-child(1) {
|
219 |
+
margin-top: 15px; }
|
220 |
+
|
221 |
+
.position_content div label {
|
222 |
+
padding: 10px; }
|
223 |
+
|
224 |
+
.position_content div {
|
225 |
+
padding-bottom: 15px !important; }
|
226 |
.quads-user-targeting table td {
|
227 |
width: 25%; }
|
228 |
|
265 |
|
266 |
#post_shortcode_php {
|
267 |
width: 380px; }
|
268 |
+
|
269 |
+
.position_content div {
|
270 |
+
padding-bottom: 5px; }
|
271 |
+
|
272 |
+
#repeat_paragraph + label {
|
273 |
+
text-transform: none; }
|
274 |
/*
|
275 |
To change this license header, choose License Headers in Project Properties.
|
276 |
To change this template file, choose Tools | Templates
|
461 |
font-family: inherit;
|
462 |
background-color: transparent;
|
463 |
width: 225px;
|
464 |
+
height: 50px;
|
465 |
padding: 7px 10px 7px 20px;
|
466 |
font-size: 18px;
|
467 |
border-radius: 0;
|
admin/assets/js/src/components/ads/targeting/QuadsAdTargeting.jsx
CHANGED
@@ -29,7 +29,7 @@ class QuadsAdTargeting extends Component {
|
|
29 |
<div className="quads-panel-body">
|
30 |
<table>
|
31 |
<tbody>
|
32 |
-
<tr>
|
33 |
<td><label>{__('Where will the AD appear?', 'quick-adsense-reloaded')}</label></td>
|
34 |
<td><QuadsAdvancePosition parentState={this.props.parentState} adFormChangeHandler = {this.props.adFormChangeHandler}/></td>
|
35 |
</tr>
|
29 |
<div className="quads-panel-body">
|
30 |
<table>
|
31 |
<tbody>
|
32 |
+
<tr className="quads-tr-position">
|
33 |
<td><label>{__('Where will the AD appear?', 'quick-adsense-reloaded')}</label></td>
|
34 |
<td><QuadsAdvancePosition parentState={this.props.parentState} adFormChangeHandler = {this.props.adFormChangeHandler}/></td>
|
35 |
</tr>
|
admin/assets/js/src/components/ads/targeting/QuadsAdTargeting.scss
CHANGED
@@ -19,4 +19,18 @@ and open the template in the editor.
|
|
19 |
padding: 5px;
|
20 |
border-radius: 4px;
|
21 |
cursor: pointer;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
22 |
}
|
19 |
padding: 5px;
|
20 |
border-radius: 4px;
|
21 |
cursor: pointer;
|
22 |
+
}
|
23 |
+
|
24 |
+
.quads-panel-body tr.quads-tr-position{
|
25 |
+
display: inline-flex;
|
26 |
+
}
|
27 |
+
|
28 |
+
.quads-panel-body td:nth-child(1) {
|
29 |
+
margin-top: 15px;
|
30 |
+
}
|
31 |
+
.position_content div label{
|
32 |
+
padding: 10px;
|
33 |
+
}
|
34 |
+
.position_content div {
|
35 |
+
padding-bottom: 15px !important;
|
36 |
}
|
admin/assets/js/src/components/common/advance-position/QuadsAdvancePosition.jsx
CHANGED
@@ -69,12 +69,20 @@ class QuadsAdvancePosition extends Component {
|
|
69 |
<div>
|
70 |
|
71 |
{post_meta.position == 'after_paragraph' ?
|
|
|
|
|
72 |
<label>
|
73 |
{post_meta.position == 'after_paragraph' ? <input min="1" onChange={this.props.adFormChangeHandler} name="paragraph_number" value={post_meta.paragraph_number} type="number" /> : ''}
|
74 |
-
|
75 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
76 |
|
77 |
-
|
78 |
|
79 |
{post_meta.position == 'after_image' ?
|
80 |
<label>
|
69 |
<div>
|
70 |
|
71 |
{post_meta.position == 'after_paragraph' ?
|
72 |
+
<div>
|
73 |
+
<div>
|
74 |
<label>
|
75 |
{post_meta.position == 'after_paragraph' ? <input min="1" onChange={this.props.adFormChangeHandler} name="paragraph_number" value={post_meta.paragraph_number} type="number" /> : ''}
|
76 |
+
|
77 |
+
</label>
|
78 |
+
<label for="enable_on_end_of_post">
|
79 |
+
<input id='enable_on_end_of_post' checked={post_meta.enable_on_end_of_post} name="enable_on_end_of_post" onChange={this.props.adFormChangeHandler} type="checkbox"/>
|
80 |
+
{__('to', 'quick-adsense-reloaded')} <strong>{__('End of Post', 'quick-adsense-reloaded')}</strong> {__('if fewer paragraphs', 'quick-adsense-reloaded')}</label>
|
81 |
+
</div><div>
|
82 |
+
<input id='repeat_paragraph' checked={post_meta.repeat_paragraph} name="repeat_paragraph" onChange={this.props.adFormChangeHandler} type="checkbox"/>
|
83 |
+
<label for="repeat_paragraph"> {__('Display After Every ', 'quick-adsense-reloaded')}{post_meta.paragraph_number}</label>
|
84 |
|
85 |
+
</div></div> : ''}
|
86 |
|
87 |
{post_meta.position == 'after_image' ?
|
88 |
<label>
|
admin/assets/js/src/components/common/advance-position/QuadsAdvancePosition.scss
CHANGED
@@ -21,4 +21,10 @@ and open the template in the editor.
|
|
21 |
}
|
22 |
#post_shortcode_php{
|
23 |
width:380px;
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
}
|
21 |
}
|
22 |
#post_shortcode_php{
|
23 |
width:380px;
|
24 |
+
}
|
25 |
+
.position_content div {
|
26 |
+
padding-bottom: 5px;
|
27 |
+
}
|
28 |
+
#repeat_paragraph+label {
|
29 |
+
text-transform: none;
|
30 |
}
|
admin/assets/js/src/components/common/layout/QuadsLayout.jsx
CHANGED
@@ -45,8 +45,8 @@ class QuadsLayout extends Component {
|
|
45 |
<td><label>{__('Ad Label Position', 'quick-adsense-reloaded')}</label></td>
|
46 |
<td>
|
47 |
<select name="adlabel" value={post_meta.adlabel} onChange={this.props.adFormChangeHandler}>
|
48 |
-
<option value="above">{__('Above
|
49 |
-
<option value="below">{__('Below
|
50 |
</select>
|
51 |
</td>
|
52 |
</tr>
|
45 |
<td><label>{__('Ad Label Position', 'quick-adsense-reloaded')}</label></td>
|
46 |
<td>
|
47 |
<select name="adlabel" value={post_meta.adlabel} onChange={this.props.adFormChangeHandler}>
|
48 |
+
<option value="above">{__('Above Ad', 'quick-adsense-reloaded')}</option>
|
49 |
+
<option value="below">{__('Below Ad', 'quick-adsense-reloaded')}</option>
|
50 |
</select>
|
51 |
</td>
|
52 |
</tr>
|
admin/assets/js/src/style/common.scss
CHANGED
@@ -188,7 +188,7 @@ and open the template in the editor.
|
|
188 |
font-family: inherit;
|
189 |
background-color: transparent;
|
190 |
width: 225px;
|
191 |
-
height:
|
192 |
padding: 7px 10px 7px 20px;
|
193 |
font-size: 18px;
|
194 |
border-radius: 0;
|
188 |
font-family: inherit;
|
189 |
background-color: transparent;
|
190 |
width: 225px;
|
191 |
+
height:50px;
|
192 |
padding: 7px 10px 7px 20px;
|
193 |
font-size: 18px;
|
194 |
border-radius: 0;
|
admin/includes/rest-api.php
CHANGED
@@ -317,7 +317,7 @@ class QUADS_Ad_Setup_Api {
|
|
317 |
|
318 |
$message = '<p>'.$message.'</p><br><br>'
|
319 |
. $customer_type
|
320 |
-
. '<br><br>'.'Query from WP Quads plugin support tab';
|
321 |
|
322 |
if($email && $message){
|
323 |
|
317 |
|
318 |
$message = '<p>'.$message.'</p><br><br>'
|
319 |
. $customer_type
|
320 |
+
. '<br><br>'.'Query from WP Quads plugin support tab <br> User Website URL: '.site_url();
|
321 |
|
322 |
if($email && $message){
|
323 |
|
includes/admin/plugins.php
CHANGED
@@ -24,7 +24,7 @@ if ( ! defined( 'ABSPATH' ) ) exit;
|
|
24 |
* @return array $links
|
25 |
*/
|
26 |
function quads_plugin_action_links( $links, $file ) {
|
27 |
-
$settings_link = '<a href="' . admin_url( '
|
28 |
|
29 |
if ( $file == 'quick-adsense-reloaded/quick-adsense-reloaded.php' || $file == 'quads-pro/wpquads-pro.php' ){
|
30 |
array_unshift( $links, $settings_link );
|
24 |
* @return array $links
|
25 |
*/
|
26 |
function quads_plugin_action_links( $links, $file ) {
|
27 |
+
$settings_link = '<a href="' . admin_url( 'admin.php?page=quads-settings' ) . '">' . esc_html__( 'General Settings', 'quick-adsense-reloaded' ) . '</a>';
|
28 |
|
29 |
if ( $file == 'quick-adsense-reloaded/quick-adsense-reloaded.php' || $file == 'quads-pro/wpquads-pro.php' ){
|
30 |
array_unshift( $links, $settings_link );
|
includes/admin/settings/register-settings.php
CHANGED
@@ -477,7 +477,7 @@ function wpquads_send_query_message(){
|
|
477 |
$customer_type = 'Are you a premium customer ? Yes';
|
478 |
}
|
479 |
|
480 |
-
$message = '<p>'.$message.'</p><br><br>'. $customer_type. '<br><br> query from WPQuads support tab';
|
481 |
|
482 |
if($user){
|
483 |
$user_data = $user->data;
|
477 |
$customer_type = 'Are you a premium customer ? Yes';
|
478 |
}
|
479 |
|
480 |
+
$message = '<p>'.$message.'</p><br><br>'. $customer_type. '<br><br> query from WPQuads support tab <br> User Website URL: '.site_url();
|
481 |
|
482 |
if($user){
|
483 |
$user_data = $user->data;
|
includes/frontend-checks.php
CHANGED
@@ -179,9 +179,7 @@ function quads_add_admin_bar_menu( $wp_admin_bar ) {
|
|
179 |
'id' => 'quads_ad_check_fine',
|
180 |
'title' => __( 'WP QUADS is working fine', 'quick-adsense-reloaded' ),
|
181 |
'href' => false,
|
182 |
-
|
183 |
-
'target' => '_blank',
|
184 |
-
)
|
185 |
) );
|
186 |
}
|
187 |
|
179 |
'id' => 'quads_ad_check_fine',
|
180 |
'title' => __( 'WP QUADS is working fine', 'quick-adsense-reloaded' ),
|
181 |
'href' => false,
|
182 |
+
|
|
|
|
|
183 |
) );
|
184 |
}
|
185 |
|
includes/scripts.php
CHANGED
@@ -14,6 +14,7 @@ if( !defined( 'ABSPATH' ) )
|
|
14 |
|
15 |
//add_action( 'wp_enqueue_scripts', 'quads_register_styles', 10 );
|
16 |
add_action( 'wp_print_styles', 'quads_inline_styles', 9999 );
|
|
|
17 |
|
18 |
add_action( 'admin_enqueue_scripts', 'quads_load_admin_scripts', 100 );
|
19 |
add_action( 'admin_enqueue_scripts', 'quads_load_plugins_admin_scripts', 100 );
|
@@ -126,8 +127,8 @@ if(is_object($screens)){
|
|
126 |
wp_enqueue_script( 'quads-vi', $vi_dir . 'vi.js', array(), QUADS_VERSION, false );
|
127 |
|
128 |
|
129 |
-
wp_enqueue_style( 'quads-admin', $css_dir . 'quads-admin' . $suffix . '.css', QUADS_VERSION );
|
130 |
-
wp_enqueue_style( 'jquery-chosen', $css_dir . 'chosen' . $suffix . '.css', QUADS_VERSION );
|
131 |
|
132 |
$signupURL = $quads->vi->getSettings()->data->signupURL;
|
133 |
|
@@ -166,7 +167,7 @@ function quads_load_plugins_admin_scripts( $hook ) {
|
|
166 |
$suffix = ( quadsIsDebugMode() ) ? '' : '.min';
|
167 |
|
168 |
wp_enqueue_script( 'quads-plugins-admin-scripts', $js_dir . 'quads-plugins-admin' . $suffix . '.js', array('jquery'), QUADS_VERSION, false );
|
169 |
-
wp_enqueue_style( 'quads-plugins-admin', $css_dir . 'quads-plugins-admin' . $suffix . '.css', QUADS_VERSION );
|
170 |
}
|
171 |
|
172 |
/**
|
@@ -184,7 +185,7 @@ function quads_load_all_admin_scripts( $hook ) {
|
|
184 |
|
185 |
$css_dir = QUADS_PLUGIN_URL . 'assets/css/';
|
186 |
|
187 |
-
wp_enqueue_style( 'quads-admin-all', $css_dir . 'quads-admin-all.css', QUADS_VERSION );
|
188 |
}
|
189 |
|
190 |
|
@@ -227,12 +228,16 @@ function quads_inline_styles() {
|
|
227 |
$css .= quads_render_media_query( $key, $value );
|
228 |
}
|
229 |
}
|
|
|
230 |
// Register empty style so we do not need an external css file
|
231 |
wp_register_style( 'quads-styles', false );
|
232 |
// Enque empty style
|
233 |
wp_enqueue_style( 'quads-styles' );
|
234 |
// Add inline css to that style
|
235 |
wp_add_inline_style( 'quads-styles', $css );
|
|
|
|
|
|
|
236 |
}
|
237 |
|
238 |
/**
|
14 |
|
15 |
//add_action( 'wp_enqueue_scripts', 'quads_register_styles', 10 );
|
16 |
add_action( 'wp_print_styles', 'quads_inline_styles', 9999 );
|
17 |
+
add_action('amp_post_template_css','quads_inline_styles', 11);
|
18 |
|
19 |
add_action( 'admin_enqueue_scripts', 'quads_load_admin_scripts', 100 );
|
20 |
add_action( 'admin_enqueue_scripts', 'quads_load_plugins_admin_scripts', 100 );
|
127 |
wp_enqueue_script( 'quads-vi', $vi_dir . 'vi.js', array(), QUADS_VERSION, false );
|
128 |
|
129 |
|
130 |
+
wp_enqueue_style( 'quads-admin', $css_dir . 'quads-admin' . $suffix . '.css',array(), QUADS_VERSION );
|
131 |
+
wp_enqueue_style( 'jquery-chosen', $css_dir . 'chosen' . $suffix . '.css',array(), QUADS_VERSION );
|
132 |
|
133 |
$signupURL = $quads->vi->getSettings()->data->signupURL;
|
134 |
|
167 |
$suffix = ( quadsIsDebugMode() ) ? '' : '.min';
|
168 |
|
169 |
wp_enqueue_script( 'quads-plugins-admin-scripts', $js_dir . 'quads-plugins-admin' . $suffix . '.js', array('jquery'), QUADS_VERSION, false );
|
170 |
+
wp_enqueue_style( 'quads-plugins-admin', $css_dir . 'quads-plugins-admin' . $suffix . '.css', array(),QUADS_VERSION );
|
171 |
}
|
172 |
|
173 |
/**
|
185 |
|
186 |
$css_dir = QUADS_PLUGIN_URL . 'assets/css/';
|
187 |
|
188 |
+
wp_enqueue_style( 'quads-admin-all', $css_dir . 'quads-admin-all.css',array(), QUADS_VERSION );
|
189 |
}
|
190 |
|
191 |
|
228 |
$css .= quads_render_media_query( $key, $value );
|
229 |
}
|
230 |
}
|
231 |
+
$css .=".quads-ad-label { font-size: 12px; text-align: center; color: #333;}";
|
232 |
// Register empty style so we do not need an external css file
|
233 |
wp_register_style( 'quads-styles', false );
|
234 |
// Enque empty style
|
235 |
wp_enqueue_style( 'quads-styles' );
|
236 |
// Add inline css to that style
|
237 |
wp_add_inline_style( 'quads-styles', $css );
|
238 |
+
if (quads_is_amp_endpoint()){
|
239 |
+
echo $css;
|
240 |
+
}
|
241 |
}
|
242 |
|
243 |
/**
|
includes/template-functions.php
CHANGED
@@ -459,8 +459,9 @@ function quads_filter_default_ads_new( $content ) {
|
|
459 |
if(strpos( $content, '<!--OffBfLastPara-->' ) === false ) {
|
460 |
$closing_p = '</p>';
|
461 |
$paragraphs = explode( $closing_p, $content );
|
462 |
-
$p_count = count($paragraphs);
|
463 |
-
|
|
|
464 |
if($paragraph_no <= $p_count){
|
465 |
|
466 |
foreach ($paragraphs as $index => $paragraph) {
|
@@ -468,7 +469,11 @@ function quads_filter_default_ads_new( $content ) {
|
|
468 |
$paragraphs[$index] .= $closing_p;
|
469 |
}
|
470 |
if ( $paragraph_no == $index + 1 ) {
|
|
|
471 |
$paragraphs[$index] .= $cusads;
|
|
|
|
|
|
|
472 |
}
|
473 |
}
|
474 |
$content = implode( '', $paragraphs );
|
@@ -1183,7 +1188,7 @@ function quads_get_inline_ad_style( $id ) {
|
|
1183 |
//wp_die('ad'.$id);
|
1184 |
|
1185 |
// Do not create any inline style on AMP site
|
1186 |
-
$style =
|
1187 |
|
1188 |
return $style;
|
1189 |
}
|
@@ -1211,7 +1216,7 @@ function quads_get_inline_ad_style_new( $id ) {
|
|
1211 |
$margin = sprintf( $styleArray[$adsalign], $adsmargin );
|
1212 |
|
1213 |
// Do not create any inline style on AMP site
|
1214 |
-
$style =
|
1215 |
|
1216 |
return $style;
|
1217 |
}
|
459 |
if(strpos( $content, '<!--OffBfLastPara-->' ) === false ) {
|
460 |
$closing_p = '</p>';
|
461 |
$paragraphs = explode( $closing_p, $content );
|
462 |
+
$p_count = count($paragraphs);
|
463 |
+
$original_paragraph_no = $paragraph_no;
|
464 |
+
$repeat_paragraph = (isset($ads['repeat_paragraph']) && !empty($ads['repeat_paragraph'])) ? $ads['repeat_paragraph'] : false;
|
465 |
if($paragraph_no <= $p_count){
|
466 |
|
467 |
foreach ($paragraphs as $index => $paragraph) {
|
469 |
$paragraphs[$index] .= $closing_p;
|
470 |
}
|
471 |
if ( $paragraph_no == $index + 1 ) {
|
472 |
+
// exit(var_dump($index));
|
473 |
$paragraphs[$index] .= $cusads;
|
474 |
+
if($repeat_paragraph){
|
475 |
+
$paragraph_no = $original_paragraph_no+$paragraph_no;
|
476 |
+
}
|
477 |
}
|
478 |
}
|
479 |
$content = implode( '', $paragraphs );
|
1188 |
//wp_die('ad'.$id);
|
1189 |
|
1190 |
// Do not create any inline style on AMP site
|
1191 |
+
$style = apply_filters( 'quads_filter_margins', $margin, 'ad' . $id );
|
1192 |
|
1193 |
return $style;
|
1194 |
}
|
1216 |
$margin = sprintf( $styleArray[$adsalign], $adsmargin );
|
1217 |
|
1218 |
// Do not create any inline style on AMP site
|
1219 |
+
$style = apply_filters( 'quads_filter_margins', $margin, 'ad' . $id ) ;
|
1220 |
|
1221 |
return $style;
|
1222 |
}
|
package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
{
|
2 |
"name": "quick-adsense-reloaded",
|
3 |
-
"version": "2.0.
|
4 |
"devDependencies": {
|
5 |
"grunt": "~0.4.5",
|
6 |
"grunt-contrib-clean": "~0.6.0",
|
1 |
{
|
2 |
"name": "quick-adsense-reloaded",
|
3 |
+
"version": "2.0.7",
|
4 |
"devDependencies": {
|
5 |
"grunt": "~0.4.5",
|
6 |
"grunt-contrib-clean": "~0.6.0",
|
quick-adsense-reloaded.php
CHANGED
@@ -6,7 +6,7 @@
|
|
6 |
* Description: Insert Google AdSense and other ad formats fully automatic into your website
|
7 |
* Author: WP Quads
|
8 |
* Author URI: https://wordpress.org/plugins/quick-adsense-reloaded/
|
9 |
-
* Version: 2.0.
|
10 |
* Text Domain: quick-adsense-reloaded
|
11 |
* Domain Path: languages
|
12 |
* Credits: WP QUADS - Quick AdSense Reloaded is a fork of Quick AdSense
|
@@ -38,7 +38,7 @@ if( !defined( 'ABSPATH' ) )
|
|
38 |
|
39 |
// Plugin version
|
40 |
if( !defined( 'QUADS_VERSION' ) ) {
|
41 |
-
define( 'QUADS_VERSION', '2.0.
|
42 |
}
|
43 |
|
44 |
// Plugin name
|
6 |
* Description: Insert Google AdSense and other ad formats fully automatic into your website
|
7 |
* Author: WP Quads
|
8 |
* Author URI: https://wordpress.org/plugins/quick-adsense-reloaded/
|
9 |
+
* Version: 2.0.7
|
10 |
* Text Domain: quick-adsense-reloaded
|
11 |
* Domain Path: languages
|
12 |
* Credits: WP QUADS - Quick AdSense Reloaded is a fork of Quick AdSense
|
38 |
|
39 |
// Plugin version
|
40 |
if( !defined( 'QUADS_VERSION' ) ) {
|
41 |
+
define( 'QUADS_VERSION', '2.0.7' );
|
42 |
}
|
43 |
|
44 |
// Plugin name
|
readme.txt
CHANGED
@@ -10,7 +10,7 @@ Tags: adsense, ads, ad, google adsense, advertising, amp, ad injection, ad inser
|
|
10 |
Requires at least: 3.6+
|
11 |
Tested up to: 5.4
|
12 |
Requires PHP: 5.3
|
13 |
-
Stable tag: 2.0.
|
14 |
|
15 |
Ads & AdSense Plugin is the quickest way to insert Google AdSense & other ads into your website. Google AdSense integration with Google AMP support.
|
16 |
|
@@ -129,6 +129,13 @@ Alternative Installation:
|
|
129 |
|
130 |
|
131 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
132 |
= 2.0.6 =
|
133 |
* New: Added ad label for individual post in new interface #117
|
134 |
* New: Added a tutorial link in the Adsense #116
|
10 |
Requires at least: 3.6+
|
11 |
Tested up to: 5.4
|
12 |
Requires PHP: 5.3
|
13 |
+
Stable tag: 2.0.7
|
14 |
|
15 |
Ads & AdSense Plugin is the quickest way to insert Google AdSense & other ads into your website. Google AdSense integration with Google AMP support.
|
16 |
|
129 |
|
130 |
|
131 |
== Changelog ==
|
132 |
+
= 2.0.7 =
|
133 |
+
* New: Added a new option to Reapeat Ad After nth Paragraph #118
|
134 |
+
* New: Added a URL of the site so it's easier to help user #78
|
135 |
+
* Fix: Incorrect stying and wrong tab opening #130
|
136 |
+
* Fix: WPadmin toolbar has an invalid attribute in the AMP #129
|
137 |
+
* Fix: Align and Margin are not working in AMP #131
|
138 |
+
|
139 |
= 2.0.6 =
|
140 |
* New: Added ad label for individual post in new interface #117
|
141 |
* New: Added a tutorial link in the Adsense #116
|