PhotoPost Community

PhotoPost Community (http://www.photopost.com/forum/)
-   Photopost Pro How Do I...? (http://www.photopost.com/forum/photopost-pro-how-do-i/)
-   -   Condition statements in Templates? (http://www.photopost.com/forum/photopost-pro-how-do-i/132095-condition-statements-templates.html)

volarium June 5th, 2007 11:17 PM

Condition statements in Templates?
 
I'm trying to use vBulletin condition statements in the PhotoPost PRO and PhotoPost Classifieds custom1pal.tmpl files, but they don't seem to be working. My condition is:

Code:

Content visible to verified customers only.
However, it doesn't seem to check the condition statement, it always just prints the stuff. I'm assuming that the PhotoPost templates aren't able to utilize this vBulletin condition statement. Is that correct?

Is there another way to either turn the display of custom1pal.tmpl on or off based on the usergroup?

Chuck S June 6th, 2007 06:27 AM

You are correct you can not use vb conditionals in Photopost it is another completely different application.

Just for the sake of trying did you try this

$vbulletin->userinfo[usergroupid]

volarium June 6th, 2007 10:54 AM

Seems to just return the string "Array[usergroupid]". Maybe I'm not sure how to use it correctly in the template.

Basically, all I'm trying to do is display the custom pal only to certain usergroups. The reason for this is that my custom pal contains banner ads, and I want to turn OFF the banner ads for subscribers. Can you think of any other way to do this within PhotoPost? If not, not the end of the world. :-) Thanks!

Chuck S June 6th, 2007 11:29 AM

You probally want to search vbulletin to see what might work since your really dealing with vbulletin conditionals maybe this

<if condition="in_array($vbulletin->userinfo[usergroupid], array(2,5,6))">The usergroups can see this html</if>

From a photopost perspective you would need to query and define the user's usergroups and define the permissions


All times are GMT -5. The time now is 12:07 PM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97