Re: [nyphp-talk] Intellectual Monday

2007-01-22 Thread Billy Reisinger
I got nothing on chaining, but I have some opinions about the prototype concept. The prototyping concept in general is similar to using a static member in Java. A function prototype in JavaScript is a member that is common to all instances of that function (read: class). If one instance d

RE: [nyphp-talk] Intellectual Monday

2007-01-22 Thread Baer, Jon
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I must say that both techniques *can* lead to hell when debugging. The idea of adding new methods ontop of existing classes is usually not safe if not documented well. The one thing I liked about the verbose-ness of Java is the fact that I always kne

Re: [nyphp-talk] Re: talk Digest, Vol 3, Issue 50

2007-01-22 Thread Urb LeJeune
Partially. Once I find all the zip codes within an x-mile radius I have to find all records in a db table that match any of those zip codes. Load an array of zip codes within an x-mail radius, Let's assume $ZipArray. Next. $Subselect = "(" . implode('",",$ZipArray) , '")'; Let's addition

Re: [nyphp-talk] Intellectual Monday

2007-01-22 Thread Rob Marscher
A lot of the methods in the Zend Framework classes use object chaining. It requires PHP5. In terms of the prototype concept... javascript doesn't have a traditional object implementation -- you can't say "class A extends class B" -- and the lines are pretty blurred between what a function is

Re: [nyphp-talk] Intellectual Monday

2007-01-22 Thread csnyder
On 1/22/07, Cliff Hirsch <[EMAIL PROTECTED]> wrote: I wonder how these techniques work in the PHP world. Does anyone use chaining effectively? Is there a PHP equivalent to the prototype concept? Javascript is an beautiful, powerful language. I never thought I would say that, and I think Netsca

[nyphp-talk] Intellectual Monday

2007-01-22 Thread Cliff Hirsch
I have been digging into JavaScript and jQuery, and am intrigued by several concepts. 1. jQuery uses chaining, whereby every method within jQuery returns the query object itself. 2. JavaScript's prototype method is an interesting concept for adding methods to existing classes. I wonder how th

[nyphp-talk] Re: talk Digest, Vol 3, Issue 50

2007-01-22 Thread Donna Marie Vincent
Partially. Once I find all the zip codes within an x-mile radius I have to find all records in a db table that match any of those zip codes. >Date: Mon, 22 Jan 2007 01:14:51 -0500 >From: Urb LeJeune <[EMAIL PROTECTED]> >Subject: Re: [nyphp-talk] Radial Zip Code Search >To: NYPHP Talk >Message-I

Re: [nyphp-talk] Zip Code Stuff

2007-01-22 Thread Urb LeJeune
Thanks for the info, I'll check it out. Urb You almost certainly want to use the Haversine formula for this task (calculating distances to points that are quite close on a sphere). http://en.wikipedia.org/wiki/Great-circle_distance The basic Great Circle formula gives *incorrect* res

Re: [nyphp-talk] Zip Code Stuff

2007-01-22 Thread Michael Sims
On Monday 22 January 2007 9:39 am, Urb LeJeune wrote: > >There are 8 Zip codes withing a 5 miles radius of 05701 > >They are: > >05251 Dorset, VT 0.85 miles > >05701 Rutland, VT 0.00 miles > >05702 Rutland, VT 0.00 miles > >05736 Center Rutland, VT 2.59 miles > >05744 Florence, VT 3.57 miles > >05

[nyphp-talk] Zip Code Stuff

2007-01-22 Thread Urb LeJeune
There are 8 Zip codes withing a 5 miles radius of 05701 They are: 05251 Dorset, VT 0.85 miles 05701 Rutland, VT 0.00 miles 05702 Rutland, VT 0.00 miles 05736 Center Rutland, VT 2.59 miles 05744 Florence, VT 3.57 miles 05759 North Clarendon, VT 2.13 miles 05765 Proctor, VT 4.57 miles 05777 West R

Re: [nyphp-talk] Radial Zip Code Search

2007-01-22 Thread Joseph Crawford
That's a nice setup but something is wrong there There are 8 Zip codes withing a 5 miles radius of 05701 They are: 05251 Dorset, VT 0.85 miles 05701 Rutland, VT 0.00 miles 05702 Rutland, VT 0.00 miles 05736 Center Rutland, VT 2.59 miles 05744 Florence, VT 3.57 miles 05759 North Clarendon, VT 2.13