• Resolved crevinamd

    (@crevinamd)


    Love this theme – curious about functionality of post formats.

    I want to use the blog as a portfolio. Currently, the GALLERY FORMAT also shows up on the masonry style blog page, where the gallery images rotate and the page title is the link. Likewise the IMAGE FORMAT is only one image on the Single Post page (where I’d like a gallery).

    Is there any way to use the IMAGE FORMAT for the masonry blog page only, and the GALLERY FORMAT for the single post page only?

    I’m using a child, and I can handle the code, just trying to save some time since I’m not sure where to look. Any help would be appreciated.

    THANKS!

Viewing 10 replies - 1 through 10 (of 10 total)
  • Pakistan Super League | A CRICKET THRILLER TO BE LAUNCHED http://www.3dillumination.com/news/pakistan_super_league

    The main index file (index.php) gets the formats for the home and archive pages.

    Just as a test I changed

    <?php get_template_part('content',get_post_format()); ?>

    to

    <?php get_template_part('content-image'); ?>

    it makes all posts use the image format for the home and archive pages. However the posts that are assigned the gallery format for single view don’t get the hover-overlay, not sure why that is..

    Thread Starter crevinamd

    (@crevinamd)

    Thanks deepbevel.

    I see it now, but it broke the post itself (there is no image at all). Maybe I can jimmy-rig a solution based on that idea. Stay tuned.

    Unfortunately it may have something to do with the format actually assigned to the post, I always thought single post format was independent of format for archives or blog/home. But in fact I don’t know all that much about it..

    just confirmed that in my test, the posts that are assigned gallery format for single view do not get the over-lay on hover, otherwise posts assigned the standard and image formats get the hover, behave as expected. But at least, all display their featured images.

    almost have it, these posts are of all 3 formats, but all do the image format for the home page

    http://www.foursticks.net/Demo/

    Still as you will notice the overlay on hover isn’t complete, still doesn’t get the zoom transition for posts assigned the gallery format.

    The way I got this far was to add this to the main index template

    <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>

    so it wraps the already existing

    <div class="posts" id="posts">

    before I did this, I got no overlay on hover of any kind, as I previously described. Now at least I get the overlay, just no zoom.

    I think it MAY have something to do with Flex Slider not using the post thumbnail. In functions.php I see a get_posts array that gets the attachment by date for the flexslider. I realized this when I noticed the featured image is not the first image in the sliders, depending on it’s order of upload.

    I’ll have to think about this one.. maybe the overlay is part of the post class for the image format, but perhaps it needs the post thumbnail to get the transition zoom effect?, and the slider doesn’t use it? scratching my head..

    well, the theme developer is probably having a good laugh at least.. I only hope I can help out and also learn something in the attempt. This is my school you know.

    I got zoom by force tu have class as for image-gallery:
    1. take file from fukusawa content.php
    2. change the name of the file into content-gallery.php
    3. change:
    <div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    into
    <div id="post-<?php the_ID(); ?>" class="post-<?php the_ID(); ?> post type-post status-publish format-image has-post-thumbnail hentry category-uncategorized post_format-post-format-image" >
    better is to change the function but…

    anyway I have copied first 19 lines from content-image

    http://projektowanie.requiem-records.com/

    Maybe this is not the best way but it works (if ti will really have “post thumbnail same category etc.) crutial are in class –> format-image and post_format-post-format-image

    Well if it’s not the best, it’s the best so far, thanks!

Viewing 10 replies - 1 through 10 (of 10 total)
  • The topic ‘Image Post vs. Gallery Post Format’ is closed to new replies.