Place the reviews and buttons anywhere – secret solution
-
By default,every time you give reviews you get forms and all the reviews below the review button.By implementing this you can place the button and form anywhere and reviews too.In nutshell,both reviews form and reviews are independent now
Step1
open wp-customer-reviews.php file
step2
find this codeadd_shortcode( 'WPCR_SHOW', array(&$this, 'shortcode_wpcr_show') ); insert following code after the above line add_shortcode( 'WPCR_SHOW_ATC', array(&$this, 'shortcode_wpcr_show_atc') );
step3
just find following codefunction shortcode_wpcr_insert() {
step4
inserrt the below code just before the step3 function. function shortcode_wpcr_show_atc() { $this->force_active_page = 1; $is_active_page = $this->is_active_page(); global $post; $the_content=''; //$inside_div = true; // $this->force_active_page = 1; // return $this->do_the_content('shortcode_insert'); //echo "anil".$post->ID; //echo $inside_div; //echo $this->options['reviews_per_page']; $ret_Arr = $this->output_reviews_show( $inside_div, $post->ID, $this->options['reviews_per_page'], -1 ); //print_r($ret_Arr); $the_content .= $ret_Arr[0]; $total_reviews = $ret_Arr[1]; $the_content .= $this->pagination($total_reviews, $this->options['reviews_per_page']); return $the_content; }
step5
find this function
function do_the_content($original_content) {
and just comment out following code
/* $ret_Arr = $this->output_reviews_show( $inside_div, $post->ID, $this->options['reviews_per_page'], -1 ); $the_content .= $ret_Arr[0]; $total_reviews = $ret_Arr[1]; $the_content .= $this->pagination($total_reviews, $this->options['reviews_per_page']); */
thats all
Now you will get only reviews button and form on that page,you can display the customer reviews in any page by using the following short code in page/post
[WPCR_SHOW_ATC]
If you need any help post here or mail me [ redacted support is offered via the forums and not email ]
https://www.ads-software.com/extend/plugins/wp-customer-reviews/
- The topic ‘Place the reviews and buttons anywhere – secret solution’ is closed to new replies.