Commits

simplemediacode committed 56d2e14

add: vers. 3.2.0

  • Participants
  • Parent commits 59776ce

Comments (0)

Files changed (6)

 
 Add human invisible schema.org itemprop code to post content
 
-* Contributors: rolandinsh (Rolands Umbrovskis)
 * [Donate](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=Z4ALL9WUMY3CL&lc=LV&item_name=Umbrovskis%2e%20WordPress%20plugins&item_number=002&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donate_SM%2egif%3aNonHosted) or promote this work 
-* Tags: SEO, schema, schema.org, itemprop, schema.org itemprop, images, microdata, rich snippets, richsnippets, SERP, html5, structured data
-* Requires at least: 3.3
-* Tested up to: 3.4.2
-* Stable tag: 3.1.3
 * License URI: http://simplemediacode.com/license/gpl/
 
 ## Description
 
-This plugin is very simple. Using WordPress built in function to filter element attributes. It will add human invisible / search engine visible schema.org `itemprop` code to content (via META tags).
+Very simple WordPress plugin, that uses built in function to filter element attributes. It will add human invisible / search engine visible schema.org `itemprop` code to content (via META tags).
 
 ### Example:
 
-	<span itemscope itemtype="http://schema.org/Article">
+	<span itemscope itemtype="http://schema.org/Article" class="itempropwp-wrap">
 	<!-- Itemprop WP 3.1.3 by Rolands Umbrovskis http://umbrovskis.com -->
 	 <meta itemprop="name" content="Title of the Article" />
 	 <meta itemprop="url" content="http://fulllink.example.com/seo-optimized-article/" />
 
 ## Changelog
 
+### 3.2.0
+
+* updated: admin interface for options
+* new: CSS class for wrapper
+
 ### 3.1.4
 
 * updated: itemprop="description"

File admin/adminipwp.php

 
 function smc_ipwp_admin_menu() {
 	//create new top-level menu
-	add_menu_page(__('itemprop WP for SERP/SEO Rich snippets','itempropwp'), __('itemprop WP','itempropwp'), 'activate_plugins', 'smcipwp_menu', 'smcipwp_settings');
+	add_menu_page(__('itemprop WP for SERP/SEO Rich snippets','itempropwp'), __('itemprop WP','itempropwp'), 'activate_plugins', 'smcipwp_menu', 'smcipwp_settings',SMCIPWPURL.'assets/img/itempropwp-icon-small.jpg');
 	//add_submenu_page( 'smcipwp_menu', __('Help','itempropwp'), __('Help','itempropwp'), 'edit_posts', 'smcipwphelp', 'smcipwp_help');
 	register_setting( 'smcipwp-settings', 'smcipwp_maxlenght' );
 	register_setting( 'smcipwp-settings', 'smcipwp_showcommcount' );
 	register_setting( 'smcipwp-settings', 'smcipwp_perpostopt' ); /* Per post options @since 1.5.0 */
 }
 
-function smcipwp_settings(){ ?><div class="wrap"><div class="icon32" id="icon-tools"><br /></div>
+function smcipwp_settings(){ ?><div class="wrap"><img src="<?php echo SMCIPWPURL;?>assets/img/itempropwp-icon-64.jpg" alt="itempropWP" style="float: left; display:inline; margin-right:10px;" />
 	<h2><?php _e('Settings');?></h2>
 	<form method="post" action="options.php">
 <?php 
 @since 1.5.0 
 */
 ?>
+<!-- 
 	<tr>
 		<th valign="top"><?php _e('Per post options','itempropwp');?></th>
 		<td valign="top"><input type="checkbox" id="smcipwp_perpostopt" name="smcipwp_perpostopt" <?php checked($smcipwp_perpostopt,'on') ?> /></td>
 	</tr>
+-->
  </table>
     <p class="submit"><input type="submit" class="button-primary" value="<?php _e('Save Changes','itempropwp') ?>" /></p>
 </form>

File assets/css/itempropwp.css

+@charset "utf-8";
+/*
+ * itempropwp CSS
+ * @since 3.1.4.3
+ * @version 1.0
+*/
+.itempropwp-wrap{
+	padding:0;
+	margin:0;
+	overflow:hidden;
+	display:inline;
+}
+

File assets/img/itempropwp-icon-small.jpg

Added
New image

File itempropwp.php

 <?php 
 /**
 Plugin Name: itemprop WP for SERP/SEO Rich snippets
-Plugin URI: http://simplemediacode.com/wordpress-pugins/itemprop-wp/?utm_source=wordpress&utm_medium=wpplugin&utm_campaign=itempropWP&utm_content=v-3.1.4.2-itempropWP_load_widgets
+Plugin URI: http://simplemediacode.com/wordpress-pugins/itemprop-wp/?utm_source=wordpress&utm_medium=wpplugin&utm_campaign=itempropWP&utm_content=v-3.2.0-itempropWP_load_widgets
 Description: Add human invisible schema.org itemprop code to images
-Version: 3.1.4.2
+Version: 3.2.0
 Requires at least: 3.3
 Tested up to: 3.5
 Author: Rolands Umbrovskis
 Copyright (C) 2008-2012, Rolands Umbrovskis - rolands@simplemediacode.com
 
  */
-	define('SMCIPWPV','3.1.4.2'); // location general @since 1.0
+	define('SMCIPWPV','3.2.0'); // location general @since 1.0
 	define('SMCIPWPM',dirname(__FILE__)); // location general @since 1.0
 	define('SMCIPWPF','itempropwp'); // location folder @since 1.0 
 	define('IPWPT',__('itemprop WP for SERP/SEO Rich snippets','itempropwp')); // Name @since 1.1
 	define('SMCIPWPURL', plugin_dir_url(__FILE__)); // Plugin URI @since 1.0
+	define('SMCIPWPDIR',dirname( plugin_basename( __FILE__ ) ));/* @since 3.2.0 */
 	$smcipwp_url = SMCIPWPURL; // @since 3.1 Use of undefined constant SMCIPWPURL - assumed 'SMCIPWPURL' in 
 	$smcipwp_f = SMCIPWPF; // @since 3.1 Use of undefined constant SMCIPWPF - assumed 'SMCIPWPF' in 
 	
 			if(is_admin()):
 				include_once(SMCIPWPM.'/admin/adminipwp.php');
 			endif;
+/*
+ * itempropwp CSS
+ * @since 3.2.0
+ * @version 1.0
+*/
+			if(!is_admin()):	
+				wp_register_style('itempropwp', SMCIPWPURL.'/assets/css/itempropwp.css', array(), SMCIPWPV, 'all');
+				wp_enqueue_style('itempropwp');
+			endif;
 		} 
 		// Initialize
 		public function init() {
-			load_plugin_textdomain( 'itempropwp', false, dirname( plugin_basename( __FILE__ ) ). '/lang/');
+			load_plugin_textdomain( 'itempropwp', false, SMCIPWPDIR. '/lang/');
 			add_filter('the_content', array( 'itempropwp', 'ipwp_the_content_filter' ), 10, 2 ); // Adding context @since 3.0
 			
 		}
 				}
 
 				$content = $content.'
-<span itemscope itemtype="http://schema.org/Article">
+<span itemscope itemtype="http://schema.org/Article" class="itempropwp-wrap">
 <!-- ItemProp WP '.SMCIPWPV.' by Rolands Umbrovskis http://umbrovskis.com -->
 	<meta itemprop="name" content="'.esc_attr($thisipwp_post->post_title).'" />
 	<meta itemprop="url" content="'.esc_url(get_permalink()).'" />'
 Tags: SEO, schema, schema.org, itemprop, schema.org itemprop, images, microdata, rich snippets, richsnippets, SERP, html5, structured data
 Requires at least: 3.3
 Tested up to: 3.5
-Stable tag: 3.1.4.1
+Stable tag: 3.2.0
 License: simplemediacode
 License URI: http://simplemediacode.com/license/gpl/
 
 Example output:
 
 `
-<span itemscope itemtype="http://schema.org/Article">
-<!-- Itemprop WP 3.1.4 by Rolands Umbrovskis http://umbrovskis.com -->
+<span itemscope itemtype="http://schema.org/Article" class="itempropwp-wrap">
+<!-- Itemprop WP 3.1.4.3 by Rolands Umbrovskis http://umbrovskis.com -->
  <meta itemprop="name" content="Title of the Article" />
  <meta itemprop="url" content="http://example.com/seo-optimized-article/" />
  <meta itemprop="image" content="http://example.com/images/example.jpg" />
  <meta itemprop="datePublished" content="2012-09-13 19:17:21" />
  <meta itemprop="dateModified" content="2012-09-29 13:33:25" />
  <meta itemprop="interactionCount" content="UserComments:356" />
-<!-- Itemprop WP 3.1.4 by Rolands Umbrovskis http://umbrovskis.com end -->
+<!-- Itemprop WP 3.1.4.3 by Rolands Umbrovskis http://umbrovskis.com end -->
 </span>
 `
 
 How does it work?
 
-There are no options. yet!
-
-This asumes that Yout page is not fully integrated with HTML5's data properties for microdata. This plugin will create small code inside Your full content, with extra microdata from schema.org. This will be ONLY on singular pages - post, page or your custom post type.
+This asumes that Your page is not fully integrated with HTML5's data properties for microdata. This plugin will create small code inside Your `full content`, with extra microdata from schema.org. This will be ONLY on singular pages - post, page or your custom post type.
 
 Once we are on singular page:
 
 # If we have empty content, from previous step, we will use post title. Not best choise, but at least we have some `description`.
 # If Your post do not have even title, plugin will giveup and your description will be ampty. (This ir very bad :') )
 
-Other options, like `datePublished`, `UserComments`, `url` are taken from post
-
-NEW in 3.1.4
-
-* updated: itemprop="description"
-* Admin interface for options: description lenght (if excerpt not provided),show/hide UserComments:325,  show/hide dateModified 
-
-NEW in 3.1
-
-* itemprop="description"
-
-NEW in 3.0 
-
-* new: context, without context for SEO this plugin was somehow useless. We FIXED it ;)
-* new: itemprop="name"
-* new: itemprop="url"
-* new: itemprop="image"
-* new: itemprop="author"
-* new: itemprop="datePublished"
-* new: "UserComments:325" itemprop="interactionCount"
-
-Add human invisible schema.org `itemprop` code to images (post thumbnails!).
+Other options, like `datePublished`, `dateModified` (if enabled), `UserComments` (if enabled), `url` are taken from post
 
 * [Project Page](http://simplemediacode.com/wordpress-pugins/itemprop-wp/)
 * [SMC Facebook](http://www.facebook.com/pages/SimpleMediaCode/125547717479727)
 1. See `itempropwp.php` for usage
 
 == Frequently Asked Questions ==
-There are no questions for now! [Ask!](http://simplemediacode.info/snippets/itemprop-attributes-for-wordpress-serp-results/)
+There are no questions for now! [Ask!](http://simplemediacode.com/wordpress-pugins/itemprop-wp/)
 
 == Changelog ==
 
+= 3.2.0  =
+
+* updated: admin interface for options
+* new: CSS class for wrapper
+
+
 = 3.1.4 =
 
 * updated: itemprop="description"