Changeset 2783238
- Timestamp:
- 09/12/2022 09:04:57 AM (4 years ago)
- Location:
- content-bot/trunk
- Files:
-
- 4 added
- 6 edited
-
content-bot.php (modified) (8 diffs)
-
css/style.css (modified) (1 diff)
-
js (added)
-
js/frame-builders.js (added)
-
js/functions.js (added)
-
js/script.js (added)
-
readme.txt (modified) (1 diff)
-
script.js (modified) (3 diffs)
-
templates/settings.html.php (modified) (2 diffs)
-
templates/welcome.html.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
content-bot/trunk/content-bot.php
r2558520 r2783238 4 4 Plugin URI: https://contentbot.ai 5 5 Description: Create amazing AI content snippets with OpenAI's GPT3 autoregressive language model that uses deep learning to produce human-like text. 6 Version: 1. 1.007 Author: NickDuncan6 Version: 1.2.00 7 Author: ContentBot 8 8 Author URI: https://codecabin.io 9 9 Text Domain: wp-content-bot … … 13 13 14 14 /** 15 * v1.2.0 - 2022-09-09 16 * Added all the latest short form tools 17 * - blog conclusions 18 * - paragraph 19 * - engaging questions 20 * - explain it to a child 21 * - explain it like a professor 22 * - brand story 23 * - photo captions 24 * Added ability to login with API key in Gutenberg block area 25 * Updated media 15 26 * 16 27 * v1.1.0 - 2021-07-05 … … 69 80 global $cbaiVersion; 70 81 wp_enqueue_script( 71 'content-bot- gutenberg',72 plugin_dir_url(__FILE__) . ' script.js',82 'content-bot-functions', 83 plugin_dir_url(__FILE__) . 'js/functions.js', 73 84 array('wp-blocks','wp-editor'), 74 85 $cbaiVersion 75 86 ); 87 88 wp_enqueue_script( 89 'content-bot-gutenberg', 90 plugin_dir_url(__FILE__) . 'js/script.js', 91 array('wp-blocks','wp-editor'), 92 $cbaiVersion 93 ); 94 95 wp_enqueue_script( 96 'content-bot-frame-builders', 97 plugin_dir_url(__FILE__) . 'js/frame-builders.js', 98 array('wp-blocks','wp-editor'), 99 $cbaiVersion 100 ); 101 102 76 103 77 104 $current_user = wp_get_current_user(); … … 106 133 'gravs'=> $gravs_array 107 134 ); 135 136 wp_localize_script( 'content-bot-functions', 'cbai_data', $translation_array ); 108 137 wp_localize_script( 'content-bot-gutenberg', 'cbai_data', $translation_array ); 109 138 wp_localize_script( 'content-bot-frame-builders', 'cbai_data', $translation_array ); 110 139 111 140 wp_enqueue_style( 'content-bot', plugin_dir_url(__FILE__) . 'css/style.css' ); … … 135 164 update_option( 'cbai_hash', sanitize_text_field( $_POST['cbai_apikey'] ) ); 136 165 } 137 138 166 } 139 167 … … 167 195 function cbai_render_callback( $attributes, $content ){ 168 196 return html_entity_decode( $content ); 169 170 197 } 171 198 … … 183 210 update_option( 'cbai_hash', sanitize_text_field( $_POST['apikey'] ) ); 184 211 die('1'); 185 186 212 } 187 213 … … 194 220 update_option( 'cbai_otl', sanitize_text_field( $_POST['otl'] ) ); 195 221 die('1'); 196 197 } 198 199 222 } 223 224 -
content-bot/trunk/css/style.css
r2469258 r2783238 42 42 color: red; 43 43 background-color: #fbe7e7; 44 border: 1px solid #red;44 border: 1px solid red; 45 45 padding: 5px; 46 46 border-radius: 5px; 47 47 } 48 49 .content-bot-end-buttons-container{ 50 display: flex; 51 justify-content: space-between; 52 } -
content-bot/trunk/readme.txt
r2781920 r2783238 89 89 == Changelog == 90 90 91 = v1.2.00 - 2022-09-09 = 92 * Added all the latest short form tools 93 * - blog conclusions 94 * - paragraph 95 * - engaging questions 96 * - explain it to a child 97 * - explain it like a professor 98 * - brand story 99 * - photo captions 100 * Added ability to login with API key in Gutenberg block area 101 * Updated media 102 91 103 = v1.1.00 - 2021-07-05 = 92 104 * Added all the latest short form tools -
content-bot/trunk/script.js
r2558520 r2783238 204 204 type: "GET", 205 205 dataType: "json", 206 url: cb_REST+" action=register&u="+cbai_data.uemail,206 url: cb_REST+"v2=true&action=register&u="+cbai_data.uemail, 207 207 success: function(msg){ 208 208 if (typeof msg.apikey !== 'undefined') { … … 214 214 jQuery("#content-bot-message").removeClass('hidden'); 215 215 jQuery("#content-bot-message").addClass('content-bot-message-green'); 216 jQuery("#content-bot-message").html(' You\'re account has been created. You will receive an email (to '+cbai_data.uemail+') with log in details for future reference.');216 jQuery("#content-bot-message").html('<p>You\'re account has been created. <strong>You will receive an email</strong> (to '+cbai_data.uemail+') with <strong>log in details</strong> for future reference.</p><p>Your account currently has <strong>'+msg.credits+'</strong> Pay As You Go credits.</p>'); 217 217 setTimeout(function() { 218 218 jQuery("#content-bot-message").fadeOut('slow'); … … 398 398 var url = "https://contentbot.ai/app/api/"; 399 399 400 var query = " ?action=" + action + "&apikey=" + cbai_data.hash + "&rel=" + rel;400 var query = "action=" + action + "&apikey=" + cbai_data.hash + "&rel=" + rel; 401 401 402 402 jQuery.get(url + query).always(function( data ) { -
content-bot/trunk/templates/settings.html.php
r2475458 r2783238 6 6 ?> 7 7 <div class="wrap"> 8 <h1><?php _e("Content Bot Settings", "wp-content-bot"); ?></h1>8 <h1><?php _e("ContentBot Settings", "wp-content-bot"); ?></h1> 9 9 10 10 <form method="post" action="" novalidate="novalidate"> … … 31 31 <input name="cbai_apikey" type="text" id="cbai_apikey" value="<?php echo get_option('cbai_hash'); ?>" class="regular-text"> 32 32 <p class="description" id="apikey-description"> 33 <?php _e("An API key will be generated for you as soon as you start using the ContentBot <strong>block</strong> in your posts/pages", "wp-content-bot"); ?>33 <?php _e("An API key will be generated for you as soon as you start using ContentBot <strong>block</strong> in your posts/pages", "wp-content-bot"); ?> 34 34 </p> 35 35 </td> -
content-bot/trunk/templates/welcome.html.php
r2478787 r2783238 50 50 <div id="content-bot-welcome-page" class="wrap about-wrap"> 51 51 <p> </p> 52 <img style="width: 212px;" src="<?php echo CBAI_PLUGIN_DIR_URL.'img/squarel.png'; ?>" alt="Content Bot"/>52 <img style="width: 212px;" src="<?php echo CBAI_PLUGIN_DIR_URL.'img/squarel.png'; ?>" alt="ContentBot"/> 53 53 <h1><?php _e("Welcome to ContentBot","wp-content-bot"); ?></h1> 54 54 … … 66 66 <div class="cbai-card"> 67 67 <h3><?php _e("Step 1","wp-content-bot"); ?></h3> 68 <p><?php _e("Add the Content Bot block to your page/post","wp-content-bot"); ?></p>68 <p><?php _e("Add the ContentBot block to your page/post","wp-content-bot"); ?></p> 69 69 <img src='<?php echo CBAI_PLUGIN_DIR_URL.'img/step1.gif'; ?>' style="border:1px solid #ccc;" /> 70 70 </div>
Note: See TracChangeset
for help on using the changeset viewer.