• Resolved CHEWX

    (@chewx)


    Hello,

    Is it possible to echo the photos assigned to the property into a simple, ul li structure so we can implement custom gallery ?

    Also, is it possible to see the photos assigned to the property in the property view rather than all jumbled in add/media.

    Thanks

    http://ww.wp.xz.cn/plugins/wp-property/

Viewing 1 replies (of 1 total)
  • Thread Starter CHEWX

    (@chewx)

    Hacked to pieces Gallery Widget. Just don’t update plug-in as it will overwrite /core/class_widgets.php

    <div id="slider" class="flexslider">
            	<ul class="slides"><?php
            foreach($gallery as $image) {
    
              $thumb_image = wpp_get_image_link($image['attachment_id'], $image_type);
              ?>
              <li>
                <?php if(!empty($big_image_type)) : ?>
                  <?php $big_image = wpp_get_image_link($image['attachment_id'], $big_image_type); ?>
    
                    <img src="<?php echo $thumb_image; ?>" title="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title'] . ' - ' . $post->post_title); ?>" alt="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title']); ?>" />
    
                <?php else : ?>
                  <img src="<?php echo $thumb_image; ?>" title="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title'] . ' - ' . $post->post_title); ?>" alt="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title']); ?>" class="wpp_gallery_widget_image size-thumbnail "  width="<?php echo $thumbnail_dimensions['width']; ?>" height="<?php echo $thumbnail_dimensions['height']; ?>" />
                    <?php endif; ?>
    
              </li>
              <?php
              $real_count++;
    
              if(!empty($gallery_count) && $gallery_count == $real_count) {
                break;
              }
    
            }?></ul>
            </div>
            <div id="carousel" class="flexslider">
            	<ul class="slides">
    		<?php
            foreach($gallery as $image) {
    
              $thumb_image = wpp_get_image_link($image['attachment_id'], $image_type);
              ?>
              <li>
                <?php if(!empty($big_image_type)) : ?>
                  <?php $big_image = wpp_get_image_link($image['attachment_id'], $big_image_type); ?>
    
                    <img src="<?php echo $thumb_image; ?>" title="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title'] . ' - ' . $post->post_title); ?>" alt="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title']); ?>" />
    
                <?php else : ?>
                  <img src="<?php echo $thumb_image; ?>" title="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title'] . ' - ' . $post->post_title); ?>" alt="<?php echo esc_attr($image['post_excerpt'] ? $image['post_excerpt'] : $image['post_title']); ?>" class="wpp_gallery_widget_image size-thumbnail "  width="<?php echo $thumbnail_dimensions['width']; ?>" height="<?php echo $thumbnail_dimensions['height']; ?>" />
                    <?php endif; ?>
    
              </li>
              <?php
              $real_count++;
    
              if(!empty($gallery_count) && $gallery_count == $real_count) {
                break;
              }
    
            }?></ul>
            </div>

    Anyone see a better solution ?

Viewing 1 replies (of 1 total)

The topic ‘Draw Gallery’ is closed to new replies.