Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
Let's go
  • Loading branch information
vsg24 committed Jul 7, 2016
1 parent bb9c4e0 commit 706173d
Show file tree
Hide file tree
Showing 13 changed files with 642 additions and 0 deletions.
59 changes: 59 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@

# Created by https://www.gitignore.io/api/phpstorm

### PhpStorm ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and Webstorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# User-specific stuff:
.idea/workspace.xml
.idea/tasks.xml
.idea/dictionaries
.idea/vcs.xml
.idea/jsLibraryMappings.xml

# Sensitive or high-churn files:
.idea/dataSources.ids
.idea/dataSources.xml
.idea/dataSources.local.xml
.idea/sqlDataSources.xml
.idea/dynamic.xml
.idea/uiDesigner.xml

# Composer
vendor

# Gradle:
.idea/gradle.xml
.idea/libraries

# Mongo Explorer plugin:
.idea/mongoSettings.xml

## File-based project format:
*.iws

## Plugin-specific files:

# IntelliJ
/out/

# mpeltonen/sbt-idea plugin
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

### PhpStorm Patch ###
# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721

# *.iml
# modules.xml
# .idea/misc.xml
# *.ipr
8 changes: 8 additions & 0 deletions .idea/EasyDateTime.iml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions .idea/copyright/profiles_settings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions .idea/deployment.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions .idea/encodings.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 13 additions & 0 deletions .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions .idea/modules.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

84 changes: 84 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
#EasyDateTime

EasyDateTime is a Jalali/Shamsi and Gregorian class based on jDateTimePlus that aims to simplify common DateTime tasks by abstracting the complex layers. It's the **simplest** solution for Jalali/Shamsi calendar issues in PHP.

#About this class

EasyDateTime is directly based on `jDateTimePlus` 1.0.0 which is itself based on `jDateTime` 2.2.0

#Requirements

* **PHP >= 5.4**.
* Being based on jDateTimePlus, this package has a dependency on jDateTimePlus 1.0.0+

#Installation

##Using Composer

You can install this package using [composer](https://getcomposer.org). Add this package to your `composer.json`:

```
"require": {
"vsg24/easydatetime": "dev-master"
}
```

or if you prefer command line, change directory to project root and:

```
php composer.phar require "vsg24/easydatetime":"dev-master"
```

##Manual Installation

Get a copy of package source code. You can do this in two ways:

1. Download ZIP version of the source code and unzip it in desired location
2. Run `git clone https://github.com/vsg24/easydatetime.git` to clone this repository

After getting a copy of source code, it is enough to include `easydatetime.class.php` where you need to use it.

```php
require_once 'path/to/source/easydatetime.class.php';
```

#Examples

Please run [examples.php](examples.php) or see [examples-compiled.html](examples-compiled.html) for working examples.

**Important Note:**
If you want to do more complicated things, you can access an instance of `jDatetimePlus` from an EasyDateTime object:

`$edtObj->$jDatetimePlus`

#Contributors:
- [Vahid Amiri Motlagh](http://atvsg.com)

##License
EasyDateTime was created by [Vahid Amiri Motlagh](http://atvsg.com) and released under the [MIT License](http://opensource.org/licenses/mit-license.php).

Copyright (C) 2016 [Vahid Amiri Motlagh](http://atvsg.com)



The MIT License (MIT)

Copyright (C) 2016 Vahid Amiri Motlagh

Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:

1- The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.

2- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
26 changes: 26 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"name": "vsg24/easydatetime",
"type": "library",
"description": "Jalali (Shamsi) DateTime class written in PHP, abstraction, easy, little configuration",
"keywords": ["date", "datetime", "jalali", "jalalidate", "jdatetime","shamsi","iran","farsi","persian","time"],
"homepage": "https://vsg24.github.io/EasyDateTime/",
"license": "MIT",
"authors": [
{
"name": "Vahid Amiri Motlagh",
"email": "[email protected]",
"homepage": "http://atvsg.com",
"role": "Developer"
}
],
"require": {
"php": ">=5.4.0",
"vsg24/jdatetimeplus": ">=1.0.0"
},
"autoload": {
"classmap": [
"easydatetime.class.php"
]
},
"minimum-stability": "dev"
}
72 changes: 72 additions & 0 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 706173d

Please sign in to comment.