Re: Date picker for CakePHP 2.0.3

2014-12-27 Thread Sandeep Kumar
Thank you Florin Trifu for your answer, it saved a lot of time..

I made some changes to script to include date format to hope that helps 
someone else

script
$(function() {
   $(.datepicker).datepicker(
{
   dateFormat: 'yy-mm-dd',
   onSelect: function(dateText, inst){
 $('#select_date').val(dateText);
 $(#datepicker).datepicker(destroy);
  }
}
   
   
   );
});
/script





On Wednesday, November 30, 2011 4:11:27 AM UTC+4, Florin Trifu wrote:

 Thank you very much! Indeed it worked.

 Just to let the other users know in case they will have the same problem:

 1. Download jquery (http://docs.jquery.com/Downloading_jQuery) and put 
 the file in $project/app/webroot/js (e.q: 
 *$project/app/webroot/js/jquery.js*)
 2. Download jquery-ui (http://jqueryui.com/download); I, for example, 
 downloaded a zip archive called: jquery-ui-1.8.16.custom.zip. From this 
 archive you will have to copy the followings:

 a. *$archive_root/js/jquery-ui-*.js* in *$project/app/webroot/js* (give 
 it a shorter name e.q: jquery-ui.js)
 b. *$archive_root/css/smothness/** to *$project/app/webroot/css* 
 (including the images; rename the css file to something shorter)

 3. Include both js files in your layout. eq:






 *//$project/app/views/Layouts/default.ctp-echo
  
 $this-Html-script(array('jquery', 
 'jquery-ui'));*4. Include the css file. Eq





 *//$project/app/views/Layouts/default.ctp 
 -echo 
 $this-Html-css('jquery-ui.css');*5. Put this lines of code before 
 calling the date-picker:





 *script$(function() {$(#datepicker).datepicker();});/script*

 6. Call the date picker in your form:





 *echo $this-Form-input('expire', array(   
 'id'='datepicker','type'='text')*

 This is it!

 Best regards!




-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
CakePHP group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: mysql gone away

2012-04-04 Thread Sandeep Kumar
Miles, it is in cli...


On Wed, Apr 4, 2012 at 4:14 AM, Miles J mileswjohn...@gmail.com wrote:

 Are these PDFs being created in the CLI/cron? If not, they should be.


 On Tuesday, April 3, 2012 12:54:27 AM UTC-7, Sandy wrote:

 HI There,

 I'm facing a big problem with cakephp 1.2

 first one is that cakephp is creating connection with mysql using
 mysql_pconnect, but in database.php I've set persistent to false.
 For this I've changed core files and change mysql_pconnect to
 mysql_connect. I know it is not a good idea. could any body suggest me
 a better one, as mysql is not changing the connection type from
 database.php

 second one, I'm creating pdf and excel reports using html2pdf library,
 while creating small reports it works fine, But when a report with
 large data is provided it takes about 40+ minutes to created the
 report in this case my report get created but after creating the
 report, I need to send a email alert to users about the report, for
 which I've to pick some data from database and at this time I get an
 error
 Mysql gone away 2006

 I've increase

 mysql_wait_timeout

 max_allowed_packet

 but not succeeded.

 Could any one suggest me what to do to figure out this problem.

 Thanks in advance

  --
 Our newest site for the community: CakePHP Video Tutorials
 http://tv.cakephp.org
 Check out the new CakePHP Questions site http://ask.cakephp.org and help
 others with their CakePHP related questions.


 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


-- 
Our newest site for the community: CakePHP Video Tutorials 
http://tv.cakephp.org 
Check out the new CakePHP Questions site http://ask.cakephp.org and help others 
with their CakePHP related questions.


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