Submit
Path:
~
/
home
/
getwphos
/
public_html
/
giulianos
/
wp-content
/
plugins
/
pixelwars-core
/
themes
/
unrovr
/
File Content:
shortcodes.php
<?php function quote($atts, $content = "") { extract( shortcode_atts( array('name' => ""), $atts ) ); $output = '<blockquote>'; $output .= do_shortcode($content); $output .= '<cite>' . esc_html($name) . '</cite>'; $output .= '</blockquote>'; return $output; } add_shortcode('quote', 'quote'); /* ============================================================================================================================================= */ function mini_text($atts, $content = "") { $output = '<div class="mini-text">' . do_shortcode($content) . '</div>'; return $output; } add_shortcode('mini_text', 'mini_text'); /* ============================================================================================================================================= */ // Actual processing of the shortcode happens here function pixelwars_core_run_shortcode($content) { global $shortcode_tags; // Backup current registered shortcodes and clear them all out $orig_shortcode_tags = $shortcode_tags; remove_all_shortcodes(); add_shortcode('quote', 'quote'); add_shortcode('mini_text', 'mini_text'); // Do the shortcode ( only the one above is registered ) $content = do_shortcode($content); // Put the original shortcodes back $shortcode_tags = $orig_shortcode_tags; return $content; } add_filter('the_content', 'pixelwars_core_run_shortcode', 7); ?>
Submit
FILE
FOLDER
Name
Size
Permission
Action
index.php
28 bytes
0644
post-type-portfolio.php
2699 bytes
0644
shortcodes.php
1450 bytes
0644
widget-homepage-menu-item.php
4755 bytes
0644
widget-map.php
5794 bytes
0644
widget-testimonial.php
5184 bytes
0644
N4ST4R_ID | Naxtarrr