Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
On 2005-06-08 17:14:58 -0500 (Wed, Jun), Michael Sullivan wrote: Each time I offload photos from my camera I create a directory for those photos and name it the date I offloaded them in mmddyy format. I then create a list of files in that directory (ex, if I offloaded pix today I would have called the directory 060805 and the list list060805.txt. There is also a file called list.txt that contains each of the list filenames on its own line. My VB program (and now my PHP script) opens list.txt and reads in a list filename and passes it to a subroutine which in turn opens the list filename and formats an HTML page with the 100x100 photos organized into tables by date. It then returns this page to the web browser requesting it. [...] If PHP is a server side scripting language, then why is mozilla requiring so much of my RAM memory and hard drive? Shouldn't all the work of generating the page be being done on bullet??? You did not said that you prepare the 'thumbnails' - small versions of the images. Thus, if you generate a page that includes 10 000 images (I suppose that they are really large images) then the client has to download all these images and shrink them for display. It will consume a lot of disk space, a lot of memory, a lot of CPU cycles, a lot of bandwidth. You should create smaller versions of your photos, for example by using the 'convert' program from ImageMagick package: mkdir thu; \ for x in *.jpg; do \ convert $x -thumbnail 200x200 -verbose thu/thu_$x; \ done and then, in the generated HTML you should make something like: a href=image.png img src=thu/thu_image.png height=200 width=200 alt=image.png / /a HTH. -- $ ls -lart /bin/ls: you must be root to use LART pgpiW6BPQlBon.pgp Description: PGP signature
Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
The images on the photoindex page are sized 100x100. They are miniatures. To get the full size picture one must first click on the miniature of the desired photo. I used Mikov Image Resizer for this... On Thu, 2005-06-09 at 09:01 +0200, Mariusz Pkala wrote: On 2005-06-08 17:14:58 -0500 (Wed, Jun), Michael Sullivan wrote: Each time I offload photos from my camera I create a directory for those photos and name it the date I offloaded them in mmddyy format. I then create a list of files in that directory (ex, if I offloaded pix today I would have called the directory 060805 and the list list060805.txt. There is also a file called list.txt that contains each of the list filenames on its own line. My VB program (and now my PHP script) opens list.txt and reads in a list filename and passes it to a subroutine which in turn opens the list filename and formats an HTML page with the 100x100 photos organized into tables by date. It then returns this page to the web browser requesting it. [...] If PHP is a server side scripting language, then why is mozilla requiring so much of my RAM memory and hard drive? Shouldn't all the work of generating the page be being done on bullet??? You did not said that you prepare the 'thumbnails' - small versions of the images. Thus, if you generate a page that includes 10 000 images (I suppose that they are really large images) then the client has to download all these images and shrink them for display. It will consume a lot of disk space, a lot of memory, a lot of CPU cycles, a lot of bandwidth. You should create smaller versions of your photos, for example by using the 'convert' program from ImageMagick package: mkdir thu; \ for x in *.jpg; do \ convert $x -thumbnail 200x200 -verbose thu/thu_$x; \ done and then, in the generated HTML you should make something like: a href=image.png img src=thu/thu_image.png height=200 width=200 alt=image.png / /a HTH. -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
On Thu, 9 Jun 2005, Michael Sullivan wrote: The images on the photoindex page are sized 100x100. They are miniatures. To get the full size picture one must first click on the miniature of the desired photo. I used Mikov Image Resizer for this... Not what you were looking for, but for the archives: Perhaps there is already a program that will do what you like? jigl - Jason's Image Gallery http://xome.net/projects/jigl/ Christopher Fisk -- Good morning, fellow employee. You'll notice that I am now a model worker. We should continue this conversation later, during the designated break periods. Sincerely, Homer Simpson. -- Homer Simpson Homer's Enemy -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
Try accessing the link with a different browser, use a text only one, like links or elinks, and see the result, this will get the result of the php script but won't show you the pictures, so, you'll know if the issue is the way firefox is dealing with the pictures. That program you mentioned to convert and resize, is a Windows one, isnt? So, you convert your images at Windows and then use the images on Linux? I would use Mariusz tip on using convert directly. On 6/9/05, Christopher Fisk [EMAIL PROTECTED] wrote: On Thu, 9 Jun 2005, Michael Sullivan wrote: The images on the photoindex page are sized 100x100. They are miniatures. To get the full size picture one must first click on the miniature of the desired photo. I used Mikov Image Resizer for this... Not what you were looking for, but for the archives: Perhaps there is already a program that will do what you like? jigl - Jason's Image Gallery http://xome.net/projects/jigl/ Christopher Fisk -- Good morning, fellow employee. You'll notice that I am now a model worker. We should continue this conversation later, during the designated break periods. Sincerely, Homer Simpson. -- Homer Simpson Homer's Enemy -- gentoo-user@gentoo.org mailing list -- Daniel da Veiga Computer Operator - RS - Brazil -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
Up until recently I didn't think there was a Linux driver for my camera, so while I was offloading the photos in Windows I went ahead and resized them too... On Thu, 2005-06-09 at 13:21 -0300, Daniel da Veiga wrote: Try accessing the link with a different browser, use a text only one, like links or elinks, and see the result, this will get the result of the php script but won't show you the pictures, so, you'll know if the issue is the way firefox is dealing with the pictures. That program you mentioned to convert and resize, is a Windows one, isnt? So, you convert your images at Windows and then use the images on Linux? I would use Mariusz tip on using convert directly. On 6/9/05, Christopher Fisk [EMAIL PROTECTED] wrote: On Thu, 9 Jun 2005, Michael Sullivan wrote: The images on the photoindex page are sized 100x100. They are miniatures. To get the full size picture one must first click on the miniature of the desired photo. I used Mikov Image Resizer for this... Not what you were looking for, but for the archives: Perhaps there is already a program that will do what you like? jigl - Jason's Image Gallery http://xome.net/projects/jigl/ Christopher Fisk -- Good morning, fellow employee. You'll notice that I am now a model worker. We should continue this conversation later, during the designated break periods. Sincerely, Homer Simpson. -- Homer Simpson Homer's Enemy -- gentoo-user@gentoo.org mailing list -- Daniel da Veiga Computer Operator - RS - Brazil -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
On Thu, 9 Jun 2005, Daniel da Veiga wrote: That program you mentioned to convert and resize, is a Windows one, isnt? So, you convert your images at Windows and then use the images on Linux? I would use Mariusz tip on using convert directly. jigl? No, it's a perl script that calls imagemagik and jhead. Or did you hit reply on my message and were talking about his message? Hard to follow a thread when you do that =) Christopher Fisk -- Calvin : I think we have got enough information now, don't you? Hobbes : All we have is one fact that you made up. Calvin : That's plenty. By the time we add an introduction, a few illustrations and a conclusion, it'll look like a graduate thesis. -- gentoo-user@gentoo.org mailing list
[gentoo-user] Question about Apache, PHP and where execution actually takes place
I have my server box (bullet) and my client box (baby). My wife and I take a lot of digital photos of our cats and post them on our website for friends and family to see. The page consists of sets of 100x100 photographs that can be enlarged if they are clicked on. I was using a VB6.0 program that I wrote to generate the page, but since Windows ME is becoming rather clunky and I'd rather use Linux to do everything I thought I'd try translating my program into PHP. Each time I offload photos from my camera I create a directory for those photos and name it the date I offloaded them in mmddyy format. I then create a list of files in that directory (ex, if I offloaded pix today I would have called the directory 060805 and the list list060805.txt. There is also a file called list.txt that contains each of the list filenames on its own line. My VB program (and now my PHP script) opens list.txt and reads in a list filename and passes it to a subroutine which in turn opens the list filename and formats an HTML page with the 100x100 photos organized into tables by date. It then returns this page to the web browser requesting it. This php script is on bullet in the directory where the lists are. In theory it should work. The first time I used mozilla on baby to go bullet (192.168.1.2:/members/michael/camera/picindex.php) my hard drive started going crazy. On this computer if the hard drive is busy nothing will work. I had to manually poweroff the computer and restart. I logged back in and tried it again, thinking that the first time something else was going on with baby. The same thing happened and I had to manually power down and restart. After I restarted again and logged back in I opened gnome-system-monitor and asked to see the Active Process report. Everything looked good. I opened mozilla to my new php script and watched as mozilla swelled up to take 623.3MB of RAM. This computer only has 256MB RAM with 512MB swap space. My question is this: If PHP is a server side scripting language, then why is mozilla requiring so much of my RAM memory and hard drive? Shouldn't all the work of generating the page be being done on bullet??? -- gentoo-user@gentoo.org mailing list
Re: [gentoo-user] Question about Apache, PHP and where execution actually takes place
--- Michael Sullivan [EMAIL PROTECTED] wrote: Process report. Everything looked good. I opened mozilla to my new php script and watched as mozilla swelled up to take 623.3MB of RAM. This computer only has 256MB RAM with 512MB swap space. My question is this: If PHP is a server side scripting language, then why is mozilla requiring so much of my RAM memory and hard drive? Shouldn't all the work of generating the page be being done on bullet??? Something about the (server) generated html is overloading mozilla (too much html or too many large images). Use wget to download the html and see what it looks like: wget http://192.168.1.2:/members/michael/camera/picindex.php Zac __ Discover Yahoo! Find restaurants, movies, travel and more fun for the weekend. Check it out! http://discover.yahoo.com/weekend.html -- gentoo-user@gentoo.org mailing list