THEME COLOR
I am trying to convert a date from yyyy-mm-dd to dd-mm-yyyy (but not in SQL); however I don't know how the date function requires a timestamp, and I can't get a timestamp from this string.
How is this possible?
Use Can Use strtotime() and date():
strtotime()
date()
$originalDate = "2010-03-21"; $newDate = date("d-m-Y", strtotime($originalDate));
(see strtotime and date docs on the PHP site).
Post Your Answers
विश्व में सर्वाधिक बड़ा, छोटा, लम्बा एवं ऊँचा की सूची क्या है ..?
How many types we show dates in PHP ie Formatting of date function in PHP . ?
How to Increase Import Size Limit in phpMyAdmin using Xampp server?
Get a substring between two strings in PHP
What is mysqLi and PDO, how to use it...?
How to Auto Post on Twitter with PHP
Jquery focus out after pressing enter key
how to Get string between two strings
Bootstrap contact form background only around form
how to Convert Array to Object with stdClass?
Adding 1 hour to time variable
How to get first 5 characters from string
लद्दाख जेसे ठंढे रेगिस्तानी क्षेत्र मे पर्यटन की क्या संभावनाए है?
How to Create a table 2 to 20 using for loop in php
How to create a MySQL database using PHP?
Write a program that reads a string and then prints a diamond shaped array based on the characters of the string.
INSERT IGNORE” vs “INSERT … ON DUPLICATE KEY UPDATE
php set session with cookies
How to create Pyramid of asterisks in php
CakePHP Retrieving rows for the current month
List the four developer practices of XP.
How can I get a date after 15 days/1 month in PHP?
How many types of PHP Operators. Describe it
सांस्कृतिक पर्यावरण के तहत कौन - कौन सी बाते आती है?
What is local by flywheel. ? Introduce local by flywheel in Details
What is the difference between client-side and server-side programming?
count no of rows in cakephp base on email id
Executing multiple SQL queries in one statement with PHP
How do you parse and process HTML/XML in PHP?
Your Answer