Note that there are some explanatory texts on larger screens.

plurals
  1. POshortcode doesn't work wordpress
    text
    copied!<p>I have this shortcode code..</p> <pre><code>function codeThree($attr,$content) { extract(shortcode_atts(array( 'style' =&gt; 'design1', 'title' =&gt; 'Here is where the title will be reside..', 'image' =&gt; 'codethreeimg' ), $atts)); $dir = get_template_directory_uri(); return '&lt;div class="codethree extend" style="background: transparent url('.$dir.'/images/'.$style.'.jpg) no-repeat top center;"&gt;&lt;img class="codethreeimg" src="'.$dir.'/'.$image.'" /&gt;&lt;p class="codethreep"&gt;&lt;h2 class="codethreetitle"&gt;'.$title.'&lt;/h2&gt;&lt;br/&gt;'.do_shortcode($content).'&lt;/p&gt;&lt;/div&gt;'; } function register_shortcodes(){ add_shortcode('codethree', 'codeThree'); } add_action( 'init', 'register_shortcodes'); </code></pre> <p>and this for displaying them..</p> <pre><code>[codethree style="design1" title="Hi, I'm Armando Gutierrez, #1 Personal Trainer in Torrance &amp; LA, and Body Transformation Specialist." image="http://localhost/wordpress/wp-content/uploads/2013/09/Profile.png"]some contents here[/codethree] </code></pre> <p>as you can see, this:</p> <pre><code>'style' =&gt; 'design1', 'title' =&gt; 'Here is where the title will be reside..', 'image' =&gt; 'codethreeimg' </code></pre> <p>will be default, if user doesn't specify there define content on those array fields, but what happens, the default content was instead displayed although those fields has been filled by the user define content.</p> <pre><code>[codethree style="design1" title="Hi, I'm Armando Gutierrez, #1 Personal Trainer in Torrance &amp; LA, and Body Transformation Specialist." image="http://localhost/wordpress/wp-content/uploads/2013/09/Profile.png"]some contents here[/codethree] </code></pre> <p>Could someone check my codes and at least tell me whats wrong please? I'm open to any suggestions, ideas and recommendations! Thank you in advance.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload