The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
IF Condition for this?
I am trying to display something on specific pages only. Is there an IF like this?:
Example only: <if condition="url == http://example.com/example1.php"></if> |
#2
|
||||
|
||||
depending on where you put it you might want to try <IF THIS_SCRIPT == "index">
that will show whatever the code is on the index only. |
#3
|
|||
|
|||
I went to put it on specific members' profiles.
|
#4
|
|||
|
|||
There are ways to check the url - there's a $_SERVER variable that has that info in various forms. Here's a reference: http://php.net/manual/en/reserved.variables.server.php (maybe $_SERVER['PHP_SELF'] is what you're talking about).
However, it sounds like what you want is to check the user id, like Code:
<if condition="$bbuserinfo['userid']==X"> if you want to put something in a template that's also included in other pages you could do like BigJohnny said, Code:
<if condition="THIS_SCRIPT=='member' AND $bbuserinfo['userid']==X"> and if you also want to show it for a page that has a "do=" on the URL (but only for certain values), there's a way to do that, too. Code:
<if condition="$_REQUEST['do'] == 'something'> |
#5
|
|||
|
|||
Quote:
Also, I want this displayed on specific user profiles. However, I want it seen by every member. That's the reason why I need an IF. I intend to place it right under the username on certain profiles, like user ID 1, 5 and 7, yet seen by everybody. |
#6
|
|||
|
|||
Oh, I see now - my mistake. I think you want:
Code:
<if condition="$userinfo['userid'] == X"> |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|