Move price below short description in Woocommerce single products [closed] Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern) Data science time! April 2019 and salary with experience The Ask Question Wizard is Live!WooCommerce - Replace Price with Variable Price on Single Product PageRemove Woocommerce Product Short Descriptionwoocommerce product excerpt description (short)limit woocommerce product short description in home page and category pageAdd content above the product short description on the product page in WooCommerceMove woocommerce category description below productsWoocommerce: Display Product Variation Description on shop catalog pageMove Add To Cart button and Variation Selector above product short description in WoocommerceSingle product category description using shortcodes in Woocommercewoocommerce variable product price not showing in shop page
What does Turing mean by this statement?
Caught masturbating at work
How were pictures turned from film to a big picture in a picture frame before digital scanning?
Tips to organize LaTeX presentations for a semester
Flight departed from the gate 5 min before scheduled departure time. Refund options
what is the log of the PDF for a Normal Distribution?
What does it mean that physics no longer uses mechanical models to describe phenomena?
Why are vacuum tubes still used in amateur radios?
I can't produce songs
What does the writing on Poe's helmet say?
Sally's older brother
Can an iPhone 7 be made to function as a NFC Tag?
Resize vertical bars (absolute-value symbols)
Co-worker has annoying ringtone
Does silver oxide react with hydrogen sulfide?
Why is std::move not [[nodiscard]] in C++20?
Monty Hall Problem-Probability Paradox
i2c bus hangs in master RPi access to MSP430G uC ~1 in 1000 accesses
If Windows 7 doesn't support WSL, then what is "Subsystem for UNIX-based Applications"?
malloc in main() or malloc in another function: allocating memory for a struct and its members
Is there public access to the Meteor Crater in Arizona?
Moving a wrapfig vertically to encroach partially on a subsection title
Delete free apps from library
AppleTVs create a chatty alternate WiFi network
Move price below short description in Woocommerce single products [closed]
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 23, 2019 at 23:30 UTC (7:30pm US/Eastern)
Data science time! April 2019 and salary with experience
The Ask Question Wizard is Live!WooCommerce - Replace Price with Variable Price on Single Product PageRemove Woocommerce Product Short Descriptionwoocommerce product excerpt description (short)limit woocommerce product short description in home page and category pageAdd content above the product short description on the product page in WooCommerceMove woocommerce category description below productsWoocommerce: Display Product Variation Description on shop catalog pageMove Add To Cart button and Variation Selector above product short description in WoocommerceSingle product category description using shortcodes in Woocommercewoocommerce variable product price not showing in shop page
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
I am using Woocommerce for a small online shop and using Movedo Wordpress theme by greatives.
I am trying to move the product price below short description in single product pages. I inserted the code in functions.php
file of my child theme:
remove_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 4 );
add_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 29 );
But it ends up displaying the price twice: single product page.
What I am doing wrong? Any help is appreciated.
php wordpress woocommerce product hook-woocommerce
closed as too broad by ochi, thewaywewere, DebanjanB, greg-449, Billal Begueradj Mar 9 at 19:06
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
add a comment |
I am using Woocommerce for a small online shop and using Movedo Wordpress theme by greatives.
I am trying to move the product price below short description in single product pages. I inserted the code in functions.php
file of my child theme:
remove_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 4 );
add_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 29 );
But it ends up displaying the price twice: single product page.
What I am doing wrong? Any help is appreciated.
php wordpress woocommerce product hook-woocommerce
closed as too broad by ochi, thewaywewere, DebanjanB, greg-449, Billal Begueradj Mar 9 at 19:06
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
To review and moderators: This question is not too broad, and the question provide some code. My answer took me 1mn… Please consider reopening the thread.
– LoicTheAztec
Mar 16 at 0:15
add a comment |
I am using Woocommerce for a small online shop and using Movedo Wordpress theme by greatives.
I am trying to move the product price below short description in single product pages. I inserted the code in functions.php
file of my child theme:
remove_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 4 );
add_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 29 );
But it ends up displaying the price twice: single product page.
What I am doing wrong? Any help is appreciated.
php wordpress woocommerce product hook-woocommerce
I am using Woocommerce for a small online shop and using Movedo Wordpress theme by greatives.
I am trying to move the product price below short description in single product pages. I inserted the code in functions.php
file of my child theme:
remove_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 4 );
add_action('woocommerce_single_product_summary',
'woocommerce_template_single_price', 29 );
But it ends up displaying the price twice: single product page.
What I am doing wrong? Any help is appreciated.
php wordpress woocommerce product hook-woocommerce
php wordpress woocommerce product hook-woocommerce
edited Mar 10 at 20:20
LoicTheAztec
98.4k1472114
98.4k1472114
asked Mar 8 at 23:24
Sayed totomobilSayed totomobil
114
114
closed as too broad by ochi, thewaywewere, DebanjanB, greg-449, Billal Begueradj Mar 9 at 19:06
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
closed as too broad by ochi, thewaywewere, DebanjanB, greg-449, Billal Begueradj Mar 9 at 19:06
Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. Avoid asking multiple distinct questions at once. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.
To review and moderators: This question is not too broad, and the question provide some code. My answer took me 1mn… Please consider reopening the thread.
– LoicTheAztec
Mar 16 at 0:15
add a comment |
To review and moderators: This question is not too broad, and the question provide some code. My answer took me 1mn… Please consider reopening the thread.
– LoicTheAztec
Mar 16 at 0:15
To review and moderators: This question is not too broad, and the question provide some code. My answer took me 1mn… Please consider reopening the thread.
– LoicTheAztec
Mar 16 at 0:15
To review and moderators: This question is not too broad, and the question provide some code. My answer took me 1mn… Please consider reopening the thread.
– LoicTheAztec
Mar 16 at 0:15
add a comment |
1 Answer
1
active
oldest
votes
You are not targeting the right hook priority when using remove_action()
… Try this instead:
add_action('woocommerce_single_product_summary', 'move_single_product_price', 1);
function move_single_product_price()
remove_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 10);
add_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 29);
It should only display one price only in the new desired location.
Code goes in function.php file of your active child theme (or active theme).
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
|
show 4 more comments
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
You are not targeting the right hook priority when using remove_action()
… Try this instead:
add_action('woocommerce_single_product_summary', 'move_single_product_price', 1);
function move_single_product_price()
remove_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 10);
add_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 29);
It should only display one price only in the new desired location.
Code goes in function.php file of your active child theme (or active theme).
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
|
show 4 more comments
You are not targeting the right hook priority when using remove_action()
… Try this instead:
add_action('woocommerce_single_product_summary', 'move_single_product_price', 1);
function move_single_product_price()
remove_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 10);
add_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 29);
It should only display one price only in the new desired location.
Code goes in function.php file of your active child theme (or active theme).
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
|
show 4 more comments
You are not targeting the right hook priority when using remove_action()
… Try this instead:
add_action('woocommerce_single_product_summary', 'move_single_product_price', 1);
function move_single_product_price()
remove_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 10);
add_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 29);
It should only display one price only in the new desired location.
Code goes in function.php file of your active child theme (or active theme).
You are not targeting the right hook priority when using remove_action()
… Try this instead:
add_action('woocommerce_single_product_summary', 'move_single_product_price', 1);
function move_single_product_price()
remove_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 10);
add_action('woocommerce_single_product_summary', 'woocommerce_template_single_price', 29);
It should only display one price only in the new desired location.
Code goes in function.php file of your active child theme (or active theme).
edited Mar 9 at 10:57
answered Mar 9 at 8:35
LoicTheAztecLoicTheAztec
98.4k1472114
98.4k1472114
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
|
show 4 more comments
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
Hi @LoicTheAztec Thank you for your reply. I replaced my code by yours. alas it does not change anything. I appreciate your intention to help me.
– Sayed totomobil
Mar 9 at 9:12
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
As I have the same value for (..hooked woocommerce_template_single_rating - 10) (..hooked woocommerce_template_single_price - 10) I wondered if it create a conflict single_rating/single_price. But No.
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
Can it come from a modification in the parent theme by the theme editor? Or can an entry in the database not reset?
– Sayed totomobil
Mar 9 at 9:14
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I added the code above. it does not work. I always have twice the price, one up and the other down. Thank you @LoicTheAztec for your time.
– Sayed totomobil
Mar 9 at 10:23
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
I confirm: the text appears on the pages of my site. I misunderstood. I thinked this text will replace the price.. The text du test : appears
– Sayed totomobil
Mar 9 at 12:45
|
show 4 more comments
To review and moderators: This question is not too broad, and the question provide some code. My answer took me 1mn… Please consider reopening the thread.
– LoicTheAztec
Mar 16 at 0:15