Re: [PHP] How to "download" a multi-part file at the "server" side?

2013-11-02 Thread Aziz Saleh
On Sat, Nov 2, 2013 at 1:03 PM, Ajay Garg wrote: > Hi all. > > 1. > I could have the proper "$_FILES["userfile"]["name"]" been echoed back, by > replacing >ContentBody cbFile = new > FileBody(file, "image/png"); > > with >

Re: [PHP] I am puzzled. Error on one site, no error on the other

2013-10-26 Thread Aziz Saleh
On Fri, Oct 25, 2013 at 8:27 PM, Stephen wrote: > Problem Situation > > I have two web sites on the same shared host. They share code for the > control panel. When executed for one site I get a warning (reproducible > always), but on the other there is no warning. > > One my home server, set up i

Re: [PHP] date time problem

2013-10-06 Thread Aziz Saleh
am i getting an hour value in this case? > > jg > > > On Oct 6, 2013, at 7:14 PM, Aziz Saleh wrote: > > Jim, > > The date method takes in a timestamp (not seconds away). > > You have the seconds, you will need to manually convert those seconds to > what you desire

Re: [PHP] date time problem

2013-10-06 Thread Aziz Saleh
Jim, The date method takes in a timestamp (not seconds away). You have the seconds, you will need to manually convert those seconds to what you desire (minutes = seconds / 60), (hours = minutes / 60), etc.. Aziz On Sun, Oct 6, 2013 at 7:07 PM, Farzan Dalaee wrote: > Its so freaky > > Best Reg

Re: [PHP] Algorithm Help

2013-10-01 Thread Aziz Saleh
DB or flatfile? I would create a matrix of all kids crossed with every kid. Everytime a kid is put in a home with another kid, ++ that index. When dispatching kids, sort by index ASC. Aziz On Tue, Oct 1, 2013 at 3:01 PM, John Meyer wrote: > On 10/1/2013 12:51 PM, Floyd Resler wrote: > >> Here'

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-10-01 Thread Aziz Saleh
Hey Tim, It seems that deleteObject takes in 2 params, and you are sending it 1 param. I would recommend you look at the documentation and make sure you are sending the right params. Aziz On Sun, Sep 29, 2013 at 10:29 PM, Tim Dunphy wrote: > Hi Aziz, > > Thank you for getting back to me! > >

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Aziz Saleh
36): call_user_func_array(Array, Array) #3 > /var/www/awssdk/delete_bucket.php(72): CFRuntime->__call('deleteObject', > Array) #4 /var/www/awssdk/delete_bucket.php(72): > AmazonS3->deleteObject(Array) #5 {main} thrown in > /var/www/awssdk/services/s3.class.php on line 548 >

Re: [PHP] delete S3 bucket with AWS PHP SDK

2013-09-29 Thread Aziz Saleh
Hi Tim, Is the call working? Does it actually get deleted? This could just be an issue (which I see alot) where developers do not check for variables or preset them before usage, causing those notices to come up (pretty harmless most of the times). Aziz On Sun, Sep 29, 2013 at 12:30 PM, Tim Du

Re: [PHP] Switch Statement

2013-09-29 Thread Aziz Saleh
What is the output? On Sun, Sep 29, 2013 at 1:34 AM, Ethan Rosenberg < erosenb...@hygeiabiomedical.com> wrote: > On 09/28/2013 10:53 PM, Aziz Saleh wrote: > >> Ethan, can you do a var_dump instead of print_r. It might be that >> next_step >> has spaces in it c

Re: [PHP] Switch Statement

2013-09-28 Thread Aziz Saleh
Ethan, can you do a var_dump instead of print_r. It might be that next_step has spaces in it causing the switch to not match. Aziz On Sat, Sep 28, 2013 at 10:33 PM, Ethan Rosenberg < erosenb...@hygeiabiomedical.com> wrote: > Dear List - > > I have a working program. I made one change in a swit

Re: [PHP] Sending PHP mail with Authentication

2013-09-25 Thread Aziz Saleh
Usually if I am using a framework I would use the SMTP library associated with it. If it doesn't have one, I use phpmailer, fast and easy to setup: http://phpmailer.worxware.com/index.php?pg=examplebsmtp Aziz On Wed, Sep 25, 2013 at 4:11 PM, dealTek wrote: > Hi All, > > Semi newbie email ques

Re: [PHP] No MIME-Type in "imap_fetch_overview()"

2013-09-23 Thread Aziz Saleh
What Niklaus wishes for is a way to detect if an email message contains an attachment by just reading the headers (correct me if I am wrong). This isn't really a PHP issue. In any language you can't really figure out if an email has an attachment by just looking at the headers, you need to check t

Re: [PHP] Problem with mbstring.internal_encoding, mcrypt and php-fpm

2013-09-23 Thread Aziz Saleh
Hristo, Try changing the php.ini config: mbstring.func_overload 0 See if that helps your issue, more on what it does: http://php.net/manual/en/mbstring.overload.php Aziz On Mon, Sep 23, 2013 at 8:23 AM, Condor wrote: > > Hello, > > from two days I have strange problem with this param > mbst

Re: [PHP] Friday's Question

2013-09-20 Thread Aziz Saleh
Haha, like your product usage chart Tedd, Age: 31 Mousepad: Webster New Dictionary of Synonyms, too lazy of having to go to Microcenter and buy one! Aziz On Fri, Sep 20, 2013 at 12:58 PM, Larry Martell wrote: > On Fri, Sep 20, 2013 at 10:51 AM, Tedd Sperling wrote: > > Hi gang: > > > > Do yo

Re: [PHP] Static methods vs. plain functions

2013-09-19 Thread Aziz Saleh
I think that it would be more elegant if you are already in a OOP to keep the flow and stick to OOP. It just doesn't make sense to me in an environment that uses OOP to have functions laying around. Personally I like to group similar functionality together in their own objects, this way I can reus

Re: [PHP] Apache's PHP handlers

2013-09-19 Thread Aziz Saleh
The best way to handle file uploads is to: 1) Store the filename somewhere in the DB, rename the file to a random string without extension and store the mapping in the DB as well. 2) When sending the file, set the header content to the filename and output the content of the file via PHP (ex: by re