Changeset 1810242
- Timestamp:
- 01/26/2018 11:00:44 PM (8 years ago)
- Location:
- wp-mastodon-share/trunk
- Files:
-
- 1 added
- 2 edited
-
form.tpl.php (modified) (2 diffs)
-
uninstall.php (added)
-
wp-mastodon-share.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wp-mastodon-share/trunk/form.tpl.php
r1809481 r1810242 10 10 </th> 11 11 <td> 12 <input type="text" id="instance" name="instance" size="80" value="<?php esc_attr_e( $instance ); ?>"> 12 <input type="text" id="instance" name="instance" size="80" value="<?php esc_attr_e( $instance ); ?>" pattern="^http.+"> 13 <p class="description"><?php esc_html_e('The instance url must be like http(s)://domain.tld', 'wp-mastodon-share') ?></p> 13 14 </td> 14 15 </tr> … … 42 43 <textarea rows="10" cols="80" name="message" id="message"><?php esc_html_e( stripslashes( $message ) ); ?></textarea> 43 44 <p class="description"><i><?php esc_html_e( 'You can use these metas in the message', 'wp-mastodon-share' ); ?></i> 44 : [title], [excerpt], [permalink] <?php esc_html_e( 'and', 'wp-mastodon-share' ); ?> <a href="#" draggable="true">[tags]</a></p>45 : [title], [excerpt], [permalink] <?php esc_html_e( 'and', 'wp-mastodon-share' ); ?> [tags]</p> 45 46 </td> 46 47 </tr> -
wp-mastodon-share/trunk/wp-mastodon-share.php
r1809646 r1810242 26 26 add_action( 'tiny_mce_before_init', array($this, 'tinymce_before_init' ) ); 27 27 add_action( 'publish_future_post', array($this, 'toot_scheduled_post') ); 28 29 register_uninstall_hook(__FILE__, array($this, 'uninstall'));30 28 } 31 29 … … 163 161 } 164 162 165 $message = get_option( 'mastoshare-message', '[title] - [excerpt] - [permalink]');163 $message = get_option( 'mastoshare-message', "[title]\n\n[excerpt]\n\n[permalink]\n\n[tags]" ); 166 164 $mode = get_option( 'mastoshare-mode', 'public' ); 167 165 $toot_size = get_option( 'mastoshare-toot-size', 500 ); … … 359 357 return $init_array; 360 358 } 361 362 public function uninstall(){363 delete_option( 'mastoshare-client-id' );364 delete_option( 'mastoshare-client-secret' );365 delete_option( 'mastoshare-token' );366 delete_option( 'mastoshare-instance' );367 delete_option( 'mastoshare-message' );368 delete_option( 'mastoshare-mode' );369 delete_option( 'mastoshare-toot-size' );370 delete_option( 'mastoshare-notice' );371 }372 359 } 373 360
Note: See TracChangeset
for help on using the changeset viewer.