WebmasterSite.net: PHP scripts to enable your creativity
WSN Links PHP Directory Software
PHP Scripts Webmaster Links Support Forums


conditional error

Version: 1.3.4
printPrint


conditional error
sertan6
Experienced

Usergroup: Customer
Joined: Feb 22, 2004
Total Topics: 45
Total Posts: 83
Posted 11/08/06 - 10:01 AM:
quote post
#1
there is a bug when i use:

<IF {TID} contains displaylinks.tpl or {TID} contains suggestlink.tpl>
<br>
</IF>


error message:
--------------
If you are not the administrator of this site, please report this page to the administrator. If you are the administrator, please pay careful attention: You have a parse error in your template (or perhaps in your header or footer) which you need to repair before this page can be displayed correctly. The error is picked up on by php at line 31 of the output.
Warning: fopen(templates/default/): failed to open stream: Permission denied in d:\easyphp1-8\www\wsnforum\filefunctions.php on line 331

Warning: fclose(): supplied argument is not a valid stream resource in d:\easyphp1-8\www\wsnforum\filefunctions.php on line 334
Line #26: <?php } else { ?>
Line #27: <body>
Line #28: <?php } ?>
Line #29:
Line #30: <?php if (strstr(templates/default/viewcomments.tpl, "displaylinks.tpl" || "templates/default/viewcomments.tpl", "suggestlink.tpl")) { ?>
Line #31: <br>


Paul
Administrator
Avatar

Usergroup: Administrator
Joined: Dec 21, 2001
Location: Northern California
Total Topics: 55
Total Posts: 5703
Posted 11/10/06 - 07:26 PM:
quote post
#2
Multi-term conditionals can be problematic, use
<?php if (strstr("{TID}", "displaylinks.tpl") || strstr("{TID}", "suggestlink.tpl")) { ?>
<br>
<?php } ?>
sertan6
Experienced

Usergroup: Customer
Joined: Feb 22, 2004
Total Topics: 45
Total Posts: 83
Posted 11/13/06 - 07:53 AM:
quote post
#3
thanks Paul, this works perfect
Search thread for
Download thread as


You don't have permission to post.

Please login or register.

   
 
© 2008 Paul Knierim. All rights reserved.