Make WordPress Core

Opened 14 years ago

Closed 14 years ago

#22943 closed defect (bug) (fixed)

Twenty Twelve: show featured images single page view

Reported by: tomontoast Owned by: lancewillett
Priority: normal Milestone: 3.6
Component: Bundled Theme Version: 3.5
Severity: normal Keywords: has-patch
Cc: Focuses:

Description

Twenty Twelve theme is reporting featured images can be used on pages which is not the case. Users can add featured images to pages but these don't show up in the theme as the user would expect.

See support thread ​http://wordpress.org/support/topic/2012-featured-image-not-showing-in-body-of-page-or-post?replies=17

The patch is a simple change in the functions file from

add_theme_support( 'post-thumbnails' );


to

add_theme_support( 'post-thumbnails', array( 'post' ) );

Attachments (3)

22943.diff​ (1.1 KB ) - added by MikeHansenMe 14 years ago.
show featured image on pages
22943.2.diff​ (481 bytes ) - added by MikeHansenMe 14 years ago.
New patch that leaves support open for other post types
22943.3.patch​ (577 bytes ) - added by lancewillett 14 years ago.
Fixes issue with duplicate image in front page template display

Download all attachments as: .zip

Change History (12)

#1 @MikeHansenMe
14 years ago

I would think they should work on Pages as well as Posts.

@MikeHansenMe
14 years ago

show featured image on pages

#2 @MikeHansenMe
14 years ago

  • Cc mdhansen@… added

#3 @DrewAPicture
14 years ago

  • Cc xoodrew@… added

#4 @obenland
14 years ago

  • Milestone Awaiting Review → 3.6
  • Severity minor → normal

Very interesting, nice catch!

From the inline documentation in current_theme_supports():

If no array was passed, then any type is accepted

I agree with MikeHansenMe, it should work also on pages. I'm not sure whether we want to restrict it to post and pages, though.

#5 @tomontoast
14 years ago

  • Cc tomontoast added

I agree, users expect featured images to work on pages as they did in twenty eleven.

Another forum thread ​http://wordpress.org/support/topic/featured-image-for-pages?replies=3

What types of page other than posts and pages would you want featured images to work on?

@MikeHansenMe
14 years ago

New patch that leaves support open for other post types

#6 @lancewillett
14 years ago

  • Summary Twenty Twelve theme reporting featured images can be used on pages → Twenty Twelve: show featured images single page view

#7 @lancewillett
14 years ago

  • Owner set to lancewillett
  • Resolution → fixed
  • Status new → closed

In 23471:

Twenty Twelve: show featured image in single page views. Fixes #22943, props MikeHansenMe.

#8 @lancewillett
14 years ago

  • Resolution fixed
  • Status closed → reopened

Found a small issue, reported on WP.com sites, example here: ​https://twentytwelvedemo.wordpress.com/

Screenshot: ​http://d.pr/i/wgbF/1PI95pEn

Two featured images in the case a page has a featured image *and* it's set to front static page, *and* it's using the Front Page Template.

@lancewillett
14 years ago

Fixes issue with duplicate image in front page template display

#9 @lancewillett
14 years ago

  • Resolution → fixed
  • Status reopened → closed

In 23561:

Twenty Twelve: fix double featured images in Front Page Template, closes #22943.

Note: See TracTickets for help on using tickets.