[{"data":1,"prerenderedAt":11},["ShallowReactive",2],{"$f51ohz7pl76p4":3},{"slug":4,"title":5,"description":6,"published":7,"updated":8,"thumb":9,"html":10},"how-to-create-own-shortcode-for-clear-property-in-wordpress","How To Create Your Own Shortcode For Clear Property in WordPress","When writing HTML code or working with WordPress pages, we often come across a situation where we want to clear areas and put next div or element on next...","2015-04-13","2016-06-17",null,"\u003Cp>When writing HTML code or working with WordPress pages, we often come across a situation where we want to clear areas and put next div or element on next line instead of floating with previous block.\u003C\u002Fp>\n\u003Cp>You can write quick HTML to fix such issues. But in case of repeated situation, you may create this handy code using WordPress shortcode feature. Add the following lines in  your theme&#8217;s funtions.php and use the  shortcode you clear the areas on left and right in HTML.\u003C\u002Fp>\n\u003Cp>Step 1:\u003Cbr \u002F>\n\u003Ccode>\u003Cbr \u002F>\nfunction ad_clear_shortcode( $atts , $content = null ) {\u003C\u002Fp>\n\u003Cp>\t\u002F\u002F Code\u003Cbr \u002F>\nreturn '\u003C\u002Fp>\n\u003Cp>';\u003Cbr \u002F>\n}\u003Cbr \u002F>\nadd_shortcode( 'clear', 'ad_clear_shortcode' );\u003Cbr \u002F>\n\u003C\u002Fcode>\u003C\u002Fp>\n\u003Cp>Step 2:\u003Cbr \u002F>\nAnd when you want to use the clear property, you can simply use the shortcode  instead of using the long \u003C\u002Fp>\n\u003Cp>\u003Ccode>\u003C\u002Fcode>\u003C\u002Fp>\n\u003Cp>Backup of funtions.php is recommended before making any change to it so that you can restore it via FTP or file manager in order something goes wrong in editing.\u003C\u002Fp>",1792666409023]