4 Commits

Author SHA1 Message Date
htdat 4c6f02f4ec Update readme.txt for the version 1.1 2017-01-03 08:58:52 +07:00
htdat de81124fe0 Push to the version 1.1 2017-01-02 08:32:17 +07:00
htdat 16a12b59ae Push to the version 1.1 2017-01-02 08:23:13 +07:00
dat b3eb79cc3f Rename to "Woo Viet"
* Replace all “WooCommerce for Vietnam” to “Woo Viet”

* Replace all “woocomerce-fo-vietnam” to “woo-viet”
2017-01-02 08:18:01 +07:00
6 changed files with 122 additions and 127 deletions
+20 -20
View File
@@ -5,7 +5,7 @@ if ( ! defined( 'ABSPATH' ) ) {
} }
/** /**
* Create the admin page under wp-admin -> WooCommerce -> WooCommerce for Vietnam * Create the admin page under wp-admin -> WooCommerce -> Woo Viet
* *
* @author htdat * @author htdat
* @since 1.0 * @since 1.0
@@ -36,33 +36,33 @@ class WooViet_Admin_Page {
*/ */
public function save_settings() { public function save_settings() {
if ( wp_verify_nonce( $_REQUEST['wooviet_nonce'], 'wooviet_save_settings' ) ) { if ( wp_verify_nonce( $_REQUEST['wooviet_nonce'], 'wooviet_save_settings' ) ) {
update_option( 'woocommerce-for-vietnam', $_REQUEST['settings'] ); update_option( 'woo-viet', $_REQUEST['settings'] );
$this->message = $this->message =
'<div class="updated notice"><p><strong>' . '<div class="updated notice"><p><strong>' .
__( 'Settings saved', 'woocommerce-for-vietnam' ) . __( 'Settings saved', 'woo-viet' ) .
'</p></strong></div>'; '</p></strong></div>';
} else { } else {
$this->message = $this->message =
'<div class="error notice"><p><strong>' . '<div class="error notice"><p><strong>' .
__( 'Can not save settings! Please refresh this page.', 'woocommerce-for-vietnam' ) . __( 'Can not save settings! Please refresh this page.', 'woo-viet' ) .
'</p></strong></div>'; '</p></strong></div>';
} }
} }
/** /**
* Register the sub-menu under "WooCommerce" * Register the sub-menu under "WooCommerce"
* Link: http://my-site.com/wp-admin/admin.php?page=woocommerce-for-vietnam * Link: http://my-site.com/wp-admin/admin.php?page=woo-viet
*/ */
public function register_submenu_page() { public function register_submenu_page() {
add_submenu_page( add_submenu_page(
'woocommerce', 'woocommerce',
'WooCommerce for Vietnam Settings', 'Woo Viet Settings',
'WooCommerce for Vietnam', 'Woo Viet',
'manage_options', 'manage_options',
'woocommerce-for-vietnam', 'woo-viet',
array( $this, 'admin_page_html' ) array( $this, 'admin_page_html' )
); );
} }
@@ -89,61 +89,61 @@ class WooViet_Admin_Page {
<table class="form-table"> <table class="form-table">
<tbody> <tbody>
<tr> <tr>
<th scope="row"><?php _e( 'Add provinces for Vietnam', 'woocommerce-for-vietnam' ) ?></th> <th scope="row"><?php _e( 'Add provinces for Vietnam', 'woo-viet' ) ?></th>
<td> <td>
<input name="settings[add_province][enabled]" type="hidden" value="no"> <input name="settings[add_province][enabled]" type="hidden" value="no">
<input name="settings[add_province][enabled]" type="checkbox" id="add_province" value="yes" <input name="settings[add_province][enabled]" type="checkbox" id="add_province" value="yes"
<?php if ( 'yes' == $settings['add_province']['enabled'] ) <?php if ( 'yes' == $settings['add_province']['enabled'] )
echo 'checked="checked"' ?>> echo 'checked="checked"' ?>>
<label for="add_province"><?php _e( 'Enabled', 'woocommerce-for-vietnam' ) ?></label> <label for="add_province"><?php _e( 'Enabled', 'woo-viet' ) ?></label>
</td> </td>
</tr> </tr>
<tr> <tr>
<th scope="row"><?php _e( 'Change VND currency symbol', 'woocommerce-for-vietnam' ) ?></th> <th scope="row"><?php _e( 'Change VND currency symbol', 'woo-viet' ) ?></th>
<td> <td>
<input name="settings[change_currency_symbol][enabled]" type="hidden" value="no"> <input name="settings[change_currency_symbol][enabled]" type="hidden" value="no">
<input name="settings[change_currency_symbol][enabled]" type="checkbox" <input name="settings[change_currency_symbol][enabled]" type="checkbox"
id="change_currency_symbol" value="yes" id="change_currency_symbol" value="yes"
<?php if ( 'yes' == $settings['change_currency_symbol']['enabled'] ) <?php if ( 'yes' == $settings['change_currency_symbol']['enabled'] )
echo 'checked="checked"' ?>> echo 'checked="checked"' ?>>
<label for="change_currency_symbol"><?php _e( 'Enabled', 'woocommerce-for-vietnam' ) ?></label> <label for="change_currency_symbol"><?php _e( 'Enabled', 'woo-viet' ) ?></label>
<br/> <br/>
<br/> <br/>
<input type="text" name="settings[change_currency_symbol][text]" <input type="text" name="settings[change_currency_symbol][text]"
value="<?php echo $settings['change_currency_symbol']['text'] ?>" value="<?php echo $settings['change_currency_symbol']['text'] ?>"
id="change_currency_symbol_text" class="small-text"> id="change_currency_symbol_text" class="small-text">
<label for="change_currency_symbol_text"><?php _e( 'Insert a text to change the default symbol <code>đ</code>', 'woocommerce-for-vietnam' ) ?></label> <label for="change_currency_symbol_text"><?php _e( 'Insert a text to change the default symbol <code>đ</code>', 'woo-viet' ) ?></label>
</td> </td>
</tr> </tr>
<tr> <tr>
<th scope="row"><?php _e( 'Convert <code>000</code> of prices to K (or anything)', 'woocommerce-for-vietnam' ) ?></th> <th scope="row"><?php _e( 'Convert <code>000</code> of prices to K (or anything)', 'woo-viet' ) ?></th>
<td> <td>
<input name="settings[convert_price][enabled]" type="hidden" value="no"> <input name="settings[convert_price][enabled]" type="hidden" value="no">
<input name="settings[convert_price][enabled]" type="checkbox" id="convert_price" <input name="settings[convert_price][enabled]" type="checkbox" id="convert_price"
value="yes" value="yes"
<?php if ( 'yes' == $settings['convert_price']['enabled'] ) <?php if ( 'yes' == $settings['convert_price']['enabled'] )
echo 'checked="checked"' ?>> echo 'checked="checked"' ?>>
<label for="convert_price"><?php _e( 'Enabled', 'woocommerce-for-vietnam' ) ?></label> <label for="convert_price"><?php _e( 'Enabled', 'woo-viet' ) ?></label>
<fieldset><br/> <fieldset><br/>
<input type="text" name="settings[convert_price][text]" <input type="text" name="settings[convert_price][text]"
value="<?php echo $settings['convert_price']['text'] ?>" value="<?php echo $settings['convert_price']['text'] ?>"
id="convert_price_text" class="small-text"> id="convert_price_text" class="small-text">
<label for="convert_price_text"><?php _e( 'Choose what you want to change. E.g:', 'woocommerce-for-vietnam' ) ?> <label for="convert_price_text"><?php _e( 'Choose what you want to change. E.g:', 'woo-viet' ) ?>
<code>K</code>, <code>nghìn</code>, <code>ngàn</code></label> <code>K</code>, <code>nghìn</code>, <code>ngàn</code></label>
</fieldset> </fieldset>
</td> </td>
</tr> </tr>
<tr> <tr>
<th scope="row"><?php printf( __( 'Support VND for <a href="%s">the PayPal Standard gateway</a>', 'woocommerce-for-vietnam' ), 'https://docs.woocommerce.com/document/paypal-standard/' ) ?></th> <th scope="row"><?php printf( __( 'Support VND for <a href="%s">the PayPal Standard gateway</a>', 'woo-viet' ), 'https://docs.woocommerce.com/document/paypal-standard/' ) ?></th>
<td> <td>
<input name="settings[vnd_paypal_standard][enabled]" type="hidden" value="no"> <input name="settings[vnd_paypal_standard][enabled]" type="hidden" value="no">
<input name="settings[vnd_paypal_standard][enabled]" type="checkbox" <input name="settings[vnd_paypal_standard][enabled]" type="checkbox"
id="vnd_paypal_standard" value="yes" id="vnd_paypal_standard" value="yes"
<?php if ( 'yes' == $settings['vnd_paypal_standard']['enabled'] ) <?php if ( 'yes' == $settings['vnd_paypal_standard']['enabled'] )
echo 'checked="checked"' ?>> echo 'checked="checked"' ?>>
<label for="vnd_paypal_standard"><?php _e( 'Enabled', 'woocommerce-for-vietnam' ) ?></label> <label for="vnd_paypal_standard"><?php _e( 'Enabled', 'woo-viet' ) ?></label>
<fieldset><br/> <fieldset><br/>
<select name="settings[vnd_paypal_standard][currency]" <select name="settings[vnd_paypal_standard][currency]"
@@ -188,14 +188,14 @@ class WooViet_Admin_Page {
} }
?> ?>
</select> </select>
<label for="vnd_paypal_standard_currency"><?php _e( 'Select a PayPal supported currency (like USD, EUR, etc), which is used to convert VND prices', 'woocommerce-for-vietnam' ) ?></label> <label for="vnd_paypal_standard_currency"><?php _e( 'Select a PayPal supported currency (like USD, EUR, etc), which is used to convert VND prices', 'woo-viet' ) ?></label>
<br/> <br/>
<br/> <br/>
<input name="settings[vnd_paypal_standard][rate]" type="number" step="1" min="100" <input name="settings[vnd_paypal_standard][rate]" type="number" step="1" min="100"
id="vnd_paypal_standard_rate" style="width: 70px;" id="vnd_paypal_standard_rate" style="width: 70px;"
value="<?php echo $settings['vnd_paypal_standard']['rate'] ?>" value="<?php echo $settings['vnd_paypal_standard']['rate'] ?>"
<label for="vnd_paypal_standard_rate"><?php _e( 'Insert the exchange rate of this currency to VND', 'woocommerce-for-vietnam' ) ?></label> <label for="vnd_paypal_standard_rate"><?php _e( 'Insert the exchange rate of this currency to VND', 'woo-viet' ) ?></label>
</fieldset> </fieldset>
</td> </td>
+63 -63
View File
@@ -68,69 +68,69 @@ class WooViet_Provinces {
* @source: https://vi.wikipedia.org/wiki/Tỉnh_thành_Việt_Nam and https://en.wikipedia.org/wiki/Provinces_of_Vietnam * @source: https://vi.wikipedia.org/wiki/Tỉnh_thành_Việt_Nam and https://en.wikipedia.org/wiki/Provinces_of_Vietnam
*/ */
$states['VN'] = array( $states['VN'] = array(
'AN-GIANG' => __( 'An Giang', 'woocommerce-for-vietnam' ), 'AN-GIANG' => __( 'An Giang', 'woo-viet' ),
'BA-RIA-VUNG-TAU' => __( 'Ba Ria - Vung Tau', 'woocommerce-for-vietnam' ), 'BA-RIA-VUNG-TAU' => __( 'Ba Ria - Vung Tau', 'woo-viet' ),
'BAC-LIEU' => __( 'Bac Lieu', 'woocommerce-for-vietnam' ), 'BAC-LIEU' => __( 'Bac Lieu', 'woo-viet' ),
'BAC-KAN' => __( 'Bac Kan', 'woocommerce-for-vietnam' ), 'BAC-KAN' => __( 'Bac Kan', 'woo-viet' ),
'BAC-GIANG' => __( 'Bac Giang', 'woocommerce-for-vietnam' ), 'BAC-GIANG' => __( 'Bac Giang', 'woo-viet' ),
'BAC-NINH' => __( 'Bac Ninh', 'woocommerce-for-vietnam' ), 'BAC-NINH' => __( 'Bac Ninh', 'woo-viet' ),
'BEN-TRE' => __( 'Ben Tre', 'woocommerce-for-vietnam' ), 'BEN-TRE' => __( 'Ben Tre', 'woo-viet' ),
'BINH-DUONG' => __( 'Binh Duong', 'woocommerce-for-vietnam' ), 'BINH-DUONG' => __( 'Binh Duong', 'woo-viet' ),
'BINH-DINH' => __( 'Binh Dinh', 'woocommerce-for-vietnam' ), 'BINH-DINH' => __( 'Binh Dinh', 'woo-viet' ),
'BINH-PHUOC' => __( 'Binh Phuoc', 'woocommerce-for-vietnam' ), 'BINH-PHUOC' => __( 'Binh Phuoc', 'woo-viet' ),
'BINH-THUAN' => __( 'Binh Thuan', 'woocommerce-for-vietnam' ), 'BINH-THUAN' => __( 'Binh Thuan', 'woo-viet' ),
'CA-MAU' => __( 'Ca Mau', 'woocommerce-for-vietnam' ), 'CA-MAU' => __( 'Ca Mau', 'woo-viet' ),
'CAO-BANG' => __( 'Cao Bang', 'woocommerce-for-vietnam' ), 'CAO-BANG' => __( 'Cao Bang', 'woo-viet' ),
'CAN-THO' => __( 'Can Tho', 'woocommerce-for-vietnam' ), 'CAN-THO' => __( 'Can Tho', 'woo-viet' ),
'DA-NANG' => __( 'Da Nang', 'woocommerce-for-vietnam' ), 'DA-NANG' => __( 'Da Nang', 'woo-viet' ),
'DAK-LAK' => __( 'Dak Lak', 'woocommerce-for-vietnam' ), 'DAK-LAK' => __( 'Dak Lak', 'woo-viet' ),
'DAK-NONG' => __( 'Dak Nong', 'woocommerce-for-vietnam' ), 'DAK-NONG' => __( 'Dak Nong', 'woo-viet' ),
'DONG-NAI' => __( 'Dong Nai', 'woocommerce-for-vietnam' ), 'DONG-NAI' => __( 'Dong Nai', 'woo-viet' ),
'DONG-THAP' => __( 'Dong Thap', 'woocommerce-for-vietnam' ), 'DONG-THAP' => __( 'Dong Thap', 'woo-viet' ),
'DIEN-BIEN' => __( 'Dien Bien', 'woocommerce-for-vietnam' ), 'DIEN-BIEN' => __( 'Dien Bien', 'woo-viet' ),
'GIA-LAI' => __( 'Gia Lai', 'woocommerce-for-vietnam' ), 'GIA-LAI' => __( 'Gia Lai', 'woo-viet' ),
'HA-GIANG' => __( 'Ha Giang', 'woocommerce-for-vietnam' ), 'HA-GIANG' => __( 'Ha Giang', 'woo-viet' ),
'HA-NAM' => __( 'Ha Nam', 'woocommerce-for-vietnam' ), 'HA-NAM' => __( 'Ha Nam', 'woo-viet' ),
'HA-NOI' => __( 'Ha Noi', 'woocommerce-for-vietnam' ), 'HA-NOI' => __( 'Ha Noi', 'woo-viet' ),
'HA-TINH' => __( 'Ha Tinh', 'woocommerce-for-vietnam' ), 'HA-TINH' => __( 'Ha Tinh', 'woo-viet' ),
'HAI-DUONG' => __( 'Hai Duong', 'woocommerce-for-vietnam' ), 'HAI-DUONG' => __( 'Hai Duong', 'woo-viet' ),
'HAI-PHONG' => __( 'Hai Phong', 'woocommerce-for-vietnam' ), 'HAI-PHONG' => __( 'Hai Phong', 'woo-viet' ),
'HOA-BINH' => __( 'Hoa Binh', 'woocommerce-for-vietnam' ), 'HOA-BINH' => __( 'Hoa Binh', 'woo-viet' ),
'HAU-GIANG' => __( 'Hau Giang', 'woocommerce-for-vietnam' ), 'HAU-GIANG' => __( 'Hau Giang', 'woo-viet' ),
'HUNG-YEN' => __( 'Hung Yen', 'woocommerce-for-vietnam' ), 'HUNG-YEN' => __( 'Hung Yen', 'woo-viet' ),
'HO-CHI-MINH' => __( 'Ho Chi Minh', 'woocommerce-for-vietnam' ), 'HO-CHI-MINH' => __( 'Ho Chi Minh', 'woo-viet' ),
'KHANH-HOA' => __( 'Khanh Hoa', 'woocommerce-for-vietnam' ), 'KHANH-HOA' => __( 'Khanh Hoa', 'woo-viet' ),
'KIEN-GIANG' => __( 'Kien Giang', 'woocommerce-for-vietnam' ), 'KIEN-GIANG' => __( 'Kien Giang', 'woo-viet' ),
'KON-TUM' => __( 'Kon Tum', 'woocommerce-for-vietnam' ), 'KON-TUM' => __( 'Kon Tum', 'woo-viet' ),
'LAI-CHAU' => __( 'Lai Chau', 'woocommerce-for-vietnam' ), 'LAI-CHAU' => __( 'Lai Chau', 'woo-viet' ),
'LAO-CAI' => __( 'Lao Cai', 'woocommerce-for-vietnam' ), 'LAO-CAI' => __( 'Lao Cai', 'woo-viet' ),
'LANG-SON' => __( 'Lang Son', 'woocommerce-for-vietnam' ), 'LANG-SON' => __( 'Lang Son', 'woo-viet' ),
'LAM-DONG' => __( 'Lam Dong', 'woocommerce-for-vietnam' ), 'LAM-DONG' => __( 'Lam Dong', 'woo-viet' ),
'LONG-AN' => __( 'Long An', 'woocommerce-for-vietnam' ), 'LONG-AN' => __( 'Long An', 'woo-viet' ),
'NAM-DINH' => __( 'Nam Dinh', 'woocommerce-for-vietnam' ), 'NAM-DINH' => __( 'Nam Dinh', 'woo-viet' ),
'NGHE-AN' => __( 'Nghe An', 'woocommerce-for-vietnam' ), 'NGHE-AN' => __( 'Nghe An', 'woo-viet' ),
'NINH-BINH' => __( 'Ninh Binh', 'woocommerce-for-vietnam' ), 'NINH-BINH' => __( 'Ninh Binh', 'woo-viet' ),
'NINH-THUAN' => __( 'Ninh Thuan', 'woocommerce-for-vietnam' ), 'NINH-THUAN' => __( 'Ninh Thuan', 'woo-viet' ),
'PHU-THO' => __( 'Phu Tho', 'woocommerce-for-vietnam' ), 'PHU-THO' => __( 'Phu Tho', 'woo-viet' ),
'PHU-YEN' => __( 'Phu Yen', 'woocommerce-for-vietnam' ), 'PHU-YEN' => __( 'Phu Yen', 'woo-viet' ),
'QUANG-BINH' => __( 'Quang Binh', 'woocommerce-for-vietnam' ), 'QUANG-BINH' => __( 'Quang Binh', 'woo-viet' ),
'QUANG-NAM' => __( 'Quang Nam', 'woocommerce-for-vietnam' ), 'QUANG-NAM' => __( 'Quang Nam', 'woo-viet' ),
'QUANG-NGAI' => __( 'Quang Ngai', 'woocommerce-for-vietnam' ), 'QUANG-NGAI' => __( 'Quang Ngai', 'woo-viet' ),
'QUANG-NINH' => __( 'Quang Ninh', 'woocommerce-for-vietnam' ), 'QUANG-NINH' => __( 'Quang Ninh', 'woo-viet' ),
'QUANG-TRI' => __( 'Quang Tri', 'woocommerce-for-vietnam' ), 'QUANG-TRI' => __( 'Quang Tri', 'woo-viet' ),
'SOC-TRANG' => __( 'Soc Trang', 'woocommerce-for-vietnam' ), 'SOC-TRANG' => __( 'Soc Trang', 'woo-viet' ),
'SON-LA' => __( 'Son La', 'woocommerce-for-vietnam' ), 'SON-LA' => __( 'Son La', 'woo-viet' ),
'TAY-NINH' => __( 'Tay Ninh', 'woocommerce-for-vietnam' ), 'TAY-NINH' => __( 'Tay Ninh', 'woo-viet' ),
'THAI-BINH' => __( 'Thai Binh', 'woocommerce-for-vietnam' ), 'THAI-BINH' => __( 'Thai Binh', 'woo-viet' ),
'THAI-NGUYEN' => __( 'Thai Nguyen', 'woocommerce-for-vietnam' ), 'THAI-NGUYEN' => __( 'Thai Nguyen', 'woo-viet' ),
'THANH-HOA' => __( 'Thanh Hoa', 'woocommerce-for-vietnam' ), 'THANH-HOA' => __( 'Thanh Hoa', 'woo-viet' ),
'THUA-THIEN-HUE' => __( 'Thua Thien - Hue', 'woocommerce-for-vietnam' ), 'THUA-THIEN-HUE' => __( 'Thua Thien - Hue', 'woo-viet' ),
'TIEN-GIANG' => __( 'Tien Giang', 'woocommerce-for-vietnam' ), 'TIEN-GIANG' => __( 'Tien Giang', 'woo-viet' ),
'TRA-VINH' => __( 'Tra Vinh', 'woocommerce-for-vietnam' ), 'TRA-VINH' => __( 'Tra Vinh', 'woo-viet' ),
'TUYEN-QUANG' => __( 'Tuyen Quang', 'woocommerce-for-vietnam' ), 'TUYEN-QUANG' => __( 'Tuyen Quang', 'woo-viet' ),
'VINH-LONG' => __( 'Vinh Long', 'woocommerce-for-vietnam' ), 'VINH-LONG' => __( 'Vinh Long', 'woo-viet' ),
'VINH-PHUC' => __( 'Vinh Phuc', 'woocommerce-for-vietnam' ), 'VINH-PHUC' => __( 'Vinh Phuc', 'woo-viet' ),
'YEN-BAI' => __( 'Yen Bai', 'woocommerce-for-vietnam' ), 'YEN-BAI' => __( 'Yen Bai', 'woo-viet' ),
); );
return $states; return $states;
+1 -1
View File
@@ -97,7 +97,7 @@ class WooViet_VND_PayPal_Standard {
$value['description'] .= '<br />'; $value['description'] .= '<br />';
$value['description'] .= $value['description'] .=
sprintf( __( 'The prices will be converted to %1$s in the PayPal pages with the exchange rate %2$s.', 'woocommerce-for-vietnam' ), sprintf( __( 'The prices will be converted to %1$s in the PayPal pages with the exchange rate %2$s.', 'woo-viet' ),
"<span style='color:red'> $this->paypal_currency</span>", "<span style='color:red'> $this->paypal_currency</span>",
"<span style='color:red'> $this->paypal_currency / VND = $this->exchange_rate_to_vnd</span>" "<span style='color:red'> $this->paypal_currency / VND = $this->exchange_rate_to_vnd</span>"
); );
@@ -14,9 +14,9 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n" "Content-Transfer-Encoding: 8bit\n"
"X-Generator: Loco https://localise.biz/" "X-Generator: Loco https://localise.biz/"
#: woocommerce-for-vietnam.php:87 #: woo-viet.php:87
msgid "" msgid ""
"WooCommerce for Vietnam is not running because WooCommerce is not active. " "Woo Viet is not running because WooCommerce is not active. "
"Please activate both plugins" "Please activate both plugins"
msgstr "" msgstr ""
@@ -328,7 +328,7 @@ msgid ""
msgstr "" msgstr ""
#. Name of the plugin #. Name of the plugin
msgid "WooCommerce for Vietnam" msgid "Woo Viet"
msgstr "" msgstr ""
#. Description of the plugin #. Description of the plugin
@@ -337,7 +337,7 @@ msgid ""
msgstr "" msgstr ""
#. URI of the plugin #. URI of the plugin
msgid "https://github.com/htdat/woocommerce-for-vietnam" msgid "https://github.com/htdat/woo-viet"
msgstr "" msgstr ""
#. Author of the plugin #. Author of the plugin
+26 -31
View File
@@ -1,9 +1,9 @@
=== Plugin Name === === Woo Viet - WooCommerce for Vietnam ===
Contributors: htdat Contributors: htdat
Tags: WooCommerce Vietnam, vietnam, vietnamese, vietnam provinces, paypal for vietnam dong, vnd, vietnam dong Tags: WooCommerce Vietnam, vietnam, vietnamese, vietnam provinces, paypal for vietnam dong, vnd, vietnam dong, vietnam currency, vietnam customization
Requires at least: 4.3 Requires at least: 4.3
Tested up to: 4.7 Tested up to: 4.7
Stable tag: 1.0 Stable tag: 1.1
License: GPLv2 or later License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html License URI: https://www.gnu.org/licenses/gpl-2.0.html
@@ -11,84 +11,79 @@ Add features to WooCommerce stores having anything related to Vietnam: currency,
== Description == == Description ==
`WooCommerce for Vietnam` brings the features that help to run WooCommerce stores and customize them for Vietnam much easier. **Woo Viet brings the features that help to run WooCommerce stores and customize them for Vietnam much easier.**
`WooCommerce for Vietnam` đem đến các chức năng để site WooCommerce có thể dễ dàng tuỳ biến cho thị trường Việt Nam. **Woo Viet đem đến các chức năng để site WooCommerce có thể dễ dàng tuỳ biến cho thị trường Việt Nam.**
**Chức năng - Features** = CHỨC NĂNG - FEATURES =
(Tiếng Việt) **(Tiếng Việt)**
* Đổi ký hiệu ngôn ngữ của VND từ mặc định `đ` sang bất cứ thừ gì khác, ví dụ: `VND`, `VNĐ`, `đồng`, v..
* Đổi ký hiệu ngôn ngữ của VND từ mặc định `đ` sang bất cứ thừ gì khác, ví dụ: `VND`, `VNĐ`, `đồng`, v.v.
* Thêm tỉnh thành cho Việt Nam khi khách hiền điền địa chỉ nhận hàng hoặc nhận hoá đơn. Chức năng này không có ở trong WooCommerce mặc định. * Thêm tỉnh thành cho Việt Nam khi khách hiền điền địa chỉ nhận hàng hoặc nhận hoá đơn. Chức năng này không có ở trong WooCommerce mặc định.
* Đổi các số `000` trong giá cả thành `K` (hoặc bất cứ từ nào khác). Ví dụ: `50000` (VND) thành `50K` (VND), hay `50 nghìn` (VND). * Đổi các số `000` trong giá cả thành `K` (hoặc bất cứ từ nào khác). Ví dụ: `50000` (VND) thành `50K` (VND), hay `50 nghìn` (VND).
* Hỗ trợ `VND` cho [cổng thanh toán PayPal Standard](https://docs.woocommerce.com/document/paypal-standard/). Chuyển đổi các giá `VND` sang bất kỳ loại tiền tệ nào mà PayPal hỗ trợ trước khi chuyển người dùng sang PayPal. * Hỗ trợ `VND` cho [cổng thanh toán PayPal Standard](https://docs.woocommerce.com/document/paypal-standard/). Chuyển đổi các giá `VND` sang bất kỳ loại tiền tệ nào mà PayPal hỗ trợ trước khi chuyển người dùng sang PayPal.
**(English)**
(English)
* Change the VND currency symbol `đ` to anything, e.g: `VND`, `VNĐ`, `đồng`, etc. * Change the VND currency symbol `đ` to anything, e.g: `VND`, `VNĐ`, `đồng`, etc.
* Add provinces for Vietnam when visitors select Vietnam as a country of the shipping (billing) address. This is not available in WooCommerce by default. * Add provinces for Vietnam when visitors select Vietnam as a country of the shipping (billing) address. This is not available in WooCommerce by default.
* Convert `000` of prices to `K` (or anything). E.g: `50000` (VND) will be `50K` (VND), or `50 thousand` (VND). * Convert `000` of prices to `K` (or anything). E.g: `50000` (VND) will be `50K` (VND), or `50 thousand` (VND).
* Support `VND` for [the PayPal Standard gateway](https://docs.woocommerce.com/document/paypal-standard/). Convert `VND` prices to any PayPal supported currency before sending visitors to the PayPal pages. * Support `VND` for [the PayPal Standard gateway](https://docs.woocommerce.com/document/paypal-standard/). Convert `VND` prices to any PayPal supported currency before sending visitors to the PayPal pages.
**Road Map** = ROAD MAP =
In the future, this plugin will be added more and more features for the Vietnam market: In the future, this plugin will be added more and more features for the Vietnam market:
* Integrate all districts to Vietnam provinces. * Integrate all districts to Vietnam provinces.
* Integrate at least one solution for collecting money by phone cards. * Integrate at least one solution for collecting money by phone cards.
* Integrate the Vietnam payment gateways like 1Pay, OnePay, BaoKim, Ngan Luong, etc. * Integrate the Vietnam payment gateways like 1Pay, OnePay, BaoKim, Ngan Luong, etc.
* Integrate the Vietnam shipping solutions like ShipChung, Giaohangnhanh, ViettelPost, etc. * Integrate the Vietnam shipping solutions like ShipChung, Giaohangnhanh, ViettelPost, etc.
**Where can I contribute my code or idea?** = WHERE CAN I CONTRIBUTE MY CODE OR IDEA? =
* You can report bugs or contribute code on [this GitHub repo](https://github.com/htdat/woocommerce-for-vietnam).
* You can report bugs or contribute code on [this GitHub repo](https://github.com/htdat/woo-viet).
* Please also do let us know if the "bug" is just a grammar/spelling error in both English and Vietnamese. We try to make our products as perfect as possible. * Please also do let us know if the "bug" is just a grammar/spelling error in both English and Vietnamese. We try to make our products as perfect as possible.
**Installation** = INSTALLATION =
Follow these steps to install and use the plugin: Follow these steps to install and use the plugin:
1. Upload the plugin files to the `/wp-content/plugins/woocommerce-for-vietnam` directory, or install the plugin through the WordPress plugins screen directly. 1. Upload the plugin files to the `/wp-content/plugins/woo-viet` directory, or install the plugin through the WordPress plugins screen directly.
1. Activate the plugin through the `Plugins` screen in WordPress. 1. Activate the plugin through the `Plugins` screen in WordPress.
1. Go to the `WooCommerce -> WooCommerce for Vietnam` screen and configure the plugin. 1. Go to the `WooCommerce -> Woo Viet` screen and configure the plugin.
== Installation == == Installation ==
Follow these steps to install and use the plugin: Follow these steps to install and use the plugin:
1. Upload the plugin files to the `/wp-content/plugins/woocommerce-for-vietnam` directory, or install the plugin through the WordPress plugins screen directly. 1. Upload the plugin files to the `/wp-content/plugins/woo-viet` directory, or install the plugin through the WordPress plugins screen directly.
1. Activate the plugin through the 'Plugins' screen in WordPress. 1. Activate the plugin through the 'Plugins' screen in WordPress.
1. Go to the `WooCommerce -> WooCommerce for Vietnam` screen and configure the plugin. 1. Go to the `WooCommerce -> Woo Viet` screen and configure the plugin.
== Frequently Asked Questions == == Frequently Asked Questions ==
= Where can I contribute my code or idea? = = WHERE CAN I CONTRIBUTE MY CODE OR IDEA? =
* You can report bugs or contribute code on [this GitHub repo](https://github.com/htdat/woocommerce-for-vietnam). * You can report bugs or contribute code on [this GitHub repo](https://github.com/htdat/woo-viet).
* Please also do let us know if the "bug" is just a grammar/spelling error in both English and Vietnamese. We try to make our products as perfect as possible. * Please also do let us know if the "bug" is just a grammar/spelling error in both English and Vietnamese. We try to make our products as perfect as possible.
== Screenshots == == Screenshots ==
1. The settings page under WooCommerce -> WooCommerce for Vietnam. 1. The settings page under WooCommerce -> Woo Viet.
2. Prices are changed to "K", and the symbol is now "VND". 2. Prices are changed to "K", and the symbol is now "VND".
3. List provinces when selecting Vietnam. 3. List provinces when selecting Vietnam.
4. Let clients know about the currency conversion before switching to the PayPal pages. 4. Let clients know about the currency conversion before switching to the PayPal pages.
== Changelog == == Changelog ==
= 1.1 =
* Replace all “WooCommerce for Vietnam” to “Woo Viet”
* Replace all “woocomerce-fo-vietnam” to “woo-viet”
* Re-upload to WordPress.org
= 1.0 = = 1.0 =
* First release. * First release.
* Upload to WordPress.org
+7 -7
View File
@@ -1,13 +1,13 @@
<?php <?php
/** /**
* Plugin Name: WooCommerce for Vietnam * Plugin Name: Woo Viet
* Plugin URI: https://github.com/htdat/woocommerce-for-vietnam * Plugin URI: https://github.com/htdat/woo-viet
* Description: This plugin provides features and integrations specifically for Vietnam. * Description: This plugin provides features and integrations specifically for Vietnam.
* Author: htdat * Author: htdat
* Author URI: https://profiles.wordpress.org/htdat * Author URI: https://profiles.wordpress.org/htdat
* Text Domain: woocommerce-for-vietnam * Text Domain: woo-viet
* Domain Path: /languages * Domain Path: /languages
* Version: 1.0 * Version: 1.1
* License: GPLv2+ * License: GPLv2+
*/ */
@@ -84,8 +84,8 @@ class WooViet {
public function notice_if_not_woocommerce() { public function notice_if_not_woocommerce() {
$class = 'notice notice-error'; $class = 'notice notice-error';
$message = __( 'WooCommerce for Vietnam is not running because WooCommerce is not active. Please activate both plugins', $message = __( 'Woo Viet is not running because WooCommerce is not active. Please activate both plugins',
'woocommerce-for-vietnam' ); 'woo-viet' );
printf( '<div class="%1$s"><p><strong>%2$s</strong></p></div>', $class, $message ); printf( '<div class="%1$s"><p><strong>%2$s</strong></p></div>', $class, $message );
} }
@@ -165,7 +165,7 @@ class WooViet {
* @return array * @return array
*/ */
static function get_settings() { static function get_settings() {
return get_option( 'woocommerce-for-vietnam', self::$default_settings ); return get_option( 'woo-viet', self::$default_settings );
} }
} }