Support

Account

Home Forums ACF PRO error 'multisite' => 1 don't work

Helping

error 'multisite' => 1 don't work

  • Hi guys,

    Since the last update, the line ” multisite’ => 1,” don’t work.
    I need to delete this, to show my diferrent new on my page but i have only main site news.

    Could you have a idea, how i can fix that ?

    Thanks

    <?php Starkers_Utilities::get_template_parts( array( 'parts/banner') ); 
    $sites = get_sites();
    $site_number = count($sites);
    $site_count;
    $today = date('Y-m-d');
    $support_button = get_field('support_button');
    
    for ($i=0; $i <= $site_number; $i++) { 
    	$site_count[] = $i;
    } 
    $args = array(
    	/**'multisite' => 1,**/
        'posts_per_page' => -1,
        'orderby' => 'date',
    	'order'   => 'DESC',
        'sites' => $site_count
    );
    
    $query = new WP_Query( $args );
    ?>
    
    <main id="barba-wrapper" class="page-actus" role="main">
    	<div class="barba-container">
    	<section class="news news-page container">
    	<h1 class="section-title">Actualit├ęs</h1>
    	<ul class="blog-post_list">
    		<?php
    		while( $query->have_posts() ) : $query->the_post();
    			if(!empty(get_field('news_description'))):
    				$result_txt = get_field('news_description');
    			else:
    				$result_descr = get_field('sections_articles');
    				$result_txt = wp_trim_words($result_descr[0]['contenu_texte'], 18,);
    			endif;
    			$thumb = get_field('news_illu');
    			$size = 'news_size';
    		?>
    		<li class="blog-post card">
    	        <a title="Lire l'article - <?php the_title(); ?>" href="<?php the_permalink(); ?>">
    	           <?php echo wp_get_attachment_image( $thumb, $size, "", array( "class" => "img-responsive" ) );?>
    	            <div class="actu-info" style="min-height: 35.8px;">
    	                <h2><?php the_title(); ?></h2>
    	                <p><?php= $result_txt ?></p>               
    	            </div>
    			</a>
    		</li>
    <?php
    
    endwhile; 
    ?>
    	</ul>
    <?php
    wp_reset_postdata();
     ?>
    </section>
    
  • “multisite” is not a standard WP_Query arg. I would suggest contacting the developer of the plugin(?) that adds this ability.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.