Skip to content

class Locale not found when using I18n/Time on xampp localhost #1059

Description

@godguide1

I am trying to add days to a time parsed date by doing

<?php namespace App\Libraries;

    use CodeIgniter\Libraries;
    use CodeIgniter\I18n\Time;

    class Book
    {
          public function getTime()
          {
               $time = Time::parse('June 1, 2018', 'Australia/Sydney');
               $time = $time->addDays(7);
               return $time;
          }
     }

In attempt to getTime() am having class Locale not found Error; Please what do i need to set or tweak to get this working. Thanks.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions