Skip to main content

Questions tagged [featured-post]

Filter by
Sorted by
Tagged with
0 votes
0 answers
26 views

Why I have this strange behavior when I try to exlude the featured post from posts visualization?

I am quite new to WordPress theme development and I have a strange behavior with this custom theme on which I am working: http://lnx.asper-eritrea.com/ As you can see in the home page I have 2 areas ...
AndreaNobili's user avatar
1 vote
2 answers
3k views

How do I style the first two posts of a loop

I'm trying to style a single loop to look like so --------------------------------------------- || | || || || | ||--------------|| || ...
user avatar
0 votes
2 answers
3k views

Show last 5 posts from featured category on query carousel slider with prev and next button

I managed to set up a query carousel slider on my test-site. How can i adapt the slider to show the 5 latest posts from my featured post category with thumb, title and link to the post instead of the ...
NewUser's user avatar
  • 557
-1 votes
1 answer
2k views

Previous / next posts using featured image thumbnail as links

I need navigation to two previous and two next posts, inside same category. I made it working great for one previous and one next post inside same category. This is what I have now. Previous post: &...
Advanced SEO's user avatar
1 vote
3 answers
4k views

Exclude posts from homepage having a specified tag

I am pretty new in WordPress development and I am trying to implement this custom theme that handle the so called featured posts As you can see in the posts area of the homepage I have the Articoli ...
AndreaNobili's user avatar
2 votes
2 answers
9k views

How to get relative URL of medium sized featured image?

How to show featured image (medium sized) relative URL (relative to the website root)? I need something like this: uploads/214/07/image-600x400.png I tried with this: if ( has_post_thumbnail()) { ...
Advanced SEO's user avatar
-2 votes
1 answer
3k views

Orientation of featured image in post?

Is it possible to show orientation of featured image in post on single.php? For example: Orientation of featured image is: portrait / landscape. I have found that this could be done by calculating ...
Advanced SEO's user avatar
-2 votes
1 answer
1k views

How to show file size of featured image? [duplicate]

How to show file size of featured image in post on single.php? For example: File size of featured image is: xx kb/Mb I need size of featured "full" rezolution, also file size of "medium" resolution ...
Advanced SEO's user avatar
-3 votes
1 answer
3k views

How to show file type of featured image?

How to show file type of featured image in post on single.php? For example: Featured image type is: ".jpg" I can get mime-type, like "image/jpeg". It could be also some check of image mime-type ...
Advanced SEO's user avatar
1 vote
2 answers
2k views

How to check if there is image title, caption, description?

I use this code to display featured image title, caption (excerpt), description (content): echo get_post(get_post_thumbnail_id())->post_title; echo get_post(get_post_thumbnail_id())->...
Advanced SEO's user avatar
3 votes
1 answer
7k views

Get the size (size in Kb or MB) of an featured image?

I need to display some featured image info on post page. Among other info I need to display file size of image (featured image of post). I tried this function inside single.php. <?php function ...
Advanced SEO's user avatar
3 votes
1 answer
1k views

Featured Image Inherited from Parent Page

What I would like to do is have my parent page's featured images display, unless a child page has its own featured image, then I would like that image to become the featured image from that page and ...
JHP's user avatar
  • 83
17 votes
1 answer
699 views

Keep featured content post in homepage with original order

I'm searching how to keep the featured post in my blog homepage without excluding it from query post. My blog uses the Twenty Fourteen theme. I found this solution. Open the featured-content.php ...
Naziman Azlye's user avatar
4 votes
2 answers
4k views

How to get featured post title & image using JSON API?

Is there any possibility to get featured post title and image using the JSON API. I tried using this: example.com/?json=the_post_thumbnails&count=3 But instead of recent posts, I get featured ...
warzone_fz's user avatar
0 votes
1 answer
672 views

Featured posts and the loop

I'm trying to add a box in index.php where to show the latest 3 featured posts. According to this tutorial, I've added the following to functions.php: add_theme_support( 'featured-content', array( ...
user50694's user avatar
0 votes
2 answers
3k views

Display single most recent post in category on every page of category archive

I am trying to display a single "featured post" in the archive.php template using a custom query. This featured post should be the most recent post in that category or tag. I'm using pagination for ...
markcbain's user avatar
  • 333
0 votes
1 answer
2k views

External URL Link as Featured Images

How do set post thumbnail (featured image) from an external URL without uploading the image to WordPress media library.
Deacon Tran's user avatar
0 votes
1 answer
2k views

How to display the featured image of a parent on child pages?

I was searching how I can get the featured images of the parent also on the child pages, without uploading it also for the childs. How can this solve?
Casper's user avatar
  • 409
0 votes
1 answer
873 views

Display thumbnail of child, parent and ancestor using featured thumbnails

I have tried to achieve that the Home page displays featured images of all it's child pages and in turn some child pages are displaying the featured images of their child pages. This is my code so far!...
HannesH's user avatar
  • 75
1 vote
2 answers
520 views

"Issues" loading MANY featured images on a single page (custom template)

I have a page that loads a lot of featured items in a grid. There are up to 56 images loading, and it does have a bit of a delay. This is the code as it runs now: if( count( $postslist ) > 0 ) { ...
SlackerCoder's user avatar
1 vote
2 answers
223 views

Latest Post Styled Different Than other Posts

I'm just completely mixed-up with this. I need the 1st post of the loop looks differently, as a kind of magazine style, you know: bigger thumbnail and bigger title. I tried already nth-of-type in CSS,...
Paul K's user avatar
  • 11
1 vote
2 answers
438 views

How to change featured content to a different tag in Wordpress Twenty Fourteen?

In twenty fourteen theme, we’d like to know how to change the features content tag. Currently it’s set as featured. Now, we would like to know how to code this for different page templates. We ...
alex's user avatar
  • 133
1 vote
0 answers
158 views

Setup Featured image on all posts from thesis thesis_post_image custom field?

I moved from thesis to other wp theme and i want to change the thesis post images (these are saved under thesis_post_image in database )as featured images. Site have over 1000+ posts. Is there a way ...
Gowtham's user avatar
  • 11
0 votes
1 answer
2k views

Exclude most recent posts from specific category in wp_query()

I have a featured posts slider, which uses the 'featured' tag. I have a query for this which grabs the 3 most recent posts with this tag and shows them in the slider. Below this, I have a list of 10 ...
Tom Oakley's user avatar
1 vote
1 answer
1k views

How to display only feautured/sticky listings on the homepage

I want on my homepage on my first page to be displayed only featured listings no matter how old they are This is my homepage code: <?php get_header(); ?> <?php if(get_option('aven_home'...
Bogdan Bătrânu's user avatar
1 vote
2 answers
2k views

Front page should display only one category of posts including sticky post with custom featured post box

I need code to get one category - including its sticky post and a custom featured post box on my front page. I am using twenty twelve. I have created a child theme. I have wordpress 3.6 on a wordpress....
skj's user avatar
  • 11
0 votes
1 answer
189 views

How can I detect if the current post is in this loop?

My featured articles have been built with the following query: $featured_posts = new WP_Query(  array(  'post__not_in' =--> get_option( 'sticky_posts' ),  'meta_key' => is_featured',  '...
p.a.'s user avatar
  • 581
0 votes
1 answer
2k views

Option to feature custom post type on home page

I am wondering what's the best way to give a user the option to feature a custom post type on the home page. I have a Case Study custom post type and some of them need to be feautured on the home ...
semory's user avatar
  • 27
0 votes
1 answer
354 views

Title image is missing ( but is not the WP 3.5 issue )

I use Wp 3.4.2 and Featured Image. After I feel the Title, Alternate Text and publish the post, html code looks like this: <img width="214" height="300" title="" alt="Test" class="frame wp-post-...
Blanka's user avatar
  • 35
2 votes
2 answers
772 views

Include a specific post to the query_posts and remove it if it is already in the returned list

Bare with me. Firstly, here is my whole script for my featured slider articles: <div id="featured" class="<?php if ( $responsive ) echo 'flexslider' . $featured_auto_class; else echo 'et_cycle';...
Christine Cooper's user avatar
  • 8,857
33 votes
3 answers
36k views

Can I exclude a post by meta key using pre_get_posts function?

I see many people prefer to use pre_get_posts hook instead of query_posts. The code below works and shows all posts which have meta key "featured" function show_featured_posts ( $query ) { if ( $...
Carlisle's user avatar
  • 351
0 votes
1 answer
555 views

Automatic connect wordpress to facebook with featured image?

I want, when I publish any post, that it shows my facebook with featured image. Most of the plugins don't show feature images but shows other images. How can I do it - simply connect to facebook and ...
Smart Shovon's user avatar
2 votes
2 answers
2k views

How to set the width and height rule for featured image

I want to know how to make rules to re-size the images for featured image? I am uploading an image in featured image section but it is not cropping the images in exact width and height for all the ...
user159377's user avatar
0 votes
1 answer
2k views

How can I specify the width and height of the Featured Image in TwentyTwelve theme?

I am trying to get set the width, height and position of the Featured image for a new page I created.
zadubz's user avatar
  • 163
1 vote
1 answer
633 views

Big Image on Featured Post, Normal on Single Post

I have included a code which fetches any post under my category=featured. And that shows-up on the top of my content (*whenever we have any breaking news to show*)on blog-page. The problem is, The ...
vajrasar's user avatar
  • 169
1 vote
2 answers
4k views

Get the 5 lastest Featured Posts from a category

Here is the website http://ariadneswonderland.gr/ that all this concerns. On the homepage I'm using a Drop shadow box plugin under the gallery to show a series of images of featured posts, as of ...
presdec's user avatar
  • 11
4 votes
2 answers
897 views

How to display Section for certain time

i am building a News site. I want to display 1 featured post from "prime" category for only few hours. after it should be expired or disappeared from the section. please have a look here u can see ...
Nisha_at_Behance's user avatar
0 votes
2 answers
2k views

show div only if have a related post inside

I want to have a related box to show up - but only if a related post is inside the div. If theres no post the whole "related_box" div should be not shown. Any idea? Here's the code so far. <...
ad2003's user avatar
  • 251
0 votes
2 answers
1k views

handling the featured category

From time to time, I feature posts from the archives. Sometimes, I need to feature items 2 3 years back. In order to feature such posts, I simply categorized them into the featured category and once ...
Average Joe's user avatar
  • 1,889
1 vote
1 answer
145 views

How to use photo in multiple posts?

I have a theme that shows images only from gallery tab (so i can't re-use an image to other posts). As you know an image can only get attached to 1 post. I found a plugin that you can attach an image ...
beachlizard's user avatar
0 votes
3 answers
158 views

How to automate featured posts number? [duplicate]

Possible Duplicate: featuring old articles without messing up with the archive Let's say you have a category called "featured". and you use that to feature posts. And the theme you have has a ...
Average Joe's user avatar
  • 1,889
0 votes
1 answer
64 views

featuring old articles without messing up with the archive

This is all about featuring content in WP. Say, you got 1000's of posts that you accumulated over the years and each has their own original ( and true ) post dates. And now you want to feature them ...
Average Joe's user avatar
  • 1,889
0 votes
3 answers
5k views

Featured Posts Code - Repeated featured posts

I am soooo close to getting this to work but I have one outstanding issues. The featured posts code keeps repeating itself before/after each post. Any help would be greatly appreciated. The code ...
Matthew Snider's user avatar
0 votes
1 answer
833 views

filter posts without images or featured image

I'm using wordpress MU 3.3.1. I want to add a function within a loop that displays only posts with image, or featured image. please help me on how to filter posts. <?php get_header(); ?> <...
heradius's user avatar
0 votes
2 answers
3k views

Wordpress: Notice:Object of class WP_Query could not be converted to int in on line

I am facing issue in debug mode with wordpress. In my featured slider getting error Notice: Object of class WP_Query could not be converted to int in on line I am using below code for my slider <...
pixelngrain's user avatar
  • 1,390
1 vote
4 answers
3k views

Hide featured post on second page

I have a index.php with a featured post and a number of other posts and the standard wp_pagenavi at the bottom. I'm using the 2 loops from the wordpress codex like this: <?php $my_query = new ...
Jan Henckens's user avatar
1 vote
1 answer
1k views

How to add pagination to my code?

I just want to ask how can I add pagination here in this code: <?php if ( get_option('webly_display_media') == 'on' ){ ?> <div id="recent-projects"> ...
markyeoj's user avatar
  • 507
0 votes
1 answer
142 views

Broken pagination, need help figuring out why!

I just tried slapping together a poor-man's "featured post" section with this exact code out of my index.php: <div id="post-wrapper"> <?php if (is_home() && !is_paged()) : ?> ...
user avatar
1 vote
1 answer
5k views

how to exclude "featured" posts from the main loop?

In a category.php template, I built a function that lists "featured" posts before the main loop. The featured posts are selected using a custom field and get_posts(): function list_featured_articles()...
pixeline's user avatar
  • 2,877
0 votes
1 answer
311 views

Hide featured post from second page

This is my category page code <--Featured Post start--> <?php $count = 1; if (have_posts()) : while (have_posts()) : the_post(); if($count == 1) : ?> <a href="<?php the_permalink() ?...
user8503's user avatar

1
2