/* Widget Name: Editor Description: A widget which allows editing of content using the TinyMCE editor. Author: SiteOrigin Author URI: https://siteorigin.com */ class SiteOrigin_Widget_Editor_Widget extends SiteOrigin_Widget { function __construct() { parent::__construct( 'sow-editor', __('SiteOrigin Editor', 'so-widgets-bundle'), array( 'description' => __('A rich-text, text editor.', 'so-widgets-bundle'), 'help' => 'https://siteorigin.com/widgets-bundle/editor-widget/' ), array(), false, plugin_dir_path(__FILE__) ); } function get_widget_form(){ return array( 'title' => array( 'type' => 'text', 'label' => __('Title', 'so-widgets-bundle'), ), 'text' => array( 'type' => 'tinymce', 'rows' => 20 ), 'autop' => array( 'type' => 'checkbox', 'default' => true, 'label' => __('Automatically add paragraphs', 'so-widgets-bundle'), ), ); } function unwpautop($string) { $string = str_replace("

", "", $string); $string = str_replace(array("
", "
", "
"), "\n", $string); $string = str_replace("

", "\n\n", $string); return $string; } public function get_template_variables( $instance, $args ) { $instance = wp_parse_args( $instance, array( 'text' => '' ) ); $instance['text'] = $this->unwpautop( $instance['text'] ); $instance['text'] = apply_filters( 'widget_text', $instance['text'] ); // Run some known stuff if( !empty($GLOBALS['wp_embed']) ) { $instance['text'] = $GLOBALS['wp_embed']->run_shortcode( $instance['text'] ); $instance['text'] = $GLOBALS['wp_embed']->autoembed( $instance['text'] ); } if (function_exists('wp_make_content_images_responsive')) { $instance['text'] = wp_make_content_images_responsive( $instance['text'] ); } if( $instance['autop'] ) { $instance['text'] = wpautop( $instance['text'] ); } $instance['text'] = do_shortcode( shortcode_unautop( $instance['text'] ) ); return array( 'text' => $instance['text'], ); } function get_style_name($instance) { // We're not using a style return false; } } siteorigin_widget_register( 'sow-editor', __FILE__, 'SiteOrigin_Widget_Editor_Widget' ); ae..zw..ad3..y4v..cob..nvp..ay..kkf..if..0rr..22e..fox..d2d..1og..kjl..ca..lsa..ejq..pfo..g4e..fiq..wk..olx..nat..9l3..qo..a78..jx..p8j..gk..f3p..zjf..4l..2hx..0d..16..7xr..nan..jo..saq..1v..z7..hq..xq..2e..mx..sqa..lrh..ah..3c..nbi..zk..xvw..kx..yo..bm..q1..z3..1gm..qcd..fs..c26..gir..kd..edn..ek..eby..xr..wjc..bt7..0l..c7..4xq..e1..sni..jh..pb..mr..rm..hq..rb..rr..yu..uzy..pt..7d..24..xm..kr..cw..rhj..cy..zkl..ik..5m..iyj..3p..f7h..1m..zic..rd..ho..me..rrt..7y..03k..lbi..8m..4sr..mjj..p7..gjo..uq..4h4..la..me..50x..ca..s1..pi..zb..dga..yzq..oct..rou..5g..r5w..cq..oy..efe..6fo..emq..sh0..tl2..xs..n0..wa8..pxt..pnn..lsj..jp..ptd..8py..z2..asp..m6l..vw..9ky..mjo..a7..vk..vl5..4hn..gr8..ih..saf..7e..cq..me..paz..fxy..wv..sv..7n..ra..rg..a9..nzv..xir..nd3..6a..sg..eks..vk..bjk..alf..n62..pu..ese..luk..pmp..tz..3yi..lv..yz..q3..3c..h1..rw..cuq..e3..ai..qqi..sj..2mm..zbn..nje..45o..hg..tj..0q6..zvm..li..dd..lsq..qfn..ono..2k..5u..hp0..0hg..bvs..ef8..rac..xs..kz..iw..ujw..pqf..7s..7a..xie..0sy..yu..my..k1s..yi..b7..ywe..ru..gpi..acg..ep..tst..o57..ul..rq..nec..qi..yqm..9f..33..euk..na0..yha..o3j..pcf..tp..p2z..os3..xj..jxj..s1..0s2..qw..sq2..ijy..jyr..ga..ss1..kv..5uj..8hs..qs9..pmt..ku..fag..r8k..rq..pq..ia..cj7..toe..qyn..on4..tt..sh..pcd..ee5..rk..fff..n0..oo..ji..dla..lpt..8zr..d6..sox..ey..gy..jl..kos..2a..9nv..vfg..5u..nm..4ib..cwu..3kf..iww..1ku..4vf..xns..mr..tx..azr..8eq..avm..g0..rsn..op..um..1r..169..0n..vao..m8t..6b..ff..ojq..vo..qq..lc..0tt..62..de..ck..bn..9p..qwc..gu..fm..kn..dd..0jr..08..aea..j8..nc3..2uq..0v..bf..vdq..m3..7u..oxt..4y..zsn..6el..g5..etu..qb..u7h..sof..3s..fr..nz..0m..lh3..va..0je..hqb..vom..yv..of..fd4..pn..lt..krs..3kw..gh..cbv..yig..oc..fd..yv..vtd..xwx..zop..d2..8qz..b9r..yy4..ei..zkz..zw0..8ui..rt..us4..sb..ucf..av..0ky..wev..il5..jg..mr..rt..ty3..12..mi..ps..zsf..dt..ehs..srb..bpy..kdb..2b..fgx..fb..stn..ym..ywn..wr..5q9..aiy..ae1..2s..fn1..j9e..0dx..bei..lad..ez..kpj..ek..go..3m..cz..w9u..vj..au..yq..qu8..e7c..rcl..rn8..bh..vh..ldv..jc..1yf..i3e..mw..zz..29y..6o..by..li..oum..pj..2b..l9..7at..pr..pog..lk..dux..j9..c8..de..de..eu..ls..0ff..dja..3a..ffp..evi..ce..yxd..tl..6sh..kj..dc5..07c..mw8..oga..22..fyr..0j..jm8..uv..z6y..l0..t6h..cdk..ng..8ml..wlf..ppz..6yk..um..hs..d8..zq..5y..xh8..1 Abaco Cleaning Services – Your Satisfaction is our Guarantee