Support » Plugin: WPCasa » Min and max living area search

  • Resolved designerpart

    (@designerpart)


    hi,

    how can i add a min and max filter for the living area?

    i tried something like this in functions.php but it doesnt filter the listings:

    $fields[‘w_min’] = array(
    ‘label’ => ‘ab Wohnfl├Ąche’,
    ‘key’ => ‘_details_9’,
    ‘type’ => ‘text’,
    ‘query_var’ => ‘details_9’,
    ‘data_compare’ => ‘>=’,
    ‘data_type’ => ‘numeric’,
    ‘class’ => ‘width-1-2’,
    ‘priority’ => 71
    );

    $fields[‘w_max’] = array(
    ‘label’ => ‘bis Wohnfl├Ąche’,
    ‘key’ => ‘_details_9’,
    ‘type’ => ‘text’,
    ‘query_var’ => ‘living_area’,
    ‘data_compare’ => ‘<=’,
    ‘data_type’ => ‘numeric’,
    ‘class’ => ‘width-1-2’,
    ‘priority’ => 72
    );

    can you help me?

    thx

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author WPSight

    (@wpsight)

    Hello,

    you actually were on the right track but it needs a bit more code in order to implement this functionality. Please see here for a full working example.

    Be aware that this most likely will be added in one of the next releases of either WPCasa or WPCasa Advanced Search.

    Let me know if there is anything else I can do for you.

    All the best

    designerpart

    (@designerpart)

    thank you!

    it works for me. yet i know too what was missing in my code.

    best regards

    Plugin Author WPSight

    (@wpsight)

    Great, I’m glad that I could be of some help for you.

    All the best and have a nice day

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Min and max living area search’ is closed to new replies.