Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- if (is_post_type('the_store')) {
- function add_some_stuff($content) {
- $whateveryouwanttoadd = <<<PAYPAL
- <form method="post" action="https://www.paypal.com/cgi-bin/webscr" target="paypal">
- <input type="hidden" name="cmd" value="_cart">
- <input type="hidden" name="business" value="$mama_paypal">
- <input type="hidden" name="item_name" value="the_title()">
- <input type="hidden" name="shopping_url" value="the_permalink()">
- <input type="hidden" name="item_number" value="the_ID()">
- <input type="hidden" name="amount" value="$price[0]">
- <input type="hidden" name="currency_code" value="USD">
- <input type="hidden" name="shipping" value="$shipping[0]">
- <input type="hidden" name="shipping2" value="$another[0]">
- <input type="hidden" name="handling_cart" value="$mama_handling">
- <input type="hidden" name="bn" value="ButtonFactory.PayPal.001">
- <input type="image" name="add" src="http://www.powersellersunite.com/buttonfactory/sc-but-01.gif">
- </form>
- PAYPAL;
- $content = preg_replace('/<\/p>/', '</p><p>'. $whateveryouwanttoadd.'</p>', $content, 1);
- return $content;
- }
- add_filter('the_content', 'add_some_stuff');
- }
- ?>
Add Comment
Please, Sign In to add comment