Web Hosting
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Receiving "Warning: explode" error

Discussion in 'Troubleshooting & How-To's' started by RichardRice, Mar 18, 2014.

  1. RichardRice

    New Member

    Joined:
    Mar 18, 2014
    Messages:
    2
    Likes Received:
    0
    I'm getting the following error on my site:

    Warning: explode() expects parameter 2 to be string, array given in /home/content/p3nexnas03/06/2064606/html/wp-content/themes/tatsoft/functions.php on line 480

    line 480 reads:

    Code:
    if($break == explode(',',$break))
    The whole of the code reads:

    Code:
    function sub_content($cat_name, $break = array() ) {
    	if( query_posts('posts_per_page=5&orderby=menu_order&order=ASC&post_type=wordblock&wordblock_category='.$cat_name )): // run querys
    		if($break == explode(',',$break)) // sets when to create <div class="clear both"></div> :: default is none
    			$i = 0; // slide count sets
    		?>
    		<div class="entry-sub-content">
    		<?php
    			while(have_posts()) : the_post();
    			$i++ ; // slide count adds
    			$wb = wdblk(get_the_ID()); // grab content
    		?>
    			<div class="slide-content">
    			    <?
    			     $link_title= $wb['title'];
                     $link_title = str_replace('&','and',$link_title);
                     $link_title = str_replace(' ','-',$link_title);
    			    ?>
    				<h2><a href="/services/<?echo strtolower($link_title)?>"><?php echo $wb['title']; ?></a></h2>
    				<?php echo $wb['content']; ?>
    			</div>
    		<?php if(in_array($i,$break))
    				echo '<div class="clear both"></div>';
            
             endwhile; wp_reset_query(); //resets query and end while case?>
    		
    		</div>
    		<?php endif; 
    }
    Can anyone tell me how to fix this, or what I might need to chase down in order to fix?
     
    #1

Share This Page

Web Hosting