Changeset 873210
- Timestamp:
- 03/11/2014 04:44:44 AM (12 years ago)
- Location:
- exxmlrpc/tags/0.2.0.9
- Files:
-
- 2 edited
-
Readme.txt (modified) (2 diffs)
-
exxmlrpc.php (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
exxmlrpc/tags/0.2.0.9/Readme.txt
r766750 r873210 5 5 Requires at least: 3.3.1 6 6 Tested up to: 3.5.2 7 Stable tag: 0.2. 0.97 Stable tag: 0.2.1.0 8 8 License: GPLv2 or later 9 9 License URI: http://www.gnu.org/licenses/gpl-2.0.html … … 58 58 Fix the search function of past articles. 59 59 60 0.2.0.9 61 Fix the search function of past articles. 62 60 63 == Upgrade Notice == 61 64 62 0.2. 0.965 0.2.1.0 63 66 Fix the search function of past articles. 64 67 -
exxmlrpc/tags/0.2.0.9/exxmlrpc.php
r766748 r873210 2 2 /* 3 3 Plugin Name: ExXmlRpc for WordPressPost 4 Version: 0.2. 0.94 Version: 0.2.1.0 5 5 Plugin URI:http://wpp.nethmk.com/plugin/ExXmlRpcForWPP/ExXmlRpc.zip 6 6 Description:ExXmlRpc(WordPressPost) is a plugin to post to WordPress from WordPressPost. … … 9 9 */ 10 10 11 define("THIS_VERSION", "0.2. 0.9");11 define("THIS_VERSION", "0.2.1.0"); 12 12 13 13 … … 43 43 $this->methods['wpex.replaceString'] = 'this:wpex_replaceString'; 44 44 $this->methods['wpex.getPages'] = 'this:wpex_getPages'; 45 $this->methods['wpex.saveCustomFields'] = 'this:wpxe_save_custom_fields'; 45 46 } 46 47 … … 624 625 $dateFrom = isset( $args[5] ) ? $args[5] : ''; 625 626 $dateTo = isset( $args[6] ) ? $args[6] : ''; 626 // mode=R:リプレイス mode=C:チェック 627 627 628 $mode = isset( $args[7] ) ? $args[7] : ''; 628 // type=POST:記事 type=PAGE:固定ページ 629 629 630 $type = isset( $args[8] ) ? $args[8] : ''; 630 631 … … 813 814 } 814 815 816 /* ------------------------------------------------------------------------- */ 817 /* Save Custom fields for WordPessPost */ 818 /* ------------------------------------------------------------------------- */ 819 function wpxe_save_custom_fields($args){ 820 821 $this->escape($args); 822 823 $blog_id = (int) $args[0]; 824 $username = $args[1]; 825 $password = $args[2]; 826 $post_id = isset($args[3]) ? $args[3] : ''; 827 $wpxe_custom_fields = $args[4]; 828 829 if ( $post_id <> '' ){ 830 foreach($wpxe_custom_fields as $wpxe_field) { 831 832 $wpxe_value = get_post_meta($post_id, $wpxe_field['key']); 833 $wpex_set_value = $wpxe_field['value']; 834 835 if( $wpxe_value == "" && $wpex_set_value!="" ) { 836 add_post_meta($post_id, $wpxe_field['key'], $wpex_set_value, true); 837 } elseif ( $wpxe_value != $wpex_set_value && $wpex_set_value<>"" ) { 838 update_post_meta($post_id, $wpxe_field['key'], $wpex_set_value); 839 } elseif ( $wpex_set_value == "" ) { 840 delete_post_meta( $post_id, $wpxe_field['key'] ); 841 } 842 } 843 return true; 844 845 }else{ 846 return false; 847 } 848 } 849 850 815 851 } 816 852 853 817 854 ?>
Note: See TracChangeset
for help on using the changeset viewer.