1. Docs
  2. Add Ons
  3. Frontend Property Submissions

Frontend Property Submissions

The Frontend Property Submissions add on allows agents, vendors or landlords to upload their own property stock through the frontend of your website.

The Shortcodes

There are two main shortcodes available when using this add on:

[propertyhive_submit_property_form]

Displays the form allowing users to upload the property details.

[propertyhive_submitted_properties]

If you require people be logged in when adding properties, this shortcode displays a list of properties they’ve previously uploaded so they can modify them, take them off of the market etc.

Settings

The settings for the add on can be accessed by navigating to ‘Property Hive > Settings > Frontend Submissions‘.

The settings available on this page are as follows:

User must be logged in?
Check this setting if users must have an account and be logged in before being able to add properties. If not selected then anybody can add properties. A login form can be displayed by using the shortcode [propertyhive_login_form].

Login URL
If users must be logged in (see above setting) but they try to add a property they’ll be shown a link to login instead. This field should contain a link to the URL where they can login.

Register URL
If users must be logged in (see above setting) but they try to add a property they’ll be shown a link to regsiter instead. This field should contain a link to the URL where they can register.

When properties are added…
You can use this setting if you’d prefer to moderate properties before they go live. If this is the case, properties will appear in the WordPress and be flagged as ‘Awaiting Moderation’:

Alternatively you can set it so properties go live automatically as soon as they’re added.

Allow Editing of Properties?
Should a user be able to edit properties that they’ve added. If enabled, an ‘Edit’ link will be displayed when outputting properties using the [propertyhive_submitted_properties] shortcode.

Edit Property URL
If you’re allowing users to edit properties this should contain a URL to the page which allows them to edit their property. The page in question should contain the [propertyhive_submit_property_form] shortcode.

Overriding The Submit Property Form Template

The form that people complete when submitting their property is an editable template which can be overridden should you wish to change the layout or HTML. Overriding the template means you won’t lose your changes should you perform an update to the add on in the future.

To do so simply copy:

/wp-content/plugins/propertyhive-frontend-property-submissions/templates/submit-property-form.php

to:

/wp-content/themes/{your-theme-name}/propertyhive/submit-property-form.php

.. and make the changes required.

Developer Hooks

There are a number of filters available allowing the fields to be modified in each section. These are as follows:

propertyhive_submit_property_address_form_fields
propertyhive_submit_property_details_form_fields
propertyhive_submit_property_residential_sales_details_form_fields
propertyhive_submit_property_residential_lettings_details_form_fields
propertyhive_submit_property_residential_details_form_fields

Each of the above is passed a single parameter $fields and could be used like so. The below is adding an additional field called ‘Directions’:

add_filter( 'propertyhive_submit_property_address_form_fields', 'my_function', 10, 1 );
function my_function( $fields )
{
    $fields['directions'] = array(
        'type' => 'textarea',
        'show_label' => true, 
        'label' => 'Directions'
    );

    return $fields;
}

FAQs

Is there any payment integration?

No. Not at the moment at least. We have seen people add their own payment integration however, for example (http://www.esaleuk.com/). NB: We did not build that site so can offer no advice about how they achieved it or the steps involved. Our advice at the moment would be to use WooCommerce to handle the product display and payment, then once the checkout is complete, send them a link (either manually or automate it) to the page where they can submit their properties and that contains the [propertyhive_submit_property_form] shortcode.

Was this article helpful to you? Yes No