• Nicole
    September 14, 2014 at 9:03 am #82860

    Hello Anna! I need to be able to show on the front end of the property list numbers like “4.5”

    For example, over here we use to say that a property has 4.5 rooms (which is essencially 4 rooms and 1 half). I notice that if i put 4.5 it doesn’t show anyting in the front list. There is any way to let the system show the 4.5 ???

    Thanks a lot!

    Anna
    September 15, 2014 at 8:05 am #83559

    Hi Nicole

    Thank you for the message.

    You have to chance the number format in PHP.

    he intval need to be replaced to floatval on the lines you want to use float numbers like 3.5

    You’d have to change in all the locations which can be several and you’d have to do a search first in theme code by property_rooms

    in the end it should look like $property_rooms = floatval ( get_post_meta($post->ID, 'property_rooms', true) );

    Thank you,
    Anna

You must be logged in to reply to this topic.