1 ethan5150 Sep 05, 2012 22:48
3 ethan5150 Sep 06, 2012 05:28
It's currently at the end of the Featured Posts section in the posts.main.php file which appears to be above the main post area but maybe I'm missing something... ?
4 sam2kb Sep 06, 2012 20:16
Try this
if( $Item->ptyp_ID == 1500 ) echo 'Yes, I am really an intro post!';
5 ethan5150 Sep 07, 2012 01:57
Thanks Sam2kb - I replaced my code with what you provided and it appears to have no effect.
6 sam2kb Sep 07, 2012 07:14
Then the post is not of type 1500
Use $Item->is_intro() instead
if( $Item->is_intro() ) echo 'Hooray! I\'m an intro post!';
7 ethan5150 Sep 07, 2012 19:24
Again, no effect. Not sure what the problem is but something is obviously broken...
8 sam2kb Sep 07, 2012 20:29
Try this
echo $Item->ptyp_ID;
9 ethan5150 Sep 07, 2012 21:08
It put a "1" (no quotes) below the post.
10 sam2kb Sep 07, 2012 21:09
Then it's a regular post
11 ethan5150 Sep 07, 2012 21:15
Well, the Featured Post box is checked - I've even unchecked it, saved, rechecked it and saved again. Any ideas?
12 sam2kb Sep 07, 2012 21:33
Ok, I see it now. There's a difference between featured and intro posts
Your post is not intro that's why it doesn't respond to is_intro() check. Add this
if( $Item->is_intro() || $Item->is_featured() ) echo 'Either intro or featured post';
13 ethan5150 Sep 07, 2012 21:45
Ok, that makes sense. So then what should I replace my original code
if( $Item->ptyp_ID == 1500 ) $GLOBALS['MainList'] = NULL;
to make it so the featured post is the only post that shows up?
***EDIT***
I'm an idiot.
I should have had it set to Intro the whole time. So sorry to waste your time - I'm retarded.
14 sam2kb Sep 07, 2012 22:03
if( $Item->is_intro() || $Item->is_featured() ) $GLOBALS['MainList'] = NULL;
15 ethan5150 Sep 07, 2012 22:06
Man, I feel like a total jackass. I'm really sorry!
16 sam2kb Sep 07, 2012 22:27
no problem
Where did you put this code? It should go somewhere above the main posts loop.