Jump to content

Search the Community

Showing results for tags 'dates'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (Dreamweaver, Zend, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start





Website URL








Donation Link

Found 2 results

  1. Hello: How could I use php to automatically insert the correct 3 letter month abbreviations and four digit year in the following pdf filenames on the first of each month? (For example "...Feb2015.pdf" then "...Mar2015.pdf" and so on.... <div>Book One: <a href="http://monthlybookfiles.mysite.com/BookOne_Jan2015.pdf">Download Here</a></div> <div>Book Two: <a href="http://monthlybookfiles.mysite.com/BookTwo_Jan2015.pdf">Download Here</a></div> <div>Book Three: <a href="http://monthlybookfiles.mysite.com/BookThree_Jan2015.pdf">Download Here</a> </div> <div>Book Four: <a href="http://monthlybookfiles.mysite.com/BookFour_Jan2015.pdf">Download Here</a> </div> Please advise, Eggie
  2. // find the time difference between now and the expiry date $expiry_date = '2017-04-20 09:02:23'; $then = new DateTime($expiry_date); $now = new DateTime(); $remaining_time = $then->diff($now); // I want to add two weeks to the new date. $two_weeks = $now->add(new DateInterval('P2W'))->format('Y-m-d H:i:s'); // new date that combines the remaining time from above and adds 2 weeks to create a new date. This is the issue here. How do I combine these two dates properly? The new date has to be in this format ('Y-m-d H:i:s') $new_date = $remaining_time + $two_weeks;
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.