Advertisement
Guest User

Untitled

a guest
Feb 21st, 2019
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. function folder_paragrapgh($content){
  2. return preg_replace('/<p([^>]+)?>/', '<p class="para para2">', $content);
  3. }
  4. add_filter('the_content', 'folder_paragrapgh');
  5.  
  6. <script>
  7. (function($) {
  8. // do all your $ based jquery in here.
  9. $(function() {
  10. $('p.class2').prepend('<img src="http:/sample.com/img/folder.svg" width="50" height="25" alt="">');
  11. });
  12. })(jQuery);
  13. </script>
  14.  
  15. if( is_page_template( 'f-template.php' ) ) {
  16.  
  17. function folder_paragrapgh($content){
  18. return preg_replace('/<p([^>]+)?>/', '<p class="para para2">', $content);
  19. }
  20. add_filter('the_content', 'folder_paragrapgh');
  21. }
  22.  
  23. the_content();
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement