php-general Digest 10 Nov 2008 13:00:54 -0000 Issue 5783
Topics (messages 283154 through 283169):
Re: PHP - Web/list Question...
283154 by: Jochem Maas
Re: strtotime
283155 by: Eric Butera
Re: It's Sunday, and I'm bored...
283156 by: Colin Guthrie
283160 by: Peter Ford
283163 by: Richard Heyes
283164 by: Richard Heyes
PHP / Procmail / MIME decoder, Imagemagick, MySQL, PDF fax management system
283157 by: Dan Harrington
283159 by: Ashley Sheridan
283161 by: Richard Heyes
283162 by: Ashley Sheridan
283165 by: Richard Heyes
283166 by: Colin Guthrie
283168 by: Richard Heyes
Managed VPS recommendations
283158 by: Larry Garfield
Re: PHP and Cyrus problem
283167 by: Emerson Virti
Re: Image Manipulation
283169 by: tedd
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[EMAIL PROTECTED]
----------------------------------------------------------------------
--- Begin Message ---
Stut schreef:
> On 9 Nov 2008, at 20:30, Robert Cummings wrote:
....
> Agreed, but IMHO lack of URL-sharing is just one of many reasons to
> avoid sessions if possible.
>
>> Taking further context though on my stream of responses... you did say:
>>
>> Seriously? You'd rather use sessions than explode, modify and
>> implode an array of numbers on each request?
>>
>> This suggests you thought my particular opinion to be ludicrous ;) As
>> such, I felt inclined to more strongly defend my stance.
>
> I should've explained the context of that reply. I was specifically
> referring to your assertion that "sessions are easier to manage". They
> are slightly easier than most alternatives for the developer, but they
> can quickly become a nightmare for the sysadmin.
I here by baptise you 'Stateless Stut' ;-)
... oh, I had a drinking session on friday ... it didn't make anything
easier ... especially not driving.
>
> -Stut
>
--- End Message ---
--- Begin Message ---
On Sun, Nov 9, 2008 at 3:50 PM, Ashley Sheridan
<[EMAIL PROTECTED]> wrote:
> On Sun, 2008-11-09 at 19:46 +0100, gilles wrote:
>> "Thodoris" <[EMAIL PROTECTED]> a crit dans le message de news:
>> [EMAIL PROTECTED]
>> > O/H Bastien Koert ??????:
>> >> 2008/11/8 Maciek Sokolewicz <[EMAIL PROTECTED]>
>> >>
>> >>
>> >>> gilles wrote:
>> >>>
>> >>>
>> >>>> Avec la version 4 de php, strtotime("20080950") fonctionne correctement
>> >>>> en
>> >>>> allant sur le mois d'octobre, alors qu'en version 5: 19700101.
>> >>>> Merci de votre aide
>> >>>>
>> >>>>
>> >>>>
>> >>> This is an ENGLISH list, please rephrase your question in english and
>> >>> people might understand.
>> >>>
>> >>> Cette liste est une liste anglaise, reformulent svp votre question en
>> >>> anglais svp.
>> >>>
>> >>> merci,
>> >>>
>> >>> - Tul
>> >>>
>> >>>
>> >>> --
>> >>> PHP General Mailing List (http://www.php.net/)
>> >>> To unsubscribe, visit: http://www.php.net/unsub.php
>> >>>
>> >>>
>> >>>
>> >> I'll translate
>> >>
>> >> In PHP4, strtotime works fine
>> >>
>> >
>> > Define "works fine".
>> >
>> >> in PHP5 strtotime gives a result of 19700101 when the data entered was
>> >> strtotime("20080950")
>> >>
>> >>
>> >
>> > Linux
>> > PHP version 5.1.6
>> > Apache 2
>> >
>> > This strtotime("20080950") returns nothing.
>> >
>> > ---
>> > Thodoris
>> "Works fine" in php4 means date("d/m/Y",strtotime("20080950")) returns
>> 20/10/2008, which is correct.
>> Thanks
>>
>>
>>
> Which is actually incorrect (I've never seen the 50th of September) and
> it was fixed in PHP 5. What you are assuming is correct behaviour is
> actually a bug.
>
>
> Ash
> www.ashleysheridan.co.uk
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
I didn't read this thread (sorry) but I wonder if timezone/locale
might be the culprit.
--- End Message ---
--- Begin Message ---
Jochem Maas wrote:
you're not 'loose' the asylum is just bigger than you realise ... most people
know it by it's other name ... Earth.
Yeah the "outside" of the Asylum is pretty small... if you don't
believe me, ask Wonko the Sane...
So long :p
Col
--
Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/
Day Job:
Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
Mandriva Linux Contributor [http://www.mandriva.com/]
PulseAudio Hacker [http://www.pulseaudio.org/]
Trac Hacker [http://trac.edgewall.org/]
--- End Message ---
--- Begin Message ---
Govinda wrote:
>
> On Nov 9, 2008, at 12:28 PM, Richard Heyes wrote:
>>
>> Subversion, or svn for short. Helps you maintain code bases. Far
>> better than regular backups (though by no means a replacement).
>
> I looked it over briefly and it looks smart for serious collaborated
> efforts.. but i ask - is anyone finding it makes sense for one-man shows?
> (For the time to get up to speed with this maybe I could just pay more
> attention to making/naming my own backups?)
>>
>>
>>> It's nice to have at least loose communities like this list so we solo
>>> freelancers don't think we're simply mad.
>>
>> You are... :-)
> Well yes, but I meant without company.. See when we are in a herd, then
> even if we're all mad, then somehow it seems alright. ;-) We even have
> professional looking tools to track which version of madness!
>
Absolutely - I use it for my (largely) solo projects. For one thing, not all
projects remain solo efforts - at least two of my recent projects have been big
enough to bring someone else in, and at that point if the stuff is all in SVN
then it's MUCH easier...
Also, I find that I can easily be a different "person" on another day, and want
to experiment with some refactoring or neat way of doing stuff. SVN gives me a
simple way to fall back to the previous stuff without too many headaches.
AND (this is probably most relevant to the original thread) when I commit code
to the repository, it asks for a comment to attach to the commit.
That's really useful (as I think Richard finds) when I come to do my timesheets,
which is usually less often than my commits...
Cheers
Pete
--
Peter Ford phone: 01580 893333
Developer fax: 01580 893399
Justcroft International Ltd., Staplehurst, Kent
--- End Message ---
--- Begin Message ---
> I looked it over briefly and it looks smart for serious collaborated
> efforts.. but i ask - is anyone finding it makes sense for one-man shows?
Absolutely. Change management and recording makes sense for any
development, whether it's one or a thousand people. An example is my
RGraph software. I use svn so I don't (and won't) remember what I've
changed between releases. It therefore helps to document said changes.
And documentation is goood...
> (For the time to get up to speed with this maybe I could just pay more
> attention to making/naming my own backups?)
Doing more backups is a very poor substitute.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November 1st)
--- End Message ---
--- Begin Message ---
> That's really useful (as I think Richard finds) when I come to do my
> timesheets,
Me? I don't do time sheets...
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November 1st)
--- End Message ---
--- Begin Message ---
Hello,
I have seen procmail and PERL, and some MIME handling scripts...but I
haven't seen PHP, Procmail, Mysql, and MIME handling to effectively handle
incoming emails. I don't know PERL, so naturally I'd like to see it all
written in stuff that I can understand and tweak if needbe.
I have a Fax to Email service that sends me emails with all my faxes. I
want to process and parse them as follows:
Fax >> multi-page PDFs >> My Email >> Procmail >> PHP / MIME decoder /
Imagemagick >> MySQL >> save PDF >> Imagemagick each page to preview
thumbnails.
The attachments would be stored (or links to attachments stored on file
system) along with main message stored in MySQL, and Imagemagick would make
thumbnails of each page of the multi-page PDFs.
I could then have my office assistant browse the messages by web browser,
add keywords, To/From, Subject, categories to each of the
messages,images,PDFs for later perusal and searching. And when I wanted to
go back a year ago and try to retrieve an old fax, it wouldn't be so hard.
:-)
Surely someone has done this, but I can't find it....and I'm too busy and
cowardly to write it myself :-)
Thanks
Dan
--- End Message ---
--- Begin Message ---
On Sun, 2008-11-09 at 21:50 -0700, Dan Harrington wrote:
> Hello,
>
> I have seen procmail and PERL, and some MIME handling scripts...but I
> haven't seen PHP, Procmail, Mysql, and MIME handling to effectively handle
> incoming emails. I don't know PERL, so naturally I'd like to see it all
> written in stuff that I can understand and tweak if needbe.
>
> I have a Fax to Email service that sends me emails with all my faxes. I
> want to process and parse them as follows:
> Fax >> multi-page PDFs >> My Email >> Procmail >> PHP / MIME decoder /
> Imagemagick >> MySQL >> save PDF >> Imagemagick each page to preview
> thumbnails.
>
> The attachments would be stored (or links to attachments stored on file
> system) along with main message stored in MySQL, and Imagemagick would make
> thumbnails of each page of the multi-page PDFs.
>
> I could then have my office assistant browse the messages by web browser,
> add keywords, To/From, Subject, categories to each of the
> messages,images,PDFs for later perusal and searching. And when I wanted to
> go back a year ago and try to retrieve an old fax, it wouldn't be so hard.
> :-)
>
> Surely someone has done this, but I can't find it....and I'm too busy and
> cowardly to write it myself :-)
>
> Thanks
> Dan
>
>
This may sound a bit of a strange question, but why put the fax in a
PDF? I mean, it's a bitmap graphic, so why not just leave it in a bitmap
format?
If that sounds strange, I'm the kind of person who gets annoyed at
people who put screenshots in MSWord documents!
Ash
www.ashleysheridan.co.uk
--- End Message ---
--- Begin Message ---
>> Surely someone has done this, but I can't find it....and I'm too busy and
>> cowardly to write it myself :-)
Then get your wallet out. If you want email handling (ie Mime
parsing), then the mimeDecode class in PEAR will do this, and put the
resulting data (attachments and all) in an array structure for you to
play with.
> If that sounds strange, I'm the kind of person who gets annoyed at
> people who put screenshots in MSWord documents!
Ahh MSWord. Unfortunately I'm stuck with OpenOffice for the time
being, [looks longingly in the direction of MSOffice]
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November 1st)
--- End Message ---
--- Begin Message ---
On Mon, 2008-11-10 at 09:21 +0000, Richard Heyes wrote:
> >> Surely someone has done this, but I can't find it....and I'm too busy and
> >> cowardly to write it myself :-)
>
> Then get your wallet out. If you want email handling (ie Mime
> parsing), then the mimeDecode class in PEAR will do this, and put the
> resulting data (attachments and all) in an array structure for you to
> play with.
>
> > If that sounds strange, I'm the kind of person who gets annoyed at
> > people who put screenshots in MSWord documents!
>
> Ahh MSWord. Unfortunately I'm stuck with OpenOffice for the time
> being, [looks longingly in the direction of MSOffice]
>
> --
> Richard Heyes
>
> HTML5 Graphing for FF, Chrome, Opera and Safari:
> http://www.rgraph.org (Updated November 1st)
>
Are you serious? I've switched to OOo and never looked back. Does
everything I need, and makes styling documents a hell of a lot easier.
Ash
www.ashleysheridan.co.uk
--- End Message ---
--- Begin Message ---
> Are you serious? I've switched to OOo and never looked back. Does
> everything I need, and makes styling documents a hell of a lot easier.
Absolutely, I've used MSWord for years and know it quite well. So
getting along with OpenOffice is just a pain. I'm not an MS zealot
though (believe it or not). For example I think Vista is the work of
the devil...
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November 1st)
--- End Message ---
--- Begin Message ---
Ashley Sheridan wrote:
This may sound a bit of a strange question, but why put the fax in a
PDF? I mean, it's a bitmap graphic, so why not just leave it in a bitmap
format?
Most fax systems I've seen deal with TIFF images but they can be in a
slightly weird format (missing lines, requiring stretching or something
like that). Putting the data into PDF is trivial (this is done
automatically by hylafax system IIRC).
Also it seems Dan's issue is not converting it in PDF format, as he gets
the data sent to him in PDF already.
For the email decoding, as Richard said, the PEAR MimeDecode classes do
a fair job of this.
Col
--
Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/
Day Job:
Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
Mandriva Linux Contributor [http://www.mandriva.com/]
PulseAudio Hacker [http://www.pulseaudio.org/]
Trac Hacker [http://trac.edgewall.org/]
--- End Message ---
--- Begin Message ---
> fair
Fair ?! It does an outstanding job! :-)
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November 1st)
--- End Message ---
--- Begin Message ---
OK, so maybe I'm not looking for a VPS per se but I suspect I am given the
requirements I have.
I am looking for a new web host, both for my personal work and on behalf of my
company. (Two separate entities entirely, but odds are I'll end up using the
same host for both just to make my life easier.) My specific requirements
relate to running medium to large PHP-based web sites. The host we've been
using at work is having trouble scaling up nicely, and I want to see what else
is out there.
Requirements are:
- Apache 2
+ Must include mod_rewrite, mod_deflate, and other modern tools
+ Must support at least 2 GB storage per account.
- MySQL 5 installed by default.
+ Must allow databases up to 1 GB in size at least. Larger would be even
nicer.
+ Must support remote database management (tunneled through SSH is OK).
+ Must allow InnoDB tables; requiring it database-wide and using a different DB
server for it is acceptable.
- PHP 5.2.3 or better installed by default, including
+ User-configurable memory limit, up to at least 100 MB.
+ Respectable set of PHP modules enabled, including SOAP, PDO, SQLite,
XML/XSLT, etc. The "modern" tools.
+ Must be able and willing to install additional PHP modules upon request.
+ Must be able and willing to configure an opcode cache upon request, or even
have it by default. (Here's where I suspect a VPS will be necessary.)
- Managed
I'm a web developer, not a sysadmin. Installing, configuring, and upgrading
the above (such as opcode caches, PHP modules, etc.) must be something the
host does, not something they expect me to do. I also don't want to have to
go through a multi-week song and dance before the host is convinced to install
a common PHP module. (I had to do that to get SOAP support at our current
host, and they don't allow us to tweak the memory limit, which is why we're
looking elsewhere.
A decent control panel is, of course, a must. I admit to not actually liking
CPanel or Plesk, as I find them way over-featured and therefore impossible to
navigate, but I can probably deal if the host is good otherwise.
Naturally a good reputation for not over-selling is also important. It should
also be based in the continental USA, but I don't particularly care if they're
local. Good corporate citizen track record (e.g., hosts public mirrors) is
good icing but not make-or-break as long as they're not douchebags. We're
willing to pay for quality, but not be robbed for it. We're looking for a
company we can partner with long-term for hosing several dozen sites.
So, does this sound like anyone you know? :-) Any hosts you can
recommend/avoid? So far random searching has turned up Amazon EC2 and Jaguar
VPS as possibilities, but I'd like to get broader input if possible.
Thanks all!
--
Larry Garfield
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
Thank's for response.
This solution I tried many times but didn't resolved.
The reconstruct command don't modify this cyrus.header file.
2008/11/7 Colin Guthrie <[EMAIL PROTECTED]>
> Emerson Virti wrote:
>
>> Where is the problem?
>>
>
> Probably not the right list, but have you tried using cyradm and running:
> reconstruct user.name.mailbox.name
>
> (correct the folder as needed).
>
> When a cyrus database file gets corrupted or generally borked this fixes it
> 99% of the time for me.
>
> Col
>
> --
>
> Colin Guthrie
> gmane(at)colin.guthr.ie
> http://colin.guthr.ie/
>
> Day Job:
> Tribalogic Limited [http://www.tribalogic.net/]
> Open Source:
> Mandriva Linux Contributor [http://www.mandriva.com/]
> PulseAudio Hacker [http://www.pulseaudio.org/]
> Trac Hacker [http://trac.edgewall.org/]
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
Émerson Salvadori Virti
Engenheiro de Computação
Mestre em Ciência da Computação
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
At 7:16 PM -0500 11/9/08, Ron Piggott wrote:
Is there a way to find out the number of pixels wide and high an image
is in PHP?
Is there a way to resize an image using PHP?
Ron
Yes
tedd
--
-------
http://sperling.com http://ancientstones.com http://earthstones.com
--- End Message ---