<if condition>

ssj162

New Member
how do I merge these two ?

<if condition="is_member_of($vbulletin->userinfo, 1, 2, 3, 4, 5, 6, 7, 8, 9)">

<if condition="$post[postcount] % $vboptions[maxposts] == 1">
 

JMaldo

New Member
try using

PHP:
<if condition="is_member_of($vbulletin->userinfo, 1, 2, 3, 4, 5, 6, 7, 8, 9)";"$post[postcount] % $vboptions[maxposts] == 1">
 

ssj162

New Member
eko said:
try using

PHP:
<if condition="is_member_of($vbulletin->userinfo, 1, 2, 3, 4, 5, 6, 7, 8, 9)";"$post[postcount] % $vboptions[maxposts] == 1">

nope, not working. get syntax error.
 

Takster

New Member
I thought it was like AND or OR

PHP:
<if condition="condition1 AND condition2">
or
PHP:
<if condition="(condition1) AND (condition2)">

PHP:
<if condition="is_member_of($vbulletin->userinfo, 1, 2, 3, 4, 5, 6, 7, 8, 9) AND $post[postcount] % $vboptions[maxposts] == 1">some stuff</if>

but I'm prolly wrong. It's not something I've needed much in the past (conditionals that is)
 

ssj162

New Member
it works, but then I won't see the anything at all.

I tried this option already but then the part after AND is not working.
 

Hoxxy

New Member
ssj162 said:
anyone able to help? hoxxy maybe? ^^

Just wrap the hidden code in both

HTML:
<if condition="is_member_of($vbulletin->userinfo, 1, 2, 3, 4, 5, 6, 7, 8, 9)">
<if condition="$post[postcount] % $vboptions[maxposts] == 1"> 

<-- HIDDEN CODE -->

</if></if>

There shouldnt be any conflicts.
 

ssj162

New Member
aint working, still the add is not showing up at all.

code is as follow

Code:
<if condition="$post[postcount] % $vboptions[maxposts] == 1"> 
    <table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
    <tr>
        <td class="thead" align="left">Sponsored Link</td>
    </tr>
    <tr>
        <td class="alt1" align="center">
        <br />
<script type="text/javascript"><!--
google_ad_client = "pub-xxxxxxxxxxxxxx";
/* Ad 728x90 */
google_ad_slot = "xxxxxx";
google_ad_width = 728;
google_ad_height = 90;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script><a href="http://www.xxxxxx.com/forum/payments.php"  style={font-size: 90px; color:#FFF;}>Donate</a> <style={color:#F00; font-size: 90px;}>to remove ads</font>
        </td>
    </tr>
    </table>

    </div>
</if>

any other ideas?
 

Hoxxy

New Member
Mmm.....ok so what your trying to do is place an ad after the first post yes?

If you are running 3.7.x all you have to do for this is add the code to the "ad_showthread_firstpost" template and do not need the if conditional.
 

ssj162

New Member
Hoxxy said:
Mmm.....ok so what your trying to do is place an ad after the first post yes?

If you are running 3.7.x all you have to do for this is add the code to the "ad_showthread_firstpost" template and do not need the if conditional.


yeah that's correct, ok I'll try it now
 
Top