You are missing our premiere tool bar navigation system! Register and use it for FREE!

NukeCops  
•  Home •  Downloads •  Gallery •  Your Account •  Forums • 
Readme First
- Readme First! -

Read and follow the rules, otherwise your posts will be closed
Modules
· Home
· FAQ
· Buy a Theme
· Advertising
· AvantGo
· Bookmarks
· Columbia
· Community
· Donations
· Downloads
· Feedback
· Forums
· PHP-Nuke HOWTO
· Private Messages
· Search
· Statistics
· Stories Archive
· Submit News
· Surveys
· Theme Gallery
· Top
· Topics
· Your Account
Who's Online
There are currently, 140 guest(s) and 0 member(s) that are online.

You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - Making PHPNuke more secure:A Way Forward [ ]
 Forum FAQ  •  Search  •   •  Memberlist  •  Usergroups   •  Register  •  Profile •    •  Log in to check your private messages  •  Log in

 
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next topic
Author Message
Tank863
Lieutenant
Lieutenant


Joined: Feb 21, 2003
Posts: 195

Location: Philadelphia

PostPosted: Mon Feb 23, 2004 9:27 am Reply with quoteBack to top

I went back through the code... reloaded a archived mainfile.php and redid it...

It worked this time without the errors.. don't know what wnet wrong last time...
Find all posts by Tank863View user's profileSend private messageVisit poster's websiteICQ Number
djmaze
Captain
Captain


Joined: Nov 29, 2003
Posts: 566

Location: Netherlands

PostPosted: Mon Feb 23, 2004 10:56 am Reply with quoteBack to top

steven111 wrote:
Caching is the next thing..... for example, function returning active modules does not change from on user to the next, and from one day to the next. This is not a good example, as the table is small, but on big tables and joins it start to make an impact.


What about caching IP or usergroup based ?

Cos there are users and users and both have different privileges on a website if a groups system is used.

A file where you can setup the caching would best i think.
For example
Code:

$blocks = array(
    "blocktitle" => "cachetime",
    "blocktitle" => "cachetime",
    "blocktitle" => "cachetime"
);
$module = array(
    "title" => "cachetime",
    "title" => "cachetime",
    "title" => "cachetime"
);

So you can setup how long a part has to be cached before it's cached again.
Then make differences in "anon" and "member"

then cachetime * anon = totaltime to cache block

For example
Code:

$membertime = 1;
$anonymtime = 10;
$blocks = array(
    "Survey" => "60" // 60 seconds
);
if (is_user($user)) {
    $cachetime = $blocks["Survey"] * $membertime;
} else {
    $cachetime = $blocks["Survey"] * $anonymtime;
}

if (filetime + $cachetime < time()) {
    cache again;
} else {
    echo cache;
}

_________________
Famous people never give their signature Rolling Eyes
http://www.cpgnuke.com <- back online thanks to dedicatednow.com
Don't ask me to be admin on your site please Exclamation
Find all posts by djmazeView user's profileSend private messageVisit poster's website
steven111
Lieutenant
Lieutenant


Joined: Dec 30, 2003
Posts: 283


PostPosted: Mon Feb 23, 2004 11:12 am Reply with quoteBack to top

Good one, dj. There are many areas in the code ripe for caching.

Also note that Raven and I have had extensive discussions on this, and there is code available as well, at http://www.ravenphpscripts.com/posts1033-highlightsteven.html%2A

steve
Find all posts by steven111View user's profileSend private messageVisit poster's website
Display posts from previous:      
Post new topic  Reply to topicprinter-friendly view
View previous topic Log in to check your private messages View next topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



Powered by phpBB © 2001, 2005 phpBB Group

Ported by Nuke Cops © 2003 www.nukecops.com
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::
Powered by TOGETHER TEAM srl ITALY http://www.togetherteam.it - DONDELEO E-COMMERCE http://www.DonDeLeo.com - TUTTISU E-COMMERCE http://www.tuttisu.it
Web site engine's code is Copyright © 2002 by PHP-Nuke. All Rights Reserved. PHP-Nuke is Free Software released under the GNU/GPL license.
Page Generation: 0.589 Seconds - 88 pages served in past 5 minutes. Nuke Cops Founded by Paul Laudanski (Zhen-Xjell)
:: FI Theme :: PHP-Nuke theme by coldblooded (www.nukemods.com) ::