Changeset 736661
- Timestamp:
- 07/05/2013 01:11:42 PM (13 years ago)
- Location:
- content-for-money/trunk
- Files:
-
- 2 edited
-
contentformoney.php (modified) (5 diffs)
-
readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
content-for-money/trunk/contentformoney.php
r698325 r736661 5 5 Author: Panagiotis Angelidis (paaggeli) 6 6 Author URI: http://panoswebsites.com 7 Version: 1.1. 17 Version: 1.1.2 8 8 License: GPL version 2 or later 9 9 */ … … 124 124 125 125 <p>With the parameter <strong>amount</strong> you set the price for the hidden content, in this example the price is 11$.</p> 126 127 <h4>Parameters:</h4> 128 <p><b>amount:</b> With the parameter <u>amount</u> you set the price for the hidden content like the example above.</p> 129 <p><b>display_comments:</b> With the parameter <u>display_comments</u> you can hide the comments giving to this parameter the value 'no'. 130 <br/>E.g. <b>[paycontent display_comments='no']</b> <i> Here Goes The Content <i> <b>[/paycontent]</b></p> 126 131 </fieldset></div> 127 132 <?php … … 130 135 function HideContent($atts, $content=null){ 131 136 extract(shortcode_atts( array( 132 'amount' => '16' 137 'amount' => '16', 138 'display_comments' => '' 133 139 ), $atts )); 134 140 … … 143 149 } 144 150 else { 151 if($display_comments == no){ 152 //hide the comments 153 function hide_comments(){ 154 return "You are not allowed to read this comment!"; 155 } 156 add_filter( 'comment_text', 'hide_comments' ); 157 }//if 158 //display the paypal button instead the content 145 159 $message=$this->genButton($atts); 146 160 return $message ; 147 161 } 148 162 }//end method HideContent 163 149 164 /*Now we create the PayPal button*/ 150 165 function genButton($a){ … … 167 182 return $button; 168 183 }//end method genButton 169 184 170 185 }//end class Contentformoney 171 186 }//end if -
content-for-money/trunk/readme.txt
r626469 r736661 5 5 Requires at least: 3.0.0 6 6 Tested up to: 3.3 7 Stable tag: 1.1. 17 Stable tag: 1.1.2 8 8 License: GPLv2 or later 9 9 With this plugin you can hide a part or the entire content of your posts and pages. The hidden content can be seen by members, non members must pay. … … 56 56 With the parameter amount you set the price for the hidden content, in this example the price is 11$. 57 57 58 Parameters: 59 60 'amount': With the parameter amount you set the price for the hidden content like the example above. 61 62 'display_comments': With the parameter display_comments you can hide the comments giving to this parameter the value 'no'. 63 -E.g. [paycontent display_comments='no'] Here Goes The Content [/paycontent] 64 65 58 66 [youtube http://www.youtube.com/watch?v=A9PIEoOQzc8] 59 67 … … 70 78 71 79 == Changelog == 80 = 1.1.2 = 81 -Added Shortcode Parameter 'display_comments' 82 72 83 = 1.1.1 = 73 84 -Added Help Section
Note: See TracChangeset
for help on using the changeset viewer.