Forms to create Users from another controller

2009-01-17 Thread WidePixels
Ok here is the dilema. I need to create 2 user forms basically the same, but they have different validations. The forms are identical only differance is the validation on the contractor checks the email field for free email accounts which are not allowed so i split the forms up into separate

Re: Variable state through multiple Ajax requests (ModalBox) including forms

2009-01-16 Thread WebbedIT
Resolved thanks to Martin's help in the following thread ... http://groups.google.com/group/cake-php/browse_thread/thread/cf431215392af9bb/3e927decddb4f1b2#3e927decddb4f1b2 --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Gro

Re: Questions about forms / validation

2009-01-15 Thread fly2279
On the first part of the question you can do an 'on' => 'create' so that it doesn't run that portion of validation when updating a record. http://book.cakephp.org/view/131/on I'll let someone more experienced answer the second part about population. On Jan 15, 1:45 am, Miles J wrote: > So Im w

Re: Questions about forms / validation

2009-01-15 Thread Miles J
Any help would be lovely! --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubsc

Re: Questions about forms / validation

2009-01-15 Thread Miles J
My date validation keeps failing also, but its in the correct format: [birthdate] => 02-26-1988 'birthdate' => array( 'rule' => 'date', 'message' => 'birthdateInvalid', ) --~--~-~--~~~---~--~~ You received this message because you are subscribed to

Questions about forms / validation

2009-01-14 Thread Miles J
So Im working on this area where users can edit their profile, etc. All the validation works, its just on the email field it always errors because I am using the isUnique rule. It keeps erroring because the email in the input is THEIR email, and it does exist in the database. So it keeps throwing

Re: Variable state through multiple Ajax requests (ModalBox) including forms

2009-01-13 Thread WebbedIT
Would love to share what I have learnt, but would prefer to do so after I have a fully working example. I will also provide a demo of it in use the way I am using it as it is quite neat and should be something most people could use. Also I can get some feedback on it's positives and negatives th

Re: Variable state through multiple Ajax requests (ModalBox) including forms

2009-01-13 Thread Chad Casselman
al window > (Index, Add, Edit, Delete). > > In my opinion I have also implemented ModalBox much better by > adjusting how links and forms are submitted within the window so that > ModalBox does the hard work of displaying the spinner whilst the > content is updated and then resizes th

Re: Variable state through multiple Ajax requests (ModalBox) including forms

2009-01-13 Thread WebbedIT
27;s worth of actions within a single modal window (Index, Add, Edit, Delete). In my opinion I have also implemented ModalBox much better by adjusting how links and forms are submitted within the window so that ModalBox does the hard work of displaying the spinner whilst the content is update

Re: Variable state through multiple Ajax requests (ModalBox) including forms

2009-01-13 Thread Siegfried Hirsch
Hello Paul, this one has helped me a lot in using modalbox: http://nerdnotes.org/2008/02/28/combining-modalbox-cakephp/ On Tue, Jan 13, 2009 at 4:45 PM, WebbedIT wrote: > > Hi, > > I am having a fair amount of success with ModalBox after playing > around with it for a couple of days. > > http:

Variable state through multiple Ajax requests (ModalBox) including forms

2009-01-13 Thread WebbedIT
Hi, I am having a fair amount of success with ModalBox after playing around with it for a couple of days. http://www.wildbit.com/labs/modalbox/ My reason for wanting to use modal windows in my app is that the following models can all have unlimited Telephone Numbers Organisation, Person, Schem

Re: Multiple forms per page, field IDs need to be unique

2009-01-12 Thread mark_story
specify the id attribute? -Mark On Jan 12, 6:05 am, Chris Hawes wrote: > Hello, > > I'm currently working on an e-commerce application. > > On the product pages, I am generating a form to add products to the > cart. As such, each page can contain several forms. > >

Re: Multiple forms per page, field IDs need to be unique

2009-01-12 Thread brian
nce) but If it was me doing it I would instead of using forms I would > just add links in the form /produtcs/addtocart/45 or > /products/addtocart/VeryNiceProduct and then use the flash function to > redirect back to the products page noting which products are added to the > cart. Like

Re: Multiple forms per page, field IDs need to be unique

2009-01-12 Thread Rogelio Nodal
I'm new to CakePHP(day of reading documentation is pretty much my experience) but If it was me doing it I would instead of using forms I would just add links in the form /produtcs/addtocart/45 or /products/addtocart/VeryNiceProduct and then use the flash function to redirect back to the pro

Multiple forms per page, field IDs need to be unique

2009-01-12 Thread Chris Hawes
Hello, I'm currently working on an e-commerce application. On the product pages, I am generating a form to add products to the cart. As such, each page can contain several forms. I've created a helper for my application which contains: product display; add to cart form genera

Re: set checkboxes on multiple forms

2009-01-02 Thread brian
On Fri, Jan 2, 2009 at 11:53 PM, brian wrote: > I have an admin_index page for a model that requires a listing for > each row, which includes a *separate* form with a couple of > checkboxes. The controller action is: > > public function admin_index() > { >$this->data = $this->paginate();

set checkboxes on multiple forms

2009-01-02 Thread brian
I have an admin_index page for a model that requires a listing for each row, which includes a *separate* form with a couple of checkboxes. The controller action is: public function admin_index() { $this->data = $this->paginate(); } Now, in the view, I cannot figure out how to get the For

Security component and AJAX forms

2009-01-01 Thread archF6
em. I can use the blackhole callback to circumvent the issue by determining controller name and action, but would prefer to keep security component enabled for these forms if possible. The reason for such an approach is this... Basically a blog with comments, but product developers want people to w

Re: How to make forms in cakephp

2008-12-23 Thread eMarcus
Hi Mona, Well, it would help if you could specify the error a bit more. The form need to be called 'app/views/users/add.ctp'. I don't know if you can make "echo $form->inputs(array('name', 'email', 'password'));" I would rather do: echo $form->input('User.name'); echo $form->input('User.pas

How to make forms in cakephp

2008-12-23 Thread mona
I m new to cake php i want to make form in cakephp and i make the following things class User extends AppModel { var $name = 'User'; var $validate = array( 'name'=>array('rule'=>'notEmpty'), 'email'=>array('rule'=>'email'), 'password'=>array(

Re: cake 1.2 forms: date fields left empty => null in database?

2008-12-18 Thread Sebastian Göttschkes
Hi, thanks for your reply. The data field was set to null before. If I update a dataset and assigning the null value to a the birthday field (SET birthday=null) it works fine. So I added the following code to my controller: if(empty($this->data['Employee']['birthday'])) $this->data['Emplo

Re: cake 1.2 forms: date fields left empty => null in database?

2008-12-17 Thread Adriano Varoli Piazza
On 16 dic, 11:44, Sebastian Göttschkes wrote: > Additionally, if I add a valid birthday, it is saved correctly. When > editing the employee, I would like to get the birthday viewed in the > format dd.mm.. How can I tell cake to view the birthday like this? Ok, here's what I've done: in the

Re: cake 1.2 forms: date fields left empty => null in database?

2008-12-16 Thread Adriano Varoli Piazza
I am in the process of editing my views to get a similar effect. If you can wait a couple hours, I'll be back with an explanation. But, to whet your appetite: controlling for '-00-00' is not that different from controlling for null, seems to me. '-00-00' is the 'null value' for a date fie

AW: cake 1.2 forms: date fields left empty => null in database?

2008-12-16 Thread Liebermann, Anja Carolin
pe that helps. Be careful what format to validate! Anja -Ursprüngliche Nachricht- Von: cake-php@googlegroups.com [mailto:cake-...@googlegroups.com] Im Auftrag von Sebastian Göttschkes Gesendet: Dienstag, 16. Dezember 2008 14:45 An: CakePHP Betreff: cake 1.2 forms: date fields left empty

Re: cake 1.2 forms: date fields left empty => null in database?

2008-12-16 Thread Alexandru Ciobanu
Sebastian Göttschkes wrote: > Hi, > > i got the following problem using cakePHP 1.2 RC3: > > My Model 'Employee' has a attribute called 'birthday' (datatype: > DATE). In the add-view, I have the following code: > input('birthday',array('type'=>'text'));?> > If i left this field blank when adding a

cake 1.2 forms: date fields left empty => null in database?

2008-12-16 Thread Sebastian Göttschkes
Hi, i got the following problem using cakePHP 1.2 RC3: My Model 'Employee' has a attribute called 'birthday' (datatype: DATE). In the add-view, I have the following code: input('birthday',array('type'=>'text'));?> If i left this field blank when adding an employee, this employee has the birthday

Re: Prepopulating forms via the URL

2008-12-15 Thread acoustic_overdrive
Hi, thanks both for your replies. @Alexandru: Unfortunately that's not flexible enough for me, because depending on where I'm coming from I may or may not want to pre- populate a field. @brian: I usually do it something like /project_images/add/project_id: 3 but that means I have to write logic

Re: Prepopulating forms via the URL

2008-12-15 Thread brian
On Mon, Dec 15, 2008 at 1:18 PM, acoustic_overdrive wrote: > > I just thought of a little function that I wanted to get some feedback > on. It's a way to pre-populate a form when adding new records, using > the URL only and no controller-specific controller logic. > > In AppController::beforeRend

Re: Prepopulating forms via the URL

2008-12-15 Thread Alexandru Ciobanu
acoustic_overdrive wrote: > I just thought of a little function that I wanted to get some feedback > on. It's a way to pre-populate a form when adding new records, using > the URL only and no controller-specific controller logic. > > In AppController::beforeRender : > > if(isset($_REQUEST['populat

Prepopulating forms via the URL

2008-12-15 Thread acoustic_overdrive
I just thought of a little function that I wanted to get some feedback on. It's a way to pre-populate a form when adding new records, using the URL only and no controller-specific controller logic. In AppController::beforeRender : if(isset($_REQUEST['populate'])) { if(empty($this->data))

Re: adding info from forms to more then one table

2008-12-09 Thread webscriptz
I'm going to give a better description of the problem When I add a record the data will be stored in the records table of my database what I want to do is: When my records is saved the system should do something like this, when it's saved call the timespan that is selected, load the saldo debet

Re: adding info from forms to more then one table

2008-12-09 Thread webscriptz
I was thinking like this: function add() { if (!empty($this->data)) { $this->Timespan->create(); if ($this->Timespan->save($this->data)) { $this->data['Timespan']['saldo'] = $this->data['Timespan'] ['

Re: Managing empty data in forms with associations

2008-12-09 Thread majna
Maybe you can use $this->data['Users'] = Set::filter($this->data['Users']); On Dec 8, 8:52 pm, variaas <[EMAIL PROTECTED]> wrote: > Does CakePHP have a function to clear out empty datarows before > saving? Right now I manually parse the array to see if there is an > empty array and unset it. > >

Managing empty data in forms with associations

2008-12-08 Thread variaas
Does CakePHP have a function to clear out empty datarows before saving? Right now I manually parse the array to see if there is an empty array and unset it. So given this array: [data] => [0] => [name] => 'alice' [1] => [name] => 'bob' [2] => [name] => '' I would unse

Re: correct way to create multiple text forms in a table

2008-12-03 Thread Todd M
I wanted to use a table that is XxY wide. So in my original example there was 2 entries for both X & Y from the findAll functions. This would produce a 2x2 table. The part that I don't quite understand is how to create the forms with knowledge of the X's & Y's ID. so I

Re: correct way to create multiple text forms in a table

2008-12-02 Thread brian
Could you query again, but without all the table display stuff? You have 4 text boxes in a view and ... what? What's the model name, and what models is it associated to (and how)? Or is it 4 separate forms? 5? On Wed, Dec 3, 2008 at 12:27 AM, Todd M <[EMAIL PROTECTED]> wrote: >

correct way to create multiple text forms in a table

2008-12-02 Thread Todd M
is to have one submit and the controller will will call a model->saveall function. However of the text box forms has a id associated to the top row and leftmost column. In other words the form is saving to a model that has belongsTo association with the top row and left. Is there something that I&#

Re: adding info from forms to more then one table

2008-12-02 Thread Rob
I would suggest looking at saveAll to do the save part, then to do your addition you just need to make sure it's in the data. That said, here's the way I handle adding a related record as shown in your add() above: function add() { if (!empty($this->data)) {

Re: adding info from forms to more then one table

2008-12-02 Thread webscriptz
normally i would read it out with php, put them in vars and addition the values and resave them. On Dec 2, 10:49 am, webscriptz <[EMAIL PROTECTED]> wrote: > Sorry for that, > > I have a model Records and Timespans. DEBET and CREDIT have to be > inserted in the records table but also in the Timesp

Re: adding info from forms to more then one table

2008-12-02 Thread webscriptz
Sorry for that, I have a model Records and Timespans. DEBET and CREDIT have to be inserted in the records table but also in the Timespans table in DEBET and CREDIT The first is not a problem but the second is. IT has to be additioned not just replaced by the latest. function add() {

Re: adding info from forms to more then one table

2008-12-01 Thread Rob
So just a suggestion for future questions, describe the tables and their relationship in your question a little next time. Assuming you have a Records model and a Timespans model that are related to each other, and the relationships are described in the models for those two entities ... So, for

adding info from forms to more then one table

2008-12-01 Thread webscriptz
I'm making a register and I have a small problem, I want two numbers to be additioned (+) with the numbers already in an other table, unfortunantly I don't know how to do this. i have a Record with "debet" and "credit" and i want to addition them to "debet" and "credit" in timespans. but they g

Re: Working with forms for CMS

2008-11-22 Thread Jon Bennett
> 1. The value appears to be set early on the life of the model, so > overriding afterwards has no affect on the fields array cake uses for > form->inputs(). 'The value' of SCHEMA! crucial piece of info forgotten there! j -- jon bennett w: http://www.jben.net/ iChat (AIM): jbendotnet Skype

Re: Working with forms for CMS

2008-11-22 Thread Jon Bennett
Hi Flipflops, > > class FormsController extends AppController { > > > > var $name = 'Forms'; > > > > /** > > * a generic method to handle the submited forms > > * looks up a schema / and va

Re: Working with forms for CMS

2008-11-20 Thread Jon Bennett
Hi Flipflops, Nice one, sorry for delayed response but been sidetracked by another project. > class FormsController extends AppController { > > var $name = 'Forms'; > > /** > * a generic method to handle the submited forms > * loo

Re: need help with forms and ajax

2008-11-19 Thread mmm
already found a solution to it! thanks anyway! On 19 Nov., 13:15, mmm <[EMAIL PROTECTED]> wrote: > hi group, > i'm missing something really simple and i need your help, i have a > simple form in my view, when a user presses submit button i want to > send form data to controller( or view) and get

need help with forms and ajax

2008-11-19 Thread mmm
hi group, i'm missing something really simple and i need your help, i have a simple form in my view, when a user presses submit button i want to send form data to controller( or view) and get the result back in the ajax callback, updating one singe div on the view. how can actually do that? pleas

Re: Working with forms for CMS

2008-11-19 Thread Flipflops
Hi Jon, Dardo I guess it depends how hacky you want to be. You could have two models one that manages the form builder and another which is really just a shell that would validate the actual forms when you submit them. Off the top of my head I guess you could do something like this (not tried

Re: Working with forms for CMS

2008-11-18 Thread Dardo Sordi Bogado
> so did I - but I've just realised that my 'EmailForm' model would have > it's own schema, at least: Why don't use two models: one for handling the validation of the dynamic forms and one for storing the metadata in the DB. Then in the dynamics forms, you can o

Re: Working with forms for CMS

2008-11-18 Thread Jon Bennett
Hi Flip flops, > Passing the schema and validation rules seems like a good idea - I'm > guessing your are thinking you could couple it with some kind of > wizard / interface so you build your forms within the CMS... could be > a really goood feature but at the end of the day

Re: Working with forms for CMS

2008-11-18 Thread Flipflops
Hi Passing the schema and validation rules seems like a good idea - I'm guessing your are thinking you could couple it with some kind of wizard / interface so you build your forms within the CMS... could be a really goood feature but at the end of the day it boils down to how long the in

Re: Working with forms for CMS

2008-11-18 Thread Jon Bennett
> It seems pretty strightforward to do, why don't give it a try and then > tell us how it went? Am just thinking things through a little further. I was thinking about how I would set the _schema and validate values. I had thought about calling a method in afterFind, but they aren't run for assoc

Re: Working with forms for CMS

2008-11-18 Thread Dardo Sordi Bogado
> What about adding 2 fields to Forms: > > Forms > - id > - name > - schema (serialised obj) > - validation_rules (serialised obj) > > And then passing the values of each to the Form model in beforeValidate? It seems pretty strightforward to do, why don't give

Re: Working with forms for CMS

2008-11-18 Thread Dardo Sordi Bogado
> Often I have to work with forms, contact forms, email sign ups etc > that are then embedded in each page, and I'd really like to use the > cake validation and auto magic, whilst avoiding manually creating a > model for each form. What is wrong with creating a Model for han

Re: Working with forms for CMS

2008-11-18 Thread Jon Bennett
Hi bakers, > Got a theory/approach question, hoping someone's been down this route > already. > > A lot of my projects are CMS'd sites. This largely means a few models: > > * Page > * Article > * Documents (files, images, media etc) > > Often

Working with forms for CMS

2008-11-17 Thread Jon Bennett
Hi folks, Got a theory/approach question, hoping someone's been down this route already. A lot of my projects are CMS'd sites. This largely means a few models: * Page * Article * Documents (files, images, media etc) Often I have to work with forms, contact forms, email sign ups et

Re: Handy trick for forms that down offer all fields from model.

2008-11-13 Thread teknoid
'requied'=>true, is rarely necessary. You are probably more interested in the 'notEmpty' rule. If you read the manual (ans possibly my post above), you'll see why 'required' doesn't exactly mean what you'd expect. Using the default value of false, will help you to avoid any trickery (unless you tr

Re: Handy trick for forms that down offer all fields from model.

2008-11-13 Thread teknoid
I assume you had 'required'=>true as part of the validation rules. Seems like, yet another, misunderstanding :) http://teknoid.wordpress.com/2008/11/04/requiredtrue-the-source-of-major-confusion/ On Nov 13, 9:02 am, Josey <[EMAIL PROTECTED]> wrote: > As a relatively new baker and programmer, for

Handy trick for forms that down offer all fields from model.

2008-11-13 Thread Josey
As a relatively new baker and programmer, for that matter, I ran into a problem earlier this week. I was creating a form for users to edit their information however, not all fields were present in this form for the general member but those fields happened to be required fields. In the model those

Accessibility and forms

2008-11-09 Thread イタリア人
Hello all, although putting tags in the right order does not make an accessible website, I was wondering if anyone is really looking at priority AAA for accessible websites and updated the form helper... Anyone ? Julien --~--~-~--~~~---~--~~ You received this mes

Re: validation conflicts: two forms, one model, one page

2008-10-27 Thread RyOnLife
It's a workaround, but did the trick: $('#FormName .error-message').hide() -- View this message in context: http://n2.nabble.com/validation-conflicts%3A-two-forms%2C-one-model%2C-one-page-tp1370230p1382883.html Sent from the CakePHP mailing list archiv

Re: validation conflicts: two forms, one model, one page

2008-10-27 Thread Christian Leskowsky
shows the message on the > 'username' field > in the registration form and the 'login' form. How can I contain the > error > message to the appropriate form? > -- > View this message in context: > http://www.nabble.com/validation-conflicts%3A-

validation conflicts: two forms, one model, one page

2008-10-23 Thread RyOnLife
;login' form. How can I contain the error message to the appropriate form? -- View this message in context: http://www.nabble.com/validation-conflicts%3A-two-forms%2C-one-model%2C-one-page-tp20141502p20141502.html Sent from the CakePHP mailing list archive at Nabble.com. --~--~-~-

Re: Auth component and ajax forms

2008-10-03 Thread CG
you need. HTH, CG On Oct 2, 4:17 pm, RobertoSDN <[EMAIL PROTECTED]> wrote: > Hello, i am using ajax forms and i have a problem with the Auth > component that works fine with the login action but not with others > actions because only the login action has the bahavior to render

Auth component and ajax forms

2008-10-02 Thread RobertoSDN
Hello, i am using ajax forms and i have a problem with the Auth component that works fine with the login action but not with others actions because only the login action has the bahavior to render a element to handle errors like bellow: if ($loginAction == $url) { ...code } else { if

Re: CakePHP 1.1, AJAX and forms not doing anything.

2008-09-30 Thread aka
Yes Sorry clemos, was alittle tired on this afternoon. Here is the question completely rewritten :) 1. Download the latest stable release of CakePHP (1.1.19.6305) 1.1 Set it up and running. 2. Download the prototype.js library and copy it to your fresh cake installation "js" -folder. 3. Lets c

Re: CakePHP 1.1, AJAX and forms not doing anything.

2008-09-30 Thread clemos
Hi You should at least give the code from your view, so that we can figure out what's going on. Also, english is not my mother language, and I don't understand this sentence : > However, the $ajax->link's works just fine and when I click one of the > links, resultin an update to the that element

CakePHP 1.1, AJAX and forms not doing anything.

2008-09-30 Thread aka
Hi! I have a controller, which fetches other controllers data through requestAction(). The first element contains a form in which there is an $ajax- >submit(...); the problem here is that the form does nothing. The form doesen't even send XHR request. However, the $ajax->link's works just fine

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread Brett Wilton
pr($this->validationErrors) in your view will show you the errors. --- Brett Wilton http://wiltonsoftware.com On Fri, Sep 19, 2008 at 12:31 PM, David C. Zentgraf <[EMAIL PROTECTED]> wrote: > > On 18 Sep 2008, at 23:53, 703designs wrote: > >> So a rendered view will automatically receive validati

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread David C. Zentgraf
On 18 Sep 2008, at 23:53, 703designs wrote: > So a rendered view will automatically receive validation messages? In > which variable? Yes. When a model is validated in the controller, invalid fields will be noted in a variable. Don't know of the top of my head in which one, do a debug($this)

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread 703designs
So a rendered view will automatically receive validation messages? In which variable? If I need to set a var, what should my target be ($this->set('errors', /* what here? */))? I tried substituting a minLength 1 rule yesterday and if it worked, I would not have changed it, although I can't with ce

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread David C. Zentgraf
I'm not 100% sure, but I think older versions of Cake required you to specify a rule. If you're only interested in the 'required' field, specify a rule that'll always validate, like '/.*/' . What version of Cake are you using? Structure your app the way you see fit. It's not good form to us

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread 703designs
Note that each ['validate'] key also has a normal ['message'] defined, saying that the field in question is required. On Sep 18, 9:29 am, "David C. Zentgraf" <[EMAIL PROTECTED]> wrote: > On 18 Sep 2008, at 21:50, 703designs wrote: > > > I got funny preg_match errors > > Show us your $validate rul

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread 703designs
Right, that was a typo, not a paste. I think that you'll be able to better help me if you understand how I've designed my contact form: Model: Contact[name, email, city, subject, message, and a couple others] Model['validate']: Name, email, and message have 'required' => true Views: index (just p

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread David C. Zentgraf
On 18 Sep 2008, at 21:50, 703designs wrote: > I got funny preg_match errors Show us your $validate rules then or go through them with a fine comb. > $this->Contact->set('$this->data); I hope this is not copy&pasted as it's invalid PHP. > This controller's 'add' method just sends out emails >

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread 703designs
I saw that last night before posting, and wrapping the send sequence in this conditional didn't work: I got funny preg_match errors (also noted here: http://ryan.ifupdown.com/2008/08/24/delimiter-must-not-be-alphanumeric-or-backslash-corecakelibsmodelmodelphp-line-2202/ , although his fix didn't

Re: Forms not validating while using EmailComponent?

2008-09-18 Thread David C. Zentgraf
Are you looking for this? http://book.cakephp.org/view/410/Validating-Data-from-the-Controller On 18 Sep 2008, at 13:51, 703designs wrote: > > How can I check if the data is valid before trying to send the mail > out? Validation errors are falling into the "email failed" condition, > and validat

Forms not validating while using EmailComponent?

2008-09-17 Thread 703designs
How can I check if the data is valid before trying to send the mail out? Validation errors are falling into the "email failed" condition, and validation errors aren't reported to the user. --~--~-~--~~~---~--~~ You received this message because you are subscribed to

upgrading to 1.2 and non-ascii characters in forms

2008-09-13 Thread igor
Hello, I'm in a middle of migrating a project from cake 1.1 to 1.2. I've got most pages to display, but I ran into one problem with forms. Source code in a view goes like this: $miesiace=array('Styczeń','Luty','Marzec','Kwiecień','Maj&

Re: Edit forms in Internet Explorer

2008-09-13 Thread chicklin
Wow, that's pretty obscure. Yes, I'm using mod_auth_sspi. It was so easy to set up, I hate to change to LDAP, but it looks like that's going to be necessary. Thanks for the suggestion, I'll give it a try. On Sep 12, 6:32 pm, Niko <[EMAIL PROTECTED]> wrote: > I was having the exact same problem

Re: Edit forms in Internet Explorer

2008-09-12 Thread Niko
I was having the exact same problem until I disable the mod_auth_sspi module. I then replaced it with mod_authnz_ldap and everything works fine. Maybe you can check something at a module level. When I set a proxy between the web server and IE I found out that when it got stuck all the server got w

Re: Edit forms in Internet Explorer

2008-09-09 Thread chicklin
There is no Javascript in the page whatsoever. If you read through the controller logic, the only way that the form will return to itself without doing anything is if $this->data is not set (i.e. empty($this- >data)). Here is the controller: Domain->recursive = 0; $this->set('d

Re: Edit forms in Internet Explorer

2008-09-09 Thread scs
I suggest posting the view and controller. The first thing I would look at is there any JavaScript that IE is having issue with. On Sep 9, 10:46 am, chicklin <[EMAIL PROTECTED]> wrote: > Hello, using cake_1.2.0.7296-rc2 under Apache/PHP5/Windows > > I'm having a problem where when I submit a form

Edit forms in Internet Explorer

2008-09-09 Thread chicklin
Hello, using cake_1.2.0.7296-rc2 under Apache/PHP5/Windows I'm having a problem where when I submit a form to edit a database entity, the controller sometimes does not recognize $this->data as being set and sends me back to the orignal edit form. The weird thing is, that if I try it a couple tim

Multiple AJAX forms per page from the same source

2008-09-07 Thread Warringer
I have a database driven galery. CREATE TABLE EXISTS `galeries` ( `id` int(11) NOT NULL auto_increment, `year` year(4) NOT NULL, `titel` tinytext NOT NULL, `subtitle` tinytext NOT NULL, `folder` tinytext NOT NULL, PRIMARY KEY (`id`) ) CREATE TABLE EXISTS `images` ( `id` int(11) N

Re: Handling HTML special chars from user generated content ( e.g. forms)

2008-08-29 Thread Mark (Germany)
i dont see the reason for changing them to HTML code anyway - as with utf8 they can all be handled and displayed as they originally are. On 28 Aug., 17:46, worthy <[EMAIL PROTECTED]> wrote: > You saved my day. :D > > I was messing with this problem the whole day and never thought it > would be t

Re: Handling HTML special chars from user generated content ( e.g. forms)

2008-08-28 Thread worthy
You saved my day. :D I was messing with this problem the whole day and never thought it would be that simple :). Thank you so much for this simple solution! Greetings worthy On 28 Aug., 17:38, Günther Theilen <[EMAIL PROTECTED]> wrote: > Hi, > > do you use the form helper? > If so try somethin

Re: Handling HTML special chars from user generated content ( e.g. forms)

2008-08-28 Thread Günther Theilen
Hi, do you use the form helper? If so try something like this: $form->input('foo.bar', array('escape' => false)) Regards Guenther worthy schrieb: > Another explaining example for the edit form: > > http://localhost/regions/edit/15 > > data['Regions']['id']=15 > data['Regions']['name']='Test

Re: Handling HTML special chars from user generated content ( e.g. forms)

2008-08-28 Thread worthy
Another explaining example for the edit form: http://localhost/regions/edit/15 data['Regions']['id']=15 data['Regions']['name']='Test ä' Now when cakephp fills the form with this data the value of the field changes from 'Test ä' to 'Test ä' And so the field shows 'Test ä instead of 'Test

Re: Handling HTML special chars from user generated content ( e.g. forms)

2008-08-28 Thread worthy
Hi bakers again :), i managed to do it another way. These two function provided below are the key for it. As you can see I placed them inside of the app_controller.php class AppController extends Controller { function htmlchars($data) { if (empty($data)) {

Handling HTML special chars from user generated content ( e.g. forms)

2008-08-28 Thread worthy
Hi bakers, as by the last week i am really getting into CakePHP and enjoy the easeness of the creation process. But i have one simple problem. In every form of the project where users can input data, they can for example input ( ä,ö,ü, é... and special chars like %§"%/ or whatever) So i want to

Re: Forms not associated to models - alternative to the Form core helper?

2008-08-27 Thread RichardAtHome
> > On Aug 26, 11:15 am, validkeys <[EMAIL PROTECTED]> > wrote: > > > Hey Enrique, > > > You could still use the regular forms: > > > create('Search',array('url' => '/search','type' => > > 'get&#

Re: Forms not associated to models - alternative to the Form core helper?

2008-08-26 Thread Enrique Delgado
for pointing this out. I was getting too caught up and spoiled by the input() automagic method, my bad. Using the regular methods works just fine. Thanks! On Aug 26, 11:15 am, validkeys <[EMAIL PROTECTED]> wrote: > Hey Enrique, > > You could still use the regular forms: > >

Re: Forms not associated to models - alternative to the Form core helper?

2008-08-26 Thread validkeys
Hey Enrique, You could still use the regular forms: create('Search',array('url' => '/search','type' => 'get')) ?> text('query',array('type' => 'textarea')) ?> end('Search!') ?> On Au

Re: Forms not associated to models - alternative to the Form core helper?

2008-08-26 Thread Samuel DeVore
On Tue, Aug 26, 2008 at 8:45 AM, Enrique Delgado <[EMAIL PROTECTED]> wrote: > > Hi All, > > The core Form helper works great as long as you have a model behind > it, but what about forms that are not related to a model? > > Is there any helpers that I can use in

Forms not associated to models - alternative to the Form core helper?

2008-08-26 Thread Enrique Delgado
Hi All, The core Form helper works great as long as you have a model behind it, but what about forms that are not related to a model? Is there any helpers that I can use in the view? Or do I just code plain HTML? Thanks! --~--~-~--~~~---~--~~ You received this

Re: One to many forms with ajax

2008-07-13 Thread Andraž
Hm, I see, that i didn't reply to this post. :( http://groups.google.com/group/cake-php/browse_thread/thread/3f707d87836750ab On Jul 12, 9:12 pm, Andraž <[EMAIL PROTECTED]> wrote: > Did you find the solution? --~--~-~--~~~---~--~~ You received this message becaus

Re: One to many forms with ajax

2008-07-12 Thread Andraž
Did you find the solution? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTE

Re: Possible security risk when saving data in forms - adding fields

2008-07-05 Thread the_woodsman
I think you can also do this globally for a model using its $whitelist field. On Jul 5, 7:11 am, "Dr. Tarique Sani" <[EMAIL PROTECTED]> wrote: > On Sat, Jul 5, 2008 at 11:37 AM, phpjoy <[EMAIL PROTECTED]> wrote: > > > Throughout the examples in the manual (1.2 and 1.1), I haven't noticed > > any

Re: Possible security risk when saving data in forms - adding fields

2008-07-04 Thread Dr. Tarique Sani
On Sat, Jul 5, 2008 at 11:37 AM, phpjoy <[EMAIL PROTECTED]> wrote: > > Throughout the examples in the manual (1.2 and 1.1), I haven't noticed > any reminder of that possible risk, though I noticed the bad > http://api.cakephp.org/1.2/class_model.html#ebe42ae387be89985b5a35dd428f5c81 Notice the t

<    1   2   3   4   5   6   7   >