function install_ShareThis() { $publisher_id = get_option('st_pubid'); //pub key value $widget = get_option('st_widget'); //entire script tag $newUser = false; if (get_option('st_version') == '') { update_option('st_version', '5x'); } if (empty($publisher_id)) { if (!empty($widget)) { $newPkey = getKeyFromTag(); if ($newPkey == false) { $newUser = true; update_option('st_pubid', trim(makePkey())); } else { update_option('st_pubid', $newPkey); //pkey found set old key } } else { $newUser = true; update_option('st_pubid', trim(makePkey())); } } if ($widget == false || !preg_match('/stLight.options/', $widget)) { $pkey2 = get_option('st_pubid'); $widget = "<script charset=\"utf-8\" type=\"text/javascript\">var switchTo5x=true;</script>"; $widget .= "<script charset=\"utf-8\" type=\"text/javascript\" src=\"http://w.sharethis.com/button/buttons.js\"></script>"; $widget .= "<script type=\"text/javascript\">stLight.options({publisher:'{$pkey2}'});var st_type='wordpress" . trim(get_bloginfo('version')) . "';</script>"; update_option('st_widget', $widget); } $st_sent = get_option('st_sent'); $st_upgrade_five = get_option('st_upgrade_five'); if (empty($st_sent)) { update_option('st_sent', 'true'); update_option('st_upgrade_five', '5x'); $st_sent = get_option('st_sent'); //confirm if value has been set if (!empty($st_sent)) { sendWelcomeEmail($newUser); } $st_upgrade_five = get_option('st_upgrade_five'); } else { if (empty($st_upgrade_five)) { update_option('st_upgrade_five', '5x'); $st_upgrade_five = get_option('st_upgrade_five'); //confirm if value has been set if (!empty($st_upgrade_five)) { sendUpgradeEmail(); } } } if (get_option('st_add_to_content') == '') { update_option('st_add_to_content', 'yes'); } if (get_option('st_add_to_page') == '') { update_option('st_add_to_page', 'yes'); } }
function st_customized_buttons_shortcode() { global $post; $widgetTag = stripslashes(get_option('st_widget')); $publisher_id = get_option('st_pubid'); if (empty($publisher_id)) { $toShow = ""; // Re-generate new random publisher key $publisher_id = trim(makePkey()); } else { $toShow = $widgetTag; } $content = $toShow; $services = get_option('st_services'); if (empty($services)) { $services = "facebook,twitter,linkedin,email,sharethis,fblike,plusone,pinterest"; } $tags = stripslashes(get_option('st_tags')); if (empty($tags)) { foreach (explode(',', $services) as $svc) { $tags .= "<span class='st_" . $svc . "_large' st_title='" . get_the_title($post->ID) . "' st_url='" . get_permalink($post->ID) . "' displayText='" . $svc . "'></span>"; } } else { $tagsArray = explode('<?php the_title(); ?>', $tags); $myTitle = get_the_title($post->ID); $tags = implode($myTitle, $tagsArray); $tagsArray = explode('<?php the_permalink(); ?>', $tags); $myPermalink = get_permalink($post->ID); $tags = implode($myPermalink, $tagsArray); } $content .= $tags; return $content; }
function st_options_form() { $plugin_location = plugins_url() . '/' . str_replace(basename(__FILE__), "", plugin_basename(__FILE__)); $publisher_id = get_option('st_pubid'); $services = get_option('st_services'); $tags = stripslashes(get_option('st_tags')); $tagsFromDb = stripslashes(get_option('st_tags')); $st_current_type = get_option('st_current_type'); $st_current_type_from_db = get_option('st_current_type'); $st_widget_version = get_option('st_version'); $st_prompt = get_option('st_prompt'); $st_username = get_option('st_username'); $st_pulldownlogo = get_option('st_pulldownlogo'); $st_hoverbarServices = get_option('st_hoverbar_services'); $st_pulldownbarServices = get_option('st_pulldownbar_services'); $cns_settings = get_option('copynshareSettings'); $stProtocol = get_option('protocolType'); $stPagesTop = get_option('st_pages_on_top'); $stPagesBot = get_option('st_pages_on_bot'); $stPostsTop = get_option('st_posts_on_top'); $stPostsBot = get_option('st_posts_on_bot'); $stPostExcerpt = get_option('st_post_excerpt'); $freshInstalation = empty($services) ? 1 : 0; $checkPagesTop = ''; $checkPagesBot = ''; if ($stPagesTop == 'top' && $stPagesBot == 'bot') { $checkPagesTop = 'checked="checked"'; $checkPagesBot = 'checked="checked"'; } else { if (empty($stPagesTop) && $stPagesBot == 'bot') { $checkPagesTop = ''; $checkPagesBot = 'checked="checked"'; } else { if ($stPagesTop == 'top' && empty($stPagesBot)) { $checkPagesTop = 'checked="checked"'; $checkPagesBot = ''; } } } $checkPostsTop = ''; $checkPostsBot = ''; if ($stPostsTop == 'top' && $stPostsBot == 'bot') { $checkPostsTop = 'checked="checked"'; $checkPostsBot = 'checked="checked"'; } else { if (empty($stPostsTop) && $stPostsBot == 'bot') { $checkPostsTop = ''; $checkPostsBot = 'checked="checked"'; } else { if ($stPostsTop == 'top' && empty($stPostsBot)) { $checkPostsTop = 'checked="checked"'; $checkPostsBot = ''; } } } $checkPostExcerpt = ''; if ($stPostExcerpt == 'true') { $checkPostExcerpt = 'checked="checked"'; } else { if ($stPostExcerpt == 'false') { $checkPostExcerpt = ''; } else { // First installation - By default Checked $checkPostExcerpt = 'checked="checked"'; } } $isSecure = ''; $isNonSecure = 'checked="checked"'; if (!empty($stProtocol)) { if ('https' == $stProtocol) { $isNonSecure = ''; $isSecure = 'checked="checked"'; } else { $isNonSecure = 'checked="checked"'; $isSecure = ''; } } else { if ($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https' || $_SERVER['HTTPS'] == 'on') { $isNonSecure = ''; $isSecure = 'checked="checked"'; } else { $isNonSecure = 'checked="checked"'; $isSecure = ''; } } if (empty($st_username)) { $st_username = ""; } if (empty($st_pulldownlogo)) { $st_pulldownlogo = "//sd.sharethis.com/disc/images/Logo_Area.png"; } if (empty($pulldown_scrollpx)) { $pulldown_scrollpx = ''; } if (empty($st_current_type)) { $st_current_type = "_large"; //$st_current_type_from_db="_large"; } if (empty($services)) { $services = "facebook,twitter,linkedin,email,sharethis,fblike,plusone,pinterest"; } if (empty($st_prompt)) { //$services.=",instagram"; update_option('st_prompt', 'true'); } if (empty($tags)) { $tagsFromDb = ''; foreach (explode(',', $services) as $svc) { $tags .= "<span class='st_" . $svc . "_large' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='" . $svc . "'></span>"; $tagsFromDb .= "<span class='st_" . $svc . "_large' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='" . $svc . "'></span>"; } } if (empty($st_widget_version)) { $st_widget_version = "5x"; } if (empty($st_hoverbarServices)) { $st_hoverbarServices = ''; } if (empty($st_pulldownbarServices)) { $st_pulldownbarServices = ''; } if (empty($cns_settings)) { $cns_settings = ''; } $widgetTag = stripslashes(get_option('st_widget')); if (empty($publisher_id)) { $toShow = ""; // Re-generate new random publisher key $publisher_id = trim(makePkey()); } else { $toShow = $widgetTag; } /* Pulls the scrollpx value for the pull down bar */ $a = preg_replace('~[\\r\\n]+~', '', $toShow); if (preg_match('/pulldownbar/', $a)) { $pattern = "/<script(.*?)<\\/script>/"; preg_match_all($pattern, $a, $matches); foreach ($matches[1] as $k => $v) { if (preg_match('/pulldownbar/', $v)) { preg_match("/\"scrollpx\":[\\s\"\\']{0,}(\\d+)[\\s\"\\']{0,}/", $v, $matches); $pulldown_scrollpx = $matches[1]; break; } } } $wpVersion = trim(get_bloginfo('version')); $scriptProtocolCss = ''; if (version_compare($wpVersion, '3.7.1', '<=')) { $scriptProtocolCss = "margin-right:7px;"; } else { $scriptProtocolCss = ''; } $nonceField = ''; if (function_exists('wp_nonce_field')) { $nonceField = wp_nonce_field('st_nonce'); } $stType = 'wordpress' . trim(get_bloginfo('version')); $sharethis_callesi = preg_match('/doNotCopy/', $widgetTag) ? 0 : 1; $include_scripts = '<script type="text/javascript">var switchTo5x=true;</script><script type="text/javascript" src="http://w.sharethis.com/dynamic/stlib/allServices.js"></script><script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script> <script type="text/javascript" src="http://s.sharethis.com/loader.js"></script><link rel="stylesheet" type="text/css" href="http://w.sharethis.com/button/css/buttons.css"></link>'; if (isset($_SERVER['HTTPS'])) { if ($_SERVER['HTTPS'] == "on") { $include_scripts = '<script type="text/javascript">var switchTo5x=true;</script><script type="text/javascript" src="https://ws.sharethis.com/dynamic/stlib/allServices.js"></script><script type="text/javascript" src="https://ws.sharethis.com/button/buttons.js"></script> <script type="text/javascript" src="https://ss.sharethis.com/loader.js"></script><link rel="stylesheet" type="text/css" href="https://ws.sharethis.com/button/css/buttons.css"></link>'; } } print ' <link rel="stylesheet" type="text/css" href="' . $plugin_location . 'css/st_wp_style.css"/> <link rel="stylesheet" type="text/css" href="' . $plugin_location . 'css/stlib_picker.css" /> <script type="text/javascript"> if (typeof(stlib) == "undefined") { var stlib = {}; } if (typeof(stlib_picker) == "undefined") { var stlib_picker = {}; } if (typeof(stlib_preview) == "undefined") { var stlib_preview = {}; } stlib.getButtonConfig = { dest : "website", style : "chickletStyle" } var st_button_state = 1; </script> ' . $include_scripts . ' <script type="text/javascript" src="' . $plugin_location . 'libraries/get-buttons-new.js"></script> <script type="text/javascript" src="' . $plugin_location . 'libraries/stlib_picker.js"></script> <script type="text/javascript" src="' . $plugin_location . 'libraries/stlib_preview.js"></script> <iframe id="settingSaved" name="settingSaved" width="0" height="0"></iframe> <div class="wrap"> <div style="padding:10px;border:1px solid #aaa;background-color:#9fde33;text-align:center;display:none;" id="st_updated">Your options were successfully updated</div> <div id="showLoadingStatus" class="wp_st_showLoadingStatus">Loading please wait...</div> <div id="wp_st_outerContainer" style="width:1000px;"> <div id="st_title" style="width: 100%; height: 38px;"> <div class="wp_st_header_title"> <label>Welcome to ShareThis for WordPress</label> </div> <div class="wp_st_userinfo"> <div id="usernameContainer" style="display:none">You are logged in as : <span id="login_name"></span><span style="float:right;font-size:16px;cursor:pointer;" onclick="st_signOut(\'' . trim(makePkey()) . '\')">Sign out</span></div> <div id="pbukeyContainer" style="display:none">Your publisher key : <span id="login_key"></span></div> </div> </div> <form id="ak_sharethis" name="ak_sharethis" action="' . get_bloginfo('wpurl') . '/wp-admin/index.php" method="post" > ' . $nonceField . ' <fieldset class="options"> <div id="step1" class="wp_st_parentDiv"> <div id="wp_st_header" class="wp_st_headerFooter"> <div class="wp_st_left_navigator"> <img class="wp_st_arrow wp_st_leftarrow" src="' . $plugin_location . 'images/leftArrow.png" onclick="moveToPrevious(st_button_state)" style="display:none"/> <label class="wp_st_backText" onclick="moveToPrevious(st_button_state)" style="display:none">Back : </label> <label class="wp_st_backTitle" style="display:none" onclick="moveToPrevious(st_button_state)">Select Serivce</label> </div> <div class="wp_st_header_middle"> <label id="wp_st_slideTitle">1. Choose Buttons and Options</label> </div> <div class="wp_st_right_navigator"> <label class="wp_st_nextText" onclick="moveToNext(st_button_state)">Next : </label> <label class="wp_st_nextTitle" onclick="moveToNext(st_button_state)">Select Services</label> <img id="st_rightarrow" class="wp_st_arrow wp_st_rightarrow" src="' . $plugin_location . 'images/rightArrow.png" onclick="moveToNext(st_button_state)"/> <input type="submit" id="edit" value="Edit" name="Edit" class="wp_st_editButton"/> </div> </div> <div id="wp_st_mainbody"> <div class="wp_st_centerContainer1"> <div id="getchicklet" class="configChooser hcountStyleConfig vcountStyleConfig chickletStyleConfig wp_st_show"> <div class="wp_st_previewDiv"> <span>Preview (or Current Configuration):</span> <div id="barPreview1" class="wp_st_barPreview1"> <div class="wp_st_bartext"> <div class="wp_st_barPreviewHeader">Look to the side!</div> <div class="wp_st_barPreviewText">Preview your bar at the side of the page</div> </div> </div> <div id="preview" style="margin-top:30px;font-size:30px;"></div> <div id="errorMessage" style="margin-top:30px;font-size:30px;" class="wp_st_error_message"></div> <div id="barPreview2" class="wp_st_barPreview2"> <div class="wp_st_bartext"> <div class="wp_st_barPreviewHeader">Look to the side!</div> <div class="wp_st_barPreviewText">Preview your bar at the side of the page</div> </div> </div> <div id="barPreview3" class="wp_st_barPreview3"> <div class="wp_st_bartext"> <div class="wp_st_barPreviewHeader">Look Up!</div> <div class="wp_st_barPreviewText">Preview your bar at the top of the page</div> </div> </div> </div> </div> </div> <hr id="wp_st_separator"/> <!-- STEP 1 --> <div id="st_step1" class="wp_st_centerContainer2"> <div id="wp_st_styleLinks" class="linksDiv"> <h1 class="nonbars">Choose a button style:</h1> <h1 class="bars wp_st_show">Choose more options</h1> <div style="clear:both;"></div> <div class="wp_st_widget5x"> <ul class="nonbars" style="padding-left:80px"> <li class="wp_st_styleLink chickletStyle jqBtnStyle" id="chickletStyle"><div class="wp_st_hoverState2 chickletStyle"></div><div class="wp_st_hoverState chickletStyle">Prominent, yet minimalistic, the classic style of these buttons display sharing icons in 2 different sizes (16x16 & 32x32).</div><img src="' . $plugin_location . 'images/Button4.png" class="wp_st_chickletStyleButtonImg"/></li> <li class="wp_st_styleLink hcountStyle jqBtnStyle" id="hcountStyle"><div class="wp_st_hoverState2 hcountStyle"></div><div class="wp_st_hoverState hcountStyle">Sharing buttons with horizontal counters to publicly display the sharing activity for that piece of content.</div><img src="' . $plugin_location . 'images/HORZ.png" class="wp_st_hcountStyleButtonImg"/></li> <li class="wp_st_styleLink vcountStyle jqBtnStyle" id="vcountStyle"><div class="wp_st_hoverState2 vcountStyle"></div><div class="wp_st_hoverState vcountStyle">Sharing buttons with vertical counters to publicly display the sharing activity for that piece of content.</div><img src="' . $plugin_location . 'images/VERT.png" class="wp_st_vcountStyleButtonImg"/></li> </ul> <ul style="width:100px"> <li style="border:0px" class="wp_st_inputBoxLI"> <div id="selectSizeType" class="wp_st_selectSizeType"> <div>Button Size :</div> <div><input type="radio" name="selectSize_type" value="16x16"/> Small</div> <div><input checked="true" type="radio" name="selectSize_type" value="32x32"/> Large</div> </div> </li> </ul> </div> <div class="wp_st_vseparator" style="height:478px; margin-top: -25px"> <hr/> </div> <div class="wp_st_widget4x"> <ul class="bars wp_st_show" style="padding-left:80px"> <li class="wp_st_styleLink jqBarStyle hoverbarStyle" id="hoverbarStyle"><div class="wp_st_hoverState2 hoverbarStyle"></div><div class="wp_st_hoverState hoverbarStyle">This bar can float either on the left side or the right side of the page to provide an always-visible view of the sharing tools.</div><img id="hoverBarImage" src="' . $plugin_location . 'images/HOVER_Buttons.png" class="wp_st_hoverbarStyleButtonImg"/><img id="hoverbarLoadingImg" src="' . $plugin_location . 'images/loading.gif" class="wp_st_loadingImage" style="display:none"/></li> <li class="wp_st_styleLink jqBarStyle pulldownStyle" id="pulldownStyle"><div class="wp_st_hoverState2 pulldownStyle"></div><div class="wp_st_hoverState pulldownStyle">This bar with sharing buttons is placed at the top of page, but appears only when the reader scrolls down.</div><img id="pullDownBarImage" src="' . $plugin_location . 'images/PULLDOWN.png" class="wp_st_pulldownStyleButtonImg"/><img id="pulldownLoadingImg" src="' . $plugin_location . 'images/loading.gif" class="wp_st_loadingImage" style="display:none"/></li> </ul> <ul style="width:100px"> <li style="border:0px" class="wp_st_inputBoxLI"><div class="btnDiv" > <div id="hoverbar_selectDock" class="wp_st_hoverbar_selectDock"> <div>Docking Position :</div> <div><input type="radio" value="left" name="selectDock_type"/> Left</div> <div><input checked="true" type="radio" value="right" name="selectDock_type"/> Right</div> </div> </div> </li> <li class="wp_st_pulldownCustomization wp_st_inputBoxLI" style="border:0px" > <span id="st_configure_pulldown" style="display:none"> Configure it!</span> </li> </ul> </div> <div style="clear:both;" class="bars wp_st_show"></div> </div> </div> <div id="st_pulldownConfig" class="wp_st_pulldownConfig" style="display:none;"> <h3 style="margin-left:5px">Customize PullDownBar:</h3> <ul> <li> <div id="pulldown_selectDock" class="wp_st_pulldown_selectDock"> <label style="margin-right:138px;">Logo URL:</label> <input class="wp_st_pulldown_optionsTextbox" id="pulldown_optionsTextbox_id" name="pulldown_optionsTextbox_id" type="textbox" value="" data-value=""/><span class="pulldown_previewButton">Update Preview</span> </div> </li> <li> <div id="pulldown_selectDock" class="wp_st_pulldown_selectDock"> <span> <label style="margin-right:100px;">Scroll Height (px):</label><input style="width:10%;margin-bottom:0px;margin-left:5px" class="wp_st_pulldown_optionsTextbox" id="selectScrollHeight_id" name="selectScrollHeight_id" type="textbox" value="50" data-value=""/> </span> </div> </li> </ul> </div> <!-- STEP 2 --> <div id="st_step2" class="wp_st_centerContainer2" style="display:none;"> <div style="height:230px;text-align: center;"> <div id="mySPicker"></div> </div> </div> <!-- STEP 3 --> <div id="st_step3" class="wp_st_centerContainer2" style="display:none;"> </div> <div id="st_splServiceContainer" class="wp_st_splServiceContainer"> </div> <!-- STEP 4 --> <div id="st_step4" class="wp_st_centerContainer2" style="display:none;"> <div style="height:118px;text-align: center;"> <div id="" class="wp_st_widget5x"> <div class="wp_st_copynshare_heading"> <span id="wp_st_copynshare">Enable CopyNShare</span> </div> <div> <div class="wp_st_copynshare_text"> <p class="">CopyNShare is the new ShareThis widget feature that enables you to track the shares that occur when a user copies and pastes your websites URL or content</p> </div> <div id="st_cns_settings" class="wp_st_copynshare_checkboxes"> <input type="checkbox" class="cnsCheck wp_st_defaultCursor" id="donotcopy" name="donotcopy" value="true" ></input> <label for="donotcopy" class="cnsCheck" id="wp_st_donotcopy_label"> Measure copy and shares of your website\'s content</label> <br /> <br /> <input type="checkbox" class="cnsCheck wp_st_defaultCursor" id="hashaddress" name="hashaddress" value="false" ></input> <label for="hashaddress" class="cnsCheck" id="wp_st_hashaddress_label"> Measure copy and shares of your website\'s URLs</label> </div> </div> </div> </div> <hr id="wp_st_separator"> <div style="height:auto;text-align: center;margin-top:15px;"> <div> <div class="wp_st_customizewidget_heading" style="padding-bottom:5px;"> <span>Customize Widget Position</span> </div> <div class="wp_st_customizewidget_options"> <div> <div style="float:left;font-size:15px;"> <span>Pages</span> </div> <div style="margin-top: 5px;font-size:15px;margin-left:301px;"> <span>Posts</span> </div> </div> <div style="margin-top:10px;"> <div style="float:left;"> <span style="cursor:auto;"><input id="st_pages_on_top" class="cnsCheck wp_st_defaultCursor" type="checkbox" value="top" name="st_pages_on_top" ' . $checkPagesTop . '></span> <span>Show buttons on <strong style="font-family: sans-serif;font-weight:bold;">top of pages</strong></span> </div> <div style="margin-top: 5px"> <span style="cursor:auto;margin-left:264px"><input id="st_posts_on_top" class="cnsCheck wp_st_defaultCursor" type="checkbox" value="top" name="st_posts_on_top" onclick="setPostExcerpt()" ' . $checkPostsTop . '></span> <span>Show buttons on <strong style="font-family: sans-serif;font-weight:bold;">top of posts</strong></span> </div> </div> <div> <div style="float:left;"> <span style="cursor:auto;"><input id="st_pages_on_bot" class="cnsCheck wp_st_defaultCursor" type="checkbox" value="bot" name="st_pages_on_bot" ' . $checkPagesBot . '></span> <span>Show buttons on <strong style="font-family: sans-serif;font-weight:bold;">bottom of pages</strong></span> </div> <div style="margin-top: 7px"> <span style="cursor:auto;margin-left:264px;"><input id="st_posts_on_bot" class="cnsCheck wp_st_defaultCursor" type="checkbox" value="bot" name="st_posts_on_bot" onclick="setPostExcerpt()" ' . $checkPostsBot . '></span> <span>Show buttons on <strong style="font-family: sans-serif;font-weight:bold;">bottom of posts</strong></span> </div> </div> </div> <div style="margin-bottom:30px;"></div> <div class="wp_st_customizewidget_heading" style="padding-bottom:5px;"> <span>Customize Post Excerpts</span> </div> <div> <div style="float:left;"> <div style="margin-top: 7px"> <span style="cursor:auto;margin-left:52px;"><input id="st_post_excerpt" class="cnsCheck wp_st_defaultCursor" type="checkbox" value="true" name="st_post_excerpt" ' . $checkPostExcerpt . '></span> <span>Show buttons on <strong style="font-family: sans-serif;font-weight:bold;">Post Excerpt</strong></span> </div> </div> </div> <div style="margin-bottom:50px;"></div> <div class="wp_st_customizewidget_heading"> <span class="heading"> <span id="headingimgPageList" class="headingimgPageList_right"></span> Manage Page Exceptions </span> </div> <br/> <div id="divPageList" style="display:none;"> <div class="wp_st_customizewidget_heading"> <span style="font-size:12px;">Do <strong style="font-family: sans-serif;font-weight:bold;"><i>not</i></strong> show on</span> </div> <div style="border: 1px solid #AAAAAA; overflow: auto; width: 43%; margin-left: 50px; height: 180px;margin-top:5px;"> ' . st_get_list_of_pages() . ' </div> </div> </div> </div> </div> <!-- STEP 5 --> <div id="st_step5" class="wp_st_centerContainer2" style="display:none;"> <div id="loginWindowDiv" class="wp_st_loginWindowDiv"> <div id="signInBlock" style="height:110px;"> <div><h1 style="margin-top: 50px;">To get detailed analytics about sharing done on your site, please Sign In.</h1> <span id="winSignin" class="step5SignInBtn">Sign In</span></div> </div> <!--<iframe id="loginFrame" width="644px" height="398px" frameborder="0" src="//www.sharethis.com/external-login?pluginType=newPlugins"></iframe>--> <div class="wp_st_login_message">You are successfully logged-in with ShareThis.</div> </div> </div> <!-- STEP 6 --> <div id="st_step6" class="wp_st_centerContainer2" style="display:none;"> <div id="st_additional_options" class="wp_st_additional_options"> </div> <div style="margin-left: -367px;"> <h1><span class="heading" style="font-size:18px"> <span id="codeToggle" class="headingimg_right" style="left:249px;left:240px\\9;"></span> View & edit code: </span></h1> </div> <div id="codeDiv" style="display:none;"> <div id="divScripTag" style="background:#ECECEC;display:inline-block;padding:5px;"> <div style="float: left;color:#36759A;">Modify script tags<a style="padding-left:5px;" href="//support.sharethis.com/customer/portal/articles/464663-customize-functionality" title="Customize Functionality" target="_blank"><img src="' . $plugin_location . 'images/QUESTION_Icon.png" /></a></div> <div style="float: left; margin-left: 288px;color:#36759A;margin-top:1px;"><input type="radio" name="protocolType" id="typehttp" value="http" ' . $isNonSecure . ' style="' . $scriptProtocolCss . '"/>http </div> <div style="float:left;color:#36759A;"><input type="radio" name="protocolType" id="typehttps" value="https" ' . $isSecure . ' style="' . $scriptProtocolCss . '" />https<a style="padding-left:5px;" href="//support.sharethis.com/customer/portal/articles/475097-ssl-support" title="SSL Support" target="_blank"><img src="' . $plugin_location . 'images/QUESTION_Icon.png" /></a></div> </div> <div style="clear:both;"><textarea id="st_widget" name="st_widget" style="height: 150px; width: 525px;font-size:12px;">' . htmlspecialchars($toShow) . '</textarea></div> <div> </div> <div id="divHtmlTag" style="background:#ECECEC;display:inline-block;padding:5px;width:517px;text-align:left;"> <div style="float: left;color:#36759A;">Modify HTML tags<a style="padding-left:5px;" href="//support.sharethis.com/customer/portal/articles/475079-share-properties-and-sharing-custom-information#Properties_Tags" title="Share Properties and Sharing Custom Information" target="_blank"><img src="' . $plugin_location . 'images/QUESTION_Icon.png" /></a></div> </div> <div style="clear:both;"><textarea id="st_tags" name="st_tags" style="height: 150px; width: 525px;font-size:12px;">' . htmlspecialchars($tags) . '</textarea></div> </div> </div> <div id="lastStep" style="padding-bottom:0px;"><input type="submit" id="wp_st_savebutton" value="SAVE" name="submit_button" value="' . __('Update ShareThis Options', 'sharethis') . '" style="display:none;"/></div> <div id="wp_st_footer" class="wp_st_headerFooter"> <div class="wp_st_left_navigator" > <img class="wp_st_arrow wp_st_leftarrow " src="' . $plugin_location . 'images/leftArrow.png" onclick="moveToPrevious(st_button_state)" style="display:none"/> <label class="wp_st_backText" onclick="moveToPrevious(st_button_state)" style="display:none">Back : </label> <label class="wp_st_backTitle" style="display:none" onclick="moveToPrevious(st_button_state)">Select Serivce</label> </div> <div class="wp_st_footer_middle"> <div id="wp_st_stepfooter">Step 1 of 6</div> <div id="wp_st_navDots"> <div class="wp_st_navSlideDot wp_st_slideSelected" id="navDotSlide1" value="1"> </div> <div class="wp_st_navSlideDot" id="navDotSlide2" value="2"> </div> <div class="wp_st_navSlideDot" id="navDotSlide3" value="3"> </div> <div class="wp_st_navSlideDot" id="navDotSlide4" value="4"> </div> <div class="wp_st_navSlideDot" id="navDotSlide5" value="5"> </div> <div class="wp_st_navSlideDot" id="navDotSlide6" value="6"> </div> </div> </div> <div class="wp_st_right_navigator" style="position:relative;right:6px;"> <label class="wp_st_nextText" onclick="moveToNext(st_button_state)">Next : </label> <label class="wp_st_nextTitle" onclick="moveToNext(st_button_state)">Select Services</label> <img class="wp_st_arrow wp_st_rightarrow" src="' . $plugin_location . 'images/rightArrow.png" onclick="moveToNext(st_button_state)"/> </div> </div> </div> </div> <script src="' . $plugin_location . 'js/sharethis.js" type="text/javascript"></script> </fieldset> <input type="hidden" id="is_hoverbar_selected" value=""/> <input type="hidden" id="is_copynshre_selected" value=""/> <input type="hidden" name="st_action" value="st_update_settings" /> <input type="hidden" name="st_version" id="st_version" value="' . $st_widget_version . '"/> <input type="hidden" name="st_services" id="st_services" value="' . $services . '"/> <input type="hidden" name="st_current_type" id="st_current_type" value="' . $st_current_type . '"/> <input type="hidden" name="st_current_type_from_db" id="st_current_type_from_db" value="' . $st_current_type_from_db . '"/> <input type="hidden" name="st_tags_from_db" id="st_tags_from_db" value="' . htmlspecialchars($tagsFromDb) . '"/> <input type="hidden" name="st_script_tags_from_db" id="st_script_tags_from_db" value="' . htmlspecialchars($toShow) . '"/> <input type="hidden" name="st_type" id="st_type" value="' . $stType . '"/> <input type="hidden" name="st_pkey" id="st_pkey" value="' . htmlspecialchars($publisher_id) . '"/> <input type="hidden" name="st_user_name" id="st_user_name" value="' . $st_username . '"/> <input type="hidden" name="selectedBar" id="st_selected_bar" value=""/> <input type="hidden" name="hoverbar[position]" id="st_hoverbar_position" value=""/> <input type="hidden" name="hoverbar[services]" id="st_hoverbar_services" value="' . $st_hoverbarServices . '"/> <input type="hidden" name="pulldownbar[scrollpx]" id="st_pulldownbar_scrollpx" value="' . $pulldown_scrollpx . '"/> <input type="hidden" name="pulldownbar[logo]" id="st_pulldownbar_logo" value="' . $st_pulldownlogo . '"/> <input type="hidden" name="pulldownbar[services]" id="st_pulldownbar_services" value="' . $st_pulldownbarServices . '"/> <input type="hidden" name="copynshareSettings" id="copynshareSettings" value="' . $cns_settings . '"/> <input type="hidden" name="st_callesi" id="st_callesi" value="' . $sharethis_callesi . '" /> <input type="hidden" id="freshInstalation" value="' . $freshInstalation . '"/> </form> </div> </div> '; }
function st_options_form() { $plugin_location = WP_PLUGIN_URL . '/' . str_replace(basename(__FILE__), "", plugin_basename(__FILE__)); $publisher_id = get_option('st_pubid'); $services = get_option('st_services'); $tags = get_option('st_tags'); $st_current_type = get_option('st_current_type'); $st_widget_version = get_option('st_version'); $st_prompt = get_option('st_prompt'); $st_username = get_option('st_username'); $st_pulldownlogo = get_option('st_pulldownlogo'); $freshInstalation = empty($services) ? 1 : 0; if (empty($st_username)) { $st_username = ""; } if (empty($st_pulldownlogo)) { $st_pulldownlogo = "http://sd.sharethis.com/disc/images/Logo_Area.png"; } if (empty($st_current_type)) { $st_current_type = "_large"; } if (empty($services)) { $services = "facebook,twitter,linkedin,email,sharethis,fblike,plusone,pinterest"; } if (empty($st_prompt)) { //$services.=",instagram"; update_option('st_prompt', 'true'); } if (empty($tags)) { foreach (explode(',', $services) as $svc) { $tags .= "<span class='st_" . $svc . "_large' st_title='<?php the_title(); ?>' st_url='<?php the_permalink(); ?>' displayText='" . $svc . "'></span>"; } } if (empty($st_widget_version)) { $st_widget_version = "5x"; } /* Retrives widget version from the database */ $widget5xSelected = ""; $widget4xSelected = ""; if ($st_widget_version == "5x") { $widget5xSelected = "selected"; } else { if ($st_widget_version == "4x") { $widget4xSelected = "selected"; } } if (get_option('st_add_to_content') != 'no') { $st_add_to_contentYes = ' selected="selected" '; $st_add_to_contentNo = ""; } else { $st_add_to_contentYes = ""; $st_add_to_contentNo = ' selected="selected" '; } if (get_option('st_add_to_page') != 'no') { $st_add_to_pageYes = ' selected="selected" '; $st_add_to_pageNo = ""; } else { $st_add_to_pageYes = ""; $st_add_to_pageNo = ' selected="selected" '; } $widgetTag = get_option('st_widget'); if (empty($publisher_id)) { $toShow = ""; // Re-generate new random publisher key $publisher_id = trim(makePkey()); } else { $toShow = $widgetTag; } /* Pulls the theme ID for the sharenow feature*/ if (preg_match('/serviceWidget/', $toShow)) { $pattern = "/<script(.*?)<\\/script>/"; preg_match_all($pattern, $toShow, $matches); foreach ($matches[1] as $k => $v) { if (preg_match('/serviceWidget/', $v)) { preg_match("/style(.*):[\\s\"\\']{0,}(\\d)[\\s\"\\']{0,}/", $v, $matches); $sharenow_style = $matches[2]; break; } } } /* Pulls the scrollpx value for the pull down bar */ if (preg_match('/pulldownbar/', $toShow)) { $pattern = "/<script(.*?)<\\/script>/"; preg_match_all($pattern, $toShow, $matches); foreach ($matches[1] as $k => $v) { if (preg_match('/pulldownbar/', $v)) { preg_match("/scrollpx(.*):[\\s\"\\']{0,}(\\d+)[\\s\"\\']{0,}/", $v, $matches); $pulldown_scrollpx = $matches[2]; break; } } } $sharethis_callesi = preg_match('/doNotCopy/', $widgetTag) ? 0 : 1; print ' <link rel="stylesheet" type="text/css" href="' . $plugin_location . 'css/st_wp_style.css"/> <link rel="stylesheet" type="text/css" href="' . $plugin_location . 'css/stlib_picker.css" /> <script type="text/javascript"> if (typeof(stlib) == "undefined") { var stlib = {}; } if (typeof(stlib_picker) == "undefined") { var stlib_picker = {}; } if (typeof(stlib_preview) == "undefined") { var stlib_preview = {}; } stlib.getButtonConfig = { dest : "website", style : "chickletStyle" } var st_button_state = 1;</script> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"></script> <script type="text/javascript" src="http://w.sharethis.com/dynamic/stlib/allServices.js"></script> <script type="text/javascript" src="http://w.sharethis.com/button/buttons.js"></script> <script type="text/javascript" src="http://s.sharethis.com/loader.js"></script> <script type="text/javascript" src="http://sharethis.com/js/new/json2.js"></script> <script type="text/javascript" src="http://sharethis.com/js/new/jquery.autocomplete.js"></script> <script type="text/javascript" src="http://sharethis.com/js/new/jquery.colorbox.js"></script> <script type="text/javascript" src="' . $plugin_location . 'libraries/get-buttons-new.js"></script> <link rel="stylesheet" type="text/css" href="http://w.sharethis.com/button/css/buttons.css"></link> <script type="text/javascript" src="' . $plugin_location . 'libraries/stlib_picker.js"></script> <script type="text/javascript" src="' . $plugin_location . 'libraries/stlib_preview.js"></script> <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(["_setAccount", "UA-1645146-1"]); _gaq.push(["_trackPageview"]); (function() { var ga = document.createElement("script"); ga.type = "text/javascript"; ga.async = true; ga.src = ("https:" == document.location.protocol ? "https://ssl" : "http://www") + ".google-analytics.com/ga.js"; var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(ga, s); })(); </script> <iframe id="settingSaved" name="settingSaved" width="0" height="0"></iframe> <div class="wrap"> <div style="padding:10px;border:1px solid #aaa;background-color:#9fde33;text-align:center;display:none;" id="st_updated">Your options were successfully updated</div> <div id="showLoadingStatus" class="wp_st_showLoadingStatus">Loading...</div> <div id="wp_st_outerContainer" style="width:1000px;"> <div id="st_title" style="width: 100%; height: 38px;"> <div class="wp_st_header_title"> <label>Welcome to ShareThis for WordPress</label> </div> <div class="wp_st_userinfo"> <div id="usernameContainer" style="display:none">You are logged in as : <span id="login_name"></span></div> <div id="pbukeyContainer" style="display:none">Your publisher key : <span id="login_key"></span></div> </div> </div> <form id="ak_sharethis" name="ak_sharethis" action="' . get_bloginfo('wpurl') . '/wp-admin/index.php" method="post" > <fieldset class="options"> <div id="step1" class="wp_st_parentDiv"> <div id="wp_st_header" class="wp_st_headerFooter"> <div class="wp_st_left_navigator"> <img class="wp_st_arrow wp_st_leftarrow" src="' . $plugin_location . 'images/leftArrow.png" onclick="moveToPrevious(st_button_state)" style="display:none"/> <label class="wp_st_backText" onclick="moveToPrevious(st_button_state)" style="display:none">Back : </label> <label class="wp_st_backTitle" style="display:none" onclick="moveToPrevious(st_button_state)">Select Serivce</label> </div> <div class="wp_st_header_middle"> <label id="wp_st_slideTitle">1. Choose Buttons and Options</label> </div> <div class="wp_st_right_navigator"> <label class="wp_st_nextText" onclick="moveToNext(st_button_state)">Next : </label> <label class="wp_st_nextTitle" onclick="moveToNext(st_button_state)">Select Services</label> <img id="st_rightarrow" class="wp_st_arrow wp_st_rightarrow" src="' . $plugin_location . 'images/rightArrow.png" onclick="moveToNext(st_button_state)"/> <input type="submit" id="edit" value="Edit" name="Edit" class="wp_st_editButton"/> </div> </div> <div id="wp_st_mainbody"> <div class="wp_st_centerContainer1"> <div id="getchicklet" class="configChooser hcountStyleConfig vcountStyleConfig chickletStyleConfig wp_st_show"> <div class="wp_st_previewDiv"> <span>Preview (or Current Configuration):</span> <div id="barPreview1" class="wp_st_barPreview1"> <div class="wp_st_bartext"> <div class="wp_st_barPreviewHeader">Look to the side!</div> <div class="wp_st_barPreviewText">Preview your bar at the side of the page</div> </div> </div> <div id="preview" style="margin-top:30px;"></div> <div id="barPreview2" class="wp_st_barPreview2"> <div class="wp_st_bartext"> <div class="wp_st_barPreviewHeader">Look to the side!</div> <div class="wp_st_barPreviewText">Preview your bar at the side of the page</div> </div> </div> <div id="barPreview3" class="wp_st_barPreview3"> <div class="wp_st_bartext"> <div class="wp_st_barPreviewHeader">Look Up!</div> <div class="wp_st_barPreviewText">Preview your bar at the top of the page</div> </div> </div> </div> </div> </div> <hr id="wp_st_separator"/> <!-- STEP 1 --> <div id="st_step1" class="wp_st_centerContainer2"> <div id="wp_st_styleLinks" class="linksDiv"> <h1 class="nonbars">Choose a button style:</h1> <h1 class="bars wp_st_show">Choose more options</h1> <div style="clear:both;"></div> <div class="wp_st_widget5x"> <ul class="nonbars" style="padding-left:80px"> <li class="wp_st_styleLink chickletStyle jqBtnStyle" id="chickletStyle"><div class="wp_st_hoverState2 chickletStyle"></div><div class="wp_st_hoverState chickletStyle">Prominent, yet minimalistic, the classic style of these buttons display sharing icons in 2 different sizes (16x16 & 32x32).</div><img src="' . $plugin_location . 'images/Button4.png" class="wp_st_chickletStyleButtonImg"/></li> <li class="wp_st_styleLink hcountStyle jqBtnStyle" id="hcountStyle"><div class="wp_st_hoverState2 hcountStyle"></div><div class="wp_st_hoverState hcountStyle">Sharing buttons with horizontal counters to publicly display the sharing activity for that piece of content.</div><img src="' . $plugin_location . 'images/HORZ.png" class="wp_st_hcountStyleButtonImg"/></li> <li class="wp_st_styleLink vcountStyle jqBtnStyle" id="vcountStyle"><div class="wp_st_hoverState2 vcountStyle"></div><div class="wp_st_hoverState vcountStyle">Sharing buttons with vertical counters to publicly display the sharing activity for that piece of content.</div><img src="' . $plugin_location . 'images/VERT.png" class="wp_st_vcountStyleButtonImg"/></li> </ul> <ul style="width:100px"> <li style="border:0px" class="wp_st_inputBoxLI"> <div id="selectSizeType" class="wp_st_selectSizeType"> <div>Chicklet Size :</div> <div><input type="radio" name="selectSize_type" value="16x16"/> Small</div> <div><input checked="true" type="radio" name="selectSize_type" value="32x32"/> Large</div> </div> </li> </ul> </div> <div class="wp_st_vseparator" style="height:500px; margin-top: -31px"> <hr/> </div> <div class="wp_st_widget4x"> <ul class="bars wp_st_show" style="padding-left:80px"> <li class="wp_st_styleLink jqBarStyle hoverbarStyle" id="hoverbarStyle"><div class="wp_st_hoverState2 hoverbarStyle"></div><div class="wp_st_hoverState hoverbarStyle">This bar can float either on the left side or the right side of the page to provide an always-visible view of the sharing tools.</div><img id="hoverBarImage" src="' . $plugin_location . 'images/HOVER_Buttons.png" class="wp_st_hoverbarStyleButtonImg"/><img id="hoverbarLoadingImg" src="' . $plugin_location . 'images/loading.gif" class="wp_st_loadingImage" style="display:none"/></li> <li class="wp_st_styleLink jqBarStyle pulldownStyle" id="pulldownStyle"><div class="wp_st_hoverState2 pulldownStyle"></div><div class="wp_st_hoverState pulldownStyle">This bar with sharing buttons is placed at the top of page, but appears only when the reader scrolls down.</div><img id="pullDownBarImage" src="' . $plugin_location . 'images/PULLDOWN.png" class="wp_st_pulldownStyleButtonImg"/><img id="pulldownLoadingImg" src="' . $plugin_location . 'images/loading.gif" class="wp_st_loadingImage" style="display:none"/></li> <li class="wp_st_styleLink jqShareNow fbStyle" id="fbStyle"><div class="wp_st_hoverState2 fbStyle"></div><div class="wp_st_hoverState fbStyle">ShareNow allows any publisher to leverage Facebook frictionless sharing without having to create their own solution.</div><img id="shareNowImage" src="' . $plugin_location . 'images/ShareNow_Button.png" class="wp_st_sharebarStyleButtonImg"/><img id="sharenowLoadingImg" src="' . $plugin_location . 'images/loading.gif" class="wp_st_loadingImage" style="display:none"/></li> </ul> <ul style="width:100px"> <li style="border:0px" class="wp_st_inputBoxLI"><div class="btnDiv" > <div id="hoverbar_selectDock" class="wp_st_hoverbar_selectDock"> <div>Docking Position :</div> <div><input type="radio" value="left" name="selectDock_type"/> Left</div> <div><input checked="true" type="radio" value="right" name="selectDock_type"/> Right</div> </div> </div> </li> <li class="wp_st_pulldownCustomization wp_st_inputBoxLI" style="border:0px" > <span id="st_configure_pulldown" style="display:none"> Configure it!</span> </li> <li class="wp_st_shareNowCustomization wp_st_inputBoxLI" style="border:0px" > <span id="st_customize_sharenow" style="display:none;position:relative;top:5px;"> Customize it!</span> </li> </ul> </div> <div style="clear:both;" class="bars wp_st_show"></div> </div> </div> <div id="wp_st_slidingContainer" style="display:none;"> <h3 style="margin-left:5px">Customize ShareNow:</h3> <ul id="themeList" class="wp_st_subOptions"> <li data-value="3" class="wp_st_sharenowImg" id="st_sharenowImg3"> <a><img class="widgetIconSelected" id="opt_theme3" src="' . $plugin_location . 'images/fbtheme_3.png"/></a> </li> <li data-value="4" class="wp_st_sharenowImg" id="st_sharenowImg4"> <a><img class="widgetIconSelected" id="opt_theme4" src="' . $plugin_location . 'images/fbtheme_4.png"/></a> </li> <li data-value="5" class="wp_st_sharenowImg" id="st_sharenowImg5"> <a><img class="widgetIconSelected" id="opt_theme5" src="' . $plugin_location . 'images/fbtheme_5.png"/></a> </li> <li data-value="6" class="wp_st_sharenowImg" id="st_sharenowImg6"> <a><img class="widgetIconSelected" id="opt_theme6" src="' . $plugin_location . 'images/fbtheme_6.png"/></a> </li> <li data-value="7" class="wp_st_sharenowImg" id="st_sharenowImg7"> <a><img class="widgetIconSelected" id="opt_theme7" src="' . $plugin_location . 'images/fbtheme_7.png"/></a> </li> </ul> </div> <div id="st_pulldownConfig" class="wp_st_pulldownConfig" style="display:none;"> <h3 style="margin-left:5px">Customize PullDownBar:</h3> <ul> <li> <div id="pulldown_selectDock" class="wp_st_pulldown_selectDock"> <label style="margin-right:138px;">Logo URL:</label> <input class="wp_st_pulldown_optionsTextbox" id="pulldown_optionsTextbox_id" name="pulldown_optionsTextbox_id" type="textbox" value="" data-value=""/><span class="pulldown_previewButton">Update Preview</span> </div> </li> <li> <div id="pulldown_selectDock" class="wp_st_pulldown_selectDock"> <span> <label style="margin-right:100px;">Scroll Height (px):</label><input style="width:10%;margin-bottom:0px;margin-left:5px" class="wp_st_pulldown_optionsTextbox" id="selectScrollHeight_id" name="selectScrollHeight_id" type="textbox" value="50" data-value=""/> </span> </div></li> </ul> </div> <!-- STEP 2 --> <div id="st_step2" class="wp_st_centerContainer2" style="display:none;"> <div style="height:230px;text-align: center;"> <div id="mySPicker"></div> </div> </div> <!-- STEP 3 --> <div id="st_step3" class="wp_st_centerContainer2" style="display:none;"> <div style="height:250px;text-align: center;"> <div id="st_widget5x" class="wp_st_widget5x"> <div style="width:48%; float:left"> <img src="' . $plugin_location . 'images/widget-5x.png"/> </div> <div style="width:48%; float:right;"> <p id="st_5xwidget" class="wp_st_post_heading ' . $widget5xSelected . '" style="width:86%">Multi Post</p> <p class="wp_st_text">Sharing takes place inside the widget, without taking users away from your site. Preferences are saved so your users can share to more than one service at the same time.</p> </div> </div> <div class="wp_st_vseparator"> <hr/> </div> <div id="st_widget4x" class="wp_st_widget4x"> <div style="width:48%; float:left;position: relative"> <img src="' . $plugin_location . 'images/widget-4x.png"/> </div> <div style="width:48%; float:right"> <p id="st_4xwidget" class="wp_st_post_heading ' . $widget4xSelected . '" style="width:86%">Direct Post</p> <p class="wp_st_text">Your users will be redirected to Facebook, Twitter, etc when clicking on the corresponding buttons. The widget is opened when users click on "Email" and "ShareThis".</p> </div> </div> </div> </div> <div id="st_splServiceContainer" class="wp_st_splServiceContainer"> </div> <!-- STEP 4 --> <div id="st_step4" class="wp_st_centerContainer2" style="display:none;"> <div style="height:175px;text-align: center;"> <div id="" class="wp_st_widget5x"> <div class="wp_st_copynshare_heading"> <span id="wp_st_copynshare">Enable CopyNShare</span> </div> <div> <div class="wp_st_copynshare_image"> <img src="' . $plugin_location . 'images/copynshare.jpg"/> </div> <div class="wp_st_copynshare_text"> <p class="">CopyNShare is the new ShareThis widget feature that enables you to track the shares that occur when a user copies and pastes your websites URL or content</p> </div> <div id="st_cns_settings" class="wp_st_copynshare_checkboxes"> <input type="checkbox" class="cnsCheck wp_st_defaultCursor" id="donotcopy" name="donotcopy" value="true" ></input> <label for="donotcopy" class="cnsCheck wp_st_defaultCursor" id="wp_st_donotcopy_label"> Measure copy and shares of your website\'s content</label> <br /> <br /> <input type="checkbox" class="cnsCheck wp_st_defaultCursor" id="hashaddress" name="hashaddress" value="false" ></input> <label for="hashaddress" class="cnsCheck wp_st_defaultCursor" id="wp_st_hashaddress_label"> Measure copy and shares of your website\'s URLs</label> </div> </div> </div> </div> <div style="height:175px;text-align: center;"> <div> <div class="wp_st_customizewidget_heading"> <span>Customize Widget Position</span> </div> <div class="wp_st_customizewidget_options"> <div style="margin-top: 5px"> <span style="cursor:auto;">Automatically add ShareThis to your posts?</span> <span style="margin-left: 10px"><select name="st_add_to_content" id="st_add_to_content"> <option value="yes"' . $st_add_to_contentYes . '>Yes</option> <option value="no"' . $st_add_to_contentNo . '>No</option> </select></span> </div> <div style="margin-top: 7px"> <span style="cursor:auto;position: relative; left: 2px;">Automatically add ShareThis to your pages?</span> <span style="margin-left: 10px;position:relative;left:-2px;"><select name="st_add_to_page" id="st_add_to_page"> <option value="yes"' . $st_add_to_pageYes . '>Yes</option> <option value="no"' . $st_add_to_pageNo . '>No</option> </select></span> </div> </div> </div> </div> </div> <!-- STEP 5 --> <div id="st_step5" class="wp_st_centerContainer2" style="display:none;"> <div id="loginWindowDiv" class="wp_st_loginWindowDiv"> <iframe id="loginFrame" width="644px" height="398px" frameborder="0" src="http://sharethis.com/external-login?pluginType=newPlugins"></iframe> <div class="wp_st_login_message">You are successfully logged-in with ShareThis.</div> </div> </div> <!-- STEP 6 --> <div id="st_step6" class="wp_st_centerContainer2" style="display:none;"> <div id="st_additional_options" class="wp_st_additional_options"> </div> </div> <div id="wp_st_footer" class="wp_st_headerFooter"> <div class="wp_st_left_navigator" > <img class="wp_st_arrow wp_st_leftarrow " src="' . $plugin_location . 'images/leftArrow.png" onclick="moveToPrevious(st_button_state)" style="display:none"/> <label class="wp_st_backText" onclick="moveToPrevious(st_button_state)" style="display:none">Back : </label> <label class="wp_st_backTitle" style="display:none" onclick="moveToPrevious(st_button_state)">Select Serivce</label> </div> <div class="wp_st_footer_middle"> <div id="wp_st_stepfooter">Step 1 of 6</div> <div id="wp_st_navDots"> <div class="wp_st_navSlideDot wp_st_slideSelected" id="navDotSlide1" value="1"> </div> <div class="wp_st_navSlideDot" id="navDotSlide2" value="2"> </div> <div class="wp_st_navSlideDot" id="navDotSlide3" value="3"> </div> <div class="wp_st_navSlideDot" id="navDotSlide4" value="4"> </div> <div class="wp_st_navSlideDot" id="navDotSlide5" value="5"> </div> <div class="wp_st_navSlideDot" id="navDotSlide6" value="6"> </div> </div> </div> <div class="wp_st_right_navigator" style="position:relative;right:6px;"> <label class="wp_st_nextText" onclick="moveToNext(st_button_state)">Next : </label> <label class="wp_st_nextTitle" onclick="moveToNext(st_button_state)">Select Services</label> <img class="wp_st_arrow wp_st_rightarrow" src="' . $plugin_location . 'images/rightArrow.png" onclick="moveToNext(st_button_state)"/> </div> </div> </div> </div> <div><input type="submit" onclick="st_log();" id="wp_st_savebutton" value="SAVE" name="submit_button" value="' . __('Update ShareThis Options', 'sharethis') . '" style="display:none;"/> </div> <script src="' . $plugin_location . 'js/sharethis.js" type="text/javascript"></script> </fieldset> <input type="hidden" id="is_hoverbar_selected" value=""/> <input type="hidden" id="is_sharenow_selected" value=""/> <input type="hidden" id="is_copynshre_selected" value=""/> <input type="hidden" name="st_action" value="st_update_settings" /> <input type="hidden" name="st_nonce" value="' . wp_create_nonce("wp-sharethis") . '" /> <input type="hidden" name="st_version" id="st_version" value="' . $st_widget_version . '"/> <input type="hidden" name="st_services" id="st_services" value="' . $services . '"/> <input type="hidden" name="st_current_type" id="st_current_type" value="' . $st_current_type . '"/> <input type="hidden" name="st_widget" id="st_widget" value="' . htmlspecialchars($toShow) . '"/> <input type="hidden" name="st_tags" id="st_tags" value="' . htmlspecialchars($tags) . '"/> <input type="hidden" name="st_pkey" id="st_pkey" value="' . htmlspecialchars($publisher_id) . '"/> <input type="hidden" name="st_user_name" id="st_user_name" value="' . $st_username . '"/> <input type="hidden" name="selectedBar" id="st_selected_bar" value=""/> <input type="hidden" name="hoverbar[position]" id="st_hoverbar_position" value=""/> <input type="hidden" name="hoverbar[services]" id="st_hoverbar_services" value=""/> <input type="hidden" name="pulldownbar[scrollpx]" id="st_pulldownbar_scrollpx" value="' . $pulldown_scrollpx . '"/> <input type="hidden" name="pulldownbar[logo]" id="st_pulldownbar_logo" value="' . $st_pulldownlogo . '"/> <input type="hidden" name="pulldownbar[services]" id="st_pulldownbar_services" value=""/> <input type="hidden" name="sharenowSelected" id="st_sharenow_selected" value="false"/> <input type="hidden" name="sharenow[theme]" id="st_sharenow_theme" value="' . $sharenow_style . '"/> <input type="hidden" name="copynshareSettings" id="copynshareSettings" value=""/> <input type="hidden" name="st_callesi" id="st_callesi" value="' . $sharethis_callesi . '" /> <input type="hidden" id="freshInstalation" value="' . $freshInstalation . '"/> </form> </div> </div> '; }