You are here

README.txt in Datex 7.2

Same filename and directory in other branches
  1. 7.3 README.txt
  2. 7 README.txt
INTRODUCTION
------------

Datex and related module will help to create a better multilingual website for
languages needing a Jalali (Or in near feature of datex, any) calendar instead 
of default Gregorian calendar.

  - datex API: is the base module, And used by other modules to localize dates. 
    On it's own, It would do nothing. It has API related to converting and 
    calculating dates of different calendars.

  - datex: When enabled, Will convert all dates to Jalali before display in
    page.

  - datex_date For Jalali support in date module, This module should be enabled
    It supports "views" too.

  - datex_popup: If you want to have date_popup localized, You should enable 
    this.


Since there is not a good "hook" in Drupal's core to alter dates and their
format, Some extra effort is needed to get "datex" module working. datex_date 
will work out of the box though. There are two methods available for datex:

  - Converting dates to Jalali in theming layer. Using this method, You won't 
    have to patch the core, But you will might miss localized date in  some 
    places. It's been tried to keep it as good as possible in non-patching
    mode, Views, node edit form, scheduler module and... are handled.
    If you encounter no problem using this mode, This is the recomended (and
    default) method.

  - Patching core: There is a patch file provided within this module, If you
    apply it on 'common.inc' file, You get localized date everywhere.
    This patch adds a hook to core for altering format_date result with 
    smallest footprint possible.

Keep in mind that hacking core is a *very bad* practice, So decide for yourself.


INSTALLATION
------------

  - Download datex from http://drupal.org/project/datex and put it in your 
    sites/all/modules folder of your Drupal installation or use drush. Then enable 
    it.
  - Enable Locale
  - Go to admin/config/regional/date-time/datex and configure default schema.

If you read above and want to apply the patch, Locate the patch file in
module's folder "drupal-jalali_support-0-0.patch", and apply it to file
"includes/common.inc". Instructions about patching files is at drupal.org.
You should configure datex to use patching-mode.


JQUERY LIBRARY
--------------

Since default library of date (datepicker) does not support international
calendars, A very good robust library written by "Keith Wood" is used. Note that
version 1.2.1 is tested and fully working. Download it from:

  - http://keith-wood.name/calendars.html
  or
  - https://github.com/kbwood/calendars

And extract it in "sites/all/libraries/jquery.calendars" of your Drupal.
So finally you will have a file like this: 
sites/all/libraries/jquery.calendars/jquery.calendars.all.min.js


CONFIGURATION
-------------

For each part of Drupal, Datex follows a behaviour called 'schema'. Different 
schemas can be defined and edited at datex configuration page. By default,
everything follows the default schema unless set otherwise.
Node display page, Views and other stuff always follow the default schema, But
date field widget, Diplay formatter, And views formatter can be configured 
independently. Just go to the configuration form of each, And you see a option
indicating what datex should do. If it's Forced disabled, Then datex ignores 
the field completely.


TRANSLATION
-----------

No localized, Translated string is harcoded in the code, So a persian month is
like 'Aban', You can translate it to "آبان" using locale.

File

README.txt
View source
  1. INTRODUCTION
  2. ------------
  3. Datex and related module will help to create a better multilingual website for
  4. languages needing a Jalali (Or in near feature of datex, any) calendar instead
  5. of default Gregorian calendar.
  6. - datex API: is the base module, And used by other modules to localize dates.
  7. On it's own, It would do nothing. It has API related to converting and
  8. calculating dates of different calendars.
  9. - datex: When enabled, Will convert all dates to Jalali before display in
  10. page.
  11. - datex_date For Jalali support in date module, This module should be enabled
  12. It supports "views" too.
  13. - datex_popup: If you want to have date_popup localized, You should enable
  14. this.
  15. Since there is not a good "hook" in Drupal's core to alter dates and their
  16. format, Some extra effort is needed to get "datex" module working. datex_date
  17. will work out of the box though. There are two methods available for datex:
  18. - Converting dates to Jalali in theming layer. Using this method, You won't
  19. have to patch the core, But you will might miss localized date in some
  20. places. It's been tried to keep it as good as possible in non-patching
  21. mode, Views, node edit form, scheduler module and... are handled.
  22. If you encounter no problem using this mode, This is the recomended (and
  23. default) method.
  24. - Patching core: There is a patch file provided within this module, If you
  25. apply it on 'common.inc' file, You get localized date everywhere.
  26. This patch adds a hook to core for altering format_date result with
  27. smallest footprint possible.
  28. Keep in mind that hacking core is a *very bad* practice, So decide for yourself.
  29. INSTALLATION
  30. ------------
  31. - Download datex from http://drupal.org/project/datex and put it in your
  32. sites/all/modules folder of your Drupal installation or use drush. Then enable
  33. it.
  34. - Enable Locale
  35. - Go to admin/config/regional/date-time/datex and configure default schema.
  36. If you read above and want to apply the patch, Locate the patch file in
  37. module's folder "drupal-jalali_support-0-0.patch", and apply it to file
  38. "includes/common.inc". Instructions about patching files is at drupal.org.
  39. You should configure datex to use patching-mode.
  40. JQUERY LIBRARY
  41. --------------
  42. Since default library of date (datepicker) does not support international
  43. calendars, A very good robust library written by "Keith Wood" is used. Note that
  44. version 1.2.1 is tested and fully working. Download it from:
  45. - http://keith-wood.name/calendars.html
  46. or
  47. - https://github.com/kbwood/calendars
  48. And extract it in "sites/all/libraries/jquery.calendars" of your Drupal.
  49. So finally you will have a file like this:
  50. sites/all/libraries/jquery.calendars/jquery.calendars.all.min.js
  51. CONFIGURATION
  52. -------------
  53. For each part of Drupal, Datex follows a behaviour called 'schema'. Different
  54. schemas can be defined and edited at datex configuration page. By default,
  55. everything follows the default schema unless set otherwise.
  56. Node display page, Views and other stuff always follow the default schema, But
  57. date field widget, Diplay formatter, And views formatter can be configured
  58. independently. Just go to the configuration form of each, And you see a option
  59. indicating what datex should do. If it's Forced disabled, Then datex ignores
  60. the field completely.
  61. TRANSLATION
  62. -----------
  63. No localized, Translated string is harcoded in the code, So a persian month is
  64. like 'Aban', You can translate it to "آبان" using locale.