Per page add to head - Version 1.4.1

Version Description

  • Fixed an error leading to incorrect new line storage
Download this release

Release Info

Developer Erikvona
Plugin Icon wp plugin Per page add to head
Version 1.4.1
Comparing to
See all releases

Code changes from version 1.4 to 1.4.1

Files changed (2) hide show
  1. perpagehead.php +3 -3
  2. readme.txt +4 -1
perpagehead.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Per page head
4
  Plugin URI: http://www.evona.nl/plugins/per-page-head
5
  Description: Allows you to add content into the <head> section for a specific page, like custom JS or custom HTML
6
- Version: 1.4
7
  Author: Erik von Asmuth
8
  Author URI: http://evona.nl/over-mij/
9
  License: GPLv2
@@ -77,8 +77,8 @@ function perpageath_save_postdata( $post_id ) {
77
 
78
  /* OK, its safe for us to save the data now. */
79
 
80
- // Sanitize user input.
81
- $mydata = esc_sql( str_replace(array("\r\n", "\r", "\n"), '',$_POST['per-page-ath']) );
82
 
83
  // Update the meta field in the database.
84
  update_post_meta( $post_id, 'per-page-ath-content', $mydata );
3
  Plugin Name: Per page head
4
  Plugin URI: http://www.evona.nl/plugins/per-page-head
5
  Description: Allows you to add content into the <head> section for a specific page, like custom JS or custom HTML
6
+ Version: 1.4.1
7
  Author: Erik von Asmuth
8
  Author URI: http://evona.nl/over-mij/
9
  License: GPLv2
77
 
78
  /* OK, its safe for us to save the data now. */
79
 
80
+ // Add slashes because update_post_meta will expect them
81
+ $mydata = addslashes($_POST['per-page-ath'] );
82
 
83
  // Update the meta field in the database.
84
  update_post_meta( $post_id, 'per-page-ath-content', $mydata );
readme.txt CHANGED
@@ -6,7 +6,7 @@ Author URI: http://evona.nl/over-mij
6
  Author: Erik von Asmuth (Erikvona)
7
  Requires at least: 3.5
8
  Tested up to: 4.7
9
- Stable tag: 1.4
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
@@ -35,6 +35,9 @@ Installation is plain and simple
35
  1. You can also add head to all posts! Just use settings -> per page add to head
36
 
37
  == Changelog ==
 
 
 
38
  = 1.4 =
39
  - Added shortcode support. You can now place shortcodes in both the posts/pages, and the "every page" area
40
  - Fixed an error generating output during installation, and corrected a misplaced linebreak outside the PHP code
6
  Author: Erik von Asmuth (Erikvona)
7
  Requires at least: 3.5
8
  Tested up to: 4.7
9
+ Stable tag: 1.4.1
10
  License: GPLv2 or later
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
35
  1. You can also add head to all posts! Just use settings -> per page add to head
36
 
37
  == Changelog ==
38
+ = 1.4.1 =
39
+ - Fixed an error leading to incorrect new line storage
40
+
41
  = 1.4 =
42
  - Added shortcode support. You can now place shortcodes in both the posts/pages, and the "every page" area
43
  - Fixed an error generating output during installation, and corrected a misplaced linebreak outside the PHP code