Register Members List Search Today's Posts Mark Forums Read

Reply
 
Article Options
phpinclude tip (for running queries)
Black Vivi
Join Date: Dec 2002
Posts: 120

United Kingdom
by Black Vivi Black Vivi is offline 02 May 2003

the main problem with phpinclude is running queries, it runs them on every page, even if they're not needed...

using the following you can make it so tey're only ran on certain files:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

obviously you have to replace a few things (like the file path)

hope it helps some of you
Views: 2130
Reply With Quote
Comments
  #2  
Old 03 May 2003, 01:18
filburt1 filburt1 is offline
 
Join Date: Feb 2002
You need to use == or that will return true every time. Also $PHP_SELF is depreicated. Finally this is easier:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Or use PAPI if you want to be really simple.
Reply With Quote
  #3  
Old 03 May 2003, 07:54
Black Vivi's Avatar
Black Vivi Black Vivi is offline
 
Join Date: Dec 2002
Real name: Dominic
Originally Posted by filburt1
You need to use == or that will return true every time.
i always forget that for some reason...

Originally Posted by filburt1
Finally this is easier:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.
I find it easier to use the full path, seeing as for me it's quite short

Originally Posted by filburt1
Or use PAPI if you want to be really simple.
I don't like PAPI, one of my other admins would probably delete all of it, and i just think it's too long...
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Article Options

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


New To Site? Need Help?

All times are GMT. The time now is 19:47.

Layout Options | Width: Wide Color: