Welcome to PressWork!

Want to ask a question or join the discussion? Great! Join now.

In this Discussion

Picture sizes
  • Hi,

    I would like to change the size of the feature images on the posts on the front page (www.wordmurder.com), as they are so small I can barely see them. How can I do this?
  • um? Hello? is there anybody actually doing support?
  • now that I have looked through the site, I see that you have to pay to actually get answers, or to change anything. Thats crap. Time to change Wordpress themes.
  • I don't know what you are referring to in regards to having to pay to get support. If you want to change the size of your thumbnails you need to go into the WordPress Media settings and change the size of your thumbnails. Then it will be reflected throughout your site. You may also have to look into using the Regenerate Thumbnail plugin if your new size is in a different aspect ratio.
    image Senior Developer & Co-Founder of PressWork
  • the little tiny pictures of post excerpts on the front page. Why would anyone want pictures so small that no one can see them? No that is not a thumbnail issue. And the pay, is the briefcase thing. This does not answer my question.
  • You would have to create a Custom Action to rewrite the post content for the home page. Read about Custom Actions at http://presswork.me/2011/custom-css-and-custom-actions/.

    This is the code you would need:
    remove_action('pw_index_post_middle', 'pw_post_content', 11);
    add_action('pw_index_post_middle', 'custom_pw_post_content', 11);
    /*
    * Custom Post content
    */
    function custom_pw_post_content($ignore_image = false, $excerpt_length = 55, $hide_readmore = false, $display_excerpt = false) {
    echo pw_function_handle(__FUNCTION__);
    ?>
    <div class="storycontent">
    <?php
    if(function_exists('has_post_format') && !is_singular()) {
    $format = get_post_format();
    if(empty($format) || has_post_format('image')) {
    if(has_post_format('image')) $size = 'full'; elseif(empty($ignore_image)) $size = array(150, 150); else $size = 'thumbnail';
    if(function_exists('has_post_thumbnail') && has_post_thumbnail()) {
    if(empty($ignore_image) || has_post_format('image')) {
    echo '<a href="'.get_permalink().'" class="image-anchor">';
    the_post_thumbnail($size, array( 'class' => 'alignleft' ));
    echo '</a>';
    }
    } else {
    if(has_post_format('image'))
    the_content();
    }
    if(empty($format)) {
    pw_excerpt($excerpt_length);
    if(empty($hide_readmore)) echo '<a href="'.get_permalink().'" class="more-link">'.__('Read more &rarr;', "presswork").'</a>';
    }
    } elseif(has_post_format('gallery')) { // new gallery post format
    global $post;
    $images = get_children( array( 'post_parent' => $post->ID, 'post_type' => 'attachment', 'post_mime_type' => 'image', 'orderby' => 'menu_order', 'order' => 'ASC', 'numberposts' => 999 ) );
    if ( $images ) :
    $total_images = count( $images );
    $image = array_shift( $images );
    $image_img_tag = wp_get_attachment_image( $image->ID, 'full' );
    ?>
    <a class="gallery-thumb alignnone" href="<?php the_permalink(); ?>"><?php echo $image_img_tag; ?></a>
    <p class="gallery-text clearfix fl"><em><?php printf( _n( 'This gallery contains <a %1$s>%2$s photo &rarr;</a>', 'This gallery contains <a %1$s>%2$s photos &rarr;</a>', $total_images, "presswork" ), 'href="' . get_permalink() . '" title="' . sprintf( esc_attr__( 'Permalink to %s', "presswork" ), the_title_attribute( 'echo=0' ) ) . '" rel="bookmark"',
    number_format_i18n( $total_images )
    ); ?></em>
    </p>
    <?php endif; ?>
    <?php
    } else {
    // new aside || link || audio || video || image post format
    echo '<div class="pformat clearfix">';
    the_content('');
    echo '</div>';
    }
    } else {
    if(!empty($display_excerpt))
    pw_excerpt($excerpt_length);
    else
    the_content( __( 'Read more &rarr;', "presswork" ) );
    }
    ?>
    </div>
    <?php
    }


    The line that sets the image size is this:
    if(has_post_format('image')) $size = 'full'; elseif(empty($ignore_image)) $size = array(150, 150); else $size = 'thumbnail';


    You just need to set the size in that array array(150, 150).
    image Senior Developer & Co-Founder of PressWork
  • Images not appearing at all in home page posts, while they do if you actually click your posts? ==> click "set as featured image" in the media uploader, down at the bottom.
  • Seems Presswork 1.0.4.2 adds a media size called 'small' that is 80x80. A bit confusing, since there is a standard WordPress 'thumbnail' size for featured images with post excerpts. But easy to change in the code, although just use 'thumbnail' rather than hardcoding values, since WP has long-established media settings for this.

    if(has_post_format('image')) $size = 'full'; elseif(empty($ignore_image)) $size = 'small'; else $size = 'thumbnail';

    If Presswork is going to extend the media settings, might be nice to expose that in the UI.
  • I just installed PW on a freshly upgraded WP, I love the theme! Really great it has all the features I was looking for. Thanks sooo much!!! Unfortunately it doesn't like my pictures. I put the slideshow in "top main content on index" and I can see titles and summary, but no pics even if I set them as "featured" in the posts. I uploaded my header, in perfect size, it is in the media gallery but I cannot get it to show in the site. Any suggestions?
    I don't have any fancy plugins just a SEO
  • Can I see your site live?
    image Senior Developer & Co-Founder of PressWork
  • Hi! Thanks for the quick reply :), I found the error the path was not set properly on the test site.
    Thanks a lot for the great theme!