Results 1 to 5 of 5
Threaded View
-
4th Sep 2009, 01:44 PM #1OPMemberWebsite's:
Doxsters.netUsing Vbulletin Conditionals
Hi Guys,
Thought i'd write a tutorial on using vBulletin conditionals, i got some spare time
What is a conditional?
Basically, its an <if> tag that checks if something is true or not.
Whatever the conditional is wrapper around is only executed/seen if the condition is met, hence the name conditional
Some Common Conditionals:
First of all Note that these conditionals havent been found by me, etc. I just googled for em
Anyway hers a few that i find useful
Code:<if condition="is_member_of($vbulletin->userinfo, X, Y, Z)"></if>
Code:<if condition="THIS_SCRIPT == 'index'">
Code:define('THIS_SCRIPT', 'index');
Code:<if condition="$bbuserinfo['userid'] == 667">
Code:<if condition="in_array($forumid, array(X,Y,Z))">
Code:<if condition="$bbuserinfo['birthday_search'] > '1980-01-01'">
Code:<if condition="can_moderate($forum['X'])">
Code:<if condition="$threadinfo['postuserid'] == $bbuserinfo['userid']">
Code:<if condition="!$GLOBALS['FIRSTPOSTID']">
Else and Not
Okay now for something a little more complex. With all these conditionals you can use an <else> tag to execute different information if the condition isn't met.
So for example:
Code:<if condition="$bbuserinfo['birthday_search'] > '1980-01-01'"> <!---Adult section stuff here--> <else> Too Young </if>
There is also the ! character. If you put that infront of the =, the conditional will check if the condition is not met.
So for example
Code:<if condition="$bbuserinfo['userid'] != 667">
Some Common Screwups
I know i definately did this one a lot
Basically, Template Conditionals will only work in templates. Full Stop
I tried using em in bbcodes, was wondering why they didnt work
But yeah, now you know.
Finally got this finished, enjoy
-timtamboy63
Oh and let me know if u need any helptimtamboy63 Reviewed by timtamboy63 on . Using Vbulletin Conditionals Hi Guys, Thought i'd write a tutorial on using vBulletin conditionals, i got some spare time :) What is a conditional? Basically, its an <if> tag that checks if something is true or not. Whatever the conditional is wrapper around is only executed/seen if the condition is met, hence the name conditional Some Common Conditionals: First of all Note that these conditionals havent been found by me, etc. I just googled for em :P Anyway hers a few that i find useful Rating: 5
Need a Designer/Web Developer? Click Me
MSN: PM me for it.
Email(Preferred):timtamboy63@gmail.com
"Power Corrupts. Absolute Power Corrupts Absolutely"
Sponsored Links
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
[vBulletin] Understanding vBulletin Database Errors!6019+8.6
By Exel in forum Tutorials and GuidesReplies: 0Last Post: 10th Apr 2012, 12:11 AM -
upgrading nulled vbulletin to legal version of vbulletin
By radiking in forum vBulletinReplies: 6Last Post: 27th Sep 2011, 05:57 PM -
vBulletin Template Conditionals List
By jokerhacker in forum vBulletinReplies: 0Last Post: 30th Jul 2011, 10:54 PM -
Template Conditionals For VB4
By AmN in forum vBulletinReplies: 1Last Post: 16th Oct 2010, 02:03 PM -
FS Owned vBulletin License with vBulletin Blog
By JMaldo in forum Completed TransactionsReplies: 5Last Post: 19th Aug 2009, 10:58 PM
themaCreator - create posts from...
Version 3.47 released. Open older version (or...