|
|
|
||||
|
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() |
|
|||||||
| Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
|
Thread Tools |
|
|
#1 |
|
in a van by the river
Industry Role:
Join Date: May 2003
Posts: 76,806
|
SSI includes question for you server guys
question for you server tech guys..
I'm working on a lot of sites for SE stuff and I'm trying to simplify my work in adding new links for in the future. I was planning on adding my text links on these pages via SSI includes. Well simply put, will having a lot of pages with SSI includes hurt my server preformance? Also I'll admit I don't know much about .PHP but would I be better off doing the pages in PHP and using PHP includes? I know my way around windows machines but when it comes to unix servers and server loads and so on I'm clueless.. ![]()
__________________
In November, you can vote for America's next president or its first dictator. |
|
|
|
|
|
#2 |
|
G F Y not
Industry Role:
Join Date: Jan 2004
Location: MN
Posts: 2,910
|
Rename to .php and add the following line for inludes:
<?php require("includefile.txt"); ?> PHP performance is so fast you shouldn't notice any lag unless you've got like 80 includes per page that are all doing mathematical functions or database queries.
__________________
![]() TGPFactory Full TGP Design & Installation Services ICQ 250 142 484 · AIM TGPDynamix · Email: patrick (at) tgpfactory (dot) com See who I am at AdultWhosWho.com! |
|
|
|
|
|
#3 | |
|
in a van by the river
Industry Role:
Join Date: May 2003
Posts: 76,806
|
Quote:
__________________
In November, you can vote for America's next president or its first dictator. |
|
|
|
|
|
|
#4 |
|
DINO CORTEZ™
Industry Role:
Join Date: Jun 2003
Location: Vancouver Island
Posts: 2,145
|
Hi,
Each time you start a web process, it uses a sizeable chunk of resource overhead. Every server-side include (SSI) in a page requires a new process (like above) - try to keep the number of SSI's in a given page down to a minimum. On the other hand, a single SSI can do a pile of grunt work (including HD accesses/writes) without even warming up your box (if it's unix/linux). I use SSI extensively and without any performance issues (that is, after I distilled 13 SSIs/page down to 2 or 3 If you need help with SSI strategies, let me know - I'd be happy to help... -Dino |
|
|
|
|
|
#5 |
|
Confirmed User
Join Date: Oct 2002
Posts: 826
|
Dependind on how you call the SSI tag...
Most of my pages have 3-4 calls and I get close to 250k traffic per day on em... doesnt even slow my server down. |
|
|
|
|
|
#6 |
|
Confirmed User
Join Date: Mar 2004
Posts: 683
|
The more includes you have the more of a performance hit you will take .. but that performance hit can be almost completely illiminated by using PHP with a compiler cache.
Without a compiler cache I don't think using PHP would be faster than SSI.. but with the compiler cache all the includes would be performed once.. then the PHP script would compiled and cached so all your includes would essentially be run once every so often (when the cache expires) rather than on every single request ... which would virtually illiminate the overhead of having all those includes. |
|
|
|
|
|
#7 | |
|
in a van by the river
Industry Role:
Join Date: May 2003
Posts: 76,806
|
Quote:
I like the idea of doing the pages in PHP becouse I could make the pages a little more dnymanic that way. However I know almost nothing about PHP, but I can learn what ever I need to.. I'm just trying to do this right from the start, becouse I'm building these pages mostly by hand so I don't want to redo them anytime soon.
__________________
In November, you can vote for America's next president or its first dictator. |
|
|
|
|
|
|
#8 | |
|
DINO CORTEZ™
Industry Role:
Join Date: Jun 2003
Location: Vancouver Island
Posts: 2,145
|
Quote:
If most of your pages will be PHP, you may want to add it as the 'handler' for your '.htm/.html' type. This way you can use '.html' extensions (SEs don't have any problems HTML) but the pages (ALL of them - whether they have PHP in them) will be parsed for PHP. -Dino |
|
|
|
|
|
|
#9 | |
|
Confirmed User
Join Date: Mar 2004
Posts: 683
|
Quote:
You don't have to do anything manually except configure the cache once. Basically it interfaces with the Zend engine so that when a script is compiled it saves it and on future requests it uses the pre-copmiled script rather than re-compiling it every time someone requests the document, which is the way it works without the cache (and is why PHP is slower than using a compiled language like C). Another thing you can do.. if you want to be as SE-friendly as possible and have the benefit of a compiler cache without actually having to install and configure one is what I do on my TGPs.. I run php on the command line to generate static pages. So for example.. $ php -q main.php > index.html You can set that up with cron so that it runs once per day, or every 5 minutes or whatever you need to keep your site updating when it's supposed to. With this you have pretty much all the benefits of a compiler cache (the script is compiled more often than it would be with a cache but surfers get a static page which is faster than PHP no matter what - even with a cache) and you illiminate any SE un-friendliness that PHP might introduce. |
|
|
|
|
|
|
#10 | |
|
DINO CORTEZ™
Industry Role:
Join Date: Jun 2003
Location: Vancouver Island
Posts: 2,145
|
Quote:
A true HTML page is the best for SE. Even pages with .html extensions which are dynamically created can send HTTP headers which reveal the page was built on the fly (depending on how the server is configured). -Dino |
|
|
|
|