Adding Custom Fields To ListGo

Adding Custom Fields To ListGo

 

I. Installing Advanced Custom Fields (ACF) plugin

From the admin sidebar, please click on Plugins -> Add New  -> Search for “Advanced Custom Fields” plugin.

II. Adding a new field with ACF

Once this plugin is activated, you will see Custom Fields Menu on your admin bar like this

and click on + Add Field to add your custom field.

 

Now navigate to Listings -> Add New -> You will see “Test” field in this area

 

III. Adding the custom fields to Add Listing page.

  1. From the admin sidebar, please click on Listing Pricings -> Custom Field
  2. Make sure Wiloke Design AddListing is activated.
  3. From the admin sidebar, click on Wiloke Design AddListing -> Dragging Advanced Custom Field to Used Fields area

IV. Printing Custom Field to the Single page

From the admin sidebar, Click on Wiloke Design AddListing -> Single -> Inserting [wilokeAFC id=’my_unique_id’] to the place you want to show custom field content.

For example: If you want show the custom field content under Listing Content:

Or you can also create a new Custom tab like this

*Important:  The id must be unique

Next, go to Appearance -> Themes -> Activating Listgo Child, then accessing your hosting -> wp-folder -> themes -> listgo-child -> Opening functions.php -> and put the below code into this file:

add_action('wiloke-listgo-functionality/print-custom-field/my_custom_field', 'listgoChildPrintCustomFieldContent', 10, 1);

function listgoChildPrintCustomFieldContent($post){
// my content
}

Please pay attention wiloke-listgo-functionality/print-custom-field/my_custom_field: my_custom_field is the  id that you used in wilokeAFC shortcode.

My content: To get your custom fields content, please refer to https://www.advancedcustomfields.com/resources/ -> Field Types.

Warning: If you want to use Upload Field, please upgrade to Advanced Custom Field pro 

NEWSLETTERS

Subscribe to our email list and stay up-to-date with all our awesome releases and latest updates.
MailChimp Icon