From mogmios at mlug.missouri.edu Mon Nov 1 05:22:48 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Mon, 01 Nov 2004 02:22:48 -0800 Subject: [nycphp-talk] PHP 5; like ASP.NET? In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705536975@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705536975@ehost011-1.exch011.intermedia.net> Message-ID: <41860E78.6010709@mlug.missouri.edu> >PHP 5 is often compared to Java because of its attempts at a correct >object model. But this story, below, is a different take I haven't yet >seen, as it's likened to ASP.NET > > I'd like to see PHP, Perl, (mod_perl), and Python (mod_python) compared and contrasted for web development. I personally like Python best but mod_python is something of a pain to compile (more like PHP was a couple years ago). I haven't really taken much advantage of PHP5 yet so I'd like some insight on how it compares with Python as far as code size, speed, available features, CPU usage, etc. I'm still of the general opinion that anyone that pays for a development platform, when you can get better platforms for free, deserves to go out of business. My LAMPPP systems are powerful, secure, and very stable. I can't think of any reason I'd want to consider ASP.NET. JSP possibly but not anything .NET. -- Michael http://kavlon.org From mwithington at PLMresearch.com Mon Nov 1 08:11:23 2004 From: mwithington at PLMresearch.com (Mark Withington) Date: Mon, 1 Nov 2004 08:11:23 -0500 Subject: [nycphp-talk] OpenSource Project Management [was OpenSource CMS] Message-ID: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> Slightly OT: I'm researching available PHP project management tools. To date I've found: dotproject eGroupware more.groupware PHProjekt phpcollab Anyone know of others? Can anyone comment on any of the above? I've used phpcollab, which is pretty good, but apparently is no longer being developed. -------------------------- Mark L. Withington PLMresearch "eBusiness for the Midsize Enterprise" PO Box 1354 Plymouth, MA 02362 o: 800-310-3992 f: 508-746-4973 v: 508-746-2383 m: 508-801-0181 http://www.PLMresearch.com Netscape/AOL/MSN IM: PLMresearch mwithington at plmresearch.com Public Key: http://www.PLMresearch.com/keys/MLW_public_key.asc Calendar: http://www.plmresearch.com/calendar.php -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org]On Behalf Of Hans Zaunere Sent: Sunday, October 31, 2004 12:47 PM To: NYPHP Talk Subject: RE: [nycphp-talk] OpenSource CMS > I am currently looking for a very good CMS that has > good colloboration functionality to build a web site > from. I am looking for a cms that is very customizable > and modular with good performance and security. Security is going to be a trick... > The following are the CMSs I am looking into so far. > XARAYA, PHPNUKE, MAMBO, TIKIWIKI... Don't use PHPNUKE - in fact, don't use anything with the word "nuke" in it... > Just starting out with PHP so I dont have much experience > with programming. I am hoping to get some feedback/suggestion > from folks that have worked with the above CMS or others worth > considering - Thanks! http://oscom.org can also be a resource. It's generally a matter of trial and error, but I can say Mambo, Midgard, eZ Publish, Drupal have a generally good reputation. Another thing to keep in mind is cost. If you're willing a little, you'll probably end up with a solid CMS. H _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/ms-tnef Size: 3331 bytes Desc: not available URL: From jeff.loiselle at gmail.com Mon Nov 1 08:53:09 2004 From: jeff.loiselle at gmail.com (Jeff Loiselle) Date: Mon, 1 Nov 2004 09:53:09 -0400 Subject: [nycphp-talk] OpenSource Project Management [was OpenSource CMS] In-Reply-To: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> References: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> Message-ID: <4b18871104110105536cd5b655@mail.gmail.com> > Anyone know of others? gForge is very nice and also quite popular. http://gforge.org/ From 1j0lkq002 at sneakemail.com Mon Nov 1 09:34:58 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Mon, 1 Nov 2004 09:34:58 -0500 Subject: [nycphp-talk] cross server session id and SHARED HOSTING Message-ID: <21342-62342@sneakemail.com> There are four reasons I always caution against using shared hosting. Most important (to me) is the IP block -- if someone on that block does something bad like send spam or spam the search engines, you may find your site banned or your emails blacklisted or your domain otherwise guilty by association. The second is because an enterprising user on virtual site A can find his way through the file system tree to view your source code on virtual site B. The third is because another site can rash or jeopardize the server at your expense. The fourth is because you share all server-based low-level systems, such as the cookie issue you highlighted. It is also apparent when one influential site runs an insecure version of Apache/PHP/whatever, thus delaying an upgrade which would benefit your site. Of course I use shared hosting, because of the benefits :-) and because of the downsides associated with dedicated hosting :-) If this stuff was easy, all the newbies would be taking all the consulting business, and the market rates would go way down. Thankfully, that is not the case! -=john andrews Original Message: ----------------- From: Matthew Terenzio webmaster-at-localnotion.com |nyphp dev/internal group use| ... Date: Sun, 31 Oct 2004 21:51:50 -0500 To: talk at lists.nyphp.org Subject: [nycphp-talk] cross server session id Did anyone know you can read a PHP session id from a JSP page running on the same box(and domain), different port. I guess it only makes sense, but I wasn't expecting it. _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org -------------------------------------------------------------------- mail2web - Check your email from the web at http://mail2web.com/ . From dmintz at davidmintz.org Mon Nov 1 09:47:54 2004 From: dmintz at davidmintz.org (David Mintz) Date: Mon, 1 Nov 2004 09:47:54 -0500 (EST) Subject: [nycphp-talk] escaping % and _ in a MySQL query In-Reply-To: References: <2503.168.122.228.12.1099200555.squirrel@168.122.228.12> Message-ID: On Sun, 31 Oct 2004, Adam Maccabee Trachtenberg wrote: > I prefer str_replace() to preg_replace(), but this is essentially what > I do. Use the feature which allows you to pass multiple search/replace > pairs as arrays to reduce this to one call. > > Somehow this seems missing from PHP Cookbook. I will add it list of > things for the 2nd Edition. The Other Cookbook (MySQL Cookbook) doesn't seem to have anything about this either, so there's probably still a marketplace of hungry consumers for this (-; --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From tgales at tgaconnect.com Mon Nov 1 09:48:59 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Mon, 1 Nov 2004 09:48:59 -0500 Subject: [nycphp-talk] OpenSource Project Management [was OpenSource CMS] Message-ID: <200411011448.iA1EmxU12019@tgaconnect.com> > Slightly OT: I'm researching available PHP project management tools. To > date I've found: > > dotproject > eGroupware > more.groupware > PHProjekt > phpcollab > > Anyone know of others? You could have a look at Eventum http://dev.mysql.com/downloads/other/eventum/ It is fundamentally a bug tracking system -- but you could use it to track anything (e.g. software development 'to-do' items) I built a new 'Tea Party' based on it. http://teaparty.tgaconnect.com http://teaparty.tgaconnect.com/docs/html/ If you want to try it, mail me offlist and I'll give you a login. T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com -- From ajai at bitblit.net Mon Nov 1 11:04:57 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Mon, 01 Nov 2004 11:04:57 -0500 Subject: [nycphp-talk] OpenSource CMS In-Reply-To: <330532b604103105356a3147e6@mail.gmail.com> References: <330532b604103105356a3147e6@mail.gmail.com> Message-ID: <41865EA9.1090504@bitblit.net> Mitch Pirtle wrote: >As a core developer on mambo, I am unabashedly biased ;-) > >Functionality-wise, the king of the hill IMHO is plone, but also has >the greatest complexity and performance requirements (dual processor >machine with >1GB RAM is minimal for a serious site). After that it >becomes a pick-your-poison type of exercise. > >You must weigh the importance of simplicity, ease of installation, >features and 3rd party availability in your decision accordingly. I >joined the mambo team because I felt they had the cleanest/easiest >administration interface, and the most active 3rd party community (for >add-ons and extraneous goodies). Write me directly for any background >information on the latest developments, as I believe you may find them >interesting. > Just thought Id say, Ive been playing with Mambo for awhile and think its definately one of the better ones. I tried Drupal and found it hard to "get into" but Mambo out of the box has a terrific backend. Ive added some components (such as the phpShop ecommerce component) and was pleasantly suprised that it also provided a backend for product management that was completely integrated into the existing backend. Very cool. -- From ajai at bitblit.net Mon Nov 1 11:06:34 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Mon, 01 Nov 2004 11:06:34 -0500 Subject: [nycphp-talk] OpenSource CMS In-Reply-To: <330532b604103105356a3147e6@mail.gmail.com> References: <330532b604103105356a3147e6@mail.gmail.com> Message-ID: <41865F0A.3030608@bitblit.net> Mitch Pirtle wrote: >Functionality-wise, the king of the hill IMHO is plone, but also has >the greatest complexity and performance requirements (dual processor >machine with >1GB RAM is minimal for a serious site). After that it >becomes a pick-your-poison type of exercise. > Plone requires Zope no? Also the Python stuff is a major showstopper for me ;-) -- From ajai at bitblit.net Mon Nov 1 11:07:45 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Mon, 01 Nov 2004 11:07:45 -0500 Subject: [nycphp-talk] OpenSource Project Management [was OpenSource CMS] In-Reply-To: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> References: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> Message-ID: <41865F51.4020907@bitblit.net> Mark Withington wrote: >Slightly OT: I'm researching available PHP project management tools. To >date I've found: > >dotproject >eGroupware >more.groupware >PHProjekt >phpcollab > >Anyone know of others? Can anyone comment on any of the above? I've used >phpcollab, which is pretty good, but apparently is no longer being >developed. > Trac looks promising: http://www.edgewall.com/products/trac/ (Ive been meaning to play with it for some time). -- From mitch.pirtle at gmail.com Mon Nov 1 11:29:56 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 1 Nov 2004 11:29:56 -0500 Subject: [nycphp-talk] OpenSource CMS In-Reply-To: <41865F0A.3030608@bitblit.net> References: <330532b604103105356a3147e6@mail.gmail.com> <41865F0A.3030608@bitblit.net> Message-ID: <330532b6041101082924038063@mail.gmail.com> Plone is based on Zope, ZPT (Zope Page Templates) and the CMF (Content Management Framework). As such it has huge performance requirements and usually needs several servers for 'production use' - most folks put a proxy in front (I prefer pound). So not only is it very heavy in python, but will require a significant amount of effort to get setup and tuned properly. They really invented their own way of doing things, so this environment has a very, VERY steep learning curve. On the flip side it is a really fun environment, as it has a fully-OO database. So you get webpages with acquisition which is a very unique experience. It is also tremendously easy for the end-user, as the interface appears like a file browser, and all content can be organized in folders. I had a Plone site up in 15 minutes for an attorney that was incapable of configuring his email client; and I told him nothing more than his login and he was off to the races. To me this is the holy grail of CMS, and hope to influence Mambo's admin interface in that regard - just without the bloat ;-) -- Mitch, sorry to miss the last meet, but I didn't owe anyone a beer and felt safe skipping On Mon, 01 Nov 2004 11:06:34 -0500, Ajai Khattri wrote: > Mitch Pirtle wrote: > > >Functionality-wise, the king of the hill IMHO is plone, but also has > >the greatest complexity and performance requirements (dual processor > >machine with >1GB RAM is minimal for a serious site). After that it > >becomes a pick-your-poison type of exercise. > > > > Plone requires Zope no? > Also the Python stuff is a major showstopper for me ;-) > > -- > > _______________________________________________ > > > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From tom at supertom.com Mon Nov 1 11:32:17 2004 From: tom at supertom.com (Tom) Date: Mon, 01 Nov 2004 11:32:17 -0500 Subject: [nycphp-talk] OpenSource Project Management [was OpenSource CMS] In-Reply-To: <41865F51.4020907@bitblit.net> References: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> <41865F51.4020907@bitblit.net> Message-ID: <1099326736.26608.21.camel@tmelendez.int.bascom.com> We're playing with Trac, and it definitely has some cool features. IMHO, dotproject is the only system that does project management in the "traditional" sense. PM systems really shouldn't be concerned with contacts, email, tickets, CVS etc. That's creeping into groupware, with a software slant. If that is what you are looking for, that works, but when you have higher ups logging in to get info about the project process, that just isn't going to fly. (BTW, checked out Eventum for Bug Tracking - Nice!) I found dotproject to be the best of the bunch to meet this goal, EXCEPT that we have found that it doesn't seem to crunch all the numbers correctly - the percentage complete doesn't jive with the hours completed. It is a complicated thing, as you need to roll up all of the subtasks to do this, and it must have gotten lost in the logic somewhere. Also, it appears to be active, but there hasn't been a new release since March. I've been using a CVS version which I grabbed in August, but we had to hack in our own reporting (it is weak on reporting). We've submitted a few patches to it, but I think we may switch to something else if the issues aren't resolved. Tom www.liphp.org --------------------- What's Tom Listening to Right Now? http://www.supertom.com/current_track.php On Mon, 2004-11-01 at 11:07, Ajai Khattri wrote: > Mark Withington wrote: > > >Slightly OT: I'm researching available PHP project management tools. To > >date I've found: > > > >dotproject > >eGroupware > >more.groupware > >PHProjekt > >phpcollab > > > >Anyone know of others? Can anyone comment on any of the above? I've used > >phpcollab, which is pretty good, but apparently is no longer being > >developed. > > > > Trac looks promising: > > http://www.edgewall.com/products/trac/ > > (Ive been meaning to play with it for some time). From ajai at bitblit.net Mon Nov 1 11:46:21 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Mon, 01 Nov 2004 11:46:21 -0500 Subject: [nycphp-talk] OpenSource Project Management [was OpenSource CMS] In-Reply-To: <1099326736.26608.21.camel@tmelendez.int.bascom.com> References: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40DEC@network.PLMresearch.com> <41865F51.4020907@bitblit.net> <1099326736.26608.21.camel@tmelendez.int.bascom.com> Message-ID: <4186685D.8060303@bitblit.net> Tom wrote: >We're playing with Trac, and it definitely has some cool features. > We've been playing with phpwiki but needed something for issue/bug tracking - Trac seems to provide this and has a wiki so I figured we could switch from using two tools to just one. -- Aj. Systems Administrator / Developer From andrew at digitalpulp.com Mon Nov 1 12:12:27 2004 From: andrew at digitalpulp.com (Andrew Yochum) Date: Mon, 1 Nov 2004 12:12:27 -0500 Subject: [nycphp-talk] OpenSource CMS In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> Message-ID: <20041101171226.GB17557@thighmaster.digitalpulp.com> On Sun, Oct 31, 2004 at 09:47:19AM -0800, Hans Zaunere wrote: > > > I am currently looking for a very good CMS that has > > good colloboration functionality to build a web site > > from. I am looking for a cms that is very customizable > > and modular with good performance and security. > > Security is going to be a trick... > > > The following are the CMSs I am looking into so far. > > XARAYA, PHPNUKE, MAMBO, TIKIWIKI... > > Don't use PHPNUKE - in fact, don't use anything with the word "nuke" in > it... I concur. The nukes and their forks are often trouble. I've always liked TikiWiki a lot. Though, it was still *very* slow last time I used it (3+ seconds per page render). In fact, I just went to the TikiWiki homepage at http://tikiwiki.org/ and at the bottom the timing information says: [ Execution time: 6.07 secs ] [ Memory usage: 1.56MB ] [ 359 database queries used ] ... 6 seconds... :-( > > Just starting out with PHP so I dont have much experience > > with programming. I am hoping to get some feedback/suggestion > > from folks that have worked with the above CMS or others worth > > considering - Thanks! > > http://oscom.org can also be a resource. It's generally a matter of > trial and error, but I can say Mambo, Midgard, eZ Publish, Drupal have a > generally good reputation. I like Mambo and eZ. Each has its place. I haven't used Midgard in a while, but liked the framework. The Midgard CMS I believe is what used to be Nadmin Studio, a nice GUI on top of the framework. The process of choosing an OS CMS is tough and is often trial and error as Hans said. You may very well try a few before you find one that you like or does what you need. Another good resource is the CMS Matrix at http://www.cmsmatrix.org/ for comparing features and finding ones you may not have heard about. http://opensourcecms.com/ lets you try out various ones from their own demo installations. This can save you time in your evaluation process. Since you're just starting out I might suggest Mambo, but that depends on what you're looking to do. It does not offer flexible content types and can often lead to messy and duplicate URLs for pages. But it does offer a really nice flexible system for building entire sites w/o coding anything but a simple template. The most recent release is leaps and bounds greater than previous releases in terms of UI, features, flexibility and stability, which were good to begin with. Mitch might have a bit to say about all of these things. > Another thing to keep in mind is cost. If you're willing a little, > you'll probably end up with a solid CMS. Though, you can spend a lot of money on a product and still spend a lot of time/money customizing it to get what you want. There are always trade-offs. HTH, Andrew From mitch.pirtle at gmail.com Mon Nov 1 13:07:34 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 1 Nov 2004 13:07:34 -0500 Subject: [nycphp-talk] OpenSource CMS In-Reply-To: <20041101171226.GB17557@thighmaster.digitalpulp.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> Message-ID: <330532b604110110072150bc3e@mail.gmail.com> On Mon, 1 Nov 2004 12:12:27 -0500, Andrew Yochum wrote: > Since you're just starting out I might suggest Mambo, but that depends > on what you're looking to do. It does not offer flexible content types > and can often lead to messy and duplicate URLs for pages. But it does > offer a really nice flexible system for building entire sites w/o coding > anything but a simple template. The most recent release is leaps and > bounds greater than previous releases in terms of UI, features, > flexibility and stability, which were good to begin with. Mitch might > have a bit to say about all of these things. I have a LOT to say, as anyone that has had to sit next to me already knows LOL Seriously, Mambo was geared for the non-technical, and sports a very simple web-based installation interface that is hard to beat. We put a tremendous amount of time into that, and I would welcome any feedback, either positive or negative. Access to additional goodies at mosforge.net is another big draw. The 3rd party development community for Mambo is huge and active, and you can download (and use a web installer) all kinds of stuff from a fancy flash analog clock to online stores... > > Another thing to keep in mind is cost. If you're willing a little, > > you'll probably end up with a solid CMS. > > Though, you can spend a lot of money on a product and still spend a lot > of time/money customizing it to get what you want. There are always > trade-offs. I have worked with all of the 'biggies' in the last decade, and can say that none of them offer anything that is unique or significantly better than their FOSS bretheren. The coolest was Net Dynamics, which was bought out by Sun and disappeared in the mid-90s for some unknown reason. Really the 'Jimi Hendrix of CMS', IMHO. The others: Documentum, Day Interactive, Broadvision... They will certainly take longer for you to setup than Mambo or any other garden variety PHP-based CMS. Ease to administer is a big subject that has not been mentioned yet in this thread, which should deserve more focus. -- Mitch From dmintz at davidmintz.org Mon Nov 1 15:16:59 2004 From: dmintz at davidmintz.org (David Mintz) Date: Mon, 1 Nov 2004 15:16:59 -0500 (EST) Subject: [nycphp-talk] OpenSource CMS In-Reply-To: <330532b604110110072150bc3e@mail.gmail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> Message-ID: On Mon, 1 Nov 2004, Mitch Pirtle wrote: > On Mon, 1 Nov 2004 12:12:27 -0500, Andrew Yochum wrote: > > Since you're just starting out I might suggest Mambo, but that depends > > on what you're looking to do. It does not offer flexible content types > > and can often lead to messy and duplicate URLs for pages. But it does > > offer a really nice flexible system for building entire sites w/o coding > > anything but a simple template. The most recent release is leaps and > > bounds greater than previous releases in terms of UI, features, > > flexibility and stability, which were good to begin with. Mitch might > > have a bit to say about all of these things. > > I have a LOT to say, as anyone that has had to sit next to me already knows LOL > > Seriously, Mambo was geared for the non-technical, and sports a very > simple web-based installation interface that is hard to beat. We put > a tremendous amount of time into that, and I would welcome any > feedback, either positive or negative. > > Access to additional goodies at mosforge.net is another big draw. The > 3rd party development community for Mambo is huge and active, and you > can download (and use a web installer) all kinds of stuff from a fancy > flash analog clock to online stores... > > > > Another thing to keep in mind is cost. If you're willing a little, > > > you'll probably end up with a solid CMS. > > > > Though, you can spend a lot of money on a product and still spend a lot > > of time/money customizing it to get what you want. There are always > > trade-offs. > > I have worked with all of the 'biggies' in the last decade, and can > say that none of them offer anything that is unique or significantly > better than their FOSS bretheren. The coolest was Net Dynamics, which > was bought out by Sun and disappeared in the mid-90s for some unknown > reason. Really the 'Jimi Hendrix of CMS', IMHO. The others: > Documentum, Day Interactive, Broadvision... They will certainly take > longer for you to setup than Mambo or any other garden variety > PHP-based CMS. > > Ease to administer is a big subject that has not been mentioned yet in > this thread, which should deserve more focus. > > -- Mitch > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > --- David Mintz http://davidmintz.org/ On Mon, 1 Nov 2004, Mitch Pirtle wrote: > On Mon, 1 Nov 2004 12:12:27 -0500, Andrew Yochum wrote: > > Since you're just starting out I might suggest Mambo, but that depends > > on what you're looking to do. It does not offer flexible content types > > and can often lead to messy and duplicate URLs for pages. But it does > > offer a really nice flexible system for building entire sites w/o coding > > anything but a simple template. The most recent release is leaps and > > bounds greater than previous releases in terms of UI, features, > > flexibility and stability, which were good to begin with. Mitch might > > have a bit to say about all of these things. > > I have a LOT to say, as anyone that has had to sit next to me already knows LOL > > Seriously, Mambo was geared for the non-technical, and sports a very > simple web-based installation interface that is hard to beat. We put > a tremendous amount of time into that, and I would welcome any > feedback, either positive or negative. > > Access to additional goodies at mosforge.net is another big draw. The > 3rd party development community for Mambo is huge and active, and you > can download (and use a web installer) all kinds of stuff from a fancy > flash analog clock to online stores... > > > > Another thing to keep in mind is cost. If you're willing a little, > > > you'll probably end up with a solid CMS. > > > > Though, you can spend a lot of money on a product and still spend a lot > > of time/money customizing it to get what you want. There are always > > trade-offs. > > I have worked with all of the 'biggies' in the last decade, and can > say that none of them offer anything that is unique or significantly > better than their FOSS bretheren. The coolest was Net Dynamics, which > was bought out by Sun and disappeared in the mid-90s for some unknown > reason. Really the 'Jimi Hendrix of CMS', IMHO. The others: > Documentum, Day Interactive, Broadvision... They will certainly take > longer for you to setup than Mambo or any other garden variety > PHP-based CMS. > > Ease to administer is a big subject that has not been mentioned yet in > this thread, which should deserve more focus. > > -- Mitch > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > --- David Mintz http://davidmintz.org/ On Mon, 1 Nov 2004, Mitch Pirtle wrote: > On Mon, 1 Nov 2004 12:12:27 -0500, Andrew Yochum wrote: > > Since you're just starting out I might suggest Mambo, but that depends > > on what you're looking to do. It does not offer flexible content types > > and can often lead to messy and duplicate URLs for pages. But it does > > offer a really nice flexible system for building entire sites w/o coding > > anything but a simple template. The most recent release is leaps and > > bounds greater than previous releases in terms of UI, features, > > flexibility and stability, which were good to begin with. Mitch might > > have a bit to say about all of these things. > > I have a LOT to say, as anyone that has had to sit next to me already knows LOL > I wanna see a presentation -- hell, an infommercial, even -- about Mambo at a nyphp meeting. Hans Z. et al: sign him up! --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From dmintz at davidmintz.org Mon Nov 1 15:21:01 2004 From: dmintz at davidmintz.org (David Mintz) Date: Mon, 1 Nov 2004 15:21:01 -0500 (EST) Subject: [nycphp-talk] escaping % and _ in a MySQL query In-Reply-To: <20041031165829.GA26964@panix.com> References: <20041031165829.GA26964@panix.com> Message-ID: OK then, in light of all the above, how's this look? $input = str_replace( array('_','%'), array('^_','^%'), mysql_escape_string($input)); $SQL = "SELECT columns FROM table WHERE column like '$input' ESCAPE '^'"; WORKSFORME, FWIW. PS: Is there something sacred about the control character ^, or is it just one among several worthy candidates? --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From dmintz at davidmintz.org Mon Nov 1 15:27:52 2004 From: dmintz at davidmintz.org (David Mintz) Date: Mon, 1 Nov 2004 15:27:52 -0500 (EST) Subject: [nycphp-talk] OpenSource CMS In-Reply-To: References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> Message-ID: ouch, sorry for failing to delete all that last time around --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From mitch.pirtle at gmail.com Mon Nov 1 16:05:24 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 1 Nov 2004 16:05:24 -0500 Subject: [nycphp-talk] OpenSource CMS In-Reply-To: References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> Message-ID: <330532b60411011305646aeb1c@mail.gmail.com> On Mon, 1 Nov 2004 15:16:59 -0500 (EST), David Mintz wrote: > On Mon, 1 Nov 2004, Mitch Pirtle wrote: > > I have a LOT to say, as anyone that has had to sit next to me already knows LOL > > > > I wanna see a presentation -- hell, an infommercial, even -- about Mambo > at a nyphp meeting. Hans Z. et al: sign him up! Ok, I'll do it. I would love to do it, and actually am asking for permission to do it ;-) -- Mitch From 1j0lkq002 at sneakemail.com Mon Nov 1 16:43:40 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Mon, 01 Nov 2004 16:43:40 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <330532b60411011305646aeb1c@mail.gmail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> Message-ID: <14544-59972@sneakemail.com> I am curious - is this really the state of the job market for programmers these days? Here is a post that clearly states the employer wants a full-time, on-site programmer to work as directed on the core product of a new business, and even requires "significant night and weekend effort". And it quite clearly states it is to be "contract work" for an "independent contractor". This appears to be a clear violation of the IRS rules for independent contractors, *and* it was posted by the employer (not a job shop). I am no lawyer, but from what I can see this is the sort of blatant abuse of the system that the independent contractor rules were designed to control. Anyone who takes this job appears to risk failing the independent contractor test when they file their taxes as an independent contractor (1099 in-hand, expecting to file accordingly). That could make her liable for potential medicare/ss/payroll taxe issues, after the fact (i.e.plus penalties and interest). It also can result in a loss of certain deductions (such as travel, expense, self insurance, etc), again after-the-fact (i.e. plus penalties and interest). It appears to offer plenty of opportunity for such an "employee" to sue the company should there be such problems. And if the start-up operates this way, could it be susceptible to such problems for all of it's "employees" ? Maybe there's something hidden in the "open source" aspects or something... but the tone and intent of the proposal appears to strongly suggest they intend this as a way to hire someone full-time for a trial period, without legally treating them as an employee (or paying the requisite payroll taxes, social security benefits, following the labor laws, etc). I've never seen this attempted without a job shopper handling the paperwork. Okay so at least it's not overseas outsourcing, but is it better? I am no socialist by any means, but from where I sit, if you are losing even the minimal government provided worker protections that exist, something is "way wrong" with the picture. Please tell me I am completely wrong? From everythign I have seen over the past 10 years (7 of them included hiring programmers), you people are valuable. -=john andrews --------------------------------------------------------- JUNIOR PHP DEVELOPER Early stage funded startup seeks an individual consultant as junior developer for an open-source (LAMP) based web application that will serve as the core of the company's business. The system is nearly completed, and we are now looking for a junior developer to join the team. Position will begin as contract work, but we are hoping to be impressed enough to make a full-time offer towards the end of the contract. The initial opportunity is for a 4-6 week full time engagement beginning in a week or two. The position structure is as follows: ? Independent contractor ? Full-time dedication during full duration of project ? No telecommuting; must be on-site, in *** City (office near ****) ? Will require significant night and weekend effort Team is run by an experienced architect and senior developer. Fantastic learning experience for a junior programmer with exceptional technical skills who wants to be immersed in an intense real-world development/test/launch process. Great potential fit for recent college Computer Science/Engineering graduate. Requirements include: - Proficiency with PHP and MySQL - Proficiency with HTML, CSS, javascript - Hard-working, attention to detail, and fun to work with If you are interested, please: send a cover letter and resume (plain text inline preferred) to - indicate from whom you heard about this opportunity - include "Junior PHP Developer" in the Subject of your e-mail - include a sample of code (100 - 200 lines) you have personally written that highlights your understanding and expertise with PHP [Submissions that do not meet these requests will not be reviewed.] From krook at us.ibm.com Mon Nov 1 17:13:38 2004 From: krook at us.ibm.com (Daniel Krook) Date: Mon, 1 Nov 2004 17:13:38 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <14544-59972@sneakemail.com> Message-ID: > This appears to be a clear violation of the IRS rules for independent > contractors, *and* it was posted by the employer (not a job shop). >> Position will begin as contract work, but >> we are hoping to be impressed enough to make a full-time offer towards >> the end of the contract. These type of "trial period" contracts directly with employers seem to be more and more common these days. The most often quoted time frame I see is 6-month contract to hire, and it applies to developers - regardless of the specialty - as well as web producers and project managers in many cases. Sometimes it's an accurate and good faith description of how the employer views its committment to you as a labor producer, many times not; regardless of performance. As I understand it, the limits of working 40 hours per week as a contractor top out at 18 months, in which case the "project" or core function to which you are assigned must change, or you must have a 6 month break before working on the same project again. Ways around this are to set up a legal entity for dealing corp-to-corp with the company, or to work for a contracting agency middleman who becomes your proxy "employer" despite working on site for the first party. The former entitles you to deduct many things including rent and car payments, among other things, but requires more work to maintain and plan paperwork-wise. The latter has the advantage of taking care of most tax related paperwork as a W2 but rarely provides any benefits and will leave you a bitter and twisted shell of a human being in a relatively short amount of time. But yeah, this job description is legal, AFAIK. Daniel Krook, Application Developer WW Web Production Services North 2, ibm.com 1133 Westchester Avenue, White Plains, NY 10604 Personal: http://info.krook.org/ Persona: http://w3.ibm.com/eworkplace/persona_bp_finder.jsp?CNUM=9A9796897 From mitch.pirtle at gmail.com Mon Nov 1 17:15:52 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 1 Nov 2004 17:15:52 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <14544-59972@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> <14544-59972@sneakemail.com> Message-ID: <330532b6041101141539196e8b@mail.gmail.com> On Mon, 01 Nov 2004 16:43:40 -0500, inforequest <1j0lkq002 at sneakemail.com> wrote: > I am curious - is this really the state of the job market for > programmers these days? Part of it, at least. The person taking this position will get paid by he hundreds, and not the thousands (like they probably would deserve). There is no headhunter involved, as the client is too cheap to pay them either. These are the bottom-feeder projects, and there are too many of them. -- Mitch From mitch.pirtle at gmail.com Mon Nov 1 17:20:28 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 1 Nov 2004 17:20:28 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: References: <14544-59972@sneakemail.com> Message-ID: <330532b604110114206652c646@mail.gmail.com> On Mon, 1 Nov 2004 17:13:38 -0500, Daniel Krook wrote: > These type of "trial period" contracts directly with employers seem to be > more and more common these days. The most often quoted time frame I see > is 6-month contract to hire, and it applies to developers - regardless of > the specialty - as well as web producers and project managers in many > cases. Sometimes it's an accurate and good faith description of how the > employer views its committment to you as a labor producer, many times not; > regardless of performance. If they won't commit to the 6 months of pay, then you know they are just looking for cheap labor. A 6-month guarantee for a business shouldn't be an unreasonable risk, as they are getting a skilled laborer at (presumably) a steep discount. Tell them that if they want the trial period, they have to pay you for the whole period. Just got off the phone with a very smart and talended developer in Maryland who routinely gets projects for $800 or $1000. This, ladies (there were two of you, right?) and gentlemen, chaps my hide. -- Mitch From tgales at tgaconnect.com Mon Nov 1 17:42:43 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Mon, 1 Nov 2004 17:42:43 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers Message-ID: <200411012242.iA1Mghs03133@tgaconnect.com> > Here is a post that clearly states the employer wants a full-time, > on-site programmer to work as directed on the core product of a new > business, and even requires "significant night and weekend effort". > And it quite clearly states it is to be "contract work" for > an "independent contractor". > ... but the tone and intent of the proposal appears to > strongly suggest they intend this as a way to hire someone full-time > for a trial period, without legally treating them as an employee > (or paying the requisite payroll taxes, social security benefits, > following the labor laws, etc). This maneuver is sometimes referred to as a 'try and buy'. Usually these situations arise when the prospective employer has some complicated or 'one-off' system and must hire someone for a couple of months in order to see if the worker can handle the complexity or the 'strangeness' of the system before making a fulltime job offer. The risk the employer wants to avoid is the expense of letting someone go, which can be considerable if a large compensation package is being negotiated. In the ad you are quoting from the advertiser says: "Team is run by an experienced architect and senior developer. Fantastic learning experience for a junior programmer..." Junior programmers can be brought on for probationary periods with comparatively little risk, since they don't get huge pay packages. Further if the project leader is truly experienced, he should be able to pick someone who has the potential to grow into the job -- especially if it will be under his tutelage. I would say there is something not quite right about this job offer -- but it is not the fact that the person accepting the job would not be legally an independent contractor. T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com From leam at reuel.net Mon Nov 1 20:29:06 2004 From: leam at reuel.net (leam at reuel.net) Date: Mon, 1 Nov 2004 20:29:06 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <14544-59972@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> <14544-59972@sneakemail.com> Message-ID: <20041102012906.GC6265@leitz.earthlink.net> On Mon, Nov 01, 2004 at 04:43:40PM -0500, inforequest wrote: > I am curious - is this really the state of the job market for > programmers these days? > > Here is a post that clearly states the employer wants a full-time, > on-site programmer to work as directed on the core product of a new > business, and even requires "significant night and weekend effort". And > it quite clearly states it is to be "contract work" for an "independent > contractor". (snip) I thought it's the normal solution, just like any piece-work job. I'm doing the same thing, and yeah the taxes bite. You also have to file taxes 4 times a year. :( But at the same time, I think many employees get shafted even worse for long hours with no OT. At least as a contractor you get paid for those hours. ciao! leam From fields at surgam.net Mon Nov 1 19:25:28 2004 From: fields at surgam.net (Adam Fields) Date: Mon, 1 Nov 2004 19:25:28 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <200411012242.iA1Mghs03133@tgaconnect.com> References: <200411012242.iA1Mghs03133@tgaconnect.com> Message-ID: <20041102002528.GA20986@lola.aquick.org> On Mon, Nov 01, 2004 at 05:42:43PM -0500, Tim Gales wrote: [...] > Further if the project leader is truly experienced, he > should be able to pick someone who has the potential to > grow into the job -- especially if it will be under his > tutelage. Setting aside the question of whether this job is legit, the above paragraph is ludicrous. You can usually tell when someone's wrong for the job. Saying that someone is right for it is quite another story. Many people I've thought had the right qualifications or the skills or the potential to grow into a job have simply failed to be able to do it, for an endless variety of reasons. Hiring someone as a consult-to-hire is a good way to try that person out in a real-world scenario and see if they can actually do the work, and that there are no glaring personality conflicts. As an employer, you take the hit for this upfront - consulting rates are ALWAYS higher than employee pay for the same amount of work - in exchange for less risk in the long run. -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From codebowl at gmail.com Mon Nov 1 19:33:26 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Mon, 1 Nov 2004 19:33:26 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <20041102002528.GA20986@lola.aquick.org> References: <200411012242.iA1Mghs03133@tgaconnect.com> <20041102002528.GA20986@lola.aquick.org> Message-ID: <8d9a4280041101163340af0b02@mail.gmail.com> I would do a job like this because at the end of the time period i have no doubt they would hire me as an employee based on my performance, that is if they are not just looking for short term cheap work. however i am not willing to re-locate, anyone here know of any long term telecommuting positions available? i have been working with Lee Eyerman, and will continue to do so, however i need to get some more cash flow going here and i could use him as a reference. I have completed 1 job with him and working on a second and i think my work is good and done in a timely manner anyway. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From prusak at gmail.com Mon Nov 1 19:35:09 2004 From: prusak at gmail.com (Ophir Prusak) Date: Mon, 1 Nov 2004 19:35:09 -0500 Subject: [nycphp-talk] [OT slightly] state of the market for PHP programmers In-Reply-To: <14544-59972@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> <14544-59972@sneakemail.com> Message-ID: I think it all comes down to this: > ? Full-time dedication during full duration of project --> Will require significant night and weekend effort <-- Why would a developer's job require significant night and weekend effort? This can mean one of two things: 1. We're under a deadline that we can't meet. We don't really want to hire more people so we're looking for some contract workers but we don't have the money so we're looking for some bright but clueless newbies. Once the project is done we won't need you anymore. 2. There are issues that need to be dealt with 24 hours a day. Our current two developers are tired of being on call 24/7 so we're looking for someone cheap that can help them out till we get this fixed. I've seen both scenarios. In any case, this this sounds like a very unhealthy scenario. From 1j0lkq002 at sneakemail.com Tue Nov 2 12:08:29 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Tue, 02 Nov 2004 12:08:29 -0500 Subject: [nycphp-talk] "easily" defeating captchas using automated image analysis In-Reply-To: <20041102012906.GC6265@leitz.earthlink.net> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> <14544-59972@sneakemail.com> <20041102012906.GC6265@leitz.earthlink.net> Message-ID: <14687-93824@sneakemail.com> Isn't this fun? They canbeat most captchas automagically. They even defeat the "enter three of the following 6 overlapping captcha words" test 34% of the time. http://www.cs.sfu.ca/~mori/research/gimpy/ -=john andrews From codebowl at gmail.com Tue Nov 2 13:38:08 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 2 Nov 2004 13:38:08 -0500 Subject: [nycphp-talk] "easily" defeating captchas using automated image analysis In-Reply-To: <14687-93824@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> <14544-59972@sneakemail.com> <20041102012906.GC6265@leitz.earthlink.net> <14687-93824@sneakemail.com> Message-ID: <8d9a4280041102103847341269@mail.gmail.com> very interesting you know if there is a way to make the test there is a way to break it ;) -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From ben at atlphp.org Tue Nov 2 13:44:46 2004 From: ben at atlphp.org (Ben Ramsey) Date: Tue, 02 Nov 2004 13:44:46 -0500 Subject: [nycphp-talk] "easily" defeating captchas using automated image analysis In-Reply-To: <14687-93824@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F8705536953@ehost011-1.exch011.intermedia.net> <20041101171226.GB17557@thighmaster.digitalpulp.com> <330532b604110110072150bc3e@mail.gmail.com> <330532b60411011305646aeb1c@mail.gmail.com> <14544-59972@sneakemail.com> <20041102012906.GC6265@leitz.earthlink.net> <14687-93824@sneakemail.com> Message-ID: <4187D59E.4080305@atlphp.org> inforequest wrote: > Isn't this fun? They canbeat most captchas automagically. They even > defeat the "enter three of the following 6 overlapping captcha words" > test 34% of the time. > > http://www.cs.sfu.ca/~mori/research/gimpy/ What's even more interesting is that this is paving the way for AI in robots that can read signs and symbols, books, and recognize people and objects. -- Ben Ramsey Atlanta PHP http://atlphp.org http://benramsey.com From shiflett at php.net Tue Nov 2 13:58:44 2004 From: shiflett at php.net (Chris Shiflett) Date: Tue, 2 Nov 2004 10:58:44 -0800 (PST) Subject: [nycphp-talk] "easily" defeating captchas using automated image analysis In-Reply-To: <4187D59E.4080305@atlphp.org> Message-ID: <20041102185844.59794.qmail@web52809.mail.yahoo.com> --- Ben Ramsey wrote: > > Isn't this fun? They canbeat most captchas automagically. They > > even defeat the "enter three of the following 6 overlapping > > captcha words" test 34% of the time. > > > > http://www.cs.sfu.ca/~mori/research/gimpy/ > > What's even more interesting is that this is paving the way for > AI in robots that can read signs and symbols, books, and > recognize people and objects. But would you want to have a beer with one? That's the real question. :-) Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming January 2005 http://httphandbook.org/ From Cbielanski at inta.org Tue Nov 2 14:16:05 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Tue, 2 Nov 2004 14:16:05 -0500 Subject: [nycphp-talk] "easily" defeating captchas using automated imag e analysis Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA1A@intamail1.com> > But would you want to have a beer with one? That's the real > question. :-) > > Chris Yes...but only if it could pick a *good* beer. Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence From 1j0lkq002 at sneakemail.com Tue Nov 2 16:33:09 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Tue, 2 Nov 2004 16:33:09 -0500 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis Message-ID: <6340-88496@sneakemail.com> Original Message: ----------------- you know if there is a way to make the test there is a way to break it ;) -- Joseph Crawford Jr. Codebowl Solutions Actually, it is not quite that simple. The point of a captcha was to get past that observation (if a system built it, a system can beat it). The Captcha was to be a turing test.. something that only a human could solve. The most obvous flaw with the graphic captcha was that it was visual, and therefore *specific* --which by definition made it "discriminatory" -- against the visually impaired -- and also solveable. It is the use of machines to implement the test that causes it to be machine crackable. Think about typed print (typefaces) vs. cursive (script handwriting). Why wasn't the captcha created using cursive? That would have made it infinitely harder to crack for machines, but I bet most humans could solve a cursive captcha as well as some of the graphic ones I have seen. Of course it is really hard to make a machine write human-style cursive -- perhaps equally as hard as it is to make a machine that can read human-style cursive? Where there is a will there is a way... this is simply not a turing test. What wouldit take to build a massive Internet database of cursive words, collected continuously and used for captchas? Universal pen input, probably. until then, what do we have? -=john andrews -------------------------------------------------------------------- mail2web - Check your email from the web at http://mail2web.com/ . From joel at tagword.com Tue Nov 2 12:04:30 2004 From: joel at tagword.com (Joel De Gan) Date: Tue, 02 Nov 2004 17:04:30 +0000 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <6340-88496@sneakemail.com> References: <6340-88496@sneakemail.com> Message-ID: <1099415070.7385.21.camel@bezel> I have done a lot on this.. you might want to go through the list archive as I have posted code on this list for breaking captcha's On Tue, 2004-11-02 at 21:33, inforequest wrote: > > Original Message: > ----------------- > > you know if there is a way to make the test there is a way to break it ;) -- joeldg - developer, Intercosmos media group. http://lucifer.intercosmos.net From ashaw at iifwp.org Tue Nov 2 17:10:28 2004 From: ashaw at iifwp.org (Allen Shaw) Date: Tue, 02 Nov 2004 17:10:28 -0500 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <6340-88496@sneakemail.com> References: <6340-88496@sneakemail.com> Message-ID: <418805D4.9090101@iifwp.org> > John wrote: > The point of a captcha was to get past that observation (if a system > built it, a system can beat it). The Captcha was to be a turing test.. > something that only a human could solve. > ... > this is simply not a turing test. What wouldit take to build a > massive Internet database of cursive words, collected continuously and > used for captchas? Universal pen input, probably. until then, what do > we have? I've seen (or seen theorized) captchas that require a user to enter a keyword based on three or more different pictures -- for example, show the user a Frosted Flakes box cover, that famous Nike-branded golfer, and a Cincinatti Bengals logo, and most users (depending on the target audience) could get in by typing "tiger". One idea was also to say "three out of these 4 pictures" and then throw in a bogus picture of Bambi or the Eifel Tower. I'm sure somebody could program linguistic and cultural knowledge like this, but that seems a lot more "human" than what these guys are able to do. ... Um, right? - Allen From ben at atlphp.org Tue Nov 2 17:30:37 2004 From: ben at atlphp.org (Ben Ramsey) Date: Tue, 02 Nov 2004 17:30:37 -0500 Subject: [nycphp-talk] easily defeating captchas using automated image analysis In-Reply-To: <418805D4.9090101@iifwp.org> References: <6340-88496@sneakemail.com> <418805D4.9090101@iifwp.org> Message-ID: <41880A8D.1070509@atlphp.org> Allen Shaw wrote: > > John wrote: > > The point of a captcha was to get past that observation (if a system > > built it, a system can beat it). The Captcha was to be a turing > test.. > something that only a human could solve. > > ... > > this is simply not a turing test. What wouldit take to build a > > massive Internet database of cursive words, collected continuously and > > used for captchas? Universal pen input, probably. until then, what do > > we have? > > > I've seen (or seen theorized) captchas that require a user to enter a > keyword based on three or more different pictures -- for example, show > the user a Frosted Flakes box cover, that famous Nike-branded golfer, > and a Cincinatti Bengals logo, and most users (depending on the target > audience) could get in by typing "tiger". One idea was also to say > "three out of these 4 pictures" and then throw in a bogus picture of > Bambi or the Eifel Tower. I'm sure somebody could program linguistic and > cultural knowledge like this, but that seems a lot more "human" than > what these guys are able to do. ... Um, right? Speaking of using different recognizable images to ensure that a human is using the system, here's an interesting article about a system called PassFace, where the user's "password" is a sequence of human faces instead of insecure combinations of letters and numbers. There's a demo of the PassFace system here . It's actually pretty neat. The beauty of it is that I can't give my password to anyone since it's practically impossible for me to truly describe each face to the degree that you can pick out my password. Plus, it's hard for me to forget, too, since humans naturally recognize faces. -- Ben Ramsey Atlanta PHP http://atlphp.org http://benramsey.com From shiflett at php.net Tue Nov 2 18:20:20 2004 From: shiflett at php.net (Chris Shiflett) Date: Tue, 2 Nov 2004 15:20:20 -0800 (PST) Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <418805D4.9090101@iifwp.org> Message-ID: <20041102232020.54079.qmail@web52802.mail.yahoo.com> --- Allen Shaw wrote: > I've seen (or seen theorized) captchas that require a user to > enter a keyword based on three or more different pictures -- for > example, show the user a Frosted Flakes box cover, that famous > Nike-branded golfer, and a Cincinatti Bengals logo, and most > users (depending on the target audience) could get in by typing > "tiger". The problem with this approach is that humans can still guess it, so the adult site attack (that thing needs a name) will still work. Thus, strengthening this further doesn't really help - it's already easier to use the adult site attack than it is to leverage the captcha breaking research results that have been produced. This is a key point regarding security in general - it's unwise to focus all of your attention in any one area, thereby assuming that this is the one opening that a potential attacker will use. It's similar to how people have a false sense of security when something is encrypted - often decryption isn't necessary for a successful attack (presentation of the original encrypted data may be all that's required). I'm glad that there are people who focus a lot of effort on specific issues, but personally speaking, I try to focus on the big picture. Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming January 2005 http://httphandbook.org/ From hans at nyphp.com Tue Nov 2 18:30:55 2004 From: hans at nyphp.com (Hans Zaunere) Date: Tue, 2 Nov 2004 15:30:55 -0800 Subject: [nycphp-talk] easily defeating captchas using automatedimageanalysis Message-ID: <41EE526EC2D3C74286415780D3BA9F87056DB601@ehost011-1.exch011.intermedia.net> > > I've seen (or seen theorized) captchas that require a user to > > enter a keyword based on three or more different pictures -- for > > example, show the user a Frosted Flakes box cover, that famous > > Nike-branded golfer, and a Cincinatti Bengals logo, and most > > users (depending on the target audience) could get in by typing > > "tiger". Something here is that it's cultural - therefore, someone in Canada, might not recognize the Bengals logo, a? > The problem with this approach is that humans can still guess it, so the > adult site attack (that thing needs a name) will still work. Thus, I think we could call it genius :) > strengthening this further doesn't really help - it's already easier to > use the adult site attack than it is to leverage the captcha breaking > research results that have been produced. > > This is a key point regarding security in general - it's unwise to focus > all of your attention in any one area, thereby assuming that this is the > one opening that a potential attacker will use. It's similar to how people > have a false sense of security when something is encrypted - often > decryption isn't necessary for a successful attack (presentation of the > original encrypted data may be all that's required). Absolutely true. With the "genius" attack on captchas, they basically go out the window. Someone who is determined will defeat any captcha, and if they don't do it with computerized recognition, they'll do it with human recognition, which obviously defeats the entire purpose. That said, I can't see that captchas are really a security mechanism - a login is still required, thus being the primary "security" method (however effective of course depends). Captchas are to thwart automation, and in many cases, works. So how does one defeat automation all of the time? Maybe someone with that answer can also tell us how to be secure all of the time :) --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From 1j0lkq002 at sneakemail.com Tue Nov 2 19:51:24 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Tue, 02 Nov 2004 19:51:24 -0500 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <20041102232020.54079.qmail@web52802.mail.yahoo.com> References: <20041102232020.54079.qmail@web52802.mail.yahoo.com> Message-ID: <28987-19648@sneakemail.com> Chris Shiflett shiflett-at-php.net |nyphp dev/internal group use| wrote: >This is a key point regarding security in general - it's unwise to focus >all of your attention in any one area, thereby assuming that this is the >one opening that a potential attacker will use. It's similar to how people >have a false sense of security when something is encrypted - often >decryption isn't necessary for a successful attack (presentation of the >original encrypted data may be all that's required). > >I'm glad that there are people who focus a lot of effort on specific >issues, but personally speaking, I try to focus on the big picture. > >Chris > >===== >Chris Shiflett - http://shiflett.org/ > >PHP Security - O'Reilly HTTP Developer's Handbook - Sams >Coming January 2005 http://httphandbook.org/ >_______________________________________________ > > yes, but then this is an attempt at a "technology solution" to a security problem. There's a way to defeat the to-be-monikered-adult hack. Remind the world that it is illegal to participate in a security hack, and that participation via adultsite captcha completion is at the very minimum "grounds for investigation". Make it public enough that the FBI may come around your workplace or home asking about the time you completed a captcha to see those barnyard animal pictures.... Now to preserve privacy and liberty while removing anonymity to ensure compliance... that is a real magic trick. -=john andrews From shiflett at php.net Tue Nov 2 20:59:20 2004 From: shiflett at php.net (Chris Shiflett) Date: Tue, 2 Nov 2004 17:59:20 -0800 (PST) Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <28987-19648@sneakemail.com> Message-ID: <20041103015920.70791.qmail@web52807.mail.yahoo.com> --- inforequest <1j0lkq002 at sneakemail.com> wrote: > There's a way to defeat the to-be-monikered-adult hack. Remind > the world that it is illegal to participate in a security hack, > and that participation via adultsite captcha completion is at > the very minimum "grounds for investigation". I don't see how this idea will work, because people have no idea that they're participating in any such thing. I can think of plenty of ways to word this: "In order to keep our competitors from harvesting our images, we ask that you please type in the word you see in the box below. Once you do this, we'll show you some pictures you don't want to miss!" In fact, I would hope that it would be impossible to prosecute someone who was tricked into providing this answer, because they literally have no way to know that the answer they're provided is going to be misused in any way. Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming January 2005 http://httphandbook.org/ From george at omniti.com Tue Nov 2 21:25:12 2004 From: george at omniti.com (George Schlossnagle) Date: Tue, 2 Nov 2004 21:25:12 -0500 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <20041103015920.70791.qmail@web52807.mail.yahoo.com> References: <20041103015920.70791.qmail@web52807.mail.yahoo.com> Message-ID: <9729BDC6-2D3F-11D9-B250-000D93359332@omniti.com> On Nov 2, 2004, at 8:59 PM, Chris Shiflett wrote: > --- inforequest <1j0lkq002 at sneakemail.com> wrote: >> There's a way to defeat the to-be-monikered-adult hack. Remind >> the world that it is illegal to participate in a security hack, >> and that participation via adultsite captcha completion is at >> the very minimum "grounds for investigation". > > I don't see how this idea will work, because people have no idea that > they're participating in any such thing. I can think of plenty of ways > to > word this: > > "In order to keep our competitors from harvesting our images, we ask > that > you please type in the word you see in the box below. Once you do this, > we'll show you some pictures you don't want to miss!" > > In fact, I would hope that it would be impossible to prosecute someone > who > was tricked into providing this answer, because they literally have no > way > to know that the answer they're provided is going to be misused in any > way. Also, I suspect that people just won't care about the threat, even if you watermark the image 'this is property of foo.com, if you aren't seeing this from foo.com, please report this'. I mean millions in advertising and warnings on music/movies doesn't achieve a deterent effect. George From webmaster at localnotion.com Tue Nov 2 21:35:39 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Tue, 2 Nov 2004 21:35:39 -0500 Subject: [nycphp-talk] HTML_Quickform setChecked() Message-ID: <0D0D0C53-2D41-11D9-A001-0003938BDF32@localnotion.com> Any HTML_Quickform (3.2.3) users know how to set a radio button to checked. The following method call works with checkbox but not a radio button. $test =& HTML_Quickform::createElement('radio',null,null,'Enabled','true'); $test->setChecked('true'); From 1j0lkq002 at sneakemail.com Wed Nov 3 08:20:49 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Wed, 03 Nov 2004 08:20:49 -0500 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <20041103015920.70791.qmail@web52807.mail.yahoo.com> References: <20041103015920.70791.qmail@web52807.mail.yahoo.com> Message-ID: <5724-30510@sneakemail.com> Chris Shiflett shiflett-at-php.net |nyphp dev/internal group use| wrote: >--- inforequest <1j0lkq002 at sneakemail.com> wrote: > > >>There's a way to defeat the to-be-monikered-adult hack. Remind >>the world that it is illegal to participate in a security hack, >>and that participation via adultsite captcha completion is at >>the very minimum "grounds for investigation". >> >> > >I don't see how this idea will work, because people have no idea that >they're participating in any such thing. I can think of plenty of ways to >word this: > >"In order to keep our competitors from harvesting our images, we ask that >you please type in the word you see in the box below. Once you do this, >we'll show you some pictures you don't want to miss!" > >In fact, I would hope that it would be impossible to prosecute someone who >was tricked into providing this answer, because they literally have no way >to know that the answer they're provided is going to be misused in any >way. > >Chris > yes, that's the "balance between privacy/anonymity" and enforcement of what is essentially voluntary compliance. The idea is of course that people first have to be made aware that participation is a crime. It has to be common knowledge first. It is not up to the adult site to tell you, it is up to society to say it is wrong, and that you *should* know better. Approach a stranger on the street and offere to sell her a watch. Many, many people will turn away because they don't want to get caught up in anything illegal. That's why a technology solution is so attractive. It seems to suggest the possibility of a Utopian solution. "I would hope that it would be impossible to prosecute someone who was tricked into providing this answer, because they literally have no way to know that the answer they're provided is going to be misused in any way." This happens every day and that's what due process is for. It is not at all impossible but thankfully we still have a system that ensures an opportunity to defend ourselves, make a case etc. Or do we? That's why the recent justice dept detentions sans representation were so important... the new behavior has widespread implications. Why don't nosy neighbors try your door on occasion to see if it is unlocked? What if your door was in a dark place, out of view. How many would test it then, just to "take an innocent peek" ? Where I live in beautiful ****** many people don't carry keys and leave doors unlocked. When I lived in ******* I shopped for a steel door because wooden doors were commonly defeated in that area. Was it because all the "bad people" lived in ***** or because they had basically anonymous access to test my security system? I am of the camp "port scanning is not a crime" yet clearly our society's rule-based approach to security (threat of enforcement) does not apply - port scanning with an intent to determine a way to break security is probably worthy of being called a crime. You can't prove intent. Can we afford to try to prove it? I think any IT person with an interest in the higher aspects of security should volunteer to work in local government for a while. You can do alot of good as an advisor and educator. -=john andrews From mogmios at mlug.missouri.edu Wed Nov 3 09:02:23 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Wed, 03 Nov 2004 06:02:23 -0800 Subject: [nycphp-talk] easily defeating captchas using automated imageanalysis In-Reply-To: <20041102232020.54079.qmail@web52802.mail.yahoo.com> References: <20041102232020.54079.qmail@web52802.mail.yahoo.com> Message-ID: <4188E4EF.2010206@mlug.missouri.edu> >This is a key point regarding security in general - it's unwise to focus >all of your attention in any one area, thereby assuming that this is the >one opening that a potential attacker will use. It's similar to how people >have a false sense of security when something is encrypted - often >decryption isn't necessary for a successful attack (presentation of the >original encrypted data may be all that's required). > This is exactly why I force users on my secure Intranets to access my servers using Knoppix discs, have strong passwords, use encryption, etc. I keep telling them that it does no good to secure the servers and make users change passwords every other week when half of their computers are infected with spy software hat can capture keystrokes and other important information. Likewise there is no point in securing the client machines if everything is sent unencrpyted over their home wirelesss network. Or just walk in, say your a server tech, and walk out with the server. It's really quite easy to hack just about anybody because it's seldom that all aspects of security are really considered. -- Michael http://kavlon.org From webmaster at jaymax.com Wed Nov 3 13:05:18 2004 From: webmaster at jaymax.com (Joseph E. Maxwell) Date: Wed, 03 Nov 2004 10:05:18 -0800 Subject: [nycphp-talk] PHP Advanced Web Site Search Script Message-ID: <41891DDE.9050008@jaymax.com> Hello, There is a PHP Advanced Web Site Search Script on several web site, apparently called "advanced_search.php", I think, capable of searching according to keywords, boolean and across several categories etc. I've tried to Google it but with so many sites already using some search utility they call Advanced Search it is impossible to see the trees for the forest. Does any one have a handle on the source for this or similar script? Thanks -- Adam -- From jeff.loiselle at gmail.com Thu Nov 4 02:06:15 2004 From: jeff.loiselle at gmail.com (Jeff Loiselle) Date: Thu, 4 Nov 2004 03:06:15 -0400 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers Message-ID: <4b18871104110323064b45a2d8@mail.gmail.com> I was just doing some research into budget virtual dedicated servers and thought I might "inquire within". a. Has anyone tried VDS hosting? b. what kind of experience did you have? c. what are the major factors to look for in a good VDS host? TIA - Jeff Loiselle From suzerain at suzerain.com Thu Nov 4 06:15:23 2004 From: suzerain at suzerain.com (Marc Antony Vose) Date: Thu, 4 Nov 2004 06:15:23 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <4b18871104110323064b45a2d8@mail.gmail.com> References: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: >I was just doing some research into budget virtual dedicated servers >and thought I might "inquire within". > >a. Has anyone tried VDS hosting? >b. what kind of experience did you have? >c. what are the major factors to look for in a good VDS host? > Not entirely sure if we are using the exact same terminology, but I think two of my clients are using "virtual dedicated servers". a. They are both hosted at MediaTemple (http://www.mediatemple.net/). They have the "Application Server" accounts, which are basically a complete copy of linux running on a shared machine. So, when you log in, it looks like the whole machine is yours. (To me, that sounds like a 'virtual dedicated server', though I am only familiar with it in this context.) b. Experience is generally OK. The account itself is kind of a neat concept; I am able to log in and do anything I want, just as if it is a dedicated server. My least favorite thing about the account is the Plesk tool, which is I guess basically OK, but it has its bizarre idiosyncrasies that they do an incredibly shitty job of explaining to you. Also, I had a nightmare trying to apply a secure certificate to one account (fully purchased through the Plesk tool). Most of my problems were caused by it defaulting to open_basedir restriction set to 'on', and not treating subdomains as 'real' domains (i.e., it was not possible to have a subdomain secure unless it was created as a 'full' domain, yet no documentation explained this.) Anyway, absolutely none of that rant had to do with VDS, I guess, except that if you choose the (as) account at (mt), you are stuck with Plesk. c. I don't know that this question is a lot different from "What are the major factors to look for in a good host." It seems to me that if they are running a good virtual account system, or a good dedicated system, they are probably running a decent VDS system (assuming they offer it). Though I don't care about phone calls, in my case, my clients wanted to be able to reach people on the phone, and (mt) offers phone support. MediaTemple has been decent...there have been some moments of strangeness, but for the most part they have resolved any issues rapidly. After years in this business, I have just sort of settled into the opinion that there is no perfect Web host and I will always have some kind of problem, whomever I choose. At the moment, I'm hosted on both (mt) and DreamHost. I'm reasonably happy with both, which is about as ringing an endorsement I can ever give. Cheers, -- Marc Antony Vose http://www.suzerain.com/ The cost of liberty is less than the price of repression. -- W.E.B. Du Bois From tgales at tgaconnect.com Thu Nov 4 07:10:02 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Thu, 4 Nov 2004 07:10:02 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: <001e01c4c267$36eba750$e98d3818@oberon1> > > I was just doing some research into budget virtual dedicated > servers and thought I might "inquire within". > > a. Has anyone tried VDS hosting? > b. what kind of experience did you have? > c. what are the major factors to look for in a good VDS host? > Yes I use VDS -- Drop me a line off-list. (I am assuming very few others are interested in this) T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com From mwithington at PLMresearch.com Thu Nov 4 07:19:31 2004 From: mwithington at PLMresearch.com (Mark Withington) Date: Thu, 4 Nov 2004 07:19:31 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers Message-ID: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40F73@network.PLMresearch.com> I'm interested, primarily because I'm curious to hear what a VDS is? I use pair.net for my dedicated boxes (they're great) - I have sole use; they own the boxes; they manage them - is that a VDS? -------------------------- Mark L. Withington PLMresearch "eBusiness for the Midsize Enterprise" PO Box 1354 Plymouth, MA 02362 o: 800-310-3992 f: 508-746-4973 v: 508-746-2383 m: 508-801-0181 http://www.PLMresearch.com Netscape/AOL/MSN IM: PLMresearch mwithington at plmresearch.com Public Key: http://www.PLMresearch.com/keys/MLW_public_key.asc Calendar: http://www.plmresearch.com/calendar.php -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org]On Behalf Of Tim Gales Sent: Thursday, November 04, 2004 7:10 AM To: 'NYPHP Talk' Subject: RE: [nycphp-talk] [OT] Virtual Dedicated Servers > > I was just doing some research into budget virtual dedicated > servers and thought I might "inquire within". > > a. Has anyone tried VDS hosting? > b. what kind of experience did you have? > c. what are the major factors to look for in a good VDS host? > Yes I use VDS -- Drop me a line off-list. (I am assuming very few others are interested in this) T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org From fields at surgam.net Thu Nov 4 07:22:36 2004 From: fields at surgam.net (Adam Fields) Date: Thu, 4 Nov 2004 07:22:36 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: References: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: <20041104122236.GM20070@lola.aquick.org> On Thu, Nov 04, 2004 at 06:15:23AM -0500, Marc Antony Vose wrote: > >I was just doing some research into budget virtual dedicated servers > >and thought I might "inquire within". > > > >a. Has anyone tried VDS hosting? > >b. what kind of experience did you have? > >c. what are the major factors to look for in a good VDS host? [...] > Experience is generally OK. The account itself is kind of a neat > concept; I am able to log in and do anything I want, just as if it is > a dedicated server. > > My least favorite thing about the account is the Plesk tool, which is > I guess basically OK, but it has its bizarre idiosyncrasies that they > do an incredibly shitty job of explaining to you. Also, I had a > nightmare trying to apply a secure certificate to one account (fully > purchased through the Plesk tool). Most of my problems were caused > by it defaulting to open_basedir restriction set to 'on', and not > treating subdomains as 'real' domains (i.e., it was not possible to > have a subdomain secure unless it was created as a 'full' domain, yet > no documentation explained this.) I've used both Rose Hosting (www.rosehosting.com) and John Companies (www.johncompanies.com) for this. John Companies is a little more hands-off and will do weird things for you if you ask, but Rose has better support. If you don't know what you're doing, I'd go with Rose. Neither of these uses Plesk. The only real drawback is that, like shared hosting, disk space is still massively overpriced. Otherwise, I've been very happy. -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From fields at surgam.net Thu Nov 4 07:23:51 2004 From: fields at surgam.net (Adam Fields) Date: Thu, 4 Nov 2004 07:23:51 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40F73@network.PLMresearch.com> References: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40F73@network.PLMresearch.com> Message-ID: <20041104122351.GN20070@lola.aquick.org> On Thu, Nov 04, 2004 at 07:19:31AM -0500, Mark Withington wrote: > I'm interested, primarily because I'm curious to hear what a VDS is? I use > pair.net for my dedicated boxes (they're great) - I have sole use; they own > the boxes; they manage them - is that a VDS? No - it's like vmware. You get a full "virtual" server on a shared machine. You get root on the box, and to you, it looks like you have the whole machine. -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From tgales at tgaconnect.com Thu Nov 4 07:31:24 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Thu, 4 Nov 2004 07:31:24 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C40F73@network.PLMresearch.com> Message-ID: <000101c4c26a$32b9dd20$e98d3818@oberon1> > I'm interested, primarily because I'm curious to hear what a > VDS is? I use pair.net for my dedicated boxes (they're > great) - I have sole use; they own the boxes; they manage > them - is that a VDS? > http://www.jumpline.com/products_services.php Explains the Jumpline offering (this is not an endorsement -- they have their problems. but, depending on what you want to do they might be right for you) T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com From dcech at phpwerx.net Thu Nov 4 09:59:29 2004 From: dcech at phpwerx.net (Dan Cech) Date: Thu, 04 Nov 2004 09:59:29 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <4b18871104110323064b45a2d8@mail.gmail.com> References: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: <418A43D1.5020704@phpwerx.net> Jeff Loiselle wrote: > I was just doing some research into budget virtual dedicated servers > and thought I might "inquire within". > > a. Has anyone tried VDS hosting? Nope, but I have used http://www.linode.com for a little over a year > b. what kind of experience did you have? Good, the support is very good, the control panel is excellent. You not only get root on your own UML (User Mode Linux) instance, but also access to a virtual serial console, so you can watch your machine start up, etc. > c. what are the major factors to look for in a good VDS host? The biggest factor IMHO is the quality of the hardware and how many users are sharing said hardware. Personally I have a Linode64 which is 64MB RAM, 4.5GB disk and 25GB/month transfer for $242.62/yr. It's running a couple of reasonably low volume websites and mail for a few domains, I wouldn't use it for more than that. The major limiting factor seems to be RAM, as the majority of VDS users don't overly stress the CPU. If you move up a rung and pay $30/month you get a Linode128, with double the RAM, more disk space and 38GB/month transfer. The strength of the VDS approach is that for $60/month you could have 2 'machines' on different hosts (eg a mailserver and webserver). Dan > TIA > > - Jeff Loiselle From evan.heller at doodleboy.com Thu Nov 4 10:55:44 2004 From: evan.heller at doodleboy.com (Evan Heller) Date: Thu, 4 Nov 2004 10:55:44 -0500 Subject: [nycphp-talk] PHP on windows CE Message-ID: <200411041055.AA251986200@doodleboy.com> Does anyone know if/how to get php/apache/mysql onto windows ce or what toolkits there are out there? This would be much better than doing development with the c api. -Evan From mogmios at mlug.missouri.edu Thu Nov 4 11:02:28 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Thu, 04 Nov 2004 08:02:28 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: References: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: <418A5294.4080701@mlug.missouri.edu> > you are stuck with Plesk. Plesk annoyed the fsck out of me so I removed it. These ease of use tools are not the way to have god like powers over your servers. :) > After years in this business, I have just sort of settled into the > opinion that there is no perfect Web host and I will always have some > kind of problem, whomever I choose. I'm happy with my hosting company. They are about as perfect as humanly possible in that they provide the server and the bandwidth to specifications and stay out of my way and let me do the rest. That's all I ask really. The one time I had a server go down was a bit slow but it turned out that the machine had multiple things go wrong with it such that they replaced one part that was blown and thinking the machine was repaired put it back in service. Shortly after a part damaged when the first part blew managed to blow out taking the replacement part with it. Annoying but frankley not the hosting companies fault. These things happen and they were very responsive to fixing things as quickly as possible. -- Michael http://kavlon.org From chsnyder at gmail.com Thu Nov 4 11:14:56 2004 From: chsnyder at gmail.com (csnyder) Date: Thu, 4 Nov 2004 11:14:56 -0500 Subject: [nycphp-talk] NEW PHundamentals Question - HTTP Authentication In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870527CF70@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F870527CF70@ehost011-1.exch011.intermedia.net> Message-ID: I just discovered a really great reason to use PHP's built-in support for HTTP authentication. At work, we have a PHPWiki set up for some of the developers. It's completely private, you have to log in to view anything. It also has an RSS feed that you can use to track recently edited pages. If PHPWiki used HTTP authentication, then team members could use a Newsreader to keep an eye on recent edits, because they could embed the login information in the URL: http://username:password at intranet/wiki/index.php/RecentChanges?format=rss But since PHPWiki authenticates via an HTML form, there's nothing they can do. So I guess I won't call this a silly feature anymore. chris. From ajai at bitblit.net Thu Nov 4 11:26:21 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Thu, 04 Nov 2004 11:26:21 -0500 Subject: [nycphp-talk] OT: Non-US AMP Hosting? Message-ID: <418A582D.1070802@bitblit.net> Anybody have experience with AMP hosting providers outside the US like maybe in Canada or Europe? -- Aj. Systems Administrator / Developer From mikeh at dtev.com Thu Nov 4 11:28:55 2004 From: mikeh at dtev.com (mike hjorleifsson) Date: Thu, 04 Nov 2004 11:28:55 -0500 Subject: [nycphp-talk] OT: Non-US AMP Hosting? In-Reply-To: <418A582D.1070802@bitblit.net> References: <418A582D.1070802@bitblit.net> Message-ID: <418A58C7.4070104@dtev.com> I am using one in germany Ajai Khattri wrote: > Anybody have experience with AMP hosting providers outside the US like > maybe in Canada or Europe? > -- ======================= Mike Hjorleifsson 1110 South Ave Staten Island, NY 10314 Direct Ph: 718-247-4263 Fx: 718-247-1673 Online Store: http://www.elementcomputer.com PLEASE NOTE: This e-mail message may contain confidential and privileged material for the sole use of the intended recipient(s). If you are not the intended recipient you are hereby notified that you have received this document in error and that any review, dissemination, distribution, or copying of this message is strictly prohibited. If you have received this communication in error,please contact me immediately by e-mail or by telephone at (888) 858-4ION and delete the original message and any copies. Thank you. From henry at beewh.com Thu Nov 4 11:25:50 2004 From: henry at beewh.com (Henry Ponce) Date: Thu, 4 Nov 2004 13:25:50 -0300 Subject: [nycphp-talk] OT: Non-US AMP Hosting? In-Reply-To: <418A582D.1070802@bitblit.net> References: <418A582D.1070802@bitblit.net> Message-ID: <200411041325.51027.henry@beewh.com> I use one in Argentina. Really good. Henry On Thursday 04 November 2004 13:26, Ajai Khattri wrote: > Anybody have experience with AMP hosting providers outside the US like > maybe in Canada or Europe? > > -- > Aj. > Systems Administrator / Developer > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > > From hans at cyberxdesigns.com Thu Nov 4 12:39:01 2004 From: hans at cyberxdesigns.com (Hans C. Kaspersetz) Date: Thu, 04 Nov 2004 12:39:01 -0500 Subject: [nycphp-talk] Testing PHP with Perl In-Reply-To: <20041028025918.32398.qmail@web52810.mail.yahoo.com> References: <20041028025918.32398.qmail@web52810.mail.yahoo.com> Message-ID: <418A6935.1070102@cyberxdesigns.com> Chris, I am about to post your presentation to NYPHP, how do you prefer I do it? Should I link to Geoff's site or copy the files to NYPHP's server and serve them up? Is he planning to leave those resources online indefinitely? Hans K Chris Shiflett wrote: >Geoff has posted our slides from last night's talk as well as a tarball >that you can play with: > >http://www.modperlcookbook.org/~geoff/slides/nyphp/ > >I hope everyone enjoyed the talk. There was a lot to talk about, so I know >it was hard to follow everything, especially since this is all very new >(even if you do a lot of testing already). Hopefully reviewing these >slides will help, and I plan to generate some better documentation once >we're further along. > >If you want to play with the tarball, just follow the steps in the INSTALL >file (it even gives you an example set of steps for installing Apache with >PHP, which you can probably skip). The sample application lives in >t/htdocs, and the tests are all *.t files within t. Examples of tests >written in PHP exist within t/response/TestFunctions. > >Lastly, as I've looked more into Simple Test and PHPUnit, these seem to >only be simplistic functions that can help you write unit tests (similar >to Test::More in Perl), but they provide no automated way to run these >tests nor an easy way to create a good test environment that resembles >production (testing from the command line? Yuck!). I'm not suggesting that >they've ever claimed to be more - I just wasn't sure. Until now, they've >been our best options for testing PHP applications, but no longer. :-) > >Because PHPUnit and Simple Test seem like good approaches to unit testing, >and because there are likely many developers who have a lot of tests >already written in these, I will probably write a compatability layer that >implements the same tests but with Test::More compatible output, so that >people can easily port tests to the Apache-Test framework. > >Chris > >===== >Chris Shiflett - http://shiflett.org/ > >PHP Security - O'Reilly HTTP Developer's Handbook - Sams >Coming December 2004 http://httphandbook.org/ >_______________________________________________ >New York PHP Talk >Supporting AMP Technology (Apache/MySQL/PHP) >http://lists.nyphp.org/mailman/listinfo/talk >http://www.newyorkphp.org > > > > > -- Hans C. Kaspersetz Cyber X Designs Office: 201-558-7929 Mobile: 201-681-4156 hans at cyberxdesigns.com http://www.cyberxdesigns.com From dcech at phpwerx.net Thu Nov 4 12:51:19 2004 From: dcech at phpwerx.net (Dan Cech) Date: Thu, 04 Nov 2004 12:51:19 -0500 Subject: [nycphp-talk] NEW PHundamentals Question - HTTP Authentication In-Reply-To: References: <41EE526EC2D3C74286415780D3BA9F870527CF70@ehost011-1.exch011.intermedia.net> Message-ID: <418A6C17.6030503@phpwerx.net> csnyder wrote: > If PHPWiki used HTTP authentication, then team members could use a > Newsreader to keep an eye on recent edits, because they could embed > the login information in the URL: > > http://username:password at intranet/wiki/index.php/RecentChanges?format=rss > > But since PHPWiki authenticates via an HTML form, there's nothing they > can do. So I guess I won't call this a silly feature anymore. Yep, this is a great way to keep track of stuff, and a good reason for HTTP Auth, at least for those readers which support it. Right now Thunderbird supports embedding Login information in feed URIs, which is great, however to be secure when using HTTP auth you really should use HTTPS, which isn't supported in Thunderbird. You can view more information about this bug here: https://bugzilla.mozilla.org/show_bug.cgi?id=254231 Another situation where supporting HTTP Auth is advantageous is for web services like XMLRPC. I recently implemented an XMLRPC server which could use either the typical session based logins (ie you request system.login first with your credentials then use the returned session id for future requests), or HTTP Auth for single requests. Dan > chris. From hans at cyberxdesigns.com Thu Nov 4 13:44:10 2004 From: hans at cyberxdesigns.com (Hans C. Kaspersetz) Date: Thu, 04 Nov 2004 13:44:10 -0500 Subject: [nycphp-talk] October Presentation Message-ID: <418A787A.6040200@cyberxdesigns.com> I have posted the October NYPHP presentation. Testing PHP with Perl: Two Great Tastes that Taste Great Together This October join New York PHP and recognized author Chris Shiflett and special guest Geoff Young as they look at the interesting combination of PHP and Perl. Stop by our IBM location to see how these two languages complement each other for testing. Lots of people use PHP for Web development. Lots of people use Perl for testing. Why can't we be friends? This fun but genuine talk will show how developers can use the power of the Apache-Test framework to improve the overall quality of PHP applications using Perl's mature testing tools and methodologies. See Chris and Geoff demonstrate valuable new techniques, combining the power of PHP and Perl. Platinum sponsor IBM has provided a great room with seating for plenty. http://www.nyphp.org/content/presentations/index.php We have posted the MP3, PDF of the presentation slides and a tarball of files. Very cool stuff! -- Hans Kaspersetz Cyber X Designs http://www.cyberxdesigns.com From suzerain at suzerain.com Thu Nov 4 15:35:48 2004 From: suzerain at suzerain.com (Marc Antony Vose) Date: Thu, 4 Nov 2004 15:35:48 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <418A5294.4080701@mlug.missouri.edu> References: <4b18871104110323064b45a2d8@mail.gmail.com> <418A5294.4080701@mlug.missouri.edu> Message-ID: At 8:02 AM -0800 11/4/04, Michael wrote: >>you are stuck with Plesk. > >Plesk annoyed the fsck out of me so I removed it. These ease of use >tools are not the way to have god like powers over your servers. :) > I suppose I should follow up my post, since this capability would be unique to virtual dedicated servers over straight virtual accounts: I have root access, and I could do anything I wanted to the account (including removing Plesk). In my case, however, I've chosen not to, because (mt) will basically stop giving you support if you have root access and remove Plesk (which seems perfectly sensible to me). As a lone contractor, I don't have time to field support calls from my clients, so I choose to work in a way where I can just forward their complaints to the Web host, or even tell them to contact them directly, unless it is something technically nuanced. Cheers, -- Marc Antony Vose http://www.suzerain.com/ They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety. -- Benjamin Franklin From shiflett at php.net Thu Nov 4 17:24:22 2004 From: shiflett at php.net (Chris Shiflett) Date: Thu, 4 Nov 2004 14:24:22 -0800 (PST) Subject: [nycphp-talk] Testing PHP with Perl In-Reply-To: <418A6935.1070102@cyberxdesigns.com> Message-ID: <20041104222422.33049.qmail@web52805.mail.yahoo.com> --- "Hans C. Kaspersetz" wrote: > I am about to post your presentation to NYPHP, how do you prefer > I do it? Should I link to Geoff's site or copy the files to > NYPHP's server and serve them up? Is he planning to leave those > resources online indefinitely? It doesn't matter to me. I'm sure Geoff has no plans to ever change the URL. All we really want is for people to realize how cool this is and start using it. :-) Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming January 2005 http://httphandbook.org/ From shiflett at php.net Thu Nov 4 18:36:55 2004 From: shiflett at php.net (Chris Shiflett) Date: Thu, 4 Nov 2004 15:36:55 -0800 (PST) Subject: [nycphp-talk] Testing PHP with Perl In-Reply-To: <418ABAB4.1060705@modperlcookbook.org> Message-ID: <20041104233655.80995.qmail@web52806.mail.yahoo.com> --- Geoffrey Young wrote: > > > I am about to post your presentation to NYPHP, how do you > > > prefer I do it? Should I link to Geoff's site or copy the > > > files to NYPHP's server and serve them up? Is he planning > > > to leave those resources online indefinitely? > > > > It doesn't matter to me. I'm sure Geoff has no plans to ever > > change the URL. > > nope, that url will stick around as long as the domain exists :) > > but you guys can feel free to slurp up the content too, if you want. > > > All we really want is for people to realize how cool this is > > and start using it. :-) > > and it's even cooler now :) Yes, it is. :-) I'm hoping to blog about this project before ApacheCon and give a fairly detailed overview about what it is and why PHP developers should care. The usefulness and coolness is already there - only the advocacy and documentation are missing. Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming February 2005 http://httphandbook.org/ From matt at atopia.net Fri Nov 5 01:28:29 2004 From: matt at atopia.net (Matt Juszczak) Date: Fri, 5 Nov 2004 01:28:29 -0500 (EST) Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <418A43D1.5020704@phpwerx.net> References: <4b18871104110323064b45a2d8@mail.gmail.com> <418A43D1.5020704@phpwerx.net> Message-ID: <20041105012815.S12382@neptune.atopia.net> serverpronto.com is very good. $29.99 fully dedicated server. I was with them for a year until recently. On Thu, 4 Nov 2004, Dan Cech wrote: > Jeff Loiselle wrote: >> I was just doing some research into budget virtual dedicated servers >> and thought I might "inquire within". >> >> a. Has anyone tried VDS hosting? > > Nope, but I have used http://www.linode.com for a little over a year > >> b. what kind of experience did you have? > > Good, the support is very good, the control panel is excellent. You not only > get root on your own UML (User Mode Linux) instance, but also access to a > virtual serial console, so you can watch your machine start up, etc. > >> c. what are the major factors to look for in a good VDS host? > > The biggest factor IMHO is the quality of the hardware and how many users are > sharing said hardware. > > Personally I have a Linode64 which is 64MB RAM, 4.5GB disk and 25GB/month > transfer for $242.62/yr. It's running a couple of reasonably low volume > websites and mail for a few domains, I wouldn't use it for more than that. > > The major limiting factor seems to be RAM, as the majority of VDS users don't > overly stress the CPU. > > If you move up a rung and pay $30/month you get a Linode128, with double the > RAM, more disk space and 38GB/month transfer. > > The strength of the VDS approach is that for $60/month you could have 2 > 'machines' on different hosts (eg a mailserver and webserver). > > Dan > >> TIA >> >> - Jeff Loiselle > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > > !DSPAM:418a49c98271389916787! > From hans at nyphp.com Fri Nov 5 17:04:52 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 5 Nov 2004 14:04:52 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers Message-ID: <41EE526EC2D3C74286415780D3BA9F870580E1CF@ehost011-1.exch011.intermedia.net> > I was just doing some research into budget virtual dedicated servers > and thought I might "inquire within". > > a. Has anyone tried VDS hosting? Yeah, in fact NYPHP is all based on VDS... > b. what kind of experience did you have? Excellent.. > c. what are the major factors to look for in a good VDS host? Well, from reading the rest of the thread, there are some important different technologies that are in play here, and different ways to do it. The most typical, popular, and best VDS solution is by way of FreeBSD jails. A jail gives a user root on their own virtual server, but at the same isolates them from the other root users on the physical server. There's also very little overhead in terms of performance, and people run hundreds of jails on a single server. Google for freebsd jail hosting or some such. Other options include vmware and Linux virtual stuff. vmware is nice, and delivers a virtual machine at the hardware level; that is, the OS sees it's own hardware, as opposed to a FreeBSD jail, which is OS dependant. The problem with vmware is it's resource intensive, and might be a problem for high load environment. Linux now also has a virtual kernel support. This basically means the kernel can load itself multiple times, providing some level of virtual services. The big problem with this is security, and I doubt people use it very often for mission critical servers. Go with FreeBSD jails - you won't even know you're on a shared box. If you have the money, I think Verio provides this service, but there are many other smaller shops who do a good job, too. Check out the NYCBUG (http://nycbug.org) Talk list; there are people who can recommend providers, since many of them do it themselves :) --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From ajai at bitblit.net Fri Nov 5 17:22:35 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Fri, 05 Nov 2004 17:22:35 -0500 Subject: [nycphp-talk] OT: Non-US AMP Hosting? In-Reply-To: <418A58C7.4070104@dtev.com> References: <418A582D.1070802@bitblit.net> <418A58C7.4070104@dtev.com> Message-ID: <418BFD2B.8060904@bitblit.net> mike hjorleifsson wrote: > I am using one in germany > > Ajai Khattri wrote: > >> Anybody have experience with AMP hosting providers outside the US >> like maybe in Canada or Europe? >> > I was looking for recommendations... -- Aj. Systems Administrator / Developer From mogmios at mlug.missouri.edu Fri Nov 5 18:05:10 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Fri, 05 Nov 2004 15:05:10 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870580E1CF@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F870580E1CF@ehost011-1.exch011.intermedia.net> Message-ID: <418C0726.6070109@mlug.missouri.edu> >Go with FreeBSD jails - you won't even know you're on a shared box. If >you have the money, I think Verio provides this service, but there are >many other smaller shops who do a good job, too. Check out the NYCBUG >(http://nycbug.org) Talk list; there are people who can recommend >providers, since many of them do it themselves :) > > Ugh. Verio was the worst hosting company I ever had. Constant hassles and their support sucked. Their prices weren't especially good either. -- Michael http://kavlon.org From listings at impulsenetwork.de Fri Nov 5 19:33:01 2004 From: listings at impulsenetwork.de (Andreas Gaisbauer) Date: Sat, 06 Nov 2004 01:33:01 +0100 Subject: [nycphp-talk] OT: Non-US AMP Hosting? In-Reply-To: <418A582D.1070802@bitblit.net> References: <418A582D.1070802@bitblit.net> Message-ID: <418C1BBD.4050206@impulsenetwork.de> Hi, I'm hosting on domainfactory.de - a german hoster. It's real cool - it features php5, ruby, python and even tcl :) ciao Andreas From 1j0lkq002 at sneakemail.com Fri Nov 5 20:30:57 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Fri, 05 Nov 2004 20:30:57 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <4b18871104110323064b45a2d8@mail.gmail.com> References: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: <16662-04847@sneakemail.com> Jeff Loiselle jeff.loiselle-at-gmail.com |nyphp dev/internal group use| wrote: >I was just doing some research into budget virtual dedicated servers >and thought I might "inquire within". > >a. Has anyone tried VDS hosting? >b. what kind of experience did you have? >c. what are the major factors to look for in a good VDS host? > >TIA > >- Jeff Loiselle >_______________________________________________ > > I used Westhost VDS for several clients and have used 2 others but wasn't the systems guy for those and don't even remember the details. I can say two things about it that might be helpful: 1. For me it's more about the hosting company and CP than the server technology, IMHO. That's just where 80% of the effort is spent after the architecture is set, and a bad CP or a bad host staff can ruin everything. It seems to me VDS vendors like to produce custom CPs (WestHost's is in PHP and is at best "ok" in my experience). 2. My systems guy had some issues with the VDS when he went to do fun stuff like syslog across the servers, BigBrother monitoring, and setting up data streams for the Arkeia backup system. When it got to that true systems level, where his expectation was that he'd have full root on a virtualized server, he found he did not. I'm sure Hans Z understands this stuff and I don't , but I uhnderstand there are some things that can't be chrooted, and when it comes to those you are locked out and once again reliant on the host staff, flexibility of their server setup etc etc. My guy was surprised to find so much was falling into that category, and VDS was not a solution (we went back to dedicated machines). -=john andrews From hans at nyphp.com Fri Nov 5 20:31:41 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 5 Nov 2004 17:31:41 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers Message-ID: <41EE526EC2D3C74286415780D3BA9F870580E35D@ehost011-1.exch011.intermedia.net> > >Go with FreeBSD jails - you won't even know you're on a shared box. If > >you have the money, I think Verio provides this service, but there are > >many other smaller shops who do a good job, too. Check out the NYCBUG > >(http://nycbug.org) Talk list; there are people who can recommend > >providers, since many of them do it themselves :) > > > > > Ugh. Verio was the worst hosting company I ever had. Constant hassles > and their support sucked. Their prices weren't especially good either. Fair enough - I have heard mixed things. I do have a couple of clients on their shared VPSs though, and have had good luck. Please note, I don't work for them... And that said, support your local hoster, which is why I say NYCBUG is a good resource. There are many skilled VPS hosters around. H From hans at nyphp.com Fri Nov 5 21:14:45 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 5 Nov 2004 18:14:45 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers Message-ID: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> > >I was just doing some research into budget virtual dedicated servers > >and thought I might "inquire within". > > > >a. Has anyone tried VDS hosting? > >b. what kind of experience did you have? > >c. what are the major factors to look for in a good VDS host? > > > >TIA > > > >- Jeff Loiselle > >_______________________________________________ > > > > > I used Westhost VDS for several clients and have used 2 others but > wasn't the systems guy for those and don't even remember the details. > > I can say two things about it that might be helpful: > > 1. For me it's more about the hosting company and CP than the server > technology, IMHO. That's just where 80% of the effort is spent after the > architecture is set, and a bad CP or a bad host staff can ruin > everything. It seems to me VDS vendors like to produce custom CPs > (WestHost's is in PHP and is at best "ok" in my experience). > > 2. My systems guy had some issues with the VDS when he went to do fun > stuff like syslog across the servers, BigBrother monitoring, and setting > up data streams for the Arkeia backup system. When it got to that true > systems level, where his expectation was that he'd have full root on a > virtualized server, he found he did not. I'm sure Hans Z understands > this stuff and I don't , but I uhnderstand there are some things that > can't be chrooted, and when it comes to those you are locked out and > once again reliant on the host staff, flexibility of their server setup > etc etc. My guy was surprised to find so much was falling into that > category, and VDS was not a solution (we went back to dedicated machines). These are valid points, but let me try to make one thing clear regarding the classing virtual server environment. To me, and it's quite possible I've misunderstood this entire thread, a VDS (virtual dedicated server) or VPS (virtual private server) are the same thing. And, this doesn't include a control panel. In fact, most of these providers simply supply a stripped down server, with root access. There are some limits, but in a typical web hosting environment, these aren't a factor. For instance, you can't (at least with a FreeBSD jail) use raw sockets. There's an important distinction between these types of services, and those that simply supply a chroot environment or other shared hosting. chroot supplies only one thing; it limits your directory access to below a specified directory. A jail, on the other hand, has implications on the entire server picture that you see. This means that users are up to you, processes are up to you, etc. A VPS/VDS won't typically provide a control panel because they expect you to either configure your own, or not need one at all. At the end of the day, a VPS/VDS gives you all the root functionality you need for an AMP deployment, and you wouldn't even notice that you are in fact sharing the hardware with someone else. This also means that it's unlikely there are any services running; although they might be nice enough to get some level of email running for you. The only production level implementation of this is using FreeBSD jails, which is deployed using this technology: http://www.freebsd.org/doc/en_US.ISO8859-1/books/arch-handbook/jail.html --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From hans at nyphp.com Fri Nov 5 21:24:18 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 5 Nov 2004 18:24:18 -0800 Subject: [nycphp-talk] New York PHP Resources WAS: Idea for PHP site (series of articles) Message-ID: <41EE526EC2D3C74286415780D3BA9F870580E389@ehost011-1.exch011.intermedia.net> > The original question asked "what do you guys think of this idea for a new > web site", it seems most people so far agree this would be a good idea to > have such guidelines online. My thought is that why not put this information > on NYPHP, perhaps as part of the phundamentals? And just to followup on this topic, we have much of this in place already. I've outlined what New York PHP is already on this front. Getting Your Experiences and Information "Out There" New York PHP has developed four different ways to get your information published and public so that others can learn from your experiences and insight. NYPHP has worked hard to make these options available to our community, and we hope that people will take advantage of them. 1) Talk List Participation in the Talk List is the easiest and least formal way to share your knowledge with others. All you need to do is respond to the questions posted by other developers. See: http://lists.nyphp.org/mailman/listinfo/talk This is the obvious one, since you wouldn't see this post unless you already knew about it. 2) PHundamentals Sometimes a particular hot topic appears on the Talk List which becomes the basis of a PHundamentals article. The guiding principle behind a PHundamentals article is that it should be the distillation of the ideas and methods for numerous developers for handling a particular programming issue. The result, after much debate, is a best practice for dealing with a particular programming issue or concepts. See: http://education.nyphp.org/phundamentals/ Article ideas, which are candidates for a PHundamental, can be submitted to Jeff Siegel (jeff.siegel not junk at nyphp.org). 3) AMPeers Sometimes a topic can be handled by a single author (or two). That is, it does not require back-and-forth debate and can be presented, as-is, as a complete article on a topic. This would be a candidate for AMPeers. AMPeers came out of the need for people to be able to publish their articles on various topics. Unlike PHundamentals, which is a large collaborative effort that establishes best-practices via Talk list debate, AMPeers are general experiences shared by the authors. AMPeers is ready to launch, and we hope that the NYPHP members who want to write will submit articles to share with the community. You can send your articles to Jasper Lin (jasper.lin not junk at nyphp.org), who is the AMPeers Project Manager. A beta site is already in place, and we'll be making a formal announcement within the next couple of days. 4) Projects If you have an idea that would require programming to get it out there (e.g., a code repository), then that would be a candidate for a project. You should then follow the guidelines for submitting a project at: http://www.nyphp.org/content/presentations/nyphp/index.php?slide=10 Please contact Hans Kaspersetz (hans.kaspersetz not junk at nyphp.org) to talk about projects. New York PHP strives to bring information and resources together in one place, so that our members worldwide have easy access to them, and to form channels for people to get their own articles published. I hope that everyone will take advantage of these resources, and please don't hesitate to contact me directly with any questions. --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From fields at surgam.net Fri Nov 5 21:31:31 2004 From: fields at surgam.net (Adam Fields) Date: Fri, 5 Nov 2004 21:31:31 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> Message-ID: <20041106023131.GA25551@lola.aquick.org> On Fri, Nov 05, 2004 at 06:14:45PM -0800, Hans Zaunere wrote: [...] > At the end of the day, a VPS/VDS gives you all the root functionality > you need for an AMP deployment, and you wouldn't even notice that you > are in fact sharing the hardware with someone else. This also means > that it's unlikely there are any services running; although they might > be nice enough to get some level of email running for you. > > The only production level implementation of this is using FreeBSD jails, > which is deployed using this technology: That's poppycock. I run several production systems (+100K PV/month) on linux virtual servers. They're just fine for many sites. Again - I'd check out rosehosting.com. They come preinstalled with a bunch of stuff (you can do your own DNS if you want), and their support is good. Tell 'em I sent you. -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From hans at nyphp.com Fri Nov 5 21:31:28 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 5 Nov 2004 18:31:28 -0800 Subject: [nycphp-talk] NEW PHundamentals Question - HTTP Authentication Message-ID: <41EE526EC2D3C74286415780D3BA9F870580E38C@ehost011-1.exch011.intermedia.net> > I just discovered a really great reason to use PHP's built-in support > for HTTP authentication. > > At work, we have a PHPWiki set up for some of the developers. It's > completely private, you have to log in to view anything. It also has > an RSS feed that you can use to track recently edited pages. > > If PHPWiki used HTTP authentication, then team members could use a > Newsreader to keep an eye on recent edits, because they could embed > the login information in the URL: > > http://username:password at intranet/wiki/index.php/RecentChanges?format=rs s > > But since PHPWiki authenticates via an HTML form, there's nothing they > can do. So I guess I won't call this a silly feature anymore. That's an excellent point, and probably something no one thinks about when considering HTTP Auth. That said, however, I think the perfect solution would be to convert the HTTP auth into a form auto mechanism. I haven't looked at the headers a URL like the above generates, but I'm sure it possible to redirect that into a non HTTP auth form post? --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From hans at nyphp.com Fri Nov 5 21:41:50 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 5 Nov 2004 18:41:50 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers Message-ID: <41EE526EC2D3C74286415780D3BA9F870580E38E@ehost011-1.exch011.intermedia.net> > > At the end of the day, a VPS/VDS gives you all the root functionality > > you need for an AMP deployment, and you wouldn't even notice that you > > are in fact sharing the hardware with someone else. This also means > > that it's unlikely there are any services running; although they might > > be nice enough to get some level of email running for you. > > > > The only production level implementation of this is using FreeBSD jails, > > which is deployed using this technology: > > That's poppycock. I run several production systems (+100K PV/month) on > linux virtual servers. > > They're just fine for many sites. If you're sharing hardware with strangers, I'd read into the architecture of LVM. There's little to prevent me from loading my own kernel, having nearly full control of the hardware, and doesn't prevent raw sockets. LVM was originally developed for development purposes, which made it easy to load various kernels. It's great for that, but does very little in limiting the power of the loaded kernel. --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From 1j0lkq002 at sneakemail.com Fri Nov 5 22:25:16 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Fri, 05 Nov 2004 22:25:16 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> Message-ID: <15110-02089@sneakemail.com> Hans Zaunere hans-at-nyphp.com |nyphp dev/internal group use| wrote: >... > >A jail, on the other hand, has implications on the entire server picture >that you see. This means that users are up to you, processes are up to >you, etc. A VPS/VDS won't typically provide a control panel because >they expect you to either configure your own, or not need one at all. > >At the end of the day, a VPS/VDS gives you all the root functionality >you need for an AMP deployment, and you wouldn't even notice that you >are in fact sharing the hardware with someone else. This also means >that it's unlikely there are any services running; although they might >be nice enough to get some level of email running for you. > > This matches my experience. When I went to VDS it was at the time that VMWare 3 was out, and IBM was touting fully virtualized server hardware running Linux, virtualized on an AS/400. They had used a mainframe to host hundreds of virtual server environments, each running Linux, in a way similar to VMWare's virtualized hardware environment - with code emulating the hardware interface. The kernel didn't know whether it was hardware responding or virtual hardware. The entire kernel was dedciated to the one virtual server. That is apparantly *not* what VDS/VPS is... I'll leave the real technical stuf to you guys. -=john andrews From chsnyder at gmail.com Fri Nov 5 22:38:17 2004 From: chsnyder at gmail.com (csnyder) Date: Fri, 5 Nov 2004 22:38:17 -0500 Subject: [nycphp-talk] NEW PHundamentals Question - HTTP Authentication In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870580E38C@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F870580E38C@ehost011-1.exch011.intermedia.net> Message-ID: > I haven't looked at the headers a > URL like the above generates, but I'm sure it possible to redirect that > into a non HTTP auth form post? The client sends an Authorization header, which is the username:password string in base64 encoding. So it should be possible for your authorization scheme to check for and honor the existence of that header... From mogmios at mlug.missouri.edu Sat Nov 6 07:08:31 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Sat, 06 Nov 2004 04:08:31 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <15110-02089@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> Message-ID: <418CBEBF.1050407@mlug.missouri.edu> So the real question is why would anyone want to use a virtual dedicated server when you can get a real dedicated server for about the same price? The main benefit I can see is that in theory you can pay for only the amount of computing power you need and upgrade easily. In my experience it doesn't work out that well and it's just as easy to just have add a new didcated server when you need more power and balance your load across all your servers. As far as web hosting goes at least. What other reasons would I have to use a virtual server? I suppose it might be possible to move your entire virtual server to a new real server, as a single file, in case of a hardware failure which might save you time and money? -- Michael http://kavlon.org From tgales at tgaconnect.com Sat Nov 6 08:30:40 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Sat, 6 Nov 2004 08:30:40 -0500 Subject: [nycphp-talk] New York PHP Resources WAS: Idea for PHP site (seriesof articles) In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870580E389@ehost011-1.exch011.intermedia.net> Message-ID: <000401c4c404$cfe6f6f0$e98d3818@oberon1> > Hans Zaunere > Sent: Friday, November 05, 2004 9:24 PM > To: NYPHP Talk > Subject: [nycphp-talk] New York PHP Resources WAS: Idea for > PHP site (seriesof articles) > > And just to followup on this topic, we have much of this in > place already. I've outlined what New York PHP is already on > this front. > > Getting Your Experiences and Information "Out There" > > New York PHP has developed four different ways to get your > information published and public so that others can learn > from your experiences and insight. NYPHP has worked hard to > make these options available to our community, and we hope > that people will take advantage of them. > > > 1) Talk List > ... > > 2) PHundamentals > ... > > 3) AMPeers > ... > AMPeers is ready to launch... > A beta site is already in place, and we'll be making a formal > announcement within the next couple of days.... (from another list -- hmmn, would have been nice to 'Conversationally Link this Email) > This is a great summary of what we've got... can we work this into an > announcement and page for the nyphp.org site so that when AMPeers is > ready to go, we can get all this stuff public? Since the formal announcement for AMPeers is being readied, is there anything to more to be done on getting the explanatory page ready (or the announcement) -- your post seems to pretty much cover things. I am attaching an old post (as a reminder), because it mentions the fact that you don't have to be a PHP master to be able to contribute. Maybe this idea should somehow be worked into the summary page. > 4) Projects > ... > New York PHP strives to bring information and resources > together in one place, so that our members worldwide have > easy access to them, and to form channels for people to get > their own articles published... > Along the lines of 'easy access', maybe there could be a menu item in the left column called 'site map' or something like that. Regards, Tim G. -------------- next part -------------- An embedded message was scrubbed... From: "Tim Gales" Subject: [nycphp-talk] Publishing on the New York PHP website Date: Sun, 26 Sep 2004 09:03:07 -0500 Size: 8352 URL: From fields at surgam.net Sat Nov 6 08:47:07 2004 From: fields at surgam.net (Adam Fields) Date: Sat, 6 Nov 2004 08:47:07 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <41EE526EC2D3C74286415780D3BA9F870580E38E@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F870580E38E@ehost011-1.exch011.intermedia.net> Message-ID: <20041106134707.GC7449@lola.aquick.org> On Fri, Nov 05, 2004 at 06:41:50PM -0800, Hans Zaunere wrote: > If you're sharing hardware with strangers, I'd read into the > architecture of LVM. There's little to prevent me from loading my own > kernel, having nearly full control of the hardware, and doesn't prevent > raw sockets. > > LVM was originally developed for development purposes, which made it > easy to load various kernels. It's great for that, but does very little > in limiting the power of the loaded kernel. I'mn sorry, I wasn't clear - I meant "linux-based virtual servers", as opposed to freebsd jails, not lvm. Rosehosting says: "We are using an in-house built solution. We do not use any commercially/publicly available virtualization software. This gives us much greater control and flexibility in it's development and maintenance. Most of the commercial solutions (virtuozzo, etc...) have big problems and limitations and were created with the hosting company in mind, not the end user." Which obviously says nothing about whether they're secure or not. I'd be interested in the kinds of tests one might perform to see if access to the rest of the box is available to others on the box. -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From webmaster at localnotion.com Sat Nov 6 09:37:14 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Sat, 6 Nov 2004 09:37:14 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <418CBEBF.1050407@mlug.missouri.edu> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> <418CBEBF.1050407@mlug.missouri.edu> Message-ID: <5A210FBA-3001-11D9-A001-0003938BDF32@localnotion.com> > So the real question is why would anyone want to use a virtual > dedicated server when you can get a real dedicated server for about > the same price? That is generally not the case. I did see that serverpronto had a dedicated server for $30, the lowest I've ever seen and a price that low even scares me a little. But I've had a Virtual Private Server for $10 a month. Root access for $10 a month! Please point me to the Dedicated server for that price, I'll take ten. Matt On Nov 6, 2004, at 7:08 AM, Michael wrote: > The main benefit I can see is that in theory you can pay for only the > amount of computing power you need and upgrade easily. In my > experience it doesn't work out that well and it's just as easy to just > have add a new didcated server when you need more power and balance > your load across all your servers. As far as web hosting goes at > least. > > What other reasons would I have to use a virtual server? I suppose it > might be possible to move your entire virtual server to a new real > server, as a single file, in case of a hardware failure which might > save you time and money? > > -- > Michael > http://kavlon.org > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From mogmios at mlug.missouri.edu Sat Nov 6 17:47:40 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Sat, 06 Nov 2004 14:47:40 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <5A210FBA-3001-11D9-A001-0003938BDF32@localnotion.com> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> <418CBEBF.1050407@mlug.missouri.edu> <5A210FBA-3001-11D9-A001-0003938BDF32@localnotion.com> Message-ID: <418D548C.5020603@mlug.missouri.edu> > That is generally not the case. I did see that serverpronto had a > dedicated server for $30, the lowest I've ever seen and a price that > low even scares me a little. > But I've had a Virtual Private Server for $10 a month. Root access for > $10 a month! Please point me to the Dedicated server for that price, > I'll take ten. How much bandwidth, CPU, RAM, and hdd space does that include? I pay $50/month for a real server. I've seen cheaper offers but the difference was so little that I didn't really care. What I'd really like is a local hosting company with a huge pipe that'd let me bring my own box in and plug it in. Disk space is always my one problem with hosted solutions as their idea of enough disk space is several zerors short of my idea of enough disk space. I'd love to have 5TB of space on a server - I could make something pretty cool with that kind of space. The closest I've came to that solution so far is to put up a local server in my home and use my real server as a proxy that caches requested objects. -- Michael http://kavlon.org From webmaster at localnotion.com Sat Nov 6 23:24:47 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Sat, 6 Nov 2004 23:24:47 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <418D548C.5020603@mlug.missouri.edu> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> <418CBEBF.1050407@mlug.missouri.edu> <5A210FBA-3001-11D9-A001-0003938BDF32@localnotion.com> <418D548C.5020603@mlug.missouri.edu> Message-ID: On Nov 6, 2004, at 5:47 PM, Michael wrote: > >> That is generally not the case. I did see that serverpronto had a >> dedicated server for $30, the lowest I've ever seen and a price that >> low even scares me a little. >> But I've had a Virtual Private Server for $10 a month. Root access >> for $10 a month! Please point me to the Dedicated server for that >> price, I'll take ten. > > How much bandwidth, CPU, RAM, and hdd space does that include? I pay > $50/month for a real server. I've seen cheaper offers but the > difference was so little that I didn't really care. I'm sorry, we live in different worlds if $10 or $50 doesn't make a difference. > > What I'd really like is a local hosting company with a huge pipe > that'd let me bring my own box in and plug it in. Disk space is always > my one problem with hosted solutions as their idea of enough disk > space is several zerors short of my idea of enough disk space. I'd > love to have 5TB of space on a server - I could make something pretty > cool with that kind of space. The closest I've came to that solution > so far is to put up a local server in my home and use my real server > as a proxy that caches requested objects. > > -- > Michael > http://kavlon.org > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From mogmios at mlug.missouri.edu Sun Nov 7 17:13:02 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Sun, 07 Nov 2004 14:13:02 -0800 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> <418CBEBF.1050407@mlug.missouri.edu> <5A210FBA-3001-11D9-A001-0003938BDF32@localnotion.com> <418D548C.5020603@mlug.missouri.edu> Message-ID: <418E9DEE.9080704@mlug.missouri.edu> >> How much bandwidth, CPU, RAM, and hdd space does that include? I pay >> $50/month for a real server. I've seen cheaper offers but the >> difference was so little that I didn't really care. > > I'm sorry, we live in different worlds if $10 or $50 doesn't make a > difference. Maybe I should rephrase - the cheaper offers didn't interest me because they didn't seem to offer as much or have the same level of customer support. -- Michael http://kavlon.org From chsnyder at gmail.com Sun Nov 7 17:48:46 2004 From: chsnyder at gmail.com (csnyder) Date: Sun, 7 Nov 2004 17:48:46 -0500 Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <418D548C.5020603@mlug.missouri.edu> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> <418CBEBF.1050407@mlug.missouri.edu> <5A210FBA-3001-11D9-A001-0003938BDF32@localnotion.com> <418D548C.5020603@mlug.missouri.edu> Message-ID: > What I'd really like is a local hosting company with a huge pipe that'd > let me bring my own box in and plug it in. I thought that was the default colocation setup -- you rent rackspace for something like $30 per U per month, which includes some amount of bandwidth. Then you pay for extra bandwidth a la carte. If you ask around enough (and buy the right people drinks) you'll eventually find someone who leases a full rack somewhere, and is willing to let you buy in. You get a discount on what the datacenter would charge you for a single space, and they get break on their overhead. > I'd love to have > 5TB of space on a server - I could make something pretty cool with that > kind of space. Amen, brother. Although it would take nerves of steel to hand over my shiny new 5TB sever to someone else. From john at coggeshall.org Mon Nov 8 01:07:25 2004 From: john at coggeshall.org (John Coggeshall) Date: Mon, 08 Nov 2004 01:07:25 -0500 Subject: [nycphp-talk] simplexml, gentoo emerge In-Reply-To: <7e2c731f0410201944651a79f6@mail.gmail.com> References: <7e2c731f04101923443404f83b@mail.gmail.com> <4176733A.5050808@bitblit.net> <7e2c731f04102008231fb2a73a@mail.gmail.com> <41768F71.6020902@bitblit.net> <7e2c731f0410201944651a79f6@mail.gmail.com> Message-ID: <1099894045.25380.2.camel@localhost.localdomain> On Wed, 2004-10-20 at 22:44, chris feldmann wrote: > I ask because though simplexml commands are enabled by default, I > notice on phpinfo() that it was configured with --disable-libxml. I'm > wondering if that might be a problem. Note that this was *with* the That is the problem. All XML functionality in PHP 5 requires libxml. John From flakie at gmail.com Mon Nov 8 12:25:31 2004 From: flakie at gmail.com (Eric Rank) Date: Mon, 8 Nov 2004 11:25:31 -0600 Subject: [nycphp-talk] webservices anyone? Message-ID: Has anyone had success with web services in PHP? I'm have a need for 2 php based web servers to talk to each other (in order to do some database syncing) and I thought that webservices would be a good way to do this. I haven't done much with web services and I'm looking for a starting point for writing a SOAP client and SOAP server. Has anyone tried PEAR::SOAP? Is there a better way to do some DB syncing? Thanks for the tips, Eric Rank From tgales at tgaconnect.com Mon Nov 8 12:34:51 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Mon, 8 Nov 2004 12:34:51 -0500 Subject: [nycphp-talk] webservices anyone? Message-ID: <200411081734.iA8HYpJ10896@tgaconnect.com> > Is there a better way to do > some DB syncing? > http://dev.mysql.com/doc/mysql/en/Replication.html (needs at least version 4.1 ) T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com From tgales at tgaconnect.com Mon Nov 8 12:39:36 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Mon, 8 Nov 2004 12:39:36 -0500 Subject: [nycphp-talk] webservices anyone? Message-ID: <200411081739.iA8HdaD11701@tgaconnect.com> > (needs at least version 4.1 ) should have read: 'at least vers. 4.1 recommended) Tim G. From rolan at omnistep.com Mon Nov 8 12:39:29 2004 From: rolan at omnistep.com (Rolan Yang) Date: Mon, 08 Nov 2004 12:39:29 -0500 Subject: [nycphp-talk] webservices anyone? In-Reply-To: <200411081734.iA8HYpJ10896@tgaconnect.com> References: <200411081734.iA8HYpJ10896@tgaconnect.com> Message-ID: <418FAF51.1060601@omnistep.com> Tim Gales wrote: >>Is there a better way to do >>some DB syncing? >> >> >> > http://dev.mysql.com/doc/mysql/en/Replication.html > >(needs at least version 4.1 ) > > > > It does work with earlier versions. I've done replication with 3.23.x ~Rolan From flakie at gmail.com Mon Nov 8 12:51:43 2004 From: flakie at gmail.com (Eric Rank) Date: Mon, 8 Nov 2004 11:51:43 -0600 Subject: [nycphp-talk] webservices anyone? In-Reply-To: <418FAF51.1060601@omnistep.com> References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: Great, looks interesting.... I'm still curious about webservices though. Anyone out there with experiences? Eric. On Mon, 08 Nov 2004 12:39:29 -0500, Rolan Yang wrote: > > Tim Gales wrote: > > >>Is there a better way to do > >>some DB syncing? > >> > >> > >> > > http://dev.mysql.com/doc/mysql/en/Replication.html > > > >(needs at least version 4.1 ) > > > > > > > > > > It does work with earlier versions. I've done replication with 3.23.x > > ~Rolan > > > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From adam at trachtenberg.com Mon Nov 8 12:58:48 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Mon, 8 Nov 2004 12:58:48 -0500 (EST) Subject: [nycphp-talk] webservices anyone? In-Reply-To: References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: On Mon, 8 Nov 2004, Eric Rank wrote: > I'm still curious about webservices though. Anyone out there with > experiences? What do you want to do? What information do you want to exchange? Who do you want to communicate with? -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From flakie at gmail.com Mon Nov 8 13:39:30 2004 From: flakie at gmail.com (Eric Rank) Date: Mon, 8 Nov 2004 12:39:30 -0600 Subject: [nycphp-talk] webservices anyone? In-Reply-To: References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: > What do you want to do? What information do you want to > exchange? Who do you want to communicate with? My end goal is to have multiple affiliated websites use data from one database. Ultimately, I'd like to have the data reside on each server locally so I don't have to have the ridiculous overhead of making database requests between 2 points on the globe. My idea was to set up a sort of meta-table which would keep track of all the transactions in a database. Then, when a site needs to update it's data, it requests (via web service) all of the transactions since the last time it updated it's records, from the master database server. Then, the client retrieves the response from the SOAP server, and updates it;s records accodingly. I do realize that having such a meta-table keeping track of all the transactions in a database would be a bunch of overhead too. However, for this project, there's < 100 records per week, so it's not completely out of line. The reason I thought that web services would work well has to do with the potentially complex set of requests that I would be making remotely and the relative complex (xml) structure of the results. These sites are hosted on mainstream hosting servers, so I don't have a ton of control over using things like MySQL replication techniques... but I AM looking deeper into that solution. Thanks, Eric From mitch.pirtle at gmail.com Mon Nov 8 13:48:11 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 8 Nov 2004 13:48:11 -0500 Subject: [nycphp-talk] webservices anyone? In-Reply-To: References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: <330532b6041108104856c43beb@mail.gmail.com> I'm a PostgreSQL guy, but I am fairly confident that you could hook into MySQL's query log, and parse based on timestamps. In a sense you wouldn't even need XML, as you could just transport the data from the logfile. Assuming both servers are running compatible versions of MySQL, wouldn't this be the easiest (and therefore less error-prone) approach? -- Mitch, moving back to Server Beach *sigh* On Mon, 8 Nov 2004 12:39:30 -0600, Eric Rank wrote: > > What do you want to do? What information do you want to > > exchange? Who do you want to communicate with? > > > My end goal is to have multiple affiliated websites use data from one > database. Ultimately, I'd like to have the data reside on each server > locally so I don't have to have the ridiculous overhead of making > database requests between 2 points on the globe. From rrust at r2communications.com Mon Nov 8 13:53:49 2004 From: rrust at r2communications.com (Randal Rust) Date: Mon, 08 Nov 2004 13:53:49 -0500 Subject: [nycphp-talk] E-Commerce Packages Message-ID: <418FC0BD.6030705@r2communications.com> I have a client that has asked for me to take over the development of their e-commerce app. I can easily create the pieces/parts for entering and managing data such as products, categories, users, etc. But the client also needs some additional functionality that I've never built from scratch, such as online payment processing via a gateway. So I started looking at osCommerce, and quite frankly, can't make heads or tails out of the code. I would need to make some modifications in order to fulfill some of the requirements, but it would take me forever to figure out what is going on in osCommerce. I've been working with PHP for about three years now, and do most of my development in OOP these days, but osCommerce is just way over my head. Does anyone have any suggestions for other packages I should look at? -- Randal Rust R.Squared Communications http://www.r2communications.com Digital Design for Bricks-and-Mortar Businesses From adam at trachtenberg.com Mon Nov 8 14:02:28 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Mon, 8 Nov 2004 14:02:28 -0500 (EST) Subject: [nycphp-talk] webservices anyone? In-Reply-To: References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: On Mon, 8 Nov 2004, Eric Rank wrote: > I do realize that having such a meta-table keeping track of all the > transactions in a database would be a bunch of overhead > too. However, for this project, there's < 100 records per week, so > it's not completely out of line. Are updates occurring in one or two directions? On the whole, I wouldn't bother with all the overhead of a soap. I would just dump the update log someplace and fetch it using cron. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From mitch.pirtle at gmail.com Mon Nov 8 14:04:45 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Mon, 8 Nov 2004 14:04:45 -0500 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <418FC0BD.6030705@r2communications.com> References: <418FC0BD.6030705@r2communications.com> Message-ID: <330532b604110811042bdf666f@mail.gmail.com> I've been playing with phpShop now that it has been integrated with Mambo, and can say that it is certainly full-featured and mature. Have not spent the brain cycles to work with the code however, so my opinion is from the end-user perspective. -- Mitch On Mon, 08 Nov 2004 13:53:49 -0500, Randal Rust wrote: > I have a client that has asked for me to take over the development of > their e-commerce app. > > I can easily create the pieces/parts for entering and managing data such > as products, categories, users, etc. But the client also needs some > additional functionality that I've never built from scratch, such as > online payment processing via a gateway. > > So I started looking at osCommerce, and quite frankly, can't make heads > or tails out of the code. I would need to make some modifications in > order to fulfill some of the requirements, but it would take me forever > to figure out what is going on in osCommerce. I've been working with PHP > for about three years now, and do most of my development in OOP these > days, but osCommerce is just way over my head. > > Does anyone have any suggestions for other packages I should look at? > > -- > Randal Rust > > R.Squared Communications > http://www.r2communications.com > Digital Design for Bricks-and-Mortar Businesses > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From dmintz at davidmintz.org Mon Nov 8 14:15:42 2004 From: dmintz at davidmintz.org (David Mintz) Date: Mon, 8 Nov 2004 14:15:42 -0500 (EST) Subject: [nycphp-talk] webservices anyone (MySQL replication) In-Reply-To: <418FAF51.1060601@omnistep.com> References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: On Mon, 8 Nov 2004, Rolan Yang wrote: > > Tim Gales wrote: > > >>Is there a better way to do > >>some DB syncing? > > http://dev.mysql.com/doc/mysql/en/Replication.html > > > >(needs at least version 4.1 ) > > It does work with earlier versions. I've done replication with 3.23.x But maybe it's considerably more reliable in 4.1 ? Because I played with it in 4.0.x on 2 Windows boxes for quite a while and the slave kept falling out of sync and giving up. I myself got annoyed and gave up (for now). --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From flakie at gmail.com Mon Nov 8 14:25:11 2004 From: flakie at gmail.com (Eric Rank) Date: Mon, 8 Nov 2004 13:25:11 -0600 Subject: [nycphp-talk] webservices anyone? In-Reply-To: References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: Indeed, that seems like a much easier way to go. I'll take a closer look into doing things with the logs Thanks, E. From preinheimer at gmail.com Mon Nov 8 14:27:17 2004 From: preinheimer at gmail.com (Paul Reinheimer) Date: Mon, 8 Nov 2004 14:27:17 -0500 Subject: [nycphp-talk] webservices anyone? In-Reply-To: References: <200411081734.iA8HYpJ10896@tgaconnect.com> <418FAF51.1060601@omnistep.com> Message-ID: <6ec19ec70411081127280b9a70@mail.gmail.com> flat files and rsync? On Mon, 8 Nov 2004 13:25:11 -0600, Eric Rank wrote: > Indeed, that seems like a much easier way to go. I'll take a closer > look into doing things with the logs > > Thanks, > > E. > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- Paul Reinheimer Zend Certified Engineer From ajai at bitblit.net Mon Nov 8 14:35:40 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Mon, 08 Nov 2004 14:35:40 -0500 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <418FC0BD.6030705@r2communications.com> References: <418FC0BD.6030705@r2communications.com> Message-ID: <418FCA8C.2080706@bitblit.net> Randal Rust wrote: > I have a client that has asked for me to take over the development of > their e-commerce app. > > I can easily create the pieces/parts for entering and managing data > such as products, categories, users, etc. But the client also needs > some additional functionality that I've never built from scratch, such > as online payment processing via a gateway. > > So I started looking at osCommerce, and quite frankly, can't make > heads or tails out of the code. I would need to make some > modifications in order to fulfill some of the requirements, but it > would take me forever to figure out what is going on in osCommerce. > I've been working with PHP for about three years now, and do most of > my development in OOP these days, but osCommerce is just way over my > head. > > Does anyone have any suggestions for other packages I should look at? > Ive played with oscommerce and found it a pain to use. Currently playing with Mambo with the phpshop plugin... -- Aj. Systems Administrator / Developer From dorgan at optonline.net Mon Nov 8 14:39:53 2004 From: dorgan at optonline.net (Donald J. Organ IV) Date: Mon, 08 Nov 2004 14:39:53 -0500 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <418FCA8C.2080706@bitblit.net> References: <418FC0BD.6030705@r2communications.com> <418FCA8C.2080706@bitblit.net> Message-ID: <418FCB89.2050805@optonline.net> how do you go about capturing though, because from what i know xbox doesnt have a tuner From sailer at bnl.gov Mon Nov 8 14:43:25 2004 From: sailer at bnl.gov (Tim Sailer) Date: Mon, 8 Nov 2004 14:43:25 -0500 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <418FCB89.2050805@optonline.net> References: <418FC0BD.6030705@r2communications.com> <418FCA8C.2080706@bitblit.net> <418FCB89.2050805@optonline.net> Message-ID: <20041108194325.GA4313@bnl.gov> On Mon, Nov 08, 2004 at 02:39:53PM -0500, Donald J. Organ IV wrote: > how do you go about capturing though, because from what i know xbox > doesnt have a tuner Wrong list? Maybe Mythtv? :) Tim -- Tim Sailer Information and Special Technologies Program Office of CounterIntelligence Brookhaven National Laboratory (631) 344-3001 From dorgan at optonline.net Mon Nov 8 14:44:16 2004 From: dorgan at optonline.net (Donald J. Organ IV) Date: Mon, 08 Nov 2004 14:44:16 -0500 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <20041108194325.GA4313@bnl.gov> References: <418FC0BD.6030705@r2communications.com> <418FCA8C.2080706@bitblit.net> <418FCB89.2050805@optonline.net> <20041108194325.GA4313@bnl.gov> Message-ID: <418FCC90.2060404@optonline.net> yeah i dont know how that happened...lol.....sorry From tommyo at gmail.com Mon Nov 8 14:46:48 2004 From: tommyo at gmail.com (Thomas O'Neill) Date: Mon, 8 Nov 2004 13:46:48 -0600 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <418FCC90.2060404@optonline.net> References: <418FC0BD.6030705@r2communications.com> <418FCA8C.2080706@bitblit.net> <418FCB89.2050805@optonline.net> <20041108194325.GA4313@bnl.gov> <418FCC90.2060404@optonline.net> Message-ID: there is a commercial one out there called x-cart that i recommend. It uses smarty for templates so it is very simple to modify. On Mon, 08 Nov 2004 14:44:16 -0500, Donald J. Organ IV wrote: > yeah i dont know how that happened...lol.....sorry > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- Tom O'Neill tommyo at gmail.com http://www.dolemite.org From hans at cyberxdesigns.com Mon Nov 8 14:51:52 2004 From: hans at cyberxdesigns.com (Hans C. Kaspersetz) Date: Mon, 08 Nov 2004 14:51:52 -0500 Subject: [nycphp-talk] E-Commerce Packages In-Reply-To: <418FC0BD.6030705@r2communications.com> References: <418FC0BD.6030705@r2communications.com> Message-ID: <418FCE58.3080905@cyberxdesigns.com> I have had a lot of luck using X-Cart. I have rolled out two site this year on it. One with 600+ products and the other with 15 products. The 600+ product implementation needed a lot of customization because of thiner wacky inventory system and the way the product is grouped when sold. Both implementations were completely reskined. I am very happy with X-Cart. I have had not problems adding the custom elements I needed. I have found their staff and the forums very very helpful and it is under active development so patches are released regularly. http://www.x-cart.com/ If you have any questions about X-Cart do not hesitate to email me off list. -- Hans C. Kaspersetz Cyber X Designs http://www.cyberxdesigns.com From webmaster at localnotion.com Mon Nov 8 15:07:18 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Mon, 8 Nov 2004 15:07:18 -0500 Subject: [nycphp-talk] sessions and load balancing Message-ID: At the point where traffic becomes so great that load balancing is in order, what happens to sessions? Put another way: For applications using sessions, what are some strategies for being able to scale to a multiple box level? From adam at trachtenberg.com Mon Nov 8 15:15:15 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Mon, 8 Nov 2004 15:15:15 -0500 (EST) Subject: [nycphp-talk] sessions and load balancing In-Reply-To: References: Message-ID: On Mon, 8 Nov 2004, Matthew Terenzio wrote: > For applications using sessions, what are some strategies for being > able to scale to a multiple box level? * Store session on client (cookies) * Store session on separate database server shared among all web servers (probably the way to go at first). * Use specialized session server (like msession) * Store sessions on all db servers and do replication (harder because it requires your updates not to lag) -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From jperkins at sneer.org Mon Nov 8 15:24:25 2004 From: jperkins at sneer.org (Jason Perkins) Date: Mon, 8 Nov 2004 14:24:25 -0600 Subject: [nycphp-talk] sessions and load balancing In-Reply-To: References: Message-ID: <2F34DB7A-31C4-11D9-8EDA-000D932DF2B4@sneer.org> On Nov 8, 2004, at 2:07 PM, Matthew Terenzio wrote: > At the point where traffic becomes so great that load balancing is in > order, what happens to sessions? > > Put another way: > > For applications using sessions, what are some strategies for being > able to scale to a multiple box level? A load balancer that supports sticky originating IP addresses (so that visitors will be routed to the same server based on their originating IP address) is the most common hardware based solution that I've seen. -- Jason N Perkins From webmaster at localnotion.com Mon Nov 8 15:40:49 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Mon, 8 Nov 2004 15:40:49 -0500 Subject: [nycphp-talk] sessions and load balancing In-Reply-To: References: Message-ID: <7992E3B6-31C6-11D9-A001-0003938BDF32@localnotion.com> On Nov 8, 2004, at 3:15 PM, Adam Maccabee Trachtenberg wrote: > On Mon, 8 Nov 2004, Matthew Terenzio wrote: > >> For applications using sessions, what are some strategies for being >> able to scale to a multiple box level? > > * Store session on client (cookies) Will forcing sessions to use cookies solve the problem completely. Can you think of any issues that might arise? Forgive me for asking before I look, but it seems like a DB backed session solution would be a great PEAR project. > * Store session on separate database server shared among all web > servers (probably the way to go at first). > * Use specialized session server (like msession) > * Store sessions on all db servers and do replication (harder because > it requires your updates not to lag) > > -adam > > -- > adam at trachtenberg.com > author of o'reilly's "upgrading to php 5" and "php cookbook" > avoid the holiday rush, buy your copies today! > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From dcech at phpwerx.net Mon Nov 8 15:46:23 2004 From: dcech at phpwerx.net (Dan Cech) Date: Mon, 08 Nov 2004 15:46:23 -0500 Subject: [nycphp-talk] sessions and load balancing In-Reply-To: <7992E3B6-31C6-11D9-A001-0003938BDF32@localnotion.com> References: <7992E3B6-31C6-11D9-A001-0003938BDF32@localnotion.com> Message-ID: <418FDB1F.9030508@phpwerx.net> Matthew Terenzio wrote: > On Nov 8, 2004, at 3:15 PM, Adam Maccabee Trachtenberg wrote: >> On Mon, 8 Nov 2004, Matthew Terenzio wrote: >> >>> For applications using sessions, what are some strategies for being >>> able to scale to a multiple box level? >> >> * Store session on client (cookies) > > Will forcing sessions to use cookies solve the problem completely. Can > you think of any issues that might arise? > Forgive me for asking before I look, but it seems like a DB backed > session solution would be a great PEAR project. I think what Adam was referring to was storing the actual session content in a cookie, rather than just the session_id. This can work provided your session data is small, and you don't ever trust it any more than any other data provided by the user. As for Database backed sessions, they can and do work very well. I'd suggest you take a look at ADOdb's solution here: http://adodb.sourceforge.net/ It has a well implemented system which support various 'plugins' or 'filters' such as encryption and/or compression of the session data. Dan From george at omniti.com Mon Nov 8 15:46:51 2004 From: george at omniti.com (George Schlossnagle) Date: Mon, 8 Nov 2004 15:46:51 -0500 Subject: [nycphp-talk] sessions and load balancing In-Reply-To: <418FDB1F.9030508@phpwerx.net> References: <7992E3B6-31C6-11D9-A001-0003938BDF32@localnotion.com> <418FDB1F.9030508@phpwerx.net> Message-ID: <5176D448-31C7-11D9-BED7-000D93359332@omniti.com> On Nov 8, 2004, at 3:46 PM, Dan Cech wrote: > Matthew Terenzio wrote: >> On Nov 8, 2004, at 3:15 PM, Adam Maccabee Trachtenberg wrote: >>> On Mon, 8 Nov 2004, Matthew Terenzio wrote: >>> >>>> For applications using sessions, what are some strategies for being >>>> able to scale to a multiple box level? >>> >>> * Store session on client (cookies) >> Will forcing sessions to use cookies solve the problem completely. >> Can you think of any issues that might arise? >> Forgive me for asking before I look, but it seems like a DB backed >> session solution would be a great PEAR project. > > I think what Adam was referring to was storing the actual session > content in a cookie, rather than just the session_id. > > This can work provided your session data is small, and you don't ever > trust it any more than any other data provided by the user. You can encrypt or sign it as well, reducing a users ability to inspect or (successfully) tamper with the cookies contents. George From hans at nyphp.com Mon Nov 8 16:49:52 2004 From: hans at nyphp.com (Hans Zaunere) Date: Mon, 8 Nov 2004 13:49:52 -0800 Subject: [nycphp-talk] webservices anyone (MySQL replication) Message-ID: <41EE526EC2D3C74286415780D3BA9F870591DFDF@ehost011-1.exch011.intermedia.net> > > >>Is there a better way to do > > >>some DB syncing? > > > > http://dev.mysql.com/doc/mysql/en/Replication.html > > > > > >(needs at least version 4.1 ) > > > > It does work with earlier versions. I've done replication with 3.23.x > > > But maybe it's considerably more reliable in 4.1 ? Because I played with > it in 4.0.x on 2 Windows boxes for quite a while and the slave kept > falling out of sync and giving up. I myself got annoyed and gave up (for > now). MySQL replication has been solid since 3.23.x, and improved greatly in 4.0 (binary log). Not many changes in 4.1. Replication in 4.0 is solid, and drives many large sites, data sets, etc. I was onsite not too long ago that was replicating 2000 INSERTS/s across three slaves. --- Hans Zaunere, Sales Engineer MySQL, Inc. www.mysql.com Office: +1 212.213.1131 Are you MySQL certified? www.mysql.com/certification --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From adam at trachtenberg.com Mon Nov 8 17:22:52 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Mon, 8 Nov 2004 17:22:52 -0500 (EST) Subject: [nycphp-talk] sessions and load balancing In-Reply-To: <5176D448-31C7-11D9-BED7-000D93359332@omniti.com> References: <7992E3B6-31C6-11D9-A001-0003938BDF32@localnotion.com> <418FDB1F.9030508@phpwerx.net> <5176D448-31C7-11D9-BED7-000D93359332@omniti.com> Message-ID: On Mon, 8 Nov 2004, George Schlossnagle wrote: > You can encrypt or sign it as well, reducing a users ability to inspect > or (successfully) tamper with the cookies contents. Yes. This is the route to go if you're using cookies. Recipe 9.3 of PHP Cookbook has code to do with for forms using md5(), but it's easy to modify this for cookies. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From george at omniti.com Mon Nov 8 17:24:30 2004 From: george at omniti.com (George Schlossnagle) Date: Mon, 8 Nov 2004 17:24:30 -0500 Subject: [nycphp-talk] sessions and load balancing In-Reply-To: References: <7992E3B6-31C6-11D9-A001-0003938BDF32@localnotion.com> <418FDB1F.9030508@phpwerx.net> <5176D448-31C7-11D9-BED7-000D93359332@omniti.com> Message-ID: On Nov 8, 2004, at 5:22 PM, Adam Maccabee Trachtenberg wrote: > On Mon, 8 Nov 2004, George Schlossnagle wrote: > >> You can encrypt or sign it as well, reducing a users ability to >> inspect >> or (successfully) tamper with the cookies contents. > > Yes. This is the route to go if you're using cookies. Recipe 9.3 of > PHP Cookbook has code to do with for forms using md5(), but it's easy > to modify this for cookies. That works fine for tamper-resistance. If you want to eliminate inspection, you should use a cypher like 3des, sha or blowfish. George From emm at scriptdigital.com Mon Nov 8 18:30:04 2004 From: emm at scriptdigital.com (Emmanuel =?iso-8859-1?Q?D=E9carie?=) Date: Mon, 08 Nov 2004 18:30:04 -0500 Subject: [nycphp-talk] Getting HTTP status code In-Reply-To: <20041024160004.22C04A86C1@virtu.nyphp.org> Message-ID: Hello, Is it possible under IIS 5 with PHP 4.2.2 running as a CGI to get the HTTP status code? I'm writing a small function that will create a log of the requests in the Combined Log Format and to my despair, when I look at the $_SERVER array, I don't see where is logged the http status code. I though that I could just look at the raw request string, but I can't find a way to get it. I've been all over the web to find a solution. I don't see nothing about this in these books; PHP Cookbook, Essential PHP Tools, Advanced PHP Programming, PHP Developer's Cookbook. TIA Cheers -Emmanuel -- Emmanuel D?carie / Programmation pour le Web - Programming for the Web - Blog: - AIM: scriptdigital From mogmios at mlug.missouri.edu Mon Nov 8 21:36:07 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Mon, 08 Nov 2004 18:36:07 -0800 Subject: [nycphp-talk] sessions and load balancing In-Reply-To: References: Message-ID: <41902D17.6090602@mlug.missouri.edu> > At the point where traffic becomes so great that load balancing is in > order, what happens to sessions? > > Put another way: > > For applications using sessions, what are some strategies for being > able to scale to a multiple box level? I save my session data to my db and thus can load balance my webservers with no issues when it comes to sessions. It appears MySQL now lets you properly cluster database servers too so you can spread that load across multiple machines too. Can't wait to try it. :) -- Michael http://kavlon.org From prusak at gmail.com Mon Nov 8 22:06:23 2004 From: prusak at gmail.com (Ophir Prusak) Date: Mon, 8 Nov 2004 22:06:23 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) Message-ID: Hi All, I'm currently writing an article on learning PHP and would like to know how others learned PHP and computer programming in general. I'm specifically looking for people who do NOT have a formal university computer science education. Please reply directly. Ideally I'd like to ask you a few questions over the phone (this will take less time then you writing up a long reply). Thanks Ophir http://www.prusak.com From jonbaer at jonbaer.net Mon Nov 8 22:20:17 2004 From: jonbaer at jonbaer.net (Jon Baer) Date: Mon, 8 Nov 2004 22:20:17 -0500 Subject: [nycphp-talk] Xpath Calculations (Math) Message-ID: <002a01c4c60b$09870500$6800a8c0@SPIKETV1515> Hi, Ive moved some code from MySQL to static XML/Xpath and was trying to figure out if there is an easy way to perform (and sort) sum calculations .. For example: Id like to end up with: J. Baer 2 J. Doe 1 Without having to do a map in PHP. Is there an Xpath hack/function to do this? Thanks. - Jon From krook at us.ibm.com Tue Nov 9 02:04:19 2004 From: krook at us.ibm.com (Daniel Krook) Date: Tue, 9 Nov 2004 02:04:19 -0500 Subject: [nycphp-talk] Xpath Calculations (Math) In-Reply-To: <002a01c4c60b$09870500$6800a8c0@SPIKETV1515> Message-ID: > Ive moved some code from MySQL to static XML/Xpath and was trying to figure > out if there is an easy way to perform (and sort) sum calculations ... > Is there an Xpath hack/function to do this? Have a look at the XSLT Cookbook. I think there may be a function in there for this: TOC: http://www.oreilly.com/catalog/xsltckbk/toc.html Code samples: http://examples.oreilly.com/xsltckbk/ Daniel Krook, Application Developer WW Web Production Services North 2, ibm.com 1133 Westchester Avenue, White Plains, NY 10604 Personal: http://info.krook.org/ Persona: http://w3.ibm.com/eworkplace/persona_bp_finder.jsp?CNUM=9A9796897 From codebowl at gmail.com Tue Nov 9 07:53:37 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 9 Nov 2004 07:53:37 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: References: Message-ID: <8d9a4280041109045338856254@mail.gmail.com> Ophir, I am your man, i have no formal education with programming and have learned PHP some C without the knowledge of GTK or QT yet. I first started learning PHP about 5 years ago, i bought a few books on PHP 4 and mysql, once i read through those and did the examples (always typed them and didnt use the source on cd or any shortcuts like that) I used #php channels on IRC quite a bit for help and find that they are a good resource for help, they will not spoonfeed you, you are still going to have to google, but they will give direction, advice on better coding styles, and sometimes the flat out answer. Generally you will find me on irc.freenode.net in #php and #php-gtk as i started to learn GTK but have now stopped due to time constraints. Mostly though i have learned PHP and everything else i know about the computer through day to day use, and books. As i look at my bookshelf at this point i see 8 books related to PHP and MYSQL the best i have read would have to be Core PHP Programming 3rd Edition ISBN: 0130463469 As i said above i know a little C programming which i have thanks to Deitel & Deitel for, thier books are very expensive but are well worth the investment as they are easy to follow, clear and to the point. The book i used is C How to Program 3rd Edition ISBN: 0130895725 I want to learn more C programming and will be spending more time on it in the near future as i have always thought it is good to know more than one language if one dissapears you have the other to rely on. I would love to get a degree at some point however i do not see this happening, i have a family now and attempted the online college route, this fell through because in my second class the instructor was unreachable after the 2nd week. I had financial aid and loans but failed a course due to an instructor not being reachable nor was the classroom (newsgroup). The school stated that i had to pay for the failed course and i refuse to do so since it was the instructors fault. However that is my background, if you have any paths you suggest i travel such as new languages to learn i would appreciate any advice you have. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From psaw at pswebcode.com Tue Nov 9 08:17:57 2004 From: psaw at pswebcode.com (Peter Sawczynec) Date: Tue, 9 Nov 2004 08:17:57 -0500 Subject: [nycphp-talk] PHP CMS Product Recommendation... Message-ID: <000701c4c65e$87ebf5b0$68e4a144@yourx1adg12jme> If you've had experience (or simple heard about a colleague) using a freeware PHP/MySQL-based Content Management System (CMS), I'd like to hear your feedback/recommendations. My client will need admin tools to create things like: 1) exhibition-type galleries of images with descriptions, 2) events calendar, 3) press releases, and 4) brief articles with title, subtitle and associated image(s). Additionally, any thoughts on comparing a CMS tool that mostly has an "admin pages with input boxes saves to database" flow vs. a tool that provides graphical HTML editors that allow the client to design/maintain their site. A product name is all I really need. Thanks in advance. Warmest regards, Peter Sawczynec, Technology Director PSWebcode 718.543.3240 psaw at pswebcode.com -------------- next part -------------- An HTML attachment was scrubbed... URL: From scott at crisscott.com Tue Nov 9 08:36:29 2004 From: scott at crisscott.com (Scott Mattocks) Date: Tue, 09 Nov 2004 08:36:29 -0500 Subject: [nycphp-talk] Getting HTTP status code In-Reply-To: References: Message-ID: <4190C7DD.5070808@crisscott.com> Emmanuel D?carie wrote: > Is it possible under IIS 5 with PHP 4.2.2 running as a CGI to get the > HTTP status code? Yes. http://pear.php.net/manual/en/package.http.http-request.response-eval.php If you don't want to use the PEAR class, maybe their source code can help you. Scott Mattocks From dcech at phpwerx.net Tue Nov 9 08:48:13 2004 From: dcech at phpwerx.net (Dan Cech) Date: Tue, 09 Nov 2004 08:48:13 -0500 Subject: [nycphp-talk] Getting HTTP status code In-Reply-To: <4190C7DD.5070808@crisscott.com> References: <4190C7DD.5070808@crisscott.com> Message-ID: <4190CA9D.6060309@phpwerx.net> Scott Mattocks wrote: > Emmanuel D?carie wrote: > >> Is it possible under IIS 5 with PHP 4.2.2 running as a CGI to get the >> HTTP status code? > > Yes. > http://pear.php.net/manual/en/package.http.http-request.response-eval.php > > If you don't want to use the PEAR class, maybe their source code can > help you. I think what Emmanuel was referring to was the response code of the server, as he mentions logs. The problem is that php will only be invoked on a successful request, so the status would always be 200. The only other codes you could potentially trap and log would be to use custom 404 handlers, etc. Dan From mitch.pirtle at gmail.com Tue Nov 9 09:01:57 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Tue, 9 Nov 2004 09:01:57 -0500 Subject: [nycphp-talk] PHP CMS Product Recommendation... In-Reply-To: <000701c4c65e$87ebf5b0$68e4a144@yourx1adg12jme> References: <000701c4c65e$87ebf5b0$68e4a144@yourx1adg12jme> Message-ID: <330532b604110906012d4eec79@mail.gmail.com> Disclaimer: I am a core developer of Mambo, so my enthusiasm may be just a tad over the top ;-) I've been designing, implementing and migrating CMS since 1995, and now work on the Mambo project (www.mamboserver.com). I'm constantly evaluating both commercial and FOSS systems, and can help there if you have a short list for review. One way to try before you download is to go to Open Source CMS (www.opensourcecms.com) where you can demo one of many different ones - note that the site is powered by Mambo ;-) I like Mambo because it is simple, lightweight, and has a huge 3rd party community providing image galleries, shopping carts, events calendars, thumbnail generators, flash animated analog clocks, and anything else you would want. The biggest source for add-ons is MamboForge (mamboforge.net), where you can search or browse through what is available. -- Mitch, wondering what the plural form for CMS is On Tue, 9 Nov 2004 08:17:57 -0500, Peter Sawczynec wrote: > > > If you've had experience (or simple heard about a colleague) using a > freeware PHP/MySQL-based Content Management System (CMS), I'd like to hear > your feedback/recommendations. > > My client will need admin tools to create things like: 1) exhibition-type > galleries of images with descriptions, 2) events calendar, 3) press > releases, and 4) brief articles with title, subtitle and associated > image(s). > > Additionally, any thoughts on comparing a CMS tool that mostly has an "admin > pages with input boxes saves to database" flow vs. a tool that provides > graphical HTML editors that allow the client to design/maintain their site. > > A product name is all I really need. Thanks in advance. > > > > Warmest regards, > > Peter Sawczynec, > Technology Director > PSWebcode > 718.543.3240 > psaw at pswebcode.com > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > From chsnyder at gmail.com Tue Nov 9 09:27:03 2004 From: chsnyder at gmail.com (csnyder) Date: Tue, 9 Nov 2004 09:27:03 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <8d9a4280041109045338856254@mail.gmail.com> References: <8d9a4280041109045338856254@mail.gmail.com> Message-ID: I read the manual at php.net. The PHP manual is a concise and (mostly) elegant introduction to the language, annotated by programmers around the world. The authors deserve infinite credit in my opinion. From ajai at bitblit.net Tue Nov 9 09:40:37 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Tue, 09 Nov 2004 09:40:37 -0500 Subject: [nycphp-talk] PHP CMS Product Recommendation... In-Reply-To: <330532b604110906012d4eec79@mail.gmail.com> References: <000701c4c65e$87ebf5b0$68e4a144@yourx1adg12jme> <330532b604110906012d4eec79@mail.gmail.com> Message-ID: <4190D6E5.4040207@bitblit.net> Mitch Pirtle wrote: >I like Mambo because it is simple, lightweight, and has a huge 3rd >party community providing image galleries, shopping carts, events >calendars, thumbnail generators, flash animated analog clocks, and >anything else you would want. The biggest source for add-ons is >MamboForge (mamboforge.net), where you can search or browse through >what is available. > I second Mambo as a good choice. -- Aj. Systems Administrator / Developer From codebowl at gmail.com Tue Nov 9 09:57:12 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 9 Nov 2004 09:57:12 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: References: <8d9a4280041109045338856254@mail.gmail.com> Message-ID: <8d9a42800411090657705e2696@mail.gmail.com> yes i should also mention that the manual was a great deal of help in my learning PHP -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From emm at scriptdigital.com Tue Nov 9 10:33:56 2004 From: emm at scriptdigital.com (Emmanuel =?iso-8859-1?Q?D=E9carie?=) Date: Tue, 09 Nov 2004 10:33:56 -0500 Subject: [nycphp-talk] Getting HTTP status code In-Reply-To: <20041109140209.91B78A86E1@virtu.nyphp.org> Message-ID: >Date: Tue, 09 Nov 2004 08:48:13 -0500 >From: Dan Cech >I think what Emmanuel was referring to was the response code of the >server, as he mentions logs. The problem is that php will only be >invoked on a successful request, so > the status would always be 200. >The only other codes you could potentially trap and log would be to >use custom 404 handlers, etc. Yes, exactly. Thanks. Oh well, I wish I knew that yesterday :). Gee, I guess this is PHP 101. Before I look in my books or on the Web, anyone has a pointer to what in the Apache world is called by mod_perl developers (and probably others I guess) the "request loop". I'm definitely interested to read more about this to clear my head on the question, although, maybe it makes no sense in the context of PHP. I'm especially interested in how PHP handle the request from Apache/IIS (CGI/Fast CGI). I'd like though, to know a way in PHP 4x to get what the server is giving to PHP before PHP massage it in it's PHP Superglobal. Cheers -Emmanuel -- Emmanuel D?carie / Programmation pour le Web - Programming for the Web - Blog: - AIM: scriptdigital From psaw at pswebcode.com Tue Nov 9 10:44:16 2004 From: psaw at pswebcode.com (Peter Sawczynec) Date: Tue, 9 Nov 2004 10:44:16 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: Message-ID: <001501c4c672$fb54da30$68e4a144@yourx1adg12jme> Step One: Don't' spend money on beginner's books. Start by reading the basic books right there in the store like at a Barnes & Noble. A.) Learn about PHP and the Apache web environment first: "PHP: Your Visual Blueprint for Creating Open Source, Server-Side Content" by Paul Whitehead. This book is real good for absolute beginners with lots and lots of screen captures. B.) Then get a handle on SQL, the language: "Sams Teach Yourself SQL in 10 Minutes, Third Edition" by Ben Fort. Step by step for learning SQL. C.) Then get a grasp on MySQL by seeing it in basic action: "PHP and MySQL for Dummies" by Janet Valade. At first, learn about MySQL tangentially. Step Two: Look at and absorb as much of the intermediate books in the store also. Buy only one. The one that talks to you most. Step Three: Sample all the expert books in the too. Expert books are the only one's you will need at home/office. Buy two. Secretly, I've used the "...for Dummies" series. Always a reliable, great intro to any programming topic(s). Just don't buy. Read 'em in the store. Finally, go mano a mano with Wrox books. When you really have to know a concept, you are going to have to turn to advanced/expert Wrox. Period. Generally, I've found that I can pretty thoroughly grasp any difficult new programming concept by studying it via three different books/manuals. Concurrently, read tutorials on the web a lot. There are a lot of sources, but I found that www.phpdeveloper.org covers a lot. Warmest regards, Peter Sawczynec, Technology Director PSWebcode 718.543.3240 psaw at pswebcode.com -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On Behalf Of Ophir Prusak Sent: Monday, November 08, 2004 10:06 PM To: talk at lists.nyphp.org Subject: [nycphp-talk] How did you learn PHP (and programming) Hi All, I'm currently writing an article on learning PHP and would like to know how others learned PHP and computer programming in general. I'm specifically looking for people who do NOT have a formal university computer science education. Please reply directly. Ideally I'd like to ask you a few questions over the phone (this will take less time then you writing up a long reply). Thanks Ophir http://www.prusak.com _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org From bpang at bpang.com Tue Nov 9 11:16:33 2004 From: bpang at bpang.com (bpang at bpang.com) Date: Tue, 9 Nov 2004 11:16:33 -0500 (EST) Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: References: <8d9a4280041109045338856254@mail.gmail.com> Message-ID: <37084.127.0.0.1.1100016993.squirrel@127.0.0.1> > I read the manual at php.net. > > The PHP manual is a concise and (mostly) elegant introduction to the > language, annotated by programmers around the world. The authors > deserve infinite credit in my opinion. I don't use anything but the php.net manual.. and maybe a lil trick or two from this list. (sorry authors on the list) :( From jlacey at att.net Tue Nov 9 11:26:46 2004 From: jlacey at att.net (John Lacey) Date: Tue, 09 Nov 2004 09:26:46 -0700 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: References: Message-ID: <4190EFC6.8050804@att.net> Ophir Prusak wrote: > Hi All, > > I'm currently writing an article on learning PHP and would like to > know how others learned PHP and computer programming in general. > > I'm specifically looking for people who do NOT have a formal > university computer science education. > > Please reply directly. Ideally I'd like to ask you a few questions > over the phone (this will take less time then you writing up a long > reply). > Ophir, if you'd like, you can contact me off-list at jlacey removethisjunkat att period net John From codebowl at gmail.com Tue Nov 9 11:50:21 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 9 Nov 2004 11:50:21 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <4190EFC6.8050804@att.net> References: <4190EFC6.8050804@att.net> Message-ID: <8d9a4280041109085072dd6f8c@mail.gmail.com> Peter, I am sorry i have to disagree with you... if you are going to sit in the bookstore and read the books, you should buy them if they contain information that will help you learn, i have a rather good size php book collection because i support the authors by buying the books, if you just go to the bookstore and read and learn that author isnt getting anything if you dont buy the book, yes if you dont have the cash to buy the book right then by all means read it there, but try to buy it. Afterall the knowledge you learn from a good book is well worth the $50-100 you spend on the book. sorry i dont mean to be rude or flame i just thought i would state the obvious and my stance in this situation. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From codebowl at gmail.com Tue Nov 9 11:51:20 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 9 Nov 2004 11:51:20 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <8d9a4280041109085072dd6f8c@mail.gmail.com> References: <4190EFC6.8050804@att.net> <8d9a4280041109085072dd6f8c@mail.gmail.com> Message-ID: <8d9a4280041109085140d8df4b@mail.gmail.com> Oh incase people are not aware of it, check out Safari Bookshelf http://safari.oreilly.com you can create a bookshelf and have access to the online books for a monthly fee, usually cheaper than buying the books, only drawback is you have to read them online. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From mogmios at mlug.missouri.edu Tue Nov 9 11:49:28 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Tue, 09 Nov 2004 08:49:28 -0800 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: References: <8d9a4280041109045338856254@mail.gmail.com> Message-ID: <4190F518.6080006@mlug.missouri.edu> >The PHP manual is a concise and (mostly) elegant introduction to the >language, annotated by programmers around the world. The authors >deserve infinite credit in my opinion. > I fully agree. I know a lot of programming languages and read a lot of technical manuals and the PHP manual is one of my favorite. It is much easier to work with than most. -- Michael http://kavlon.org From psaw at pswebcode.com Tue Nov 9 12:00:21 2004 From: psaw at pswebcode.com (Peter Sawczynec) Date: Tue, 9 Nov 2004 12:00:21 -0500 Subject: [nycphp-talk] PHP CMS Product Recommendation... In-Reply-To: <4190D6E5.4040207@bitblit.net> Message-ID: <002401c4c67d$9c4c1520$68e4a144@yourx1adg12jme> I installed Mambo locally. Tooling around admin now. Looking quite nice. Further, I'll be looking at Typo3 and Digital Workroom. Thanks. -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On Behalf Of Ajai Khattri Sent: Tuesday, November 09, 2004 9:41 AM To: NYPHP Talk Subject: Re: [nycphp-talk] PHP CMS Product Recommendation... Mitch Pirtle wrote: >I like Mambo because it is simple, lightweight, and has a huge 3rd >party community providing image galleries, shopping carts, events >calendars, thumbnail generators, flash animated analog clocks, and >anything else you would want. The biggest source for add-ons is >MamboForge (mamboforge.net), where you can search or browse through >what is available. > I second Mambo as a good choice. -- Aj. Systems Administrator / Developer _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org From nyphp at enobrev.com Tue Nov 9 12:05:52 2004 From: nyphp at enobrev.com (Mark Armendariz) Date: Tue, 9 Nov 2004 12:05:52 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <8d9a4280041109085072dd6f8c@mail.gmail.com> Message-ID: <20041109170550.86089A85EA@virtu.nyphp.org> > Afterall the knowledge you learn from a good book is well worth the > $50-100 you spend on the book. And there's always the fact that quite a few of the names on this very list have their own amazon url's. And I'm not talking wish lists. Mark From emm at scriptdigital.com Tue Nov 9 12:06:43 2004 From: emm at scriptdigital.com (Emmanuel =?iso-8859-1?Q?D=E9carie?=) Date: Tue, 09 Nov 2004 12:06:43 -0500 Subject: [nycphp-talk] error_log () internal lock mechanism? Message-ID: Hello, Just to be sure, does error_log ($text, 3, $logpath); use an internal exclusive lock mechanism internally when writing to a log file? I'm wary of corrupting my log files. TIA Cheers -Emmanuel -- Emmanuel D?carie / Programmation pour le Web - Programming for the Web - Blog: - AIM: scriptdigital From codebowl at gmail.com Tue Nov 9 12:08:13 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 9 Nov 2004 12:08:13 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <20041109170550.86089A85EA@virtu.nyphp.org> References: <8d9a4280041109085072dd6f8c@mail.gmail.com> <20041109170550.86089A85EA@virtu.nyphp.org> Message-ID: <8d9a42800411090908779b0a6f@mail.gmail.com> yes very true i am sure there are several people here who have written books :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From listings at impulsenetwork.de Tue Nov 9 12:47:30 2004 From: listings at impulsenetwork.de (Andreas Gaisbauer) Date: Tue, 09 Nov 2004 18:47:30 +0100 Subject: [nycphp-talk] PHP CMS Product Recommendation... In-Reply-To: <000701c4c65e$87ebf5b0$68e4a144@yourx1adg12jme> References: <000701c4c65e$87ebf5b0$68e4a144@yourx1adg12jme> Message-ID: <419102B2.7090506@impulsenetwork.de> > A product name is all I really need. Thanks in advance. Typo3 I worked on three larger projects with Typo3 this year. It's not as simple as Mambo, but if you "get into it", it offers nearly unlimited possibilities... ciao Andreas From mitch.pirtle at gmail.com Tue Nov 9 12:59:05 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Tue, 9 Nov 2004 12:59:05 -0500 Subject: [nycphp-talk] PHP CMS Product Recommendation... In-Reply-To: <002401c4c67d$9c4c1520$68e4a144@yourx1adg12jme> References: <4190D6E5.4040207@bitblit.net> <002401c4c67d$9c4c1520$68e4a144@yourx1adg12jme> Message-ID: <330532b60411090959558aedab@mail.gmail.com> Other 'biggies' are drupal, xaraya, and midgard. Not an endorsement, but an acknowledgement! LOL -- Mitch On Tue, 9 Nov 2004 12:00:21 -0500, Peter Sawczynec wrote: > I installed Mambo locally. Tooling around admin now. Looking quite nice. > Further, I'll be looking at Typo3 and Digital Workroom. > > Thanks. > > > > -----Original Message----- > From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On > Behalf Of Ajai Khattri > Sent: Tuesday, November 09, 2004 9:41 AM > To: NYPHP Talk > Subject: Re: [nycphp-talk] PHP CMS Product Recommendation... > > Mitch Pirtle wrote: > > >I like Mambo because it is simple, lightweight, and has a huge 3rd > >party community providing image galleries, shopping carts, events > >calendars, thumbnail generators, flash animated analog clocks, and > >anything else you would want. The biggest source for add-ons is > >MamboForge (mamboforge.net), where you can search or browse through > >what is available. > > > > I second Mambo as a good choice. > > -- > Aj. > Systems Administrator / Developer > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From psaw at pswebcode.com Tue Nov 9 13:18:30 2004 From: psaw at pswebcode.com (Peter Sawczynec) Date: Tue, 9 Nov 2004 13:18:30 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <8d9a42800411090908779b0a6f@mail.gmail.com> Message-ID: <002901c4c688$872f1c40$68e4a144@yourx1adg12jme> First, I heartily apologize for not mentioning O'Reilly. They are an excellent top-caliber reference book publisher (especially on the cusp with all XML and related) and they host a best of breed web site giving tons of sample chapters as PDFs that can be used to dig into almost any topic. For all those who have written the tech books that I have used to learn programming, I apologize that I did not buy all the books, but over the past 7 years or so since I started with regular HTML and JavaScript. Then CSS. Then plain SQL. Then did VBScript. Then VB 4, 5, 6. Then ASP 3. IIS 3, 4, 5. Then T-SQL and MS SQL Server 7, 2000, 2002. Then NT4. Then Windows Server 2000, 2003. WSH. Then moved on to PHP 3, 4, 5. MySQL 3, 4, 5. Apache 1.3.x, 2. Then XML, XSLT, XPATH, XQUERY. Then Unix, PERL. VPN, TCP/IP, RTSP, WRDL, RSS, HTTP, SMTP, FTP, SSL, WML, MPEG, JPEG, TIFF, EPS, PDF, RTF, CSV, PostScript, Real, WMV, Ethernet, IDS, proxies, load balancing, firewalls, encryption... Quark 3, 4, QuickTime 4, 5, 6, Flash 4 - MX, Dreamweaver 3 - MX, Photoshop 2 - 7, Illustrator 3 - 10, MS PowerPoint, Word, Excel, Outlook 95 - XP. Also, Freehand, Fireworks, Distiller, Visio, WordPerfect, Bryce... Geez, I know I'm forgetting some things... And I know that there are many on this list still deeper than me and they know even more code/apps. I've hardly batted and eye at C, Python, Tcl, JAVA. I did an informal summation of the dollars (thru my tax records) and I have nonetheless spent a bit on books -- easily three thousand dollars. -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On Behalf Of Joseph Crawford Sent: Tuesday, November 09, 2004 12:08 PM To: NYPHP Talk Subject: Re: [nycphp-talk] How did you learn PHP (and programming) yes very true i am sure there are several people here who have written books :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org From tom at ztml.com Tue Nov 9 13:43:26 2004 From: tom at ztml.com (Tom Wong) Date: 9 Nov 2004 18:43:26 -0000 Subject: [nycphp-talk] How did you learn PHP (and programming) Message-ID: <20041109184326.90511.qmail@host180.ipowerweb.com> An embedded and charset-unspecified text was scrubbed... Name: not available URL: From tgales at tgaconnect.com Tue Nov 9 15:22:17 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Tue, 9 Nov 2004 15:22:17 -0500 Subject: [nycphp-talk] PHP CMS Product Recommendation... Message-ID: <200411092022.iA9KMHL08701@tgaconnect.com> > Other 'biggies' are drupal, xaraya, and midgard. Not an endorsement, > but an acknowledgement! LOL > > -- Mitch I don't know if phpWebsite is a 'biggie', but you might want to take a look at it. ( http://phpwebsite.appstate.edu/ ) T. Gales & Associates 'Helping People Connect with Technology' http://www.tgaconnect.com From hans at nyphp.com Tue Nov 9 16:08:27 2004 From: hans at nyphp.com (Hans Zaunere) Date: Tue, 9 Nov 2004 13:08:27 -0800 Subject: [nycphp-talk] error_log () internal lock mechanism? Message-ID: <41EE526EC2D3C74286415780D3BA9F87059C6C5F@ehost011-1.exch011.intermedia.net> > Just to be sure, does error_log ($text, 3, $logpath); > use an internal exclusive lock mechanism internally when writing to a > log file? I'm wary of corrupting my log files. Yes, I believe it handles it: http://cvs.php.net/co.php/php-src/main/main.c?r=1.614#373 H From danielc at analysisandsolutions.com Tue Nov 9 20:07:32 2004 From: danielc at analysisandsolutions.com (Daniel Convissor) Date: Tue, 9 Nov 2004 20:07:32 -0500 Subject: [nycphp-talk] november meeting Message-ID: <20041110010732.GA8114@panix.com> Hey Y'all: We're having a November meeting, right? There's nothing on the website about it. I'm too tired right now to remember or look at the mailing list archive and Greg Beaver is asking. I figured we are, but hey, may as well make sure. --Dan -- T H E A N A L Y S I S A N D S O L U T I O N S C O M P A N Y data intensive web and database programming http://www.AnalysisAndSolutions.com/ 4015 7th Ave #4, Brooklyn NY 11232 v: 718-854-0335 f: 718-854-0409 From mogmios at mlug.missouri.edu Tue Nov 9 20:06:15 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Tue, 09 Nov 2004 17:06:15 -0800 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: <20041109184326.90511.qmail@host180.ipowerweb.com> References: <20041109184326.90511.qmail@host180.ipowerweb.com> Message-ID: <41916987.70505@mlug.missouri.edu> >However, I think PHP is different from other >languages in some way that it will allow people >like me to use without taking any computer science >classes and still manage to write some useful >programs. For example, you can take a web page, >which can be easily obtained, change the format >to that of PHP and insert something like 'echo >date()' to display a date for example. So PHP is >great for all those wannabe programmers. > > The ease of seeing visible results that do something useful for even the most inexperienced programmers makes me think of PHP as the new LOGO. -- Michael http://kavlon.org From shiflett at php.net Tue Nov 9 21:53:49 2004 From: shiflett at php.net (Chris Shiflett) Date: Tue, 9 Nov 2004 18:53:49 -0800 (PST) Subject: [nycphp-talk] Getting HTTP status code In-Reply-To: Message-ID: <20041110025349.40680.qmail@web52801.mail.yahoo.com> --- Emmanuel D?carie wrote: > Before I look in my books or on the Web, anyone has a pointer to > what in the Apache world is called by mod_perl developers (and > probably others I guess) the "request loop". I'm definitely > interested to read more about this to clear my head on the > question, although, maybe it makes no sense in the context of PHP. > I'm especially interested in how PHP handle the request from > Apache/IIS (CGI/Fast CGI). Well, it only makes sense in an Apache context, of course. Geoff Young (one of the core mod_perl developers and last month's speaker) gives a talk every once in a while named something like Programming the Apache Lifecycle. You can probably find some slides online somewhere. There's also this 6 page PDF from his book: http://www.modperlcookbook.org/chapters/part3.pdf If you're interested in playing around with more than just the content generation bit, George Schlossnagle wrote a SAPI called apache_hooks. It exposes much more of the Apache API, although I've never actually played with it (I keep meaning to). He'll probably speak up and mention that it's most likely broken, since I don't think he's touched it in a while, but it's worth a try. :-) Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming February 2005 http://httphandbook.org/ From hans at nyphp.com Tue Nov 9 23:03:43 2004 From: hans at nyphp.com (Hans Zaunere) Date: Tue, 9 Nov 2004 20:03:43 -0800 Subject: [nycphp-talk] november meeting Message-ID: <41EE526EC2D3C74286415780D3BA9F87059C70AB@ehost011-1.exch011.intermedia.net> > We're having a November meeting, right? There's nothing on the > website about it. I'm too tired right now to remember or look at the > mailing list archive and Greg Beaver is asking. I figured we are, but > hey, may as well make sure. Hey folks, We certainly are having a Nov. meeting, and it'll be a very interesting one. We're having a Systems Engineer from AMD come talk about the AMP Technology platform on AMD and 64 bit. I'm sorry it's not on the calendar yet, but I'll be sure to have it by tomorrow. As a primer for the presentation, we've been working with AMD to get this under discussion. Thanks to NYPHP's Michael DeWitt and reps from AMD, we have a complimentary dual AMD64 box for testing. In fact, I've been on the PHP-Internal list discussing getting PHP up to par on lib64 systems. See http://www.zend.com/zend/week/week209.php for the work I and others have done on taking AMP to the 64 bit platform. I've documented all the gotchas, intricacies, and basic steps of working on a lib64 platform, including Apache, MySQL, SuSE, and Red Hat. As part of NYPHP's AMPeers project, I'll be publishing a detailed article on how to deploy on this next generation platform. If anyone wants the raw documentation and tutorial, feel free to contact me now. I know it's right before T-Day, but you won't want to miss it. David from AMD is a highly skilled tech that you can hit with the tough questions, so we're looking forward to a great pre T-Day meeting. Sorry for the delay folks. We'll get the announcement up tomorrow but put this meeting on your calendar. --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From george at omniti.com Tue Nov 9 23:39:25 2004 From: george at omniti.com (George Schlossnagle) Date: Tue, 9 Nov 2004 23:39:25 -0500 Subject: [nycphp-talk] Getting HTTP status code In-Reply-To: <20041110025349.40680.qmail@web52801.mail.yahoo.com> References: <20041110025349.40680.qmail@web52801.mail.yahoo.com> Message-ID: <7FBBA3E5-32D2-11D9-B931-000D93359332@omniti.com> On Nov 9, 2004, at 9:53 PM, Chris Shiflett wrote: > --- Emmanuel D?carie wrote: >> Before I look in my books or on the Web, anyone has a pointer to >> what in the Apache world is called by mod_perl developers (and >> probably others I guess) the "request loop". I'm definitely >> interested to read more about this to clear my head on the >> question, although, maybe it makes no sense in the context of PHP. >> I'm especially interested in how PHP handle the request from >> Apache/IIS (CGI/Fast CGI). > > Well, it only makes sense in an Apache context, of course. > > Geoff Young (one of the core mod_perl developers and last month's > speaker) > gives a talk every once in a while named something like Programming the > Apache Lifecycle. You can probably find some slides online somewhere. > There's also this 6 page PDF from his book: > > http://www.modperlcookbook.org/chapters/part3.pdf > > If you're interested in playing around with more than just the content > generation bit, George Schlossnagle wrote a SAPI called apache_hooks. > It > exposes much more of the Apache API, although I've never actually > played > with it (I keep meaning to). He'll probably speak up and mention that > it's > most likely broken, since I don't think he's touched it in a while, but > it's worth a try. :-) It's most likely broken (though you never know); and I'm too busy to fix it. I'm happy to help anyone trying to get it working again find the right path. Without that you have really no access to the request lifecycle from PHP. George From emm at scriptdigital.com Wed Nov 10 07:04:41 2004 From: emm at scriptdigital.com (Emmanuel =?iso-8859-1?Q?D=E9carie?=) Date: Wed, 10 Nov 2004 07:04:41 -0500 Subject: [nycphp-talk] error_log () internal lock mechanism? In-Reply-To: <20041110025359.A9845A8775@virtu.nyphp.org> Message-ID: >Date: Tue, 9 Nov 2004 13:08:27 -0800 >From: "Hans Zaunere" >> Just to be sure, does error_log ($text, 3, $logpath); use an >> internal exclusive lock mechanism internally when writing to >>a >> log file? I'm wary of corrupting my log files. > >Yes, I believe it handles it: > >http://cvs.php.net/co.php/php-src/main/main.c?r=1.614#373 Thanks Hans. Actually, when I said "internally", it was more a figure of speech :). Cheers -Emmanuel -- Emmanuel D?carie / Programmation pour le Web - Programming for the Web - Blog: - AIM: scriptdigital From tom at ztml.com Wed Nov 10 07:21:00 2004 From: tom at ztml.com (Tom Wong) Date: 10 Nov 2004 12:21:00 -0000 Subject: [nycphp-talk] How did you learn PHP (and programming) Message-ID: <20041110122100.73000.qmail@host180.ipowerweb.com> An embedded and charset-unspecified text was scrubbed... Name: not available URL: From emm at scriptdigital.com Wed Nov 10 09:29:15 2004 From: emm at scriptdigital.com (Emmanuel =?iso-8859-1?Q?D=E9carie?=) Date: Wed, 10 Nov 2004 09:29:15 -0500 Subject: [nycphp-talk] Re: Getting HTTP status code In-Reply-To: <20041110025359.A9845A8775@virtu.nyphp.org> Message-ID: >Date: Tue, 9 Nov 2004 18:53:49 -0800 (PST) >From: Chris Shiflett >--- Emmanuel D?carie wrote: >> Before I look in my books or on the Web, anyone has a pointer to >> what in the Apache world is called by mod_perl developers (and >> probably others I guess) the "request loop". I'm definitely >> interested to read more about this to clear my head on the >> question, although, maybe it makes no sense in the context of PHP. >> I'm especially interested in how PHP handle the request from >> Apache/IIS (CGI/Fast CGI). >Well, it only makes sense in an Apache context, of course. Ah sorry, I was not crystal clear about this. I used mod_perl as a comparison. What I'd like to find is some pointers that explain how PHP handle the request from the server when running for example, as a module in Apache, and the same thing when PHP is running as a CGI with IIS for example. What is exposed in PHP that comes from the server, and how to get the "raw" request that is passed to PHP before its parsed in PHP Superglobals. >Geoff Young (one of the core mod_perl developers and last month's >speaker) gives a talk every once in a while named something like >Programming the Apache Lifecycle. You can probably find some slides >online somewhere. There's also this 6 page PDF from his book: > >http://www.modperlcookbook.org/chapters/part3.pdf Thanks, I have this book and the "Writing Apache Modules". But I never really read these books. Just after getting them, I was "force" to learn PHP for a job, and then, never look back. One of the best thing that happened in my programmer life. Although before I really learned PHP, I read a lot about it, and looked at the language, and found it awful, and had my head full of stereotypes about PHP (like the famous quote from Randal L. Swartz: 'PHP - it's "training wheels without the bike"' ). >If you're interested in playing around with more than just the content >generation bit, George Schlossnagle wrote a SAPI called apache_hooks. >It exposes much more of the Apache API, although I've never actually >played with it (I keep meaning to). He'll probably speak up and >mention that it's most likely broken, since I don't think he's touched >it in a while, but it's worth a try. :-) This look interesting. I see it mentioned in its last book (I just checked the index). apache_hooks when stable could be a great addition to the PHP toolbox. Cheers -Emmanuel -- Emmanuel D?carie / Programmation pour le Web - Programming for the Web - Blog: - AIM: scriptdigital From hans at nyphp.com Wed Nov 10 09:54:46 2004 From: hans at nyphp.com (Hans Zaunere) Date: Wed, 10 Nov 2004 06:54:46 -0800 Subject: [nycphp-talk] Getting HTTP status code Message-ID: <41EE526EC2D3C74286415780D3BA9F87059C7238@ehost011-1.exch011.intermedia.net> > > If you're interested in playing around with more than just the content > > generation bit, George Schlossnagle wrote a SAPI called apache_hooks. > > It > > exposes much more of the Apache API, although I've never actually > > played > > with it (I keep meaning to). He'll probably speak up and mention that > > it's > > most likely broken, since I don't think he's touched it in a while, but > > it's worth a try. :-) > > It's most likely broken (though you never know); and I'm too busy to > fix it. I'm happy to help anyone trying to get it working again find > the right path. Without that you have really no access to the request > lifecycle from PHP. Yes, it is - and yes, I'd very much like to see it working, since it'd be invaluable, especially in a application context. But if you do get bored over the holidays, George, feel free to pick it up :) H From keithjr at gmail.com Wed Nov 10 12:36:31 2004 From: keithjr at gmail.com (Keith Richardson) Date: Wed, 10 Nov 2004 12:36:31 -0500 Subject: [nycphp-talk] How did you learn PHP (and programming) In-Reply-To: References: Message-ID: <4e1a9bc041110093643742171@mail.gmail.com> I learned PASCAL in High School, with a bit of C++ (only the 1st year class) - my high school offered about 8 programming classes, and I took 6 of them. I picked up C by the basics of C++ that I learned in class, and applied it to changing MUD code, since most distributions of MUDS are available for download. I learned php by wanting a scripting language to do databases/etc for a website I was working on, with just having an entry form and a list.. so I installed php/mysql/apache in 1999, and it just skyrocketed from there, and now I have written some php applications for the places that I have worked for. Also I took a job and am now co-webmaster of http://www.war3.com/ - where I learned a lot more about php by wanting the website to run smoother and easier, and having a lot more automated tasks, and integration between other PHP applications. PHP was easy to pick up, especially with my C/C++ knowledge, and also my dabblings with Java. I did not like visual basic at all, and having the further availability of php servers around the internet than ASP, I decided not to even touch asp until years later. -Keith Richardson On Mon, 8 Nov 2004 22:06:23 -0500, Ophir Prusak wrote: > Hi All, > > I'm currently writing an article on learning PHP and would like to > know how others learned PHP and computer programming in general. > > I'm specifically looking for people who do NOT have a formal > university computer science education. > > Please reply directly. Ideally I'd like to ask you a few questions > over the phone (this will take less time then you writing up a long > reply). > > Thanks > Ophir > > http://www.prusak.com > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- Keith Richardson keith at keithjr.net From jayeshsh at ceruleansky.com Wed Nov 10 13:02:28 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Wed, 10 Nov 2004 13:02:28 -0500 (EST) Subject: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) Message-ID: <33221.69.86.84.8.1100109748.spork@webmail.ceruleansky.com> Hello all, I hope the New York City winter winds have not cooled your interest in all things PHP and MySQL yet. I remember reading in an older issue of PHP Architect about a free tool used to build a visual representation of a MySQL database. I am not sure what to call such a tool: a schema mapper, a schema diagram tool, or something else? In any case, after quite a bit of googling, I don't seem to be getting anywhere. (I am considering buying the new SmartDraw Suite 7, available from smartdraw.com, which is an all-purpose diagramming / drawing tool. I also got a special $100 off discount link for it, which makes it more of a tempting buy.) Still, I would prefer to find a more specialized tool that will let me clearly show the relationships between tables: foreign keys, indices, keys, columns and column types, etc. I am also willing to pay a reasonable sum of money ($0 - $300) for a commercial tool that does just this. Sorry if this topic has been brought up before: I tried using "site:lists.nyphp.org mysql" in Google to search the mailing list archives, but that does not seem to work. Thanks in advance and enjoy the tropical weather here in New York! - Jay From rahmin at insite-out.com Wed Nov 10 13:15:40 2004 From: rahmin at insite-out.com (Rahmin Pavlovic) Date: Wed, 10 Nov 2004 13:15:40 -0500 Subject: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) Message-ID: <200411101815.iAAIFeDF013214@webmail4.megamailservers.com> An embedded and charset-unspecified text was scrubbed... Name: not available URL: From jsiegel1 at optonline.net Wed Nov 10 13:17:14 2004 From: jsiegel1 at optonline.net (Jeff Siegel) Date: Wed, 10 Nov 2004 13:17:14 -0500 Subject: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) In-Reply-To: <33221.69.86.84.8.1100109748.spork@webmail.ceruleansky.com> References: <33221.69.86.84.8.1100109748.spork@webmail.ceruleansky.com> Message-ID: <41925B2A.3040800@optonline.net> I believe this may do the trick. http://www.fabforce.net/dbdesigner4/ Jeff S. Jayesh Sheth wrote: > Hello all, > > I hope the New York City winter winds have not cooled your interest in all > things PHP and MySQL yet. > > I remember reading in an older issue of PHP Architect about a free tool > used to build a visual representation of a MySQL database. I am not sure > what to call such a tool: a schema mapper, a schema diagram tool, or > something else? > > In any case, after quite a bit of googling, I don't seem to be getting > anywhere. (I am considering buying the new SmartDraw Suite 7, available > from smartdraw.com, which is an all-purpose diagramming / drawing tool. I > also got a special $100 off discount link for it, which makes it more of a > tempting buy.) > > Still, I would prefer to find a more specialized tool that will let me > clearly show the relationships between tables: foreign keys, indices, > keys, columns and column types, etc. > > I am also willing to pay a reasonable sum of money ($0 - $300) for a > commercial tool that does just this. > > Sorry if this topic has been brought up before: I tried using > "site:lists.nyphp.org mysql" in Google to search the mailing list > archives, but that does not seem to work. > > Thanks in advance and enjoy the tropical weather here in New York! > > - Jay > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From hans at cyberxdesigns.com Wed Nov 10 13:42:33 2004 From: hans at cyberxdesigns.com (Hans C. Kaspersetz) Date: Wed, 10 Nov 2004 13:42:33 -0500 Subject: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) In-Reply-To: <41925B2A.3040800@optonline.net> References: <33221.69.86.84.8.1100109748.spork@webmail.ceruleansky.com> <41925B2A.3040800@optonline.net> Message-ID: <41926119.7060309@cyberxdesigns.com> I use DB Designer from FabForce regularly and love it. I use it to create the schema diagrams and then for the generation of the SQL code to build the DB. Occasionally, I have to go into the SQL and hand edit it to get things exactly right. Not sure if that is the application or if that is my poor use of it. -- Hans C. Kaspersetz Cyber X Designs http://www.cyberxdesigns.com Jeff Siegel wrote: > I believe this may do the trick. > > http://www.fabforce.net/dbdesigner4/ > > Jeff S. From jayeshsh at ceruleansky.com Wed Nov 10 13:42:52 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Wed, 10 Nov 2004 13:42:52 -0500 (EST) Subject: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) Message-ID: <33370.69.86.84.8.1100112172.spork@webmail.ceruleansky.com> Hello Rahmin, fabforce.net was the one was I was looking. Thanks a lot for the link. I could not find it anywhere on Google (during my previous search). If it is a good product, I would be happy to tip the software creator. (I just tried mydbpal and had to suffer through a painful signup form (no underscorea allowed in the email address or username). Then after 10 minutes I still could not figure out how to use the product. Clicking on any button is useless! Maybe Mydbpal is intended for people smarter than I am, but I would gladly try something else that is easier to use. On to fabforce ...) Best regards, - Jay From Cbielanski at inta.org Wed Nov 10 13:48:41 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Wed, 10 Nov 2004 13:48:41 -0500 Subject: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA47@intamail1.com> Hans, it might be your poor use, it might be the app, the part I'm hearing is "I can tweak it without a lot of fuss." *Sold!! This is a great app! Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence > -----Original Message----- > From: Hans C. Kaspersetz [mailto:hans at cyberxdesigns.com] > Sent: Wednesday, November 10, 2004 1:43 PM > To: NYPHP Talk > Subject: Re: [nycphp-talk] MySQL modelling tool (as seen in PHPArch?) > > > I use DB Designer from FabForce regularly and love it. I use it to > create the schema diagrams and then for the generation of the > SQL code > to build the DB. Occasionally, I have to go into the SQL and > hand edit > it to get things exactly right. Not sure if that is the > application or > if that is my poor use of it. > > -- > Hans C. Kaspersetz > Cyber X Designs > > http://www.cyberxdesigns.com > > > > Jeff Siegel wrote: > > > I believe this may do the trick. > > > > http://www.fabforce.net/dbdesigner4/ > > > > Jeff S. > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From jperkins at sneer.org Wed Nov 10 19:54:59 2004 From: jperkins at sneer.org (Jason Perkins) Date: Wed, 10 Nov 2004 18:54:59 -0600 Subject: [nycphp-talk] lazy initialization woes Message-ID: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> I'm working on a project in PHP with the hopes of releasing it if I can get it off of the ground and I've ran into a problem that I'm hoping someone can lend a hand with. The basic notion is that a given object will potentially contain other objects, but these contained objects aren't known (or generated) until runtime. For example, we'll instantiate a sales_order object and then, using its has_a() method, add a customer object to it. To prevent cascades of objects being instantiated, I'd plan to use lazy initialization - the customer object won't be instantiated until the first time that it's accessed through the customer class. The problem that I'm having is that lazy initialization in PHP 5 is accomplished via the __get() method which is called when an attribute (or contained class in this) isn't available - it's passed the name of the property that wasn't found and that's not enough information for me to return the attribute of the contained object that was being accessed. Here's some quickly written code with extra code stripped that'll demonstrate what I mean: relationships[ $class ] = 'has_a'; } public function __get( $class ) { if(array_key_exists( $class, $this->relationships )) { if( $this->relationships[ $class ] == 'has_a') { $this->$class = new $class( $this->id ); return; } } } } So if $attribute exists in the relationships array, it's instantiated (and, yeah, I plan to move the contained objects into a declared array. one thing at a time :) ) $sales_order = new sales_order; $sales_order->has_a( customer ); print $sales_order->customer->name; The last line fails, because __get is passed only 'customer' and not 'customer->name' - I have no way of knowing what attribute of customer was being accessed, so I can't return the requested data. Running this code: $sales_order = new sales_order; $sales_order->has_a( customer ); print $sales_order->customer->name; print $sales_order->customer->name; the fourth line works, because the customer object was instantiated during line three (line three still fails to return a value). Does anyone have any suggestions on how to get this working? Apologies in advance for the verbosity of this email, I really did try to strip out as much as I could. thanks! -- Jason N Perkins From dcech at phpwerx.net Wed Nov 10 20:10:59 2004 From: dcech at phpwerx.net (Dan Cech) Date: Wed, 10 Nov 2004 20:10:59 -0500 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> Message-ID: <4192BC23.9090304@phpwerx.net> I'm not 100% on overloading in php5, but I think you need either: class sales_order { ... public function has_a( $class ) { $this->relationships[ $class ] = 'has_a'; } public function __get( $class, &$obj ) { if(array_key_exists( $class, $this->relationships )) { if( $this->relationships[ $class ] == 'has_a') { $this->$class =& $obj =& new $class( $this->id ); return true; } } return false; } } or class sales_order { ... public function has_a( $class ) { $this->relationships[ $class ] = 'has_a'; } public function __get( $class ) { if(array_key_exists( $class, $this->relationships )) { if( $this->relationships[ $class ] == 'has_a') { return $this->$class =& new $class( $this->id ); } } } } Dan Jason Perkins wrote: > I'm working on a project in PHP with the hopes of releasing it if I can > get it off of the ground and I've ran into a problem that I'm hoping > someone can lend a hand with. The basic notion is that a given object > will potentially contain other objects, but these contained objects > aren't known (or generated) until runtime. > > For example, we'll instantiate a sales_order object and then, using its > has_a() method, add a customer object to it. To prevent cascades of > objects being instantiated, I'd plan to use lazy initialization - the > customer object won't be instantiated until the first time that it's > accessed through the customer class. The problem that I'm having is that > lazy initialization in PHP 5 is accomplished via the __get() method > which is called when an attribute (or contained class in this) isn't > available - it's passed the name of the property that wasn't found and > that's not enough information for me to return the attribute of the > contained object that was being accessed. Here's some quickly written > code with extra code stripped that'll demonstrate what I mean: > > > class sales_order { > ... > > public function has_a( $class ) { > $this->relationships[ $class ] = 'has_a'; > } > > public function __get( $class ) { > if(array_key_exists( $class, $this->relationships )) { > if( $this->relationships[ $class ] == 'has_a') { > $this->$class = new $class( $this->id ); > return; > } > } > } > } > > So if $attribute exists in the relationships array, it's instantiated > (and, yeah, I plan to move the contained objects into a declared array. > one thing at a time :) ) > > $sales_order = new sales_order; > $sales_order->has_a( customer ); > print $sales_order->customer->name; > > The last line fails, because __get is passed only 'customer' and not > 'customer->name' - I have no way of knowing what attribute of customer > was being accessed, so I can't return the requested data. Running this > code: > > $sales_order = new sales_order; > $sales_order->has_a( customer ); > print $sales_order->customer->name; > print $sales_order->customer->name; > > the fourth line works, because the customer object was instantiated > during line three (line three still fails to return a value). Does > anyone have any suggestions on how to get this working? > > Apologies in advance for the verbosity of this email, I really did try > to strip out as much as I could. > > thanks! > > > -- > Jason N Perkins > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From jperkins at sneer.org Wed Nov 10 20:24:58 2004 From: jperkins at sneer.org (Jason Perkins) Date: Wed, 10 Nov 2004 19:24:58 -0600 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: <4192BC23.9090304@phpwerx.net> References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4192BC23.9090304@phpwerx.net> Message-ID: <80791D37-3380-11D9-8B36-000D932DF2B4@sneer.org> On Nov 10, 2004, at 7:10 PM, Dan Cech wrote: > I'm not 100% on overloading in php5, but I think you need either: Hey Dan, no joy on those suggestions, though I did have some hope for the second one. The problem is that __get() is truncating the attribute that wasn't found from customer->name to just customer, so I don't know what attribute access of customer failed - if I did know then it'd just be a matter of splitting out the first class name before the -> operator, instantiating that class name and then returning its property asked for (it'd actually be more than that to account for nested containers, but you see what I'm driving at). Failing this method, does anyone have any other suggestions on implementing this type functionality? -- Jason N Perkins From adam at trachtenberg.com Wed Nov 10 20:45:52 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Wed, 10 Nov 2004 20:45:52 -0500 (EST) Subject: [nycphp-talk] lazy initialization woes In-Reply-To: <4192BC23.9090304@phpwerx.net> References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4192BC23.9090304@phpwerx.net> Message-ID: On Wed, 10 Nov 2004, Dan Cech wrote: > $this->$class =& $obj =& new $class( $this->id ); FWIW, these types of nasty hacks should no longer be necessary in PHP 5, God willing. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From adam at trachtenberg.com Wed Nov 10 20:50:24 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Wed, 10 Nov 2004 20:50:24 -0500 (EST) Subject: [nycphp-talk] lazy initialization woes In-Reply-To: <80791D37-3380-11D9-8B36-000D932DF2B4@sneer.org> References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4192BC23.9090304@phpwerx.net> <80791D37-3380-11D9-8B36-000D932DF2B4@sneer.org> Message-ID: On Wed, 10 Nov 2004, Jason Perkins wrote: > Failing this method, does anyone have any other suggestions on > implementing this type functionality? The first thing I would do is try is to sloppy way and just instantiate every object. I would then benchmark the performance and see if it's acceptable. Why stress out over a complicated programming solution when the easy one may work perfectly fine? Alternatively, it may be as simple as putting more RAM in your boxes, which would be far less than the development time necessary to write and maintain this. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From jperkins at sneer.org Wed Nov 10 21:10:46 2004 From: jperkins at sneer.org (Jason Perkins) Date: Wed, 10 Nov 2004 20:10:46 -0600 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4192BC23.9090304@phpwerx.net> <80791D37-3380-11D9-8B36-000D932DF2B4@sneer.org> Message-ID: On Nov 10, 2004, at 7:50 PM, Adam Maccabee Trachtenberg wrote: > On Wed, 10 Nov 2004, Jason Perkins wrote: > >> Failing this method, does anyone have any other suggestions on >> implementing this type functionality? > > The first thing I would do is try is to sloppy way and just > instantiate every object. I would then benchmark the performance and > see if it's acceptable. > > Why stress out over a complicated programming solution when the easy > one may work perfectly fine? The notion was to use this as the basis for an ORM (ala Class::DBI or Ruby on Rails) and in that context, given the right circumstances, it could lead to unnecessarily loading hundreds (or even thousands) a shitload of objects. I'm headed out for a walk and a cig or two to mull this over. Thanks for the suggestion, Adam. -- Jason N Perkins From jonbaer at jonbaer.net Wed Nov 10 21:52:49 2004 From: jonbaer at jonbaer.net (Jon Baer) Date: Wed, 10 Nov 2004 21:52:49 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? Message-ID: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> Hi, Kinda lame but, I tried looking for something on web which made light of what packages/libraries/functions most people were using on a normal basis so .. thought Id start a quick little topic, more like a survey, maybe someone would like to compile it and post? Here goes, pretty self explainatory: What are the top 5 most *useful* PHP functions to you? (in no order) + preg_match_all + preg_replace + array_unique + array_combine + (tie) file_get_contents and simplexml_load_string - Jon From krook at us.ibm.com Wed Nov 10 22:11:36 2004 From: krook at us.ibm.com (Daniel Krook) Date: Wed, 10 Nov 2004 22:11:36 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> Message-ID: > What are the top 5 most *useful* PHP functions to you? 1. echo() :) My favorite has always been explode() though. The name of that function alone got me interested in learning more about PHP. So in a way I guess it was the most useful. Daniel Krook, Application Developer WW Web Production Services North 2, ibm.com 1133 Westchester Avenue, White Plains, NY 10604 Personal: http://info.krook.org/ Persona: http://w3.ibm.com/eworkplace/persona_bp_finder.jsp?CNUM=9A9796897 From shiflett at php.net Wed Nov 10 22:28:39 2004 From: shiflett at php.net (Chris Shiflett) Date: Wed, 10 Nov 2004 19:28:39 -0800 (PST) Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: Message-ID: <20041111032839.22106.qmail@web52804.mail.yahoo.com> --- Daniel Krook wrote: > > What are the top 5 most *useful* PHP functions to you? > > 1. echo() :) Can that really count, though? :-) (For the record, I'm not trying to be one of those people who claim we only have 8 fingers and 2 thumbs). > My favorite has always been explode() though. Yeah, a cool and intuitive name, plus it's pretty fast. Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming February 2005 http://httphandbook.org/ From agfische at email.smith.edu Wed Nov 10 22:29:26 2004 From: agfische at email.smith.edu (Aaron Fischer) Date: Wed, 10 Nov 2004 22:29:26 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: Message-ID: I'd have to second the explode(), and it's antithesis, implode(). Just the names alone validated how cool PHP is. =) -Aaron On Nov 10, 2004, at 10:11 PM, Daniel Krook wrote: >> What are the top 5 most *useful* PHP functions to you? > > My favorite has always been explode() though. The name of that > function > alone got me interested in learning more about PHP. So in a way I > guess > it was the most useful. From j at nybg.org Wed Nov 10 22:57:44 2004 From: j at nybg.org (Freeman, Joshua) Date: Wed, 10 Nov 2004 22:57:44 -0500 Subject: [nycphp-talk] newbie confusion Message-ID: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> Hi all, I finally have a real-world project that has impelled me to get beyond all the basic tutorials I've gone through.. but I'm stuck. Here's the description of what I'm trying to achieve and the problem(s). when a hiring manager at my employer hires a new person, the HR dept. presents the hiring mgr. with these 4.25 x 5.5 inch slips of paper with some questions for rating the applicants.. you interview 5 people, you have to fill out five pieces of paper. My Database: 1) ethnicity: eth_id, eth_name (5 rows.. will never change) 2) position: pos_id, pos_name (i want to avoid creating multiple names for the same position) 3) interviewer: int_id, int_fname, int_lname (these are the managers... I'd like to prevent people from putting their name in different ways at different times (like.. Josh Freeman, Joshua Freeman..) 4) applicant: app_id, app_name (what if the same applicant applies for more than one position?) 5) reason: reason_id, reason_text (i.e. too inexperienced, not enough experience.. mean the same thing.. so create a separate table...) and the MAIN TABLE! 6) rating: rating_id, app_id, pos_id, eth_id, gender(enum or separate table?), interested (ditto), reason_id, comments, datestamp So.. already, I need some guidance on how much to break this out.. do I need two more tables for gender and 'interested'? Here's my pseudo code: 1) page loads: while loading, php reaches into the tables of the database to grab the existing lists of interviewers, positions, applicants, ethnicities, reasons and maybe genders and 'interested' 2) page displays the form: using the information grabbed while loading the form consists of: pulldowns for interviewer, position, applicant, ethnicity, reason radio button for gender checkbox for 'interested' and textarea for comments 2a) in addition to pulldowns, the person filling out the form can write in interviewer fname, lname, position name, applicant fname, lname and reason... 3) person submits form ... if information was written in instead of taken from the pulldowns then that information needs to get written to the correct tables and then the id numbers from those rows have to be put into the new record being created in the main table... Finally, 4) the submitted data is displayed back to the browser Does this all make sense? I can take form input and put it into a single table, but now.. I'm really LOST.. can someone help me? I'm googling for the tutorial(s) or examples I need but I'm not finding yet... Thanks in advance for any handholding or advice. Cheers, J. Joshua S. Freeman Director, Information Technology, NYBG v: 718 817 8937 m: 347 392 2560 jfreeman at nybg dot org -------------- next part -------------- An HTML attachment was scrubbed... URL: From chsnyder at gmail.com Wed Nov 10 23:09:02 2004 From: chsnyder at gmail.com (csnyder) Date: Wed, 10 Nov 2004 23:09:02 -0500 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4192BC23.9090304@phpwerx.net> <80791D37-3380-11D9-8B36-000D932DF2B4@sneer.org> Message-ID: You've already guessed that this is pushing the envelope in php, but that makes it kinda cool, too. Does this seem like a bug to anyone else? It *should* work exactly the way you expect it to, Jason. I know that probably doesn't help right now tonight. Would it help to use a slightly different tack? function __call( $class, $args ) { if(array_key_exists( $class, $this->relationships )) { if( $this->relationships[ $class ] == 'has_a') { if ( isset( $this->{$class} ) ) { return $this->{$class}->{$args[0]}; } else { $this->$class = new $class( $this->id ); return $this->{$class}->{$args[0]}; } } } } print $sales_order->customer('name'); From mwithington at PLMresearch.com Wed Nov 10 23:14:36 2004 From: mwithington at PLMresearch.com (Mark Withington) Date: Wed, 10 Nov 2004 23:14:36 -0500 Subject: [nycphp-talk] newbie confusion Message-ID: <1F3CD8DDFB6A9B4C9B8DD06E4A7DE358C412E8@network.PLMresearch.com> Josh, Here's my suggestion - go to http://www.dadabik.org , download the code, run it against the table you've created, it'll walk you through the rest; impress the HR folks and than take the rest of the week off (wow, sounds like a recipe for a career fast track ;-) Cheers, Mark -------------------------- Mark L. Withington PLMresearch "eBusiness for the Midsize Enterprise" PO Box 1354 Plymouth, MA 02362 o: 800-310-3992 f: 508-746-4973 v: 508-746-2383 m: 508-801-0181 http://www.PLMresearch.com Netscape/AOL/MSN IM: PLMresearch mwithington at plmresearch.com Public Key: http://www.PLMresearch.com/keys/MLW_public_key.asc Calendar: http://www.plmresearch.com/calendar.php -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org]On Behalf Of Freeman, Joshua Sent: Wednesday, November 10, 2004 10:58 PM To: talk at lists.nyphp.org Subject: [nycphp-talk] newbie confusion Hi all, I finally have a real-world project that has impelled me to get beyond all the basic tutorials I've gone through.. but I'm stuck. Here's the description of what I'm trying to achieve and the problem(s). when a hiring manager at my employer hires a new person, the HR dept. presents the hiring mgr. with these 4.25 x 5.5 inch slips of paper with some questions for rating the applicants.. you interview 5 people, you have to fill out five pieces of paper. My Database: 1) ethnicity: eth_id, eth_name (5 rows.. will never change) 2) position: pos_id, pos_name (i want to avoid creating multiple names for the same position) 3) interviewer: int_id, int_fname, int_lname (these are the managers... I'd like to prevent people from putting their name in different ways at different times (like.. Josh Freeman, Joshua Freeman..) 4) applicant: app_id, app_name (what if the same applicant applies for more than one position?) 5) reason: reason_id, reason_text (i.e. too inexperienced, not enough experience.. mean the same thing.. so create a separate table...) and the MAIN TABLE! 6) rating: rating_id, app_id, pos_id, eth_id, gender(enum or separate table?), interested (ditto), reason_id, comments, datestamp So.. already, I need some guidance on how much to break this out.. do I need two more tables for gender and 'interested'? Here's my pseudo code: 1) page loads: while loading, php reaches into the tables of the database to grab the existing lists of interviewers, positions, applicants, ethnicities, reasons and maybe genders and 'interested' 2) page displays the form: using the information grabbed while loading the form consists of: pulldowns for interviewer, position, applicant, ethnicity, reason radio button for gender checkbox for 'interested' and textarea for comments 2a) in addition to pulldowns, the person filling out the form can write in interviewer fname, lname, position name, applicant fname, lname and reason... 3) person submits form ... if information was written in instead of taken from the pulldowns then that information needs to get written to the correct tables and then the id numbers from those rows have to be put into the new record being created in the main table... Finally, 4) the submitted data is displayed back to the browser Does this all make sense? I can take form input and put it into a single table, but now.. I'm really LOST.. can someone help me? I'm googling for the tutorial(s) or examples I need but I'm not finding yet... Thanks in advance for any handholding or advice. Cheers, J. Joshua S. Freeman Director, Information Technology, NYBG v: 718 817 8937 m: 347 392 2560 jfreeman at nybg dot org -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/ms-tnef Size: 6690 bytes Desc: not available URL: From chsnyder at gmail.com Wed Nov 10 23:21:06 2004 From: chsnyder at gmail.com (csnyder) Date: Wed, 10 Nov 2004 23:21:06 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: Message-ID: Okay, I'll bite: 1) file_get_contents() -- could anything be easier? 2) serialize() -- for storable objects 3) strpos() -- even more important to me than substr() 4) htmlentities() -- speaks unicode 5) print_r() -- one-line debugger And if I had to pick a control structure it would be foreach. I mean, does anyone use list() anymore? From j at nybg.org Wed Nov 10 23:24:37 2004 From: j at nybg.org (Freeman, Joshua) Date: Wed, 10 Nov 2004 23:24:37 -0500 Subject: [nycphp-talk] newbie confusion Message-ID: <319FD9EAB7A43E43895ACA5AA1F81E05F886F2@xmail.nybg.org> I'll try it.. in the meantime... here's another question... what is PHP's default include_path on OSX 10.3? I want to install Smarty too. Thanks! Cheers, J. Joshua S. Freeman Director, Information Technology, NYBG v: 718 817 8937 m: 347 392 2560 jfreeman at nybg dot org -----Original Message----- From: talk-bounces at lists.nyphp.org on behalf of Mark Withington Sent: Wed 11/10/2004 11:14 PM To: 'NYPHP Talk' Subject: RE: [nycphp-talk] newbie confusion Josh, Here's my suggestion - go to http://www.dadabik.org , download the code, run it against the table you've created, it'll walk you through the rest; impress the HR folks and than take the rest of the week off (wow, sounds like a recipe for a career fast track ;-) Cheers, Mark -------------------------- Mark L. Withington PLMresearch "eBusiness for the Midsize Enterprise" PO Box 1354 Plymouth, MA 02362 o: 800-310-3992 f: 508-746-4973 v: 508-746-2383 m: 508-801-0181 http://www.PLMresearch.com Netscape/AOL/MSN IM: PLMresearch mwithington at plmresearch.com Public Key: http://www.PLMresearch.com/keys/MLW_public_key.asc Calendar: http://www.plmresearch.com/calendar.php -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org]On Behalf Of Freeman, Joshua Sent: Wednesday, November 10, 2004 10:58 PM To: talk at lists.nyphp.org Subject: [nycphp-talk] newbie confusion Hi all, I finally have a real-world project that has impelled me to get beyond all the basic tutorials I've gone through.. but I'm stuck. Here's the description of what I'm trying to achieve and the problem(s). when a hiring manager at my employer hires a new person, the HR dept. presents the hiring mgr. with these 4.25 x 5.5 inch slips of paper with some questions for rating the applicants.. you interview 5 people, you have to fill out five pieces of paper. My Database: 1) ethnicity: eth_id, eth_name (5 rows.. will never change) 2) position: pos_id, pos_name (i want to avoid creating multiple names for the same position) 3) interviewer: int_id, int_fname, int_lname (these are the managers... I'd like to prevent people from putting their name in different ways at different times (like.. Josh Freeman, Joshua Freeman..) 4) applicant: app_id, app_name (what if the same applicant applies for more than one position?) 5) reason: reason_id, reason_text (i.e. too inexperienced, not enough experience.. mean the same thing.. so create a separate table...) and the MAIN TABLE! 6) rating: rating_id, app_id, pos_id, eth_id, gender(enum or separate table?), interested (ditto), reason_id, comments, datestamp So.. already, I need some guidance on how much to break this out.. do I need two more tables for gender and 'interested'? Here's my pseudo code: 1) page loads: while loading, php reaches into the tables of the database to grab the existing lists of interviewers, positions, applicants, ethnicities, reasons and maybe genders and 'interested' 2) page displays the form: using the information grabbed while loading the form consists of: pulldowns for interviewer, position, applicant, ethnicity, reason radio button for gender checkbox for 'interested' and textarea for comments 2a) in addition to pulldowns, the person filling out the form can write in interviewer fname, lname, position name, applicant fname, lname and reason... 3) person submits form ... if information was written in instead of taken from the pulldowns then that information needs to get written to the correct tables and then the id numbers from those rows have to be put into the new record being created in the main table... Finally, 4) the submitted data is displayed back to the browser Does this all make sense? I can take form input and put it into a single table, but now.. I'm really LOST.. can someone help me? I'm googling for the tutorial(s) or examples I need but I'm not finding yet... Thanks in advance for any handholding or advice. Cheers, J. Joshua S. Freeman Director, Information Technology, NYBG v: 718 817 8937 m: 347 392 2560 jfreeman at nybg dot org -------------- next part -------------- An HTML attachment was scrubbed... URL: From chsnyder at gmail.com Wed Nov 10 23:28:27 2004 From: chsnyder at gmail.com (csnyder) Date: Wed, 10 Nov 2004 23:28:27 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <319FD9EAB7A43E43895ACA5AA1F81E05F886F2@xmail.nybg.org> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F2@xmail.nybg.org> Message-ID: Save it in your Sites folder as info.php and you'll have the answer to that and many other questions. From j at nybg.org Wed Nov 10 23:30:07 2004 From: j at nybg.org (Freeman, Joshua) Date: Wed, 10 Nov 2004 23:30:07 -0500 Subject: [nycphp-talk] newbie confusion Message-ID: <319FD9EAB7A43E43895ACA5AA1F81E05F886F3@xmail.nybg.org> Thanks much! J. Joshua S. Freeman Director, Information Technology, NYBG v: 718 817 8937 m: 347 392 2560 jfreeman at nybg dot org -----Original Message----- From: talk-bounces at lists.nyphp.org on behalf of csnyder Sent: Wed 11/10/2004 11:28 PM To: NYPHP Talk Subject: Re: [nycphp-talk] newbie confusion Save it in your Sites folder as info.php and you'll have the answer to that and many other questions. _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org -------------- next part -------------- A non-text attachment was scrubbed... Name: winmail.dat Type: application/ms-tnef Size: 2578 bytes Desc: not available URL: From chendry at gmail.com Wed Nov 10 23:30:18 2004 From: chendry at gmail.com (Christopher Hendry) Date: Wed, 10 Nov 2004 23:30:18 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> Message-ID: <769e4ce04111020305d269833@mail.gmail.com> > > I'm googling for the tutorial(s) or examples I need but I'm not finding > yet... > Well, it pretty much sounds like you're off to a good start. Breaking down the application flow, abstracting where you can, etc. But I'm not quite sure where your question is. I'd recommend putting the same kind of thought to the places where you are 'lost' - ie, if you're wondering how to put new interviewers into the DB that don't exist, break it down step by step and write some functions to handle it. Otherwise www.php.net/mysql_insert_id will probably be handy. function add_new_interviewer( &$interveiwer_info ) { $query = "INSERT..."; $result = mysql_query($query) or error_handler(); $new_key = mysql_insert_id(); // yes, yes - need better error handling, what if the insert fails? return $new_key; } if (!$pulldown) $new_interviewer_ID = add_new_interviewer( $some_form_data ); I would say you're pretty safe with gender being an enum - unless we're looking to add some new genders some time soon. Interested? Well, if you're certain that you'll never use anything besides yes or no than an enum could work, as could a tiny int for true/false. Kinda depends on your app. But why add an extra query or join when they will not change and can be coded into your app (or config file). Overall remember that applications evolve and do your best to allow for that in your initial design. You'll never get it perfect and pieces will have to be rewritten - but it seems to me that you're doing just fine. :) C -- "When you do things right, people won't be sure you've done anything at all." From chendry at gmail.com Wed Nov 10 23:35:36 2004 From: chendry at gmail.com (Christopher Hendry) Date: Wed, 10 Nov 2004 23:35:36 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: Message-ID: <769e4ce04111020351dc25cbc@mail.gmail.com> > 4) htmlentities() -- speaks unicode What then the aptly named html_entities_decode? Yes, I'm feeling punchy tonite. C -- "When you do things right, people won't be sure you've done anything at all." From shiflett at php.net Wed Nov 10 23:56:11 2004 From: shiflett at php.net (Chris Shiflett) Date: Wed, 10 Nov 2004 20:56:11 -0800 (PST) Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <769e4ce04111020351dc25cbc@mail.gmail.com> Message-ID: <20041111045611.49089.qmail@web52804.mail.yahoo.com> --- Christopher Hendry wrote: > > 4) htmlentities() -- speaks unicode > > What then the aptly named html_entities_decode? Or i_wish_php_5_had_name_spaces_so_this_wasnt_necessary(). :-) Chris ===== Chris Shiflett - http://shiflett.org/ PHP Security - O'Reilly HTTP Developer's Handbook - Sams Coming February 2005 http://httphandbook.org/ From mitch.pirtle at gmail.com Thu Nov 11 00:08:41 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Thu, 11 Nov 2004 00:08:41 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <20041111045611.49089.qmail@web52804.mail.yahoo.com> References: <769e4ce04111020351dc25cbc@mail.gmail.com> <20041111045611.49089.qmail@web52804.mail.yahoo.com> Message-ID: <330532b6041110210870199124@mail.gmail.com> > What are the top 5 most *useful* PHP functions to you? (in no order) Hmm, lessee... * phpinfo * print_r * echo * isset * system With these five (and my trusty homemade functions and classes) I have all I need to make a website. That's all. And I need this Image_Remote(). That's it, just these five functions and Image_Remote(). And my dog (dog growls viciously and trots off) okay I don't need my dog. -- Mitch, needing to rent some new videos From Cbielanski at inta.org Thu Nov 11 08:44:32 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Thu, 11 Nov 2004 08:44:32 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA49@intamail1.com> I'll sell you a Pirtle-port-PHP-parser that includes only these necessary operations for the low low price of... One Dollar.. and NINE CENTS!! (who needs new movies? The old ones just have that Macrovision bit-rot creeping down the frame but hey! That's *vintage!!*) Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence > -----Original Message----- > From: Mitch Pirtle [mailto:mitch.pirtle at gmail.com] > Sent: Thursday, November 11, 2004 12:09 AM > To: NYPHP Talk > Subject: Re: [nycphp-talk] Top 5 Most Useful PHP Functions? > > > > What are the top 5 most *useful* PHP functions to you? (in no order) > > Hmm, lessee... > > * phpinfo > * print_r > * echo > * isset > * system > > With these five (and my trusty homemade functions and classes) I have > all I need to make a website. That's all. And I need this > Image_Remote(). That's it, just these five functions and > Image_Remote(). And my dog (dog growls viciously and trots off) okay > I don't need my dog. > > -- Mitch, needing to rent some new videos > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From agfische at email.smith.edu Thu Nov 11 08:41:49 2004 From: agfische at email.smith.edu (Aaron Fischer) Date: Thu, 11 Nov 2004 08:41:49 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <769e4ce04111020305d269833@mail.gmail.com> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> Message-ID: <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> I'm curious to know what the "&" is for in the statement below? -Aaron On Nov 10, 2004, at 11:30 PM, Christopher Hendry wrote: > function add_new_interviewer( &$interveiwer_info ) { From codebowl at gmail.com Thu Nov 11 09:14:33 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Thu, 11 Nov 2004 09:14:33 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> Message-ID: <8d9a428004111106147b1d7c34@mail.gmail.com> > I'm curious to know what the "&" is for in the statement below? > > -Aaron Let me explain a bit and try to make it so you understand. In PHP & is the reference operator, this allows you to pass a variable by reference rather than by value. Here is an example $var = 4; func( $var ); // echo's 4 echo $var; function func( $var ) { $var++; // echo's 5 echo $var; } if you run this code, you will see how the values of $var are different inside the function and outside the function. The one outside the function is 4 and the one inside is 4. When you pass by value php defaults to making a copy of the variable. When you use the & (reference operator) it will pass $var by reference rather than by value, this passes the memory address rather than making a copy of the variable. Let me show anoher example. $var = 4; func( &$var ); // echo's 5 echo $var; function ( $var ) { $var++; } If i am correct about this (which i believe i am) when you echo $var after the function call, $var now equals 5 because you passed the variable by reference rather than letting PHP make a copy. You need to be careful passing variables/objects by reference, if you do not intend to have the function change the value of the variable outside of the functions scope, do not pass by reference. I hope you understood everything i have said, if you do not, please feel free to ask any questions reguarding my reply. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From codebowl at gmail.com Thu Nov 11 09:15:06 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Thu, 11 Nov 2004 09:15:06 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <8d9a428004111106147b1d7c34@mail.gmail.com> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> <8d9a428004111106147b1d7c34@mail.gmail.com> Message-ID: <8d9a42800411110615739ea288@mail.gmail.com> Oh and if i have something wrong, someone please reply and correct me :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From mitch.pirtle at gmail.com Thu Nov 11 09:21:40 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Thu, 11 Nov 2004 09:21:40 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> Message-ID: <330532b604111106215d45a378@mail.gmail.com> On Thu, 11 Nov 2004 08:41:49 -0500, Aaron Fischer wrote: > I'm curious to know what the "&" is for in the statement below? > > On Nov 10, 2004, at 11:30 PM, Christopher Hendry wrote: > > > function add_new_interviewer( &$interveiwer_info ) { > That is known as passing by reference. When you omit the '&', you are actually making a copy of it instead of passing it directly to that function or method. This can be a problem with larger apps under heavy load, where you accidentally have the webserver making copies of many arrays and objects. This behavior is changed by default in PHP5, and there are others on this list that are much more knowledgable on PHP5 than I. I'm still trying to get Fedora Core 3 to install ;-) -- Mitch, burning another set of CDs From sol2ray at gmail.com Thu Nov 11 09:22:06 2004 From: sol2ray at gmail.com (Sol Toure) Date: Thu, 11 Nov 2004 09:22:06 -0500 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> Message-ID: <4a67dc3904111106221bc19e03@mail.gmail.com> > $sales_order = new sales_order; > $sales_order->has_a( customer ); > print $sales_order->customer->name; > print $sales_order->customer->name; > > the fourth line works, because the customer object was instantiated > during line three (line three still fails to return a value). Does > anyone have any suggestions on how to get this working? Line 3 fails because you do not return anyting from __get() You should return " $this->$class " from your __get function call. Line 3 = $undifined->name; Line 4 succeeds because __get is not called and you have now a new property "$this->class" that is public by default so therefore accessed directly. Line 4 = $customer->name; From Cbielanski at inta.org Thu Nov 11 09:28:59 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Thu, 11 Nov 2004 09:28:59 -0500 Subject: [nycphp-talk] newbie confusion Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA4A@intamail1.com> Code examples aside, my favorite analogy regarding the difference between value and reference passing is: "A variable is like a piece of smail-mail, it comes with two parts: The letter (or value) and the envelope (or address). When you open the envelope and give someone the letter inside, you are passing by value (or assigning). It's the same as the "=" operation. When you give someone the envelope, you are passing by reference. That's the operation done by "=&" and its up to them to dereference the mail - to open the envelop to see what's inside." Maybe someone will find that useful... Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence > -----Original Message----- > From: Joseph Crawford [mailto:codebowl at gmail.com] > Sent: Thursday, November 11, 2004 9:15 AM > To: NYPHP Talk > Subject: Re: [nycphp-talk] newbie confusion > > > > I'm curious to know what the "&" is for in the statement below? > > > > -Aaron > > > Let me explain a bit and try to make it so you understand. In PHP & > is the reference operator, this allows you to pass a variable by > reference rather than by value. Here is an example > > $var = 4; > func( $var ); > // echo's 4 > echo $var; > > function func( $var ) { > $var++; > // echo's 5 > echo $var; > } > > if you run this code, you will see how the values of $var are > different inside the function and outside the function. The one > outside the function is 4 and the one inside is 4. When you pass by > value php defaults to making a copy of the variable. > > When you use the & (reference operator) it will pass $var by reference > rather than by value, this passes the memory address rather than > making a copy of the variable. Let me show anoher example. > > $var = 4; > func( &$var ); > // echo's 5 > echo $var; > > function ( $var ) { > $var++; > } > > If i am correct about this (which i believe i am) when you echo $var > after the function call, $var now equals 5 because you passed the > variable by reference rather than letting PHP make a copy. You need > to be careful passing variables/objects by reference, if you do not > intend to have the function change the value of the variable outside > of the functions scope, do not pass by reference. > > I hope you understood everything i have said, if you do not, please > feel free to ask any questions reguarding my reply. > > > -- > Joseph Crawford Jr. > Codebowl Solutions > codebowl at gmail.com > > For a GMail account > contact me OFF-LIST > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From agfische at email.smith.edu Thu Nov 11 09:29:11 2004 From: agfische at email.smith.edu (Aaron Fischer) Date: Thu, 11 Nov 2004 09:29:11 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <8d9a428004111106147b1d7c34@mail.gmail.com> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> <8d9a428004111106147b1d7c34@mail.gmail.com> Message-ID: <0E38C685-33EE-11D9-8193-0003930D07F2@email.smith.edu> Thanks, that's helpful to know, I didn't realize PHP had the option of passing variables by reference. -Aaron On Nov 11, 2004, at 9:14 AM, Joseph Crawford wrote: > When you use the & (reference operator) it will pass $var by reference > rather than by value, this passes the memory address rather than > making a copy of the variable. Let me show anoher example. From codebowl at gmail.com Thu Nov 11 09:59:06 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Thu, 11 Nov 2004 09:59:06 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: <0E38C685-33EE-11D9-8193-0003930D07F2@email.smith.edu> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> <8d9a428004111106147b1d7c34@mail.gmail.com> <0E38C685-33EE-11D9-8193-0003930D07F2@email.smith.edu> Message-ID: <8d9a428004111106594bded2ee@mail.gmail.com> yea it is very similar to pointers in c if you have any c experience :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From jperkins at sneer.org Thu Nov 11 10:24:52 2004 From: jperkins at sneer.org (Jason Perkins) Date: Thu, 11 Nov 2004 09:24:52 -0600 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4192BC23.9090304@phpwerx.net> <80791D37-3380-11D9-8B36-000D932DF2B4@sneer.org> Message-ID: On Nov 10, 2004, at 10:09 PM, csnyder wrote: > You've already guessed that this is pushing the envelope in php, but > that makes it kinda cool, too. > > Does this seem like a bug to anyone else? It *should* work exactly the > way you expect it to, Jason. I know that probably doesn't help right > now tonight. I've sent a reworded email to internals to see if this is how they'd anticipated __get() working or not. I'll submit a bug report based on the responses that I receive. > Would it help to use a slightly different tack? That's a good idea, and I'll probably wind up using something like that if the issue with __get() can't be resolved. Thank you and the other responders for your help! -- Jason N Perkins From jperkins at sneer.org Thu Nov 11 10:26:08 2004 From: jperkins at sneer.org (Jason Perkins) Date: Thu, 11 Nov 2004 09:26:08 -0600 Subject: [nycphp-talk] lazy initialization woes In-Reply-To: <4a67dc3904111106221bc19e03@mail.gmail.com> References: <4FC7F25A-337C-11D9-8B36-000D932DF2B4@sneer.org> <4a67dc3904111106221bc19e03@mail.gmail.com> Message-ID: <02961F9E-33F6-11D9-8B36-000D932DF2B4@sneer.org> On Nov 11, 2004, at 8:22 AM, Sol Toure wrote: >> $sales_order = new sales_order; >> $sales_order->has_a( customer ); >> print $sales_order->customer->name; >> print $sales_order->customer->name; >> >> the fourth line works, because the customer object was instantiated >> during line three (line three still fails to return a value). Does >> anyone have any suggestions on how to get this working? > > Line 3 fails because you do not return anyting from __get() > You should return " $this->$class " from your __get function call. > Line 3 = $undifined->name; > Line 4 succeeds because __get is not called and you have now a new > property "$this->class" that is public by default so therefore > accessed directly. > Line 4 = $customer->name; returning just the class doesn't work - I'm attempting to access an attribute of that class. Thanks for the reply, though. -- Jason N Perkins From rrust at r2communications.com Thu Nov 11 11:01:21 2004 From: rrust at r2communications.com (Randal Rust) Date: Thu, 11 Nov 2004 11:01:21 -0500 Subject: [nycphp-talk] Enterprise-level Functionality in PHP Message-ID: <41938CD1.7000401@r2communications.com> For the past two years, I have been in charge of the development of a prototype for an enterprise-level application. The prototype is in PHP/MySQL/ADODB and the *real* application is J2EE. So what I am looking to do is add some of the enterprise-level functions into the system, such as: - workflow - live chat - imaging and document management - integration with Adobe Forms I've found some live chat options, but don't seem to be having much luck in the other areas. Any suggestions? -- Randal Rust R.Squared Communications http://www.r2communications.com Digital Design for Bricks-and-Mortar Businesses From codebowl at gmail.com Thu Nov 11 11:42:36 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Thu, 11 Nov 2004 11:42:36 -0500 Subject: [nycphp-talk] A Bit Of Help Message-ID: <8d9a428004111108424e617dee@mail.gmail.com> Guys, I have an sql query that uses one table to join another, the tables are ci2_bizopps and ci2_companies, each company could have many entries in the bizopps table and what i need to do is get each company name only once. However since we are searching the bizopps table it returns a result for each bizopp found, this makes for duplicate company names added to the array. The following code works if i remove the ORDER BY statement in the SQL query, however for some reason with it in there it breaks the code. $result = $db->query(" SELECT b.id as bizopp_id, b.contract_name, c.id as company_id, c.name as company FROM ci2_bizopps b INNER JOIN ci2_companies c ON b.company_id=c.id WHERE b.contract_type=".$type." ORDER BY c.name ASC" ); $results = $db->fetchAll($result); $data = "\n"; $arr = array(); foreach($results as $result) { if(!array_search($result['company_id'], $arr)) { $data .= "\n"; $data .= "\n"; $data .= "\n"; $arr[] = $result['company_id']; } } $data .= "
".$result['company']."
"; return $data; as you can see all i did was for each record found, store the company id into another array, and also use array_search to search the array to see if that company_id has already been used. If it has been used, do nothing otherwise display the data for that company.. I have printed out the value of company_id and $arr for each item and with the order by statement, it says the company id is 2 but 2 is also in the arr 3 times, so i am not sure why array_search is not finding it in the array and just skipping it. I guess one way of accomplishing this is to not use the ORDER BY statement but create yet another array, add the companies to that which will be displayed and then sorting the array and then displaying but i think the order by would be much easier to use if it can be done. Here are the results shown with the ORDER BY in place IPRO PRO NJ Test Data Romy's Widgets The British Medicine Group IPRO IPRO And here are the results without the ORDER BY in place The British Medicine Group Romy's Widgets The British Medicine Group IPRO PRO NJ Test Data This is really starting to get to me after working on this for a while the other day to finally get it working and today just to break it with an order by statement ;D Anyone that can help i would greatly appreciate it. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From adam at trachtenberg.com Thu Nov 11 11:49:35 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Thu, 11 Nov 2004 11:49:35 -0500 (EST) Subject: [nycphp-talk] newbie confusion In-Reply-To: <330532b604111106215d45a378@mail.gmail.com> References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> <330532b604111106215d45a378@mail.gmail.com> Message-ID: On Thu, 11 Nov 2004, Mitch Pirtle wrote: > This behavior is changed by default in PHP5, and there are others on > this list that are much more knowledgable on PHP5 than I. I'm still > trying to get Fedora Core 3 to install ;-) In PHP 5, objects are passed (into and out of functions, etc) and copied by reference. Everything else (scalars, strings, booleans, etc.) behave the same and are passed by value. To make a by-value copy of an object, use the clone operator: $copy = clone $original; To control the cloning behavior of a class, define a __clone() method. More details available in "Upgrading to PHP 5." :) -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From rahmin at insite-out.com Thu Nov 11 11:51:52 2004 From: rahmin at insite-out.com (Rahmin Pavlovic) Date: Thu, 11 Nov 2004 11:51:52 -0500 Subject: [nycphp-talk] A Bit Of Help Message-ID: <200411111651.iABGpqXv013198@webmail3.megamailservers.com> An embedded and charset-unspecified text was scrubbed... Name: not available URL: From codebowl at gmail.com Thu Nov 11 11:54:55 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Thu, 11 Nov 2004 11:54:55 -0500 Subject: [nycphp-talk] A Bit Of Help In-Reply-To: <200411111651.iABGpqXv013198@webmail3.megamailservers.com> References: <200411111651.iABGpqXv013198@webmail3.megamailservers.com> Message-ID: <8d9a4280041111085474690513@mail.gmail.com> OH YEA! I completely did not know about GROUP BY that is amazing, it worked great. It also allowed for me to rid myself of that sloppy array index and search code :) thanks for your help with that ;D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From brent at landover.com Thu Nov 11 12:14:24 2004 From: brent at landover.com (Brent Baisley) Date: Thu, 11 Nov 2004 12:14:24 -0500 Subject: [nycphp-talk] A Bit Of Help In-Reply-To: <8d9a428004111108424e617dee@mail.gmail.com> References: <8d9a428004111108424e617dee@mail.gmail.com> Message-ID: <22796D46-3405-11D9-AC4C-000A95CD828E@landover.com> I think the problem may be in the array_search function. Array search returns the key of the item found or FALSE (or NULL in older versiosns) if it is not found. So what happens when there is a match found at the 0 element? Since array_search returns 0, your if() statement probably evaluates to true (!0), since 0 can also mean false. It's only first item that is getting repeated, correct? Using something stricter may resolve your problem, something like testing for boolean: if(is_bool(array_search($result['company_id'],$arr))) { } Or, drop the whole array search and use an associative array. if( !is_set( $arr[$result['company_id']] ) { ... $arr[$result['company_id']] = $result['company']; } Using an associative array may be quicker than array_search since you are referencing the index of the array instead of searching the entire array for values. The difference may not be noticeable with only a few elements. On Nov 11, 2004, at 11:42 AM, Joseph Crawford wrote: > Guys, > > I have an sql query that uses one table to join another, the tables > are ci2_bizopps and ci2_companies, each company could have many > entries in the bizopps table and what i need to do is get each company > name only once. However since we are searching the bizopps table it > returns a result for each bizopp found, this makes for duplicate > company names added to the array. The following code works if i > remove the ORDER BY statement in the SQL query, however for some > reason with it in there it breaks the code. > > $result = $db->query(" > SELECT > b.id as bizopp_id, b.contract_name, > c.id as company_id, c.name as company > FROM ci2_bizopps b > INNER JOIN ci2_companies c ON b.company_id=c.id > WHERE b.contract_type=".$type." > ORDER BY c.name ASC" > ); > $results = $db->fetchAll($result); > > $data = " align='center'>\n"; > $arr = array(); > foreach($results as $result) { > if(!array_search($result['company_id'], $arr)) { > $data .= "\n"; > $data .= "\n"; > $data .= "\n"; > $arr[] = $result['company_id']; > } > } > $data .= "
href='company.php? > id=".$result['company_id']."'>".$result['company']."
"; > return $data; > > as you can see all i did was for each record found, store the company > id into another array, and also use array_search to search the array > to see if that company_id has already been used. If it has been used, > do nothing otherwise display the data for that company.. I have > printed out the value of company_id and $arr for each item and with > the order by statement, it says the company id is 2 but 2 is also in > the arr 3 times, so i am not sure why array_search is not finding it > in the array and just skipping it. I guess one way of accomplishing > this is to not use the ORDER BY statement but create yet another > array, add the companies to that which will be displayed and then > sorting the array and then displaying but i think the order by would > be much easier to use if it can be done. > > Here are the results shown with the ORDER BY in place > IPRO > PRO NJ Test Data > Romy's Widgets > The British Medicine Group > IPRO > IPRO > > And here are the results without the ORDER BY in place > The British Medicine Group > Romy's Widgets > The British Medicine Group > IPRO > PRO NJ Test Data > > This is really starting to get to me after working on this for a while > the other day to finally get it working and today just to break it > with an order by statement ;D > > Anyone that can help i would greatly appreciate it. > > -- > Joseph Crawford Jr. > Codebowl Solutions > codebowl at gmail.com > > For a GMail account > contact me OFF-LIST > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > -- Brent Baisley Systems Architect Landover Associates, Inc. Search & Advisory Services for Advanced Technology Environments p: 212.759.6400/800.759.0577 From andrew at digitalpulp.com Thu Nov 11 13:20:27 2004 From: andrew at digitalpulp.com (Andrew Yochum) Date: Thu, 11 Nov 2004 13:20:27 -0500 Subject: [nycphp-talk] Enterprise-level Functionality in PHP In-Reply-To: <41938CD1.7000401@r2communications.com> References: <41938CD1.7000401@r2communications.com> Message-ID: <20041111182016.GQ9696@thighmaster.digitalpulp.com> On Thu, Nov 11, 2004 at 11:01:21AM -0500, Randal Rust wrote: > For the past two years, I have been in charge of the development of a > prototype for an enterprise-level application. The prototype is in > PHP/MySQL/ADODB and the *real* application is J2EE. > > So what I am looking to do is add some of the enterprise-level functions > into the system, such as: > > - workflow > - live chat > - imaging and document management > - integration with Adobe Forms > > I've found some live chat options, but don't seem to be having much luck > in the other areas. Any suggestions? I can't say I've done anything with it, but TikiWiki's GalaxiaWorkflow might be worth checking out. I've used Openflow (which is what Galaxia was based on), and if its anything like it you should have a great workflow framework with a lot of flexibility. See: http://tikiwiki.org/tiki-index.php?page=GalaxiaWorkflow HTH, Andrew From andrew at digitalpulp.com Thu Nov 11 16:13:09 2004 From: andrew at digitalpulp.com (Andrew Yochum) Date: Thu, 11 Nov 2004 16:13:09 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: Message-ID: <20041111211305.GV9696@thighmaster.digitalpulp.com> My votes go for: 5. array_walk/map - Mmmmm... code reuse. 4. get/set_include_path - I like manipulating my include path at runtime. 3. mktime - for its date arithmetic features. 2. ob_start/get_contents - for caching, code reuse/re-purposing, etc. 1. debug_backtrace - where have I been? On Wed, Nov 10, 2004 at 11:21:06PM -0500, csnyder wrote: > And if I had to pick a control structure it would be foreach. I mean, > does anyone use list() anymore? Yes. I frequently use it like this: List($A['Value1'], $A['Value2'], /*Junk*/ ) = Explode($Some_Delimeter, $Some_String); Andrew From adam at trachtenberg.com Thu Nov 11 16:25:50 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Thu, 11 Nov 2004 16:25:50 -0500 (EST) Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <20041111211305.GV9696@thighmaster.digitalpulp.com> References: <20041111211305.GV9696@thighmaster.digitalpulp.com> Message-ID: On Thu, 11 Nov 2004, Andrew Yochum wrote: > On Wed, Nov 10, 2004 at 11:21:06PM -0500, csnyder wrote: > > And if I had to pick a control structure it would be foreach. I mean, > > does anyone use list() anymore? > > Yes. I frequently use it like this: > List($A['Value1'], $A['Value2'], /*Junk*/ ) = Explode($Some_Delimeter, $Some_String); I used it today when I had to use SimpleXML / XPath to extract an attribute from a specific part of an XML file: list($version) = simplexml_load_string($xml)->xpath('/foo[@bar = "baz"]/@version'); The xpath() method returns an array of items, but I know I'm only interested in the first (and only) one. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From andrew at digitalpulp.com Thu Nov 11 17:38:41 2004 From: andrew at digitalpulp.com (Andrew Yochum) Date: Thu, 11 Nov 2004 17:38:41 -0500 Subject: Workflow & MVC in PHP (was Re: [nycphp-talk] Enterprise-level Functionality in PHP) In-Reply-To: <41938CD1.7000401@r2communications.com> References: <41938CD1.7000401@r2communications.com> Message-ID: <20041111223830.GY9696@thighmaster.digitalpulp.com> On Thu, Nov 11, 2004 at 11:01:21AM -0500, Randal Rust wrote: > For the past two years, I have been in charge of the development of a > prototype for an enterprise-level application. The prototype is in > PHP/MySQL/ADODB and the *real* application is J2EE. > > So what I am looking to do is add some of the enterprise-level functions > into the system, such as: > > - workflow > - live chat > - imaging and document management > - integration with Adobe Forms > > I've found some live chat options, but don't seem to be having much luck > in the other areas. Any suggestions? I just now happened to stumble on this doc on a workflow engine in PHP: http://www.tonymarston.net/php-mysql/workflow.html ... by way of Harry Feucks post: http://www.sitepoint.com/blog-post-view.php?id=206854 Also, of more general interest to NYPHPers is Tony Marston's doc "A Development Infrastructure for PHP", an excellent piece on MVC in PHP: http://www.tonymarston.net/php-mysql/infrastructure.html Enjoy, Andrew From chendry at gmail.com Thu Nov 11 23:13:29 2004 From: chendry at gmail.com (Christopher Hendry) Date: Thu, 11 Nov 2004 23:13:29 -0500 Subject: [nycphp-talk] newbie confusion In-Reply-To: References: <319FD9EAB7A43E43895ACA5AA1F81E05F886F1@xmail.nybg.org> <769e4ce04111020305d269833@mail.gmail.com> <7032B770-33E7-11D9-8193-0003930D07F2@email.smith.edu> <330532b604111106215d45a378@mail.gmail.com> Message-ID: <769e4ce041111201372c6dd31@mail.gmail.com> > To make a by-value copy of an object, use the clone operator: > > $copy = clone $original; > > To control the cloning behavior of a class, define a __clone() method. > > More details available in "Upgrading to PHP 5." :) > Good stuff Adam - didn't know about clone. Guess it's time to buy the book. ;) C -- "When you do things right, people won't be sure you've done anything at all." From prusak at gmail.com Thu Nov 11 23:26:06 2004 From: prusak at gmail.com (Ophir Prusak) Date: Thu, 11 Nov 2004 23:26:06 -0500 Subject: [nycphp-talk] Enterprise-level Functionality in PHP In-Reply-To: <41938CD1.7000401@r2communications.com> References: <41938CD1.7000401@r2communications.com> Message-ID: I came across this a couple of weeks ago: http://www.tonymarston.net/php-mysql/workflow.html To be honest, I haven't even read it all, but Tony know's his stuff. On Thu, 11 Nov 2004 11:01:21 -0500, Randal Rust wrote: > For the past two years, I have been in charge of the development of a > prototype for an enterprise-level application. The prototype is in > PHP/MySQL/ADODB and the *real* application is J2EE. > > So what I am looking to do is add some of the enterprise-level functions > into the system, such as: > > - workflow > - live chat > - imaging and document management > - integration with Adobe Forms > > I've found some live chat options, but don't seem to be having much luck > in the other areas. Any suggestions? > > -- > Randal Rust > > R.Squared Communications > http://www.r2communications.com > Digital Design for Bricks-and-Mortar Businesses > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From jonbaer at jonbaer.net Thu Nov 11 23:43:46 2004 From: jonbaer at jonbaer.net (Jon Baer) Date: Thu, 11 Nov 2004 23:43:46 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? xpath In-Reply-To: Message-ID: <00c501c4c872$32a2e620$6800a8c0@SPIKETV1515> Damn that's handy .. Normally takes a few lines and bloated libraries to do the same thing in other unnamed languages :-) Thanks. - Jon >>> list($version) = simplexml_load_string($xml)->xpath('/foo[@bar = "baz"]/@version'); The xpath() method returns an array of items, but I know I'm only interested in the first (and only) one. <<< From adam at trachtenberg.com Fri Nov 12 01:56:11 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Fri, 12 Nov 2004 01:56:11 -0500 (EST) Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? xpath In-Reply-To: <00c501c4c872$32a2e620$6800a8c0@SPIKETV1515> References: <00c501c4c872$32a2e620$6800a8c0@SPIKETV1515> Message-ID: On Thu, 11 Nov 2004, Jon Baer wrote: > Normally takes a few lines and bloated libraries to do the same thing in > other unnamed languages :-) XPath Rocks! It's the only part of XML I like. :) -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From keithjr at gmail.com Fri Nov 12 07:48:30 2004 From: keithjr at gmail.com (Keith Richardson) Date: Fri, 12 Nov 2004 07:48:30 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> References: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> Message-ID: <4e1a9bc04111204483aa718a1@mail.gmail.com> first is mysql_fetch_assoc, very handy next is a combonation that I use a lot - getdate(strtotime($sql_date_variable)); - to turn sql datetime variables into the date array print_r of course in_array empty (heh) and if empty doesnt count, html_special_chars On Wed, 10 Nov 2004 21:52:49 -0500, Jon Baer wrote: > Hi, > > Kinda lame but, I tried looking for something on web which made light of > what packages/libraries/functions most people were using on a normal basis > so .. thought Id start a quick little topic, more like a survey, maybe > someone would like to compile it and post? Here goes, pretty self > explainatory: > > What are the top 5 most *useful* PHP functions to you? (in no order) > > + preg_match_all > + preg_replace > + array_unique > + array_combine > + (tie) file_get_contents and simplexml_load_string > > - Jon > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- Keith Richardson keith at keithjr.net From Cbielanski at inta.org Fri Nov 12 09:25:54 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Fri, 12 Nov 2004 09:25:54 -0500 Subject: [nycphp-talk] OT: HexEditor recommendation Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA50@intamail1.com> Hey gang, it's "plug your favorite software" time again... DBDesigner was a *huge* hit in our shop :) So what are you all using for hexeditors? I wasn't really keen on UltraEdit's nuances although I admit they may be worth it given the power of the app. Let's hear it, what else is out there? Note that freeware > nagware > buyware in this instance because it's late in the year and the budget is ostensibly closed. Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence From dmintz at davidmintz.org Fri Nov 12 09:33:40 2004 From: dmintz at davidmintz.org (David Mintz) Date: Fri, 12 Nov 2004 09:33:40 -0500 (EST) Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: <20041111211305.GV9696@thighmaster.digitalpulp.com> Message-ID: On Thu, 11 Nov 2004, Adam Maccabee Trachtenberg wrote: > > I used it today when I had to use SimpleXML / XPath to extract an > attribute from a specific part of an XML file: > > list($version) = simplexml_load_string($xml)->xpath('/foo[@bar = "baz"]/@version'); > > The xpath() method returns an array of items, but I know I'm only > interested in the first (and only) one. Indeed, is there any other one-liner in PHP to snag just the 1st element of something that returns an array? --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From dmintz at davidmintz.org Fri Nov 12 09:38:44 2004 From: dmintz at davidmintz.org (David Mintz) Date: Fri, 12 Nov 2004 09:38:44 -0500 (EST) Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <4e1a9bc04111204483aa718a1@mail.gmail.com> References: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> <4e1a9bc04111204483aa718a1@mail.gmail.com> Message-ID: I was gonna make a nihilistic wisecrack and vote for die and exit, but since they're (1) language constructs and (2) synonyms for one another... what's the point? --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From scott at crisscott.com Fri Nov 12 09:39:24 2004 From: scott at crisscott.com (Scott Mattocks) Date: Fri, 12 Nov 2004 09:39:24 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: <20041111211305.GV9696@thighmaster.digitalpulp.com> Message-ID: <4194CB1C.2070601@crisscott.com> David Mintz wrote: > Indeed, is there any other one-liner in PHP to snag just the 1st element > of something that returns an array? reset() http://us2.php.net/manual/en/function.reset.php $firstElement = reset(funcThatReturnsArray()); or array_shift() if you want to remove it from the array too http://us2.php.net/manual/en/function.array-shift.php -- Scott Mattocks scott at crisscott.com http://www.crisscott.com http://pear.php.net/user/scottmattocks From chsnyder at gmail.com Fri Nov 12 11:20:02 2004 From: chsnyder at gmail.com (csnyder) Date: Fri, 12 Nov 2004 11:20:02 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <4e1a9bc04111204483aa718a1@mail.gmail.com> References: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> <4e1a9bc04111204483aa718a1@mail.gmail.com> Message-ID: On Fri, 12 Nov 2004 07:48:30 -0500, Keith Richardson wrote: > getdate(strtotime($sql_date_variable)); - to turn sql datetime strtotime() is a favorite here, too. I have an ongoing debate with my coworkers about whether it's better to create select menus for month/day/year/hour/minute/ampm on a form, or to just provide a text box and strtotime() the result. Being lazy, I incline to the latter. But the conversation goes: "Should I use January 1, 2004? Or 1/1/2004? Or Jan. 1, 2004?" "Yes." "That's too confusing!" From lists at natserv.com Fri Nov 12 13:17:24 2004 From: lists at natserv.com (Francisco Reyes) Date: Fri, 12 Nov 2004 13:17:24 -0500 (EST) Subject: [nycphp-talk] OT: Non-US AMP Hosting? In-Reply-To: <418BFD2B.8060904@bitblit.net> References: <418A582D.1070802@bitblit.net> <418A58C7.4070104@dtev.com> <418BFD2B.8060904@bitblit.net> Message-ID: <20041112131619.I77336@zoraida.natserv.net> On Fri, 5 Nov 2004, Ajai Khattri wrote: > I was looking for recommendations... Check http://hub.org They have servers in Panama and now in the US too. The people that run hub are also the same people that run PostgreSQL Inc. So, if you need postgreSQL DB that would be a good host. They also support MysQL if you use that instead. From ez at ericzander.com Fri Nov 12 15:35:25 2004 From: ez at ericzander.com (EZ) Date: Fri, 12 Nov 2004 15:35:25 -0500 Subject: [nycphp-talk] Re: DBDesigner In-Reply-To: <20041112142207.47BEAA879D@virtu.nyphp.org> References: <20041112142207.47BEAA879D@virtu.nyphp.org> Message-ID: <41951E8D.4070504@ericzander.com> I know the thread has died down/out but I finally just got around to installing DBDesigner and have to say, IT ROCKS! In less than 15 minutes I downloaded it, installed it and using the reverse engineering tool had my database mapped out! Simply brilliant! :-) EZ From mitch.pirtle at gmail.com Fri Nov 12 15:57:18 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Fri, 12 Nov 2004 15:57:18 -0500 Subject: [nycphp-talk] Re: DBDesigner In-Reply-To: <41951E8D.4070504@ericzander.com> References: <20041112142207.47BEAA879D@virtu.nyphp.org> <41951E8D.4070504@ericzander.com> Message-ID: <330532b604111212577b01b3be@mail.gmail.com> On Fri, 12 Nov 2004 15:35:25 -0500, EZ wrote: > > Simply brilliant! :-) Do you do Guinness ads? (rimshot) Seriously, I tried DBDesigner but the reverse engineering mangled a PostgreSQL database of mine and I ended up labeling it a 'MySQL-mostly' kind of tool. Anybody else use it on non-MySQL databases with success? -- Mitch From preinheimer at gmail.com Fri Nov 12 17:25:05 2004 From: preinheimer at gmail.com (Paul Reinheimer) Date: Fri, 12 Nov 2004 17:25:05 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: References: <000801c4c799$88eb9240$6700a8c0@SPIKETV1515> <4e1a9bc04111204483aa718a1@mail.gmail.com> Message-ID: <6ec19ec70411121425600b2373@mail.gmail.com> mysql_fetch_assoc and my in-house favourite wrapper for it. http://www.preinheimer.com/index.php?/archives/72_My_Favourite_PHP_MySQL_function.html and print_r, I actually only found out it existed like a month ago, but it's pretty awesome. paul On Fri, 12 Nov 2004 11:20:02 -0500, csnyder wrote: > On Fri, 12 Nov 2004 07:48:30 -0500, Keith Richardson wrote: > > getdate(strtotime($sql_date_variable)); - to turn sql datetime > > strtotime() is a favorite here, too. > > I have an ongoing debate with my coworkers about whether it's better > to create select menus for month/day/year/hour/minute/ampm on a form, > or to just provide a text box and strtotime() the result. > > Being lazy, I incline to the latter. But the conversation goes: > "Should I use January 1, 2004? Or 1/1/2004? Or Jan. 1, 2004?" > "Yes." > "That's too confusing!" > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- Paul Reinheimer Zend Certified Engineer From lists at natserv.com Fri Nov 12 22:02:40 2004 From: lists at natserv.com (Francisco Reyes) Date: Fri, 12 Nov 2004 22:02:40 -0500 (EST) Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <418CBEBF.1050407@mlug.missouri.edu> References: <41EE526EC2D3C74286415780D3BA9F870580E382@ehost011-1.exch011.intermedia.net> <15110-02089@sneakemail.com> <418CBEBF.1050407@mlug.missouri.edu> Message-ID: <20041112215829.N78780@zoraida.natserv.net> On Sat, 6 Nov 2004, Michael wrote: > So the real question is why would anyone want to use a virtual dedicated > server when you can get a real dedicated server for about the same price? For starters, it's usually NOT the same price. Virtual servers are usually cheaper. One reason I can think of to go with a VM (virtual machine) is support. I want the control of having root access, yet want someone else deal with the problems. In my view a good choice for someone with enough experience to know many admin functions, but not want to jump heads on into learning all the nuances of managing a box. ie a developer with some admin experience. > main benefit I can see is that in theory you can pay for only the amount of > computing power you need and upgrade easily. I also think that VMs work best for smaller sites. Anyone with a busy site probably is better off with a dedicated server. Moreover, if you don't choose your web hosting company properly they may put too many VMs in a single box which would degrade performance. From lists at natserv.com Fri Nov 12 22:10:55 2004 From: lists at natserv.com (Francisco Reyes) Date: Fri, 12 Nov 2004 22:10:55 -0500 (EST) Subject: [nycphp-talk] [OT] Virtual Dedicated Servers In-Reply-To: <4b18871104110323064b45a2d8@mail.gmail.com> References: <4b18871104110323064b45a2d8@mail.gmail.com> Message-ID: <20041112220445.A78780@zoraida.natserv.net> On Thu, 4 Nov 2004, Jeff Loiselle wrote: > a. Has anyone tried VDS hosting? A virtual machine? > b. what kind of experience did you have? Very good. > c. what are the major factors to look for in a good VDS host? That they don't host too many VMs in the box. That they have good response time and that you can move up to better plan easily. I use http://hub.org and am so far very happy. They are the same people that run PostgreSQL Inc. so if PostgreSQL is your DB, they are a good host. They also host Mysql too. In general I think VMs work great if you have many low traffic, low space clients. For busy sites with big disk demands a collocated box probably your best choice. From mogmios at mlug.missouri.edu Fri Nov 12 22:21:18 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Fri, 12 Nov 2004 19:21:18 -0800 Subject: [nycphp-talk] [OT] Make for System Admins Message-ID: <41957DAE.2040005@mlug.missouri.edu> Anyone interested in reading and bashing an article I'm writing? I'm not happy with the way my first draft came out and I'm looking for some suggestions as to where it gets confussing. The topic is using make and makefiles for system admin tasks. -- Michael http://kavlon.org From jayeshsh at ceruleansky.com Fri Nov 12 22:28:59 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Fri, 12 Nov 2004 22:28:59 -0500 (EST) Subject: [nycphp-talk] SQLite book by Chris Newman Message-ID: <42180.69.86.84.233.1100316539.spork@webmail.ceruleansky.com> Hello all, I have been wondering when the SQLite book by Chris Newman is to be published. Amazon lists its publish date as October 11, 2004: http://www.amazon.com/exec/obidos/tg/detail/-/067232685X/qid=1100316119/sr=8-1/ref=sr_8_xs_ap_i1_xgl14/102-8825405-9563305?v=glance&s=books&n=507846 Bookpool lists its publish date as November, 2004: http://www.bookpool.com/.x/7mtopise8m/sm/067232685X Does anyone with insider information know when in fact it will be out? I am really looking forward to this book. Thanks, - Jay PS: Another really cool new book is Beginning MySQL Database Design and Optimization (From Novice to Professional) by Jon Stephens and Chad Russell. This book has amazing, in depth information on the ins and outs of database design for MySQL. http://www.bookpool.com/.x/4mww7jo050/sm/1590593324 From faber at linuxnj.com Fri Nov 12 22:48:15 2004 From: faber at linuxnj.com (Faber Fedor) Date: Fri, 12 Nov 2004 22:48:15 -0500 Subject: [nycphp-talk] Re: Make for System Admins In-Reply-To: <41957DAE.2040005@mlug.missouri.edu> References: <41957DAE.2040005@mlug.missouri.edu> Message-ID: <20041113034815.GA30192@uranus.faber.nom> On 12/11/04 19:21 -0800, Michael wrote: > Anyone interested in reading and bashing an article I'm writing? I'm not > happy with the way my first draft came out and I'm looking for some > suggestions as to where it gets confussing. The topic is using make and > makefiles for system admin tasks. Pass it my way. I'm not very good at make, but I think it has a lot of potential in administration and documentation. -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From jlacey at att.net Sat Nov 13 11:12:53 2004 From: jlacey at att.net (John Lacey) Date: Sat, 13 Nov 2004 09:12:53 -0700 Subject: [nycphp-talk] SQLite book by Chris Newman In-Reply-To: <42180.69.86.84.233.1100316539.spork@webmail.ceruleansky.com> References: <42180.69.86.84.233.1100316539.spork@webmail.ceruleansky.com> Message-ID: <41963285.3050000@att.net> Jayesh Sheth wrote: > Hello all, > > I have been wondering when the SQLite book by Chris Newman is to be > published. > > Amazon lists its publish date as October 11, 2004: > http://www.amazon.com/exec/obidos/tg/detail/-/067232685X/qid=1100316119/sr=8-1/ref=sr_8_xs_ap_i1_xgl14/102-8825405-9563305?v=glance&s=books&n=507846 > > Bookpool lists its publish date as November, 2004: > http://www.bookpool.com/.x/7mtopise8m/sm/067232685X > > Does anyone with insider information know when in fact it will be out? > > I am really looking forward to this book. > I ordered SQLite from bookpool several weeks ago along with George's Advanced PHP Programming and I'm thinking they'll ship both next week because Sams says it was released Nov. 9th. http://www.samspublishing.com/ hth, John From fields at surgam.net Sat Nov 13 12:34:38 2004 From: fields at surgam.net (Adam Fields) Date: Sat, 13 Nov 2004 12:34:38 -0500 Subject: [nycphp-talk] PEAR mail trouble Message-ID: <20041113173438.GM26534@lola.aquick.org> I'm trying to use the PEAR mail module to allow users to upload a file and send it as an attachment to other users. It works fine if I specify just one recipient, but if there are multiple recipients, the mail only goes to the first. I've tried passing the recipient list as a comma-separated string and directly as an array (from the multi-select box input), with the same effect. Has anyone successfully used this to send mail to multiple recipients? -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From fields at surgam.net Sat Nov 13 12:36:29 2004 From: fields at surgam.net (Adam Fields) Date: Sat, 13 Nov 2004 12:36:29 -0500 Subject: [nycphp-talk] PEAR mail trouble In-Reply-To: <20041113173438.GM26534@lola.aquick.org> References: <20041113173438.GM26534@lola.aquick.org> Message-ID: <20041113173629.GN26534@lola.aquick.org> On Sat, Nov 13, 2004 at 12:34:38PM -0500, Adam Fields wrote: > I'm trying to use the PEAR mail module to allow users to upload a file > and send it as an attachment to other users. > > It works fine if I specify just one recipient, but if there are > multiple recipients, the mail only goes to the first. I should have specified here - no error is returned, the mail just doesn't show up at the second address. If I use just the second address, it does go through. > I've tried passing the recipient list as a comma-separated string and > directly as an array (from the multi-select box input), with the same > effect. > > Has anyone successfully used this to send mail to multiple recipients? -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From jayeshsh at ceruleansky.com Sat Nov 13 13:33:12 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Sat, 13 Nov 2004 13:33:12 -0500 Subject: [nycphp-talk] SQLite book by Chris Newman Message-ID: <41965368.5040506@ceruleansky.com> Hi John, thanks for your note. I think I will order it soon from Amazon or from Bookpool. (I think that Adam Trachtenberg's new book has a section on creating an address book using SQLite and PHP5, or something like that.) I could not find the book using Sams's search feature, but I did serendipitously come across the specific SQLite page at Sams, which is here, for others who may be interested: http://www.samspublishing.com/title/067232685X Best regards, - Jay PS: I also want to buy George's advanced PHP programming book; it looks pretty cool. There are also two new (co-authored) books by the founders of Zend. There's also a really cool looking new book from Apress on E-Commerce and PHP5. That one is listed as not yet published. I wonder when it will be? http://apress.com/book/bookDisplay.html?bID=356 From hans at nyphp.com Sat Nov 13 13:46:07 2004 From: hans at nyphp.com (Hans Zaunere) Date: Sat, 13 Nov 2004 10:46:07 -0800 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? Message-ID: <41EE526EC2D3C74286415780D3BA9F8705B30BFD@ehost011-1.exch011.intermedia.net> > What are the top 5 most *useful* PHP functions to you? (in no order) > > + preg_match_all > + preg_replace > + array_unique > + array_combine > + (tie) file_get_contents and simplexml_load_string Well, I'd have to go with mysql_connect() as being the number one function I've used in nearly every PHP application I've ever written :) But seriously, it's a tough call to name specific functions, especially since the most common are language constructs (and technically not functions). So, I'll say the most useful function groups: -- date/time (http://www.php.net/manual/en/ref.datetime.php) -- strings (http://www.php.net/manual/en/ref.strings.php) -- arrays (http://www.php.net/manual/en/ref.array.php) -- error handling/logging (http://www.php.net/manual/en/ref.errorfunc.php) -- php options and information (http://www.php.net/manual/en/ref.info.php) -- MySQL (http://www.php.net/manual/en/ref.mysql.php) -- variables (http://www.php.net/manual/en/ref.var.php) --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From fields at surgam.net Sat Nov 13 14:28:30 2004 From: fields at surgam.net (Adam Fields) Date: Sat, 13 Nov 2004 14:28:30 -0500 Subject: [nycphp-talk] PEAR mail trouble In-Reply-To: <20041113173629.GN26534@lola.aquick.org> References: <20041113173438.GM26534@lola.aquick.org> <20041113173629.GN26534@lola.aquick.org> Message-ID: <20041113192830.GP26534@lola.aquick.org> On Sat, Nov 13, 2004 at 12:36:29PM -0500, Adam Fields wrote: > > Has anyone successfully used this to send mail to multiple recipients? Nevermind. It works. Beware overly general procmail rules. -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From 1j0lkq002 at sneakemail.com Sat Nov 13 16:08:28 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Sat, 13 Nov 2004 16:08:28 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705B30BFD@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705B30BFD@ehost011-1.exch011.intermedia.net> Message-ID: <3051-75346@sneakemail.com> Hans Zaunere hans-at-nyphp.com |nyphp dev/internal group use| wrote: >>What are the top 5 most *useful* PHP functions to you? (in no order) >> >>+ preg_match_all >>+ preg_replace >>+ array_unique >>+ array_combine >>+ (tie) file_get_contents and simplexml_load_string >> >> > >Well, I'd have to go with mysql_connect() as being the number one >function I've used in nearly every PHP application I've ever written :) > >But seriously, it's a tough call to name specific functions, especially >since the most common are language constructs (and technically not >functions). So, I'll say the most useful function groups: > >-- date/time (http://www.php.net/manual/en/ref.datetime.php) >-- strings (http://www.php.net/manual/en/ref.strings.php) >-- arrays (http://www.php.net/manual/en/ref.array.php) >-- error handling/logging >(http://www.php.net/manual/en/ref.errorfunc.php) >-- php options and information >(http://www.php.net/manual/en/ref.info.php) >-- MySQL (http://www.php.net/manual/en/ref.mysql.php) >-- variables (http://www.php.net/manual/en/ref.var.php) > > >--- >Hans Zaunere >President, Founder >New York PHP >http://www.nyphp.org > > Hmmm.... I don't think it should be so easy to avoid answering the question ;-) Perhaps we can get Hans to commit if we clarify a bit. Given that many core functions are like language constructs, we can take them for granted (they exist in most programming languages). But since PHP is such a cool language with so many great utility functions, of those remaining utlity functions, whcih are the favorites?? So by this reasoning mysql_connect doesn't count (unless there was some special set of params or technique of use that made it do something especially cool). -=john andrews From codebowl at gmail.com Sat Nov 13 21:19:56 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sat, 13 Nov 2004 21:19:56 -0500 Subject: [nycphp-talk] Email not working Message-ID: <8d9a428004111318191e35eb58@mail.gmail.com> guys i have a mail function call however it is sending the HTML as text and not an HTML email, can anyone here help me out? Here are the headers from the email source To: codebowl at gmail.com Subject: Demonoid Account Confirmation MIME-Version: 1.0 Content-type: text/html; charset=iso-8859-1 From: Demonoid X-Mailer: PHP/4.3.9\r\n Message-Id: <20041114021655.2D9285282D8 at vt-fairhaven1a-82.bur.adelphia.net> Date: Sat, 13 Nov 2004 21:16:55 -0500 (EST) and here is the code function sendRegistrationEmail( $configs, $tpl, $email, $confirm ) { $tpl->assign('code', $confirm); $tpl->assign('url', $configs->getSiteURL()."/confirm.php?code=".$confirm); $tpl->assign('confirm_page', $configs->getSiteURL()."/confirm.php"); $sitename = $configs->getSiteName(); $tpl->assign('sitename', $sitename); $body = $tpl->fetch('email/confirm_email.tpl'); $headers = "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; $headers .= "From: ".$sitename." <".$configs->getSiteEmail().">\r\n"; $headers .= "X-Mailer: PHP/" . phpversion().'\r\n'; mail($email, $sitename." Account Confirmation", $body, $headers) or trigger_error('email not sent :(', E_USER_ERROR); } i am not sure what is going on but it's not working :( -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From chsnyder at gmail.com Sat Nov 13 21:33:02 2004 From: chsnyder at gmail.com (csnyder) Date: Sat, 13 Nov 2004 21:33:02 -0500 Subject: [nycphp-talk] Top 5 Most Useful PHP Functions? In-Reply-To: <3051-75346@sneakemail.com> References: <41EE526EC2D3C74286415780D3BA9F8705B30BFD@ehost011-1.exch011.intermedia.net> <3051-75346@sneakemail.com> Message-ID: On Sat, 13 Nov 2004 16:08:28 -0500, inforequest <1j0lkq002 at sneakemail.com> wrote: > Hmmm.... I don't think it should be so easy to avoid answering the > question ;-) I know, right? I mean, I could see naming the *entire* date/time function group, since there's now the new-fangled date_sunrise() and date_sunset() functions, in addition to old favorites like idate() and gmmktime(). But MySQL function group? I would have thought the real action was in mysqli ... maybe someone needs to update their databases... :-D From dorgan at optonline.net Sun Nov 14 02:22:11 2004 From: dorgan at optonline.net (Donald J. Organ IV) Date: Sun, 14 Nov 2004 02:22:11 -0500 Subject: [nycphp-talk] Email not working References: <8d9a428004111318191e35eb58@mail.gmail.com> Message-ID: <003601c4ca1a$a861aaf0$fe01010a@dj> look up the headers you have yo set http://www.php.net/mail ----- Original Message ----- From: "Joseph Crawford" To: "NYPHP Talk" Sent: Saturday, November 13, 2004 9:19 PM Subject: [nycphp-talk] Email not working > guys i have a mail function call however it is sending the HTML as > text and not an HTML email, can anyone here help me out? Here are the > headers from the email source > > To: codebowl at gmail.com > Subject: Demonoid Account Confirmation > MIME-Version: 1.0 > > Content-type: text/html; charset=iso-8859-1 > > From: Demonoid > X-Mailer: PHP/4.3.9\r\n > Message-Id: > <20041114021655.2D9285282D8 at vt-fairhaven1a-82.bur.adelphia.net> > Date: Sat, 13 Nov 2004 21:16:55 -0500 (EST) > > > > > and here is the code > > function sendRegistrationEmail( $configs, $tpl, $email, $confirm ) { > $tpl->assign('code', $confirm); > $tpl->assign('url', $configs->getSiteURL()."/confirm.php?code=".$confirm); > $tpl->assign('confirm_page', $configs->getSiteURL()."/confirm.php"); > $sitename = $configs->getSiteName(); > $tpl->assign('sitename', $sitename); > > $body = $tpl->fetch('email/confirm_email.tpl'); > > $headers = "MIME-Version: 1.0\r\n"; > $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; > $headers .= "From: ".$sitename." <".$configs->getSiteEmail().">\r\n"; > $headers .= "X-Mailer: PHP/" . phpversion().'\r\n'; > > mail($email, $sitename." Account Confirmation", $body, $headers) or > trigger_error('email not sent :(', E_USER_ERROR); > } > > i am not sure what is going on but it's not working :( > > -- > Joseph Crawford Jr. > Codebowl Solutions > codebowl at gmail.com > > For a GMail account > contact me OFF-LIST > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From codebowl at gmail.com Sun Nov 14 09:27:41 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 09:27:41 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <003601c4ca1a$a861aaf0$fe01010a@dj> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> Message-ID: <8d9a428004111406277a25dd46@mail.gmail.com> i have done that and all i could find were these and they are set $headers = "MIME-Version: 1.0\r\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; so i am not sure why it is not working -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From dcech at phpwerx.net Sun Nov 14 09:38:15 2004 From: dcech at phpwerx.net (Dan Cech) Date: Sun, 14 Nov 2004 09:38:15 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <8d9a428004111406277a25dd46@mail.gmail.com> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> <8d9a428004111406277a25dd46@mail.gmail.com> Message-ID: <41976DD7.2080600@phpwerx.net> Joseph Crawford wrote: > i have done that and all i could find were these and they are set > > $headers = "MIME-Version: 1.0\r\n"; > $headers .= "Content-type: text/html; charset=iso-8859-1\r\n"; > > so i am not sure why it is not working Just use phpmailer (http://phpmailer.sf.net) Dan From codebowl at gmail.com Sun Nov 14 11:16:02 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 11:16:02 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <41976DD7.2080600@phpwerx.net> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> <8d9a428004111406277a25dd46@mail.gmail.com> <41976DD7.2080600@phpwerx.net> Message-ID: <8d9a428004111408163b88e225@mail.gmail.com> this is not what i am looking for because i send very few emails and i dont need to add all that extra code... i just want to get this HTML email sending to work, i cant seem to get it to work with my domain email, but when i send to my gmail account it sends as all plain text for some reason :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From codebowl at gmail.com Sun Nov 14 11:21:08 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 11:21:08 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <8d9a428004111408163b88e225@mail.gmail.com> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> <8d9a428004111406277a25dd46@mail.gmail.com> <41976DD7.2080600@phpwerx.net> <8d9a428004111408163b88e225@mail.gmail.com> Message-ID: <8d9a4280041114082132f2065f@mail.gmail.com> here are the complete headers X-Gmail-Received: 5a9134da937ae26298872b9230cbf548ec49975d Delivered-To: codebowl at gmail.com Received: by 10.38.65.73 with SMTP id n73cs9567rna; Sun, 14 Nov 2004 08:19:21 -0800 (PST) Received: by 10.38.171.10 with SMTP id t10mr456024rne; Sun, 14 Nov 2004 08:19:20 -0800 (PST) Return-Path: Received: from vt-fairhaven1a-82.bur.adelphia.net ([68.64.74.82]) by mx.gmail.com with ESMTP id 70si1333970rnc; Sun, 14 Nov 2004 08:19:20 -0800 (PST) Received-SPF: neutral (gmail.com: 68.64.74.82 is neither permitted nor denied by domain of nobody at vt-fairhaven1a-82.bur.adelphia.net) Received: by vt-fairhaven1a-82.bur.adelphia.net (Postfix, from userid 65534) id 34F745282E6; Sun, 14 Nov 2004 11:17:51 -0500 (EST) To: codebowl at gmail.com Subject: Demonoid Account Confirmation MIME-Version: 1.0 Content-type: text/html; charset=iso-8859-1 From: Demonoid X-Mailer: PHP/4.3.9\r\n Message-Id: <20041114161751.34F745282E6 at vt-fairhaven1a-82.bur.adelphia.net> Date: Sun, 14 Nov 2004 11:17:51 -0500 (EST) // BEGINNING OF BODY OF MESSAGE -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From codebowl at gmail.com Sun Nov 14 11:34:56 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 11:34:56 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <8d9a4280041114082132f2065f@mail.gmail.com> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> <8d9a428004111406277a25dd46@mail.gmail.com> <41976DD7.2080600@phpwerx.net> <8d9a428004111408163b88e225@mail.gmail.com> <8d9a4280041114082132f2065f@mail.gmail.com> Message-ID: <8d9a428004111408347f2a6d1@mail.gmail.com> i have also posted my code on hashphp.org for you guys to chew on, i am using output buffering and i am not sure if that could be causing this. I have included all the code from register.php to the site.class.php for the method's called. http://hashphp.org/pastebin.php?pid=1318 the $site->end("flush"); and $site->end("clean") just call a method that does ob_end_flush and ob_end_clean $site->start() just calls ob_start() If anyone can help i would really appreciate it, if you need to see any other code just let me know and i can post it for you to see. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From jwilhelm at summit7solutions.com Sun Nov 14 11:49:12 2004 From: jwilhelm at summit7solutions.com (Jeff Wilhelm) Date: Sun, 14 Nov 2004 11:49:12 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <8d9a4280041114082132f2065f@mail.gmail.com> Message-ID: <20041114164915.2B5F0A85E9@virtu.nyphp.org> Joseph, Are you adding the extra spacing around the Content-Type header? I don't think you are supposed to have any extra newlines in there. Jeff .: J E F F W I L H E L M :. jeff at summit7solutions.com .:. summit7solutions.com p: (401)709-4492 .:. f: (419)735-8865 ----Original Message---- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On Behalf Of Joseph Crawford Sent: Sunday, November 14, 2004 11:21 AM To: NYPHP Talk Subject: Re: [nycphp-talk] Email not working > here are the complete headers > > > X-Gmail-Received: 5a9134da937ae26298872b9230cbf548ec49975d > Delivered-To: codebowl at gmail.com > Received: by 10.38.65.73 with SMTP id n73cs9567rna; > Sun, 14 Nov 2004 08:19:21 -0800 (PST) > Received: by 10.38.171.10 with SMTP id t10mr456024rne; > Sun, 14 Nov 2004 08:19:20 -0800 (PST) > Return-Path: > Received: from vt-fairhaven1a-82.bur.adelphia.net > ([68.64.74.82]) by mx.gmail.com with ESMTP id > 70si1333970rnc; Sun, 14 Nov 2004 08:19:20 -0800 > (PST) > Received-SPF: neutral (gmail.com: 68.64.74.82 is neither > permitted nor denied by domain of > nobody at vt-fairhaven1a-82.bur.adelphia.net) Received: by > vt-fairhaven1a-82.bur.adelphia.net (Postfix, from userid > 65534) id 34F745282E6; Sun, 14 Nov 2004 11:17:51 -0500 > (EST) > To: codebowl at gmail.com > Subject: Demonoid Account Confirmation > MIME-Version: 1.0 > > Content-type: text/html; charset=iso-8859-1 > > From: Demonoid > X-Mailer: PHP/4.3.9\r\n > Message-Id: > <20041114161751.34F745282E6 at vt-fairhaven1a-82.bur.adelphia.net> > Date: Sun, 14 Nov 2004 11:17:51 -0500 (EST) > > // BEGINNING OF BODY OF MESSAGE > > > From codebowl at gmail.com Sun Nov 14 14:26:08 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 14:26:08 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <20041114164915.2B5F0A85E9@virtu.nyphp.org> References: <8d9a4280041114082132f2065f@mail.gmail.com> <20041114164915.2B5F0A85E9@virtu.nyphp.org> Message-ID: <8d9a42800411141126320f7c53@mail.gmail.com> Jeff, i have the \r\n in there but it's in there when you look at the docs as well. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From codebowl at gmail.com Sun Nov 14 14:43:50 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 14:43:50 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <8d9a42800411141126320f7c53@mail.gmail.com> References: <8d9a4280041114082132f2065f@mail.gmail.com> <20041114164915.2B5F0A85E9@virtu.nyphp.org> <8d9a42800411141126320f7c53@mail.gmail.com> Message-ID: <8d9a428004111411433a06b78a@mail.gmail.com> it is also listing the From name as (unknown user) in gmail and Nobody in yahoo mail :( i got the html to sorta work in gmail except that all my images that are linked say thismessage:/ in yahoo it still only shows just the HTML -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From 1j0lkq002 at sneakemail.com Sun Nov 14 15:19:34 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Sun, 14 Nov 2004 15:19:34 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <8d9a428004111408163b88e225@mail.gmail.com> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> <8d9a428004111406277a25dd46@mail.gmail.com> <41976DD7.2080600@phpwerx.net> <8d9a428004111408163b88e225@mail.gmail.com> Message-ID: <16272-38799@sneakemail.com> Joseph Crawford codebowl-at-gmail.com |nyphp dev/internal group use| wrote: >this is not what i am looking for because i send very few emails and i >dont need to add all that extra code... > >i just want to get this HTML email sending to work, i cant seem to get >it to work with my domain email, but when i send to my gmail account >it sends as all plain text for some reason :D > Very often (every time?) it is wiser to start with known good code and debug if you have to, instead of starting with unknown good code and debugging. Mabe you don't need to send binary atachments etc, but why not use known good mailer code? Is your hard drive almost full? -=john andrews From codebowl at gmail.com Sun Nov 14 15:31:01 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sun, 14 Nov 2004 15:31:01 -0500 Subject: [nycphp-talk] Email not working In-Reply-To: <16272-38799@sneakemail.com> References: <8d9a428004111318191e35eb58@mail.gmail.com> <003601c4ca1a$a861aaf0$fe01010a@dj> <8d9a428004111406277a25dd46@mail.gmail.com> <41976DD7.2080600@phpwerx.net> <8d9a428004111408163b88e225@mail.gmail.com> <16272-38799@sneakemail.com> Message-ID: <8d9a4280041114123161ad0fd0@mail.gmail.com> lol good question... no my drive is not almost full however i am trying to keep the code on the site limited to code that will be used for better managing. I dont want to have a ton of code on the site that is not being used by the site because then it may confuse another programmer if i bring them into the project. I am not sure why this is not working but i will figure it out sooner or later, maybe it's just something wrong with my localhost not sending the email's properly i can see that it keeps sending 2 From headers one i created and one that seems to be created automatically. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From adam at trachtenberg.com Sun Nov 14 21:24:43 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Sun, 14 Nov 2004 21:24:43 -0500 (EST) Subject: [nycphp-talk] SQLite book by Chris Newman In-Reply-To: <41965368.5040506@ceruleansky.com> References: <41965368.5040506@ceruleansky.com> Message-ID: On Sat, 13 Nov 2004, Jayesh Sheth wrote: > thanks for your note. I think I will order it soon from Amazon or from > Bookpool. (I think that Adam Trachtenberg's new book has a section on > creating an address book using SQLite and PHP5, or something like that.) I have an entire chapter on SQLite in "Upgrading to PHP 5". In general, using SQLite in PHP isn't much different from other databases. The SQLite extension does have the neat feature of allowing you to create UDFs in PHP. I walk you though a few examples for both regular and aggregate UDFs. The book's final chapter also has a "putting it all together" wrap up, and that's where I write an address book with a SQLite backend and both web and commandline frontends. (It's not the world's most advanced address book.) Also, the SQLite extension only works with SQLite 2.x. If you want to use SQLite 3.x, I think you can use PDO, but I'm not positive. I haven't played with it myself. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From jeff.knight at gmail.com Mon Nov 15 11:22:32 2004 From: jeff.knight at gmail.com (Jeff Knight) Date: Mon, 15 Nov 2004 11:22:32 -0500 Subject: [nycphp-talk] SQLite book by Chris Newman In-Reply-To: References: <41965368.5040506@ceruleansky.com> Message-ID: <2ca9ba910411150822ac4187a@mail.gmail.com> By the way, the SQLite Chapter of Mr. Trachtenberg's book is available for free as a pdf directly from O'Reilly: http://www.oreilly.com/catalog/upgradephp5/chapter/ Of course, for the other chapters, you'll just have to buy the book.... On Sun, 14 Nov 2004 21:24:43 -0500 (EST), Adam Maccabee Trachtenberg wrote: > I have an entire chapter on SQLite in "Upgrading to PHP 5". In > general, using SQLite in PHP isn't much different from other > databases. The SQLite extension does have the neat feature of allowing > you to create UDFs in PHP. I walk you though a few examples for both > regular and aggregate UDFs. -- I'm Jeff Knight, and I approved this message From michael.southwell at nyphp.org Mon Nov 15 16:48:51 2004 From: michael.southwell at nyphp.org (Michael Southwell) Date: Mon, 15 Nov 2004 16:48:51 -0500 Subject: [nycphp-talk] Fwd: Word Annoyances Needed for New Book Message-ID: <6.1.2.0.2.20041115164722.01ff4e20@mail.optonline.net> An opportunity for possible (small-scale) publication: >Dear User Group Leader: > >O'Reilly is pulling together a new book called "Word Annoyances" and, once >again, we'd like your help! As you might guess, "Word Annoyances" ponders >the problems, snarls, quirks, bugs, and just dumb things about Word that >drive users nuts. The annoyances will encompass a range of topics: general >misbehavior, creating and saving documents, text entry and editing, >formatting and layout, printing, tables, macros, etc. > >Word is the most ubiquitous--and probably the most annoying--word >processor on the planet. If any members of your group have annoyances >they'd like to see solved, have them email marsee at oreilly.com with "Word >Annoyances" in the subject line. Just have them note what version of Word >and Windows they're using. > >As always, thanks for sharing. We'll make sure to get copies of "Word >Annoyances" sent to your group shortly after publication. > > >--Marsee Michael Southwell VP, Education Department New York PHP michael.southwell at nyphp.org From jeff.knight at gmail.com Mon Nov 15 17:46:18 2004 From: jeff.knight at gmail.com (Jeff Knight) Date: Mon, 15 Nov 2004 17:46:18 -0500 Subject: [nycphp-talk] Fwd: Word Annoyances Needed for New Book In-Reply-To: <6.1.2.0.2.20041115164722.01ff4e20@mail.optonline.net> References: <6.1.2.0.2.20041115164722.01ff4e20@mail.optonline.net> Message-ID: <2ca9ba9104111514461980350@mail.gmail.com> Are there enough trees in the forrests of the Earth for such a large volume? On Mon, 15 Nov 2004 16:48:51 -0500, Michael Southwell wrote: > An opportunity for possible (small-scale) publication: > > >Dear User Group Leader: > > > >O'Reilly is pulling together a new book called "Word Annoyances" and, once > >again, we'd like your help! As you might guess, "Word Annoyances" ponders > >the problems, snarls, quirks, bugs, and just dumb things about Word that > >drive users nuts. The annoyances will encompass a range of topics: general > >misbehavior, creating and saving documents, text entry and editing, > >formatting and layout, printing, tables, macros, etc. > > > >Word is the most ubiquitous--and probably the most annoying--word > >processor on the planet. If any members of your group have annoyances > >they'd like to see solved, have them email marsee at oreilly.com with "Word > >Annoyances" in the subject line. Just have them note what version of Word > >and Windows they're using. > > > >As always, thanks for sharing. We'll make sure to get copies of "Word > >Annoyances" sent to your group shortly after publication. > > > > > >--Marsee > > Michael Southwell > VP, Education Department > New York PHP > michael.southwell at nyphp.org > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- I'm Jeff Knight, and I approved this message From mjdewitt at alexcommgrp.com Tue Nov 16 11:08:18 2004 From: mjdewitt at alexcommgrp.com (DeWitt, Michael) Date: Tue, 16 Nov 2004 11:08:18 -0500 Subject: [nycphp-talk] MySQL query question Message-ID: Does anyone know if there is a way to write a query in a v3 engine to do a query comparing two columns using like? I would like to count all rows where the last name appears in the company name. In sql server a query like this works: select count(*) from table where company like rtrim(last_name)+'%' Thanks in advance. Mike From joel at tagword.com Tue Nov 16 06:16:03 2004 From: joel at tagword.com (Joel De Gan) Date: Tue, 16 Nov 2004 11:16:03 +0000 Subject: [nycphp-talk] MySQL query question In-Reply-To: References: Message-ID: <1100603762.8431.56.camel@bezel> Hi, In like comparisions you can use '%%%' for wildcard checking so, for anywhere SELECT * FROM table WHERE field LIKE '%%%name%%%' for right side: SELECT * FROM table WHERE field LIKE '%%%name' and for left SELECT * FROM table WHERE field LIKE 'name%%%' That is one way to do it. -joel On Tue, 2004-11-16 at 16:08, DeWitt, Michael wrote: > Does anyone know if there is a way to write a query in a v3 engine to do a > query comparing two columns using like? > > I would like to count all rows where the last name appears in the company > name. > > In sql server a query like this works: > > select count(*) from table where company like rtrim(last_name)+'%' > > Thanks in advance. > > Mike > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > -- joeldg - developer, Intercosmos media group. http://lucifer.intercosmos.net From mjdewitt at alexcommgrp.com Tue Nov 16 11:55:47 2004 From: mjdewitt at alexcommgrp.com (DeWitt, Michael) Date: Tue, 16 Nov 2004 11:55:47 -0500 Subject: [nycphp-talk] MySQL query question Message-ID: Joel, Thanks for your help. I found that mysql treats column names embedded in strings as a literal. I could get right hand like to work using: select * from table where firm like rtrim(last_name)+'%%%' but couldn't find a syntax that worked for the left hand side. The problem was that it was over matching (and yet not returning all rows). for example this query: select * from table where firm like '%%%'+rtrim(last_name)+'%%%' returned about 90% of all rows and clearly was overmatching. The solution I found which seems to duplicate the the sql server query is : select count(*) from nar where locate(rtrim(lcntct),firm)>0; Thanks again. Mike > -----Original Message----- > From: Joel De Gan [SMTP:joel at tagword.com] > Sent: Tuesday, November 16, 2004 6:16 AM > To: NYPHP Talk > Subject: Re: [nycphp-talk] MySQL query question > > Hi, > In like comparisions you can use '%%%' for wildcard checking > so, for anywhere > SELECT * FROM table WHERE field LIKE '%%%name%%%' > for right side: > SELECT * FROM table WHERE field LIKE '%%%name' > and for left > SELECT * FROM table WHERE field LIKE 'name%%%' > > That is one way to do it. > -joel > > On Tue, 2004-11-16 at 16:08, DeWitt, Michael wrote: > > Does anyone know if there is a way to write a query in a v3 engine to do > a > > query comparing two columns using like? > > > > I would like to count all rows where the last name appears in the > company > > name. > > > > In sql server a query like this works: > > > > select count(*) from table where company like rtrim(last_name)+'%' > > > > Thanks in advance. > > > > Mike > > > > _______________________________________________ > > New York PHP Talk > > Supporting AMP Technology (Apache/MySQL/PHP) > > http://lists.nyphp.org/mailman/listinfo/talk > > http://www.newyorkphp.org > > > -- > joeldg - developer, Intercosmos media group. > http://lucifer.intercosmos.net > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From prusak at gmail.com Tue Nov 16 12:00:24 2004 From: prusak at gmail.com (Ophir Prusak) Date: Tue, 16 Nov 2004 12:00:24 -0500 Subject: [nycphp-talk] MySQL query question In-Reply-To: References: Message-ID: This should work (if you want full substring search). select count(*) from table where company like concat('%',last_name,'%') On Tue, 16 Nov 2004 11:08:18 -0500, DeWitt, Michael wrote: > Does anyone know if there is a way to write a query in a v3 engine to do a > query comparing two columns using like? > > I would like to count all rows where the last name appears in the company > name. > > In sql server a query like this works: > > select count(*) from table where company like rtrim(last_name)+'%' > > Thanks in advance. > > Mike > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From mjdewitt at alexcommgrp.com Tue Nov 16 12:04:37 2004 From: mjdewitt at alexcommgrp.com (DeWitt, Michael) Date: Tue, 16 Nov 2004 12:04:37 -0500 Subject: [nycphp-talk] MySQL query question Message-ID: Ophir, Yup. Works like a charm. Funny that the '+' concatentation character doesn't work the same way. Mike > -----Original Message----- > From: Ophir Prusak [SMTP:prusak at gmail.com] > Sent: Tuesday, November 16, 2004 12:00 PM > To: NYPHP Talk > Subject: Re: [nycphp-talk] MySQL query question > > This should work (if you want full substring search). > > select count(*) from table where company like concat('%',last_name,'%') > > On Tue, 16 Nov 2004 11:08:18 -0500, DeWitt, Michael > wrote: > > Does anyone know if there is a way to write a query in a v3 engine to do > a > > query comparing two columns using like? > > > > I would like to count all rows where the last name appears in the > company > > name. > > > > In sql server a query like this works: > > > > select count(*) from table where company like rtrim(last_name)+'%' > > > > Thanks in advance. > > > > Mike > > > > _______________________________________________ > > New York PHP Talk > > Supporting AMP Technology (Apache/MySQL/PHP) > > http://lists.nyphp.org/mailman/listinfo/talk > > http://www.newyorkphp.org > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From prusak at gmail.com Tue Nov 16 12:37:37 2004 From: prusak at gmail.com (Ophir Prusak) Date: Tue, 16 Nov 2004 12:37:37 -0500 Subject: [nycphp-talk] MySQL query question In-Reply-To: References: Message-ID: I think the plus symbol only works as an arithmetic operator to do addition. On Tue, 16 Nov 2004 12:04:37 -0500, DeWitt, Michael wrote: > Ophir, > > Yup. Works like a charm. Funny that the '+' concatentation character > doesn't work the same way. > > Mike > > > > > -----Original Message----- > > From: Ophir Prusak [SMTP:prusak at gmail.com] > > Sent: Tuesday, November 16, 2004 12:00 PM > > To: NYPHP Talk > > Subject: Re: [nycphp-talk] MySQL query question > > > > This should work (if you want full substring search). > > > > select count(*) from table where company like concat('%',last_name,'%') > > > > On Tue, 16 Nov 2004 11:08:18 -0500, DeWitt, Michael > > wrote: > > > Does anyone know if there is a way to write a query in a v3 engine to do > > a > > > query comparing two columns using like? > > > > > > I would like to count all rows where the last name appears in the > > company > > > name. > > > > > > In sql server a query like this works: > > > > > > select count(*) from table where company like rtrim(last_name)+'%' > > > > > > Thanks in advance. > > > > > > Mike > > > > > > _______________________________________________ > > > New York PHP Talk > > > Supporting AMP Technology (Apache/MySQL/PHP) > > > http://lists.nyphp.org/mailman/listinfo/talk > > > http://www.newyorkphp.org > > > > > _______________________________________________ > > New York PHP Talk > > Supporting AMP Technology (Apache/MySQL/PHP) > > http://lists.nyphp.org/mailman/listinfo/talk > > http://www.newyorkphp.org > _______________________________________________ > > > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From nyphp at enobrev.com Tue Nov 16 13:06:35 2004 From: nyphp at enobrev.com (Mark Armendariz) Date: Tue, 16 Nov 2004 13:06:35 -0500 Subject: [nycphp-talk] Dynamic Methods at runtime Message-ID: <20041116180643.96A25A85E9@virtu.nyphp.org> Good afternoon ladies and gents, I can't seem to find how anywhere (been digging through the manual, google, yahoo, even msn's beta search). I think someone mentioned this recently, but I couldn't find the post either. Is there any way to create methods for a class at runtime? Thanks! Mark From scott at crisscott.com Tue Nov 16 13:14:05 2004 From: scott at crisscott.com (Scott Mattocks) Date: Tue, 16 Nov 2004 13:14:05 -0500 Subject: [nycphp-talk] Dynamic Methods at runtime In-Reply-To: <20041116180643.96A25A85E9@virtu.nyphp.org> References: <20041116180643.96A25A85E9@virtu.nyphp.org> Message-ID: <419A436D.3020906@crisscott.com> Mark Armendariz wrote: > I can't seem to find how anywhere (been digging through the manual, google, > yahoo, even msn's beta search). I think someone mentioned this recently, > but I couldn't find the post either. That someone was you! > Is there any way to create methods for a class at runtime? Manual page: http://us2.php.net/manual/en/function.create-function.php Mail archives: (It should look familiar) http://lists.nyphp.org/pipermail/talk/2004-September/011688.html -- Scott Mattocks scott at crisscott.com http://www.crisscott.com http://pear.php.net/user/scottmattocks From nyphp at enobrev.com Tue Nov 16 13:37:19 2004 From: nyphp at enobrev.com (Mark Armendariz) Date: Tue, 16 Nov 2004 13:37:19 -0500 Subject: [nycphp-talk] Dynamic Methods at runtime In-Reply-To: <419A436D.3020906@crisscott.com> Message-ID: <20041116183718.C9967A85E9@virtu.nyphp.org> > That someone was you! > Mail archives: (It should look familiar) > http://lists.nyphp.org/pipermail/talk/2004-September/011688.html Ha! Good call. > Manual page: > http://us2.php.net/manual/en/function.create-function.php Doesn't look like there's a very clean and fun way to add a method to a class though, unfortunately. Thanks!! Mark From jeff.loiselle at gmail.com Wed Nov 17 12:38:42 2004 From: jeff.loiselle at gmail.com (Jeff Loiselle) Date: Wed, 17 Nov 2004 12:38:42 -0500 Subject: [nycphp-talk] [OT] Favorite MySQL navigator Message-ID: <4b1887110411170938487e25e2@mail.gmail.com> Sorry: I am becoming notorious for asking more questions (trolling) about hosting providers, international outsourcing, databases, and programming style than strict PHP. But I value all of your opinions and I have yet another question. What is everyone's favorite MySQL database navigator program? Or are you still just loving the MySQL command line client? I have used the command line, SQLyog, and Navicat extensively. I've also seemed to stay away from MySQL Administrator, MySQL Maestro, and MySQL Control Center, and phpMyAdmin; In case you cared. Please contact me *off-list* as I fear I maybe be e-castrated for this post. From matt at atopia.net Wed Nov 17 15:08:04 2004 From: matt at atopia.net (Matt Juszczak) Date: Wed, 17 Nov 2004 15:08:04 -0500 (EST) Subject: [nycphp-talk] MySQL query question In-Reply-To: <1100603762.8431.56.camel@bezel> References: <1100603762.8431.56.camel@bezel> Message-ID: <20041117150752.D84439@neptune.atopia.net> Why not just %name% or %name or name% ? On Tue, 16 Nov 2004, Joel De Gan wrote: > Hi, > In like comparisions you can use '%%%' for wildcard checking > so, for anywhere > SELECT * FROM table WHERE field LIKE '%%%name%%%' > for right side: > SELECT * FROM table WHERE field LIKE '%%%name' > and for left > SELECT * FROM table WHERE field LIKE 'name%%%' > > That is one way to do it. > -joel > > On Tue, 2004-11-16 at 16:08, DeWitt, Michael wrote: >> Does anyone know if there is a way to write a query in a v3 engine to do a >> query comparing two columns using like? >> >> I would like to count all rows where the last name appears in the company >> name. >> >> In sql server a query like this works: >> >> select count(*) from table where company like rtrim(last_name)+'%' >> >> Thanks in advance. >> >> Mike >> >> _______________________________________________ >> New York PHP Talk >> Supporting AMP Technology (Apache/MySQL/PHP) >> http://lists.nyphp.org/mailman/listinfo/talk >> http://www.newyorkphp.org >> > -- > joeldg - developer, Intercosmos media group. > http://lucifer.intercosmos.net > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > > !DSPAM:419a2749602611012812855! > From matt at atopia.net Wed Nov 17 15:08:48 2004 From: matt at atopia.net (Matt Juszczak) Date: Wed, 17 Nov 2004 15:08:48 -0500 (EST) Subject: [nycphp-talk] MySQL query question In-Reply-To: References: Message-ID: <20041117150843.Y84439@neptune.atopia.net> Oh oops, nevermind :) On Tue, 16 Nov 2004, Ophir Prusak wrote: > This should work (if you want full substring search). > > select count(*) from table where company like concat('%',last_name,'%') > > On Tue, 16 Nov 2004 11:08:18 -0500, DeWitt, Michael > wrote: >> Does anyone know if there is a way to write a query in a v3 engine to do a >> query comparing two columns using like? >> >> I would like to count all rows where the last name appears in the company >> name. >> >> In sql server a query like this works: >> >> select count(*) from table where company like rtrim(last_name)+'%' >> >> Thanks in advance. >> >> Mike >> >> _______________________________________________ >> New York PHP Talk >> Supporting AMP Technology (Apache/MySQL/PHP) >> http://lists.nyphp.org/mailman/listinfo/talk >> http://www.newyorkphp.org >> > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > > > !DSPAM:419a322c609941025134037! > From mjdewitt at alexcommgrp.com Wed Nov 17 17:10:23 2004 From: mjdewitt at alexcommgrp.com (DeWitt, Michael) Date: Wed, 17 Nov 2004 17:10:23 -0500 Subject: [nycphp-talk] Servers may soon be less vulnerable to exploits? Message-ID: I just ran across mentions of AMD and Intel's implemention of some protection from buffer overflow attacks: >From CNET The security technology, called NX for "no execute," is built into several "x86" processors from Intel, AMD and Transmeta. The technology is designed to block vulnerabilities that viruses and worms use to spread, but operating system support is required for NX to work. http://ecoustics-cnet.com.com/Linux+gets+trial+'NX'+security+support/2100-73 44_3-5227102.html More on it here: http://www.anandtech.com/cpuchipsets/showdoc.aspx?i=2239 seems like it isn't perfect yet... from Anandtech: This is not to say that NX protection is not a step in the right direction. In fact, NX/XD is a good first step to locking down the x86 architecture, as long as it's adopted correctly. OpenBSD and the Execshield projects have made the largest progress with implementing non-executable writable pages and other features, if only in software. However, NX does not completely eliminate buffer overflow exploits, and thus far it has only caused more problems than it has solved with Windows SP2. Mike From chsnyder at gmail.com Wed Nov 17 20:40:28 2004 From: chsnyder at gmail.com (csnyder) Date: Wed, 17 Nov 2004 20:40:28 -0500 Subject: [nycphp-talk] Servers may soon be less vulnerable to exploits? In-Reply-To: References: Message-ID: On Wed, 17 Nov 2004 17:10:23 -0500, DeWitt, Michael quoted: > However, NX does not completely > eliminate buffer overflow exploits, and thus far it has only caused more > problems than it has solved with Windows SP2. In case you were wondering what those problems might be... http://support.microsoft.com/?id=884130 From jfreeman at nybg.org Thu Nov 18 11:45:31 2004 From: jfreeman at nybg.org (Joshua S. Freeman) Date: Thu, 18 Nov 2004 11:45:31 -0500 Subject: [nycphp-talk] PHPLdapAdmin Message-ID: Anyone using this application? Anyone here have good LDAP - fu? We have a middle - low tier HR application called AbraHR. It is not LDAP-compliant. It *can* output a .csv file for all 500+ employees with this information: p_nickname = (first name) p_lname = (last name) p_busext = (4 digit extension) _level1 = (primary department_name (i.e. Horticulture)) _level2 = (secondary departmental_name (i.e. Groundskeeping)) p_supervis = (supervisor's name) p_jobtitle = title p_empemail = email Now, I did an ldif export of my record in the LDAP database: # Entry 1: cn=Freeman Joshua,ou=People,dc=digir,dc=nybg,dc=org dn:cn=Freeman Joshua,ou=People,dc=digir,dc=nybg,dc=org cn: Freeman Joshua givenName: Joshua sn: Freeman o: Information Technology l: Bronx postalCode: 10458 street: 200th St. & Kazimiroff Blvd. telephoneNumber: 718 817 8937 mail: jfreeman at nybg.org objectClass: top objectClass: inetOrgPerson facsimileTelephoneNumber: 718 817 8537 uid: jfreeman title: Director of Information Technology I'd like some idea of how to add information that exists in AbraHR to the LDAP schema.. If I can add supervisor name and dept. 1, dept. 2 to the LDAP schema, then I should also be able to use PHP regex (or something...dare I say 'PERL' on this list?) to convert the .csv file to usable LDIF records that I can import into the LDAP database. Any help with this little exercise greatly appreciated. TIA, Joshua -- COMPUTER HELPDESK (when inside the Garden): http://helpdesk.nybg.org/ Joshua S. Freeman Dir. of Information Technology New York Botanical Garden v: 718 817 8937 m: 347 392 2560 This message (including any attachments) contains confidential information intended for a specific individual/group of individuals and a specific purpose, and is protected by law. If you are not an intended recipient, you should delete this message. Any disclosure, copying, or distribution of this message, or the taking of any action based on it, is strictly prohibited. From hans at nyphp.com Thu Nov 18 16:03:38 2004 From: hans at nyphp.com (Hans Zaunere) Date: Thu, 18 Nov 2004 13:03:38 -0800 Subject: [nycphp-talk] Enterprise PHP - Yes? Message-ID: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.net> Interesting - http://news.com.com/Start-up+pitches+high-end+Web+apps+on+the+cheap/2100 -7345_3-5458483.html H From hans at nyphp.com Thu Nov 18 16:04:49 2004 From: hans at nyphp.com (Hans Zaunere) Date: Thu, 18 Nov 2004 13:04:49 -0800 Subject: [nycphp-talk] Enterprise PHP - Yes? Message-ID: <41EE526EC2D3C74286415780D3BA9F8705DB3312@ehost011-1.exch011.intermedia.net> > Interesting - > > http://news.com.com/Start-up+pitches+high-end+Web+apps+on+the+cheap/2100 > -7345_3-5458483.html And I really should have included this: http://www.activegrid.com/technology/index.php --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From mogmios at mlug.missouri.edu Thu Nov 18 16:56:13 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Thu, 18 Nov 2004 13:56:13 -0800 Subject: [nycphp-talk] Enterprise PHP - Yes? In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.net> Message-ID: <419D1A7D.2090408@mlug.missouri.edu> I really don't get it. I've never had any trouble scaling pretty much any programming language across multiple servers for the purpose of web apps. It all pretty much comes down to making sure that all app data is stored in a shared database and then load balancing your application servers. If you want to be more effecient with data caching then do something like use XML-RPC between different layers of your application logic and use normal http caching with something like Squid between the layers. The programming language and OS involved are for the most part irrelevant as far as scaling goes. You can even mix and match them without any problem. CLIENT <-(cache)-> FRONTEND APP CLUSTER <-(cache)-> BACKEND APP CLUSTER <-(cache)-> DB CLUSTER -- Michael http://kavlon.org From chsnyder at gmail.com Thu Nov 18 17:20:11 2004 From: chsnyder at gmail.com (csnyder) Date: Thu, 18 Nov 2004 17:20:11 -0500 Subject: [nycphp-talk] Enterprise PHP - Yes? In-Reply-To: <419D1A7D.2090408@mlug.missouri.edu> References: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.net> <419D1A7D.2090408@mlug.missouri.edu> Message-ID: On Thu, 18 Nov 2004 13:56:13 -0800, Michael wrote: > CLIENT <-(cache)-> FRONTEND APP CLUSTER <-(cache)-> BACKEND APP CLUSTER <-(cache)-> DB CLUSTER I wonder if this is targetted at people/companies that would rather not have to hassle setting up the servers and infrastructure to implement what you describe? "I want my PHP applications to scale massively but I can't afford a CTO" kind of companies. From mogmios at mlug.missouri.edu Thu Nov 18 17:38:46 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Thu, 18 Nov 2004 14:38:46 -0800 Subject: [nycphp-talk] Enterprise PHP - Yes? In-Reply-To: References: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.net> <419D1A7D.2090408@mlug.missouri.edu> Message-ID: <419D2476.3020600@mlug.missouri.edu> >I wonder if this is targetted at people/companies that would rather >not have to hassle setting up the servers and infrastructure to >implement what you describe? > >"I want my PHP applications to scale massively but I can't afford a >CTO" kind of companies. > I suppose so but in that case why do any in-house development? If you're paying for outsourcing your development then they should be able to scale your apps as much as you need anyway assuming your willing to pay for it. For the most part all you need to do is setup the servers you want in the standard way, setup load balancing however your techs like to implement it, and setup your caches, webservers, databases, etc as normal. Nothing about it is something a reasonably well trained system admin couldn't do with ease. The only step the average admin might have to put much work into is learning how load balancing is implemented. -- Michael http://kavlon.org From jayeshsh at ceruleansky.com Thu Nov 18 17:57:39 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Thu, 18 Nov 2004 17:57:39 -0500 (EST) Subject: [nycphp-talk] PEAR Image Transform Library - similar libraries available? Message-ID: <37575.69.86.84.233.1100818659.spork@webmail.ceruleansky.com> Hi all, I was wondering if anyone has used the alpha version of the PEAR Image Transform library: http://pear.php.net/package/Image_Transform/ It has no online documentation, but I think I can figure out how to use it (/ its methods). It seems to have a lot of useful methods, such as: resize an image proportionally given either the new width or the new height. For example, suppose you have a 240 x 320 image (width by height). If you want to resize the width to 100, what should the height be to keep the image proportional? It has "drivers" for various image transformation libraries, such as GD, ImageMagick, etc. I was wondering if any of you have other functions / classes that do similar stuff, since this is supposedly alpha code (with some placeholder methods). Thanks, - Jay From suzerain at suzerain.com Fri Nov 19 03:26:34 2004 From: suzerain at suzerain.com (Marc Antony Vose) Date: Fri, 19 Nov 2004 03:26:34 -0500 Subject: [nycphp-talk] suppress errors in command line script In-Reply-To: <419D2476.3020600@mlug.missouri.edu> References: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.ne t> <419D1A7D.2090408@mlug.missouri.edu> <419D2476.3020600@mlug.missouri.edu> Message-ID: hi there: i am trying to use the command line PHP on a server which i didn't set up. it's installed at /usr/bin/php, but whenever invoked, i get this: PHP Warning: Unknown(): Unable to load dynamic library '/usr/lib/php4/pgsql.so' - libpq.so.3: cannot open shared object file: No such file or directory in Unknown on line 0 ok...so something wasn't compiled properly...apparently it can't find the postgresql library. i can deal with this later (maybe; i only have limited control here). anyway, this doesn't affect execution of my script, which i have tried invoking thusly: /usr/bin/php -q -d display_startup_errors=0 -d display_errors=0 /path/to/script.php it seems like no matter what i do, i can't suppress that PHP Warning message, and this is annoying, because the crontab manager is emailing me this warning twice every 15 minutes. anyone know how i can get rid of this temporarily, short of installing these Postgresql libraries? cheers, -- Marc Antony Vose http://www.suzerain.com/ The cost of liberty is less than the price of repression. -- W.E.B. Du Bois From chsnyder at gmail.com Fri Nov 19 08:44:25 2004 From: chsnyder at gmail.com (csnyder) Date: Fri, 19 Nov 2004 08:44:25 -0500 Subject: [nycphp-talk] suppress errors in command line script In-Reply-To: References: <419D1A7D.2090408@mlug.missouri.edu> <419D2476.3020600@mlug.missouri.edu> Message-ID: On Fri, 19 Nov 2004 03:26:34 -0500, Marc Antony Vose wrote: > it seems like no matter what i do, i can't suppress that PHP Warning > message, and this is annoying, because the crontab manager is > emailing me this warning twice every 15 minutes. Could you compile your own php binary, in your home directory? From mitch.pirtle at gmail.com Fri Nov 19 09:10:02 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Fri, 19 Nov 2004 09:10:02 -0500 Subject: [nycphp-talk] suppress errors in command line script In-Reply-To: References: <419D1A7D.2090408@mlug.missouri.edu> <419D2476.3020600@mlug.missouri.edu> Message-ID: <330532b6041119061043c8b583@mail.gmail.com> On Fri, 19 Nov 2004 03:26:34 -0500, Marc Antony Vose wrote: > anyone know how i can get rid of this temporarily, short of > installing these Postgresql libraries? If you have access to php.ini, just coment the lines that load that extension and restart apache. As long as you are not needing PostgreSQL, that is the obvious choice ;-) -- Mitch From dcech at phpwerx.net Fri Nov 19 09:30:47 2004 From: dcech at phpwerx.net (Dan Cech) Date: Fri, 19 Nov 2004 09:30:47 -0500 Subject: [nycphp-talk] suppress errors in command line script In-Reply-To: References: <41EE526EC2D3C74286415780D3BA9F8705DB330D@ehost011-1.exch011.intermedia.ne t> <419D1A7D.2090408@mlug.missouri.edu> <419D2476.3020600@mlug.missouri.edu> Message-ID: <419E0397.4030509@phpwerx.net> Marc Antony Vose wrote: > hi there: > > i am trying to use the command line PHP on a server which i didn't set > up. it's installed at /usr/bin/php, but whenever invoked, i get this: > > PHP Warning: Unknown(): Unable to load dynamic library > '/usr/lib/php4/pgsql.so' - libpq.so.3: cannot open shared object file: > No such file or directory in Unknown on line 0 > > ok...so something wasn't compiled properly...apparently it can't find > the postgresql library. i can deal with this later (maybe; i only have > limited control here). > > anyway, this doesn't affect execution of my script, which i have tried > invoking thusly: > > /usr/bin/php -q -d display_startup_errors=0 -d display_errors=0 > /path/to/script.php try making your own copy of php.ini and doing: /usr/bin/php -c /path/to/my/php.ini /path/to/script.php Dan From brian at vermonster.com Fri Nov 19 09:37:18 2004 From: brian at vermonster.com (Brian Kaney) Date: Fri, 19 Nov 2004 09:37:18 -0500 Subject: [nycphp-talk] suppress errors in command line script In-Reply-To: <330532b6041119061043c8b583@mail.gmail.com> References: <419D1A7D.2090408@mlug.missouri.edu> <419D2476.3020600@mlug.missouri.edu> <330532b6041119061043c8b583@mail.gmail.com> Message-ID: <1100875038.27443.6.camel@brian.vermonster.com> On Fri, 2004-11-19 at 09:10, Mitch Pirtle wrote: > On Fri, 19 Nov 2004 03:26:34 -0500, Marc Antony Vose > wrote: > > anyone know how i can get rid of this temporarily, short of > > installing these Postgresql libraries? > > If you have access to php.ini, just coment the lines that load that > extension and restart apache. > Strictly for the CLI you shouldn't need to restart apache. You can also try the -c argument and point to a different configuration file. /usr/bin/php -c ./my_php.ini - Brian From hans at nyphp.com Fri Nov 19 09:38:08 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 19 Nov 2004 06:38:08 -0800 Subject: [nycphp-talk] [OT] Favorite MySQL navigator Message-ID: <41EE526EC2D3C74286415780D3BA9F8705DB3839@ehost011-1.exch011.intermedia.net> > Sorry: I am becoming notorious for asking more questions (trolling) > about hosting providers, international outsourcing, databases, and > programming style than strict PHP. But I value all of your opinions > and I have yet another question. > > What is everyone's favorite MySQL database navigator program? Or are > you still just loving the MySQL command line client? > > I have used the command line, SQLyog, and Navicat extensively. I've > also seemed to stay away from MySQL Administrator, MySQL Maestro, and > MySQL Control Center, and phpMyAdmin; In case you cared. Well, I like the ones you mention... for web, phpMyAdmin of course, although I find it gives erroneous results sometimes, so be careful. For strict DB control, I like MySQL Administrator. For more SQL related things, Navicat and the MySQL Query Browser are nice... > Please contact me *off-list* as I fear I maybe be e-castrated for this post. Why? Although, these types of questions come up often enough, that we should start an NYPHP MVP, Most Valuable Project. --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From hans at nyphp.com Fri Nov 19 09:41:59 2004 From: hans at nyphp.com (Hans Zaunere) Date: Fri, 19 Nov 2004 06:41:59 -0800 Subject: [nycphp-talk] Enterprise PHP - Yes? Message-ID: <41EE526EC2D3C74286415780D3BA9F8705DB3843@ehost011-1.exch011.intermedia.net> > >I wonder if this is targetted at people/companies that would rather > >not have to hassle setting up the servers and infrastructure to > >implement what you describe? > > > >"I want my PHP applications to scale massively but I can't afford a > >CTO" kind of companies. > > > I suppose so but in that case why do any in-house development? If you're > paying for outsourcing your development then they should be able to > scale your apps as much as you need anyway assuming your willing to pay > for it. For the most part all you need to do is setup the servers you > want in the standard way, setup load balancing however your techs like > to implement it, and setup your caches, webservers, databases, etc as > normal. Nothing about it is something a reasonably well trained system > admin couldn't do with ease. The only step the average admin might have > to put much work into is learning how load balancing is implemented. Exactly - work. People want to roll things out with as little effort as possible, and the more prepackaging/preconfiguring/pre-thinking has gone into something, the more people are ready to use it, and especially in the large company world. Frankly, you can't really blame them; with so many IT systems in a single large organization, you can't spend a lot of time on things. --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From jayeshsh at ceruleansky.com Fri Nov 19 13:06:14 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Fri, 19 Nov 2004 13:06:14 -0500 (EST) Subject: [nycphp-talk] PEAR Image Transform Library - similar libraries available? Message-ID: <49351.69.86.84.233.1100887574.spork@webmail.ceruleansky.com> Hi all, I think I might have answered my own question. Here is what I found, since it may be of use to others. I found a nice image resizing / scaling class by Gregory Brown at phpclasses.org. It is freely distributable, so I decided to put it up here for others to browse: http://www.ceruleansky.com/code/images/one/ (The link above also is useful if you don't have an account at phpclasses.org) I also found some other libraries that do similar image manipulation things (thumbnails, etc.). If anyone is interested, I could post those too. I think I am modify the way this class behaves, but its core functionality seems to be neat. - Jay From dan at cain.sh Fri Nov 19 16:15:36 2004 From: dan at cain.sh (Daniel J Cain Jr.) Date: Fri, 19 Nov 2004 15:15:36 -0600 Subject: [nycphp-talk] Regex & Delimiter Trouble Message-ID: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> Given this script: I hope to match quantity1 ... quantity999, but PHP5 on Mac OS X outputs the following from the CLI: Warning: preg_match(): Delimiter must not be alphanumeric or backslash in /Users/djcain/regex on line 4 DOH! I've been trying to get around the issue for quite some time now and I think I'm unable to see the forest through the trees :) The warning seems pretty straightforward but for the life of me I'm unable to grasp what it want's for the delimiter. Anyone out there dealt with this issue before, or see the problem that I apparently do not? -dan From dcech at phpwerx.net Fri Nov 19 16:30:05 2004 From: dcech at phpwerx.net (Dan Cech) Date: Fri, 19 Nov 2004 16:30:05 -0500 Subject: [nycphp-talk] Regex & Delimiter Trouble In-Reply-To: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> References: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> Message-ID: <419E65DD.3060809@phpwerx.net> Use single quotes, the $ is screwing up the regex. $pattern = '/^quantity[1-9][0-9]{0,2}$/'; Dan Daniel J Cain Jr. wrote: > Given this script: > > $pattern = "/^quantity[1-9][0-9]{0,2}$/"; > $haystack = "quantity11"; > echo (preg_match($haystack, $pattern)) ? 'We got one!': 'DOH!', "\n"; > ?> > > I hope to match quantity1 ... quantity999, but PHP5 on Mac OS X outputs > the following from the CLI: > > Warning: preg_match(): Delimiter must not be alphanumeric or backslash > in /Users/djcain/regex on line 4 > DOH! > > I've been trying to get around the issue for quite some time now and I > think I'm unable to see the forest through the trees :) > > The warning seems pretty straightforward but for the life of me I'm > unable to grasp what it want's for the delimiter. Anyone out there > dealt with this issue before, or see the problem that I apparently do not? > > -dan > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From dan at cain.sh Fri Nov 19 16:40:48 2004 From: dan at cain.sh (Daniel J Cain Jr.) Date: Fri, 19 Nov 2004 15:40:48 -0600 Subject: [nycphp-talk] Regex & Delimiter Trouble In-Reply-To: <419E65DD.3060809@phpwerx.net> References: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> <419E65DD.3060809@phpwerx.net> Message-ID: Still getting the same warnings as before and the "DOH!" after changing the pattern to single quotes on my system On Nov 19, 2004, at 3:30 PM, Dan Cech wrote: > Use single quotes, the $ is screwing up the regex. > > $pattern = '/^quantity[1-9][0-9]{0,2}$/'; > > Dan > From Cbielanski at inta.org Fri Nov 19 16:48:45 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Fri, 19 Nov 2004 16:48:45 -0500 Subject: [nycphp-talk] Regex & Delimiter Trouble Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA83@intamail1.com> I've noticed some dodgy behavior using the ^ and \A patterns in preg_replace() and didn't put enough effort into the issue (trivial internal Wiki) to resolve it. I did manage to determine that [\r|\n] apperas to be a suitable substitute for $. Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence > -----Original Message----- > From: Daniel J Cain Jr. [mailto:dan at cain.sh] > Sent: Friday, November 19, 2004 4:41 PM > To: NYPHP Talk > Subject: Re: [nycphp-talk] Regex & Delimiter Trouble > > > Still getting the same warnings as before and the "DOH!" > after changing > the pattern to single quotes on my system > > > On Nov 19, 2004, at 3:30 PM, Dan Cech wrote: > > > Use single quotes, the $ is screwing up the regex. > > > > $pattern = '/^quantity[1-9][0-9]{0,2}$/'; > > > > Dan > > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From codebowl at gmail.com Fri Nov 19 16:38:27 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Fri, 19 Nov 2004 16:38:27 -0500 Subject: [nycphp-talk] Uploading file with PHP Message-ID: <8d9a428004111913386d8e3b59@mail.gmail.com> guys i am having a load of an error here and i cannot track it down i am running php 4.3.8 on linux and apache 2 now i am trying to submit a form with 2 file upload fields on the form, i have named the fields name="files[]" and in my code when the form is submitted i print_r both $_FILES and $HTTP_POST_FILES now here is my problem, they both return an empty array ??? my php.ini says file_uploads is On and the file sizes are not breaking the 2mb limit set in the php.ini this is on my dev server so i cannot post a url to a phpinfo page since my ISP blocks my web server, so what i have done is ran it locally and saved the source to an html file and posted it on http://www.codebowl.com/info.html if anyone can come up with any reasons as to why this would be happening i would apprectiate it. I have been fighting with this for hours. here is the code after the form is submitted. if( isset( $_POST['submit'] ) ) { echo '
';
	print_r($HTTP_POST_FILES);
	echo '
'; echo '
';
	print_r($_FILES);
	echo '
'; } -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From dcech at phpwerx.net Fri Nov 19 16:52:55 2004 From: dcech at phpwerx.net (Dan Cech) Date: Fri, 19 Nov 2004 16:52:55 -0500 Subject: [nycphp-talk] Regex & Delimiter Trouble In-Reply-To: References: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> <419E65DD.3060809@phpwerx.net> Message-ID: <419E6B37.3030106@phpwerx.net> Daniel J Cain Jr. wrote: > Still getting the same warnings as before and the "DOH!" after changing > the pattern to single quotes on my system You also have pattern and haystack reversed in the preg_match call ... DOH indeed! Dan > On Nov 19, 2004, at 3:30 PM, Dan Cech wrote: > >> Use single quotes, the $ is screwing up the regex. >> >> $pattern = '/^quantity[1-9][0-9]{0,2}$/'; >> >> Dan >> > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From tom at supertom.com Fri Nov 19 16:54:51 2004 From: tom at supertom.com (Tom) Date: Fri, 19 Nov 2004 16:54:51 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: <8d9a428004111913386d8e3b59@mail.gmail.com> References: <8d9a428004111913386d8e3b59@mail.gmail.com> Message-ID: <1100901291.31296.7.camel@tmelendez.int.bascom.com> Are you using Apache 2x? What does it say in php.conf for the limitrequest size? Tom www.liphp.org On Fri, 2004-11-19 at 16:38, Joseph Crawford wrote: > guys i am having a load of an error here and i cannot track it down > > i am running php 4.3.8 on linux and apache 2 > > now i am trying to submit a form with 2 file upload fields on the > form, i have named the fields name="files[]" and in my code when the > form is submitted i print_r both $_FILES and $HTTP_POST_FILES > > now here is my problem, they both return an empty array ??? > > my php.ini says file_uploads is On and the file sizes are not breaking > the 2mb limit set in the php.ini > > this is on my dev server so i cannot post a url to a phpinfo page > since my ISP blocks my web server, so what i have done is ran it > locally and saved the source to an html file and posted it on > http://www.codebowl.com/info.html > > if anyone can come up with any reasons as to why this would be > happening i would apprectiate it. I have been fighting with this for > hours. > > here is the code after the form is submitted. > > if( isset( $_POST['submit'] ) ) { > echo '
';
> 	print_r($HTTP_POST_FILES);
> 	echo '
'; > echo '
';
> 	print_r($_FILES);
> 	echo '
'; > } -- ==== ======================== Tom Melendez Senior Software Developer BASCOM Global Internet Services, Inc. Phone : 631-434-6600 Fax : 631-434-7800 Email : tmelendez at bascom.com Web : http://www.bascom.com ======================== From dan at cain.sh Fri Nov 19 17:02:51 2004 From: dan at cain.sh (Daniel J Cain Jr.) Date: Fri, 19 Nov 2004 16:02:51 -0600 Subject: [nycphp-talk] Regex & Delimiter Trouble In-Reply-To: <419E6B37.3030106@phpwerx.net> References: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> <419E65DD.3060809@phpwerx.net> <419E6B37.3030106@phpwerx.net> Message-ID: Um, yeah.... that would do it :D Thank you -dan "Do what I meant, not what I said!" cain On Nov 19, 2004, at 3:52 PM, Dan Cech wrote: > Daniel J Cain Jr. wrote: >> Still getting the same warnings as before and the "DOH!" after >> changing the pattern to single quotes on my system > > You also have pattern and haystack reversed in the preg_match call ... > DOH indeed! > > Dan > >> On Nov 19, 2004, at 3:30 PM, Dan Cech wrote: >>> Use single quotes, the $ is screwing up the regex. >>> >>> $pattern = '/^quantity[1-9][0-9]{0,2}$/'; >>> >>> Dan >>> >> _______________________________________________ >> New York PHP Talk >> Supporting AMP Technology (Apache/MySQL/PHP) >> http://lists.nyphp.org/mailman/listinfo/talk >> http://www.newyorkphp.org > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From dcech at phpwerx.net Fri Nov 19 17:13:32 2004 From: dcech at phpwerx.net (Dan Cech) Date: Fri, 19 Nov 2004 17:13:32 -0500 Subject: [nycphp-talk] Regex & Delimiter Trouble In-Reply-To: References: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> <419E65DD.3060809@phpwerx.net> <419E6B37.3030106@phpwerx.net> Message-ID: <419E700C.20902@phpwerx.net> Daniel J Cain Jr. wrote: > Um, yeah.... that would do it :D > > Thank you Glad to be of assistance. Dan > -dan "Do what I meant, not what I said!" cain > > On Nov 19, 2004, at 3:52 PM, Dan Cech wrote: >> Daniel J Cain Jr. wrote: >>> Still getting the same warnings as before and the "DOH!" after >>> changing the pattern to single quotes on my system >> >> You also have pattern and haystack reversed in the preg_match call ... >> DOH indeed! >> >> Dan From sol2ray at gmail.com Fri Nov 19 17:07:43 2004 From: sol2ray at gmail.com (Sol Toure) Date: Fri, 19 Nov 2004 17:07:43 -0500 Subject: [nycphp-talk] Regex & Delimiter Trouble In-Reply-To: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> References: <27F4B132-3A70-11D9-B866-000A95BE1F8C@cain.sh> Message-ID: <4a67dc3904111914073eb911d2@mail.gmail.com> On Fri, 19 Nov 2004 15:15:36 -0600, Daniel J Cain Jr. wrote: > Given this script: > > $pattern = "/^quantity[1-9][0-9]{0,2}$/"; > $haystack = "quantity11"; > echo (preg_match($haystack, $pattern)) ? 'We got one!': 'DOH!', "\n"; > ?> It should be : preg_match($pattern, $haystack) From chsnyder at gmail.com Fri Nov 19 17:27:21 2004 From: chsnyder at gmail.com (csnyder) Date: Fri, 19 Nov 2004 17:27:21 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: <8d9a428004111913386d8e3b59@mail.gmail.com> References: <8d9a428004111913386d8e3b59@mail.gmail.com> Message-ID: Do you have the right enctype attribute in your
tag? enctype="multipart/form-data" From codebowl at gmail.com Fri Nov 19 17:36:57 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Fri, 19 Nov 2004 17:36:57 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: References: <8d9a428004111913386d8e3b59@mail.gmail.com> Message-ID: <8d9a42800411191436fa8f084@mail.gmail.com> yes i do :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From tommyo at gmail.com Fri Nov 19 16:41:03 2004 From: tommyo at gmail.com (Thomas O'Neill) Date: Fri, 19 Nov 2004 15:41:03 -0600 Subject: [nycphp-talk] PHP: Universal Document Conversion Message-ID: Hey Everyone, I have a client that would like to be able to take uploaded files in *any* format and convert them to a tiff file before storing them for later viewing. When I say ANY file format I mean most printable documents. I.E. WordPad, MS Word,MS Excell,Text, Unicode,PowerPoint,MS Project,MS Visio,HTML,PDF,JPEG,GIF,BMP,PNG,Lotus 1-2-3,Xerox,CorellDRAW, etc. I have found several windows programs that are print driver emulators that all users to print to the program in order to convert the document to a TIFF. There are also some of these programs that come with and SDK so that they can be programmed to. I am wondering if anyone on the list has done something similar to this using PHP? Doesn't need to be free, open source, GPL, or any thing like that. Just wanted to check if there was already something out there before i reinvent the wheel. Thanks a million! Tom O'Neill Bloomington, MN From codebowl at gmail.com Fri Nov 19 17:44:50 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Fri, 19 Nov 2004 17:44:50 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: <1100901291.31296.7.camel@tmelendez.int.bascom.com> References: <8d9a428004111913386d8e3b59@mail.gmail.com> <1100901291.31296.7.camel@tmelendez.int.bascom.com> Message-ID: <8d9a428004111914447091bc5b@mail.gmail.com> i am using xampp and in my /opt/lampp/etc/ i do not see a php.conf, i am checking httpd.conf for the value you requested and i do not see anything pertaining to that. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From mogmios at mlug.missouri.edu Fri Nov 19 17:52:52 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Fri, 19 Nov 2004 14:52:52 -0800 Subject: [nycphp-talk] PHP: Universal Document Conversion In-Reply-To: References: Message-ID: <419E7944.7010606@mlug.missouri.edu> >I have a client that would like to be able to take uploaded files in >*any* format and convert them to a tiff file before storing them for >later viewing. > >When I say ANY file format I mean most printable documents. I.E. > >WordPad, MS Word,MS Excell,Text, Unicode,PowerPoint,MS Project,MS >Visio,HTML,PDF,JPEG,GIF,BMP,PNG,Lotus 1-2-3,Xerox,CorellDRAW, etc. > >I have found several windows programs that are print driver emulators >that all users to print to the program in order to convert the >document to a TIFF. > >There are also some of these programs that come with and SDK so that >they can be programmed to. > >I am wondering if anyone on the list has done something similar to >this using PHP? Doesn't need to be free, open source, GPL, or any >thing like that. Just wanted to check if there was already something >out there before i reinvent the wheel. > > Looked at Ghostscript? It has filters for turning just about anything into a postscript file. Then postscript is easy enough to convert to tiff files. I think ImageMagick can do that if Ghostscript can't. You could just tap your code into those. -- Michael http://kavlon.org From codebowl at gmail.com Sat Nov 20 07:25:29 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sat, 20 Nov 2004 07:25:29 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: <8d9a428004111914447091bc5b@mail.gmail.com> References: <8d9a428004111913386d8e3b59@mail.gmail.com> <1100901291.31296.7.camel@tmelendez.int.bascom.com> <8d9a428004111914447091bc5b@mail.gmail.com> Message-ID: <8d9a428004112004254905ec8@mail.gmail.com> i have still not resolved this is anyone has any furthur ideas? -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From codebowl at gmail.com Sat Nov 20 07:59:39 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Sat, 20 Nov 2004 07:59:39 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: <8d9a428004112004254905ec8@mail.gmail.com> References: <8d9a428004111913386d8e3b59@mail.gmail.com> <1100901291.31296.7.camel@tmelendez.int.bascom.com> <8d9a428004111914447091bc5b@mail.gmail.com> <8d9a428004112004254905ec8@mail.gmail.com> Message-ID: <8d9a4280041120045973d2e128@mail.gmail.com> UPDATE: problem solved, i also learned a very good lesson. When using XAMPP and you do not have your temp upload dir set in your php.ini, do not assume it uses /tmp i was doing this and having loads of problems, however once i set the dir in php.ini to /tmp it is now working 100% correctly :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From webmaster at localnotion.com Sat Nov 20 12:18:24 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Sat, 20 Nov 2004 12:18:24 -0500 Subject: [nycphp-talk] (no subject) Message-ID: <2F8A9D72-3B18-11D9-A001-0003938BDF32@localnotion.com> Assuming a certain php script was the only thing accessing a postgres DB. if I: insert into DB; select from DB to get the current value of a sequence ; Can I assume I will get the value I'm looking for? Or might this happen: insert into DB; another script instance does an insert; select brings back second and wrong value for my needs; This is really a question of how the PHP engine works, and I am aware of different ways of serializing with MySQL, but to my knowledge, those methods are not available for Postgres. Enlighten me here as well. Oh, I do also know this is a great place to create a stored procedure, which would atomize it. Matt From jayeshsh at ceruleansky.com Sat Nov 20 12:42:27 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Sat, 20 Nov 2004 12:42:27 -0500 (EST) Subject: [nycphp-talk] getting last inserted id with PostgreSQL Message-ID: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> Hi Matt, In response to your question about getting the last id inserted into a table (on a per connection basis), these documents may be relevant: http://archives.postgresql.org/pgsql-general/2003-08/msg01699.php http://www.postgresql.org/docs/7.3/static/functions-sequence.html I have not used PostgreSQL myself yet, but as far as I can tell, these documents may help. More specifically, it is the "currval" part you should be looking at. An excerpt (from the first link above): " Basicly, currval() gives the last id for that sequence in that session. So other sessions does not break anything. > The only safe methode would be to do a "select nextval(whatever)", and > aply this number by "hand" to the insert, but that remove the > possibility to make general code even more, but it will be safe. It's not needed. The following works fine (if the tables exists of course) and has no problems with concurrency: INSERT INTO foo(id,x) VALUES (DEFAULT, 'value'); INSERT INTO bar(id,foo_ref) VALUES (DEFAULT, currval('foo_id_seq')); " As I found out from the new MySQL book from Apress, you can find out the last inserted id for a particular connection only using the following technique: " When a new AUTO_INCREMENT value has been generated, you can also obtain it by executing a SELECT LAST_INSERT_ID() statement mysql_query() and retrieving the value from the result set returned by the statement. For LAST_INSERT_ID(), the most recently generated ID is maintained in the server on a per-connection basis. It will not be changed by another client. It will not even be changed if you update another AUTO_INCREMENT column with a non-magic value (that is, a value that is not NULL and not 0). If you want to use the ID that was generated for one table and insert it into a second table, you can use SQL statements like this: INSERT INTO foo (auto,text) VALUES(NULL,'text'); # generate ID by inserting NULL INSERT INTO foo2 (id,text) VALUES(LAST_INSERT_ID(),'text'); # use ID in second table " (More info on this at: http://dev.mysql.com/doc/mysql/en/Getting_unique_ID.html ) Hope all that helps and is what you were looking for. - Jay From mitch.pirtle at gmail.com Sat Nov 20 13:02:43 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Sat, 20 Nov 2004 13:02:43 -0500 Subject: [nycphp-talk] (no subject) In-Reply-To: <2F8A9D72-3B18-11D9-A001-0003938BDF32@localnotion.com> References: <2F8A9D72-3B18-11D9-A001-0003938BDF32@localnotion.com> Message-ID: <330532b604112010026b6bc3ea@mail.gmail.com> One thing you can do is get the value from that sequence, and use it in your INSERT statement. That way you won't have to guess ;-) -- Mitch On Sat, 20 Nov 2004 12:18:24 -0500, Matthew Terenzio wrote: > Assuming a certain php script was the only thing accessing a postgres > DB. > > if I: > > insert into DB; > select from DB to get the current value of a sequence ; > > Can I assume I will get the value I'm looking for? From webmaster at localnotion.com Sat Nov 20 13:17:08 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Sat, 20 Nov 2004 13:17:08 -0500 Subject: [nycphp-talk] getting last inserted id with PostgreSQL In-Reply-To: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> References: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> Message-ID: <63BF8383-3B20-11D9-A001-0003938BDF32@localnotion.com> On Nov 20, 2004, at 12:42 PM, Jayesh Sheth wrote: > It's not needed. The following works fine (if the tables exists of > course) > and has no problems with concurrency: > > INSERT INTO foo(id,x) VALUES (DEFAULT, 'value'); > INSERT INTO bar(id,foo_ref) VALUES (DEFAULT, currval('foo_id_seq')); This is what I wanted to know. If this is safe, all is good. Thanks From webmaster at localnotion.com Sat Nov 20 13:25:26 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Sat, 20 Nov 2004 13:25:26 -0500 Subject: [nycphp-talk] getting last inserted id with PostgreSQL In-Reply-To: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> References: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> Message-ID: <8CC76239-3B21-11D9-A001-0003938BDF32@localnotion.com> On Nov 20, 2004, at 12:42 PM, Jayesh Sheth wrote: > Basicly, currval() gives the last id for that sequence in that > session. So > other sessions does not break anything. I guess the only doubt lingering is whether using a persistent connection method from PHP will make a DB think one session is happening even though any number of pages might be borrowing the connection. Does anyone know the lowdown on this? From mitch.pirtle at gmail.com Sat Nov 20 13:31:40 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Sat, 20 Nov 2004 13:31:40 -0500 Subject: [nycphp-talk] getting last inserted id with PostgreSQL In-Reply-To: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> References: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> Message-ID: <330532b60411201031c8d3487@mail.gmail.com> On Sat, 20 Nov 2004 12:42:27 -0500 (EST), Jayesh Sheth wrote: > In response to your question about getting the last id inserted into a > table (on a per connection basis), these documents may be relevant: > > http://archives.postgresql.org/pgsql-general/2003-08/msg01699.php > http://www.postgresql.org/docs/7.3/static/functions-sequence.html > > I have not used PostgreSQL myself yet, but as far as I can tell, these > documents may help. More specifically, it is the "currval" part you should > be looking at. >From what I've seen, there's really only two ways to do this - the MySQL way (using auto_increment) and the non-MySQL way (using sequence values). I always thought the MySQL way was the simplest and easiest to use from a programmatic perspective, but the more time I worked on web applications (weblications?) the more I came to appreciate sequences. When you get the value from a sequence, it immediately increments itself. This is also a singular transaction, which ensures that only you will get that value from the sequence. With MySQL and auto_increment, there is the possibility for an insert to happen before you get your value, correct? Not a dig at MySQL, just wanting clarification on the atomicity of doing an insert and then getting the last value from the auto_increment fields... -- Mitch From chsnyder at gmail.com Sat Nov 20 14:16:27 2004 From: chsnyder at gmail.com (csnyder) Date: Sat, 20 Nov 2004 14:16:27 -0500 Subject: [nycphp-talk] PHP: Universal Document Conversion In-Reply-To: <419E7944.7010606@mlug.missouri.edu> References: <419E7944.7010606@mlug.missouri.edu> Message-ID: Is TIFF really the universal file format? I guess it is if you only want to view the documents, but if you ever want to recover the content, it's kind of a horrible idea. I like Michael's Ghostscript idea -- anything that you can print from Linux can be "printed" to a postscript file. Postscript preserves the look of the document (like TIFF would) but also allows the text to be extracted. The collection of software and the PHP glue to bind it all together probably doesn't exist yet. But I bet a lot of people on this list have pieces of it already. This would be an excellent open-source project. From 1j0lkq002 at sneakemail.com Sun Nov 21 00:07:38 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Sun, 21 Nov 2004 00:07:38 -0500 Subject: [nycphp-talk] Anyone used ActiveWidgets grid tool? In-Reply-To: References: <419E7944.7010606@mlug.missouri.edu> Message-ID: <19234-57473@sneakemail.com> I'm interested in opinions/experience. Thanks in advance! http://www.activewidgets.com/grid/ From jayeshsh at ceruleansky.com Sun Nov 21 00:56:22 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Sun, 21 Nov 2004 00:56:22 -0500 (EST) Subject: [nycphp-talk] PEAR XML-RPC server does not like carriage returns (details enclosed) Message-ID: <46276.69.86.84.233.1101016582.spork@webmail.ceruleansky.com> Hello everyone, Some of you may remember my presentation at NYPHP from June of this year (2004) [ http://www.moztips.com/index.php?id=335 ]. I released the code to an earlier version of fortune cookies code at moztips.com [ http://www.moztips.com/index.php?id=266 ]. Some people who were using versions of PHP greater than 4.3.5 experienced errors on the JavaScript side (e.g. "someThing is not a function"). In reality, these were caused by errors / XML-RPC faults triggerd by the PEAR XML-RPC server. I have done a lot of debugging since, and here is what I have found: The JavaScript XML-RPC client, jsolait [ http://xmlrpc.kollhof.net/index.xhtml ] sends the following bit of XML as the initial HTTP request, asking the XML-RPC server which methods it supports (If this message gets mangled, full details (including PHP code) are posted online at: http://www.moztips.com/debug2/ ): POST /xul_lessons/debug2/debugserver.php HTTP/1.1 Host: localhost User-Agent: PEAR HTTP_Request class ( http://pear.php.net/ ) Connection: close Content-Type: text/xml Content-Length: 95 system.listMethods Then the server replies: HTTP/1.1 200 OK Date: Sun, 21 Nov 2004 04:32:09 GMT Server: Apache/2.0.52 (Win32) mod_ssl/2.0.52 OpenSSL/0.9.7c PHP/4.3.9 X-Powered-By: PHP/4.3.9 Content-Length: 360 Connection: close Content-Type: text/xml echoEcho system.listMethods system.methodHelp system.methodSignature ------ ------- -------- But, if the same initial HTTP request is sent with line breaks / carriage returns after each XML tag, an error is produced. Here is the request: POST /xul_lessons/debug2/debugserver.php HTTP/1.1 Host: localhost User-Agent: PEAR HTTP_Request class ( http://pear.php.net/ ) Connection: close Content-Type: text/xml Content-Length: 89 system.listMethods And here is the response: HTTP/1.1 200 OK Date: Sun, 21 Nov 2004 04:33:18 GMT Server: Apache/2.0.52 (Win32) mod_ssl/2.0.52 OpenSSL/0.9.7c PHP/4.3.9 X-Powered-By: PHP/4.3.9 Content-Length: 362 Connection: close Content-Type: text/xml faultCode 1 faultString Unknown method ------- ------ ------ Does anyone know why this is happening? Incidentally, I tried this at moztips.com and I was able to reproduce the error. But the thing is, the NYPHP presentation hosted at moztips.com currently works. So, after all this debugging, I don't know if I found the right error after all. Another interesting thing is that the PEAR XML-RPC library, when acting as a client sends an extra pair of empty "" tags along with intitial request. Full code, including a test-case debug client and server that logs the HTTP requests and response is available at: http://www.moztips.com/debug2/ If anyone can help me with this, I will buy you a drink of your choice at the next NYPHP talk-dinner! Thanks in advance, - Jay From fields at surgam.net Sun Nov 21 01:23:19 2004 From: fields at surgam.net (Adam Fields) Date: Sun, 21 Nov 2004 01:23:19 -0500 Subject: [nycphp-talk] Some loser stole Rasmus's laptop at a PHP conference! Message-ID: <20041121062319.GB2493@lola.aquick.org> http://toys.lerdorf.com/archives/24-1-T42p-toy.html -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From tom at supertom.com Sun Nov 21 10:02:47 2004 From: tom at supertom.com (Tom) Date: Sun, 21 Nov 2004 10:02:47 -0500 Subject: [nycphp-talk] Anyone used ActiveWidgets grid tool? In-Reply-To: <19234-57473@sneakemail.com> Message-ID: <0I7J007SMADJ99@mta8.srv.hcvlny.cv.net> I'd be interested in this too, although I already notice that the grid lines for the employee column (only) are not showing up on Firefox on win2k for me. I wonder if it supports Mac Safari or even worse yet Mac IE. Tom www.liphp.org -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On Behalf Of inforequest Sent: Sunday, November 21, 2004 12:08 AM To: talk at lists.nyphp.org Subject: [nycphp-talk] Anyone used ActiveWidgets grid tool? I'm interested in opinions/experience. Thanks in advance! http://www.activewidgets.com/grid/ _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org From tom at supertom.com Sun Nov 21 10:28:38 2004 From: tom at supertom.com (Tom) Date: Sun, 21 Nov 2004 10:28:38 -0500 Subject: [nycphp-talk] Uploading file with PHP In-Reply-To: <8d9a428004111914447091bc5b@mail.gmail.com> Message-ID: <0I7J004OSBKL5K@mta2.srv.hcvlny.cv.net> Hi Joseph, These are all possible options from php.ini that can effect upload. I downloaded xampp myself and took them from their php.ini, so doubt you are having a problem with these, but just putting them in for a sanity check: memory_limit = 8M upload_max_filesize = 2M post_max_size = 8M file_uploads = On ;upload_tmp_dir = (make sure this is writeable by the User the web server is running as) max_execution_time = 30 Now, pertaining to the LimitRequestBody Directive: I have Apache 2x on Redhat 9, and I have a /etc/httpd/conf/conf.d directory, and inside of there I have a php.conf file. In that file I have this: SetOutputFilter PHP SetInputFilter PHP LimitRequestBody 524288 I know for certain that if you don't adjust the limitrequestbody attribute, you won't be able to upload files larger than this number. On this page: http://us2.php.net/features.file-upload A fellow mentions adding this to his *httpd.conf* file. Make sure to adjust the number to be larger than your upload. You'll need to make a block like this for every extension you want PHP to handle, so if you are having PHP process .html files, you'll need one that says Files *.html. Also see here: http://forums.invisionpower.com/lofiversion/index.php/t115421.html If it is not this, I'm out of ideas. Good Luck! Tom Long Island PHP Users Group http://www.liphp.org -----Original Message----- From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] On Behalf Of Joseph Crawford Sent: Friday, November 19, 2004 5:45 PM To: NYPHP Talk Subject: Re: [nycphp-talk] Uploading file with PHP i am using xampp and in my /opt/lampp/etc/ i do not see a php.conf, i am checking httpd.conf for the value you requested and i do not see anything pertaining to that. -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST _______________________________________________ New York PHP Talk Supporting AMP Technology (Apache/MySQL/PHP) http://lists.nyphp.org/mailman/listinfo/talk http://www.newyorkphp.org From adam at trachtenberg.com Sun Nov 21 14:15:41 2004 From: adam at trachtenberg.com (Adam Maccabee Trachtenberg) Date: Sun, 21 Nov 2004 14:15:41 -0500 (EST) Subject: [nycphp-talk] getting last inserted id with PostgreSQL In-Reply-To: <330532b60411201031c8d3487@mail.gmail.com> References: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> <330532b60411201031c8d3487@mail.gmail.com> Message-ID: On Sat, 20 Nov 2004, Mitch Pirtle wrote: > With MySQL and auto_increment, there is the possibility for an insert > to happen before you get your value, correct? > > Not a dig at MySQL, just wanting clarification on the atomicity of > doing an insert and then getting the last value from the > auto_increment fields... False. MySQL will return the correct value, even if other threads have inserted new rows between your initial insert and the call to get the primary key. -adam -- adam at trachtenberg.com author of o'reilly's "upgrading to php 5" and "php cookbook" avoid the holiday rush, buy your copies today! From jayeshsh at ceruleansky.com Sun Nov 21 15:21:26 2004 From: jayeshsh at ceruleansky.com (Jayesh Sheth) Date: Sun, 21 Nov 2004 15:21:26 -0500 (EST) Subject: [nycphp-talk] PEAR XML-RPC server does not like carriage returns (details enclosed) Message-ID: <49349.69.86.84.233.1101068486.spork@webmail.ceruleansky.com> Hi all, I think I found the bug report that might be relevant to the issue I am describing: http://pear.php.net/bugs/bug.php?id=1604 This might be of use to others who want to patch the PEAR XML-RPC library themselves (or install a renamed, modified one locally to use along with theirs scripts). I have a feel though that other bugs are working in collusion with this one to prevent the jsolait JavaScript XML-RPC client library from working correctly with the PEAR XML-RPC server library on PHP versions of 4.3.5 and higher. If anyone has insight into (the nuances and contributing factors to) this issue, I would greatly appreciate this. (I should probably offer a better "reward" to the smart PHP developers out there: how about a whole pie of Brooklyn-made Grandmama's pizza for the first person who has insight into this one.) Thanks, - Jay From mitch.pirtle at gmail.com Sun Nov 21 16:19:28 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Sun, 21 Nov 2004 16:19:28 -0500 Subject: [nycphp-talk] getting last inserted id with PostgreSQL In-Reply-To: References: <32965.69.86.84.233.1100972547.spork@webmail.ceruleansky.com> <330532b60411201031c8d3487@mail.gmail.com> Message-ID: <330532b6041121131926664ba3@mail.gmail.com> Thanks for the correction Adam, I was wondering about that. -- Mitch On Sun, 21 Nov 2004 14:15:41 -0500 (EST), Adam Maccabee Trachtenberg wrote: > On Sat, 20 Nov 2004, Mitch Pirtle wrote: > > > With MySQL and auto_increment, there is the possibility for an insert > > to happen before you get your value, correct? > > False. MySQL will return the correct value, even if other threads have > inserted new rows between your initial insert and the call to get the > primary key. From suzerain at suzerain.com Mon Nov 22 13:12:03 2004 From: suzerain at suzerain.com (Marc Antony Vose) Date: Mon, 22 Nov 2004 13:12:03 -0500 Subject: [nycphp-talk] turning off postgresql support Message-ID: hi there: i posted late last week about getting this error when i run php from the commandline: PHP Warning: Unknown(): Unable to load dynamic library '/usr/lib/php4/pgsql.so' - libpq.so.3: cannot open shared object file: No such file or directory in Unknown on line 0 a few people told me to disable postgresql in the php.ini file, but after looking through that file, and doing a web search, i can't seem to figure out how to do that. i can see how to change various postgresql settings, but not how to disable it entirely. so, though this seems like a really stupid question, can someone enlighten me as to what i need to set in a custom php.ini file? cheers, -- Marc Antony Vose http://www.suzerain.com/ The cost of liberty is less than the price of repression. -- W.E.B. Du Bois From ajai at bitblit.net Mon Nov 22 13:44:07 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Mon, 22 Nov 2004 13:44:07 -0500 Subject: [nycphp-talk] turning off postgresql support In-Reply-To: References: Message-ID: <41A23377.5050706@bitblit.net> Marc Antony Vose wrote: > a few people told me to disable postgresql in the php.ini file, but > after looking through that file, and doing a web search, i can't seem > to figure out how to do that. i can see how to change various > postgresql settings, but not how to disable it entirely. > > so, though this seems like a really stupid question, can someone > enlighten me as to what i need to set in a custom php.ini file? Did you try simply commenting out the PostgresSQL section??? -- Aj. Systems Administrator / Developer From hans at nyphp.com Mon Nov 22 14:16:02 2004 From: hans at nyphp.com (Hans Zaunere) Date: Mon, 22 Nov 2004 11:16:02 -0800 Subject: [nycphp-talk] turning off postgresql support Message-ID: <41EE526EC2D3C74286415780D3BA9F8705F53767@ehost011-1.exch011.intermedia.net> > i posted late last week about getting this error when i run php from > the commandline: > > PHP Warning: Unknown(): Unable to load dynamic library > '/usr/lib/php4/pgsql.so' - libpq.so.3: cannot open shared object > file: No such file or directory in Unknown on line 0 > > a few people told me to disable postgresql in the php.ini file, but > after looking through that file, and doing a web search, i can't seem > to figure out how to do that. i can see how to change various > postgresql settings, but not how to disable it entirely. > > so, though this seems like a really stupid question, can someone > enlighten me as to what i need to set in a custom php.ini file? If anything, it'd be the 'extension' directive in php.ini, although this still might not make any difference. If I remember correctly, this still might not work, depending on how it was compiled. Run: ldd /path/to/php/bin/php and maybe you'll see libpq listed, in which case you'd need to recompile. Although, I could also be forgetting something. And some more stuff: http://us2.php.net/manual/en/function.dl.php --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From chsnyder at gmail.com Mon Nov 22 15:09:50 2004 From: chsnyder at gmail.com (csnyder) Date: Mon, 22 Nov 2004 15:09:50 -0500 Subject: [nycphp-talk] turning off postgresql support In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705F53767@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705F53767@ehost011-1.exch011.intermedia.net> Message-ID: Yeah, I'm pretty sure they were talking about Windows .dll directives. What about compiling your own php binary without pgsql support? From j at nybg.org Tue Nov 23 08:32:02 2004 From: j at nybg.org (Freeman, Joshua) Date: Tue, 23 Nov 2004 08:32:02 -0500 Subject: [nycphp-talk] shopping cart solution Message-ID: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> It's time for me to go shopping for a shopping cart solution. The goal is to find or buy something to integrate into our current visitor website (http://www.nybg.org) to replace this third-part, externally hosted store at http://www.shopinthegarden.com). Ideally, we'd find something that we can easily sync up with our existing on-site retail inventory management system (WinRetail from JDS Solutions.. runs on 'doze with MS-SQL on the backend...) Found OSCommerce and Ext-cart so far... any other recommendations out there folks? It has to be something fairly 'serious', commercial class.. etc.. TIA, J. -------------- next part -------------- A non-text attachment was scrubbed... Name: winmail.dat Type: application/ms-tnef Size: 2523 bytes Desc: not available URL: From yury at heavenspa.com Tue Nov 23 09:01:41 2004 From: yury at heavenspa.com (Yury Rush) Date: Tue, 23 Nov 2004 09:01:41 -0500 Subject: [nycphp-talk] RE: shopping cart solution In-Reply-To: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> Message-ID: x-cart.com pretty nice. yury www.bimmertalk.com -----Original Message----- From: Freeman, Joshua [mailto:talk-bounces at lists.nyphp.org]On Behalf Of Freeman, Joshua Sent: Tuesday, November 23, 2004 8:32 AM To: NYPHP Talk Subject: shopping cart solution It's time for me to go shopping for a shopping cart solution. The goal is to find or buy something to integrate into our current visitor website (http://www.nybg.org) to replace this third-part, externally hosted store at http://www.shopinthegarden.com). Ideally, we'd find something that we can easily sync up with our existing on-site retail inventory management system (WinRetail from JDS Solutions.. runs on 'doze with MS-SQL on the backend...) Found OSCommerce and Ext-cart so far... any other recommendations out there folks? It has to be something fairly 'serious', commercial class.. etc.. TIA, J. -------------- next part -------------- A non-text attachment was scrubbed... Name: winmail.dat Type: application/ms-tnef Size: 1052 bytes Desc: not available URL: From codebowl at gmail.com Tue Nov 23 09:33:15 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 23 Nov 2004 09:33:15 -0500 Subject: [nycphp-talk] RE: shopping cart solution In-Reply-To: References: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> Message-ID: <8d9a42800411230633138c970@mail.gmail.com> i second the X-Cart shopping cart :D or a custom solution :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From ajai at bitblit.net Tue Nov 23 09:55:23 2004 From: ajai at bitblit.net (Ajai Khattri) Date: Tue, 23 Nov 2004 09:55:23 -0500 Subject: [nycphp-talk] shopping cart solution In-Reply-To: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> References: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> Message-ID: <41A34F5B.7070601@bitblit.net> Freeman, Joshua wrote: >It's time for me to go shopping for a shopping cart solution. The goal is to find or buy something to integrate into our current visitor website (http://www.nybg.org) to replace this third-part, externally hosted store at http://www.shopinthegarden.com). > >Ideally, we'd find something that we can easily sync up with our existing on-site retail inventory management system (WinRetail from JDS Solutions.. runs on 'doze with MS-SQL on the backend...) > > >Found OSCommerce and Ext-cart so far... any other recommendations out there folks? > >It has to be something fairly 'serious', commercial class.. etc.. > Mambo + mambo-phpshop http://mamboserver.com http://www.mambo-phpshop.net -- Aj. Systems Administrator / Developer From list at harveyk.com Tue Nov 23 10:18:32 2004 From: list at harveyk.com (harvey) Date: Tue, 23 Nov 2004 10:18:32 -0500 Subject: [nycphp-talk] Trim In-Reply-To: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> References: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> Message-ID: <6.2.0.14.0.20041123100431.04fac8c8@mail.harveyk.com> Hi, I'm trying to 'normalize' phone numbers that are submitted via a form, so that they all appear as xxx-xxx-xxxx. I'm sure there's a more elegant way of doing it, but the following seems to work-- almost. But the trim part does not actually trim. I'm sure it has something to do with the type/case of the content submitted or the quotation marks or something like that. If I replace the GetSQL statement with ' (212) 555-1212 ', it works fine. I tried dropping the GetSQL and just using the $_Post, tried putting single and double quotes, etc. Any ideas? Thanks! $phone = GetSQLValueString($_POST['phone'],"text"); $phone = trim($phone); $replace = array (") ","."," "); $newphone = str_replace($replace,"-",$phone); $newphone = str_replace("(","",$newphone); This is the GetSQLValueString function that Dreamweaver creates automatically: function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "") { $theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : $theValue; switch ($theType) { case "text": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "long": case "int": $theValue = ($theValue != "") ? intval($theValue) : "NULL"; break; case "double": $theValue = ($theValue != "") ? "'" . doubleval($theValue) . "'" : "NULL"; break; case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL"; break; case "defined": $theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue; break; } return $theValue; } From carlos at sprout.net Tue Nov 23 10:10:07 2004 From: carlos at sprout.net (Carlos G. Chiossone) Date: Tue, 23 Nov 2004 10:10:07 -0500 Subject: [nycphp-talk] RE: shopping cart solution Message-ID: <49A9DEB886049242BA28C484A36C03F19DF8B2@email.sprout.net> Intershop is commercial class and serious but a fair pain in the ass to integrate with outside solutions unless cartridges are already made or customized for you. Possibly in the 30K investment to develop. Carlos Chiossone www.sprout.net www.readysites.com -----Original Message----- From: Freeman, Joshua [mailto:talk-bounces at lists.nyphp.org] On Behalf Of Freeman, Joshua Sent: Tuesday, November 23, 2004 8:32 AM To: NYPHP Talk Subject: shopping cart solution It's time for me to go shopping for a shopping cart solution. The goal is to find or buy something to integrate into our current visitor website (http://www.nybg.org) to replace this third-part, externally hosted store at http://www.shopinthegarden.com). Ideally, we'd find something that we can easily sync up with our existing on-site retail inventory management system (WinRetail from JDS Solutions.. runs on 'doze with MS-SQL on the backend...) Found OSCommerce and Ext-cart so far... any other recommendations out there folks? It has to be something fairly 'serious', commercial class.. etc.. TIA, J. From ben at atlphp.org Tue Nov 23 10:22:51 2004 From: ben at atlphp.org (Ben Ramsey) Date: Tue, 23 Nov 2004 10:22:51 -0500 Subject: [nycphp-talk] Trim In-Reply-To: <6.2.0.14.0.20041123100431.04fac8c8@mail.harveyk.com> References: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> <6.2.0.14.0.20041123100431.04fac8c8@mail.harveyk.com> Message-ID: <41A355CB.4060708@atlphp.org> Try this link and see if it helps you easily capture the phone number data: http://benramsey.com/archive/cat/making_it_valid/making_it_valid_telephone_numbers.php Then, after using the code at that link, just do: $newphone = $area_code . '-' . $exchange . '-' . $number; That should do it for you. harvey wrote: > Hi, I'm trying to 'normalize' phone numbers that are submitted via a > form, so that they all appear as xxx-xxx-xxxx. I'm sure there's a more > elegant way of doing it, but the following seems to work-- almost. But > the trim part does not actually trim. I'm sure it has something to do > with the type/case of the content submitted or the quotation marks or > something like that. If I replace the GetSQL statement with ' (212) > 555-1212 ', it works fine. I tried dropping the GetSQL and just using > the $_Post, tried putting single and double quotes, etc. Any ideas? Thanks! > > $phone = GetSQLValueString($_POST['phone'],"text"); > $phone = trim($phone); > $replace = array (") ","."," "); > $newphone = str_replace($replace,"-",$phone); > $newphone = str_replace("(","",$newphone); > > > This is the GetSQLValueString function that Dreamweaver creates > automatically: > > function GetSQLValueString($theValue, $theType, $theDefinedValue = "", > $theNotDefinedValue = "") > { $theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : > $theValue; > switch ($theType) { > case "text": $theValue = ($theValue != "") ? "'" . $theValue . "'" : > "NULL"; break; > case "long": > case "int": $theValue = ($theValue != "") ? intval($theValue) : > "NULL"; break; > case "double": $theValue = ($theValue != "") ? "'" . > doubleval($theValue) . "'" : "NULL"; break; > case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : > "NULL"; break; > case "defined": $theValue = ($theValue != "") ? $theDefinedValue : > $theNotDefinedValue; break; } > return $theValue; } -- Ben Ramsey Atlanta PHP http://atlphp.org http://benramsey.com From krook at us.ibm.com Tue Nov 23 10:27:20 2004 From: krook at us.ibm.com (Daniel Krook) Date: Tue, 23 Nov 2004 10:27:20 -0500 Subject: [nycphp-talk] PHP in odd places Message-ID: I've seen it in odder places, but just noticed these two this morning. :) http://www.websphere.org/index.php http://supportforum.sun.com/index.php Daniel Krook, Application Developer WW Web Production Services North 2, ibm.com 1133 Westchester Avenue, White Plains, NY 10604 Personal: http://info.krook.org/ Persona: http://w3.ibm.com/eworkplace/persona_bp_finder.jsp?CNUM=9A9796897 From codebowl at gmail.com Tue Nov 23 10:33:59 2004 From: codebowl at gmail.com (Joseph Crawford) Date: Tue, 23 Nov 2004 10:33:59 -0500 Subject: [nycphp-talk] PHP in odd places In-Reply-To: References: Message-ID: <8d9a428004112307337fbe341b@mail.gmail.com> funny how not even sun uses JSP :D -- Joseph Crawford Jr. Codebowl Solutions codebowl at gmail.com For a GMail account contact me OFF-LIST From hans at nyphp.com Tue Nov 23 10:36:18 2004 From: hans at nyphp.com (Hans Zaunere) Date: Tue, 23 Nov 2004 07:36:18 -0800 Subject: [nycphp-talk] PHP in odd places Message-ID: <41EE526EC2D3C74286415780D3BA9F8705F540A0@ehost011-1.exch011.intermedia.net> > I've seen it in odder places, but just noticed these two this morning. :) > > http://www.websphere.org/index.php > http://supportforum.sun.com/index.php Very cool - we should maintain a list on NYPHP of all the odd places PHP is found :) H From ben at atlphp.org Tue Nov 23 10:48:03 2004 From: ben at atlphp.org (Ben Ramsey) Date: Tue, 23 Nov 2004 10:48:03 -0500 Subject: [nycphp-talk] PHP in odd places In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705F540A0@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705F540A0@ehost011-1.exch011.intermedia.net> Message-ID: <41A35BB3.1070005@atlphp.org> Hans Zaunere wrote: > Very cool - we should maintain a list on NYPHP of all the odd places PHP > is found :) That's because it appears they're using FUDforum to power their message boards instead of something proprietary. -- Ben Ramsey Atlanta PHP http://atlphp.org http://benramsey.com From chsnyder at gmail.com Tue Nov 23 10:53:34 2004 From: chsnyder at gmail.com (csnyder) Date: Tue, 23 Nov 2004 10:53:34 -0500 Subject: [nycphp-talk] PHP in odd places In-Reply-To: <41EE526EC2D3C74286415780D3BA9F8705F540A0@ehost011-1.exch011.intermedia.net> References: <41EE526EC2D3C74286415780D3BA9F8705F540A0@ehost011-1.exch011.intermedia.net> Message-ID: Reminds me of the ASP homepage NYPHP had one April 1st... From list at harveyk.com Tue Nov 23 11:30:12 2004 From: list at harveyk.com (harvey) Date: Tue, 23 Nov 2004 11:30:12 -0500 Subject: [nycphp-talk] Trim In-Reply-To: <41A355CB.4060708@atlphp.org> References: <319FD9EAB7A43E43895ACA5AA1F81E05F88743@xmail.nybg.org> <6.2.0.14.0.20041123100431.04fac8c8@mail.harveyk.com> <41A355CB.4060708@atlphp.org> Message-ID: <6.2.0.14.0.20041123112906.04f94810@mail.harveyk.com> Thanks. With a little tweaking, I think I got the code you referenced to work. At Tuesday 11/23/2004 10:22 AM, Ben Ramsey wrote: >Try this link and see if it helps you easily capture the phone number data: >http://benramsey.com/archive/cat/making_it_valid/making_it_valid_telephone_numbers.php > >Then, after using the code at that link, just do: >$newphone = $area_code . '-' . $exchange . '-' . $number; > >That should do it for you. > > >harvey wrote: >>Hi, I'm trying to 'normalize' phone numbers that are submitted via a >>form, so that they all appear as xxx-xxx-xxxx. I'm sure there's a more >>elegant way of doing it, but the following seems to work-- almost. But >>the trim part does not actually trim. I'm sure it has something to do >>with the type/case of the content submitted or the quotation marks or >>something like that. If I replace the GetSQL statement with ' (212) >>555-1212 ', it works fine. I tried dropping the GetSQL and just using >>the $_Post, tried putting single and double quotes, etc. Any ideas? Thanks! >> $phone = GetSQLValueString($_POST['phone'],"text"); >> $phone = trim($phone); >> $replace = array (") ","."," "); >> $newphone = str_replace($replace,"-",$phone); >> $newphone = str_replace("(","",$newphone); >> >>This is the GetSQLValueString function that Dreamweaver creates >>automatically: >>function GetSQLValueString($theValue, $theType, $theDefinedValue = "", >>$theNotDefinedValue = "") >>{ $theValue = (!get_magic_quotes_gpc()) ? addslashes($theValue) : $theValue; >> switch ($theType) { >> case "text": $theValue = ($theValue != "") ? "'" . $theValue . "'" : >> "NULL"; break; >> case "long": >> case "int": $theValue = ($theValue != "") ? intval($theValue) : >> "NULL"; break; >> case "double": $theValue = ($theValue != "") ? "'" . >> doubleval($theValue) . "'" : "NULL"; break; >> case "date": $theValue = ($theValue != "") ? "'" . $theValue . "'" : >> "NULL"; break; >> case "defined": $theValue = ($theValue != "") ? $theDefinedValue : >> $theNotDefinedValue; break; } >> return $theValue; } > >-- >Ben Ramsey >Atlanta PHP >http://atlphp.org >http://benramsey.com >_______________________________________________ >New York PHP Talk >Supporting AMP Technology (Apache/MySQL/PHP) >http://lists.nyphp.org/mailman/listinfo/talk >http://www.newyorkphp.org From faber at linuxnj.com Tue Nov 23 12:36:19 2004 From: faber at linuxnj.com (Faber Fedor) Date: Tue, 23 Nov 2004 12:36:19 -0500 Subject: [nycphp-talk] Business day calculations Message-ID: <20041123173619.GA30652@uranus.faber.nom> Before I go and reinvent the wheel... I need to do things like getPreviousBusinessDay() and getLastBusinessDayofMonth() in a PHP-based dashboard I'm writing. I Googled for such code and checked out PEAR but I didn't find anything appropriate. Am I missing something or has a PHP programmer never needed to do a getPreviousBusinessDay() type function before? -- Regards, Faber Linux New Jersey: Open Source Solutions for New Jersey http://www.linuxnj.com From scott at crisscott.com Tue Nov 23 13:23:12 2004 From: scott at crisscott.com (Scott Mattocks) Date: Tue, 23 Nov 2004 13:23:12 -0500 Subject: [nycphp-talk] Business day calculations In-Reply-To: <20041123173619.GA30652@uranus.faber.nom> References: <20041123173619.GA30652@uranus.faber.nom> Message-ID: <41A38010.3080701@crisscott.com> Try PEAR::Date There is getNextWeekday() and getPrevWeekday(). To get the last business day of the month you may have to combine a few calls but there should be enough there to get what you need without having to reinvent everything. http://pear.php.net/package/Date/docs/1.4.2/Date/Date.html#methodgetNextWeekday Scott Mattocks Faber Fedor wrote: > Before I go and reinvent the wheel... > > I need to do things like getPreviousBusinessDay() and > getLastBusinessDayofMonth() in a PHP-based dashboard I'm writing. I > Googled for such code and checked out PEAR but I didn't find anything > appropriate. Am I missing something or has a PHP programmer never > needed to do a getPreviousBusinessDay() type function before? > -- Scott Mattocks scott at crisscott.com http://www.crisscott.com http://pear.php.net/user/scottmattocks From prusak at gmail.com Tue Nov 23 14:07:30 2004 From: prusak at gmail.com (Ophir Prusak) Date: Tue, 23 Nov 2004 14:07:30 -0500 Subject: [nycphp-talk] Business day calculations In-Reply-To: <20041123173619.GA30652@uranus.faber.nom> References: <20041123173619.GA30652@uranus.faber.nom> Message-ID: How are you defining what a business day is ? Different businesses have different holidays :) On Tue, 23 Nov 2004 12:36:19 -0500, Faber Fedor wrote: > Before I go and reinvent the wheel... > > I need to do things like getPreviousBusinessDay() and > getLastBusinessDayofMonth() in a PHP-based dashboard I'm writing. I > Googled for such code and checked out PEAR but I didn't find anything > appropriate. Am I missing something or has a PHP programmer never > needed to do a getPreviousBusinessDay() type function before? > > -- > > Regards, > > Faber > > Linux New Jersey: Open Source Solutions for New Jersey > http://www.linuxnj.com > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From rrust at r2communications.com Tue Nov 23 14:23:21 2004 From: rrust at r2communications.com (Randal Rust) Date: Tue, 23 Nov 2004 14:23:21 -0500 Subject: [nycphp-talk] Storing Files Outside of HTTP Root Message-ID: <41A38E29.4020007@r2communications.com> I always read that I should store includes and any other files that may contain information like the database connection outside of the root directory of the web site, which makes perfect sense. But what should I do if I don't have access outside of httpdocs, or can't include a file from another directory such as, say, cgi-bin? -- Randal Rust R.Squared Communications http://www.r2communications.com Digital Design for Bricks-and-Mortar Businesses From hans at nyphp.com Tue Nov 23 14:45:22 2004 From: hans at nyphp.com (Hans Zaunere) Date: Tue, 23 Nov 2004 11:45:22 -0800 Subject: [nycphp-talk] Storing Files Outside of HTTP Root Message-ID: <41EE526EC2D3C74286415780D3BA9F8705F5456F@ehost011-1.exch011.intermedia.net> > I always read that I should store includes and any other files that may > contain information like the database connection outside of the root > directory of the web site, which makes perfect sense. > > But what should I do if I don't have access outside of httpdocs, or > can't include a file from another directory such as, say, cgi-bin? New York PHP recommends these best practices for handling site structure and includes: http://education.nyphp.org/phundamentals/PH_sitestructure.php --- Hans Zaunere President, Founder New York PHP http://www.nyphp.org From webmaster at localnotion.com Tue Nov 23 16:40:49 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Tue, 23 Nov 2004 16:40:49 -0500 Subject: [nycphp-talk] Business day calculations In-Reply-To: References: <20041123173619.GA30652@uranus.faber.nom> Message-ID: <579753F2-3D98-11D9-A001-0003938BDF32@localnotion.com> On Nov 23, 2004, at 2:07 PM, Ophir Prusak wrote: > How are you defining what a business day is ? > Different businesses have different holidays :) Just assume everyone works everyday. Isn't that the case? Burt really, the best you could probably do is plug standards like Jan 1 or have a human resource person enter all holidays for that year into a form and exclude those as well as weekends. In other words getlastBusinessDay() that is not 01-01 or not 12-25 etc. No? Please put my Birthday in there too :) From webmaster at localnotion.com Tue Nov 23 17:08:40 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Tue, 23 Nov 2004 17:08:40 -0500 Subject: [nycphp-talk] (no subject) Message-ID: <3B430FD3-3D9C-11D9-A001-0003938BDF32@localnotion.com> From Error handling Phundamentals: Even in development, errors dumped to the browser can be bad because they can become hidden in the HTML. What does that mean? Hidden from the developer's view? Certainly not hidden in the code? -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: text/enriched Size: 323 bytes Desc: not available URL: From chsnyder at gmail.com Tue Nov 23 17:29:40 2004 From: chsnyder at gmail.com (csnyder) Date: Tue, 23 Nov 2004 17:29:40 -0500 Subject: [nycphp-talk] (no subject) In-Reply-To: <3B430FD3-3D9C-11D9-A001-0003938BDF32@localnotion.com> References: <3B430FD3-3D9C-11D9-A001-0003938BDF32@localnotion.com> Message-ID: Actually they can wind up in all sorts of weird places if you try hard enough. Nothing like a PHP error in the middle of some javascript to break your interface... From nyphp at enobrev.com Tue Nov 23 18:10:40 2004 From: nyphp at enobrev.com (Mark Armendariz) Date: Tue, 23 Nov 2004 18:10:40 -0500 Subject: [nycphp-talk] (no subject) In-Reply-To: Message-ID: <20041123231040.F10AEA85F0@virtu.nyphp.org> You could do what Cold Fusion does, which is spit out a huge list of closing tags before it spits out an error. > -----Original Message----- > From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] > On Behalf Of csnyder > Sent: Tuesday, November 23, 2004 5:30 PM > To: NYPHP Talk > Subject: Re: [nycphp-talk] (no subject) > > Actually they can wind up in all sorts of weird places if you try hard > enough. Nothing like a PHP error in the middle of some javascript to > break your interface... > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From mogmios at mlug.missouri.edu Tue Nov 23 18:26:54 2004 From: mogmios at mlug.missouri.edu (Michael) Date: Tue, 23 Nov 2004 15:26:54 -0800 Subject: [nycphp-talk] Re: [nycphp-tallk] errors in html In-Reply-To: <20041123231040.F10AEA85F0@virtu.nyphp.org> References: <20041123231040.F10AEA85F0@virtu.nyphp.org> Message-ID: <41A3C73E.6040905@mlug.missouri.edu> If you're buffering your output then it shouldn't be a problem. -- Michael http://kavlon.org From jeff.siegel at nyphp.org Tue Nov 23 20:21:04 2004 From: jeff.siegel at nyphp.org (Jeff Siegel - PHundamentals) Date: Tue, 23 Nov 2004 20:21:04 -0500 Subject: [nycphp-talk] (no subject) In-Reply-To: <20041123231040.F10AEA85F0@virtu.nyphp.org> References: <20041123231040.F10AEA85F0@virtu.nyphp.org> Message-ID: <41A3E200.7000302@nyphp.org> I don't think you want errors appearing at all though I'm often surprised how many times I've seen Cold Fusion sites display all their errors (and path info, etc.) right there for the world to see. The warning about sending errors to the browser (at least during development) is not that it's the worst thing in the world but that there are times when an error message could have some characters that won't display properly in a browser but, of course, you can read just fine in a log file. Jeff Mark Armendariz wrote: > You could do what Cold Fusion does, which is spit out a huge list of closing > tags before it spits out an error. > > >>-----Original Message----- >>From: talk-bounces at lists.nyphp.org [mailto:talk-bounces at lists.nyphp.org] >>On Behalf Of csnyder >>Sent: Tuesday, November 23, 2004 5:30 PM >>To: NYPHP Talk >>Subject: Re: [nycphp-talk] (no subject) >> >>Actually they can wind up in all sorts of weird places if you try hard >>enough. Nothing like a PHP error in the middle of some javascript to >>break your interface... >>_______________________________________________ >>New York PHP Talk >>Supporting AMP Technology (Apache/MySQL/PHP) >>http://lists.nyphp.org/mailman/listinfo/talk >>http://www.newyorkphp.org > > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From dmintz at davidmintz.org Tue Nov 23 21:38:11 2004 From: dmintz at davidmintz.org (David Mintz) Date: Tue, 23 Nov 2004 21:38:11 -0500 (EST) Subject: [nycphp-talk] (no subject) In-Reply-To: <3B430FD3-3D9C-11D9-A001-0003938BDF32@localnotion.com> References: <3B430FD3-3D9C-11D9-A001-0003938BDF32@localnotion.com> Message-ID: On Tue, 23 Nov 2004, Matthew Terenzio wrote: > From Error handling Phundamentals: > > Even in development, errors dumped to the browser can be bad because > they can become hidden in the HTML. > > What does that mean? Hidden from the developer's view? Certainly not > hidden in the code? I think -- perhaps -- it means the error output sometimes gets tangled up with HTML form elements in such a way that you can't see it in the browser, so you're wondering WTF, and you have to look at the HTML source to figure it out. --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From 1j0lkq002 at sneakemail.com Wed Nov 24 09:38:08 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Wed, 24 Nov 2004 09:38:08 -0500 Subject: [nycphp-talk] (no subject) In-Reply-To: References: <3B430FD3-3D9C-11D9-A001-0003938BDF32@localnotion.com> Message-ID: <4621-67881@sneakemail.com> David Mintz dmintz-at-davidmintz.org |nyphp dev/internal group use| wrote: > so you're wondering WTF I find myself wondering that quite a bit. Maybe I need to check my error message settings ;-) From jsiegel1 at optonline.net Mon Nov 29 08:00:18 2004 From: jsiegel1 at optonline.net (Jeff Siegel) Date: Mon, 29 Nov 2004 08:00:18 -0500 Subject: [nycphp-talk] OT: Firefox Failing on Windows XP Message-ID: <41AB1D62.3020206@optonline.net> This problem is so strange I'm not even sure how to describe it. I've been using Firefox (and its previous incarnations) for quite some time. Then I encountered the following problem. Firefox has become completely unusable. I'm not sure if this is a Firefox issue or a WinXP issue though the problems described below have only affected Firefox and all of my other applications are working correctly. Here are some examples of the problems I've encountered. a) On startup the default 'home' page does not appear though I can right-click on the page and view the html source. b) I can not type anything into the address box nor the Google search box. c) The menus are inaccessible through either the mouse or keyboard. In fact, Firefox does not respond to any keyboard commands. I've tried uninstalling and reinstalling. No luck. Any clues? Jeff S. From dcech at phpwerx.net Mon Nov 29 10:04:10 2004 From: dcech at phpwerx.net (Dan Cech) Date: Mon, 29 Nov 2004 10:04:10 -0500 Subject: [nycphp-talk] OT: Firefox Failing on Windows XP In-Reply-To: <41AB1D62.3020206@optonline.net> References: <41AB1D62.3020206@optonline.net> Message-ID: <41AB3A6A.3000408@phpwerx.net> What version of Firefox are you running? Have you tried starting Firefox in safe mode? Also, there may be issues with your profile, you could try starting Firefox in profile manager mode and creating a new profile. Dan Jeff Siegel wrote: > This problem is so strange I'm not even sure how to describe it. I've > been using Firefox (and its previous incarnations) for quite some time. > Then I encountered the following problem. Firefox has become completely > unusable. I'm not sure if this is a Firefox issue or a WinXP issue > though the problems described below have only affected Firefox and all > of my other applications are working correctly. Here are some examples > of the problems I've encountered. > > a) On startup the default 'home' page does not appear though I can > right-click on the page and view the html source. > b) I can not type anything into the address box nor the Google search box. > c) The menus are inaccessible through either the mouse or keyboard. In > fact, Firefox does not respond to any keyboard commands. > > I've tried uninstalling and reinstalling. No luck. > > Any clues? > > Jeff S. > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org From tommyo at gmail.com Mon Nov 29 10:09:49 2004 From: tommyo at gmail.com (Thomas O'Neill) Date: Mon, 29 Nov 2004 09:09:49 -0600 Subject: [nycphp-talk] OT: Enterprise Java Development Message-ID: Hey Guys, Recently I had the pleasure of reading "Advanced PHP Programming" by George Schlossnagle. (thanks george.. great book!) It really helped me learn how to develop in PHP at more of an enterprise level. I was wondering if anyone could recommend a similar book for J2EE web development. I am a newbie to the world of java. Short of a few classes in college, I have little experience. I understand the syntax and how to use java.sun.com so I have somewhere to start from. I have a project coming up where I will need to use java. I want to be able to correctly design and implement this web application using Java. I don't want to hack my way through it as a PHP programmer. Recommendations Anyone?? -- Tom O'Neill tommyo at gmail.com http://www.dolemite.org From krook at us.ibm.com Mon Nov 29 10:24:35 2004 From: krook at us.ibm.com (Daniel Krook) Date: Mon, 29 Nov 2004 10:24:35 -0500 Subject: [nycphp-talk] OT: Enterprise Java Development In-Reply-To: Message-ID: Tom, I would recommend that you take a look at the Struts framework from Apache. It will take a bit of upfront work to understand the value that this will provide, but it's better to pick up now than halfway through the project when you need to deal with file uploads and form validation. :) As it's an implementation of the MVC pattern, you'll be able to bring a lot of concepts back to your work with PHP as well. http://struts.apache.org/ The user guide is a great place to get familiar with the technologies and concepts involved: http://struts.apache.org/userGuide/ As for a book recommendation, I'd go with: Pro Jakarta Struts, Second Edition by John Carnell, Rob Harrop It's not the highest rated book at Amazon, but I found it useful. >From O'Reilly, there's also: Programming Jakarta Struts by Chuck Cavaness Good luck, -Dan Daniel Krook, Application Developer WW Web Production Services North 2, ibm.com 1133 Westchester Avenue, White Plains, NY 10604 Personal: http://info.krook.org/ Persona: http://w3.ibm.com/eworkplace/persona_bp_finder.jsp?CNUM=9A9796897 From andrew at digitalpulp.com Mon Nov 29 10:27:09 2004 From: andrew at digitalpulp.com (Andrew Yochum) Date: Mon, 29 Nov 2004 10:27:09 -0500 Subject: [nycphp-talk] OT: Firefox Failing on Windows XP In-Reply-To: <41AB3A6A.3000408@phpwerx.net> References: <41AB1D62.3020206@optonline.net> <41AB3A6A.3000408@phpwerx.net> Message-ID: <20041129152658.GJ29028@thighmaster.digitalpulp.com> On Mon, Nov 29, 2004 at 10:04:10AM -0500, Dan Cech wrote: > What version of Firefox are you running? > > Have you tried starting Firefox in safe mode? > > Also, there may be issues with your profile, you could try starting > Firefox in profile manager mode and creating a new profile. > > Dan > > Jeff Siegel wrote: > >This problem is so strange I'm not even sure how to describe it. I've > >been using Firefox (and its previous incarnations) for quite some time. > >Then I encountered the following problem. Firefox has become completely > >unusable. I'm not sure if this is a Firefox issue or a WinXP issue > >though the problems described below have only affected Firefox and all > >of my other applications are working correctly. Here are some examples > >of the problems I've encountered. > > > >a) On startup the default 'home' page does not appear though I can > >right-click on the page and view the html source. > >b) I can not type anything into the address box nor the Google search box. > >c) The menus are inaccessible through either the mouse or keyboard. In > >fact, Firefox does not respond to any keyboard commands. > > > >I've tried uninstalling and reinstalling. No luck. > > > >Any clues? Dan's suggestion is a good one. I have had this problem in the past with both Mozilla & Firefox. It happened to me because of incompatible extensions that buggered things up to the point that the browser was useless. Creating a clean profile will do the trick hopefully - unless you've installed these extensions system-wide, however, an full uninstall / reinstall should fix that. If there is stuff in your profile you don't want to lose or transfer, it is possible to manually remove these extensions from your profile by editing various XML files in your profile dir, though that can be a pain. HTH, Andrew From tgales at tgaconnect.com Mon Nov 29 10:33:06 2004 From: tgales at tgaconnect.com (Tim Gales) Date: Mon, 29 Nov 2004 10:33:06 -0500 Subject: [nycphp-talk] OT: Enterprise Java Development Message-ID: <200411291533.iATFX6J04333@tgaconnect.com> Tom O'Neill writes: > I was wondering if anyone could recommend a book for J2EE web > development -- Hmmn, you may have the wrong list -- however you might find the 'blueprints' section at the Sun site to be useful. (particularly: http://java.sun.com/blueprints/patterns/index.html ) But I would also suggest reading http://peteryared.blogspot.com/2003/09/next-language.html to see why a scripting language like PHP may be better suited to the development environment of the future.. Tim G. From fields at surgam.net Mon Nov 29 10:42:17 2004 From: fields at surgam.net (Adam Fields) Date: Mon, 29 Nov 2004 10:42:17 -0500 Subject: [nycphp-talk] OT: Enterprise Java Development In-Reply-To: References: Message-ID: <20041129154217.GE12830@lola.aquick.org> On Mon, Nov 29, 2004 at 10:24:35AM -0500, Daniel Krook wrote: > I would recommend that you take a look at the Struts framework from > Apache. It will take a bit of upfront work to understand the value that > this will provide, but it's better to pick up now than halfway through the > project when you need to deal with file uploads and form validation. :) Instead of the basic struts, you should look at appfuse, which is a solid integration of several basic framework packages, which grew out of integrating struts with other frameworks (hibernate, spring, etc...) . It is the best introduction to enterprise java I've seen so far. http://today.java.net/pub/a/today/2004/07/15/thefuse.html -- - Adam ----- [ http://www.aquick.org/blog ] [ http://www.adamfields.com ][ http://del.icio.us/fields ] [ http://www.aquick.org/photoblog ][ http://www.aquick.org/gallery ] From jsiegel1 at optonline.net Mon Nov 29 10:59:15 2004 From: jsiegel1 at optonline.net (Jeff Siegel) Date: Mon, 29 Nov 2004 10:59:15 -0500 Subject: [nycphp-talk] OT: Firefox Failing on Windows XP In-Reply-To: <41AB3A6A.3000408@phpwerx.net> References: <41AB1D62.3020206@optonline.net> <41AB3A6A.3000408@phpwerx.net> Message-ID: <41AB4753.7090004@optonline.net> Thanks Dan and Andrew. I went into profile mode ("C:\Program Files\Mozilla Firefox\firefox.exe" -P) and that seems to have done the trick. Boy...that was REAL STRANGE!! I've had extensions do funky things but this was the strangest I had seen. Jeff Dan Cech wrote: > What version of Firefox are you running? > > Have you tried starting Firefox in safe mode? > > Also, there may be issues with your profile, you could try starting > Firefox in profile manager mode and creating a new profile. > > Dan > > Jeff Siegel wrote: > >> This problem is so strange I'm not even sure how to describe it. I've >> been using Firefox (and its previous incarnations) for quite some time. >> Then I encountered the following problem. Firefox has become completely >> unusable. I'm not sure if this is a Firefox issue or a WinXP issue >> though the problems described below have only affected Firefox and all >> of my other applications are working correctly. Here are some examples >> of the problems I've encountered. >> >> a) On startup the default 'home' page does not appear though I can >> right-click on the page and view the html source. >> b) I can not type anything into the address box nor the Google search >> box. >> c) The menus are inaccessible through either the mouse or keyboard. In >> fact, Firefox does not respond to any keyboard commands. >> >> I've tried uninstalling and reinstalling. No luck. >> >> Any clues? >> >> Jeff S. >> _______________________________________________ >> New York PHP Talk >> Supporting AMP Technology (Apache/MySQL/PHP) >> http://lists.nyphp.org/mailman/listinfo/talk >> http://www.newyorkphp.org > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From rahmin at insite-out.com Mon Nov 29 13:36:13 2004 From: rahmin at insite-out.com (Rahmin Pavlovic) Date: Mon, 29 Nov 2004 13:36:13 -0500 Subject: [nycphp-talk] cheap php hosts? Message-ID: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> An embedded and charset-unspecified text was scrubbed... Name: not available URL: From jlacey at att.net Mon Nov 29 13:48:11 2004 From: jlacey at att.net (John Lacey) Date: Mon, 29 Nov 2004 11:48:11 -0700 Subject: [nycphp-talk] cheap php hosts? In-Reply-To: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> References: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> Message-ID: <41AB6EEB.2020905@att.net> Rahmin Pavlovic wrote: > Sorry if this has been posted before - > > A friend of mine -- not exactly a client, but someone I work with in the music biz -- is looking for a cheap hosting solution. > > He asked me about this $19.95/yr package at register.com, which I'm about to shoot down for a number of reasons, but I'm > wondering what cheapo php solutions I can offer as an alternative. > > It doesn't have to be twenty-bucks-a-year cheap, and he really doesn't need a 'website building tool', but I want to offer > something that's clearly better than register.com. > > TIA > http://www.edmunds-enterprises.com/linux/hosting_plans_wc.php HTH, John From 1j0lkq002 at sneakemail.com Mon Nov 29 13:53:14 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Mon, 29 Nov 2004 13:53:14 -0500 Subject: [nycphp-talk] cheap php hosts? In-Reply-To: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> References: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> Message-ID: <9441-71715@sneakemail.com> Rahmin Pavlovic rahmin-at-insite-out.com |nyphp dev/internal group use| wrote: >Sorry if this has been posted before - > >A friend of mine -- not exactly a client, but someone I work with in the music biz -- is looking for a cheap hosting solution. > >He asked me about this $19.95/yr package at register.com, which I'm about to shoot down for a number of reasons, but I'm >wondering what cheapo php solutions I can offer as an alternative. > >It doesn't have to be twenty-bucks-a-year cheap, and he really doesn't need a 'website building tool', but I want to offer >something that's clearly better than register.com. > >TIA > >R > > For many reasons, I would advise him not to host with his his domain registrar. It is wise to keep those two business relationships separate and independent. (quick example: if a spam report comes into your registrar, true or not, your website can be taken down in accordance with the registar's TOS --if they can do that. It has "allegedly" happened more than once recently with the registrar whos name begins with the opposite of alto and ends with the compliment to madre. Best to keep the keys to the kingdom in separate hands IMHO) -=john andrews From list at harveyk.com Mon Nov 29 14:41:56 2004 From: list at harveyk.com (harvey) Date: Mon, 29 Nov 2004 14:41:56 -0500 Subject: [nycphp-talk] cheap php hosts? In-Reply-To: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> References: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> Message-ID: <6.2.0.14.0.20041129144140.05026c48@mail.harveyk.com> Dreamhost.com is pretty good and cheap At Monday 11/29/2004 01:36 PM, Rahmin Pavlovic wrote: >Sorry if this has been posted before - > >A friend of mine -- not exactly a client, but someone I work with in the >music biz -- is looking for a cheap hosting solution. > >He asked me about this $19.95/yr package at register.com, which I'm about >to shoot down for a number of reasons, but I'm >wondering what cheapo php solutions I can offer as an alternative. > >It doesn't have to be twenty-bucks-a-year cheap, and he really doesn't >need a 'website building tool', but I want to offer >something that's clearly better than register.com. > >TIA > >R > > >_______________________________________________ >New York PHP Talk >Supporting AMP Technology (Apache/MySQL/PHP) >http://lists.nyphp.org/mailman/listinfo/talk >http://www.newyorkphp.org From leam at reuel.net Mon Nov 29 21:51:20 2004 From: leam at reuel.net (leam at reuel.net) Date: Mon, 29 Nov 2004 21:51:20 -0500 Subject: [nycphp-talk] cheap php hosts? In-Reply-To: <6.2.0.14.0.20041129144140.05026c48@mail.harveyk.com> References: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> <6.2.0.14.0.20041129144140.05026c48@mail.harveyk.com> Message-ID: <20041130025120.GA3593@leitz.earthlink.net> I use gh1.com. Nice guys, good deals. If you do sales, they're opening up for resellers. *I* couldn't sell money at 10% off, but others might find it useful. ciao! leam On Mon, Nov 29, 2004 at 02:41:56PM -0500, harvey wrote: > Dreamhost.com is pretty good and cheap > > > > At Monday 11/29/2004 01:36 PM, Rahmin Pavlovic wrote: > >Sorry if this has been posted before - > > > >A friend of mine -- not exactly a client, but someone I work with in the > >music biz -- is looking for a cheap hosting solution. > > > >He asked me about this $19.95/yr package at register.com, which I'm about > >to shoot down for a number of reasons, but I'm > >wondering what cheapo php solutions I can offer as an alternative. > > > >It doesn't have to be twenty-bucks-a-year cheap, and he really doesn't > >need a 'website building tool', but I want to offer > >something that's clearly better than register.com. > > > >TIA > > > >R From darkwulf at clan-forsaken.com Mon Nov 29 22:01:41 2004 From: darkwulf at clan-forsaken.com (DarkWulf) Date: Mon, 29 Nov 2004 19:01:41 -0800 Subject: [nycphp-talk] cheap php hosts? In-Reply-To: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> References: <200411291836.iATIaD7E000305@webmail3.megamailservers.com> Message-ID: <41ABE295.8020106@clan-forsaken.com> I host a few smaller sites at www.nearlyfreespeech.net I like them because they have always struck me as very honest people, and surprisingly un-bottom-line orientated. You pay for the hard drive space and bandwidth you use, and thats about it. ($0.02/day for hosting a domain, $0.01/month/megabyte for storage, $1.00/gigabyte for bandwidth) Strong caveat is that you really do have to know what you're doing. Their control panel is sometimes confusing. There is no support for "my script doesn't work" and so on and so forth. Rahmin Pavlovic wrote: >Sorry if this has been posted before - > >A friend of mine -- not exactly a client, but someone I work with in the music biz -- is looking for a cheap hosting solution. > >He asked me about this $19.95/yr package at register.com, which I'm about to shoot down for a number of reasons, but I'm >wondering what cheapo php solutions I can offer as an alternative. > >It doesn't have to be twenty-bucks-a-year cheap, and he really doesn't need a 'website building tool', but I want to offer >something that's clearly better than register.com. > >TIA > >R > > >_______________________________________________ >New York PHP Talk >Supporting AMP Technology (Apache/MySQL/PHP) >http://lists.nyphp.org/mailman/listinfo/talk >http://www.newyorkphp.org > > > > From leam at reuel.net Tue Nov 30 06:45:37 2004 From: leam at reuel.net (leam at reuel.net) Date: Tue, 30 Nov 2004 06:45:37 -0500 Subject: [nycphp-talk] I need a date...sorta... Message-ID: <20041130114537.GB1253@leitz.earthlink.net> Trying to drink less coffee in the morning, not sure it's wise to post. :) I'm trying to write an entry form that lets people enter future dates for an event. Most events are 1-4 days in length, which means they may start in one month and end in another. This form will submit to a MySQL databse, and another page will pull out the event information with start and end dates. So if I'm going to have an event on 15 January 2005, and my event will last 4 days, the web page that shows my event will say: leam's Event, 15-18 Jan 2005 Of course, if my events begins on 30 Jan and goes for 4 days, it should put 31 Jan-2Feb 2005. I think I can make the Month and Year check itself and not print if they're the same. What I don't yet know is the best way to let a user input the date. The first thought that comes to mind is an html selection for each thing, "day" with 31 options, "month" with 12, etc. Ideally the form will be used outside the US so the whole issue of how to spell months and what order things go in has already cropped up. I don't have any translators so everything will be in english. Any suggestions? ciao! leam p.s. For once I'm not in a rush. I've set no promised date for this so I have time to think it through. If there's a function or web page I should read, point me to it! From michael.southwell at nyphp.org Tue Nov 30 08:31:59 2004 From: michael.southwell at nyphp.org (Michael Southwell) Date: Tue, 30 Nov 2004 08:31:59 -0500 Subject: [nycphp-talk] OT: Microsoft Scripting Language Message-ID: <6.1.2.0.2.20041130083000.020423e8@mail.optonline.net> An associate of mine needs help with a project involving Microsoft Scripting Language, the language used in .inf files. Is anyone out there smart about this? Michael Southwell VP, Education Department New York PHP michael.southwell at nyphp.org From mitch.pirtle at gmail.com Tue Nov 30 09:06:28 2004 From: mitch.pirtle at gmail.com (Mitch Pirtle) Date: Tue, 30 Nov 2004 09:06:28 -0500 Subject: [nycphp-talk] I need a date...sorta... In-Reply-To: <20041130114537.GB1253@leitz.earthlink.net> References: <20041130114537.GB1253@leitz.earthlink.net> Message-ID: <330532b60411300606fe22be0@mail.gmail.com> You could take a look at Pear's Date: http://pear.php.net/package/Date Or you could also see Pear's Calendar: http://pear.php.net/package/Calendar There are also some goodies to be had by HTML_QuickForm: http://pear.php.net/package/HTML_QuickForm -- Mitch On Tue, 30 Nov 2004 06:45:37 -0500, leam at reuel.net wrote: > I'm trying to write an entry form that lets people enter future dates for an event. Most events are 1-4 days in length, which means they may start in one month and end in another. This form will submit to a MySQL databse, and another page will pull out the event information with start and end dates. From Cbielanski at inta.org Tue Nov 30 09:12:43 2004 From: Cbielanski at inta.org (Chris Bielanski) Date: Tue, 30 Nov 2004 09:12:43 -0500 Subject: [nycphp-talk] I need a date...sorta... Message-ID: <4DBE3775D77C744E9D1B9D06082E75D60AAA98@intamail1.com> My advice is KISS, Leam... Create both a start date and end date input rather than fight with leap days, long months, time zones, and other holiday weirdnesses (relgious /and/ federal). That's how I approach it here. Admittedly, I have to have a resolution of minutes, and not days, because I track sessions within events as well as the event dates. Besides, given half a chance, the user will put in the wrong number of days a certain percentage of the time, rendering your calculations null (and of course since this is PHP, only null, not void ;) ) Meeting planners are not the brightest apples in the barrel. Thanks, Chris Bielanski Web Programmer, International Trademark Association, 1133 Avenue of the Americas, 33rd Floor New York, NY 10036 +1 (212) 642-1745, f: +1 (212) 768-7796 mailto:cbielanski at inta.org, www.inta.org INTA -- 125 Years of Excellence > -----Original Message----- > From: leam at reuel.net [mailto:leam at reuel.net] > Sent: Tuesday, November 30, 2004 6:46 AM > To: talk at lists.nyphp.org > Subject: [nycphp-talk] I need a date...sorta... > > > Trying to drink less coffee in the morning, not sure it's > wise to post. :) > > I'm trying to write an entry form that lets people enter > future dates for an event. Most events are 1-4 days in > length, which means they may start in one month and end in > another. This form will submit to a MySQL databse, and > another page will pull out the event information with start > and end dates. > > So if I'm going to have an event on 15 January 2005, and my > event will last 4 days, the web page that shows my event will say: > > leam's Event, 15-18 Jan 2005 > > Of course, if my events begins on 30 Jan and goes for 4 days, > it should put 31 Jan-2Feb 2005. I think I can make the Month > and Year check itself and not print if they're the same. What > I don't yet know is the best way to let a user input the > date. The first thought that comes to mind is an html > selection for each thing, "day" with 31 options, "month" with > 12, etc. Ideally the form will be used outside the US so the > whole issue of how to spell months and what order things go > in has already cropped up. I don't have any translators so > everything will be in english. > > Any suggestions? > > ciao! > > leam > > p.s. For once I'm not in a rush. I've set no promised date > for this so I have time to think it through. If there's a > function or web page I should read, point me to it! > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From chsnyder at gmail.com Tue Nov 30 09:27:59 2004 From: chsnyder at gmail.com (csnyder) Date: Tue, 30 Nov 2004 09:27:59 -0500 Subject: [nycphp-talk] I need a date...sorta... In-Reply-To: <4DBE3775D77C744E9D1B9D06082E75D60AAA98@intamail1.com> References: <4DBE3775D77C744E9D1B9D06082E75D60AAA98@intamail1.com> Message-ID: Other considerations in this thread aside, I like to provide a single text field for each of start date and end date, then use strtotime() on the input. http://us2.php.net/manual/en/function.strtotime.php This only works for applications where you know the input is generally going to be good (intranets, selfnets), but it's a lot quicker to fill out a text field than it is to dial up a date from pulldown menus. From prusak at gmail.com Tue Nov 30 10:20:43 2004 From: prusak at gmail.com (Ophir Prusak) Date: Tue, 30 Nov 2004 10:20:43 -0500 Subject: [nycphp-talk] I need a date...sorta... In-Reply-To: References: <4DBE3775D77C744E9D1B9D06082E75D60AAA98@intamail1.com> Message-ID: I actually find that a "pop up" type calendar for dates is the best solution. See expedia.com for an example of what I mean. This is especially true when the user might not remember the exact dates without looking at a calendar. On Tue, 30 Nov 2004 09:27:59 -0500, csnyder wrote: > Other considerations in this thread aside, I like to provide a single > text field for each of start date and end date, then use strtotime() > on the input. > > http://us2.php.net/manual/en/function.strtotime.php > > This only works for applications where you know the input is generally > going to be good (intranets, selfnets), but it's a lot quicker to fill > out a text field than it is to dial up a date from pulldown menus. > > > _______________________________________________ > New York PHP Talk > Supporting AMP Technology (Apache/MySQL/PHP) > http://lists.nyphp.org/mailman/listinfo/talk > http://www.newyorkphp.org > From nyphp at enobrev.com Tue Nov 30 11:19:18 2004 From: nyphp at enobrev.com (Mark Armendariz) Date: Tue, 30 Nov 2004 11:19:18 -0500 Subject: [nycphp-talk] I need a date...sorta... In-Reply-To: Message-ID: <20041130161921.6FB6FA85E9@virtu.nyphp.org> > I actually find that a "pop up" type calendar for dates is the best > solution. > See expedia.com for an example of what I mean. This is especially true > when the user might not remember the exact dates without looking at a > calendar. I've found pop-up calendars to be the 'best' (by client accolade) in my experience as well. Usually with dropdowns or a text field in a noscript tag. Also note that expedia's popup is NOT cross-browser, thought their workaround works ok. I've been a huge fan of this bad boy for a while now: http://www.dynarch.com/projects/calendar/ Mark From 1j0lkq002 at sneakemail.com Tue Nov 30 12:51:34 2004 From: 1j0lkq002 at sneakemail.com (inforequest) Date: Tue, 30 Nov 2004 12:51:34 -0500 Subject: [nycphp-talk] I need a date...sorta... Message-ID: <28271-19718@sneakemail.com> Sorry this isn't really about php code, but I am working at a conceptual level here.. and since you said you have free time on your hands, mabe you'll enjoy experimenting :-) I worked with some programmers on events-based databases a few times, and have programmed my own in numerical C and a small one in PHP. I am not a professional programmer, and I get very annoyed very easily when dealing with the nuances of date/time as implemented by MySQL or another not-really-standard system. The event data really is start TIME and DURATION (plus venueID, title, etc). After that, you have data redundancy (end date is just start time + duration, second day is just start time - time of day plus 24 hours, etc). In actuality, START TIME is realy just OFFSET FROM BASELINE too pick your baseline.. Julian zero, etc). The math associated with scheduling is done with matrices (linear algebra, or matrix math). That is very, very fast, and allows you to do clever things to get what you want. So I like to store start START TIME and DURATION, and if I want to store derivitives I can certainly do that for practical reasons, but I need to handle them as I would any non-normalized data. Any serious scheduling math will be done on the time matrix which only includes ON or OFF for time segements in the time space (if you resolve to theminute, then minutes are ON or OFF). Make the segments any size you like for flexibility, and re-segment anytme you like for utility, down to your preset max resolution/smallest increment (usually minutes). The user input should be as friendly as possible -- that's a UI job. For functionality, the system can provide the UI with a mask on the absolute time frame defined by START TIME and END=START+DURATION. So an event is Dec 1 - Dec 4 2004. Really it is Dec 1 8am tru Dec 4 4pm, and that means *really* it is START 12/1/04 09:00 DURATION 103 hours. For minute segments, that's 6180 minutes. So the user blocks out 12/2/04 9-10 am via your UI, and the system assigns minutes 1440 - 1500 (one hour) to that "event". You may be surprised at how flexible your back end becomes if you work with the data in this manner, and abstract it to the UI for appearances and utility for the user. Wanna change the event to another month? Update the START TIME. Wanna look for the least-booked 2 hour slot to plan an ad-hoc session? Search for a local minimum for offset from start as ordinate, and some sort of attendance estimate on the abscissa. Want to reschedule concurrent sessions to better accommodate the demand for a popular sesson? Same story... "slide" a bock representing session duration on X vs. estimated attendance on Y along a similar time/estimatedattendance scale for the entire event sans that session, adding the Y values together ("slide along" and "add" etc are basic linear algebra operations, simply expressed via matrix operations and super fast). Then seek a minimum. Want a plot of hallway activity? You can get clever taking derivitives (very fast algo) of the time/atendance blocks on that same scale... dy/dt spikes at the edges/transitions between sessions, proportional to attendance. Smooth it via a window function and you get an interesting approxmation of hallway traffic -- perhaps that helps schedule housekeeping visits, vendor breaks, etc. I hope you get the idea.... Not everybody will do their back end calculations with numerical algos, or get excited about the possibilities for data analysis like this, but when things get complex that is what the engine is doing anyway (or trying to do). If you get comfortable separating data from presentation, and abstracting to the UI for utility, abstracting to the DB for platform independence, etc.. then you might appreciate the gains from further separating EVENT ATTRIBUTES from the data/time constraints of MySQL/PHP or whatever as well. -=john andrews Original Message: ----------------- From: leam-at-reuel.net |nyphp dev/internal group use| ... Date: Tue, 30 Nov 2004 06:45:37 -0500 To: talk at lists.nyphp.org Subject: [nycphp-talk] I need a date...sorta... p.s. For once I'm not in a rush. I've set no promised date for this so I have time to think it through. If there's a function or web page I should read, point me to it! -------------------------------------------------------------------- mail2web - Check your email from the web at http://mail2web.com/ . From webmaster at localnotion.com Tue Nov 30 22:53:26 2004 From: webmaster at localnotion.com (Matthew Terenzio) Date: Tue, 30 Nov 2004 22:53:26 -0500 Subject: [nycphp-talk] C for PHP resources Message-ID: <8E425F56-434C-11D9-98BB-0003938BDF32@localnotion.com> Since things are quiet I guess I'll state it's been long overdue that I take the C plunge. I guess it's related to PHP since it is the way to extend the language. So what are the best resources/books for me from those who have conquered this world? Matt From dmintz at davidmintz.org Tue Nov 30 23:07:50 2004 From: dmintz at davidmintz.org (David Mintz) Date: Tue, 30 Nov 2004 23:07:50 -0500 (EST) Subject: [nycphp-talk] 4 and 5 on the same development box (again) Message-ID: This came up a few months back and I can't seem to locate the thread in the archives (It seems that when you google "whatever site:lists.nyphp.org" you strike out no matter what 'whatever' is. But I digress...) Suppose you don't mind restarting Apache to switch between 4 and 5. Is there any reason why one couldn't install php5 in something like /usr/local/php5 and write a second httpd.conf to work with it, then maybe write a shell script for restarting using the appropriate config? I've read Adam Trachtenberg's recipes for setting up PHP 5 as a CGI and using it alongside PHP4. (Great book that "Upgrading to PHP 5", btw, thank you Adam). Makes sense. There was also another recipe proposed by G. Schlossnagle on this list -- one of the posts I can't seem to find -- that involved mod_proxy and so on, which I'd love to have another look at if someone could point the way. But I was wondering about the scenario described above. Thanks, --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From dmintz at davidmintz.org Tue Nov 30 23:11:24 2004 From: dmintz at davidmintz.org (David Mintz) Date: Tue, 30 Nov 2004 23:11:24 -0500 (EST) Subject: [nycphp-talk] C for PHP resources In-Reply-To: <8E425F56-434C-11D9-98BB-0003938BDF32@localnotion.com> References: <8E425F56-434C-11D9-98BB-0003938BDF32@localnotion.com> Message-ID: On Tue, 30 Nov 2004, Matthew Terenzio wrote: > So what are the best resources/books for me from those who have > conquered this world? I would get "The C Progamming Language" by Kernighan and Ritchie if I were in your shoes. Indeed I might be, when I decide to give it a shot myself (-: --- David Mintz http://davidmintz.org/ $world =~ s|]*>.+||is; From chsnyder at gmail.com Tue Nov 30 23:16:31 2004 From: chsnyder at gmail.com (csnyder) Date: Tue, 30 Nov 2004 23:16:31 -0500 Subject: [nycphp-talk] 4 and 5 on the same development box (again) In-Reply-To: References: Message-ID: I have both 4 and 5 installed on a few boxes. Switching between them is a matter of changing which libphp is commented-out in httpd.conf, and restarting apache. The only place where you have to be careful is with the CLI php -- it will get overwritten on make install. Causes trouble if you have command line scripts that care which version you are using. You can always compile php4 --disable-cli to eliminate the problem. From jonbaer at jonbaer.net Mon Nov 29 22:29:59 2004 From: jonbaer at jonbaer.net (Jon Baer) Date: Mon, 29 Nov 2004 22:29:59 -0500 Subject: [nycphp-talk] OT: Firefox Failing on Windows XP In-Reply-To: <20041129152658.GJ29028@thighmaster.digitalpulp.com> References: <41AB1D62.3020206@optonline.net> <41AB3A6A.3000408@phpwerx.net> <20041129152658.GJ29028@thighmaster.digitalpulp.com> Message-ID: <41ABE937.8010108@jonbaer.net> ive actually had a terrible time printing from firefox/mozilla off a network'd printer recently and it has been sucking up memory like no tomorrow. i recently caught the glimpse of a headline saying 1.0 was deemed pretty unstable compared to release candidate builds so i went back and found an old download and its been holding up. im also on xp so i think its possibly bill is creeping into automatic updates to make sure he tames the beast :-) - jon -- pgp key: http://www.jonbaer.net/jonbaer.asc fingerprint: F438 A47E C45E 8B27 F68C 1F9B 41DB DB8B 9A0C AF47 From jonbaer at jonbaer.net Mon Nov 29 22:33:52 2004 From: jonbaer at jonbaer.net (Jon Baer) Date: Mon, 29 Nov 2004 22:33:52 -0500 Subject: [nycphp-talk] OT: Enterprise Java Development In-Reply-To: References: Message-ID: <41ABEA20.8070801@jonbaer.net> Your best bet is to look @ the Tomcat project ... http://jakarta.apache.org/tomcat/ If you take a weekend or two tinkering around w/ it you get a pretty good headstart for commercial builds like dynamo,websphere,weblogic,etc. 5.5 is suppose to be top notch and a great educational platform. (ie how to do things right :-) - Jon Thomas O'Neill wrote: > Hey Guys, > > Recently I had the pleasure of reading "Advanced PHP Programming" by > George Schlossnagle. (thanks george.. great book!) It really helped > me learn how to develop in PHP at more of an enterprise level. > > I was wondering if anyone could recommend a similar book for J2EE web > development. I am a newbie to the world of java. Short of a few > classes in college, I have little experience. I understand the syntax > and how to use java.sun.com so I have somewhere to start from. > > I have a project coming up where I will need to use java. I want to > be able to correctly design and implement this web application using > Java. I don't want to hack my way through it as a PHP programmer. > > Recommendations Anyone?? > -- pgp key: http://www.jonbaer.net/jonbaer.asc fingerprint: F438 A47E C45E 8B27 F68C 1F9B 41DB DB8B 9A0C AF47