Version Description
- Major Fix Headers already sent
- Major Fix SSL security fix for Google Fonts
- [Major Fix] Parse error: syntax error, unexpected T_STATIC
- general bugfixing
Download this release
Release Info
Developer | mlehelsz |
Plugin | Contact Form 7 Style |
Version | 3.0.5 |
Comparing to | |
See all releases |
Code changes from version 3.0.4 to 3.0.5
- admin/js/admin.js +1 -1
- cf7-style-meta-box.php +2 -1
- cf7-style.php +11 -7
- inc/editor_page.php +10 -9
- inc/system_status.php +1 -1
- readme.txt +15 -10
admin/js/admin.js
CHANGED
@@ -106,7 +106,7 @@ jQuery(document).ready(function($) {
|
|
106 |
function changeFont(value) {
|
107 |
$(".google-fontos").remove();
|
108 |
if ("none" != value && "undefined" != typeof value) {
|
109 |
-
$("head").append('<link class="google-fontos" rel="stylesheet" href="
|
110 |
$(".cf7-style.preview-zone p").css("font-family", "'" + value + "', sans-serif");
|
111 |
$('.preview-form-container .wpcf7').css("font-family", "'" + value + "', sans-serif");
|
112 |
}
|
106 |
function changeFont(value) {
|
107 |
$(".google-fontos").remove();
|
108 |
if ("none" != value && "undefined" != typeof value) {
|
109 |
+
$("head").append('<link class="google-fontos" rel="stylesheet" href="https://fonts.googleapis.com/css?family=' + value + ':100,200,300,400,500,600,700,800,900&subset=latin,latin-ext,cyrillic,cyrillic-ext,greek-ext,greek,vietnamese" />');
|
110 |
$(".cf7-style.preview-zone p").css("font-family", "'" + value + "', sans-serif");
|
111 |
$('.preview-form-container .wpcf7').css("font-family", "'" + value + "', sans-serif");
|
112 |
}
|
cf7-style-meta-box.php
CHANGED
@@ -377,7 +377,7 @@ function enque_selected_font() {
|
|
377 |
$fontid = get_post_meta( $cf7s_id, 'cf7_style_font', true );
|
378 |
$googlefont = preg_replace( "/ /", "+", $fontid );
|
379 |
if( ! empty( $googlefont ) && "none" !== $googlefont ) {
|
380 |
-
wp_register_style( 'googlefont-cf7style-' . $cf7s_id, '
|
381 |
wp_enqueue_style( 'googlefont-cf7style-' . $cf7s_id );
|
382 |
}
|
383 |
}
|
@@ -404,6 +404,7 @@ function return_font_name( $cf7s_id ) {
|
|
404 |
add_action('admin_head', 'hide_edit_permalinks_on_style_customizer');
|
405 |
function hide_edit_permalinks_on_style_customizer() {
|
406 |
$currentScreen = get_current_screen();
|
|
|
407 |
if ( $currentScreen->post_type == 'cf7_style' ) {
|
408 |
?>
|
409 |
<style type="text/css">
|
377 |
$fontid = get_post_meta( $cf7s_id, 'cf7_style_font', true );
|
378 |
$googlefont = preg_replace( "/ /", "+", $fontid );
|
379 |
if( ! empty( $googlefont ) && "none" !== $googlefont ) {
|
380 |
+
wp_register_style( 'googlefont-cf7style-' . $cf7s_id, 'https://fonts.googleapis.com/css?family=' . $googlefont . ':100,200,300,400,500,600,700,800,900&subset=latin,latin-ext,cyrillic,cyrillic-ext,greek-ext,greek,vietnamese', array(), false, 'all' );
|
381 |
wp_enqueue_style( 'googlefont-cf7style-' . $cf7s_id );
|
382 |
}
|
383 |
}
|
404 |
add_action('admin_head', 'hide_edit_permalinks_on_style_customizer');
|
405 |
function hide_edit_permalinks_on_style_customizer() {
|
406 |
$currentScreen = get_current_screen();
|
407 |
+
if(empty($currentScreen)) { return false;}
|
408 |
if ( $currentScreen->post_type == 'cf7_style' ) {
|
409 |
?>
|
410 |
<style type="text/css">
|
cf7-style.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: Contact Form 7 Style
|
4 |
Plugin URI: http://wordpress.reea.net/contact-form-7-style/
|
5 |
Description: Simple style customization and templating for Contact Form 7 forms. Requires Contact Form 7 plugin installed.
|
6 |
-
Version: 3.0.
|
7 |
Author: Johnny, dorumarginean, mlehelsz, MirceaR
|
8 |
Author URI: http://cf7style.com
|
9 |
License: GPL2
|
@@ -15,7 +15,7 @@ License: GPL2
|
|
15 |
*/
|
16 |
define( 'WPCF7S_PLUGIN', __FILE__ );
|
17 |
define( 'WPCF7S_PLUGIN_DIR', untrailingslashit( dirname( WPCF7S_PLUGIN ) ) );
|
18 |
-
define( 'WPCF7S_PLUGIN_VER', '3.0.
|
19 |
|
20 |
|
21 |
function get_predefined_cf7_style_template_data() {
|
@@ -221,10 +221,14 @@ function cf7_style_custom_css_generator(){
|
|
221 |
$style_manual = "\n".$cf7s_manual_style."\n";
|
222 |
}
|
223 |
$cur_css = $style_start;
|
224 |
-
|
225 |
-
|
226 |
-
|
227 |
-
|
|
|
|
|
|
|
|
|
228 |
$cur_css .= $style_manual;
|
229 |
if( ( $style_number !== 0 ) && $style_number == count( $active_styles ) ) {
|
230 |
$cur_css .= "\n</style>\n";
|
@@ -312,7 +316,7 @@ function contact_form_7_check() {
|
|
312 |
$box .= '<div style="clear:both;"></div>';
|
313 |
$box .= '</div>';
|
314 |
$screen = get_current_screen();
|
315 |
-
if($screen->id == 'edit-cf7_style' || $screen->id == 'cf7_style'){
|
316 |
echo $box;
|
317 |
}
|
318 |
}
|
3 |
Plugin Name: Contact Form 7 Style
|
4 |
Plugin URI: http://wordpress.reea.net/contact-form-7-style/
|
5 |
Description: Simple style customization and templating for Contact Form 7 forms. Requires Contact Form 7 plugin installed.
|
6 |
+
Version: 3.0.5
|
7 |
Author: Johnny, dorumarginean, mlehelsz, MirceaR
|
8 |
Author URI: http://cf7style.com
|
9 |
License: GPL2
|
15 |
*/
|
16 |
define( 'WPCF7S_PLUGIN', __FILE__ );
|
17 |
define( 'WPCF7S_PLUGIN_DIR', untrailingslashit( dirname( WPCF7S_PLUGIN ) ) );
|
18 |
+
define( 'WPCF7S_PLUGIN_VER', '3.0.5' );
|
19 |
|
20 |
|
21 |
function get_predefined_cf7_style_template_data() {
|
221 |
$style_manual = "\n".$cf7s_manual_style."\n";
|
222 |
}
|
223 |
$cur_css = $style_start;
|
224 |
+
if ( version_compare( phpversion() , '5.3', '>' ) ) {
|
225 |
+
require_once 'inc/cssparser.php';
|
226 |
+
$css = new CSSParser();
|
227 |
+
$cssIndex = $css->ParseCSS($style);
|
228 |
+
$cur_css .= $css->GetCSS($cssIndex);
|
229 |
+
} else {
|
230 |
+
$cur_css .= $style;
|
231 |
+
}
|
232 |
$cur_css .= $style_manual;
|
233 |
if( ( $style_number !== 0 ) && $style_number == count( $active_styles ) ) {
|
234 |
$cur_css .= "\n</style>\n";
|
316 |
$box .= '<div style="clear:both;"></div>';
|
317 |
$box .= '</div>';
|
318 |
$screen = get_current_screen();
|
319 |
+
if( !empty($screen) && ($screen->id == 'edit-cf7_style' || $screen->id == 'cf7_style') ){
|
320 |
echo $box;
|
321 |
}
|
322 |
}
|
inc/editor_page.php
CHANGED
@@ -26,7 +26,7 @@ if ( !function_exists( 'cf7style_editor_page_init' ) ) {
|
|
26 |
|
27 |
if ( !function_exists( 'cf7style_settings_view' ) ) {
|
28 |
function cf7style_settings_view() { ?>
|
29 |
-
<form method="POST" action=""
|
30 |
<?php
|
31 |
do_settings_sections( 'cf7style-settings' );
|
32 |
submit_button( 'Save Settings', 'primary' , 'cf7styletracking');?>
|
@@ -92,8 +92,8 @@ class init_sections_register_fields {
|
|
92 |
$set_fields = array (
|
93 |
'cf7_style_allow_tracking' => __('Data collection', 'contact-form-7-style'),
|
94 |
'cf7_style_deleted' => __('Import predefined Contact Form 7 Style templates', 'contact-form-7-style'),
|
95 |
-
);
|
96 |
-
|
97 |
add_settings_field(
|
98 |
$field,
|
99 |
$value,
|
@@ -141,12 +141,13 @@ class init_sections_register_fields {
|
|
141 |
update_option( $args[0], $_POST[$args[0]] );
|
142 |
}
|
143 |
$option = stripslashes(get_option( $args[0] ));
|
144 |
-
|
145 |
-
|
146 |
-
|
147 |
-
|
148 |
-
|
149 |
-
|
|
|
150 |
echo '<form method="POST" action="">';
|
151 |
echo '<textarea id="'.$args[0].'" name="'.$args[0].'" />' . $option. '</textarea>';
|
152 |
submit_button( 'Save CSS', 'primary' );
|
26 |
|
27 |
if ( !function_exists( 'cf7style_settings_view' ) ) {
|
28 |
function cf7style_settings_view() { ?>
|
29 |
+
<form method="POST" action="">
|
30 |
<?php
|
31 |
do_settings_sections( 'cf7style-settings' );
|
32 |
submit_button( 'Save Settings', 'primary' , 'cf7styletracking');?>
|
92 |
$set_fields = array (
|
93 |
'cf7_style_allow_tracking' => __('Data collection', 'contact-form-7-style'),
|
94 |
'cf7_style_deleted' => __('Import predefined Contact Form 7 Style templates', 'contact-form-7-style'),
|
95 |
+
);
|
96 |
+
foreach ( $set_fields as $field => $value ) {
|
97 |
add_settings_field(
|
98 |
$field,
|
99 |
$value,
|
141 |
update_option( $args[0], $_POST[$args[0]] );
|
142 |
}
|
143 |
$option = stripslashes(get_option( $args[0] ));
|
144 |
+
if ( version_compare( phpversion() , '5.3', '>' ) ) {
|
145 |
+
require_once 'cssparser.php';
|
146 |
+
$css = new CSSParser();
|
147 |
+
echo "<div class='parser-message'>";
|
148 |
+
$cssIndex = $css->ParseCSS($option);
|
149 |
+
echo "</div>";
|
150 |
+
}
|
151 |
echo '<form method="POST" action="">';
|
152 |
echo '<textarea id="'.$args[0].'" name="'.$args[0].'" />' . $option. '</textarea>';
|
153 |
submit_button( 'Save CSS', 'primary' );
|
inc/system_status.php
CHANGED
@@ -110,7 +110,7 @@ function cf7style_system_status() {
|
|
110 |
$table .= "<td>" . get_locale() . "</td></tr>";
|
111 |
|
112 |
// Email address for feedback
|
113 |
-
$table .= "<tr><td>" . __( '
|
114 |
$table .= "<td>" . get_option( 'admin_email' ) . "</td></tr>";
|
115 |
|
116 |
$table .= $table_end;
|
110 |
$table .= "<td>" . get_locale() . "</td></tr>";
|
111 |
|
112 |
// Email address for feedback
|
113 |
+
$table .= "<tr><td>" . __( 'Site email address', 'contact-form-7-style' ) . "</td>";
|
114 |
$table .= "<td>" . get_option( 'admin_email' ) . "</td></tr>";
|
115 |
|
116 |
$table .= $table_end;
|
readme.txt
CHANGED
@@ -1,9 +1,9 @@
|
|
1 |
=== Contact Form 7 Style ===
|
2 |
Contributors: ionut.iclanzan, dorumarginean, mlehelsz, mircear
|
3 |
-
Donate link:
|
4 |
Tags: contact form 7, contact form 7 style, contact form 7 css, contact form 7 styling, CF7, CF7 style, styling contact form, styling contact form 7, multiple form styling, custom form styling, CF7 addon, customize, templates, valentine's day templates, Christmas templates, manual styling, live preview, hover state styling
|
5 |
Requires at least: 3.0.1
|
6 |
-
Tested up to: 4.
|
7 |
Stable tag: 4.5.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -62,6 +62,14 @@ You will find 'Contact Style' menu in your WordPress admin panel.
|
|
62 |
|
63 |
== Changelog ==
|
64 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
65 |
= 3.0.4 =
|
66 |
* [Major Fix](https://wordpress.org/support/topic/problem-with-css-editor?replies=2) Fixed CSS editor "\" multiplier removed
|
67 |
* [Major Fix] Collection data functionality to prevent fatal error for various server setups
|
@@ -186,11 +194,8 @@ You will find 'Contact Style' menu in your WordPress admin panel.
|
|
186 |
* First plugin version.
|
187 |
|
188 |
== Upgrade Notice ==
|
189 |
-
= Contact Form 7 Style Version 3.0.
|
190 |
-
* [Major Fix]https://wordpress.org/support/topic/
|
191 |
-
* [Major Fix]
|
192 |
-
* [Major Fix]
|
193 |
-
*
|
194 |
-
* New feature - System Status page with the possibility to ask for help from the Contact Form 7 Style team by email
|
195 |
-
* New feature - Settings page - Install predefined templates or Allow collection data
|
196 |
-
* General bugfixing
|
1 |
=== Contact Form 7 Style ===
|
2 |
Contributors: ionut.iclanzan, dorumarginean, mlehelsz, mircear
|
3 |
+
Donate link: http://cf7style.com/back-this-project/
|
4 |
Tags: contact form 7, contact form 7 style, contact form 7 css, contact form 7 styling, CF7, CF7 style, styling contact form, styling contact form 7, multiple form styling, custom form styling, CF7 addon, customize, templates, valentine's day templates, Christmas templates, manual styling, live preview, hover state styling
|
5 |
Requires at least: 3.0.1
|
6 |
+
Tested up to: 4.6
|
7 |
Stable tag: 4.5.2
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
62 |
|
63 |
== Changelog ==
|
64 |
|
65 |
+
= 3.0.5 =
|
66 |
+
* [Major Fix](https://wordpress.org/support/topic/headers-already-sent-35?replies=2) Headers already sent
|
67 |
+
* [Major Fix](https://wordpress.org/support/topic/please-fix-a-googleapi-call-in-your-php?replies=2) SSL security fix for Google Fonts
|
68 |
+
* [Major Fix] Parse error: syntax error, unexpected T_STATIC
|
69 |
+
* general bugfixing
|
70 |
+
|
71 |
+
|
72 |
+
|
73 |
= 3.0.4 =
|
74 |
* [Major Fix](https://wordpress.org/support/topic/problem-with-css-editor?replies=2) Fixed CSS editor "\" multiplier removed
|
75 |
* [Major Fix] Collection data functionality to prevent fatal error for various server setups
|
194 |
* First plugin version.
|
195 |
|
196 |
== Upgrade Notice ==
|
197 |
+
= Contact Form 7 Style Version 3.0.5 =
|
198 |
+
* [Major Fix](https://wordpress.org/support/topic/headers-already-sent-35?replies=2) Headers already sent
|
199 |
+
* [Major Fix](https://wordpress.org/support/topic/please-fix-a-googleapi-call-in-your-php?replies=2) SSL security fix for Google Fonts
|
200 |
+
* [Major Fix] Parse error: syntax error, unexpected T_STATIC
|
201 |
+
* general bugfixing
|
|
|
|
|
|