[Plugin: Flickr Photo Album] Custom Gallery
-
Hi everyone,
I am trying to adapt the flickr photo album so that it looks and feels native at my current website.
I am using the WPshower WP-theme called “imbalance” and adopted the photo gallery of the WPshower WP-theme “portfolium” for single pages. You can see an example at my website here: https://www.muenchphoto.de/2009/08/traveling-china/
the single-php line which inserts the gallery looks like this:
<div id="show"> <?php $args = array( 'post_type' => 'attachment', 'orderby' => 'menu_order', 'order' => ASC, 'numberposts' => -1, 'post_status' => null, 'post_parent' => $post->ID, 'exclude' => get_post_thumbnail_id() ); $attachments = get_posts($args); if ( $attachments ): foreach ( $attachments as $attachment ): echo wp_get_attachment_image($attachment->ID, 'full'); endforeach; endif; ?> </div>
Unfortunately my knowledge of wordpress code is not too good – so that I can only guess that the gallery is built by taking the attachments of this single post, which I uploaded to the media library. I am also guessing the rest of the gallery function is done by jquery cycle, CSS and pagination.
Now I need to have the “photoalbum-photo.html” of the “Flickr Photo Album” plugin adapt to look exactly like this type of gallery.
The important part of this HTML file should be:
<div id="photo"> <img src="<?php echo $sizes['Medium']['source']?>" width="<?php echo $sizes['Medium']['width']?>" height="<?php echo $sizes['Medium']['height']?>"/> <?php if (is_array($photo['notes']['note'])):?> <div id="notes"> <?php foreach ($photo['notes']['note'] as $note):?> <div class="note" style="top:<?php echo $note['y']?>px;left:<?php echo $note['x']?>px;"> <div class="hover2"><div class="hover" style="width:<?php echo $note['w']?>px;height:<?php echo $note['h']?>px;"></div></div> <div class="text"><?php echo ($note['_content'] ? $note['_content'] : $note['_value'])?></div> </div> <?php endforeach;?> </div> <?php endif;?> </div> <p><?php echo apply_filters('the_content', $photo['description']);?></p> <?php include($TanTanFlickrPlugin->getDisplayTemplate('/photoalbum-photometa.html'));?> <?php include($TanTanFlickrPlugin->getDisplayTemplate('/photoalbum-comments.html')); ?> <?php include($TanTanFlickrPlugin->getDisplayTemplate('/photoalbum-context.html')); ?>
I have no idea how to start to merge those two different gallery-approaches. I think I need to change my current gallery so that it no longer takes the images from the attachments, but to take them from the flickr API.
If you should have a clue were I need to start, I would very welcome your thoughts.
Thanks for your efforts and best regards.
- The topic ‘[Plugin: Flickr Photo Album] Custom Gallery’ is closed to new replies.