Changeset 1339583
- Timestamp:
- 01/30/2016 11:03:58 AM (10 years ago)
- Location:
- wp2jekyll/branches/0.3
- Files:
-
- 4 edited
-
inc/admin.php (modified) (2 diffs)
-
inc/hooks.php (modified) (2 diffs)
-
readme.txt (modified) (8 diffs)
-
wordpress2jekyll.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wp2jekyll/branches/0.3/inc/admin.php
r1339416 r1339583 12 12 function wordpress2jekyll_admin_menu( ) { 13 13 14 add_options_page('Word press2Jekyll', 'Wordpress2Jekyll', 'manage_options', 'wordpress2jekyll', 'wordpress2jekyll_options_page');14 add_options_page('WordPress2Jekyll', 'WordPress2Jekyll', 'manage_options', 'wordpress2jekyll', 'wordpress2jekyll_options_page'); 15 15 16 16 add_submenu_page('tools.php', 'Build', 'Jekyll', 'administrator', 'wordpress2jekyll-build', 'wordpress2jekyll_build_page', 'dashicons-migrate'); … … 549 549 ?> 550 550 <div class="wrap"> 551 <h2><?php _e('Word press2Jekyll Build', 'wordpress2jekyll') ?></h2>551 <h2><?php _e('WordPress2Jekyll Build', 'wordpress2jekyll') ?></h2> 552 552 553 553 <form method="post" action="admin.php?page=wordpress2jekyll-build"> 554 <p>Export all Word press posts and authors in to the Jekyll directory.</p>554 <p>Export all WordPress posts and authors in to the Jekyll directory.</p> 555 555 556 556 <?php submit_button('Export', 'primary', 'export'); ?> -
wp2jekyll/branches/0.3/inc/hooks.php
r1339416 r1339583 6 6 } 7 7 8 register_activation_hook(__FILE__, 'wordpress2jekyll_activate');9 8 add_action('save_post', 'wordpress2jekyll_write_post'); 10 9 add_action('post_updated', 'wordpress2jekyll_update_post', 10, 3); … … 17 16 18 17 add_action('edit_terms', 'wordpress2jekyll_taxonomy_update', 10, 2); 19 20 function wordpress2jekyll_activate()21 {22 update_option('jekyll_path', '../_jekyll');23 update_option('jekyll_posts_directory', '_posts');24 update_option('jekyll_assets_directory', '_assets');25 update_option('jekyll_data_directory', '_data');26 update_option('jekyll_enable_auto_build', 0);27 update_option('jekyll_save_pages', 0);28 update_option('jekyll_use_wordpress_permalinks', 1);29 update_option('jekyll_wordpress_preprocess_content',1);30 update_option('jekyll_export_post_meta', 0);31 update_option('jekyll_export_users', 0);32 update_option('jekyll_export_taxonomies', 0);33 update_option('jekyll_taxonomies', array());34 }35 18 36 19 function wordpress2jekll_save_post($post_id) -
wp2jekyll/branches/0.3/readme.txt
r1339578 r1339583 1 === Word press2Jekyll ===1 === WordPress2Jekyll === 2 2 Contributors: liam_bowers 3 3 Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=A5BPK7XBH54UY … … 9 9 License URI: http://www.gnu.org/licenses/gpl-3.0.html 10 10 11 This allows you to use Word press as an interface to Jekyll. It will save posts, taxonomies and author information out in a Jekyll friendly format.11 This allows you to use WordPress as an interface to Jekyll. It will save posts, taxonomies and author information out in a Jekyll friendly format. 12 12 13 13 == Description == … … 15 15 Jekyll is a great tool that will build a full blog site using text files written in a specific format. It gives you the bonus of having a very light and quick site that can't be hacked through script vulnerabilities. The downside of this is that it's not always easy to edit. It's harder still when using a mobile device. 16 16 17 This is where Word press comes in. Wordpress can be used to modify the posts (both standard posts and pages) and these changes will automatically be exported. The same applies for taxonomies and users if desired. This means that it is possible to edit content using a mobile device and the Wordpress app.17 This is where WordPress comes in. WordPress can be used to modify the posts (both standard posts and pages) and these changes will automatically be exported. The same applies for taxonomies and users if desired. This means that it is possible to edit content using a mobile device and the WordPress app. 18 18 19 Word press2Jekyll attempts to marry these two systems together in order to make a quick, secure website that can be easily managed from all devices.19 WordPress2Jekyll attempts to marry these two systems together in order to make a quick, secure website that can be easily managed from all devices. 20 20 21 21 = What can it do? = … … 24 24 * Converts page content to Markdown format (assumes it is HTML). 25 25 * Has option to use the Wordpress Permalinks patterns rather than using the configured Jekyll method. 26 * Ability to allow Word press to run content through the_content filter to allow plugins to interact with the body content.26 * Ability to allow WordPress to run content through the_content filter to allow plugins to interact with the body content. 27 27 * Automatically builds individual pages (or full build) depending on what has changed in the post. 28 28 * Configurable assets, data and posts directories. … … 38 38 1. Upload the plugin files to the `/wp-content/plugins/wp2jekyll` directory, or install the plugin through the WordPress plugins screen directly. 39 39 1. Activate the plugin through the 'Plugins' screen in WordPress. 40 1. Use the Settings->Word press2Jekyll screen to configure the plugin. This Jekyll path must point to an existing Jekyll site directory. If you're using it for testing purposes then make sure the assets, data and posts directories exist. It will complain if it doesn't find them.40 1. Use the Settings->WordPress2Jekyll screen to configure the plugin. This Jekyll path must point to an existing Jekyll site directory. If you're using it for testing purposes then make sure the assets, data and posts directories exist. It will complain if it doesn't find them. 41 41 1. Use Tools->Jekyll to perform a full export of the current content as defined in the settings. 42 42 … … 72 72 = 0.3 = 73 73 74 * Fixed issue relating to the default settings not being set correctly after plugin activation or upgrade. 74 75 * Fixed an issue regarding the check for Jekyll returning a false positive. 75 76 … … 96 97 == Limitations == 97 98 98 * This plugin assumes that all Jekyll posts are stored in Word press and any files in the posts directory can be deleted. This is a necessary for maintenance.99 * This plugin assumes that all Jekyll posts are stored in WordPress and any files in the posts directory can be deleted. This is a necessary for maintenance. 99 100 * Featured images will be exported and linked accordingly. 100 101 * Doesn't support password protected posts at this time (I'm not sure if it ever will). … … 102 103 * Supports categories (exported in order) 103 104 * Supports tags (exported in order) 104 * Ideally the Word press installation should be hidden away and not publicly accessible. I'm working on a separate plugin to do this easily.105 * Ideally the WordPress installation should be hidden away and not publicly accessible. I'm working on a separate plugin to do this easily. 105 106 106 107 == Wishlist == -
wp2jekyll/branches/0.3/wordpress2jekyll.php
r1339416 r1339583 1 1 <?php 2 2 /* 3 Plugin Name: Word press2Jekyll3 Plugin Name: WordPress2Jekyll 4 4 Plugin URI: https://wordpress.org/plugins/wp2jekyll/ 5 5 Description: This allows you to use WordPress as an interface to Jekyll. It will save posts, taxonomies and author information out in a Jekyll friendly format. … … 12 12 if ( ! defined( 'WPINC' ) ){ 13 13 die; 14 } 15 16 //Activation hook 17 18 register_activation_hook(__FILE__, 'wordpress2jekyll_activate'); 19 20 function wordpress2jekyll_activate() 21 { 22 update_option('jekyll_path', '../_jekyll'); 23 update_option('jekyll_posts_directory', '_posts'); 24 update_option('jekyll_assets_directory', '_assets'); 25 update_option('jekyll_data_directory', '_data'); 26 update_option('jekyll_enable_auto_build', 0); 27 update_option('jekyll_save_pages', 0); 28 update_option('jekyll_use_wordpress_permalinks', 1); 29 update_option('jekyll_wordpress_preprocess_content',1); 30 update_option('jekyll_export_post_meta', 0); 31 update_option('jekyll_export_users', 0); 32 update_option('jekyll_export_taxonomies', 0); 33 update_option('jekyll_taxonomies', array()); 14 34 } 15 35 … … 26 46 echo wp_kses_post( __( '<b>Wordpress2Jekyll</b> requires PHP 5.3 or higher, and the plugin has now disabled itself.', 'wordpress2jekyll' ) ) . 27 47 '<br />' . 28 esc_attr__( 'To allow better control over dates, advanced security improvements and performance gain.', 'wordpress2jekyll' ) .29 '<br />' .30 48 esc_attr__( 'Contact your Hosting or your system administrator and ask for this Upgrade to version 5.3 of PHP.', 'wordpress2jekyll' ); 31 49 exit();
Note: See TracChangeset
for help on using the changeset viewer.