Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ction ot_shortcode_box($atts, $content = '') {
- extract(
- shortcode_atts(
- array(
- 'type' => '',
- 'title' => ''
- ),
- $atts
- )
- );
- if ($type === 'box1') {
- return '<div class="box box1"><div class="box-title"><i class="fas fa-bookmark"></i>'.$title.'</div><div class="box-content">'.$content.'</div></div>';
- }
- if ($type === 'box2') {
- return '<div class="box box2"><div class="box-title"><i class="fas fa-shapes"></i>'.$title.'</div><div class="box-content">'.$content.'</div></div>';
- }
- return '';
- }
- add_shortcode('box', 'ot_shortcode_box');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement