Re: How create a observeField with the new JSHelper?

2010-05-04 Thread cguyer
how do i pass the data of the input box to the function? not even sure
$js-request is what i should use for this. Ideas is that as a person
types in a textbox, it does a search and updates a results div. help
=D


//form element
echo $form-
input('Facility.facility_name',array('size'='40','label'='Name or
Address'));


//Old Ajax Helper
echo $ajax-
observeField('FacilityFacilityName',array('update'='facilitylist','url'='update_facility','frequency'='1'));

//New Ajax Helper
$js-get('#FacilityFacilityName');
$js-event('keyup', $js-request('/users/
update_facility',array('update'='#facilitylist','data'=???)));

On May 3, 2:18 pm, cguyer colbygu...@gmail.com wrote:
 i'm also trying to figure out this myself, hacking through the new
 help and learning jquery. any help would also be appreciated.

 On Apr 30, 2:38 pm, Celso cels...@gmail.com wrote:

  Hi ! I want using the new JSHelper with Jquery, i need create a
  observeField to fill a combo with another combo that changed

  Thanks!
  Celso

  Check out the new CakePHP Questions sitehttp://cakeqs.organdhelp others 
  with their CakePHP related questions.

  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+unsubscr...@googlegroups.com For more options, visit this group 
  athttp://groups.google.com/group/cake-php?hl=en

 Check out the new CakePHP Questions sitehttp://cakeqs.organd help others with 
 their CakePHP related questions.

 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+unsubscr...@googlegroups.com For more options, visit this group 
 athttp://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: How create a observeField with the new JSHelper?

2010-05-04 Thread cguyer
I finally came up with a solution. I don't know if this is the best
solution but it looks like it will work. Will comment back in a day or
two if i remember =)

$js-get('#FacilityFacilityName')-event('keyup', $js-
request(array('controller'='users','action'='update_facility'),array('update'='#facilitylist','dataExpression'=true,'data'=
$js-serializeForm(array('isForm' = false, 'inline' = true)) )));

On May 4, 11:05 am, cguyer colbygu...@gmail.com wrote:
 how do i pass the data of the input box to the function? not even sure
 $js-request is what i should use for this. Ideas is that as a person
 types in a textbox, it does a search and updates a results div. help
 =D

 //form element
 echo $form-input('Facility.facility_name',array('size'='40','label'='Name 
 or

 Address'));

 //Old Ajax Helper
 echo $ajax-

 observeField('FacilityFacilityName',array('update'='facilitylist','url'='update_facility','frequency'='1'));

 //New Ajax Helper
 $js-get('#FacilityFacilityName');
 $js-event('keyup', $js-request('/users/
 update_facility',array('update'='#facilitylist','data'=???)));

 On May 3, 2:18 pm, cguyer colbygu...@gmail.com wrote:



  i'm also trying to figure out this myself, hacking through the new
  help and learning jquery. any help would also be appreciated.

  On Apr 30, 2:38 pm, Celso cels...@gmail.com wrote:

   Hi ! I want using the new JSHelper with Jquery, i need create a
   observeField to fill a combo with another combo that changed

   Thanks!
   Celso

   Check out the new CakePHP Questions sitehttp://cakeqs.organdhelpothers 
   with their CakePHP related questions.

   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+unsubscr...@googlegroups.com For more options, visit this group 
   athttp://groups.google.com/group/cake-php?hl=en

  Check out the new CakePHP Questions sitehttp://cakeqs.organdhelp others 
  with their CakePHP related questions.

  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+unsubscr...@googlegroups.com For more options, visit this group 
  athttp://groups.google.com/group/cake-php?hl=en

 Check out the new CakePHP Questions sitehttp://cakeqs.organd help others with 
 their CakePHP related questions.

 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+unsubscr...@googlegroups.com For more options, visit this group 
 athttp://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: How create a observeField with the new JSHelper?

2010-05-03 Thread cguyer
i'm also trying to figure out this myself, hacking through the new
help and learning jquery. any help would also be appreciated.

On Apr 30, 2:38 pm, Celso cels...@gmail.com wrote:
 Hi ! I want using the new JSHelper with Jquery, i need create a
 observeField to fill a combo with another combo that changed

 Thanks!
 Celso

 Check out the new CakePHP Questions sitehttp://cakeqs.organd help others with 
 their CakePHP related questions.

 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+unsubscr...@googlegroups.com For more options, visit this group 
 athttp://groups.google.com/group/cake-php?hl=en

Check out the new CakePHP Questions site http://cakeqs.org and help others with 
their CakePHP related questions.

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+unsubscr...@googlegroups.com For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en


Re: Datetime Concatenate in Controller

2009-01-02 Thread cguyer

I'm not trying to change the value, im simple trying to pull it into a
string so i can use it as a condition in an sql find.

On Jan 1, 10:25 am, WebbedIT p...@webbedit.co.uk wrote:
 As you are trying to change the value of a field before it is saved
 then the simplest way is to use PHP to directly manipulate the field
 value in the $this-data['Model'] array.  That way the model's save
 function will deal with the save automagically.

 Are you using the form helper to produce the date field in the form?
 If so, cake should worry about the formatting on your behalf.

--~--~-~--~~~---~--~~
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+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Datetime Concatenate in Controller

2008-12-31 Thread cguyer

I need to concatenate a datetime field from a view in a controller
before save (.i.e $this-data['Model']['datetime'][year],$this-data
['Model']['datetime'][month], etc.). I believe I need to use $date=
$this-Model-set(??) which calls deconstruct but from the api im not
able to figure out the syntax to get it to work. Any help?

--~--~-~--~~~---~--~~
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+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: PostgreSQL Update Query and the trouble with aliases

2008-04-07 Thread cguyer

and yet this error is still around even with the latest branch? has it
been broken again?

On Feb 15, 12:23 pm, nate [EMAIL PROTECTED] wrote:
 Please do everyone else a favor and search around a little bit next
 time.  This bug has already been reported a zillion times, and was
 fixed weeks ago.

 On Jan 21, 8:58 am, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

  I'm having trouble makingUPDATEqueries in PostgreSQL. I know that
  there is a known issue aboutPostgresnot supporting aliases inUPDATE
  queries. Anyway, my problem is that when I try to create new Aro like
  this:

  $parent = $this-Acl-Aro-findByAlias('SuperUser');
  $parentId = $parent['Aro']['id'];

  $this-Acl-Aro-create();
  $this-Acl-Aro-save(array(
  'foreign_key' = null,
  'parent_id' = $parentId,
  'alias' = 'User:30'));

  I get the followingerror:

  Warning (2): pg_query() [function.pg-query]: Query failed:ERROR:
  column Aro of relation aros does not exist
  LINE 1:UPDATEaros AS Aro  SET Aro.lft = Aro.lft + 2
  W...
  ^ [CORE\cake\libs\model\datasources
  \dbo\dbo_postgres.php, line 123]
  $sql=   UPDATEaros AS Aro  SET Aro.lft = Aro.lft + 2
  WHERE Aro.lft =  '2'

  I've already posted a bug to trac.cakephp.org... the reason for this
  message is that I would like to ask everybody for help on creating
  some quick solution or patch for this problem.

  P.S. This problem with aliases isn't just a one time thing, it is and
  will be happening until cakephp developers move the method
  renderStatement from dbo_source.php to each dbo file. It should work
  as it is, but it doesn't, they should all follow SQL standards but
  they don't. So, my suggestion is to make renderStatement in every dbo.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups Cake 
PHP group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---