FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Re: Windows binaries 64bit for PHP
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Windows binaries 64bit for PHP [message #178240 is a reply to message #178239] Thu, 24 May 2012 10:00 Go to previous messageGo to previous message
Shake is currently offline  Shake
Messages: 40
Registered: May 2012
Karma:
Member
El 24/05/2012 11:40, Stig Vestøl escribió:
>
> That was the point i was trying to make. If performance is an issue, let
> apache serve the images.
> The overhead of using PHP to check if an image exists before sending it
> on every request is huge.

There is no need to check every request.

Check the process:

Supose that the images are on the home of the image gallery:

GET /Index.php -> served by PHP (by Apache) *
GET /scaleY/image1.png -> served by Apache (or LIGHTTP) **
GET /scaleY/image2.png -> served by Apache (or LIGHTTP) **
GET /scaleY/image3.png -> served by Apache (or LIGHTTP) **
GET /scaleY/image4.png -> served by Apache (or LIGHTTP) **
GET /scaleY/image5.png -> served by Apache (or LIGHTTP) **

*
Index.php check image files... If one of the images doesn't exists, it
generates.
If all images exists, no matters. Anyway PHP have to process index.php
so there is no overhead beyond a "if(file_exists))" in a foreach of images.

**
no PHP needed, images here had been always created.


Can anyone access to "/scaleY/image5.png" directly ? how? from where he
get the address?

From google? (google have to had visited the index.php) Or other search
engine? (IDEM).

Rgds.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: is_dir true from cli, false from Apache
Next Topic: in_array performance in unsorted vs sorted array
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Tue Nov 26 19:43:34 GMT 2024

Total time taken to generate the page: 0.04255 seconds