@@ -182,7 +182,7 @@ |
||
| 182 | 182 | * @param string|bool $value The term slug, or a comma separated list of slugs. Or false to remove all terms set for post. |
| 183 | 183 | * The first item is the name of taxonomy |
| 184 | 184 | * |
| 185 | - * @return bool True if update was successful, false if not. |
|
| 185 | + * @return boolean|null True if update was successful, false if not. |
|
| 186 | 186 | */ |
| 187 | 187 | public function set_custom_taxonomy( $postid, $value) { |
| 188 | 188 | |
@@ -134,7 +134,7 @@ discard block |
||
| 134 | 134 | * @since 0.9.3 |
| 135 | 135 | * |
| 136 | 136 | * @param int $postid The current postid |
| 137 | - * @param string|bool $value The term slug, or a comma separated list of slugs. Or false to remove all terms set for post. |
|
| 137 | + * @param string|bool $value The term slug, or a comma separated list of slugs. Or false to remove all terms set for post. |
|
| 138 | 138 | * @param string $taxonomy The name of the taxonomy to which the term belongs. |
| 139 | 139 | * |
| 140 | 140 | * @return bool True if update was successful, false if not. |
@@ -147,7 +147,7 @@ discard block |
||
| 147 | 147 | } |
| 148 | 148 | |
| 149 | 149 | if ($taxonomy =='category') { |
| 150 | - // convert from names to category ids |
|
| 150 | + // convert from names to category ids |
|
| 151 | 151 | $cats = array(); |
| 152 | 152 | if (is_array($value)) { |
| 153 | 153 | foreach ($value as $cat) { |
@@ -179,7 +179,7 @@ discard block |
||
| 179 | 179 | * |
| 180 | 180 | * |
| 181 | 181 | * @param int $postid The current postid |
| 182 | - * @param string|bool $value The term slug, or a comma separated list of slugs. Or false to remove all terms set for post. |
|
| 182 | + * @param string|bool $value The term slug, or a comma separated list of slugs. Or false to remove all terms set for post. |
|
| 183 | 183 | * The first item is the name of taxonomy |
| 184 | 184 | * |
| 185 | 185 | * @return bool True if update was successful, false if not. |
@@ -192,7 +192,7 @@ discard block |
||
| 192 | 192 | $value = explode( ',', $value ); |
| 193 | 193 | } |
| 194 | 194 | |
| 195 | - // Deleting first array item |
|
| 195 | + // Deleting first array item |
|
| 196 | 196 | $taxonomy = array_shift($value); |
| 197 | 197 | $cats = array(); |
| 198 | 198 | foreach ($value as $cat) { |
@@ -214,7 +214,7 @@ discard block |
||
| 214 | 214 | |
| 215 | 215 | if( $value ) { |
| 216 | 216 | $time = current_time('mysql'); |
| 217 | - wp_update_post( |
|
| 217 | + wp_update_post( |
|
| 218 | 218 | array ( |
| 219 | 219 | 'ID' => $postid, // ID of the post to update |
| 220 | 220 | 'post_date' => date( 'Y-m-d H:i:s', strtotime($value) ), |
@@ -81,7 +81,7 @@ discard block |
||
| 81 | 81 | $postid = get_the_ID(); |
| 82 | 82 | |
| 83 | 83 | $post_date = get_the_time('U', $postid); |
| 84 | - $delta = time() - $post_date; |
|
| 84 | + $delta = time() - $post_date; |
|
| 85 | 85 | |
| 86 | 86 | $strings = array( |
| 87 | 87 | 'save' => __('Save','lasso'), |
@@ -127,11 +127,11 @@ discard block |
||
| 127 | 127 | $gallery_nonce = wp_create_nonce( $gallery_nonce_action ); |
| 128 | 128 | |
| 129 | 129 | |
| 130 | - if ($allow_change_date) { |
|
| 131 | - $permalink = get_site_url().'/?p='.$postid; |
|
| 132 | - } else { |
|
| 133 | - $permalink = get_permalink($postid); |
|
| 134 | - } |
|
| 130 | + if ($allow_change_date) { |
|
| 131 | + $permalink = get_site_url().'/?p='.$postid; |
|
| 132 | + } else { |
|
| 133 | + $permalink = get_permalink($postid); |
|
| 134 | + } |
|
| 135 | 135 | |
| 136 | 136 | // rest api |
| 137 | 137 | $rest_nonce = ''; |
@@ -227,7 +227,7 @@ discard block |
||
| 227 | 227 | |
| 228 | 228 | |
| 229 | 229 | if (!$using_restapiv2) { |
| 230 | - // enqueue REST API V1 |
|
| 230 | + // enqueue REST API V1 |
|
| 231 | 231 | wp_enqueue_script( 'wp-api-js', LASSO_URL.'/public/assets/js/source/util--wp-api.js', array( 'jquery', 'underscore', 'backbone' ), LASSO_VERSION, true ); |
| 232 | 232 | $settings = array( 'root' => home_url( $home_url ), 'nonce' => wp_create_nonce( 'wp_json' ) ); |
| 233 | 233 | wp_localize_script( 'wp-api-js', 'WP_API_Settings', $settings ); |
@@ -243,7 +243,7 @@ discard block |
||
| 243 | 243 | if ($show_color) { |
| 244 | 244 | wp_enqueue_script('lasso', LASSO_URL. "/public/assets/js/lasso{$postfix}.js", array('jquery', 'wp-api','iris'), LASSO_VERSION, true); |
| 245 | 245 | } else { |
| 246 | - wp_enqueue_script('lasso', LASSO_URL. "/public/assets/js/lasso{$postfix}.js", array('jquery', 'wp-api'), LASSO_VERSION, true); |
|
| 246 | + wp_enqueue_script('lasso', LASSO_URL. "/public/assets/js/lasso{$postfix}.js", array('jquery', 'wp-api'), LASSO_VERSION, true); |
|
| 247 | 247 | } |
| 248 | 248 | wp_localize_script('lasso', 'lasso_editor', apply_filters('lasso_localized_objects', $objects ) ); |
| 249 | 249 | |
@@ -151,7 +151,7 @@ discard block |
||
| 151 | 151 | $toolbar_class = $toolbar_headings ? 'toolbar-extended' : false; |
| 152 | 152 | |
| 153 | 153 | // mobile styles |
| 154 | - $mobile_class = $is_mobile ? 'lasso-mobile' : false; |
|
| 154 | + $mobile_class = $is_mobile ? 'lasso-mobile' : false; |
|
| 155 | 155 | $mobile_style =$is_mobile ? 'style="bottom:0px;"' : null; |
| 156 | 156 | |
| 157 | 157 | //show color |
@@ -430,7 +430,7 @@ discard block |
||
| 430 | 430 | </div> |
| 431 | 431 | <?php |
| 432 | 432 | if ($allow_change_date) { |
| 433 | - $dateformat = get_option( 'date_format' ); |
|
| 433 | + $dateformat = get_option( 'date_format' ); |
|
| 434 | 434 | ?> |
| 435 | 435 | <label><?php _e( 'Post Date', 'lasso' ); ?></label> |
| 436 | 436 | <input type="text" class="editus_custom_date" name="post_date" value="<?php echo get_the_time($dateformat, $postid);?>"/> |
@@ -567,8 +567,8 @@ discard block |
||
| 567 | 567 | global $post; |
| 568 | 568 | |
| 569 | 569 | global $wp_post_types; |
| 570 | - $labels = &$wp_post_types['post']->labels; |
|
| 571 | - $labels->name = 'Articles'; |
|
| 570 | + $labels = &$wp_post_types['post']->labels; |
|
| 571 | + $labels->name = 'Articles'; |
|
| 572 | 572 | |
| 573 | 573 | ob_start(); |
| 574 | 574 | |