Consolidate the plugin into the TourWebsite repository (its separate nested git repo has been removed). Includes the full new-design reskin: scoped design stylesheet, SVG icon sprite, rebuilt listing/single/section templates, and homepage hero/FAQ/testimonials shortcodes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J4hNL1PSHxXbu94SCenpKj
11 lines
503 B
PHP
11 lines
503 B
PHP
<?php
|
|
defined( 'ABSPATH' ) || exit;
|
|
$post_id = isset( $post_id ) ? absint( $post_id ) : get_the_ID();
|
|
$rating = get_post_meta( $post_id, '_vc_rating', true );
|
|
$count = absint( get_post_meta( $post_id, '_vc_review_count', true ) );
|
|
if ( '' === $rating && ! $count ) {
|
|
return;
|
|
}
|
|
?>
|
|
<p class="vc-rating"><?php echo esc_html( $rating ); ?><?php if ( $count ) : ?> <span><?php echo esc_html( sprintf( _n( '(%d review)', '(%d reviews)', $count, 'viator-collector' ), $count ) ); ?></span><?php endif; ?></p>
|