Advertisement
lorro

WordPress - Add HTML after search form

Apr 22nd, 2015
322
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.28 KB | None | 0 0
  1. <?php
  2.   // WordPress tweak - add some html after the search form
  3.   add_filter('get_search_form', 'add_shop_link');
  4.   function add_shop_link($form) {
  5.     $form .= '<div id="my_shop_link">';
  6.     $form .= '<a href="/shop">Cart</a>';
  7.     $form .= "</div>";
  8.     return $form;
  9.   }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement