Directory Shortcodes

Shortcodes are ways to place widgets on pages if you have no widgetized areas to use. Sometimes they let you place content when widgets don’t exist.

Home Page Map

Shortcode:

No Records Found

Sorry, no records were found. Please adjust your search criteria and try again.

Google Map Not Loaded

Sorry, unable to load Google Maps API.

No category

This shortcode is the equivalent of the GD > GMap – Home Page widget.

Parameters:
  • width – A number of pixels or percent (default = 960px)
  • height – A number of pixels (default = 425px)
  • maptype – One of HYBRID, SATELLITE or ROADMAP (default = ROADMAP) – not case sensitive
  • zoom – A number between 1 (narrowest) or 19 (widest) (default = 13)
  • autozoom – True or False (default = false)
  • child_collapse – True or False (default = false)
  • scrollwheel – True or False (default = false)
  • marker_cluster – 1 or on – 0 or off, (default = 0)

Example:

No Records Found

Sorry, no records were found. Please adjust your search criteria and try again.

Google Map Not Loaded

Sorry, unable to load Google Maps API.

No category

Custom Post Type Categories

Shortcode:

This shortcode is the equivalent of the GD > CPT – Categories widget.

Parameters:
  • title – the title for the cpt categories
  • post_type – The custom post types to use (default = shows all) (examples: ‘gd_place’ or ‘gd_place,gd_event’)
  • hide_empty – Hide empty categories? True or False (default = false)
  • show_count – Show category count? True or False (default = false)
  • hide_icon – Hide category icon? True or False (default = false)
  • cpt_left – Show CPT on same line? True or False (default = false)
  • sort_by – Categories sort by. ‘az’ or ‘count’ (default = count)
  • max_count – Maximum number of sub-categories count. (default = shows all)
  • max_level – Maximum level of sub-categories depth. (default = 1)

Example:

Listings Page Map

Shortcode:

No Records Found

Sorry, no records were found. Please adjust your search criteria and try again.

Google Map Not Loaded

Sorry, unable to load Google Maps API.

This shortcode is the equivalent of the GD > GMap – Listing Page widget.

Parameters:
  • width – A number of pixels or percent (default = 294px)
  • height – A number of pixels or percent (default = 370px)
  • zoom – A number between 1 (narrowest) or 19 (widest) (default = 13)
  • autozoom – True or False (default = false)
  • sticky – True or False (default = false)
  • scrollwheel – True or False (default = false)
  • marker_cluster – 1 or on – 0 or off, (default = 0)
  • maptype – One of HYBRID, SATELLITE or ROADMAP (default = ROADMAP) – not case sensitive
  • post_type – The slug for the post_type (default = gd_place)
  • event_type – The events filter (for gd_event CPT only) (default = all)
    Options: all, today, upcoming, past
  • category – ID number of the category to show – if more than one, separate by comma (default = 0 for all)

Example:

No Records Found

Sorry, no records were found. Please adjust your search criteria and try again.

Google Map Not Loaded

Sorry, unable to load Google Maps API.

Listing Slider

Shortcode:

This shortcode is the equivalent of the GD > Listing Slider widget.

Parameters:
  • post_type – The slug for the post_type (default = gd_place)
  • category – ID number of the category to show (default = 0 for all)
  • post_number – Number of posts to show (default = 5)
  • slideshow – True or False (default = false)
  • animation_loop – True or False (default = false)
  • direction_nav – True or False (default = false)
  • slideshow_speed – A positive number of milliseconds (default = 5000)
  • animation_speed – A positive number of milliseconds (default = 600)
  • animation – Either slide or fade (default = slide)
  • order_by – One of az, latest, featured, high_review, high_rating, random (default = latest)
  • show_title – True or False (default = false)(this is the post title over image)
  • show_featured_only – True or False (default = false)
  • title – the title for the title of the slider

Example:

Login Box

Shortcode: My Dashboard

This shortcode is the equivalent of the GD > Login box widget.

No parameters

Example: My Dashboard

Popular Post Category

Shortcode:

This shortcode is the equivalent of the GD > Popular Post Category widget.

Parameters:
  • category_limit – Number of categories to show (default = 15)
  • title – (default = ‘Popular Categories’)

Example:

Popular Post View

Shortcode:

Places

View all
  • No listings found which match your selection.

This shortcode is the equivalent of the GD > Popular Post View widget.

Parameters:
  • post_type – The slug for the post_type (default = gd_place)
  • category – ID number of the category to show (default = 0 for all)
  • post_number – Number of posts to show (default = 5)
  • layout – Number of columns to show (default = 2)
  • add_location_filter – True or False (default = false)
  • list_sort – One of az, latest, featured, high_review, high_rating, random (default = latest)
  • use_viewing_post_type – True or False (default = false)
  • character_count – Number of characters to show from the Excerpt (Min/default = 20)
  • listing_width – A percent between 20 and 100 (default = ‘’)
  • show_featured_only – True or False (default = false)
  • show_special_only – True or False (default = false)
  • with_pics_only – True or False (default = false)
  • with_videos_only – True or False (default = false)
  • title – (default = ‘the name of the custom post type’)

Example:

Places

View all
  • No listings found which match your selection.

Recent Reviews

Shortcode:

This shortcode is the equivalent of the GD > Recent Reviews widget.

Parameters:
  • count – Number of posts to show (default = 5)

Example: 

Related Listings

Shortcode:

This shortcodes is the equivalent of the GD > Related Listings widget.

Parameters:
  • post_number – Number of posts to show (default = 5)
  • relate_to – Either category or tags (default=category)
  • layout – Number of columns to show (default = 2)
  • add_location_filter – True or False (default = false)
  • listing_width – A percent between 20 and 100 (default = ‘’)
  • list_sort – One of az, latest, featured, high_review, high_rating, random (default = latest)
  • character_count – Number of characters to show from the Excerpt (Min/default = 20)

Example: 

Search

Shortcode:

This shortcode is the equivalent of the GD > Search widget.

No parameters unless Advanced Search addon is active:

  • show_adv_search – If the advanced search section should be shown: (‘default’, ‘always’, ‘searched’)

Example:

GD Listings

Shortcode:
  • No listings found which match your selection.

This shortcode is almost the equivalent of what you see on the GD category listings pages.

Parameters:
  • post_number – Number of posts to show per page (default = 10)
  • post_type – The custom post type to use (default=gd_place)
  • layout – Number of columns to show (default = 2)
  • category – The category ids “1,3” (default = ”)
  • listing_width – A percent between 20 and 100 (default = ‘’)
  • list_sort – One of az, latest, featured, high_review, high_rating, random (default = latest)
  • character_count – Number of characters to show from the Excerpt (Min/default = 20)
  • post_author – Filter by current_user, current_author or ID (default = unfiltered)
    • post_author=”current_user” will filter the listings by author id of the logged in user
    • post_author=”current_author” will filter the listings by author id of current viewing post/listing
    • post_author=”11″ will filter the listings by author id = 11
  • tags – Filter by tags (default = unfiltered), for example tags=”Museum,Garden”
  • add_location_filter – True or False (default = true)
  • show_favorites_only – options are 1 [true] or 0 [false] (default = 0)
  • favorites_by_user – Values should be “current”‘ or user id [eg 5] or empty (default = empty)
    • favorites_by_user=”current”, shortcode will show the listings which are favorites by author of current viewing post.
    • favorites_by_user=”12″, shortcode will show the listings which are favorites by user id “12”.
    • favorites_by_user=”” or empty, shortcode will show the listings which are favorites by current logged user(if logged in).

Example:

  • No listings found which match your selection.
  • No listings found which match your selection.

GD Best of

Shortcode:

Best of Our-Hometown

  • No listings found which match your selection.

Parameters:

      • title – widget title (default = ”)
      • post_type – The custom post type to use (default=gd_place)
      • post_limit – Number of posts to show (default = 5)
      • categ_limit – The number of category to show (default = 3)
      • character_count – Number of characters to show from the Excerpt (Min/default = 20)
      • use_viewing_post_type – overridess parameter post_type if visiting another custom port type archive (default = false)
      • add_location_filter – True or False (default = false)
      • tab_layout – bestof-tabs-on-top or bestof-tabs-on-left or bestof-tabs-as-dropdown (default = bestof-tabs-on-top)

Example:

widget title

  • No listings found which match your selection.

 

Add Listing Form

Shortcode: You must login to post.

  1. This shortcode allows you to create your own Add Listing page(s).
  2. By default GD uses the same Add Listing page to generate different forms for all different Custom Post Typesand/or price packages.  For example:
    1. https://yoursite.com/add-listing/?listing_type=gd_place&package_id=1
    2. https://yoursite.com/add-listing/?listing_type=gd_event&package_id=6
  3. Do not add this shortcode to the Add Listing page selected at GD > Permalinks > GeoDirectory Pages > Add Listing page.
    That page is reserved for GD generated pages, so only add this shortcode to any extra WP pages.
  4. After you have created all your custom Add Listing pages, you might have to permanently delete the temporary default Add Listing page that is selected at GD > Permalinks > GeoDirectory Pages > Add Listing pagebefore your custom Add Listing pages will work.
Parameters:
  • listing_type – The custom post type to use (default=gd_place)
  • login_msg – The message to show to logged out users (default = You must login to post.)
  • show_login – show the login widget to logged out users (default = false)

Example: Please register and login to submit listings
My Dashboard