Announcement

Collapse
No announcement yet.

Conditional - Target only first post in thread

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Conditional - Target only first post in thread

    Hi, I have a conditional:-
    <if condition="(!$GLOBALS['FIRSTPOSTID'])

    This targets the first post shown on each page of a thread....

    I need to be more specific and limit it to the very post in the thread only (the thread starting post)

    Can anyone give me the correct conditional statement I need to use?

    Thanks

  • #2
    Use this condition:
    Code:
    <if condition="$post[postcount] == 1">
    Best Regards
    Colin Frei

    Please don't contact me per PM.

    Comment


    • #3
      Thanks...

      Do you also know how to say if the forumid is x?
      is it $post[forumid] ??

      Comment


      • #4
        I think you'll need to use $foruminfo[forumid]
        Best Regards
        Colin Frei

        Please don't contact me per PM.

        Comment


        • #5
          Wicked....

          Thank you.

          Comment


          • #6
            Hmmm...

            It's not working....

            I am doing this:-
            <if condition="!($post[postcount] == 1 AND $foruminfo[forumid] == 152)">
            // do the following only if it's not the thread starting post in forum 152
            </if>

            It aint working.... :S

            Comment


            • #7
              for the postbit use $thread[forumid]

              Comment


              • #8
                You also mixed up your conditional.
                Use this instead:
                <if condition="$post[postcount] != 1 AND $thread[forumid] == 152">
                Best Regards
                Colin Frei

                Please don't contact me per PM.

                Comment

                widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                Working...
                X