RE: [fw-general] Password validation

2007-07-22 Thread Bill Karwin
> -Original Message- > From: buster [mailto:[EMAIL PROTECTED] > If you look in the docs here: > http://framework.zend.com/manual/en/zend.filter.input.html > under 13.5.4.1. > they actually give this exact situation. I wrote a very quick > validator to do just what you (and the docs) ar

RE: [fw-general] Zend_Db_Table Relationships - help

2007-07-22 Thread Bill Karwin
Sorry! My mistake - this should be findDependentRowset('ProductTable'); Bill Karwin From: Bill Karwin [mailto:[EMAIL PROTECTED] $productRowset = $categoryRow->findDependentRowset('ProductCategoryTable');

RE: [fw-general] Zend_Db_Table Relationships - help

2007-07-22 Thread Bill Karwin
If you have a relationship between two tables, you have a parent and a dependent by definition. The dependent contains a foreign key that references the primary key of its parent. In the relationship you described, your parent is product_categories, and your dependent is products. The SQL table

Re: [fw-general] Password validation

2007-07-22 Thread buster
Markus Wolff wrote: > > Hi there, > > quite often one has to make a form where a user can create a user > account. It's customary to add two password fields, and add a validation > rule so that when the entries in both fields do not match, an error > message is presented to the user. > > I

RE: [fw-general] Data models

2007-07-22 Thread Bill Karwin
Rob, how do you feel about this somewhat different statement I gave on a fw-db thread: Q: "Is there a best practice when it comes to defining models on top of the Zend_Db_Table_Row class?" Regarding best practices of defining models, this is a frequently asked question. It's hard to make a one-s

Re: [fw-general] Distributing my own contributions to ZF independently?

2007-07-22 Thread Jack Sleight
OK that's fine. Good to know I could, but I actually might not bother anyway. The latest version will always be in ZF (if accepted), and its not particularly hard to just list the one dependency, so people can still use it on its own. In all honesty, I'm just thinking ahead, but I doubt I will

Re: [fw-general] Going to start using ZF

2007-07-22 Thread Nick Lo
Regarding tree structures and databases, there are several solutions for representing trees in a relational database using standard SQL. - path enumeration - nested sets - adjacency lists Here are a few articles that describe how to use these techniques: http://www.onlamp.com/pub/a/onlamp/200

Re: [fw-general] Password validation

2007-07-22 Thread Markus Wolff
Hi Karol, the problem seems trivial at first glance, since it could be solved by a simple if($a != $b) echo "Error"; - but this would break the elegance of defining all your validation logic in one place and have only one single mechanism to determine whether or not your form has validated, an

[fw-general] Distributing my own contributions to ZF independently?

2007-07-22 Thread Jack Sleight
Hey, If this is frowned upon, or you dont like people doing it then thats fine, I wont, but im just a little confused. I know that any contributions I make to ZF are still my own property to do what I like with, but I just have one little question. If I wanted to distribute a component that I

Re: [fw-general] Password validation

2007-07-22 Thread Markus Wolff
Looking at the code of Zend_Validate_Abstract a bit more, it seems that I can't have exactly what I propose unless Zend_Filter_Input is being modified as well, because Zend_Validate_Abstract right now does not know about other fields than the one it's currently processing. So, there's two poss

Re: [fw-general] Password validation

2007-07-22 Thread Karol Grecki
Markus I think this problem is so trivial that it doesn't require a dedicated validator. You usually need it once during signup and it's solved by simple == operator. Regards Karol Markus Wolff wrote: > > Hey Jason, > > that's where I was looking and couldn't find any. Sure, I can write my

Re: [fw-general] Wiki down

2007-07-22 Thread till
On 7/22/07, Thomas Weidner <[EMAIL PROTECTED]> wrote: Still down :-( How about a clock timer from walmart ? Reset the server's power all 4 hours ;-) Walmart is evil. I doubt the sign a CLA and then the license of the timer is probably not so BSD-like. :D Till

Re: [fw-general] Wiki down

2007-07-22 Thread Thomas Weidner
But access to an crashed server which is unavaiable is not possible or necessary. They need access to the power-plug of the server ;-) Anyway... it's frustrating not being able to close / comment issues, not work on new ideas or verify existing proposals for work. Another day which is over wit

Re: [fw-general] Wiki down

2007-07-22 Thread Thomas Weidner
Still down :-( How about a clock timer from walmart ? Reset the server's power all 4 hours ;-) Thomas - Original Message - From: "Jack Sleight" <[EMAIL PROTECTED]> To: "Zend Framework General List" Sent: Sunday, July 22, 2007 4:00 PM Subject: [fw-general] Wiki down again :( -- Jac

Re: [fw-general] Password validation

2007-07-22 Thread Markus Wolff
Hey Jason, that's where I was looking and couldn't find any. Sure, I can write my own validator, I just couldn't believe I was the first one finding the obvious gap in the existing validators. What I need is a validator that compares one field's value to another. Something along the lines of

Re: [fw-general] Password validation

2007-07-22 Thread Jason Qi
Hi Markus, Do you think the Standard Validation Classes is useful for you? http://framework.zend.com/manual/en/zend.validate.set.html Or you might write Validators yourself to fit your needs. see here: http://framework.zend.com/manual/en/zend.validate.writing_validators.html Regards, Jason. -

Re: [fw-general] Data models

2007-07-22 Thread Karol Grecki
Rob I don't believe YAGNI applies here but "favour composition over inheritance" sure does. It's just up to you how you treat your models, as simple extension of the data, or an entity that can be persistent in a database (or somewhere else). So I totally agree with Bill that this is a bad idea.

[fw-general] Wiki down

2007-07-22 Thread Jack Sleight
again :( -- Jack

[fw-general] Zend_Db_Table Relationships - help

2007-07-22 Thread Matt M.
Hi, I'm trying to follow the docs but I'm still confused as to what to do to get relationships going. Here are my models: Product + ProductTable ProductCategory + ProductCategoryTable I don't want cascading actions, so I left out $_dependentTables as the docs say. My tables are setup so produc

[fw-general] Password validation

2007-07-22 Thread Markus Wolff
Hi there, quite often one has to make a form where a user can create a user account. It's customary to add two password fields, and add a validation rule so that when the entries in both fields do not match, an error message is presented to the user. I was searching for such a validation rul

Re: [fw-general] Data models

2007-07-22 Thread Rob Allen
Karol Grecki wrote: > Hi Rob, > > Applications tend to evolve, often beyond what you expected. Of course. > Creating a proper model that is decoupled from a database is not that much > effort. > And it may benefit you greatly if you're building non trivial application > Strikes me as a case o

Re: [fw-general] Data models

2007-07-22 Thread Karol Grecki
Hi Rob, Applications tend to evolve, often beyond what you expected. Creating a proper model that is decoupled from a database is not that much effort. And it may benefit you greatly if you're building non trivial application Regards Karol Rob Allen-3 wrote: > > I would disagree with this. T

Re: [fw-general] Data models

2007-07-22 Thread Rob Allen
Bill Karwin wrote: > Right; I don't believe it's appropriate to assume that a "model" can > simply extend a table or row object. It's better to write your own > model class, extending nothing, that may use a table or row object, and > may also use other sources of data, such as a SOAP service. >

Re: [fw-general] RE: ZF is ubeatable BUT...

2007-07-22 Thread Simon Mundy
FWIW, I love the way Mootools (www.mootools.net) allows you to create your own download that's mix-n-matchable. It wouldn't be too hard to figure out how to work out dependencies for the more specific compents (PDF, Locale, etc.) so that you could tailor-make your own ZF download for your