Changeset 2683660
- Timestamp:
- 02/23/2022 11:06:12 AM (4 years ago)
- Location:
- kafkai/trunk
- Files:
-
- 2 added
- 2 deleted
- 15 edited
-
i18n/kafkai.pot (modified) (3 diffs)
-
inc/Admin.php (modified) (2 diffs)
-
inc/Admin/API.php (added)
-
inc/Admin/Api.php (deleted)
-
inc/Admin/Articles.php (modified) (3 diffs)
-
inc/Admin/Helper.php (modified) (3 diffs)
-
inc/Admin/Niches.php (added)
-
inc/Admin/Updater.php (deleted)
-
inc/Admin/views/generate.php (modified) (5 diffs)
-
inc/Admin/views/import.php (modified) (14 diffs)
-
inc/Admin/views/settings.php (modified) (5 diffs)
-
inc/Config.php (modified) (1 diff)
-
kafkai.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
vendor/autoload.php (modified) (1 diff)
-
vendor/composer/autoload_classmap.php (modified) (1 diff)
-
vendor/composer/autoload_real.php (modified) (5 diffs)
-
vendor/composer/autoload_static.php (modified) (3 diffs)
-
vendor/composer/installed.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
kafkai/trunk/i18n/kafkai.pot
r2682292 r2683660 3 3 msgid "" 4 4 msgstr "" 5 "Project-Id-Version: Kafkai - AI Writer Plugin 1.5. 4\n"5 "Project-Id-Version: Kafkai - AI Writer Plugin 1.5.5\n" 6 6 "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/kafkai\n" 7 7 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" … … 91 91 msgstr "" 92 92 93 #: inc/Admin/A pi.php:17393 #: inc/Admin/API.php:173 94 94 msgid "Authorization token is not available. Please go to %1$splugin settings%2$s and provide credentials or re-generate token." 95 95 msgstr "" … … 154 154 msgstr "" 155 155 156 #: inc/Admin/ Updater.php:169156 #: inc/Admin/Niches.php:169 157 157 msgid "New niches are available for the plugin. Please go to %1$sSettings page%2$s to update." 158 158 msgstr "" 159 159 160 #: inc/Admin/ Updater.php:179160 #: inc/Admin/Niches.php:179 161 161 msgid "New languages are available for the plugin. Please go to %1$sSettings page%2$s to update." 162 162 msgstr "" 163 163 164 #: inc/Admin/ Updater.php:205164 #: inc/Admin/Niches.php:205 165 165 msgid "Update Niches & Languages" 166 166 msgstr "" -
kafkai/trunk/inc/Admin.php
r2525142 r2683660 7 7 8 8 use Niteo\Kafkai\Plugin\Admin\Articles; 9 use Niteo\Kafkai\Plugin\Admin\ Updater;9 use Niteo\Kafkai\Plugin\Admin\Niches; 10 10 11 11 /** … … 27 27 */ 28 28 public function __construct() { 29 new Updater();29 new Niches(); 30 30 31 31 add_action( 'admin_menu', array( $this, 'add_menu' ), PHP_INT_MAX ); -
kafkai/trunk/inc/Admin/Articles.php
r2525142 r2683660 94 94 95 95 // Make connection to API 96 $api = new A pi();96 $api = new API(); 97 97 $response = $api->call( 98 98 sprintf( … … 295 295 296 296 // Make connection to API 297 $api = new A pi();297 $api = new API(); 298 298 $response = $api->call( 299 299 '/articles/generate', … … 577 577 try { 578 578 // Make connection to API 579 $api = new A pi();579 $api = new API(); 580 580 $call = $api->call( 581 581 '/articles/' . $article_id, -
kafkai/trunk/inc/Admin/Helper.php
r2525142 r2683660 8 8 use Niteo\Kafkai\Plugin\Config; 9 9 use Niteo\Kafkai\Plugin\Helper as MainHelper; 10 use Niteo\Kafkai\Plugin\Admin\A pi;10 use Niteo\Kafkai\Plugin\Admin\API; 11 11 12 12 trait Helper { … … 91 91 92 92 // API call for authentication 93 $api = new A pi();93 $api = new API(); 94 94 $response = $api->authenticate(); 95 95 … … 290 290 */ 291 291 public function add_notice( $code, $response ) : void { 292 echo '<div class="notice notice-' . $code . ' is-dismissible"><p>' . $response . '</p></div>';292 echo esc_html('<div class="notice notice-' . $code . ' is-dismissible"><p>' . $response . '</p></div>'); 293 293 } 294 294 -
kafkai/trunk/inc/Admin/views/generate.php
r2525142 r2683660 25 25 26 26 <form method="post"> 27 <input type="hidden" name="_<?php echo Config::PLUGIN_PREFIX; ?>nonce" id="_<?php echo Config::PLUGIN_PREFIX; ?>nonce" value="<?php echo esc_attr( wp_create_nonce( Config::PLUGIN_SLUG . '-nonce' ) ); ?>">27 <input type="hidden" name="_<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>nonce" id="_<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>nonce" value="<?php echo esc_attr( wp_create_nonce( Config::PLUGIN_SLUG . '-nonce' ) ); ?>"> 28 28 29 29 <table class="form-table"> … … 31 31 <tr> 32 32 <th scope="row"> 33 <label for="<?php echo Config::PLUGIN_PREFIX; ?>niche">33 <label for="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>niche"> 34 34 <?php esc_html_e( 'Niche', 'kafkai' ); ?> 35 35 </label> 36 36 </th> 37 37 <td> 38 <select name="<?php echo Config::PLUGIN_PREFIX; ?>niche" id="<?php echo Config::PLUGIN_PREFIX; ?>niche" class="regular-text">38 <select name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>niche" id="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>niche" class="regular-text"> 39 39 <?php 40 40 … … 50 50 <tr> 51 51 <th scope="row"> 52 <label for="<?php echo Config::PLUGIN_PREFIX; ?>language">52 <label for="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>language"> 53 53 <?php esc_html_e( 'Language', 'kafkai' ); ?> 54 54 </label> 55 55 </th> 56 56 <td> 57 <select name="<?php echo Config::PLUGIN_PREFIX; ?>language" id="<?php echo Config::PLUGIN_PREFIX; ?>language" class="regular-text">57 <select name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>language" id="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>language" class="regular-text"> 58 58 <?php 59 59 … … 84 84 <tr> 85 85 <td class="no-margin-left"> 86 <textarea name="<?php echo Config::PLUGIN_PREFIX; ?>seed" id="<?php echo Config::PLUGIN_PREFIX; ?>seed" class="large-text" rows="4" placeholder="<?php esc_attr_e( 'Optional', 'kafkai' ); ?>"></textarea>86 <textarea name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>seed" id="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>seed" class="large-text" rows="4" placeholder="<?php esc_attr_e( 'Optional', 'kafkai' ); ?>"></textarea> 87 87 <p class="help-text"><?php esc_html_e( 'Please note that advanced articles take longer to finish.', 'kafkai' ); ?></p> 88 88 </td> … … 92 92 93 93 <p class="submit"> 94 <input type="submit" name="<?php echo Config::PLUGIN_PREFIX; ?>generate" value="<?php esc_attr_e( 'Generate Article', 'kafkai' ); ?>" class="button button-primary">94 <input type="submit" name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>generate" value="<?php esc_attr_e( 'Generate Article', 'kafkai' ); ?>" class="button button-primary"> 95 95 </p> 96 96 </form> -
kafkai/trunk/inc/Admin/views/import.php
r2516263 r2683660 13 13 </h1> 14 14 15 <a href="<?php echo add_query_arg( array( 'action' => 'refresh_list') ); ?>" class="page-title-action">15 <a href="<?php echo esc_attr( add_query_arg( array( 'action' => 'refresh_list' ) ) ); ?>" class="page-title-action"> 16 16 <?php esc_html_e( 'Refresh List', 'kafkai' ); ?> 17 17 </a> … … 49 49 <?php if ( (int) $this->articles->response['pageCount'] > 1 && (int) $this->articles->response['pageNum'] !== 1 ) : ?> 50 50 <?php if ( (int) $this->articles->response['pageNum'] > 2 ) : ?> 51 <a class="prev-page button" href="<?php echo add_query_arg( 'paged', 1); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">«</span></a>51 <a class="prev-page button" href="<?php echo esc_attr( add_query_arg( 'paged', 1 ) ); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">«</span></a> 52 52 <?php endif; ?> 53 <a class="prev-page button" href="<?php echo add_query_arg( 'paged', $this->articles->response['pageNum'] - 1); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">‹</span></a> 53 <a class="prev-page button" href="<?php echo esc_attr( add_query_arg( 'paged', $this->articles->response['pageNum'] - 1 ) ); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">‹</span></a> 54 54 <?php endif; ?> 55 55 56 <span class="displaying-num">Page <?php echo $this->articles->response['pageNum']; ?> of <?php echo $this->articles->response['pageCount']; ?></span>56 <span class="displaying-num">Page <?php echo esc_html($this->articles->response['pageNum']); ?> of <?php echo esc_html($this->articles->response['pageCount']); ?></span> 57 57 58 58 <?php if ( (int) $this->articles->response['pageCount'] > $this->articles->response['pageNum'] ) : ?> 59 <a class="next-page button" href="<?php echo add_query_arg( 'paged', $this->articles->response['pageNum'] + 1); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">›</span></a> 59 <a class="next-page button" href="<?php echo esc_attr( add_query_arg( 'paged', $this->articles->response['pageNum'] + 1 ) ); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">›</span></a> 60 60 <?php if ( (int) $this->articles->response['pageCount'] > 2 && ( $this->articles->response['pageCount'] - $this->articles->response['pageNum'] ) > 1 ) : ?> 61 <a class="next-page button" href="<?php echo add_query_arg( 'paged', $this->articles->response['pageCount']); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">»</span></a>61 <a class="next-page button" href="<?php echo esc_attr( add_query_arg( 'paged', $this->articles->response['pageCount'] ) ); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">»</span></a> 62 62 <?php endif; ?> 63 63 <?php endif; ?> … … 101 101 foreach ( $this->articles->response['articles'] as $key => $data ) : 102 102 $key = esc_attr( $key ); 103 $ title = trim( esc_html( $data['title'] ) );103 $article_title = trim( esc_html( $data['title'] ) ); 104 104 $niche = esc_html( $data['niche'] ); 105 105 $state = esc_attr( $data['state'] ); 106 $ status = esc_attr__( 'raw', 'kafkai' );106 $article_status = esc_attr__( 'raw', 'kafkai' ); 107 107 $niche_image = strtolower( str_replace( ' ', '_', $this->articles->niche_name( $niche ) ) ); 108 108 … … 113 113 // Check for import status 114 114 if ( in_array( $key, $this->articles->imported_article_ids ) ) { 115 $ status = esc_attr__( 'imported', 'kafkai' );115 $article_status = esc_attr__( 'imported', 'kafkai' ); 116 116 } 117 117 118 118 ?> 119 <tr id="article-<?php echo $key; ?>" class="niche-<?php echo $niche; ?> state-<?php echo $state; ?> status-<?php echo $status; ?>">119 <tr id="article-<?php echo esc_attr($key); ?>" class="niche-<?php echo esc_attr($niche); ?> state-<?php echo esc_attr($state); ?> status-<?php echo esc_attr($article_status); ?>"> 120 120 <td class="image column-image"> 121 <img src="<?php echo Config::$plugin_url . 'assets/admin/images/' . $niche_image . '.svg'; ?>" alt="<?php echo $niche; ?>" onerror="javascript:this.style.display='none'">121 <img src="<?php echo esc_attr(Config::$plugin_url . 'assets/admin/images/' . $niche_image . '.svg'); ?>" alt="<?php echo esc_attr($niche); ?>" onerror="javascript:this.style.display='none'"> 122 122 </td> 123 123 … … 125 125 <?php 126 126 127 if ( strlen( $ title ) > 120 ) {128 echo '<a href="javascript:;" class="fetch-article" data-id="' . $key . '">' . substr( $title, 0, 120 ) . '</a>...';127 if ( strlen( $article_title ) > 120 ) { 128 echo esc_html( '<a href="javascript:;" class="fetch-article" data-id="' . $key . '">' . substr( $title, 0, 120 ) . '</a>...' ); 129 129 } else { 130 echo '<a href="javascript:;" class="fetch-article" data-id="' . $key . '">' . $title . '</a>';130 echo esc_html( '<a href="javascript:;" class="fetch-article" data-id="' . $key . '">' . $article_title . '</a>' ); 131 131 } 132 132 … … 135 135 136 136 <td class="niche column-niche" data-colname="<?php esc_html_e( 'Niche', 'kafkai' ); ?>"> 137 <?php echo $this->articles->niche_name( $niche); ?>137 <?php echo esc_html( $this->articles->niche_name( $niche ) ); ?> 138 138 </td> 139 139 140 140 <td class="date column-date" data-colname="<?php esc_html_e( 'Date', 'kafkai' ); ?>"> 141 <?php echo $formatted_date; ?>141 <?php echo esc_html( $formatted_date ); ?> 142 142 </td> 143 143 </tr> … … 151 151 <?php 152 152 153 echo sprintf( 154 esc_html__( 'There are no articles under your account. You can %1$sclick here%2$s to generate one.', 'kafkai' ), 155 '<a href="' . self_admin_url( 'admin.php?page=' . Config::PLUGIN_PREFIX . 'generate' ) . '">', 156 '</a>' 157 ); 153 echo esc_html( 154 sprintf( 155 esc_html__( 'There are no articles under your account. You can %1$sclick here%2$s to generate one.', 'kafkai' ), 156 '<a href="' . self_admin_url( 'admin.php?page=' . esc_attr(Config::PLUGIN_PREFIX) . 'generate' ) . '">', 157 '</a>' 158 ) 159 ); 158 160 159 161 ?> … … 212 214 <?php if ( (int) $this->articles->response['pageCount'] > 1 && (int) $this->articles->response['pageNum'] !== 1 ) : ?> 213 215 <?php if ( (int) $this->articles->response['pageNum'] > 2 ) : ?> 214 <a class="prev-page button" href="<?php echo add_query_arg( 'paged', 1); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">«</span></a>216 <a class="prev-page button" href="<?php echo esc_attr( add_query_arg( 'paged', 1 ) ); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">«</span></a> 215 217 <?php endif; ?> 216 <a class="prev-page button" href="<?php echo add_query_arg( 'paged', $this->articles->response['pageNum'] - 1); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">‹</span></a> 218 <a class="prev-page button" href="<?php echo esc_attr( add_query_arg( 'paged', $this->articles->response['pageNum'] - 1 ) ); ?>"><span class="screen-reader-text">Previous page</span><span aria-hidden="true">‹</span></a> 217 219 <?php endif; ?> 218 220 219 <span class="displaying-num">Page <?php echo $this->articles->response['pageNum']; ?> of <?php echo $this->articles->response['pageCount']; ?></span>221 <span class="displaying-num">Page <?php echo esc_html($this->articles->response['pageNum']); ?> of <?php echo esc_html($this->articles->response['pageCount']); ?></span> 220 222 221 223 <?php if ( (int) $this->articles->response['pageCount'] > $this->articles->response['pageNum'] ) : ?> 222 <a class="next-page button" href="<?php echo add_query_arg( 'paged', $this->articles->response['pageNum'] + 1); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">›</span></a> 224 <a class="next-page button" href="<?php echo esc_attr( add_query_arg( 'paged', $this->articles->response['pageNum'] + 1 ) ); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">›</span></a> 223 225 <?php if ( (int) $this->articles->response['pageCount'] > 2 && ( $this->articles->response['pageCount'] - $this->articles->response['pageNum'] ) > 1 ) : ?> 224 <a class="next-page button" href="<?php echo add_query_arg( 'paged', $this->articles->response['pageCount']); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">»</span></a>226 <a class="next-page button" href="<?php echo esc_attr( add_query_arg( 'paged', $this->articles->response['pageCount'] ) ); ?>"><span class="screen-reader-text">Next page</span><span aria-hidden="true">»</span></a> 225 227 <?php endif; ?> 226 228 <?php endif; ?> … … 235 237 </form> 236 238 237 <div id="<?php echo Config::PLUGIN_PREFIX; ?>inline-article-container" class="single-article-container">238 <form method="post" id="<?php echo Config::PLUGIN_PREFIX; ?>import_form">239 <div id="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>inline-article-container" class="single-article-container"> 240 <form method="post" id="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>import_form"> 239 241 <div class="single-article-scrollable"> 240 242 <div class="article-actions top"> … … 259 261 <div class="article-actions bottom"> 260 262 <p> 261 <label for="<?php echo Config::PLUGIN_PREFIX; ?>article-import-status">263 <label for="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>article-import-status"> 262 264 <strong><?php esc_html_e( 'Status', 'kafkai' ); ?></strong> 263 265 </label> … … 270 272 // Make sure the array is not empty 271 273 if ( ! empty( $statuses ) ) { 272 echo '<select name="' . Config::PLUGIN_PREFIX . 'article-import-status" id="' . Config::PLUGIN_PREFIX. 'article-import-status">';274 echo '<select name="' . esc_attr(Config::PLUGIN_PREFIX) . 'article-import-status" id="' . esc_attr(Config::PLUGIN_PREFIX) . 'article-import-status">'; 273 275 274 276 // Loop over array 275 277 foreach ( $statuses as $status_key => $status_name ) { 276 echo sprintf( 277 '<option value="%s">%s</option>', 278 $status_key, 279 $status_name 280 ); 278 echo esc_html( 279 sprintf( 280 '<option value="%s">%s</option>', 281 $status_key, 282 $status_name 283 ) 284 ); 281 285 } 282 286 … … 290 294 291 295 <p> 292 <label for="<?php echo Config::PLUGIN_PREFIX; ?>article-import-author">296 <label for="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>article-import-author"> 293 297 <strong><?php esc_html_e( 'Author', 'kafkai' ); ?></strong> 294 298 </label> … … 306 310 // Make sure the array is not empty 307 311 if ( ! empty( $users ) ) { 308 echo '<select name="' . Config::PLUGIN_PREFIX . 'article-import-author" id="' . Config::PLUGIN_PREFIX. 'article-import-author">';312 echo '<select name="' . esc_attr(Config::PLUGIN_PREFIX) . 'article-import-author" id="' . esc_attr(Config::PLUGIN_PREFIX) . 'article-import-author">'; 309 313 310 314 // Loop over array 311 315 foreach ( $users as $user ) { 312 echo sprintf( 313 '<option value="%s">%s</option>', 314 $user->data->ID, 315 $user->data->user_login 316 ); 316 echo esc_html( 317 sprintf( 318 '<option value="%s">%s</option>', 319 $user->data->ID, 320 $user->data->user_login 321 ) 322 ); 317 323 } 318 324 … … 326 332 327 333 <p class="align-right"> 328 <input type="hidden" name="<?php echo Config::PLUGIN_PREFIX; ?>article_id" id="<?php echo Config::PLUGIN_PREFIX; ?>article_id">329 <input type="submit" name="<?php echo Config::PLUGIN_PREFIX; ?>article_import" id="<?php echo Config::PLUGIN_PREFIX; ?>article_import" value="<?php esc_attr_e( 'Import Article', 'kafkai' ); ?>" class="button button-primary">334 <input type="hidden" name="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>article_id" id="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>article_id"> 335 <input type="submit" name="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>article_import" id="<?php echo esc_attr(Config::PLUGIN_PREFIX); ?>article_import" value="<?php esc_attr_e( 'Import Article', 'kafkai' ); ?>" class="button button-primary"> 330 336 </p> 331 337 </div> -
kafkai/trunk/inc/Admin/views/settings.php
r2525142 r2683660 25 25 26 26 <form method="post"> 27 <input type="hidden" name="_<?php echo Config::PLUGIN_PREFIX; ?>nonce" id="_<?php echo Config::PLUGIN_PREFIX; ?>nonce" value="<?php echo esc_attr( wp_create_nonce( Config::PLUGIN_SLUG . '-nonce' ) ); ?>">27 <input type="hidden" name="_<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>nonce" id="_<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>nonce" value="<?php echo esc_attr( wp_create_nonce( Config::PLUGIN_SLUG . '-nonce' ) ); ?>"> 28 28 29 29 <table class="form-table"> … … 31 31 <tr> 32 32 <th scope="row"> 33 <label for="<?php echo Config::PLUGIN_PREFIX; ?>email"><?php esc_html_e( 'Email', 'kafkai' ); ?></label>33 <label for="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>email"><?php esc_html_e( 'Email', 'kafkai' ); ?></label> 34 34 </th> 35 35 <td> 36 <input type="text" name="<?php echo Config::PLUGIN_PREFIX; ?>email" id="<?php echo Config::PLUGIN_PREFIX; ?>email" class="regular-text" value="<?php echo $settings['email']; ?>">36 <input type="text" name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>email" id="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>email" class="regular-text" value="<?php echo esc_attr($settings['email']); ?>"> 37 37 <p class="description"><?php esc_html_e( 'Email address you use for login on Kafkai.', 'kafkai' ); ?></p> 38 38 </td> … … 41 41 <tr> 42 42 <th scope="row"> 43 <label for="<?php echo Config::PLUGIN_PREFIX; ?>password"><?php esc_html_e( 'Password', 'kafkai' ); ?></label>43 <label for="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>password"><?php esc_html_e( 'Password', 'kafkai' ); ?></label> 44 44 </th> 45 45 <td> 46 <input type="password" name="<?php echo Config::PLUGIN_PREFIX; ?>password" id="<?php echo Config::PLUGIN_PREFIX; ?>password" class="regular-text" value="<?php echo $settings['password']; ?>">46 <input type="password" name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>password" id="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>password" class="regular-text" value="<?php echo esc_attr($settings['password']); ?>"> 47 47 <p class="description"><?php esc_html_e( 'Account password for authentication.', 'kafkai' ); ?></p> 48 48 </td> … … 51 51 <tr> 52 52 <th scope="row"> 53 <label for="<?php echo Config::PLUGIN_PREFIX; ?>token"><?php esc_html_e( 'Token', 'kafkai' ); ?></label>53 <label for="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>token"><?php esc_html_e( 'Token', 'kafkai' ); ?></label> 54 54 </th> 55 55 <td> 56 <input type="text" name="<?php echo Config::PLUGIN_PREFIX; ?>token" id="<?php echo Config::PLUGIN_PREFIX; ?>token" class="regular-text code" value="<?php echo $token; ?>" disabled>56 <input type="text" name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>token" id="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>token" class="regular-text code" value="<?php echo esc_attr( $token ); ?>" disabled> 57 57 <p class="description"><?php esc_html_e( 'Bearer token for authenticating Kafkai API calls.', 'kafkai' ); ?></p> 58 58 <p class="description"><?php esc_html_e( 'This is generated once valid credentials are processed.', 'kafkai' ); ?></p> … … 63 63 64 64 <p class="submit"> 65 <input type="submit" name="<?php echo Config::PLUGIN_PREFIX; ?>settings" value="<?php esc_attr_e( 'Save Settings', 'kafkai' ); ?>" class="button button-primary">65 <input type="submit" name="<?php echo esc_attr( Config::PLUGIN_PREFIX ); ?>settings" value="<?php esc_attr_e( 'Save Settings', 'kafkai' ); ?>" class="button button-primary"> 66 66 <?php 67 67 -
kafkai/trunk/inc/Config.php
r2682292 r2683660 56 56 * @var string 57 57 */ 58 const PLUGIN_VERSION = '1.5. 4';58 const PLUGIN_VERSION = '1.5.5'; 59 59 60 60 /** -
kafkai/trunk/kafkai.php
r2682292 r2683660 3 3 * Plugin Name: Kafkai - AI Writer Plugin 4 4 * Description: Kafkai is a machine-learning algorithm that can write articles from scratch. Cutting-edge technology for marketers and SEOs. 5 * Version: 1.5. 45 * Version: 1.5.5 6 6 * Requires at least: 4.2 7 7 * Requires PHP: 7.3 … … 92 92 93 93 // Initialize plugin 94 $ plugin = new KafKai();94 $KafKaiPlugin = new KafKai(); 95 95 96 96 // Tasks to be taken care of on activation 97 register_activation_hook( __FILE__, array( $ plugin, 'activate' ) );97 register_activation_hook( __FILE__, array( $KafKaiPlugin, 'activate' ) ); -
kafkai/trunk/readme.txt
r2682292 r2683660 4 4 Requires at least: 4.2 5 5 Tested up to: 5.9 6 Stable tag: 1.5. 46 Stable tag: 1.5.5 7 7 Requires PHP: 7.3 8 8 License: GPLv3 or later … … 32 32 == Changelog == 33 33 34 = 1.5. 4=34 = 1.5.5 = 35 35 * Update compatibility 36 36 -
kafkai/trunk/vendor/autoload.php
r2682292 r2683660 5 5 require_once __DIR__ . '/composer/autoload_real.php'; 6 6 7 return ComposerAutoloaderInit e1e4a5a0992e571802f91089fad4dbfc::getLoader();7 return ComposerAutoloaderInit9486b8a3b41cbd83b4329847196fceeb::getLoader(); -
kafkai/trunk/vendor/composer/autoload_classmap.php
r2516263 r2683660 9 9 'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php', 10 10 'Niteo\\Kafkai\\Plugin\\Admin' => $baseDir . '/inc/Admin.php', 11 'Niteo\\Kafkai\\Plugin\\Admin\\A pi' => $baseDir . '/inc/Admin/Api.php',11 'Niteo\\Kafkai\\Plugin\\Admin\\API' => $baseDir . '/inc/Admin/API.php', 12 12 'Niteo\\Kafkai\\Plugin\\Admin\\Articles' => $baseDir . '/inc/Admin/Articles.php', 13 13 'Niteo\\Kafkai\\Plugin\\Admin\\Helper' => $baseDir . '/inc/Admin/Helper.php', 14 'Niteo\\Kafkai\\Plugin\\Admin\\ Updater' => $baseDir . '/inc/Admin/Updater.php',14 'Niteo\\Kafkai\\Plugin\\Admin\\Niches' => $baseDir . '/inc/Admin/Niches.php', 15 15 'Niteo\\Kafkai\\Plugin\\Config' => $baseDir . '/inc/Config.php', 16 16 'Niteo\\Kafkai\\Plugin\\Helper' => $baseDir . '/inc/Helper.php', -
kafkai/trunk/vendor/composer/autoload_real.php
r2682292 r2683660 3 3 // autoload_real.php @generated by Composer 4 4 5 class ComposerAutoloaderInit e1e4a5a0992e571802f91089fad4dbfc5 class ComposerAutoloaderInit9486b8a3b41cbd83b4329847196fceeb 6 6 { 7 7 private static $loader; … … 25 25 require __DIR__ . '/platform_check.php'; 26 26 27 spl_autoload_register(array('ComposerAutoloaderInit e1e4a5a0992e571802f91089fad4dbfc', 'loadClassLoader'), true, true);27 spl_autoload_register(array('ComposerAutoloaderInit9486b8a3b41cbd83b4329847196fceeb', 'loadClassLoader'), true, true); 28 28 self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__))); 29 spl_autoload_unregister(array('ComposerAutoloaderInit e1e4a5a0992e571802f91089fad4dbfc', 'loadClassLoader'));29 spl_autoload_unregister(array('ComposerAutoloaderInit9486b8a3b41cbd83b4329847196fceeb', 'loadClassLoader')); 30 30 31 31 $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); … … 33 33 require __DIR__ . '/autoload_static.php'; 34 34 35 call_user_func(\Composer\Autoload\ComposerStaticInit e1e4a5a0992e571802f91089fad4dbfc::getInitializer($loader));35 call_user_func(\Composer\Autoload\ComposerStaticInit9486b8a3b41cbd83b4329847196fceeb::getInitializer($loader)); 36 36 } else { 37 37 $map = require __DIR__ . '/autoload_namespaces.php'; … … 54 54 55 55 if ($useStaticLoader) { 56 $includeFiles = Composer\Autoload\ComposerStaticInit e1e4a5a0992e571802f91089fad4dbfc::$files;56 $includeFiles = Composer\Autoload\ComposerStaticInit9486b8a3b41cbd83b4329847196fceeb::$files; 57 57 } else { 58 58 $includeFiles = require __DIR__ . '/autoload_files.php'; 59 59 } 60 60 foreach ($includeFiles as $fileIdentifier => $file) { 61 composerRequire e1e4a5a0992e571802f91089fad4dbfc($fileIdentifier, $file);61 composerRequire9486b8a3b41cbd83b4329847196fceeb($fileIdentifier, $file); 62 62 } 63 63 … … 71 71 * @return void 72 72 */ 73 function composerRequire e1e4a5a0992e571802f91089fad4dbfc($fileIdentifier, $file)73 function composerRequire9486b8a3b41cbd83b4329847196fceeb($fileIdentifier, $file) 74 74 { 75 75 if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { -
kafkai/trunk/vendor/composer/autoload_static.php
r2682292 r2683660 5 5 namespace Composer\Autoload; 6 6 7 class ComposerStaticInit e1e4a5a0992e571802f91089fad4dbfc7 class ComposerStaticInit9486b8a3b41cbd83b4329847196fceeb 8 8 { 9 9 public static $files = array ( … … 42 42 'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php', 43 43 'Niteo\\Kafkai\\Plugin\\Admin' => __DIR__ . '/../..' . '/inc/Admin.php', 44 'Niteo\\Kafkai\\Plugin\\Admin\\A pi' => __DIR__ . '/../..' . '/inc/Admin/Api.php',44 'Niteo\\Kafkai\\Plugin\\Admin\\API' => __DIR__ . '/../..' . '/inc/Admin/API.php', 45 45 'Niteo\\Kafkai\\Plugin\\Admin\\Articles' => __DIR__ . '/../..' . '/inc/Admin/Articles.php', 46 46 'Niteo\\Kafkai\\Plugin\\Admin\\Helper' => __DIR__ . '/../..' . '/inc/Admin/Helper.php', 47 'Niteo\\Kafkai\\Plugin\\Admin\\ Updater' => __DIR__ . '/../..' . '/inc/Admin/Updater.php',47 'Niteo\\Kafkai\\Plugin\\Admin\\Niches' => __DIR__ . '/../..' . '/inc/Admin/Niches.php', 48 48 'Niteo\\Kafkai\\Plugin\\Config' => __DIR__ . '/../..' . '/inc/Config.php', 49 49 'Niteo\\Kafkai\\Plugin\\Helper' => __DIR__ . '/../..' . '/inc/Helper.php', … … 66 66 { 67 67 return \Closure::bind(function () use ($loader) { 68 $loader->prefixLengthsPsr4 = ComposerStaticInit e1e4a5a0992e571802f91089fad4dbfc::$prefixLengthsPsr4;69 $loader->prefixDirsPsr4 = ComposerStaticInit e1e4a5a0992e571802f91089fad4dbfc::$prefixDirsPsr4;70 $loader->classMap = ComposerStaticInit e1e4a5a0992e571802f91089fad4dbfc::$classMap;68 $loader->prefixLengthsPsr4 = ComposerStaticInit9486b8a3b41cbd83b4329847196fceeb::$prefixLengthsPsr4; 69 $loader->prefixDirsPsr4 = ComposerStaticInit9486b8a3b41cbd83b4329847196fceeb::$prefixDirsPsr4; 70 $loader->classMap = ComposerStaticInit9486b8a3b41cbd83b4329847196fceeb::$classMap; 71 71 72 72 }, null, ClassLoader::class); -
kafkai/trunk/vendor/composer/installed.php
r2682292 r2683660 1 1 <?php return array( 2 2 'root' => array( 3 'pretty_version' => 'v1.5. 4',4 'version' => '1.5. 4.0',3 'pretty_version' => 'v1.5.5', 4 'version' => '1.5.5.0', 5 5 'type' => 'wordpress-plugin', 6 6 'install_path' => __DIR__ . '/../../', 7 7 'aliases' => array(), 8 'reference' => ' ad14035169d1741c44cf54fcd37619cfe342fea6',8 'reference' => '5de3c40ed2ebae242307fe6133b9a20e3f625994', 9 9 'name' => 'teamniteo/kafkai-plugin', 10 10 'dev' => false, … … 39 39 ), 40 40 'teamniteo/kafkai-plugin' => array( 41 'pretty_version' => 'v1.5. 4',42 'version' => '1.5. 4.0',41 'pretty_version' => 'v1.5.5', 42 'version' => '1.5.5.0', 43 43 'type' => 'wordpress-plugin', 44 44 'install_path' => __DIR__ . '/../../', 45 45 'aliases' => array(), 46 'reference' => ' ad14035169d1741c44cf54fcd37619cfe342fea6',46 'reference' => '5de3c40ed2ebae242307fe6133b9a20e3f625994', 47 47 'dev_requirement' => false, 48 48 ),
Note: See TracChangeset
for help on using the changeset viewer.