Changeset 186846
- Timestamp:
- 12/24/2009 12:37:17 PM (16 years ago)
- Location:
- wp-markkeyword
- Files:
-
- 4 edited
-
tags/0.6/index.php (modified) (13 diffs)
-
tags/0.6/readme.txt (modified) (2 diffs)
-
trunk/index.php (modified) (12 diffs)
-
trunk/readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wp-markkeyword/tags/0.6/index.php
r185566 r186846 4 4 Plugin URI: http://conis.cn/1365/ 5 5 Description: This plugin can high light keyword after someone searchecd it, which supports the search engines like google, baidu, ask, yahoo&bing.wp-markKeyword可以高亮显示来自搜索引擎的关键字,支持多个搜索引擎,更多请访问我的博客 6 Version: 0. 56 Version: 0.6 7 7 Author: Conis 8 8 Author URI: http://conis.cn/ … … 10 10 11 11 $mmkKeyword; 12 $mmkIsShowMsg; 12 13 13 14 function momoMarkKeywordMsg() … … 21 22 $mmkMsg = $mmkMsg.'<a href="'.get_bloginfo('url').'/?s='.$item.'">'.$item.'</a> '; 22 23 } 23 $mmkMsg = '< div class="wmkFrame">Your keyword is: <span class="wmkHighLight">'.$mmkMsg.'</span>';24 $mmkMsg = $mmkMsg . '<span class="wmkPowerBy"> <a href="http://conis.cn/?s=wp_markkeyword" target="_blank">wp_markKeyword</a>, Power by: <a href ="http://conis.cn" target="_blank">conis.cn</a></span></div>';25 echo$mmkMsg;24 $mmkMsg = '<fieldset class="wmkFrame" id="wmkFrame">Your keyword is: <span class="wmkHighLight">'.$mmkMsg.'</span>'; 25 $mmkMsg = $mmkMsg . '<span class="wmkPowerBy">Power by: <a href ="http://conis.cn" target="_blank">conis.cn</a></span></fieldset>'; 26 return $mmkMsg; 26 27 } 28 return ''; 27 29 } 28 30 … … 30 32 { 31 33 global $mmkKeyword; 34 global $mmkIsShowMsg; 35 if($mmkIsShowMsg) return $content; 32 36 if(isset($mmkKeyword)) 33 37 { … … 38 42 } 39 43 } 40 return $content; 44 $mmkIsShowMsg = true; 45 return momoMarkKeywordMsg().$content; 41 46 } 42 47 … … 67 72 .wmkFrame 68 73 { 69 margin: 0px;74 margin: 5px 0px 5px 0px; 70 75 background-color:#FCF4D3; 71 76 padding: 5px 0px 5px 0px; 72 border-bottom: 1px solid #CCC; 73 position: absolute; 74 top: 0px; 75 left: 0px; 76 width: 100%; 77 text-indent: 10px; 78 filter:alpha(opacity=50); 79 opacity:0.5; 77 border: 1px solid #CCC; 78 text-indent: 10px; 80 79 text-align: left; 80 -moz-border-radius: 6px; 81 81 } 82 82 .wmkPowerBy … … 86 86 color: #000; 87 87 font-size: 11px; 88 margin-right: 5px; 88 89 } 89 90 .wmkPowerBy a … … 97 98 function mmkInit() 98 99 { 99 echo is_single();100 100 global $mmkKeyword; 101 101 $mmkReferer = $_SERVER['HTTP_REFERER']; //get referfer url … … 105 105 $mmkReferer = $url; 106 106 } 107 107 108 if(!isset($mmkReferer)) return; 108 109 if(strpos($mmkReferer, 'baidu.com') != false) … … 110 111 $mmkReferer = urldecode($mmkReferer); 111 112 $mmkReferer = iconv('gb2312', 'utf-8', $mmkReferer); 112 if(preg_match("/(word|wd)=(.+)& /im", $mmkReferer, $arr))113 if(preg_match("/(word|wd)=(.+)&*/im", $mmkReferer, $arr)) 113 114 { 114 115 $mmkKeyword = $arr[2]; … … 117 118 else 118 119 { 119 //$mmkReferer = iconv('gb2312', 'utf-8', $mmkReferer);120 120 $mmkReferer = urldecode($mmkReferer); 121 121 if(preg_match("/[&\?]([qps]|query)=(.+?)&/im", $mmkReferer, $arr)) … … 125 125 if(!isset($mmkKeyword)) 126 126 { 127 //echo $mmkReferer;128 127 if(preg_match("/[&\?]([qps]|query)=(.+)/im", $mmkReferer, $arr)) 129 128 { … … 140 139 add_filter('the_content', 'momoMarkKeyword', 0); 141 140 add_filter('the_excerpt', 'momoMarkKeywordExcerpt', 0); 142 add_filter('wp_footer', 'momoMarkKeywordMsg', 0);143 141 } 144 142 ?> -
wp-markkeyword/tags/0.6/readme.txt
r185566 r186846 30 30 31 31 == Screenshots == 32 <img src="/tags/screenshot-1.JPG" /> 33 1. search 34 2. the highlight words are from the link of the search engine 35 3. high light keyword in the site 32 empty 36 33 37 34 == Changelog == … … 40 37 basic version 41 38 = 0.6 = 42 repair a fwe bugs. 43 basic version 39 empty 44 40 == Upgrade Notice == 45 41 -
wp-markkeyword/trunk/index.php
r185657 r186846 10 10 11 11 $mmkKeyword; 12 $mmkIsShowMsg; 12 13 13 14 function momoMarkKeywordMsg() … … 21 22 $mmkMsg = $mmkMsg.'<a href="'.get_bloginfo('url').'/?s='.$item.'">'.$item.'</a> '; 22 23 } 23 $mmkMsg = '< div class="wmkFrame">Your keyword is: <span class="wmkHighLight">'.$mmkMsg.'</span>';24 $mmkMsg = $mmkMsg . '<span class="wmkPowerBy"> <a href="http://conis.cn/?s=wp_markkeyword" target="_blank">wp_markKeyword</a>, Power by: <a href ="http://conis.cn" target="_blank">conis.cn</a></span></div>';25 echo$mmkMsg;24 $mmkMsg = '<fieldset class="wmkFrame" id="wmkFrame">Your keyword is: <span class="wmkHighLight">'.$mmkMsg.'</span>'; 25 $mmkMsg = $mmkMsg . '<span class="wmkPowerBy">Power by: <a href ="http://conis.cn" target="_blank">conis.cn</a></span></fieldset>'; 26 return $mmkMsg; 26 27 } 28 return ''; 27 29 } 28 30 … … 30 32 { 31 33 global $mmkKeyword; 34 global $mmkIsShowMsg; 35 if($mmkIsShowMsg) return $content; 32 36 if(isset($mmkKeyword)) 33 37 { … … 38 42 } 39 43 } 40 return $content; 44 $mmkIsShowMsg = true; 45 return momoMarkKeywordMsg().$content; 41 46 } 42 47 … … 67 72 .wmkFrame 68 73 { 69 margin: 0px;74 margin: 5px 0px 5px 0px; 70 75 background-color:#FCF4D3; 71 76 padding: 5px 0px 5px 0px; 72 border-bottom: 1px solid #CCC; 73 position: absolute; 74 top: 0px; 75 left: 0px; 76 width: 100%; 77 text-indent: 10px; 78 filter:alpha(opacity=50); 79 opacity:0.5; 77 border: 1px solid #CCC; 78 text-indent: 10px; 80 79 text-align: left; 80 -moz-border-radius: 6px; 81 81 } 82 82 .wmkPowerBy … … 86 86 color: #000; 87 87 font-size: 11px; 88 margin-right: 5px; 88 89 } 89 90 .wmkPowerBy a … … 97 98 function mmkInit() 98 99 { 99 echo is_single();100 100 global $mmkKeyword; 101 101 $mmkReferer = $_SERVER['HTTP_REFERER']; //get referfer url … … 105 105 $mmkReferer = $url; 106 106 } 107 107 108 if(!isset($mmkReferer)) return; 108 109 if(strpos($mmkReferer, 'baidu.com') != false) … … 110 111 $mmkReferer = urldecode($mmkReferer); 111 112 $mmkReferer = iconv('gb2312', 'utf-8', $mmkReferer); 112 if(preg_match("/(word|wd)=(.+)& /im", $mmkReferer, $arr))113 if(preg_match("/(word|wd)=(.+)&*/im", $mmkReferer, $arr)) 113 114 { 114 115 $mmkKeyword = $arr[2]; … … 117 118 else 118 119 { 119 //$mmkReferer = iconv('gb2312', 'utf-8', $mmkReferer);120 120 $mmkReferer = urldecode($mmkReferer); 121 121 if(preg_match("/[&\?]([qps]|query)=(.+?)&/im", $mmkReferer, $arr)) … … 125 125 if(!isset($mmkKeyword)) 126 126 { 127 //echo $mmkReferer;128 127 if(preg_match("/[&\?]([qps]|query)=(.+)/im", $mmkReferer, $arr)) 129 128 { … … 140 139 add_filter('the_content', 'momoMarkKeyword', 0); 141 140 add_filter('the_excerpt', 'momoMarkKeywordExcerpt', 0); 142 add_filter('wp_footer', 'momoMarkKeywordMsg', 0);143 141 } 144 142 ?> -
wp-markkeyword/trunk/readme.txt
r185657 r186846 4 4 Tags: high light, search engine, keyword, seo, keyword 5 5 Requires at least: 2.0.2 6 Tested up to: 0.66 Tested up to: 2.6 7 7 Stable tag: trunk 8 8 … … 30 30 31 31 == Screenshots == 32 <img src="/tags/screenshot-1.JPG" /> 33 1. search 34 2. the highlight words are from the link of the search engine 35 3. high light keyword in the site 32 empty 36 33 37 34 == Changelog == … … 40 37 basic version 41 38 = 0.6 = 42 repair a fwe bugs. 43 basic version 39 empty 44 40 == Upgrade Notice == 45 41
Note: See TracChangeset
for help on using the changeset viewer.