• Resolved despina.mina

    (@despinamina)


    Hello,
    It is wrong that if a field remains empty to display zero!
    For ex.if i left empty the field “price” the listing it appears with price zero.There is a way to fix it?

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Barry Kooij

    (@barrykooij)

    Hey,

    You can solve this by overriding the content template part: https://www.wpcarmanager.com/kb/overriding-content-templates/

    Kind Regards,

    Barry Kooij

    Thread Starter despina.mina

    (@despinamina)

    Hello,can you please help me with this?
    I have created a folder named “wp-car-manager” inside my theme and i copied the folder “templates” from plugin.
    With this,nothing changed.If i delete the folder from plugin does not appear at all the plugin inside my site.

    Plugin Author Barry Kooij

    (@barrykooij)

    You only have to copy and modify the files you want to change. I can’t do the actual modifications for you as this is beyond our support scope. If you are unable to do these changes yourself, I recommend hiring a developer.

    Thread Starter despina.mina

    (@despinamina)

    Hello,
    I’m not unable to do these changes,i just want only to know exactly the way to do it.
    This is a malfunction of plugin,isn’t?Is not a custom change out of your support scope.
    So,i just want to fix it,and do not pay a developer!
    Can you please tell me,if after copy templates to theme folder i should delete them from plugin folder?And if then,i should change something?
    Thanks

    WP Car Manager’s templates can be overridden from your theme by copying them to yourtheme/wp-car-manager/, or you can add your own new ones to the same folder. They are then referenced in the shortcodes.

    Example: yourtheme/wp-car-manager/single-vehicle/price.php

    You shouldn’t modify or delete any files from the plugin folder!

    • This reply was modified 6 years, 12 months ago by Patrick.

    Hello despina.mina, follow the instruction to create a override theme, then:

    to remove the price from the single car page edit the page /yourtheme/wp-car-manager/single-vehicle/price.php

    MAKE A BACKUP BEFORE

    find and comment or remove this line:

    <div class="wpcm-price-wrapper" itemprop="offers" itemscope itemtype="https://schema.org/Offer">
    	<span class="wpcm-price"><?php echo $vehicle->get_formatted_price(); ?></span>
    
    	<meta itemprop="price" content="<?php echo $vehicle->get_price(); ?>"/>
    	<meta itemprop="priceCurrency" content="<?php echo wp_car_manager()->service( 'settings' )->get_option( 'currency' ); ?>"/>

    To remove the price from the car listing edit the page /yourtheme/wp-car-manager/listings/item.php

    MAKE A BACKUP BEFORE

    find and comment or remove this line:

    <li class="wpcm-price"><?php echo $price; ?></li>

    Thread Starter despina.mina

    (@despinamina)

    hello,
    i don’t want to remove completely the price,i just want it not to appear “0” if i left empty the field “price” when i add a car.
    So,these instructions are valid?
    Thank you

    Thread Starter despina.mina

    (@despinamina)

    I still wait for your response.i don’t want to remove completely the price,i just want it not to appear “0” if i left empty the field “price” when i add a car.
    Thanks

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Do not display “0”’ is closed to new replies.