N
N
noni71rus2016-04-04 14:08:40
CMS
noni71rus, 2016-04-04 14:08:40

How to display product price in page title in woocommerce?

It is important to display the price of the product in the site title or description. Maybe someone knows how to implement. Worth Yoast SEO, how can you use it?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Dmitry, 2016-04-04
@Designult

Tweak woocommerce php files. Whatever single-product.php In it, find the function that is responsible for displaying the price. And paste it into a tag in your theme template.
Rather, it would be wiser not to kill the function that is already written in, but simply add one more function. So that the page name is not just with the price, but with an example: Men's shoes - 8,900 rubles.

A
Andrey Kolodiy, 2017-04-28
@Rozumno

Use this code:
<?php echo $product->get_price_html(); ?>

V
Valera, 2018-11-22
@GrifasOfficial

Hello. Have you resolved the issue? Also faced this problem.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question