Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • Submitting current timestamp in CakePHP

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 1.19k
    Comment on it

    Hi If you want to send curret_timestamp, you can store it by using function below.

    DboSource::expression('NOW()');
    

    Lets take an example, save your timestamp in a key 'your_datetime_field'

    $this->data['SomeModel']['your_datetime_field'] = DboSource::expression('NOW()');
    $this->Model->save($this->data);
    

    and then you can insert the data.

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: