• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Appfinite

Appfinite

Premium WordPress Themes for The Genesis Framework

  • Themes
  • Blog
  • Tutorials and Resources
  • Forums
  • Contact Us

Portfolio Page

Home › Community Forums › Optimal Theme Support › Portfolio Page

Tagged: featured image, legacy, Optimal, portfolio page, post, thumbnail

  • This topic has 3 replies, 2 voices, and was last updated 10 years, 3 months ago by Wes.
Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • May 11, 2012 at 8:06 pm #986
    pecographe
    Customer

    I am trying to use the Optimal Portfolio page. My problem is that when you click on the featured image thumbnail it does not link to the post that it is suppose to represent. What happens instead is that I get a large version of the featured image on a white background. How do I get my featured image thumbnail to link to the post it is suppose to represent ie. like the demo?
    I would really appreciate help with this issue before I pull out all my hair as a result of frustration!!!!

    May 11, 2012 at 11:55 pm #987
    Wes
    Moderator

    When you click on an image in the demo, the prettyPhoto slideshow is what comes up and displays all of the images. You can turn this off and have the images link to the post by doing the following –

    In your “page_portfolio.php” file in your theme, look for the area that looks like this (should be around line 50) –

    // Add Featured Image for the Portfolio posts in this Page Template
    add_action('genesis_before_post_content', 'legacy_portfolio_do_post_image');
    function legacy_portfolio_do_post_image() {
        $img = genesis_get_image( array( 'format' => 'html', 'size' => 'portfolio-thumbnail', 'attr' => array( 'class' => 'alignnone post-image' ) ) );
    	printf( '<a href="%s" rel="prettyPhoto[gallery1]" title="%s" rel="nofollow">%s</a>', genesis_get_image( array( 'format' => 'url', 'size' => 'Portfolio Full', 'attr' => array( 'class' => 'alignnone post-image' ) ) ), the_title_attribute('echo=0'), $img );
    }

    Then replace that code with the code below –

    // Add Featured Image for the Portfolio posts in this Page Template
    add_action('genesis_before_post_content', 'legacy_portfolio_do_post_image');
    function legacy_portfolio_do_post_image() {
        $img = genesis_get_image( array( 'format' => 'html', 'size' => 'portfolio-thumbnail', 'attr' => array( 'class' => 'alignnone post-image' ) ) );
        printf( '<a href="%s" title="%s" rel="nofollow">%s</a>', get_permalink(), the_title_attribute('echo=0'), $img );
    }
    May 12, 2012 at 4:10 am #988
    pecographe
    Customer

    Brilliant, works perfectly now…. I’m so happy!!!!!

    May 12, 2012 at 3:40 pm #989
    Wes
    Moderator

    You’re Welcome!

  • Author
    Posts
Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Portfolio Page’ is closed to new replies.

Primary Sidebar

Search Forums

Affiliate Program

Looking to earn some money? Join our Affiliate program and earn 35% of every sale you refer. Top referrers earn 40-50%.

Join Now →

The Genesis Framework

All of our themes are designed for the Genesis Framework. You will need to purchase Genesis in order to use any of our themes.

Purchase Genesis

Hire a Web Developer

Need help setting up or customizing your website?

Contact Us →

Search Full Site

  • Buy Genesis!
  • Shopping Cart
  • Themes
  • My Account
  • Support Forums
  • Tutorials and Resources
  • Privacy Policy
  • Contact Us
  • Follow Us on Twitter

Copyright © 2022 · Appfinite · Built With The Genesis Framework