Organise bike touring content by tour dates.
Please read DTRT WordPress Plugin Boilerplate: Workflows.
Please prefix the WordPress block in your .htaccess file with the following:
# wpdtrt-tourdates content partials
RewriteEngine On
RewriteRule "^(content-)+.*" "/" [L,R=301]
Please read the WordPress readme.txt.
wpdtrt_tourdates_taxonomy_tour
- Options (Term type):
region(e.g. Asia)tour(e.g. East Asia (2015))tour_leg(e.g. Japan)
start_date(e.g. 2015-09-02)end_date(e.g. 2016-06-25)first_visit(iftour_leg- Used in country traversal counts)leg_count(iftour_leg- Used in country traversal counts)thumbnail_id(iftour)content_id(Inserts the content page with this ID below the description on the tour page)disabled(iftour_leg- Disables terms which have no posts yet)
When a post is assigned to the tour and its publish date is within the Date Range:
- display Current/Elapsed Day on day maps and in daily statistics (e.g.
#32). - display Relative Duration on a post (e.g.
32%).
Note: Day number is relative to the Total Duration, not the published duration. This prevents mangling of the stats when content is being published retrospectively.
Usage:
- Shortcode:
[wpdtrt_tourdates_shortcode_daynumber] - Template Tag:
echo do_shortcode( '[wpdtrt_tourdates_shortcode_daynumber]' );
The public function is used when generating links and titles:
$wpdtrt_tourdates_plugin->get_post_daynumber()
When a post is assigned to the tour and its publish date is within the Date Range:
- display Total Duration in daily statistics (e.g.
100) - display Relative Duration on a post (in conjunction with Day Number) (e.g.
32%)
Usage:
- Shortcode:
[wpdtrt_tourdates_shortcode_daytotal] - Template Tag:
echo do_shortcode( '[wpdtrt_tourdates_shortcode_daytotal]' );
Navigate previous/next post via arrow icons.
- Shortcode:
[wpdtrt_tourdates_shortcode_navigation posttype="tourdiaries" taxonomy="tours"] - Template Tag:
echo do_shortcode( '[wpdtrt_tourdates_shortcode_navigation posttype="tourdiaries" taxonomy="tours"]' );
Display Relative Date Duration on a sub-category in a hierarchical archive page (Tour taxonomy) (e.g. January to February 2017)
The public function is used when generating tour summaries:
$wpdtrt_tourdates_plugin->get_term_start_month()$wpdtrt_tourdates_plugin->get_term_end_month()
- Shortcode:
[wpdtrt_tourdates_shortcode_summary] - Template Tag:
echo do_shortcode( '[wpdtrt_tourdates_shortcode_summary]' );
The public function is used on sitemaps and tour landing pages:
$wpdtrt_tourdates_plugin->helper_order_tour_terms_by_date()
Not used.
$wpdtrt_tourdates_plugin->helper_order_tour_terms_by_hierarchy()
$wpdtrt_tourdates_plugin->get_meta_term_type()
Display a custom CSS background image on region, tour and tour_leg landing pages.
- Shortcode:
[wpdtrt_tourdates_shortcode_thumbnail] - Template Tag:
echo do_shortcode( '[wpdtrt_tourdates_shortcode_thumbnail]' );
The public function is used to get the custom image ID in order to generate different sizes:
$wpdtrt_tourdates_plugin->get_meta_thumbnail_id()
The public function is used to determine whether the tour should be shown as active or disabled:
$wpdtrt_tourdates_plugin->get_meta_term_disabled()
Display Relative Day Duration on a sub-category in a hierarchical archive page (e.g. tour_leg) (e.g. Days #1-#32)
- Shortcode:
[wpdtrt_tourdates_shortcode_tourlengthdays] - Template Tag:
echo do_shortcode( '[wpdtrt_tourdates_shortcode_tourlengthdays]' );
Core CSS properties may be overwritten by changing the variable values in your theme stylesheet.
See scss/variables/_css.scss.
