Skip to content

Instantly share code, notes, and snippets.

View kamel3d's full-sized avatar

Kamel Labiad kamel3d

View GitHub Profile
kamel3d / arabic_post_date.php
Created June 7, 2020 20:09
The function relativedate() take date as argument in ISO 8601 format and returns an array with Arabic text that has the relative time since the time of the input and the other value in the array tells if the post is new or not, it is considered as new if the input is less than 4 hours old
Copyright 2020 KAMEL LABIAD
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:
The above copyright notice and this permission notice shall be included in all copies or substantial portions