PDA

View Full Version : How to Combine <IF Conditions Please Help!


kalisekj
10-07-2009, 04:18 AM
I Need to Make 2 <if conditions combined then run a script. The Conditions are To Not Include Certain Forums and to Not Include Mod User groups then Run The Script. I tried the following but it did not work.
Example:

<if condition="!is_member_of($bbuserinfo, 5, 6, 7, 10, 12)"> AND <if condition="!in_array($forumid, array(145,113,103,10,114,117,164,9,144,158))"> <else /> <script src="http://www.cpalead.com/mygateway.php?pub=21615&gateid=MTA4MDI%3D" language="JavaScript" type="text/javascript"></script>
</if></if>

Iain M
10-07-2009, 01:03 PM
<if condition="!is_member_of($bbuserinfo, 5, 6, 7, 10, 12) AND !in_array($forumid, array(145,113,103,10,114,117,164,9,144,158))">
CPA LEAD
</if>

you might also want the thread starter to not see the gateway, in which case use:
<if condition="!is_member_of($bbuserinfo, 5, 6, 7, 10, 12) AND !in_array($forumid, array(145,113,103,10,114,117,164,9,144,158)) AND $thread['postuserid'] != $bbuserinfo['userid']">
CPA LEAD
</if>