WordPress.org

Forums

Relevanssi - A Better Search
[resolved] Blank white page when I search (5 posts)

  1. nstriegel
    Member
    Posted 2 years ago #

    Hey there. This plugin looks to be exactly what we need in our site. However, when it's activated and I search anything, it just opens a blank white page. No errors or anything.

    My theme (u-design) did have the query_posts() call... so I removed it. but no change. I'm also using wp-better-security which has caused problems with other plugins. Wondering if there's something in there that's causing this.

    Any ideas? Here's what's in my search.php file right now:

    <?php
    /**
     * @package WordPress
     * @subpackage U-Design
     */
    
    get_header();
    
    include('scripts/search_excerpt/ylsy_search_excerpt.php');
    
    ?>
    
    <div id="content-container" class="container_24">
        <div id="main-content" class="grid_24">
    	<div class="main-content-padding">
    
    	<?php if (have_posts()) : ?>
    
    		<?php while (have_posts()) : the_post(); ?>
    
    			<div <?php post_class() ?>>
    <?php
    				$title = get_the_title();
    				$search_term = preg_replace('/\/|\+|\*|\[|\]/iu','',$s);
    				$keys= explode(" ",$search_term);
    				$title = preg_replace( '/('.implode('|', $keys) .')/iu', '<strong class="search-excerpt"></strong>', $title );
    ?>
    				<h3 id="post-<?php the_ID(); ?>"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php echo $title; ?></a></h3>
    
    				<?php
    				    $excerpt = new SearchExcerpt();
                                        echo strip_shortcodes( $excerpt->the_excerpt( get_the_excerpt() ) );
    				?>
    			</div>
    
    		<?php endwhile; ?>
    
    		    <div class="clear"></div>
    
    <?php		    // Pagination
    		    if(function_exists('wp_pagenavi')) :
    			wp_pagenavi();
    		    else : ?>
    			<div class="navigation">
    				<div class="alignleft"><?php previous_posts_link() ?></div>
    				<div class="alignright"><?php next_posts_link() ?></div>
    			</div>
    <?php		    endif; ?>
    
    	<?php else : ?>
    		<h2 class="center"><?php esc_html_e("Didn't find what you were looking for? Refine your search!", 'udesign'); ?></h2>
    		<?php get_search_form(); ?>
    
    	<?php endif; ?>
    
    	</div><!-- end main-content-padding -->
        </div><!-- end main-content -->
    </div><!-- end content-container -->
    
    <div class="clear"></div>
    
    <?php
    
    get_footer();

    http://wordpress.org/extend/plugins/relevanssi/

  2. Mikko Saari
    Member
    Plugin Author

    Posted 2 years ago #

    Error logs may contain something useful of what's going on - can you access error logs? This sounds like a some sort of server error.

  3. nstriegel
    Member
    Posted 2 years ago #

    Thanks for the reply Mikko! I'm getting the following error:

    [Thu Dec 20 10:34:52 2012] [error] [client 66.94.196.138] PHP Fatal error: Call to undefined function mb_strtoupper() in /var/www/html/content/plugins/relevanssi/lib/excerpts-highlights.php on line 135, referer: http://www.peoriagov.org/

  4. nstriegel
    Member
    Posted 2 years ago #

    You were correct. I contacted our host provider, and the PHP package did not have multibyte installed. They installed PHP-mbstring and restarted apache and everything's running great.

    Thanks so much for the direction!

  5. Mikko Saari
    Member
    Plugin Author

    Posted 2 years ago #

    Strange, that part of code is behind a check that checks if the multibyte string operations are available. Looks like you have mb_strpos, but not mb_strtoupper... I'll fix that check to more strict to prevent this from happening in the future.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Relevanssi - A Better Search
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.