// Add custom Theme Functions here
//CODE LAY LUOT XEM
function getPostViews($postID){
$count_key = 'post_views_count';
$count = get_post_meta($postID, $count_key, true);
if($count==''){
delete_post_meta($postID, $count_key);
add_post_meta($postID, $count_key, '0');
return "01 lượt xem";
}
return $count.' lượt xem';
}
// CODE DEM LUOT XEM
function setPostViews($postID) {
$count_key = 'post_views_count';
$count = get_post_meta($postID, $count_key, true);
if($count==''){
$count = 0;
delete_post_meta($postID, $count_key);
add_post_meta($postID, $count_key, '0');
}else{
$count++;
update_post_meta($postID, $count_key, $count);
}
}
//CODE HIEN THI SO LUOT XEM BAI VIET TRONG DASHBOARDH
add_filter('manage_posts_columns', 'posts_column_views');
add_action('manage_posts_custom_column', 'posts_custom_column_views',5,2);
function posts_column_views($defaults){
$defaults['post_views'] = __('Views');
return $defaults;
}
function posts_custom_column_views($column_name, $id){
if($column_name === 'post_views'){
echo getPostViews(get_the_ID());
}
}
/*Sắp xếp lại thứ tự các field*/
add_filter("woocommerce_checkout_fields", "order_fields");
function order_fields($fields) {
//Shipping
$order_shipping = array(
"shipping_last_name",
"shipping_phone",
"shipping_address_1"
);
foreach($order_shipping as $field_shipping)
{
$ordered_fields2[$field_shipping] = $fields["shipping"][$field_shipping];
}
$fields["shipping"] = $ordered_fields2;
return $fields;
}
add_filter( 'woocommerce_checkout_fields' , 'custom_override_checkout_fields',99 );
function custom_override_checkout_fields( $fields ) {
unset($fields['billing']['billing_company']);
unset($fields['billing']['billing_first_name']);
unset($fields['billing']['billing_postcode']);
unset($fields['billing']['billing_country']);
unset($fields['billing']['billing_city']);
unset($fields['billing']['billing_state']);
unset($fields['billing']['billing_address_2']);
$fields['billing']['billing_last_name'] = array(
'label' => __('Họ và tên', 'devvn'),
'placeholder' => _x('Nhập đầy đủ họ và tên của bạn', 'placeholder', 'devvn'),
'required' => true,
'class' => array('form-row-wide'),
'clear' => true
);
$fields['billing']['billing_address_1']['placeholder'] = 'Ví dụ: Số xx Ngõ xx Phú Kiều, Bắc Từ Liêm, Hà Nội';
unset($fields['shipping']['shipping_company']);
unset($fields['shipping']['shipping_postcode']);
unset($fields['shipping']['shipping_country']);
unset($fields['shipping']['shipping_city']);
unset($fields['shipping']['shipping_state']);
unset($fields['shipping']['shipping_address_2']);
$fields['shipping']['shipping_phone'] = array(
'label' => __('Điện thoại', 'devvn'),
'placeholder' => _x('Số điện thoại người nhận hàng', 'placeholder', 'devvn'),
'required' => true,
'class' => array('form-row-wide'),
'clear' => true
);
$fields['shipping']['shipping_last_name'] = array(
'label' => __('Họ và tên', 'devvn'),
'placeholder' => _x('Nhập đầy đủ họ và tên của người nhận', 'placeholder', 'devvn'),
'required' => true,
'class' => array('form-row-wide'),
'clear' => true
);
$fields['shipping']['shipping_address_1']['placeholder'] = 'Ví dụ: Số xx Ngõ xx Phú Kiều, Bắc Từ Liêm, Hà Nội';
return $fields;
}
add_action( 'woocommerce_admin_order_data_after_shipping_address', 'my_custom_checkout_field_display_admin_order_meta', 10, 1 );
function my_custom_checkout_field_display_admin_order_meta($order){
echo '
'.__('Số ĐT người nhận').': ' . get_post_meta( $order->get_id(), '_shipping_phone', true ) . '
';
}
Bia Heineken - 24 lon 300ml - Nước khoáng
Skip to content
Bia Heineken – 24 lon 300ml
Home - Sản phẩm - Bia - Bia Heineken – 24 lon 300ml
“Cây nước nóng lạnh Daiwa YDG2-5BB-A” đã được thêm vào giỏ hàng.
Xem giỏ hàng
Bia Heineken – 24 lon 300ml
Heineken là thương hiệu bia được thành lập năm 1864 tại Hà Lan, có lịch sử lâu đời, nổi tiếng và có vị thế trong thị trường bia thế giới. Heineken đã trải qua quá trình dài để phát triển, đáp ứng nhu cầu của người tiêu dùng và đạt được những thành tựu đáng tự hào. Hiện nay, Heineken đang được ưa chuộng tại hơn 192 quốc gia trên thế giới.
Rudolph Hayoz –
Merely a smiling visitor here to share the love (:, btw great style.
https://www.zoritolerimol.com
miminwd login –
Some times its a pain in the ass to read what blog owners wrote but this site is very user genial! .
https://miminwd.it.com/
CooMeet –
I simply could not depart your site prior to suggesting that I really loved the usual information a person supply on your guests? Is going to be again frequently in order to check up on new posts.
https://vibragame.biz/th/
login cakra111 –
I would like to thank you for the efforts you’ve put in writing this web site. I’m hoping the same high-grade web site post from you in the upcoming as well. Actually your creative writing abilities has inspired me to get my own web site now. Actually the blogging is spreading its wings quickly. Your write up is a good example of it.
https://cakra111.com/
mim parts –
You are my aspiration, I possess few web logs and sometimes run out from to brand : (.
https://mikeshoppingroom.com/product-category/mim-parts/
bandar99 slot –
Hey! I’m at work surfing around your blog from my new iphone 4! Just wanted to say I love reading through your blog and look forward to all your posts! Keep up the excellent work!
https://bandar99.it.com/
pengacara perceeaian jakarta utara –
I believe you have remarked some very interesting points, appreciate it for the post.
https://www.legalkeluarga.id/
Ethical hacking laws and regulations –
There are some interesting points in time in this article however I don’t know if I see all of them heart to heart. There may be some validity but I’ll take hold opinion until I look into it further. Good article , thanks and we wish more! Added to FeedBurner as nicely
https://thenoblehackers.com/
Penetration testing and ethical hackers –
Great weblog right here! Also your web site rather a lot up very fast! What web host are you the use of? Can I am getting your affiliate link on your host? I want my web site loaded up as quickly as yours lol
https://thenoblehackers.com/