Re: [PHP] Developer needed, right place for it?
On Thu, Dec 30, 2010 at 15:44, Bill Marcy bill.ma...@gmail.com wrote: Looking to get a bit of PHP work done, is this the right place for it, or is there a better place to ask? This is generally fine for one-off PHP requests, sure. We really need to get a jobs list up. I'll work on that, but in the meantime, go ahead and post the message here, Bill. -- /Daniel P. Brown Network Infrastructure Manager Documentation, Webmaster Teams http://www.php.net/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Developer needed, right place for it?
Hi Bill, I'm a senior PHP/Javascript/Actionscript 3 developer. If you need some PHP work done, contact me off-list and I can see what I can do for you. Regards, Tim ++Tim Hinnerk Heuer++ http://www.ihostnz.com On 31 December 2010 09:44, Bill Marcy bill.ma...@gmail.com wrote: Looking to get a bit of PHP work done, is this the right place for it, or is there a better place to ask? Bill
Re: [PHP] headers: setting right for browser to force reload at a certain point in time
German Geek wrote: Hi All, We have an application that generates dynamic ebooks. One of the (minor) problems (but yet annoying) is that when a user comes back to an ebook, they have to actually delete the cache and reload the page to not get the cached version which might be wrong because the content or even the flash application is updated. Deleting the cache should not be necessary, a reload should be enough. (it certainly is with Firefox). It would be neat if we could force a reload of the page, but only with a special condition like the ebook being updated or the swf. The swf and also the other resources are not reloaded though, because it is a get request. The request type has nothing to do with it - the browser will do a conditional GET if the local copy is expired. Just set the right expiry time on your files when you serve them, then they will automatically be checked by the browser. /Per -- Per Jessen, Zürich (2.8°C) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] headers: setting right for browser to force reload at a certain point in time
Yes, that's what i thought, but with my FF 3.0 the resources (swf,png,jpg) don't get reloaded. I have to reload the page (after deleting cache). Something to do with the Apache configuration? ?? Thanks for the reply. Tim-Hinnerk Heuer http://www.ihostnz.com Laurence J. Peter - If two wrongs don't make a right, try three. 2009/2/23 Per Jessen p...@computer.org German Geek wrote: Hi All, We have an application that generates dynamic ebooks. One of the (minor) problems (but yet annoying) is that when a user comes back to an ebook, they have to actually delete the cache and reload the page to not get the cached version which might be wrong because the content or even the flash application is updated. Deleting the cache should not be necessary, a reload should be enough. (it certainly is with Firefox). It would be neat if we could force a reload of the page, but only with a special condition like the ebook being updated or the swf. The swf and also the other resources are not reloaded though, because it is a get request. The request type has nothing to do with it - the browser will do a conditional GET if the local copy is expired. Just set the right expiry time on your files when you serve them, then they will automatically be checked by the browser. /Per -- Per Jessen, Zürich (2.8°C) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] headers: setting right for browser to force reload at a certain point in time
German Geek wrote: Yes, that's what i thought, but with my FF 3.0 the resources (swf,png,jpg) don't get reloaded. I have to reload the page (after deleting cache). Something to do with the Apache configuration? Hi Tim, Try loading up just a single file in FF - one of your graphics for instance - then hit Ctrl-i to get the info page. That will tell you exactly how FF sees the file - expiry time etc. /Per -- Per Jessen, Zürich (2.6°C) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] headers: setting right for browser to force reload at a certain point in time
2009/2/23 Per Jessen p...@computer.org German Geek wrote: Yes, that's what i thought, but with my FF 3.0 the resources (swf,png,jpg) don't get reloaded. I have to reload the page (after deleting cache). Something to do with the Apache configuration? Hi Tim, Try loading up just a single file in FF - one of your graphics for instance - then hit Ctrl-i to get the info page. That will tell you exactly how FF sees the file - expiry time etc. Hi Per, Thanks. But: This didn't work. ctrl+i brought up my bookmarks. ?? Do i need a special plugin/extension? Have web developer etc. I have Firebug but in the net tab the cached resources don't show up when reloading the page, i guess because they are not reloaded... So, i can't think of a way how to see that information when it is in cache. I had followed some examples on the web talking about the e-tag header which changes the checksum when the file changes, also i remember setting the expiry to yesterday and things like that... However it all didn't work. Anyway, i might just force a reload by changing the links every time dynamically, although it seems a bit overkill :-S. Tim-Hinnerk Heuer http://www.ihostnz.com P. J. O'Rourke - Everybody knows how to raise children, except the people who have them. /Per -- Per Jessen, Zürich (2.6°C) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] headers: setting right for browser to force reload at a certain point in time
German Geek wrote: This didn't work. ctrl+i brought up my bookmarks. ?? Do i need a special plugin/extension? Have web developer etc. Nope, this is standard FF. Ctrl+i should give you the Page Info window. Try looking for that in your menubar and pulldowns. -- Per Jessen, Zürich (3.1°C) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP Header] Right-Click Download in Firefox showing php filename
On 8/3/08, Will [EMAIL PROTECTED] wrote: @readfile($filename); You should look into a webserver and instead of using readfile() which will keep the PHP engine open while it is spoonfeeding the browser, offload the file to the webserver. nginx has X-Accel-Redirect (nginx is the best anyway) Lighttpd has X-Lighttpd-Sendfile (or something) Apache has mod_sendfile (something like that) etc. I don't think it will change the renaming behavior, but it will offload your PHP engines for normal processing. :) Basically (you'll have to configure it quick but otherwise) instead of the readfile($file) you'd be sending another: header(X-Accel-Redirect: $file); (you have to configure $file's location) and that's it. the webserver takes over and PHP is released back to do other things. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP Header] Right-Click Download in Firefox showing php filename
2008/8/4 Will [EMAIL PROTECTED]: I am trying to have users download a file named 'Setup.msi', however under a PHP file with the sent header information, the default name to $forcename = ApplicationSetup_v1_0.msi; $filename = Setup.msi; header(Content-Type: application/force-download); header(Content-Type: application/octet-stream; name=.$forcename); header(Content-Type: application/octetstream; name=.$forcename); header(Content-Transfer-Encoding: binary); header(Content-Length: .filesize($filename)); @readfile($filename); Try a variation on this: header(Content-Type: application/x-msi); header(Content-Disposition: attachment; filename=\ApplicationSetup_v1_0.msi\; ); header(Content-Transfer-Encoding: binary); header(Content-Length: . filesize('Setup.msi')); readfile('Setup.msi'); http://www.mhonarc.org/~ehood/MIME/rfc2183.txt content-disposition controls what the browser should do with the file you're sending (open it or save it). filename suggests what the file should be saved as on the local system, when downloading as an attachment content-type is the mime-type of the file you're sending -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP Header] Right-Click Download in Firefox showing php filename
Thanks everyone. I looked into the Firefox browser forums/support and found that the Right-Click Save Link As does not send the header response, as it will take the file as-is. So in this example, it sees the 'download.php' and then takes that as the default name. It then starts the download of the file, which in turn gets the header information and starts downloading the 'Setup.msi'... but now under the name of 'download.php' -- Again to note in IE the Right-Click will get the header information including the Content-Disposition and THEN open the Save As window. In all browsers, the Left-Click works as normal as it processes the header information. My solution: With mod_rewrite under Apache. I know rewrite the 'download.php' file as default of 'ApplicationSetup.msi' -- So IF Right-Clicked in FF, the user defaults the link with the proper extension to Save As. Otherwise if Left-Clicked, the rewrite will run the 'download.php' and then prompt with the correct MSI with version number (as intended) : 'ApplicationSetup_v1_0.msi' Otherwise with all the other header information, it works fine.. its just the browsers that DO NOT get the header info on a Right-Click Save As on objects, as they prompt to save in location BEFORE header info is sought. William Frankhouser WilzDezign On Mon, Aug 4, 2008 at 2:40 AM, David Otton [EMAIL PROTECTED] wrote: 2008/8/4 Will [EMAIL PROTECTED]: I am trying to have users download a file named 'Setup.msi', however under a PHP file with the sent header information, the default name to $forcename = ApplicationSetup_v1_0.msi; $filename = Setup.msi; header(Content-Type: application/force-download); header(Content-Type: application/octet-stream; name=.$forcename); header(Content-Type: application/octetstream; name=.$forcename); header(Content-Transfer-Encoding: binary); header(Content-Length: .filesize($filename)); @readfile($filename); Try a variation on this: header(Content-Type: application/x-msi); header(Content-Disposition: attachment; filename=\ApplicationSetup_v1_0.msi\; ); header(Content-Transfer-Encoding: binary); header(Content-Length: . filesize('Setup.msi')); readfile('Setup.msi'); http://www.mhonarc.org/~ehood/MIME/rfc2183.txt content-disposition controls what the browser should do with the file you're sending (open it or save it). filename suggests what the file should be saved as on the local system, when downloading as an attachment content-type is the mime-type of the file you're sending -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Getting the right path output from $_SERVER
On Mon, May 22, 2006 12:12 am, Dave M G wrote: What I am trying to achieve is to output the path in which the current script is executing, without having the name of the file attached. I'm hoping to be able to do this without complicated code to truncate path names and whatnot. Either of these two variables do what I want, except that they include the name of the file: $_SERVER[PHP_SELF] $_SERVER[SCRIPT_NAME] For example, if create file called test.php and I echo the output of $_SERVER[PHP_SELF], I get: /web_sites/gutteridge.info/web/test.php But all I want is: /web_sites/gutteridge.info/web (It's important that the last forward slash not be there). I would have thought that an existing global variable would exist to do this, but I can't find it in the php manual: http://www.php.net/manual/en/reserved.variables.php $_SERVER[DOCUMENT_ROOT] provides a path without the file name, but it's not the path I need. In my case, the output is: /var/www $_SERVER[PATH_TRANSLATED] also provides a different path, and also attaches the file name: /var/www/web_sites/gutteridge.info/web/test.php The bottom line is, how can I get the same path as $_SERVER[PHP_SELF] or $_SERVER[SCRIPT_NAME], but without including the file name? Thank you for any advice. http://php.net/dirname -- Like Music? http://l-i-e.com/artists.htm -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Getting the right path output from $_SERVER
Dave M G wrote: PHP General, What I am trying to achieve is to output the path in which the current script is executing, without having the name of the file attached. I'm hoping to be able to do this without complicated code to truncate path names and whatnot. Either of these two variables do what I want, except that they include the name of the file: $_SERVER[PHP_SELF] $_SERVER[SCRIPT_NAME] For example, if create file called test.php and I echo the output of $_SERVER[PHP_SELF], I get: /web_sites/gutteridge.info/web/test.php But all I want is: /web_sites/gutteridge.info/web (It's important that the last forward slash not be there). I would have thought that an existing global variable would exist to do this, but I can't find it in the php manual: http://www.php.net/manual/en/reserved.variables.php $_SERVER[DOCUMENT_ROOT] provides a path without the file name, but it's not the path I need. In my case, the output is: /var/www $_SERVER[PATH_TRANSLATED] also provides a different path, and also attaches the file name: /var/www/web_sites/gutteridge.info/web/test.php The bottom line is, how can I get the same path as $_SERVER[PHP_SELF] or $_SERVER[SCRIPT_NAME], but without including the file name? use dirname(). http://www.php.net/dirname -- Postgresql php tutorials http://www.designmagick.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] learning to right objects
On Wed, 11 Aug 2004 16:35:33 -0500, Blake Schroeder [EMAIL PROTECTED] wrote: I am trying to change some of my functions in to classes and objects. I have been checking out the php.net and google and still not grasping the concept. here is my example all I am trying to do is print 2 numbers to the browser that are randomly generated from dieRolls. Thanks in advance -Blake class dieRolls{ function dieRolls($die){ $num = rand(1, $die); You're storing this value in a local var, not an object property. Try: $this-num = rand(1, $die); $this-num; This does nothing as $this-num is not set (see above) and you're not *doing* anything with it. } } $num1 = new dieRolls(6); $num2 = new dieRolls(8); $bar1 = $num1-bar1; $bar2 = $num2-bar2; I don't know what you think these two lines are doing. You never set bar1 or bar2, so you'r enot going to get anything. echoHibr\n; echo$bar1br\n; echo$bar2br\n; I would suggest using this (after fixing the first problem I pointed out): echo $num1-num.br/\n; echo $num2-num.br/\n; -- DB_DataObject_FormBuilder - The database at your fingertips http://pear.php.net/package/DB_DataObject_FormBuilder paperCrane --Justin Patrin-- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] learning to right objects
Justin Thank you now I have a working example to go from. Justin Patrin wrote: On Wed, 11 Aug 2004 16:35:33 -0500, Blake Schroeder [EMAIL PROTECTED] wrote: I am trying to change some of my functions in to classes and objects. I have been checking out the php.net and google and still not grasping the concept. here is my example all I am trying to do is print 2 numbers to the browser that are randomly generated from dieRolls. Thanks in advance -Blake class dieRolls{ function dieRolls($die){ $num = rand(1, $die); You're storing this value in a local var, not an object property. Try: $this-num = rand(1, $die); $this-num; This does nothing as $this-num is not set (see above) and you're not *doing* anything with it. } } $num1 = new dieRolls(6); $num2 = new dieRolls(8); $bar1 = $num1-bar1; $bar2 = $num2-bar2; I don't know what you think these two lines are doing. You never set bar1 or bar2, so you'r enot going to get anything. echoHibr\n; echo$bar1br\n; echo$bar2br\n; I would suggest using this (after fixing the first problem I pointed out): echo $num1-num.br/\n; echo $num2-num.br/\n; -- +-+-++ | Blake Schroeder | Owner/Developer |lhwd.net| +--(http://www.lhwd.net)+--/3174026352\--+ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OMG your right ... $REMOTE_ADDR don't work in Samber 5.1, PHP4
Philip J Newman wrote: OK yah, this is a pain in the butt, $REMOTE_ADDR Dose not work in Sambar 51 Anyone have anyone have any solutions that can be used insteard? Whenever you have a problem like this run phpinfo(); and have a look at the available environment variables Useing print_r($HTTP_SERVER_VARS); can be very helpful as well -- PHP General Mailing List (http://wwwphpnet/) To unsubscribe, visit: http://wwwphpnet/unsubphp
Re: [PHP] OMG your right ... $REMOTE_ADDR don't work in Samber 5.1, PHP4
Is this a server thing, becuse I have just updated the server, and I used to use it all ver the site and it worked ... is there anything else that could do the job of $REMOTE_ADDR ? I run the windows isapi 4.0.5 on Sambar 5.1 if that healps - Original Message - From: Simon Willison [EMAIL PROTECTED] To: Philip J. Newman [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Friday, March 01, 2002 11:15 AM Subject: Re: [PHP] OMG your right ... $REMOTE_ADDR don't work in Samber 5.1, PHP4 Philip J. Newman wrote: OK yah, this is a pain in the butt, $REMOTE_ADDR Dose not work in Sambar 5.1. Anyone have anyone have any solutions that can be used insteard? Whenever you have a problem like this run phpinfo(); and have a look at the available environment variables. Useing print_r($HTTP_SERVER_VARS); can be very helpful as well. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] getting the right REMOTE_ADDR
I don't know too much about this, but IP checking is not a reliable way of identification anyway. Depending on how people connect to the internet, some people will have different IPs every time. Since I use a cable modem, my IP address rarely changes (if ever) so I use it as a safety net to prevent other users from accessing my files. Steven J. Walker Walker Effects www.walkereffects.com [EMAIL PROTECTED] On Wednesday, February 20, 2002, at 08:28 PM, [EMAIL PROTECTED] wrote: Hi all, I need to know the exact ip of who is entering a site and I'm worried about proxies and spoofing. From php.net: http://www.php.net/manual/en/function.getenv.php This was listed: This gives you the right ip: if (getenv(HTTP_CLIENT_IP)){ $ip=getenv(HTTP_CLIENT_IP); } else { $ip=getenv(REMOTE_ADDR); } Is this really a fool-proof method of knowing exactly what the ip is that's getting onboard? Thanks! Sean --- I N T E R C O N N E C T Internet Image Development Tel: 505 989 3749 http://www.InterConnect.is.it --- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] getting the right REMOTE_ADDR
My problem is a touch different, I know the IP's of the visitors who can visit the site, but I need to make sure that it's *really* them. Cookies are a potential solution, but don't quite fit the bill due to some variables on the users sides - and what I'm really keeping out are bots (that break in), not people. I've tested for: $HTTP_CONNECTION (Keep-Alive means not a robot - right?) $HTTP_REFERER (can't fake this if you're a robot...?) $HTTP_ACCEPT_LANGUAGE (Only comes along with browsers... yea?) In short, I need to make sure that only humans (who are on the IP list) can view content... and I wanted to make sure that bots couldn't spoof their IP and look like one of the human IP's. make sense? thanks, Sean -Original Message- From: Steven Walker [mailto:[EMAIL PROTECTED]] I don't know too much about this, but IP checking is not a reliable way of identification anyway. Depending on how people connect to the internet, some people will have different IPs every time. Since I use a cable modem, my IP address rarely changes (if ever) so I use it as a safety net to prevent other users from accessing my files. Steven J. Walker Walker Effects www.walkereffects.com [EMAIL PROTECTED] On Wednesday, February 20, 2002, at 08:28 PM, [EMAIL PROTECTED] wrote: Hi all, I need to know the exact ip of who is entering a site and I'm worried about proxies and spoofing. From php.net: http://www.php.net/manual/en/function.getenv.php This was listed: This gives you the right ip: if (getenv(HTTP_CLIENT_IP)){ $ip=getenv(HTTP_CLIENT_IP); } else { $ip=getenv(REMOTE_ADDR); } Is this really a fool-proof method of knowing exactly what the ip is that's getting onboard? Thanks! Sean -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] getting the right REMOTE_ADDR
You lost me... but it sounds like fun! :) BTW, can anything fake $HTTP_REFERER? I'm sure one of the pros on the list can answer your original question: Is this really a fool-proof method of knowing exactly what the ip is if (getenv(HTTP_CLIENT_IP)){ $ip=getenv(HTTP_CLIENT_IP); } else { $ip=getenv(REMOTE_ADDR); } Steven J. Walker Walker Effects www.walkereffects.com [EMAIL PROTECTED] On Wednesday, February 20, 2002, at 10:56 PM, [EMAIL PROTECTED] wrote: My problem is a touch different, I know the IP's of the visitors who can visit the site, but I need to make sure that it's *really* them. Cookies are a potential solution, but don't quite fit the bill due to some variables on the users sides - and what I'm really keeping out are bots (that break in), not people. I've tested for: $HTTP_CONNECTION (Keep-Alive means not a robot - right?) $HTTP_REFERER (can't fake this if you're a robot...?) $HTTP_ACCEPT_LANGUAGE (Only comes along with browsers... yea?) In short, I need to make sure that only humans (who are on the IP list) can view content... and I wanted to make sure that bots couldn't spoof their IP and look like one of the human IP's. make sense? thanks, Sean -Original Message- From: Steven Walker [mailto:[EMAIL PROTECTED]] I don't know too much about this, but IP checking is not a reliable way of identification anyway. Depending on how people connect to the internet, some people will have different IPs every time. Since I use a cable modem, my IP address rarely changes (if ever) so I use it as a safety net to prevent other users from accessing my files. On Wednesday, February 20, 2002, at 08:28 PM, [EMAIL PROTECTED] wrote: Hi all, I need to know the exact ip of who is entering a site and I'm worried about proxies and spoofing. From php.net: http://www.php.net/manual/en/function.getenv.php This was listed: This gives you the right ip: if (getenv(HTTP_CLIENT_IP)){ $ip=getenv(HTTP_CLIENT_IP); } else { $ip=getenv(REMOTE_ADDR); } Is this really a fool-proof method of knowing exactly what the ip is that's getting onboard? Thanks! Sean -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Getting the right hour?
On Thu, 4 Oct 2001 07:38, Jay Paulson wrote: I am trying to get the right hour using php's date() function. However, I don't know how to set the clock on my redhat machine via command prompt. I keep getting 18 for the hour and it should be 17. Anyone know how to set the time on the machine correctly? Thanks, jay man date ?? -- David Robley Techno-JoaT, Web Maintainer, Mail List Admin, etc CENTRE FOR INJURY STUDIES Flinders University, SOUTH AUSTRALIA All dogs go to heaven. Cats watch them leave. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Am I right or wrong?
My ISP has a limit on my site of 10,000MB of data transfer per month. 4 days into september and I'm already at 2,500MB. It would seem they're including requests by their own PHP server. I have a folder of ~80kb images that are dynamically resized using PHP into ~1.4kb thumbnails. Now for each one the PHP server sends an HTTP request for the 80kb image, and this is being counted against my 10,000MB. Should it? Am I in the right in thinking that it shouldn't? regards, Everybody will always try to screw you some way or another... Always look at the small print ;) And you're right... it's wrong of them... imho. -- Stig-Ørjan Smelror Systemutvikler Linux Communications AS Sandakerveien 48b Box 1801 - Vika N-0123 Oslo, Norway tel. +47 22 09 28 80 fax. +47 22 09 28 81 http://www.lincom.no/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Am I right or wrong?
It's wrong of them?!?! Not to sound irrational here, but you're DOWNLOADING the file every time, even if you are downloading it every time. Why are you opening it through HTTP? Why not directly via the FS? If you're local to the machine, that seems more intelligent. If you're not local to the machine then you're using not only CPU resource, but network resource, and even more so should be responsible. It is very difficult for an ISP to differentiate between what was an external request and what was you requesting something from yourself. Even if it was simple, I'm not sure they have any obligation or responsibility to do it. Regards, Cristopher Daniluk President CEO email: [EMAIL PROTECTED] direct: 330/530-2373 Digital Services Network, Inc Unleashing Your Potential voice: 800/845-4822 web: http://www.dsnet.net/ -Original Message- From: Stig-Ørjan Smelror [mailto:[EMAIL PROTECTED]] Sent: Monday, September 03, 2001 8:33 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: [PHP] Am I right or wrong? My ISP has a limit on my site of 10,000MB of data transfer per month. 4 days into september and I'm already at 2,500MB. It would seem they're including requests by their own PHP server. I have a folder of ~80kb images that are dynamically resized using PHP into ~1.4kb thumbnails. Now for each one the PHP server sends an HTTP request for the 80kb image, and this is being counted against my 10,000MB. Should it? Am I in the right in thinking that it shouldn't? regards, Everybody will always try to screw you some way or another... Always look at the small print ;) And you're right... it's wrong of them... imho. -- Stig-Ørjan Smelror Systemutvikler Linux Communications AS Sandakerveien 48b Box 1801 - Vika N-0123 Oslo, Norway tel. +47 22 09 28 80 fax. +47 22 09 28 81 http://www.lincom.no/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Am I right or wrong?
On Tue, 4 Sep 2001, Seb Frost wrote: I have a folder of ~80kb images that are dynamically resized using PHP into ~1.4kb thumbnails. Now for each one the PHP server sends an HTTP request for the 80kb image, and this is being counted against my 10,000MB. Should it? Am I in the right in thinking that it shouldn't? So, your PHP scripts are on one server, and your big images are on a separate server? If so, you are generating traffic between the two servers ... at which point you need to consult your service contract. Your contract should tell you for what traffic (including between which servers, across which networks) you will be billed. It's kind of strict to charge for traffic across a local network ... I wish you luck fighting your ISP if the contract doesn't define for which traffic you'll be billed. Aside from the ISP issue ... dynamically resizing 80K images on the fly is frightful thing. Creating thumbnails [once/at regular intervals] would be a wise step to take. It takes the load off the web server and will cut your network traffic. The tradeoff is disk space usage ... but you can store 57 1.4KB thumbnails in the same space as one 80KB image :) Good trade! ~Chris /\ \ / Pine Ribbon Campaign Microsoft Security Specialist X Against Outlook The moron in Oxymoron. / \ http://www.thebackrow.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Am I right or wrong?
Hmmm, I suppose the files and the php server may be on different machines - hadn't thought of that :-) I guess I need to make a compromise on my script then. - seb -Original Message- From: Chris Wesley [mailto:[EMAIL PROTECTED]]On Behalf Of Christopher William Wesley Sent: 04 September 2001 01:59 To: Seb Frost Cc: [EMAIL PROTECTED] Subject: Re: [PHP] Am I right or wrong? On Tue, 4 Sep 2001, Seb Frost wrote: I have a folder of ~80kb images that are dynamically resized using PHP into ~1.4kb thumbnails. Now for each one the PHP server sends an HTTP request for the 80kb image, and this is being counted against my 10,000MB. Should it? Am I in the right in thinking that it shouldn't? So, your PHP scripts are on one server, and your big images are on a separate server? If so, you are generating traffic between the two servers ... at which point you need to consult your service contract. Your contract should tell you for what traffic (including between which servers, across which networks) you will be billed. It's kind of strict to charge for traffic across a local network ... I wish you luck fighting your ISP if the contract doesn't define for which traffic you'll be billed. Aside from the ISP issue ... dynamically resizing 80K images on the fly is frightful thing. Creating thumbnails [once/at regular intervals] would be a wise step to take. It takes the load off the web server and will cut your network traffic. The tradeoff is disk space usage ... but you can store 57 1.4KB thumbnails in the same space as one 80KB image :) Good trade! ~Chris /\ \ / Pine Ribbon Campaign Microsoft Security Specialist X Against Outlook The moron in Oxymoron. / \ http://www.thebackrow.net --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.274 / Virus Database: 144 - Release Date: 23/08/2001 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.274 / Virus Database: 144 - Release Date: 23/08/2001 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Am I right or wrong?
On 4 Sep 01, at 1:14, Seb Frost wrote: My ISP has a limit on my site of 10,000MB of data transfer per month. 4 days into september and I'm already at 2,500MB. It would seem they're including requests by their own PHP server. I have a folder of ~80kb images that are dynamically resized using PHP into ~1.4kb thumbnails. Now for each one the PHP server sends an HTTP request for the 80kb image, and this is being counted against my 10,000MB. Should it? Am I in the right in thinking that it shouldn't? I would think that, basically, it's their server and they can do pretty much whatever they like with it. If you don't like it you can attempt to change their policy or vote with your feed and move elsewhere. Just my opinion though. CYA, Dave --- Outback Queensland Internet - Longreach, Outback Queensland - Australia http://www.outbackqld.net.au mailto:[EMAIL PROTECTED] --- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] is this right
this doesn't work,how should it be done? insert into test (uid, companyUid) values(1, select uid from companysTable where company = Micrsoft); If you are using MySQL, it doesn't support sub selects... Chris
Re: [PHP] is this right
Jeremy Morano wrote: insert into test (uid, companyUid) values(1, select uid from companysTable where company = Micrsoft); insert into test (uid, companyUid) select 1,uid from companysTable where company = Micrsoft; I hope this works. HTH Wagner -- Madness takes its toll. Please have exact change. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] is CURL right for SSL post to payment processing Authenticate.net
Hi Tom Yep, php_curl is the way to go. I have used exactly the same method to connect to WorldPay. Check out php_curl on php.net. Cheers Peter Tom Beidler [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I'm wondering if anyone has experience using CURL and could advise if it's the best direction for creating a SSL to a payment processing service. I'm trying to connect an existing PHP form to a payment processing service called Authorize.net. Using there direct response method requires a Secure Socket which a thought meant to send from a secure form to their secure script which didn't work. Here's what I got from their tech support. The problem is that you can't send an HTML form POST when using Direct Response. You must write a script that creates an SSL connection directly with our server (port 443) and send the information to us through that connection. I do not know if this is possible through PHP but usually this is done with PERL, CGI, or ColdFusion. Please refer to the Developer's guide for more information: https://secure.authorize.net/docs Thank you for contacting our customer service group. I found some info about CURL, http://curl.haxx.se/, and it seems like it might do the trick. I was wondering if anyone has experience with this a can confirm that this is the best approach or give me some other direction. Thanks, Tom . Tom Beidler Orbit Tech Services 805.682.8972 (phone) 805.682.5833 (fax) [EMAIL PROTECTED] http://www.orbittechservices.com/ . -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]