Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [box] Text [/box]
- <div class="box"> Text </div>
- function infoButton($atts, $content = null) {
- extract( shortcode_atts( array(
- 'class' => '',
- ), $atts ));
- $str = '<div class="box ' . $class . '">' . do_shortcode($content) . '</div>';
- $new_str = str_replace(' ','',$str);
- return $new_str;
- }
- add_shortcode('box', 'infoButton');
- function infoButton($atts, $content = null) {
- extract( shortcode_atts( array(
- 'class' => '',
- ), $atts ));
- $str = '<div class="box ' . $class . '">' . do_shortcode( trim( $content ) ) . '</div>';
- return $str;
- }
- add_shortcode('box', 'infoButton');
Add Comment
Please, Sign In to add comment