• Resolved rbergeron81

    (@rbergeron81)


    Moved a site from a dev environment on Bluehost to a live URL on Hostway and now SLB has stopped working.

    Here is the page that it is working on (bluehost):

    https://prattarch.hay-wire.com/project/healthcare/

    And here is where it is NOT working (Hostway):

    https://prattarch.com/project/healthcare/

    I am using an ACF repeater field with an ob_get_clean() for the content (code below)

    <?php if(have_rows(‘project_gallery’)): ?>

    <?php

    $cntr = 0;

    $row_cntr = 0;

    ;?>

    <div class=”project-gallery-row cf”>

    <?php while(have_rows(‘project_gallery’)) : the_row();?>

    <?php

    $cntr++;

    $row_cntr++;

    ob_start();

    $image = get_sub_field(‘project_photo’);

    $large_size = ‘project-two-third’;

    $small_size = ‘project-one-third’;// (thumbnail, medium, large, full or custom size)

    if( ! empty( $image ) ) {

    // vars

    $url = $image[‘url’];

    $title = $image[‘title’];

    $alt = $image[‘alt’];

    $caption = $image[‘caption’];

    // thumbnail

    $large_size_image = $image[‘sizes’][‘large’];

    $two_thirds_image = $image[‘sizes’][ $large_size ];

    $one_third_image = $image[‘sizes’][ $small_size ];

    $width_large = $image[‘sizes’][ $large_size . ‘-width’ ];

    $height_lage = $image[‘sizes’][ $large_size . ‘-height’ ];

    $width_small = $image[‘sizes’][ $small_size . ‘-width’ ];

    $height_small = $image[‘sizes’][ $small_size . ‘-height’ ];

    ?>

    <?php

    if ($row_cntr === 2) {

    $class = ‘last-project-image’;

    } elseif ($row_cntr === 1) {

    $class = ‘large-project-image’;

    } elseif ($cntr%3 === 0) {

    $class = ‘last-project-image’;

    };

    ?>

    <?php if ($row_cntr === 1):?>

    <div class=”project-gallery-item m-all t-2of3 d-2of3 <?php echo $large_size;?>”>

    ” title=”<?php echo $title; ?>”>

    <img src=”<?php echo $two_thirds_image; ?>” alt=”<?php echo $alt; ?>” />

    </div>

    <?php else:?>

    <div class=”project-gallery-item m-all t-1of3 d-1of3 <?php echo $class;?>”>

    ” title=”<?php echo $title; ?>”>

    <img src=”<?php echo $one_third_image; ?>” alt=”<?php echo $alt; ?>” />

    </div>

    <?php endif;?>

    <?php } ?>

    <?php

    $content = ob_get_clean();

    echo slb_activate($content);

    ?>

    <?php

    if ($row_cntr == 2) {

    $cntr = 0;

    echo ‘</div><div class=”project-gallery-row cf”>’;

    }elseif ($cntr%3 == 0) {

    $cntr = 0;

    echo ‘</div><div class=”project-gallery-row cf”>’;

    }

    ;?>

    <?php endwhile;?>

    </div> <?php // end project gallery row?>

    <?php endif;?>

    </section> <?php // end article section ?>

    https://www.ads-software.com/plugins/simple-lightbox/

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘SLB Not working after Hosting change’ is closed to new replies.