• Hello Dear,
    first A lot of Thanks and HUG for great
    theme.
    i just want to use your theme for my product.
    I’m ok with all features of this. but i just
    need to show product price of every pictures
    of product.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi Hemeljon,

    Can you send us a link to your project – that will help understand your request. Are you talking about adding prices to you can sell things (e-commerce)? One option is to use the caption on images or simply edit the image with the pricing before you upload… But generally if you want to overlay a price that comes from your database, this will take some custom coding.

    Thread Starter hemeljon

    (@hemeljon)

    Hello frasermarlow,
    Thanks For Reply,

    It’s not an e-commerce project. I just need like that. Demo Link>>
    https://www.mobiledokan.com/nokia/

    or it possible to show/write price, where comments icon show upper corner of images?

    Hi hemeljon.

    So my guess is that you want to use the Hueman theme to set up a merchandising website which shows lots of products, and your plan is to use one post for each product.
    When you do that you can set a ‘Featured image’ for each post/product. You goal is to show the price of the product on the image in the category pages, correct?

    When you upload an image to WordPress there are four pieces of Metadata you can add with the image:
    1) Title
    2) Alt-Text
    3) Caption (by default appears on the image in large white letters on the post page)
    4) Description ( by default appears on the image in smaller text in the post page)

    Now, by default the CATEGORY pages do not display any of this information. even the ‘Alt-Text’ is swapped out for the post title.

    The only item overlaid on the image in Category pages is the number of comments. This is handled in code lines 15 to 17 in the file content.php (and I recommend using a child theme before you go and modify).

    So one option is to use one of the 4 image metadata fields listed above to store the price… this might be a weird shortcut, but would work.

    Either way what you are looking to do is not supported out of the box and will take a bit of PHP work, but nothing that can’t be managed with child-theme files.

    I hope this helps point you in the right direction.

    PS: if you are looking for the calls that display the caption and description they are found in the folder ‘inc’ in the file page-image.php and read:

    <?php
    $caption = get_post(get_post_thumbnail_id())->post_excerpt;
    $description = get_post(get_post_thumbnail_id())->post_content;
    echo ‘<div class=”page-image-text”>’;
    if ( isset($caption) && $caption ) echo ‘<div class=”caption”>’.$caption.'</div>’;
    if ( isset($description) && $description ) echo ‘<div class=”description”><i>’.$description.'</i></div>’;
    echo ‘</div>’;
    ?>

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Alex pls Help me on it :(’ is closed to new replies.