Log in

View Full Version : Conditional Question-simple


RichieBoy67
05-08-2012, 09:25 PM
Hey all, Thanks for helping.


I already have a conditional set up to show a banner after the first post. I also want a banner to display after the last post but only if there are a few posts.

I have written the following but it ends up showing just as it is written, 1 banner after the 11th post and then another after the last post. I believe I need a Or Else statement but I am just not getting it.

<vb:if condition="$post[postcount] % $vboptions[maxposts] == 11 OR $post['islastshown']">

I really appreciate it.

Thanks,
Richie

kh99
05-08-2012, 10:22 PM
I'm not sure I understand completely what you want, but maybe this:

<vb:if condition="$post[postcount] > 11 AND $post['islastshown']">


I think that should display it after the last post, but only if there are more than 11.

RichieBoy67
05-08-2012, 10:47 PM
Thanks, I believe that is exactly what I want. Had I just used the last post conditional it would interfere with the display after first post conditional I already have. This works for me perfectly. I originally had wanted to display at the 11th and also at the last post but I can see how to make that happen now..I got it I think. Thanks

I appreciate the help friend!