Changeset 2179244
- Timestamp:
- 10/24/2019 11:31:03 AM (5 years ago)
- Location:
- tidio-live-chat/trunk
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
tidio-live-chat/trunk/media/css/options.css
r2178184 r2179244 57 57 } 58 58 59 .tidio-box- advert{59 .tidio-box-george { 60 60 text-align: center; 61 61 position: relative; … … 75 75 } 76 76 77 .tidio-box- adverth2, .tidio-box-actions h1 {77 .tidio-box-george h2, .tidio-box-actions h1 { 78 78 font-size: 24px; 79 79 line-height: 34px; … … 97 97 } 98 98 99 .tidio-box- advert-image {99 .tidio-box-george-image { 100 100 position: absolute; 101 101 left: 0; … … 210 210 } 211 211 212 .tidio-box- adverth2 {212 .tidio-box-george h2 { 213 213 margin-top: 24px; 214 214 } … … 229 229 } 230 230 231 .tidio-box- adverth2 {231 .tidio-box-george h2 { 232 232 margin-top: 32px; 233 233 } … … 237 237 } 238 238 239 .tidio-box- advert{239 .tidio-box-george { 240 240 flex-basis: 680px; 241 241 } -
tidio-live-chat/trunk/media/js/options.js
r2178254 r2179244 75 75 return false; 76 76 } 77 if (passwordField. is(':invalid')) {78 this.showError('Password must be at least 6 characters long!');77 if (passwordField.val() === '') { 78 this.showError('Password can’t be empty!'); 79 79 return false; 80 80 } … … 131 131 select_project.children().remove(); 132 132 select_project.append(defaultOption); 133 var selected = false; 134 if (data.value.length === 1) { 135 selected = true; 136 } 133 137 for (var i in data.value) { 134 138 var project = data.value[i]; … … 140 144 141 145 var option = $( 142 '<option value="' + project.id + '" >' + project.name +146 '<option value="' + project.id + '" ' + (selected ? 'selected="selected"' : '') + '>' + project.name + 143 147 '</option>'); 144 148 option.data('value', value); … … 152 156 api_token: token, 153 157 }, (function (response) { 154 this.form.hide(); 155 this.form = $('#tidio-project'); 156 this.form.show(); 157 this.renderProjects(response); 158 this.form.off().submit(this.onProjectSubmit.bind(this)); 159 var startOver = $('#start-over'); 160 startOver.click(this.startOver.bind(this)); 158 if (response.value.length === 1) { 159 this.renderProjects(response); 160 this.onProjectSubmit(); 161 } else { 162 this.form.hide(); 163 this.form = $('#tidio-project'); 164 this.form.show(); 165 this.renderProjects(response); 166 this.form.off().submit(this.onProjectSubmit.bind(this)); 167 var startOver = $('#start-over'); 168 startOver.click(this.startOver.bind(this)); 169 } 161 170 }).bind(this), 'json'); 162 171 }, … … 164 173 var details = $('#select-tidio-project option:selected'). 165 174 data('value'); 166 $.extend(details, { 'action': ' get_project_keys'});175 $.extend(details, { 'action': 'set_project_keys', 'api_token': TidioChatWP.token }); 167 176 $.post(ajaxurl, details, (function (response) { 168 177 window.open(response, '_blank'); -
tidio-live-chat/trunk/options.php
r2178184 r2179244 25 25 <label> 26 26 Password 27 <input type="password" id="password" minlength="6" required placeholder="Type your password…"/>27 <input type="password" id="password" placeholder="Type your password…" required/> 28 28 </label> 29 29 … … 53 53 </form> 54 54 </div> 55 <div class="tidio-box tidio-box- advert">55 <div class="tidio-box tidio-box-george"> 56 56 <h2>Join 300 000+ websites using Tidio - Live Chat boosted with Bots</h2> 57 57 <p>Increase sales by skyrocketing communication with customers.</p> 58 <div class="tidio-box- advert-image"></div>58 <div class="tidio-box-george-image"></div> 59 59 </div> 60 60 </div> -
tidio-live-chat/trunk/readme.txt
r2178254 r2179244 4 4 Requires at least: 3.0 5 5 Tested up to: 5.2 6 Stable tag: trunk6 Stable tag: 4.1.0 7 7 License: GPLv2 8 8 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 122 122 == Changelog == 123 123 124 = 4.1.0 = 125 * Simplify login flow for users with only one project 126 * Set widget as installed immediately after user connected project 127 124 128 = 4.0.1 = 125 129 * Fix saving project data after creating new project -
tidio-live-chat/trunk/tidio-elements.php
r2178254 r2179244 5 5 * Plugin URI: http://www.tidiochat.com 6 6 * Description: Tidio Live Chat - Live chat for your website. No logging in, no signing up - integrates with your website in less than 20 seconds. 7 * Version: 4. 0.17 * Version: 4.1.0 8 8 * Author: Tidio Ltd. 9 9 * Author URI: http://www.tidiochat.com 10 10 * License: GPL2 11 11 */ 12 define('TIDIOCHAT_VERSION', '4. 0.1');12 define('TIDIOCHAT_VERSION', '4.1.0'); 13 13 define('AFFILIATE_CONFIG_FILE_PATH', get_template_directory().'/tidio_affiliate_ref_id.txt'); 14 14 … … 53 53 54 54 add_action('wp_ajax_tidio_chat_save_keys', array($this, 'ajaxTidioChatSaveKeys')); 55 add_action('wp_ajax_ get_project_keys', array($this, 'ajaxGetProjectKeys'));55 add_action('wp_ajax_set_project_keys', array($this, 'ajaxSetProjectKeys')); 56 56 add_action('wp_ajax_get_private_key', array($this, 'ajaxGetPrivateKey')); 57 57 … … 217 217 } 218 218 219 public function ajax GetProjectKeys()219 public function ajaxSetProjectKeys() 220 220 { 221 221 update_option(TidioLiveChat::PUBLIC_KEY_OPTION, $_POST['public_key']); 222 222 update_option(TidioLiveChat::PRIVATE_KEY_OPTION, $_POST['private_key']); 223 224 $query = http_build_query(array( 225 'api_token' => $_POST['api_token'], 226 'project_public_key' => $_POST['public_key'] 227 )); 228 229 $options = array('http' => array('method' => 'POST')); 230 231 $context = stream_context_create($options); 232 @file_get_contents(TidioLiveChat::API_URL . '/access/connectWordpress?' . $query, false, $context); 233 223 234 echo TidioLiveChat::getRedirectUrl($_POST['private_key']); 224 235 exit();
Note: See TracChangeset
for help on using the changeset viewer.