Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8634771
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T09:48:12+00:00 2026-06-12T09:48:12+00:00

Hi I know this question is a bit trivial. I googled it but could

  • 0

Hi I know this question is a bit trivial. I googled it but could not find the exact problem anywhere.

I have a string which contains a application filling date how can I convert this string into date

 $appln_filling_date = '20020315';

The type of appln_filling_date is string I want to convert its type to date and want the data remain the same. The field in the database has a type date.

EDIT

This is what I am trying to do

 $appln_filling_date = strtotime($appln_data['bibliographic-data']['application-reference']['document-id']['1']['date']['$']);
 $appln_filling_date = date('Y-m-d', $appln_filling_date);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T09:48:14+00:00Added an answer on June 12, 2026 at 9:48 am

    If your date is in some standard date format use this example:

    $d = new DateTime('20020315');
    echo $d->format('Y-m-d');
    
    # or [if you do not have DateTime, which is in php >= 5.2.0]
    
    $t = strtotime('20020315');
    echo date('Y-m-d', $t);
    

    If your date is not in some standard format use this example:

    $d = DateTime::createFromFormat('d . Y - m', '15 . 2002 - 03');
    echo $d->format('Y-m-d');
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know this is a bit bleeding edge, but here's the question anyway: Given
This might sound a bit of an odd question but I know what I
I know this question might be little silly but I can't seem to find
I know that this question has been asked loads of times, but I have
I know that this question might have been asked like 100 times, but, believe
Firstly, this DB question could be a bit DB agnostic, but I am using
I know this must be a trivial question, but I've tried many different ways,
I know this question has been asked, but I can't find more than one
I know this question might sound a little bit crazy, but I tough that
I know this question has been asked a lot, but I want to find

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.