WordPress.org

Ready to get started?Download WordPress

Forums

IProperty Real Estate Agent
[resolved] Fractional baths not agreeing to 'no' setting! (8 posts)

  1. CarolVerity
    Member
    Posted 1 year ago #

    Hi there, despite setting the fractional baths to 'no' it is still displaying as 2.00 for example... Please could you advise?

    thank you

    http://wordpress.org/plugins/intellectual-property-basic/

  2. thinkeryllc
    Member
    Plugin Author

    Posted 1 year ago #

    Hi - setting the fractional baths to 'no' will prevent the fractions from showing in the baths select drop down, but the value is still stored with a decimal point in the db.

    To fix the front end display if you have fractional baths disabled, you can edit your 'iproperty/views/_compact_property.php' file and find:

    <?php echo esc_html( $value ); ?>

    and change it to:

    <?php echo ($name == 'baths' && !iproperty_option( 'fractional_baths' )) ? round($value) : esc_html( $value ); ?>

    Let us know any questions. Thanks.

  3. CarolVerity
    Member
    Posted 1 year ago #

    Thank you - that worked perfectly on the general listing page... however... this doesn't fix the fraction on the single property page :-( Where do I do this please?

    Thank you
    Carol

  4. thinkeryllc
    Member
    Plugin Author

    Posted 1 year ago #

    Ok, glad it worked. For the details view, open your 'iproperty/views/single_property.php' and 'iproperty/views/single_property/main_tabs/_details.php' files and find:

    <?php echo ( $value ); ?>

    change it to:

    <?php echo ($name == 'baths' && !iproperty_option( 'fractional_baths' )) ? round($value) : ( $value ); ?>

    Let us know questions. Thanks!

  5. CarolVerity
    Member
    Posted 1 year ago #

    Hmmm that hasn't worked :-(

  6. CarolVerity
    Member
    Posted 1 year ago #

    Forget that... it has worked... didn't do it in both files... so now have and that's perfect! Thank you so much :-)

  7. thinkeryllc
    Member
    Plugin Author

    Posted 1 year ago #

    You're welcome! Please don't forget rate the product when you are satisfied!

  8. Fraser Martin
    Member
    Posted 10 months ago #

    Same changes required in the file:

    /wp-content/plugins/intellectual-property-basic/views/single_property.php

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.