Search Documentation

WP Travel Developer Documentation

  1. Home
  2. Docs
  3. WP Travel Developer Documentation
  4. Action Hooks Associated With Singe Itinerary Page
  5. Action : wp_travel_before_main_content

Action : wp_travel_before_main_content

This hook lets you to add the content above the featured image in single trip page. The content are added in a full width container.

Source

File : /templates/archive-itineraries.php

Used by
/templates/archive-itineraries.php
/templates/single-itineraries.php

Example :

function prefix_wp_travel_before_main_content() {
    esc_html_e( 'This is the content added using this hook', 'text-domain' );
}
add_action( 'wp_travel_before_main_content', 'prefix_wp_travel_before_main_content'  );
Was this article helpful to you? Yes No

How can we help?