WordPress.org

Ready to get started?Download WordPress

Forums

zAlive
[resolved] slider title url issue SOLVED! (2 posts)

  1. 2twins
    Member
    Posted 6 months ago #

    Hi - I see many of you are trying to get the slider link to go into the title. Here is the fix: open slider.php in the templates folder and replace it with this:

    <?php
    
    /**
    
     * slider template
    
     */
    
     global $zAlive_options;
    
    ?>
    
      <div id="zSlider" class="container carousel slide">
    
        <!-- Carousel items -->
    
        <div class="carousel-inner">
    
          <div class="active item">
    
            <?php if ( !empty( $zAlive_options['slider1_link'] ) ) { ?>
    
            <a href="<?php echo esc_url ( $zAlive_options['slider1_link'] ) ; ?>"><img src="<?php echo esc_url ( $zAlive_options['slider1_img'] ) ; ?>" alt="" /></a>
    
            <?php } else { ?>
    
            <img src="<?php echo esc_url ( $zAlive_options['slider1_img'] ) ; ?>" alt="" />
    
            <?php } ?>
    
          </div>
    
          <div class="item">
    
            <?php if ( !empty( $zAlive_options['slider2_link'] ) ) { ?>
    
            <a href="<?php echo esc_url ( $zAlive_options['slider2_link'] ) ; ?>"><img src="<?php echo esc_url ( $zAlive_options['slider2_img'] ) ; ?>" alt="" /></a>
    
            <?php } else { ?>
    
            <img src="<?php echo esc_url ( $zAlive_options['slider2_img'] ) ; ?>" alt="" />
    
            <?php } ?>
    
          </div>
    
          <div class="item">
    
            <?php if ( !empty( $zAlive_options['slider3_link'] ) ) { ?>
    
            <a href="<?php echo esc_url ( $zAlive_options['slider3_link'] ); ?>"><img src="<?php echo esc_url ( $zAlive_options['slider3_img'] ) ; ?>" alt="" /></a>
    
            <?php } else { ?>
    
            <img src="<?php echo esc_url ( $zAlive_options['slider3_img'] ) ; ?>" alt="" />
    
            <?php } ?>
    
          </div>
    
          <div class="item">
    
            <?php if ( !empty( $zAlive_options['slider4_link'] ) ) { ?>
    
            <a href="<?php echo esc_url ( $zAlive_options['slider4_link'] ) ; ?>"><img src="<?php echo esc_url ( $zAlive_options['slider4_img'] ); ?>" alt="" /></a>
    
            <?php } else { ?>
    
            <img src="<?php echo esc_url ( $zAlive_options['slider4_img'] ) ; ?>" alt="" />
    
            <?php } ?>
    
          </div>
    
        </div>
    
        <ul class="description hidden-phone">
    
          <li class="active">
    
    			<a href="<?php echo esc_url ( $zAlive_options['slider1_link'] ) ; ?>"><strong><?php echo esc_attr ( $zAlive_options['slider1_title' ] ) ; ?></strong></a>
    
            <p><?php echo $zAlive_options['slider1_content']; ?></p>
    
          </li>
    
          <li>
    
    			<a href="<?php echo esc_url ( $zAlive_options['slider2_link'] ) ; ?>"><strong><?php echo esc_attr ( $zAlive_options['slider2_title'] ) ; ?></strong></a>
    
            <p><?php echo $zAlive_options['slider2_content']; ?></p>
    
          </li>
    
          <li>
    
    			<a href="<?php echo esc_url ( $zAlive_options['slider3_link'] ) ; ?>"><strong><?php echo esc_attr ( $zAlive_options['slider3_title'] ) ; ?></strong></a>
    
            <p><?php echo $zAlive_options['slider3_content']; ?></p>
    
          </li>
    
          <li>
    
    			<a href="<?php echo esc_url ( $zAlive_options['slider4_link'] ) ; ?>"><strong><?php echo esc_attr ( $zAlive_options['slider4_title'] ) ; ?></strong></a>
    
            <p><?php echo $zAlive_options['slider4_content']; ?></p>
    
          </li>
    
        </ul>
    
      </div>
  2. outwardjourney
    Member
    Posted 2 months ago #

    Thanks a bunch! Worked for me!

Reply

You must log in to post.

About this Theme

About this Topic