Quellcode durchsuchen

Modules updates.

AntonLV vor 7 Jahren
Ursprung
Commit
a4e2a65c96
100 geänderte Dateien mit 23386 neuen und 4 gelöschten Zeilen
  1. 53 0
      modules/boonex/english/updates/9.0.14_10.0.0/install/config.php
  2. 15 0
      modules/boonex/english/updates/9.0.14_10.0.0/install/installer.php
  3. 271 0
      modules/boonex/english/updates/9.0.14_10.0.0/install/langs/en.xml
  4. 2877 0
      modules/boonex/english/updates/9.0.14_10.0.0/source/data/langs/system/en.xml
  5. 72 0
      modules/boonex/english/updates/9.0.14_10.0.0/source/install/config.php
  6. 34 0
      modules/boonex/english/updates/9.0.14_10.0.0/source/template/images/icons/std-icon.svg
  7. 7 3
      modules/boonex/posts/updates/9.0.11_10.0.0/install/installer.php
  8. 77 0
      modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/install/config.php
  9. 38 0
      modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/install/langs/en.xml
  10. 59 0
      modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/install/sql/enable.sql
  11. 37 0
      modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/template/images/icons/std-icon.svg
  12. 186 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/classes/BxShopifyConfig.php
  13. 121 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/classes/BxShopifyTemplate.php
  14. 116 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/config.php
  15. 242 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/langs/en.xml
  16. 424 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/sql/enable.sql
  17. 326 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/sql/install.sql
  18. 59 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/sql/uninstall.sql
  19. 14 0
      modules/boonex/shopify/updates/9.0.7_10.0.0/source/template/entry-text.html
  20. 51 0
      modules/boonex/smtpmailer/updates/9.0.4_10.0.0/install/config.php
  21. 13 0
      modules/boonex/smtpmailer/updates/9.0.4_10.0.0/install/installer.php
  22. 210 0
      modules/boonex/smtpmailer/updates/9.0.4_10.0.0/source/classes/BxSMTPModule.php
  23. 68 0
      modules/boonex/smtpmailer/updates/9.0.4_10.0.0/source/install/config.php
  24. 37 0
      modules/boonex/smtpmailer/updates/9.0.4_10.0.0/source/template/images/icons/std-icon.svg
  25. 185 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/classes/BxSnipcartConfig.php
  26. 197 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/classes/BxSnipcartModule.php
  27. 136 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/config.php
  28. 261 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/langs/en.xml
  29. 425 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/sql/enable.sql
  30. 406 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/sql/install.sql
  31. 68 0
      modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/sql/uninstall.sql
  32. 217 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesConfig.php
  33. 25 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesMenuView.php
  34. 24 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesMenuViewActions.php
  35. 97 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesModule.php
  36. 22 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesPrivacyPost.php
  37. 55 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesTemplate.php
  38. 152 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/config.php
  39. 323 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/langs/en.xml
  40. 57 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/disable.sql
  41. 528 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/enable.sql
  42. 368 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/install.sql
  43. 64 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/uninstall.sql
  44. 37 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/template/images/icons/std-icon.svg
  45. 1 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/template/menu_main_submenu.html
  46. 1 0
      modules/boonex/spaces/updates/9.0.5_10.0.0/source/template/unit_wo_cover.html
  47. 3 1
      modules/boonex/timeline/updates/9.0.14_10.0.0/install/config.php
  48. 20 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineCmts.php
  49. 578 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineConfig.php
  50. 36 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineCronPublishing.php
  51. 853 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineDb.php
  52. 247 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineFormPost.php
  53. 112 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineGridAdministration.php
  54. 279 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineMenuItemActions.php
  55. 40 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineMenuItemManage.php
  56. 159 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineMenuItemShare.php
  57. 3640 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineModule.php
  58. 61 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelinePrivacy.php
  59. 186 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineResponse.php
  60. 77 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineSearchResult.php
  61. 2282 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineTemplate.php
  62. 22 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineUploaderHTML5Attach.php
  63. 22 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineUploaderSimpleAttach.php
  64. 20 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineVoteLikes.php
  65. 135 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/config.php
  66. 268 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/langs/en.xml
  67. 56 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/disable.sql
  68. 343 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/enable.sql
  69. 497 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/install.sql
  70. 71 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/uninstall.sql
  71. 356 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/js/main.js
  72. 369 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/js/post.js
  73. 860 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/js/view.js
  74. 254 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/css/view-media-desktop.css
  75. 556 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/css/view.css
  76. 36 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/images/icons/std-icon.svg
  77. 67 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/item_outline.html
  78. 70 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/item_timeline.html
  79. 9 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/link_embed_common.html
  80. 1 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/link_embed_provider.html
  81. 5 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/live_update_button.html
  82. 10 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/live_update_notification.html
  83. 39 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/type_post.html
  84. 1 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/uploader_button_html5_attach.html
  85. 1 0
      modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/uploader_button_simple_attach.html
  86. 68 0
      modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/config.php
  87. 37 0
      modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/langs/en.xml
  88. 49 0
      modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/sql/enable.sql
  89. 21 0
      modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/sql/install.sql
  90. 68 0
      modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/config.php
  91. 28 0
      modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/langs/en.xml
  92. 52 0
      modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/sql/enable.sql
  93. 21 0
      modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/sql/install.sql
  94. 17 0
      modules/boonex/una_connect/updates/9.0.3_10.0.0/source/template/images/icons/std-icon.svg
  95. 183 0
      modules/boonex/videos/updates/9.0.4_10.0.0/source/classes/BxVideosConfig.php
  96. 142 0
      modules/boonex/videos/updates/9.0.4_10.0.0/source/classes/BxVideosModule.php
  97. 203 0
      modules/boonex/videos/updates/9.0.4_10.0.0/source/classes/BxVideosTemplate.php
  98. 142 0
      modules/boonex/videos/updates/9.0.4_10.0.0/source/install/config.php
  99. 228 0
      modules/boonex/videos/updates/9.0.4_10.0.0/source/install/langs/en.xml
  100. 430 0
      modules/boonex/videos/updates/9.0.4_10.0.0/source/install/sql/enable.sql

+ 53 - 0
modules/boonex/english/updates/9.0.14_10.0.0/install/config.php

@@ -0,0 +1,53 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'title' => 'English',
+    'version_from' => '9.0.14',
+    'version_to' => '10.0.0',
+    'vendor' => 'BoonEx',
+
+    'compatible_with' => array(
+        '9.0.x',
+        '10.0.x'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/english/updates/update_9.0.14_10.0.0/',
+    'home_uri' => 'en_update_9014_1000',
+
+    'module_dir' => 'boonex/english/',
+    'module_uri' => 'en',
+
+    'db_prefix' => 'bx_eng_',
+    'class_prefix' => 'BxEng',
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 0,
+        'update_files' => 1,
+        'update_languages' => 1,
+        'restore_languages' => 0,
+        'clear_db_cache' => 0,
+    ),
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'System',
+
+    /**
+     * Files Section
+     */
+    'delete_files' => array(),
+);

+ 15 - 0
modules/boonex/english/updates/9.0.14_10.0.0/install/installer.php

@@ -0,0 +1,15 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ */
+
+bx_import('BxDolStudioUpdater');
+
+class BxEngUpdater extends BxDolStudioUpdater
+{
+    function __construct($aConfig)
+    {
+        parent::__construct($aConfig);
+    }
+}

+ 271 - 0
modules/boonex/english/updates/9.0.14_10.0.0/install/langs/en.xml

@@ -0,0 +1,271 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+	<string_add name="_adm_bp_txt_block_hidden_on_mobile"><![CDATA[mobile app]]></string_add>
+	<string_add name="_adm_btn_settings_mix_hide"><![CDATA[Hide]]></string_add>
+	<string_add name="_adm_btn_settings_mix_publish"><![CDATA[Publish]]></string_add>
+	<string_add name="_adm_dbd_txt_c_clear_custom"><![CDATA[Clear Custom cache]]></string_add>
+	<string_add name="_adm_form_btn_labels_add"><![CDATA[Add]]></string_add>
+	<string_add name="_adm_form_btn_labels_back"><![CDATA[Back]]></string_add>
+	<string_add name="_adm_form_btn_labels_cancel"><![CDATA[Cancel]]></string_add>
+	<string_add name="_adm_form_btn_labels_submit"><![CDATA[Submit]]></string_add>
+	<string_add name="_adm_form_err_field_add_already_exists"><![CDATA[Field with similar name already exists]]></string_add>
+	<string_add name="_adm_form_err_labels_add"><![CDATA[Cannot add label]]></string_add>
+	<string_add name="_adm_form_err_labels_edit"><![CDATA[Cannot update label]]></string_add>
+	<string_add name="_adm_form_err_labels_value"><![CDATA[Label should have unique non-empty value.]]></string_add>
+	<string_add name="_adm_form_txt_field_checker_custom"><![CDATA[Custom check]]></string_add>
+	<string_add name="_adm_form_txt_field_checker_func_info_custom"><![CDATA[Note. It's not recommended to edit this field without absolute necessity.]]></string_add>
+	<string_add name="_adm_form_txt_field_type_block_end"><![CDATA[block end]]></string_add>
+	<string_add name="_adm_form_txt_field_db_pass_select_value"><![CDATA[Select value...]]></string_add>
+	<string_add name="_adm_form_txt_labels_add_popup"><![CDATA[Add label]]></string_add>
+	<string_add name="_adm_form_txt_labels_edit_popup"><![CDATA[Edit "{0}" label]]></string_add>
+	<string_add name="_adm_form_txt_labels_items"><![CDATA[Items]]></string_add>
+	<string_add name="_adm_form_txt_labels_manage_items"><![CDATA[Manage child labels]]></string_add>
+	<string_add name="_adm_form_txt_labels_n_items"><![CDATA[{0} items]]></string_add>
+	<string_add name="_adm_form_txt_labels_parent"><![CDATA[Parent]]></string_add>
+	<string_add name="_adm_form_txt_labels_parent_empty"><![CDATA[No Parent]]></string_add>
+	<string_add name="_adm_form_txt_labels_grandparent_label"><![CDATA[Grandparent Label]]></string_add>
+	<string_add name="_adm_form_txt_labels_parent_label"><![CDATA[Parent Label]]></string_add>
+	<string_add name="_adm_form_txt_labels_sibling_labels"><![CDATA[Sibling Labels]]></string_add>
+	<string_add name="_adm_form_txt_labels_value"><![CDATA[Label]]></string_add>
+	<string_add name="_adm_lmi_cpt_labels"><![CDATA[Labels]]></string_add>
+	<string_add name="_adm_msg_oauth_non_owner_logged"><![CDATA[WARNING: You are logged in to an <a href="{0}">UNA.IO</a> account which is different from the account that generated UNA Key & Secret for your domain.]]></string_add>
+	<string_add name="_adm_nav_txt_block_hidden_on_mobile"><![CDATA[mobile app]]></string_add>
+	<string_add name="_adm_stg_cpt_option_sys_player_default"><![CDATA[Default Player]]></string_add>
+	<string_add name="_adm_stg_cpt_option_sys_player_default_format"><![CDATA[Default video format]]></string_add>
+	<string_add name="_adm_stg_cpt_option_sys_relations"><![CDATA[Enable relationships between]]></string_add>
+	<string_add name="_adm_stg_cpt_option_sys_search_keyword_min_len"><![CDATA[Keyword min length in site search]]></string_add>
+	<string_add name="_adm_stg_txt_mix_title_inf"><![CDATA[Create a <b>_sys_template_mixed_[template_name]_[mix_name]</b> language key in Polyglot to customise the publicly-displayed name. <b>[template_name]</b> and <b>[mix_name]</b> are in lowercase, underscore instead of space.]]></string_add>
+	<string_add name="_adm_tmi_cpt_launcher"><![CDATA[Back to Launcher]]></string_add>
+	<string_add name="_cmt_txt_new_content"><![CDATA[New content]]></string_add>
+	<string_add name="_sys_acl_action_set_acl_as_privacy"><![CDATA[Choose membership level as privacy]]></string_add>
+	<string_add name="_sys_acl_action_set_acl_as_privacy_desc"><![CDATA[Choose membership level as privacy in add content forms]]></string_add>
+	<string_add name="_sys_acl_action_vote_view"><![CDATA[View votes]]></string_add>
+	<string_add name="_sys_acl_action_vote_view_voters"><![CDATA[View voters]]></string_add>
+	<string_add name="_sys_add_relation"><![CDATA[Add relationship]]></string_add>
+	<string_add name="_sys_confirm"><![CDATA[Confirm]]></string_add>
+	<string_add name="_sys_confirmed"><![CDATA[Confirmed]]></string_add>
+	<string_add name="_sys_decline"><![CDATA[Decline]]></string_add>
+	<string_add name="_sys_form_confirm_phone_input_phone_info"><![CDATA[Enter your phone with country code]]></string_add>
+	<string_add name="_sys_form_login_input_phone_info"><![CDATA[Enter your phone with country code]]></string_add>
+	<string_add name="_sys_menu_item_title_copyright"><![CDATA[Copyright]]></string_add>
+	<string_add name="_sys_menu_item_title_sm_votes"><![CDATA[Votes]]></string_add>
+	<string_add name="_sys_menu_item_title_sm_nl"><![CDATA[New line]]></string_add>
+	<string_add name="_sys_menu_item_title_system_copyright"><![CDATA[Copyright]]></string_add>
+	<string_add name="_sys_menu_item_title_system_va_reaction"><![CDATA[Reaction]]></string_add>
+	<string_add name="_sys_menu_item_title_system_sm_votes"><![CDATA[Votes]]></string_add>
+	<string_add name="_sys_menu_item_title_system_sm_nl"><![CDATA[New Line]]></string_add>
+	<string_add name="_sys_menu_template_title_buttons_icon_hor"><![CDATA[Horizontal Buttons (icons only)]]></string_add>
+	<string_add name="_sys_menu_template_title_floating_blocks_dash"><![CDATA[Floating Blocks with icons & captions]]></string_add>
+	<string_add name="_sys_menu_title_homepage_submenu"><![CDATA[Homepage Submenu]]></string_add>
+	<string_add name="_sys_menu_set_title_homepage_submenu"><![CDATA[Homepage Submenu]]></string_add>
+	<string_add name="_sys_menu_item_title_system_explore"><![CDATA[Explore]]></string_add>
+	<string_add name="_sys_menu_item_title_explore"><![CDATA[Explore]]></string_add>
+	<string_add name="_sys_menu_item_title_system_updates"><![CDATA[Updates]]></string_add>
+	<string_add name="_sys_menu_item_title_updates"><![CDATA[Updates]]></string_add>
+	<string_add name="_sys_menu_item_title_system_trends"><![CDATA[Trends]]></string_add>
+	<string_add name="_sys_menu_item_title_trends"><![CDATA[Trends]]></string_add>
+	<string_add name="_sys_menu_title_add_relation"><![CDATA[Add Relationship Menu]]></string_add>
+	<string_add name="_sys_menu_dashboard_manage_tools_addon_counter1_caption_default"><![CDATA[hidden]]></string_add>
+	<string_add name="_sys_menu_dashboard_manage_tools_addon_counter1_caption_profile_default"><![CDATA[unapproved]]></string_add>
+	<string_add name="_sys_menu_dashboard_manage_tools_addon_counter2_caption_default"><![CDATA[reported]]></string_add>
+	<string_add name="_sys_page_block_title_homepage_splash"><![CDATA[Splash]]></string_add>
+	<string_add name="_sys_page_title_explore"><![CDATA[Explore]]></string_add>
+	<string_add name="_sys_page_title_updates"><![CDATA[Updates]]></string_add>
+	<string_add name="_sys_page_title_trends"><![CDATA[Trends]]></string_add>
+	<string_add name="_sys_page_title_sys_explore"><![CDATA[Explore]]></string_add>
+	<string_add name="_sys_page_title_sys_updates"><![CDATA[Updates]]></string_add>
+	<string_add name="_sys_page_title_sys_trends"><![CDATA[Trends]]></string_add>
+	<string_add name="_sys_pre_lists_relations"><![CDATA[Relationships]]></string_add>
+	<string_add name="_sys_pre_lists_relations_husband"><![CDATA[husband]]></string_add>
+	<string_add name="_sys_pre_lists_relations_wife"><![CDATA[wife]]></string_add>
+	<string_add name="_sys_pre_lists_relations_father"><![CDATA[father]]></string_add>
+	<string_add name="_sys_pre_lists_relations_mother"><![CDATA[mother]]></string_add>
+	<string_add name="_sys_pre_lists_relations_son"><![CDATA[son]]></string_add>
+	<string_add name="_sys_pre_lists_relations_daughter"><![CDATA[daughter]]></string_add>
+	<string_add name="_sys_pre_lists_relations_brother"><![CDATA[brother]]></string_add>
+	<string_add name="_sys_pre_lists_relations_sister"><![CDATA[sister]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions"><![CDATA[Reactions]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions_like"><![CDATA[Like]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions_love"><![CDATA[Love]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions_joy"><![CDATA[Haha]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions_surprise"><![CDATA[Wow]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions_sadness"><![CDATA[Sad]]></string_add>
+	<string_add name="_sys_pre_lists_vote_reactions_anger"><![CDATA[Angry]]></string_add>
+	<string_add name="_sys_profile_friend_request_added"><![CDATA[<b class="bx-ntfs-content-profile">{owner_name}</b> befriended <b class="bx-ntfs-content-entry">{entry_caption}</b>]]></string_add>
+	<string_add name="_sys_privacy_groups_acl"><![CDATA[Membership Levels]]></string_add>
+	<string_add name="_sys_ps_group_title_followers"><![CDATA[Followers]]></string_add>
+	<string_add name="_sys_ps_group_title_participants"><![CDATA[Participants]]></string_add>
+	<string_add name="_sys_relation"><![CDATA[Relationship]]></string_add>
+	<string_add name="_sys_status"><![CDATA[Status]]></string_add>
+	<string_add name="_sys_status_awaiting"><![CDATA[awaiting]]></string_add>
+	<string_add name="_sys_status_failed"><![CDATA[failed]]></string_add>
+	<string_add name="_sys_template_mixed_mask"><![CDATA[{0} ({1})]]></string_add>
+	<string_add name="_sys_txt_splash_title"><![CDATA[Connect. Share. Create.]]></string_add>
+	<string_add name="_sys_txt_splash_slogan"><![CDATA[Join our community now to connect with like-minded people, share exciting news and create inspiring content.]]></string_add>
+	<string_add name="_sys_txt_splash_login"><![CDATA[Login]]></string_add>
+	<string_add name="_sys_txt_splash_join"><![CDATA[Join]]></string_add>
+	<string_add name="_sys_txt_splash_connect"><![CDATA[Connect]]></string_add>
+	<string_add name="_sys_txt_splash_connect_text"><![CDATA[Find like-minded people, make new friends, follow interesting authors and stay in touch anywhere.]]></string_add>
+	<string_add name="_sys_txt_splash_share"><![CDATA[Share]]></string_add>
+	<string_add name="_sys_txt_splash_share_text"><![CDATA[Bring up the latest news, share interesting articles, exciting websites, cool photos and awesome videos.]]></string_add>
+	<string_add name="_sys_txt_splash_create"><![CDATA[Create]]></string_add>
+	<string_add name="_sys_txt_splash_create_text"><![CDATA[Build your social profile, post status updates, write notes, create polls and upload media albums.]]></string_add>
+	<string_add name="_sys_unconfirmed"><![CDATA[Unconfirmed]]></string_add>
+	<string_add name="_vote_do_by_reactions"><![CDATA["{0}" by]]></string_add>
+	<string_add name="_vote_n_votes"><![CDATA[{0} votes]]></string_add>
+
+	<string_upd name="_adm_bp_err_block_title"><![CDATA[Enter title, more than 3 characters]]></string_upd>
+	<string_upd name="_adm_btn_settings_mix_import"><![CDATA[Import]]></string_upd>
+	<string_upd name="_adm_btn_settings_mix_export"><![CDATA[Export]]></string_upd>
+	<string_upd name="_adm_btn_settings_mix_delete"><![CDATA[Delete]]></string_upd>
+	<string_upd name="_adm_form_err_displays_title"><![CDATA[Enter title, more than 3 characters]]></string_upd>
+	<string_upd name="_adm_form_err_forms_title"><![CDATA[Enter name, more than 3 characters]]></string_upd>
+	<string_upd name="_adm_form_err_pre_lists_title"><![CDATA[Enter title, more than 3 characters]]></string_upd>
+	<string_upd name="_adm_form_err_search_forms_title"><![CDATA[Enter name, more than 3 characters]]></string_upd>
+	<string_upd name="_adm_pgt_err_etemplates_name_system"><![CDATA[Enter name, more than 3 characters]]></string_upd>
+	<string_upd name="_adm_stg_cpt_option_sys_captcha_default"><![CDATA[Default Ñaptcha]]></string_upd>
+	<string_upd name="_adm_stg_cpt_option_sys_editor_default"><![CDATA[Default HTML editor]]></string_upd>
+	<string_upd name="_adm_stg_cpt_option_sys_transcoder_queue_storage"><![CDATA[Remote video transcoding (requires special setup)]]></string_upd>
+	<string_upd name="_sys_audit_msg_manual_audit"><![CDATA[<p>
+Some things can not be determined automatically, manual server audit is required to check it.
+If you don't know how to do it by yourself you can submit <a target="_blank" href="mailto:support@una.io?subject=Server Audit Request">Server Audit Request</a>.
+</p>]]></string_upd>
+	<string_upd name="_sys_audit_msg_serverside_compression"><![CDATA[
+can be checked <a href="#manual_audit">manually</a> or in "Page Speed" tool build-in into browser.<br />
+If it is not enabled then please consider implement this optimization, since it improve perceived site speed and save the bandwidth, refer to <a href="http://www.boonex.com/trac/dolphin/wiki/HostingServerSetupRecommendations#Serversidecontentcompression">this tutorial</a> on how to do this.<br />{0}]]></string_upd>
+	<string_upd name="_sys_audit_msg_userside_caching"><![CDATA[
+<a href="{0}">click here to check it in Google Page Speed</a><br />
+If it is not enabled then please consider implement this optimization, since it improve perceived site speed and save the bandwidth, refer to <a target="_blank" href="http://www.boonex.com/trac/dolphin/wiki/HostingServerSetupRecommendations#Usersidecachingforstaticcontent">this tutorial</a> on how to do this.<br />{1}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_admin_email"><![CDATA[{email_header}
+<p>Message from <a href="{site_url}">{site_name}</a> admin:</p>
+<p> </p>
+<p>{MessageText}</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_comment_replied"><![CDATA[{email_header}
+<p>User {sender_display_name} posted reply to your comment: </p>
+<p> </p>
+<p>{reply_text}</p>
+<p> </p>
+<p>View and reply here: <a href="{page_url}">{page_title}</a>.</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_system_reported"><![CDATA[{email_header}
+<p>New <b>{report_type}</b> report received:</p>
+<p> </p>
+<p>{report_text}</p>
+<p> </p>
+<p><a href="{report_url}">View report</a>.</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_confirmation"><![CDATA[{email_header}
+<p>Hello, {name}.</p>
+<p>Click the link below to verify your email address, please:</p>
+<p> </p>
+<p><a href="{conf_link}">{conf_link}</a></p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_delayed_module_uninstall"><![CDATA[{email_header}
+<p>Module: <b>{Module}</b></p>
+<p>Uninstallation result: {Result}</p>
+<p> </p>
+<p>{Message}</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_forgot"><![CDATA[{email_header}
+<p>Click the link below to reset your password, please:</p>
+<p> </p>
+<p><a href="{forgot_password_url}">Reset my password</a>.</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_mem_changed"><![CDATA[{email_header}
+<p><b>{profile_name}</b> profile membership level is now <b>{membership_level}</b>.</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_mem_expiration"><![CDATA[{email_header}
+<p>Your {membership_name} membership will expire in {expire_days} days (-1 means already expired).</p>
+<p>Click the link below to renew your membership:</p>
+<p> </p>
+<p><a href="{page_url}">Renew my membership</a></p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_password_reset"><![CDATA[{email_header}
+<p>Your new password is:</p>
+<p> </p>
+<p><b>{password}</b></p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_profile_change_status_active"><![CDATA[{email_header}
+<p>Your {site_name} account details:</p>
+<p> </p>
+<p>Name: {account_name}</p>
+<p>Email: {account_email}</p>
+<p>URL: <a href="{site_url}">{site_url}</a></p>
+<p></p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_profile_change_status_pending"><![CDATA[{email_header}
+<p>Your profile is pending review. We will send you the review result shortly.</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_profile_change_status_suspended"><![CDATA[{email_header}
+<p>Your profile is currently suspended.</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_account"><![CDATA[{email_header}
+<p>{account_output}</p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_pruning"><![CDATA[{email_header}
+<p>{pruning_output}</p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_upgrade_failed"><![CDATA[{email_header}
+<p>Upgrade failed due to the following error:</p>
+<p> </p>
+<p>{error_msg}</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_upgrade_modules_failed"><![CDATA[{email_header}
+<p>The following errors appeared during modules upgrade:</p>
+<p> </p>
+<p>{conclusion}</p>
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_upgrade_success"><![CDATA[{email_header}
+<p>Site was successfully upgraded to {new_version}.</p>
+<p>Please go to <b>Studio &gt; Apps Market &gt; Updates</b> to check for modules updates.</p>
+<p> </p>
+{conclusion}
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_upgrade_modules_success"><![CDATA[{email_header}
+<p>The following modules were successfully upgraded.</p>
+<p> </p>
+{conclusion}
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_et_txt_body_bg_operation_failed"><![CDATA[{email_header}
+<p>Background operation failed with the following message.</p>
+<p> </p>
+{conclusion}
+<p> </p>
+{email_footer}]]></string_upd>
+	<string_upd name="_sys_menu_item_title_cmts_administration"><![CDATA[Comments]]></string_upd>
+	<string_upd name="_sys_menu_item_title_system_cmts_administration"><![CDATA[Comments]]></string_upd>
+	<string_upd name="_sys_profile_friendship_added"><![CDATA[Now <b class="bx-ntfs-content-profile">{owner_name}</b> and <b class="bx-ntfs-content-entry">{entry_caption}</b> are friends]]></string_upd>
+	<string_upd name="_sys_pruning_db"><![CDATA[<h3>Database pruning:</h3>
+        <ul>
+            <li><b>{0}</b> deleted expired membership levels</li>
+            <li><b>{1}</b> deleted expired sessions</li>
+            <li><b>{2}</b> deleted expired keys</li>
+            <li><b>{3}</b> deleted expired storage tokens</li>
+            <li><b>{4}</b> deleted outdated transcoded images</li>
+        </ul>]]></string_upd>
+	<string_upd name="_sys_pruning_files"><![CDATA[<h3>Files pruning:</h3>
+        <ul>
+            <li><b>{0}</b> total</li>
+            <li><b>{1}</b> deleted</li>
+        </ul>]]></string_upd>
+
+	<string_del name="_adm_txt_back_to_launcher"><![CDATA[Back to Launcher]]></string_del>
+	<string_del name="_sys_menu_item_title_social_sharing_googleplus"><![CDATA[Share in Google Plus]]></string_del>
+	<string_del name="_sys_menu_item_title_system_social_sharing_googleplus"><![CDATA[Share in Google Plus]]></string_del>
+</resources>

+ 2877 - 0
modules/boonex/english/updates/9.0.14_10.0.0/source/data/langs/system/en.xml

@@ -0,0 +1,2877 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="en" title="English">
+	<string name="_ADM_PROFILE_SEND_MSG"><![CDATA[Message was successfully sent.]]></string>
+	<string name="_ATT_ACTIVE_E"><![CDATA[You are a full-featured member of our community. You can, however, suspend your profile to become temporarily unavailable for others.]]></string>
+	<string name="_ATT_APPROVAL_E"><![CDATA[Your profile activation is in progress. Usually it takes up to 24 hours. Thank you for your patience.]]></string>
+	<string name="_ATT_REJECTED_E"><![CDATA[Your profile was rejected by the system administrator because it contains illegal information or is missing some information. If you have any questions, please, <a target=_blank href="contact.php">contact us</a>, and don't forget to specify your profile ID.]]></string>
+	<string name="_ATT_SUSPENDED_E"><![CDATA[Your profile is temporarily out of {0} system services. You can activate it <a target=_blank href="change_status.php">here</a>. If you have any questions, please <a target=_blank href="contact.php">contact the administrators</a>.]]></string>
+	<string name="_ATT_UNCONFIRMED_E"><![CDATA[You will need to follow the link supplied in the e-mail to get your account submitted for approval. <br />Send me <a target=_blank href="activation_email.php">confirmation e-mail</a>.]]></string>
+	<string name="_Access denied"><![CDATA[Access denied]]></string>
+	<string name="_Action"><![CDATA[Action]]></string>
+	<string name="_all"><![CDATA[All]]></string>
+	<string name="_Allowed Since"><![CDATA[Allowed Since]]></string>
+	<string name="_Allowed Until"><![CDATA[Allowed Until]]></string>
+    <string name="_Allowed actions"><![CDATA[Allowed actions]]></string>
+    <string name="_anonymous"><![CDATA[anonymous]]></string>
+    <string name="_anonymous_f"><![CDATA[anonymous ({0})]]></string>
+	<string name="_Are_you_sure"><![CDATA[Are you sure?]]></string>
+	<string name="_Auth type"><![CDATA[Auth type]]></string>
+	<string name="_Basic"><![CDATA[Basic]]></string>
+	<string name="_CONTACT_H"><![CDATA[Contact us]]></string>
+	<string name="_CONTACT_H1"><![CDATA[Contact]]></string>
+	<string name="_Can not delete comments with replies"><![CDATA[Cannot delete comments with replies]]></string>
+	<string name="_Cancel"><![CDATA[Cancel]]></string>
+	<string name="_Content"><![CDATA[Content]]></string>
+	<string name="_Count"><![CDATA[Count]]></string>
+	<string name="_DELETE_SUCCESS"><![CDATA[You account was successfully deleted]]></string>
+	<string name="_DELETE_TEXT"><![CDATA[All your content will be deleted. Are you sure you want to delete your account?]]></string>
+	<string name="_Date"><![CDATA[Date]]></string>
+	<string name="_Delete"><![CDATA[Delete]]></string>
+	<string name="_Delete account"><![CDATA[Delete account]]></string>
+	<string name="_Description"><![CDATA[Description]]></string>
+	<string name="_EXPLANATION_H"><![CDATA[Explanation]]></string>
+	<string name="_Edit"><![CDATA[Edit]]></string>
+	<string name="_Email"><![CDATA[Email]]></string>
+	<string name="_Email sent failed"><![CDATA[Email send failed]]></string>
+	<string name="_Empty"><![CDATA[Empty]]></string>
+	<string name="_Enter_value_here"><![CDATA[Please, enter a value here]]></string>
+	<string name="_Error"><![CDATA[Error]]></string>
+	<string name="_Failed"><![CDATA[Failed]]></string>
+	<string name="_favorite_counter"><![CDATA[{0}]]></string>
+	<string name="_favorite_do_favorite"><![CDATA[Favorite]]></string>
+	<string name="_favorite_do_unfavorite"><![CDATA[Unfavorite]]></string>
+	<string name="_favorite_do_favorite_by"><![CDATA[Favorited by]]></string>
+	<string name="_favorite_err_cannot_perform_action"><![CDATA[Cannot perform the action.]]></string>
+	<string name="_favorite_err_duplicate_favorite"><![CDATA[You already favorited this item.]]></string>
+	<string name="_favorite_err_not_enabled"><![CDATA[The feature is not available right now. Please, try again later.]]></string>
+	<string name="_feature_do_feature"><![CDATA[Feature]]></string>
+    <string name="_feature_do_unfeature"><![CDATA[Unfeature]]></string>
+    <string name="_feature_err_cannot_perform_action"><![CDATA[Cannot perform the action.]]></string>
+    <string name="_feature_err_duplicate_feature"><![CDATA[The item was already added in featured list.]]></string>
+    <string name="_feature_err_not_enabled"><![CDATA[The feature is not available right now. Please, try again later.]]></string>
+	<string name="_Female"><![CDATA[Woman]]></string>
+	<string name="_From"><![CDATA[From]]></string>
+	<string name="_Header"><![CDATA[Header]]></string>
+	<string name="_Incorrect Captcha"><![CDATA[Incorrect Captcha]]></string>
+	<string name="_Incorrect Email"><![CDATA[Incorrect Email]]></string>
+	<string name="_Info"><![CDATA[Info]]></string>
+	<string name="_Keyword"><![CDATA[Keyword]]></string>
+	<string name="_LookinFemale"><![CDATA[Woman]]></string>
+	<string name="_LookinMale"><![CDATA[Man]]></string>
+	<string name="_MEMBERSHIP_EXPIRES_IN_DAYS"><![CDATA[expires: in {0} day(s)]]></string>
+	<string name="_MEMBERSHIP_EXPIRES_NEVER"><![CDATA[expires: never]]></string>
+	<string name="_MEMBERSHIP_EXPIRES_TODAY"><![CDATA[expires: today at {0}. (Server time: {1})]]></string>
+	<string name="_MEMBERSHIP_STANDARD"><![CDATA[You are a standard member.]]></string>
+	<string name="_MEMBERSHIP_UPGRADE_FROM_STANDARD"><![CDATA[]]></string>
+	<string name="_Male"><![CDATA[Man]]></string>
+	<string name="_Manage"><![CDATA[Manage]]></string>
+	<string name="_Member"><![CDATA[Member]]></string>
+	<string name="_Member Login"><![CDATA[Login]]></string>
+	<string name="_Message text"><![CDATA[Message text]]></string>
+	<string name="_N_point"><![CDATA[<span>{0}</span> plus]]></string>
+	<string name="_N_points"><![CDATA[<span>{0}</span> pluses]]></string>
+	<string name="_Name"><![CDATA[Name]]></string>
+	<string name="_Name is required"><![CDATA[Name is required]]></string>
+	<string name="_No"><![CDATA[No]]></string>
+	<string name="_None"><![CDATA[None]]></string>
+	<string name="_No actions allowed for this membership"><![CDATA[No actions allowed for this membership]]></string>
+	<string name="_No such comment"><![CDATA[No such comment]]></string>
+	<string name="_Ok"><![CDATA[OK]]></string>
+	<string name="_Period"><![CDATA[Period]]></string>
+	<string name="_Please Wait"><![CDATA[Please Wait]]></string>
+	<string name="_Please enter n1-n2 characters"><![CDATA[Please enter {0}-{1} characters]]></string>
+	<string name="_Please select value"><![CDATA[Please select a value from the list]]></string>
+	<string name="_Preview"><![CDATA[Preview]]></string>
+	<string name="_report_counter"><![CDATA[{0}]]></string>
+	<string name="_report_do_report"><![CDATA[Report]]></string>
+	<string name="_report_do_report_by"><![CDATA[Reported by]]></string>
+	<string name="_report_err_cannot_perform_action"><![CDATA[Cannot perform action.]]></string>
+	<string name="_report_err_duplicate_report"><![CDATA[You already reported this item.]]></string>
+	<string name="_report_err_not_enabled"><![CDATA[The feature is not available right now. Please, try again later.]]></string>
+	<string name="_report_err_wrong_type"><![CDATA[Wrong report type.]]></string>
+	<string name="_report_reported_as"><![CDATA[Reported as:]]></string>
+	<string name="_RSS_Feed_Title_Common"><![CDATA[{0} RSS]]></string>
+	<string name="_RSS_Feed_Title_Profile"><![CDATA[{0}'s Recent {1}]]></string>
+	<string name="_Rate"><![CDATA[Rate]]></string>
+	<string name="_Read"><![CDATA[Read]]></string>
+	<string name="_Read more"><![CDATA[Read more]]></string>
+	<string name="_Reset"><![CDATA[Reset]]></string>
+	<string name="_Search"><![CDATA[Search]]></string>
+  <string name="_search_in_all_section"><![CDATA[Search in all sections]]></string>
+  <string name="_Section"><![CDATA[Section]]></string>
+	<string name="_Select_one"><![CDATA[Select one...]]></string>
+	<string name="_Select_all"><![CDATA[Select all]]></string>
+	<string name="_Show"><![CDATA[Show]]></string>
+	<string name="_Sorry, your IP been banned"><![CDATA[Sorry, your IP has been banned]]></string>
+	<string name="_Subject"><![CDATA[Subject]]></string>
+	<string name="_Submit"><![CDATA[Submit]]></string>
+	<string name="_Success"><![CDATA[Success]]></string>
+	<string name="_Times allowed"><![CDATA[Times allowed]]></string>
+	<string name="_Title"><![CDATA[Title]]></string>
+	<string name="_To"><![CDATA[to]]></string>
+	<string name="_VIEW_MEMBERSHIP_ACTIONS"><![CDATA[View Allowed Actions]]></string>
+	<string name="_View"><![CDATA[View]]></string>
+	<string name="_Yes"><![CDATA[Yes]]></string>
+	<string name="_Your email"><![CDATA[Your email]]></string>
+	<string name="_Your name"><![CDATA[Your name]]></string>
+	<string name="__Afghanistan"><![CDATA[Afghanistan]]></string>
+	<string name="__Afrikaans"><![CDATA[Afrikaans]]></string>
+	<string name="__Aland_Islands"><![CDATA[Aland Islands]]></string>
+	<string name="__Albania"><![CDATA[Albania]]></string>
+	<string name="__Algeria"><![CDATA[Algeria]]></string>
+	<string name="__American Samoa"><![CDATA[American Samoa]]></string>
+	<string name="__Andorra"><![CDATA[Andorra]]></string>
+	<string name="__Angola"><![CDATA[Angola]]></string>
+	<string name="__Anguilla"><![CDATA[Anguilla]]></string>
+	<string name="__Antarctica"><![CDATA[Antarctica]]></string>
+	<string name="__Antigua and Barbuda"><![CDATA[Antigua and Barbuda]]></string>
+	<string name="__Arabic"><![CDATA[Arabic]]></string>
+	<string name="__Argentina"><![CDATA[Argentina]]></string>
+	<string name="__Armenia"><![CDATA[Armenia]]></string>
+	<string name="__Aruba"><![CDATA[Aruba]]></string>
+	<string name="__Australia"><![CDATA[Australia]]></string>
+	<string name="__Austria"><![CDATA[Austria]]></string>
+	<string name="__Azerbaijan"><![CDATA[Azerbaijan]]></string>
+	<string name="__Bahrain"><![CDATA[Bahrain]]></string>
+	<string name="__Bangladesh"><![CDATA[Bangladesh]]></string>
+	<string name="__Barbados"><![CDATA[Barbados]]></string>
+	<string name="__Belarus"><![CDATA[Belarus]]></string>
+	<string name="__Belgium"><![CDATA[Belgium]]></string>
+	<string name="__Belize"><![CDATA[Belize]]></string>
+	<string name="__Benin"><![CDATA[Benin]]></string>
+	<string name="__Bermuda"><![CDATA[Bermuda]]></string>
+	<string name="__Bhutan"><![CDATA[Bhutan]]></string>
+	<string name="__Bolivia"><![CDATA[Bolivia]]></string>
+	<string name="__Bosnia and Herzegovina"><![CDATA[Bosnia and Herzegovina]]></string>
+	<string name="__Botswana"><![CDATA[Botswana]]></string>
+	<string name="__Bouvet Island"><![CDATA[Bouvet Island]]></string>
+	<string name="__Brazil"><![CDATA[Brazil]]></string>
+	<string name="__British Indian Ocean Territory"><![CDATA[British Indian Ocean Territory]]></string>
+	<string name="__British Virgin Islands"><![CDATA[British Virgin Islands]]></string>
+	<string name="__Brunei Darussalam"><![CDATA[Brunei]]></string>
+	<string name="__Bulgaria"><![CDATA[Bulgaria]]></string>
+	<string name="__Bulgarian"><![CDATA[Bulgarian]]></string>
+	<string name="__Burkina Faso"><![CDATA[Burkina Faso]]></string>
+	<string name="__Burma"><![CDATA[Burma]]></string>
+	<string name="__Burmese"><![CDATA[Burmese]]></string>
+	<string name="__Burundi"><![CDATA[Burundi]]></string>
+	<string name="__Cambodia"><![CDATA[Cambodia]]></string>
+	<string name="__Cameroon"><![CDATA[Cameroon]]></string>
+	<string name="__Canada"><![CDATA[Canada]]></string>
+	<string name="__Cantonese"><![CDATA[Cantonese]]></string>
+	<string name="__Cape Verde"><![CDATA[Cape Verde]]></string>
+	<string name="__Cayman Islands"><![CDATA[Cayman Islands]]></string>
+	<string name="__Central African Republic"><![CDATA[Central African Republic]]></string>
+	<string name="__Chad"><![CDATA[Chad]]></string>
+	<string name="__Chile"><![CDATA[Chile]]></string>
+	<string name="__China"><![CDATA[China]]></string>
+	<string name="__Christmas Island"><![CDATA[Christmas Island]]></string>
+	<string name="__Cocos (Keeling) Islands"><![CDATA[Cocos (Keeling) Islands]]></string>
+	<string name="__Colombia"><![CDATA[Colombia]]></string>
+	<string name="__Comoros"><![CDATA[Comoros]]></string>
+	<string name="__Congo, Democratic Republic of the"><![CDATA[Congo, Democratic Republic of the]]></string>
+	<string name="__Congo, Republic of the"><![CDATA[Congo, Republic of the]]></string>
+	<string name="__Cook Islands"><![CDATA[Cook Islands]]></string>
+	<string name="__Costa Rica"><![CDATA[Costa Rica]]></string>
+	<string name="__Cote d'Ivoire"><![CDATA[Cote d'Ivoire]]></string>
+	<string name="__Croatia"><![CDATA[Croatia]]></string>
+	<string name="__Croatian"><![CDATA[Croatian]]></string>
+	<string name="__Cuba"><![CDATA[Cuba]]></string>
+	<string name="__Cyprus"><![CDATA[Cyprus]]></string>
+	<string name="__Czech Republic"><![CDATA[Czech Republic]]></string>
+	<string name="__Danish"><![CDATA[Danish]]></string>
+	<string name="__Denmark"><![CDATA[Denmark]]></string>
+	<string name="__Djibouti"><![CDATA[Djibouti]]></string>
+	<string name="__Dominica"><![CDATA[Dominica]]></string>
+	<string name="__Dominican Republic"><![CDATA[Dominican Republic]]></string>
+	<string name="__Dutch"><![CDATA[Dutch]]></string>
+	<string name="__East Timor"><![CDATA[East Timor]]></string>
+	<string name="__Ecuador"><![CDATA[Ecuador]]></string>
+	<string name="__Egypt"><![CDATA[Egypt]]></string>
+	<string name="__El Salvador"><![CDATA[El Salvador]]></string>
+	<string name="__English"><![CDATA[English]]></string>
+	<string name="__Equatorial Guinea"><![CDATA[Equatorial Guinea]]></string>
+	<string name="__Eritrea"><![CDATA[Eritrea]]></string>
+	<string name="__Esperanto"><![CDATA[Esperanto]]></string>
+	<string name="__Estonia"><![CDATA[Estonia]]></string>
+	<string name="__Estonian"><![CDATA[Estonian]]></string>
+	<string name="__Ethiopia"><![CDATA[Ethiopia]]></string>
+	<string name="__Falkland Islands (Islas Malvinas)"><![CDATA[Falkland Islands (Islas Malvinas)]]></string>
+	<string name="__Faroe Islands"><![CDATA[Faroe Islands]]></string>
+	<string name="__Fiji"><![CDATA[Fiji]]></string>
+	<string name="__Finland"><![CDATA[Finland]]></string>
+	<string name="__Finnish"><![CDATA[Finnish]]></string>
+	<string name="__France"><![CDATA[France]]></string>
+	<string name="__French"><![CDATA[French]]></string>
+	<string name="__French Guiana"><![CDATA[French Guiana]]></string>
+	<string name="__French Polynesia"><![CDATA[French Polynesia]]></string>
+	<string name="__French Southern and Antarctic Lands"><![CDATA[French Southern and Antarctic Lands]]></string>
+	<string name="__Gabon"><![CDATA[Gabon]]></string>
+	<string name="__Georgia"><![CDATA[Georgia]]></string>
+	<string name="__German"><![CDATA[German]]></string>
+	<string name="__Germany"><![CDATA[Germany]]></string>
+	<string name="__Ghana"><![CDATA[Ghana]]></string>
+	<string name="__Gibraltar"><![CDATA[Gibraltar]]></string>
+	<string name="__Greece"><![CDATA[Greece]]></string>
+	<string name="__Greek"><![CDATA[Greek]]></string>
+	<string name="__Greenland"><![CDATA[Greenland]]></string>
+	<string name="__Grenada"><![CDATA[Grenada]]></string>
+	<string name="__Guadeloupe"><![CDATA[Guadeloupe]]></string>
+	<string name="__Guam"><![CDATA[Guam]]></string>
+	<string name="__Guatemala"><![CDATA[Guatemala]]></string>
+	<string name="__Guernsey"><![CDATA[Guernsey]]></string>
+	<string name="__Guinea"><![CDATA[Guinea]]></string>
+	<string name="__Guinea-Bissau"><![CDATA[Guinea-Bissau]]></string>
+	<string name="__Gujrati"><![CDATA[Gujrati]]></string>
+	<string name="__Guyana"><![CDATA[Guyana]]></string>
+	<string name="__Haiti"><![CDATA[Haiti]]></string>
+	<string name="__Heard Island and McDonald Islands"><![CDATA[Heard Island and McDonald Islands]]></string>
+	<string name="__Hebrew"><![CDATA[Hebrew]]></string>
+	<string name="__Hindi"><![CDATA[Hindi]]></string>
+	<string name="__Holy See (Vatican City)"><![CDATA[Holy See (Vatican City)]]></string>
+	<string name="__Honduras"><![CDATA[Honduras]]></string>
+	<string name="__Hong Kong (SAR)"><![CDATA[Hong Kong (SAR)]]></string>
+	<string name="__Hungarian"><![CDATA[Hungarian]]></string>
+	<string name="__Hungary"><![CDATA[Hungary]]></string>
+	<string name="__Iceland"><![CDATA[Iceland]]></string>
+	<string name="__Icelandic"><![CDATA[Icelandic]]></string>
+	<string name="__India"><![CDATA[India]]></string>
+	<string name="__Indonesia"><![CDATA[Indonesia]]></string>
+	<string name="__Indonesian"><![CDATA[Indonesian]]></string>
+	<string name="__Iran"><![CDATA[Iran]]></string>
+	<string name="__Iraq"><![CDATA[Iraq]]></string>
+	<string name="__Ireland"><![CDATA[Ireland]]></string>
+	<string name="__Isle_of_Man"><![CDATA[Isle of Man]]></string>
+	<string name="__Israel"><![CDATA[Israel]]></string>
+	<string name="__Italian"><![CDATA[Italian]]></string>
+	<string name="__Italy"><![CDATA[Italy]]></string>
+	<string name="__Jamaica"><![CDATA[Jamaica]]></string>
+	<string name="__Japan"><![CDATA[Japan]]></string>
+	<string name="__Japanese"><![CDATA[Japanese]]></string>
+	<string name="__Jersey"><![CDATA[Jersey]]></string>
+	<string name="__Jordan"><![CDATA[Jordan]]></string>
+	<string name="__Kazakhstan"><![CDATA[Kazakhstan]]></string>
+	<string name="__Kenya"><![CDATA[Kenya]]></string>
+	<string name="__Kiribati"><![CDATA[Kiribati]]></string>
+	<string name="__Korea, North"><![CDATA[Korea, North]]></string>
+	<string name="__Korea, South"><![CDATA[Korea, South]]></string>
+	<string name="__Korean"><![CDATA[Korean]]></string>
+	<string name="__Kuwait"><![CDATA[Kuwait]]></string>
+	<string name="__Kyrgyzstan"><![CDATA[Kyrgyzstan]]></string>
+	<string name="__Laos"><![CDATA[Laos]]></string>
+	<string name="__Latvia"><![CDATA[Latvia]]></string>
+	<string name="__Latvian"><![CDATA[Latvian]]></string>
+	<string name="__Lebanon"><![CDATA[Lebanon]]></string>
+	<string name="__Lesotho"><![CDATA[Lesotho]]></string>
+	<string name="__Liberia"><![CDATA[Liberia]]></string>
+	<string name="__Libya"><![CDATA[Libya]]></string>
+	<string name="__Liechtenstein"><![CDATA[Liechtenstein]]></string>
+	<string name="__Lithuania"><![CDATA[Lithuania]]></string>
+	<string name="__Lithuanian"><![CDATA[Lithuanian]]></string>
+	<string name="__Luxembourg"><![CDATA[Luxembourg]]></string>
+	<string name="__Macao"><![CDATA[Macao]]></string>
+	<string name="__Macedonia, The Former Yugoslav Republic of"><![CDATA[Macedonia, The Former Yugoslav Republic of]]></string>
+	<string name="__Madagascar"><![CDATA[Madagascar]]></string>
+	<string name="__Malawi"><![CDATA[Malawi]]></string>
+	<string name="__Malay"><![CDATA[Malay]]></string>
+	<string name="__Malaysia"><![CDATA[Malaysia]]></string>
+	<string name="__Maldives"><![CDATA[Maldives]]></string>
+	<string name="__Mali"><![CDATA[Mali]]></string>
+	<string name="__Malta"><![CDATA[Malta]]></string>
+	<string name="__Mandarin"><![CDATA[Mandarin]]></string>
+	<string name="__Marathi"><![CDATA[Marathi]]></string>
+	<string name="__Marshall Islands"><![CDATA[Marshall Islands]]></string>
+	<string name="__Martinique"><![CDATA[Martinique]]></string>
+	<string name="__Mauritania"><![CDATA[Mauritania]]></string>
+	<string name="__Mauritius"><![CDATA[Mauritius]]></string>
+	<string name="__Mayotte"><![CDATA[Mayotte]]></string>
+	<string name="__Mexico"><![CDATA[Mexico]]></string>
+	<string name="__Micronesia, Federated States of"><![CDATA[Micronesia, Federated States of]]></string>
+	<string name="__Moldova"><![CDATA[Moldova]]></string>
+	<string name="__Moldovian"><![CDATA[Moldovian]]></string>
+	<string name="__Monaco"><![CDATA[Monaco]]></string>
+	<string name="__Mongolia"><![CDATA[Mongolia]]></string>
+	<string name="__Montenegro"><![CDATA[Montenegro]]></string>
+	<string name="__Montserrat"><![CDATA[Montserrat]]></string>
+	<string name="__Morocco"><![CDATA[Morocco]]></string>
+	<string name="__Mozambique"><![CDATA[Mozambique]]></string>
+	<string name="__Namibia"><![CDATA[Namibia]]></string>
+	<string name="__Nauru"><![CDATA[Nauru]]></string>
+	<string name="__Nepal"><![CDATA[Nepal]]></string>
+	<string name="__Nepalese"><![CDATA[Nepalese]]></string>
+	<string name="__Netherlands"><![CDATA[Netherlands]]></string>
+	<string name="__Netherlands Antilles"><![CDATA[Netherlands Antilles]]></string>
+	<string name="__New Caledonia"><![CDATA[New Caledonia]]></string>
+	<string name="__New Zealand"><![CDATA[New Zealand]]></string>
+	<string name="__Nicaragua"><![CDATA[Nicaragua]]></string>
+	<string name="__Niger"><![CDATA[Niger]]></string>
+	<string name="__Nigeria"><![CDATA[Nigeria]]></string>
+	<string name="__Niue"><![CDATA[Niue]]></string>
+	<string name="__Norfolk Island"><![CDATA[Norfolk Island]]></string>
+	<string name="__Northern Mariana Islands"><![CDATA[Northern Mariana Islands]]></string>
+	<string name="__Norway"><![CDATA[Norway]]></string>
+	<string name="__Norwegian"><![CDATA[Norwegian]]></string>
+	<string name="__Oman"><![CDATA[Oman]]></string>
+	<string name="__Pakistan"><![CDATA[Pakistan]]></string>
+	<string name="__Palau"><![CDATA[Palau]]></string>
+	<string name="__Palestinian Territory, Occupied"><![CDATA[Palestinian Territory, Occupied]]></string>
+	<string name="__Panama"><![CDATA[Panama]]></string>
+	<string name="__Papua New Guinea"><![CDATA[Papua New Guinea]]></string>
+	<string name="__Paraguay"><![CDATA[Paraguay]]></string>
+	<string name="__Persian"><![CDATA[Persian]]></string>
+	<string name="__Peru"><![CDATA[Peru]]></string>
+	<string name="__Philippines"><![CDATA[Philippines]]></string>
+	<string name="__Pitcairn Islands"><![CDATA[Pitcairn Islands]]></string>
+	<string name="__Poland"><![CDATA[Poland]]></string>
+	<string name="__Polish"><![CDATA[Polish]]></string>
+	<string name="__Portugal"><![CDATA[Portugal]]></string>
+	<string name="__Portuguese"><![CDATA[Portuguese]]></string>
+	<string name="__Puerto Rico"><![CDATA[Puerto Rico]]></string>
+	<string name="__Punjabi"><![CDATA[Punjabi]]></string>
+	<string name="__Qatar"><![CDATA[Qatar]]></string>
+	<string name="__Reunion"><![CDATA[Reunion]]></string>
+	<string name="__Romania"><![CDATA[Romania]]></string>
+	<string name="__Romanian"><![CDATA[Romanian]]></string>
+	<string name="__Russia"><![CDATA[Russia]]></string>
+	<string name="__Russian"><![CDATA[Russian]]></string>
+	<string name="__Rwanda"><![CDATA[Rwanda]]></string>
+	<string name="__Saint Helena"><![CDATA[Saint Helena]]></string>
+	<string name="__Saint Kitts and Nevis"><![CDATA[Saint Kitts and Nevis]]></string>
+	<string name="__Saint Lucia"><![CDATA[Saint Lucia]]></string>
+	<string name="__Saint Pierre and Miquelon"><![CDATA[Saint Pierre and Miquelon]]></string>
+	<string name="__Saint Vincent and the Grenadines"><![CDATA[Saint Vincent and the Grenadines]]></string>
+	<string name="__Saint_Barthelemy"><![CDATA[Saint Barthelemy]]></string>
+	<string name="__Saint_Martin_French_part"><![CDATA[Saint Martin (French part)]]></string>
+	<string name="__Samoa"><![CDATA[Samoa]]></string>
+	<string name="__San Marino"><![CDATA[San Marino]]></string>
+	<string name="__Sao Tome and Principe"><![CDATA[Sao Tome and Principe]]></string>
+	<string name="__Saudi Arabia"><![CDATA[Saudi Arabia]]></string>
+	<string name="__Senegal"><![CDATA[Senegal]]></string>
+	<string name="__Serbia"><![CDATA[Serbia]]></string>
+	<string name="__Serbian"><![CDATA[Serbian]]></string>
+	<string name="__Seychelles"><![CDATA[Seychelles]]></string>
+	<string name="__Sierra Leone"><![CDATA[Sierra Leone]]></string>
+	<string name="__Singapore"><![CDATA[Singapore]]></string>
+	<string name="__Slovakia"><![CDATA[Slovakia]]></string>
+	<string name="__Slovenia"><![CDATA[Slovenia]]></string>
+	<string name="__Solomon Islands"><![CDATA[Solomon Islands]]></string>
+	<string name="__Somalia"><![CDATA[Somalia]]></string>
+	<string name="__South Africa"><![CDATA[South Africa]]></string>
+	<string name="__South Georgia and the South Sandwich Islands"><![CDATA[South Georgia and the South Sandwich Islands]]></string>
+	<string name="__Spain"><![CDATA[Spain]]></string>
+	<string name="__Spanish"><![CDATA[Spanish]]></string>
+	<string name="__Sri Lanka"><![CDATA[Sri Lanka]]></string>
+	<string name="__Sudan"><![CDATA[Sudan]]></string>
+	<string name="__Suriname"><![CDATA[Suriname]]></string>
+	<string name="__Svalbard"><![CDATA[Svalbard]]></string>
+	<string name="__Swaziland"><![CDATA[Swaziland]]></string>
+	<string name="__Sweden"><![CDATA[Sweden]]></string>
+	<string name="__Swedish"><![CDATA[Swedish]]></string>
+	<string name="__Switzerland"><![CDATA[Switzerland]]></string>
+	<string name="__Syria"><![CDATA[Syria]]></string>
+	<string name="__Tagalog"><![CDATA[Tagalog]]></string>
+	<string name="__Taiwan"><![CDATA[Taiwan]]></string>
+	<string name="__Taiwanese"><![CDATA[Taiwanese]]></string>
+	<string name="__Tajikistan"><![CDATA[Tajikistan]]></string>
+	<string name="__Tamil"><![CDATA[Tamil]]></string>
+	<string name="__Tanzania"><![CDATA[Tanzania]]></string>
+	<string name="__Telugu"><![CDATA[Telugu]]></string>
+	<string name="__Thai"><![CDATA[Thai]]></string>
+	<string name="__Thailand"><![CDATA[Thailand]]></string>
+	<string name="__The Bahamas"><![CDATA[The Bahamas]]></string>
+	<string name="__The Gambia"><![CDATA[The Gambia]]></string>
+	<string name="__Togo"><![CDATA[Togo]]></string>
+	<string name="__Tokelau"><![CDATA[Tokelau]]></string>
+	<string name="__Tonga"><![CDATA[Tonga]]></string>
+	<string name="__Tongan"><![CDATA[Tongan]]></string>
+	<string name="__Trinidad and Tobago"><![CDATA[Trinidad and Tobago]]></string>
+	<string name="__Tunisia"><![CDATA[Tunisia]]></string>
+	<string name="__Turkey"><![CDATA[Turkey]]></string>
+	<string name="__Turkish"><![CDATA[Turkish]]></string>
+	<string name="__Turkmenistan"><![CDATA[Turkmenistan]]></string>
+	<string name="__Turks and Caicos Islands"><![CDATA[Turks and Caicos Islands]]></string>
+	<string name="__Tuvalu"><![CDATA[Tuvalu]]></string>
+	<string name="__Uganda"><![CDATA[Uganda]]></string>
+	<string name="__Ukraine"><![CDATA[Ukraine]]></string>
+	<string name="__Ukrainian"><![CDATA[Ukrainian]]></string>
+	<string name="__United Arab Emirates"><![CDATA[United Arab Emirates]]></string>
+	<string name="__United Kingdom"><![CDATA[United Kingdom]]></string>
+	<string name="__United States"><![CDATA[United States]]></string>
+	<string name="__United States Minor Outlying Islands"><![CDATA[United States Minor Outlying Islands]]></string>
+	<string name="__Urdu"><![CDATA[Urdu]]></string>
+	<string name="__Uruguay"><![CDATA[Uruguay]]></string>
+	<string name="__Uzbekistan"><![CDATA[Uzbekistan]]></string>
+	<string name="__Vanuatu"><![CDATA[Vanuatu]]></string>
+	<string name="__Venezuela"><![CDATA[Venezuela]]></string>
+	<string name="__Vietnam"><![CDATA[Vietnam]]></string>
+	<string name="__Vietnamese"><![CDATA[Vietnamese]]></string>
+	<string name="__Virgin Islands"><![CDATA[Virgin Islands]]></string>
+	<string name="__Visayan"><![CDATA[Visayan]]></string>
+	<string name="__Wallis and Futuna"><![CDATA[Wallis and Futuna]]></string>
+	<string name="__Western Sahara"><![CDATA[Western Sahara]]></string>
+	<string name="__Yemen"><![CDATA[Yemen]]></string>
+	<string name="__Zambia"><![CDATA[Zambia]]></string>
+	<string name="__Zimbabwe"><![CDATA[Zimbabwe]]></string>
+	<string name="_adm_act_err_failed_page_loading"><![CDATA[Cannot load the page]]></string>
+	<string name="_adm_action_cpt_checkout"><![CDATA[Checkout]]></string>
+	<string name="_adm_action_cpt_delete_all"><![CDATA[Delete All]]></string>
+	<string name="_adm_action_cpt_see_all"><![CDATA[See All]]></string>
+	<string name="_adm_admtools_Audit"><![CDATA[Audit]]></string>
+	<string name="_adm_admtools_Current_level"><![CDATA[Current status]]></string>
+	<string name="_adm_admtools_Desired_level"><![CDATA[Desired status]]></string>
+	<string name="_adm_admtools_Executable"><![CDATA[Executable]]></string>
+	<string name="_adm_admtools_Non_Executable"><![CDATA[Not executable]]></string>
+	<string name="_adm_admtools_Non_Writable"><![CDATA[Not writable]]></string>
+	<string name="_adm_admtools_Not_Exists"><![CDATA[Not exists]]></string>
+	<string name="_adm_admtools_Path"><![CDATA[Path]]></string>
+	<string name="_adm_admtools_Permissions"><![CDATA[Permissions]]></string>
+	<string name="_adm_admtools_Writable"><![CDATA[Writable]]></string>
+	<string name="_adm_admtools_title"><![CDATA[Admin Tools]]></string>
+	<string name="_adm_block_cpt_categories"><![CDATA[Categories]]></string>
+	<string name="_adm_block_cpt_category"><![CDATA[Category: {0}]]></string>
+	<string name="_adm_block_cpt_checkout"><![CDATA[Checkout]]></string>
+	<string name="_adm_block_cpt_checkout_by_vendor_ccode"><![CDATA[Products from {0} ({1} {2})]]></string>
+	<string name="_adm_block_cpt_checkout_by_vendor_csign"><![CDATA[Products from {0} ({1}{2})]]></string>
+	<string name="_adm_block_cpt_downloaded_modules"><![CDATA[Modules]]></string>
+	<string name="_adm_block_cpt_downloaded_updates"><![CDATA[Updates]]></string>
+	<string name="_adm_block_cpt_featured"><![CDATA[Featured]]></string>
+	<string name="_adm_block_cpt_goodies"><![CDATA[Storefront]]></string>
+	<string name="_adm_block_cpt_latest"><![CDATA[Latest]]></string>
+	<string name="_adm_block_cpt_modules_upload"><![CDATA[Add New Module]]></string>
+	<string name="_adm_block_cpt_popular"><![CDATA[Popular]]></string>
+	<string name="_adm_block_cpt_purchases"><![CDATA[Purchases]]></string>
+	<string name="_adm_block_cpt_search"><![CDATA[Search]]></string>
+	<string name="_adm_block_cpt_space"><![CDATA[Space Usage]]></string>
+	<string name="_adm_block_cpt_tag"><![CDATA[Hashtag: {0}]]></string>
+	<string name="_adm_block_cpt_tags"><![CDATA[Hashtags]]></string>
+	<string name="_adm_block_cpt_updates"><![CDATA[Updates]]></string>
+	<string name="_adm_block_cpt_versions"><![CDATA[Versions]]></string>
+	<string name="_adm_bp_btn_add_block"><![CDATA[Add Blocks]]></string>
+	<string name="_adm_bp_btn_block_add"><![CDATA[Add to Page]]></string>
+	<string name="_adm_bp_btn_block_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_bp_btn_block_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_bp_btn_block_save"><![CDATA[Save]]></string>
+	<string name="_adm_bp_btn_create_new"><![CDATA[Add New Page]]></string>
+	<string name="_adm_bp_btn_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_bp_btn_page_apply"><![CDATA[Apply]]></string>
+	<string name="_adm_bp_btn_page_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_bp_btn_page_create"><![CDATA[Create]]></string>
+	<string name="_adm_bp_btn_settings"><![CDATA[Settings]]></string>
+	<string name="_adm_bp_btn_view_page"><![CDATA[View Page]]></string>
+	<string name="_adm_bp_cpt_type_custom"><![CDATA[Custom]]></string>
+	<string name="_adm_bp_cpt_type_modules"><![CDATA[Modules]]></string>
+	<string name="_adm_bp_cpt_type_system"><![CDATA[System]]></string>
+	<string name="_adm_bp_dsc_block_content_image_file"><![CDATA[The image will be displayed in block]]></string>
+	<string name="_adm_bp_dsc_block_content_lang"><![CDATA[Enter the content in accordance with the selected language]]></string>
+	<string name="_adm_bp_dsc_block_content_raw"><![CDATA[Enter HTML content here]]></string>
+	<string name="_adm_bp_dsc_block_content_rss_length"><![CDATA[Enter a number of displayed items here]]></string>
+	<string name="_adm_bp_dsc_block_content_rss_url"><![CDATA[Enter URL to RSS resource here]]></string>
+	<string name="_adm_bp_dsc_block_title"><![CDATA[Short name for the block, visible in block header.]]></string>
+	<string name="_adm_bp_dsc_block_visible_for_levels"><![CDATA[Select user levels that can see this block]]></string>
+	<string name="_adm_bp_dsc_page_cache_lifetime"><![CDATA[Store page in cache for this number of seconds]]></string>
+	<string name="_adm_bp_dsc_page_meta_description"><![CDATA[Use 10-50 words to tell search engines what the page is about.]]></string>
+	<string name="_adm_bp_dsc_page_meta_keywords"><![CDATA[Use 5-10 keywords, separated by comma, associated with page content.]]></string>
+	<string name="_adm_bp_dsc_page_meta_robots"><![CDATA[Standard commands for search engine robots. Example: noindex, nofollow.]]></string>
+	<string name="_adm_bp_dsc_page_title"><![CDATA[Page title displayed in page header. Use at least 3 characters.]]></string>
+	<string name="_adm_bp_dsc_page_title_system"><![CDATA[Page name, displayed in studio only.]]></string>
+	<string name="_adm_bp_dsc_page_uri"><![CDATA[Page address used after 'youdomain.com/page/'. It must be unique and it can not be changed later.]]></string>
+	<string name="_adm_bp_dsc_page_url"><![CDATA[Page link to access the page.]]></string>
+	<string name="_adm_bp_dsc_page_visible_for_levels"><![CDATA[Select user levels that can see this page]]></string>
+	<string name="_adm_bp_err_block_added"><![CDATA[Cannot add block(s)]]></string>
+	<string name="_adm_bp_err_block_content_image_preview_delete"><![CDATA[Cannot delete image.]]></string>
+	<string name="_adm_bp_err_block_delete"><![CDATA[Cannot delete block]]></string>
+	<string name="_adm_bp_err_block_designbox"><![CDATA[Select a layout box for the block]]></string>
+	<string name="_adm_bp_err_block_edit"><![CDATA[Cannot update block]]></string>
+	<string name="_adm_bp_err_block_not_deletable"><![CDATA[The requested block cannot be deleted.]]></string>
+	<string name="_adm_bp_err_block_not_found"><![CDATA[The requested block cannot be found.]]></string>
+	<string name="_adm_bp_err_block_title"><![CDATA[Enter title, more than 3 characters]]></string>
+	<string name="_adm_bp_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_bp_err_nothing_changed"><![CDATA[Nothing was changed or an error occurred.]]></string>
+	<string name="_adm_bp_err_page_create"><![CDATA[Cannot create the page.]]></string>
+	<string name="_adm_bp_err_page_delete"><![CDATA[Cannot delete the page.]]></string>
+	<string name="_adm_bp_err_page_layout"><![CDATA[Please, select a page layout.]]></string>
+	<string name="_adm_bp_err_page_title"><![CDATA[A title with at least 3 characters is required.]]></string>
+	<string name="_adm_bp_err_page_title_system"><![CDATA[A name with at least 3 characters is required.]]></string>
+	<string name="_adm_bp_err_page_uri"><![CDATA[A unique URL with at least 3 characters is required.]]></string>
+	<string name="_adm_bp_err_page_visible_for_levels"><![CDATA[Visibility setting are determined by custom code or not applicable here.]]></string>
+	<string name="_adm_bp_err_save"><![CDATA[Cannot save or nothing was changed.]]></string>
+	<string name="_adm_bp_mi_page_cache"><![CDATA[Cache]]></string>
+	<string name="_adm_bp_mi_page_cover"><![CDATA[Cover]]></string>
+	<string name="_adm_bp_mi_page_layout"><![CDATA[Layout]]></string>
+	<string name="_adm_bp_mi_page_options"><![CDATA[Options]]></string>
+	<string name="_adm_bp_mi_page_seo"><![CDATA[SEO]]></string>
+	<string name="_adm_bp_mi_page_visibility"><![CDATA[Visibility]]></string>
+	<string name="_adm_bp_scs_save"><![CDATA[The changes were successfully saved]]></string>
+	<string name="_adm_bp_txt_block_active"><![CDATA[Active]]></string>
+	<string name="_adm_bp_txt_block_content_attachments_html"><![CDATA[Attachments]]></string>
+	<string name="_adm_bp_txt_block_content_image_align"><![CDATA[Alignment]]></string>
+	<string name="_adm_bp_txt_block_content_image_align_center"><![CDATA[center]]></string>
+	<string name="_adm_bp_txt_block_content_image_align_empty"><![CDATA[Select alignment...]]></string>
+	<string name="_adm_bp_txt_block_content_image_align_left"><![CDATA[left]]></string>
+	<string name="_adm_bp_txt_block_content_image_align_right"><![CDATA[right]]></string>
+	<string name="_adm_bp_txt_block_content_image_file"><![CDATA[Upload New Image]]></string>
+	<string name="_adm_bp_txt_block_content_image_preview"><![CDATA[Current Image]]></string>
+	<string name="_adm_bp_txt_block_content_lang"><![CDATA[Content]]></string>
+	<string name="_adm_bp_txt_block_content_menu"><![CDATA[Menu]]></string>
+	<string name="_adm_bp_txt_block_content_menu_empty"><![CDATA[Select menu...]]></string>
+	<string name="_adm_bp_txt_block_content_raw"><![CDATA[Content]]></string>
+	<string name="_adm_bp_txt_block_content_rss_length"><![CDATA[Length]]></string>
+	<string name="_adm_bp_txt_block_content_rss_url"><![CDATA[URL]]></string>
+	<string name="_adm_bp_txt_block_content_service_method"><![CDATA[Method]]></string>
+	<string name="_adm_bp_txt_block_content_service_module"><![CDATA[Module]]></string>
+	<string name="_adm_bp_txt_block_designbox"><![CDATA[Block Layout]]></string>
+	<string name="_adm_bp_txt_block_designbox_empty"><![CDATA[Select layout...]]></string>
+	<string name="_adm_bp_txt_block_hidden_on"><![CDATA[Hidden on]]></string>
+	<string name="_adm_bp_txt_block_hidden_on_phone"><![CDATA[phone]]></string>
+	<string name="_adm_bp_txt_block_hidden_on_tablet"><![CDATA[tablet]]></string>
+	<string name="_adm_bp_txt_block_hidden_on_desktop"><![CDATA[desktop]]></string>
+        <string name="_adm_bp_txt_block_hidden_on_mobile"><![CDATA[mobile app]]></string>
+	<string name="_adm_bp_txt_block_selected"><![CDATA[blocks selected]]></string>
+	<string name="_adm_bp_txt_block_title"><![CDATA[Title]]></string>
+	<string name="_adm_bp_txt_block_visible_for"><![CDATA[Visible For]]></string>
+	<string name="_adm_bp_txt_block_visible_for_all"><![CDATA[Anyone]]></string>
+	<string name="_adm_bp_txt_block_visible_for_levels"><![CDATA[Select Levels]]></string>
+	<string name="_adm_bp_txt_block_visible_for_selected"><![CDATA[Selected levels]]></string>
+	<string name="_adm_bp_txt_create_popup"><![CDATA[Create New Page]]></string>
+	<string name="_adm_bp_txt_edit_block_popup"><![CDATA[Edit "{0}" Block]]></string>
+	<string name="_adm_bp_txt_new_block_popup"><![CDATA[Add New Block]]></string>
+	<string name="_adm_bp_txt_page_cache_lifetime"><![CDATA[Cache]]></string>
+	<string name="_adm_bp_txt_page_cover"><![CDATA[Cover]]></string>
+	<string name="_adm_bp_txt_page_cover_image"><![CDATA[Custom Cover]]></string>
+	<string name="_adm_bp_txt_page_layout"><![CDATA[Layout]]></string>
+	<string name="_adm_bp_txt_page_layout_empty"><![CDATA[Select Layout...]]></string>
+	<string name="_adm_bp_txt_page_meta_description"><![CDATA[Page (Meta) Description]]></string>
+	<string name="_adm_bp_txt_page_meta_keywords"><![CDATA[Keywords]]></string>
+	<string name="_adm_bp_txt_page_meta_robots"><![CDATA[Meta Robots]]></string>
+        <string name="_adm_bp_txt_page_submenu"><![CDATA[Submenu]]></string>
+	<string name="_adm_bp_dsc_page_submenu"><![CDATA[Page submenu can be selected here]]></string>
+	<string name="_adm_bp_txt_page_title"><![CDATA[Title]]></string>
+	<string name="_adm_bp_txt_page_title_system"><![CDATA[System Name]]></string>
+	<string name="_adm_bp_txt_page_type_id"><![CDATA[Type]]></string>
+	<string name="_adm_bp_dsc_page_type_id"><![CDATA[Page display type]]></string>
+	<string name="_adm_bp_txt_page_uri"><![CDATA[URL]]></string>
+	<string name="_adm_bp_txt_page_url"><![CDATA[Link]]></string>
+	<string name="_adm_bp_txt_page_visible_for_levels"><![CDATA[Select Levels]]></string>
+	<string name="_adm_bp_txt_select_page"><![CDATA[Select Page...]]></string>
+	<string name="_adm_bp_txt_settings_popup"><![CDATA[Settings]]></string>
+	<string name="_adm_bp_txt_visible_for"><![CDATA[Visible for {0}]]></string>
+	<string name="_adm_bp_wrn_page_delete"><![CDATA[Are you sure you want to delete the page?]]></string>
+	<string name="_adm_bp_wrn_page_block_delete"><![CDATA[Are you sure you want to delete the block?]]></string>
+	<string name="_adm_btn_cancel_submit"><![CDATA[Cancel]]></string>
+	<string name="_adm_btn_checkout_submit"><![CDATA[Checkout]]></string>
+	<string name="_adm_btn_delete_submit"><![CDATA[Delete]]></string>
+	<string name="_adm_btn_designer_submit"><![CDATA[Submit]]></string>
+	<string name="_adm_btn_download_submit"><![CDATA[Download]]></string>
+	<string name="_adm_btn_install_submit"><![CDATA[Install]]></string>
+	<string name="_adm_btn_installed_submit"><![CDATA[Installed]]></string>
+	<string name="_adm_btn_login_submit"><![CDATA[Enter]]></string>
+	<string name="_adm_btn_queued_submit"><![CDATA[Queued]]></string>
+	<string name="_adm_btn_settings_import"><![CDATA[Import]]></string>
+	<string name="_adm_btn_settings_save"><![CDATA[Save]]></string>
+	<string name="_adm_btn_settings_mix_create"><![CDATA[Add New Mix]]></string>
+	<string name="_adm_btn_settings_mix_import"><![CDATA[Import]]></string>
+	<string name="_adm_btn_settings_mix_export"><![CDATA[Export]]></string>
+	<string name="_adm_btn_settings_mix_delete"><![CDATA[Delete]]></string>
+        <string name="_adm_btn_settings_mix_hide"><![CDATA[Hide]]></string>
+        <string name="_adm_btn_settings_mix_publish"><![CDATA[Publish]]></string>
+	<string name="_adm_btn_store_search"><![CDATA[Search]]></string>
+	<string name="_adm_dbd_btn_update"><![CDATA[Update]]></string>
+	<string name="_adm_dbd_txt_version_n_available"><![CDATA[UNA {0} is available!]]></string>
+	<string name="_adm_dbd_txt_script_on"><![CDATA[UNA on]]></string>
+	<string name="_adm_dbd_txt_htools_status"><![CDATA[{0} - <b>{1}</b>]]></string>
+	<string name="_adm_dbd_txt_installed"><![CDATA[Installed:]]></string>
+	<string name="_adm_dbd_txt_version"><![CDATA[Version:]]></string>
+    <string name="_adm_dbd_msg_upgrade_started"><![CDATA[Site will be upgraded within a minute.<br />Don't forget to <a href="{0}store.php?page=updates">check for modules updates</a> after that.]]></string>
+	<string name="_adm_dbd_txt_su_database"><![CDATA[Database]]></string>
+	<string name="_adm_dbd_txt_su_system"><![CDATA[System]]></string>
+	<string name="_adm_dbd_txt_su_system_media"><![CDATA[System Media]]></string>
+	<string name="_adm_dbd_txt_c_clear_all"><![CDATA[Clear all caches]]></string>
+	<string name="_adm_dbd_txt_c_db"><![CDATA[DB]]></string>
+	<string name="_adm_dbd_txt_c_clear_db"><![CDATA[Clear DB cache]]></string>
+	<string name="_adm_dbd_txt_c_template"><![CDATA[Template]]></string>
+	<string name="_adm_dbd_txt_c_clear_template"><![CDATA[Clear Template cache]]></string>
+	<string name="_adm_dbd_txt_c_css"><![CDATA[CSS]]></string>
+	<string name="_adm_dbd_txt_c_clear_css"><![CDATA[Clear CSS cache]]></string>
+	<string name="_adm_dbd_txt_c_js"><![CDATA[JavaScript]]></string>
+	<string name="_adm_dbd_txt_c_clear_js"><![CDATA[Clear JavaScript cache]]></string>
+        <string name="_adm_dbd_txt_c_clear_custom"><![CDATA[Clear Custom cache]]></string>
+	<string name="_adm_dbd_err_c_clean_failed"><![CDATA[Failed to clean cache]]></string>
+	<string name="_adm_dbd_msg_c_clean_success"><![CDATA[Cache was successfully cleaned]]></string>
+	<string name="_adm_dbd_msg_c_all_disabled"><![CDATA[All caches are disabled]]></string>
+    <string name="_adm_dsn_cnf_uninstall"><![CDATA[<h3>Uninstall "{0}" template?</h3><p>Uninstalling "{0}" template will also delete all of its data. Do you want to continue?</p>]]></string>
+	<string name="_adm_dsg_btn_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_dsg_btn_make_default"><![CDATA[Make Default]]></string>
+	<string name="_adm_dsg_dsc_alt_text"><![CDATA[Serves as "ALT" text for logo image. Used as a logo when no logo image is uploaded.]]></string>
+	<string name="_adm_dsg_dsc_splash_warning"><![CDATA[Note, that improper use of HTML may break the site layout.]]></string>
+	<string name="_adm_dsg_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_dsg_err_deactivate_default"><![CDATA[You cannot deactivate template which was selected as Default]]></string>
+	<string name="_adm_dsg_err_last_active"><![CDATA[You need to have at least one active template.]]></string>
+	<string name="_adm_dsg_err_make_default"><![CDATA[Cannot make the template default.]]></string>
+	<string name="_adm_dsg_err_remove_old_cover"><![CDATA[Cannot remove current cover image.]]></string>
+	<string name="_adm_dsg_err_remove_old_icon"><![CDATA[Cannot remove current icon.]]></string>
+	<string name="_adm_dsg_err_remove_old_logo"><![CDATA[Cannot remove current logo image.]]></string>
+	<string name="_adm_dsg_err_save"><![CDATA[Cannot save: ]]></string>
+	<string name="_adm_dsg_err_save_changes"><![CDATA[Cannot save changes.]]></string>
+	<string name="_adm_dsg_scs_save"><![CDATA[The changes were successfully saved]]></string>
+	<string name="_adm_dsg_txt_alt_text"><![CDATA[Logo Text]]></string>
+	<string name="_adm_dsg_txt_cover_common"><![CDATA[Default pages cover]]></string>
+	<string name="_adm_dsg_txt_cover_unit_profile"><![CDATA[Default profile unit cover]]></string>
+	<string name="_adm_dsg_txt_splash_enabled"><![CDATA[Enable splash page]]></string>
+	<string name="_adm_dsg_txt_default"><![CDATA[default]]></string>
+	<string name="_adm_dsg_txt_icon_apple"><![CDATA[Apple Touch Devices (152x152)]]></string>
+	<string name="_adm_dsg_txt_icon_facebook"><![CDATA[Facebook Share (100x100)]]></string>
+	<string name="_adm_dsg_txt_icon_favicon"><![CDATA[Favicon (16x16)]]></string>
+	<string name="_adm_dsg_txt_upload_cover_common"><![CDATA[Upload new common pages cover]]></string>
+	<string name="_adm_dsg_txt_upload_cover_unit_profile"><![CDATA[Upload new profile unit cover]]></string>
+	<string name="_adm_dsg_txt_upload_icon"><![CDATA[Upload New Site Icon]]></string>
+	<string name="_adm_dsg_txt_upload_image"><![CDATA[Upload New Logo Image]]></string>
+	<string name="_adm_dsg_txt_upload_image_preview"><![CDATA[Current Logo Image]]></string>
+	<string name="_adm_dsg_txt_inj_head"><![CDATA[&lt;HEAD&gt; injection]]></string>
+	<string name="_adm_dsg_txt_inj_head_inf"><![CDATA[Code to insert before closing HEAD tag]]></string>
+	<string name="_adm_dsg_txt_inj_body"><![CDATA[&lt;BODY&gt; injection]]></string>
+	<string name="_adm_dsg_txt_inj_body_inf"><![CDATA[Code to insert before closing BODY tag]]></string>
+	<string name="_adm_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_err_form_view_iu_delete"><![CDATA[Cannot remove current image.]]></string>
+	<string name="_adm_err_form_view_iu_save"><![CDATA[Cannot save: ]]></string>
+	<string name="_adm_err_modules_already_disabled"><![CDATA[The module is already disabled.]]></string>
+	<string name="_adm_err_modules_already_enabled"><![CDATA[The module is already enabled.]]></string>
+	<string name="_adm_err_modules_already_installed"><![CDATA[The module was already installed.]]></string>
+	<string name="_adm_err_modules_already_uninstalled"><![CDATA[The module was already uninstalled.]]></string>
+	<string name="_adm_err_modules_cannot_add_to_cart"><![CDATA[Cannot add the product to shopping cart.]]></string>
+	<string name="_adm_err_modules_cannot_checkout_empty_vendor"><![CDATA[Cannot checkout. The vendor is unknown.]]></string>
+	<string name="_adm_err_modules_cannot_delete_from_cart"><![CDATA[Cannot delete the product(s) from shopping cart.]]></string>
+	<string name="_adm_err_modules_cannot_remove_package"><![CDATA[Cannot remove package.]]></string>
+	<string name="_adm_err_modules_cannot_subscribe"><![CDATA[Cannot initialize the subscription.]]></string>
+	<string name="_adm_err_modules_module_not_found"><![CDATA[Module not found]]></string>
+	<string name="_adm_err_modules_module_not_match"><![CDATA[Update is not suitable for this module.]]></string>
+	<string name="_adm_err_modules_module_not_installed"><![CDATA[Module not installed]]></string>
+	<string name="_adm_err_modules_module_was_modified"><![CDATA[Module was modified]]></string>
+	<string name="_adm_err_modules_pending_uninstall"><![CDATA[Module uninstall was postponed. Module will be uninstalled automatically after all its files are deleted.]]></string>
+	<string name="_adm_err_modules_pending_uninstall_already"><![CDATA[Module is pending uninstall already.]]></string>
+	<string name="_adm_err_modules_process_action_failed"><![CDATA[An error occurred. Contact with module's vendor]]></string>
+	<string name="_adm_err_modules_wrong_dependency_disable"><![CDATA[Failed to disable. The module has the following dependent modules. At least you need to disable them first.]]></string>
+	<string name="_adm_err_modules_wrong_dependency_install"><![CDATA[The following modules should be installed and activated first:]]></string>
+	<string name="_adm_err_modules_wrong_dependency_uninstall"><![CDATA[Failed to uninstall. The module has the following dependent modules. You need to uninstall them first.]]></string>
+	<string name="_adm_err_modules_wrong_mysql_query"><![CDATA[There are errors in the following MySQL queries:]]></string>
+	<string name="_adm_err_modules_wrong_mysql_query_msg"><![CDATA[Error: {0}]]></string>
+	<string name="_adm_err_modules_wrong_permissions_change"><![CDATA[Unable to change permissions automatically. You need to manually change them for the following files and folders and try again:]]></string>
+	<string name="_adm_err_modules_wrong_permissions_check"><![CDATA[You need to change permissions for the following files and folders:]]></string>
+	<string name="_adm_err_modules_wrong_permissions_msg"><![CDATA[{0} - {1}]]></string>
+	<string name="_adm_err_modules_wrong_version"><![CDATA[The module has incompatible version]]></string>
+	<string name="_adm_err_modules_wrong_version_script"><![CDATA[The module is not compatible with your version of UNA]]></string>
+	<string name="_adm_err_modules_wrong_version_script_update"><![CDATA[The new version of {0} module isn't compatible with your version of UNA. Please upgrade UNA first (Studio &gt; Dashboard &gt; Version) and then try to upgrade the module.]]></string>
+	<string name="_adm_err_oauth_cannot_get_token"><![CDATA[Cannot connect to <b>UNA</b>. Please try again later.]]></string>
+	<string name="_adm_err_oauth_cannot_read_answer"><![CDATA[Cannot get a valid answer from <b>UNA</b>. Please try again later.]]></string>
+	<string name="_adm_err_oauth_empty_key_secret"><![CDATA[You need to enter Key and Secret provided by <b>UNA</b> in Settings -> General.]]></string>
+	<string name="_adm_err_operation_failed"><![CDATA[Operation failed. Please report.]]></string>
+	<string name="_adm_form_btn_displays_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_form_btn_displays_edit"><![CDATA[Edit display]]></string>
+	<string name="_adm_form_btn_displays_save"><![CDATA[Save]]></string>
+	<string name="_adm_form_btn_field_add"><![CDATA[Add]]></string>
+	<string name="_adm_form_btn_field_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_form_btn_field_delete"><![CDATA[Delete field]]></string>
+	<string name="_adm_form_btn_field_edit"><![CDATA[Edit field]]></string>
+	<string name="_adm_form_btn_field_save"><![CDATA[Save]]></string>
+	<string name="_adm_form_btn_fields_create"><![CDATA[Add New Field]]></string>
+	<string name="_adm_form_btn_fields_visible"><![CDATA[Visible For]]></string>
+	<string name="_adm_form_btn_forms_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_form_btn_forms_edit"><![CDATA[Edit form]]></string>
+	<string name="_adm_form_btn_forms_save"><![CDATA[Save]]></string>
+        <string name="_adm_form_btn_labels_add"><![CDATA[Add]]></string>
+        <string name="_adm_form_btn_labels_back"><![CDATA[Back]]></string>
+        <string name="_adm_form_btn_labels_cancel"><![CDATA[Cancel]]></string>
+        <string name="_adm_form_btn_labels_submit"><![CDATA[Submit]]></string>
+	<string name="_adm_form_btn_pre_lists_add"><![CDATA[Add]]></string>
+	<string name="_adm_form_btn_pre_lists_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_form_btn_pre_lists_create"><![CDATA[Add New List]]></string>
+	<string name="_adm_form_btn_pre_lists_delete"><![CDATA[Delete List]]></string>
+	<string name="_adm_form_btn_pre_lists_edit"><![CDATA[Edit List]]></string>
+	<string name="_adm_form_btn_pre_lists_save"><![CDATA[Save]]></string>
+	<string name="_adm_form_btn_pre_values_add"><![CDATA[Add]]></string>
+	<string name="_adm_form_btn_pre_values_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_form_btn_pre_values_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_form_btn_pre_values_create"><![CDATA[Add New Item]]></string>
+	<string name="_adm_form_btn_pre_values_delete_item"><![CDATA[Delete Item]]></string>
+	<string name="_adm_form_btn_pre_values_edit_item"><![CDATA[Edit Item]]></string>
+	<string name="_adm_form_btn_search_forms_edit"><![CDATA[Edit search form]]></string>
+    <string name="_adm_form_btn_search_forms_fields_edit"><![CDATA[Edit search field]]></string>
+    <string name="_adm_form_btn_search_forms_fields_reset"><![CDATA[Reset]]></string>
+    <string name="_adm_form_btn_search_forms_save"><![CDATA[Save]]></string>
+    <string name="_adm_form_btn_search_forms_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_form_dsc_displays_title"><![CDATA[Name of the form display mode. Displayed in Studio only.]]></string>
+	<string name="_adm_form_dsc_field_attrs_max"><![CDATA[Enter numeric value]]></string>
+	<string name="_adm_form_dsc_field_attrs_min"><![CDATA[Enter numeric value]]></string>
+	<string name="_adm_form_dsc_field_attrs_src"><![CDATA[Enter correct image URL]]></string>
+	<string name="_adm_form_dsc_field_attrs_step"><![CDATA[Enter numeric value]]></string>
+	<string name="_adm_form_dsc_field_caption"><![CDATA[Item name displayed on site]]></string>
+	<string name="_adm_form_dsc_field_caption_block_header"><![CDATA[Title for the group of fields]]></string>
+	<string name="_adm_form_dsc_field_caption_system"><![CDATA[Field title, displayed in Studio only.]]></string>
+	<string name="_adm_form_dsc_field_checker_error_captcha"><![CDATA[Error message to display if text doesn't match with text on the image]]></string>
+	<string name="_adm_form_dsc_field_checker_params_preg"><![CDATA[Use standard <a href="http://en.wikipedia.org/wiki/Regular_expression" target="_blank">regular expression</a>. Example: #^[A-Za-z0-9]{3,16}$#]]></string>
+	<string name="_adm_form_dsc_field_collapsed"><![CDATA[Pack down the group of this field by default]]></string>
+	<string name="_adm_form_dsc_field_html"><![CDATA[Select type of HTML editor]]></string>
+	<string name="_adm_form_dsc_field_info"><![CDATA[Enter field description (optional)]]></string>
+	<string name="_adm_form_dsc_field_required"><![CDATA[Check it if the field should have value]]></string>
+	<string name="_adm_form_dsc_field_unique"><![CDATA[Check it if the field should have unique value]]></string>
+	<string name="_adm_form_dsc_field_value_button"><![CDATA[Enter button title here]]></string>
+	<string name="_adm_form_dsc_field_value_checkbox"><![CDATA[Send this data if checkbox is checked and form is submitted]]></string>
+	<string name="_adm_form_dsc_field_value_reset"><![CDATA[Button title (this button type is used to reset the form to its default state)]]></string>
+	<string name="_adm_form_dsc_field_value_submit"><![CDATA[Button title (this button type is used to send in the form data)]]></string>
+	<string name="_adm_form_dsc_field_visible_for_levels"><![CDATA[Select user levels that can see this menu item]]></string>
+	<string name="_adm_form_dsc_field_db_pass"><![CDATA[Select how field's data will be processed before saving in the database]]></string>
+	<string name="_adm_form_dsc_forms_title"><![CDATA[Name of the form. Displayed in Studio only.]]></string>
+	<string name="_adm_form_dsc_pre_lists_title"><![CDATA[List Name for Studio use only]]></string>
+	<string name="_adm_form_dsc_pre_values_empty"><![CDATA[You can use it for items like "Please select..." which can't be submitted.]]></string>
+	<string name="_adm_form_dsc_pre_values_lkey"><![CDATA[Item name displayed on site]]></string>
+	<string name="_adm_form_dsc_search_forms_fields_search_type"><![CDATA[The type of control element in search form]]></string>
+    <string name="_adm_form_dsc_search_forms_title"><![CDATA[Name of the search form. Displayed in Studio only.]]></string>
+	<string name="_adm_form_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_form_err_displays_edit"><![CDATA[Cannot update display]]></string>
+	<string name="_adm_form_err_displays_title"><![CDATA[Enter title, more than 3 characters]]></string>
+	<string name="_adm_form_err_field_add"><![CDATA[Cannot add new field]]></string>
+        <string name="_adm_form_err_field_add_already_exists"><![CDATA[Field with similar name already exists]]></string>
+	<string name="_adm_form_err_field_add_not_allowed"><![CDATA[Fields cannot be added in this form]]></string>
+	<string name="_adm_form_err_field_caption_system"><![CDATA[A name with at least 3 characters is required.]]></string>
+	<string name="_adm_form_err_field_checker_error"><![CDATA[You need to enter error message]]></string>
+	<string name="_adm_form_err_field_checker_func"><![CDATA[Check Function should be selected]]></string>
+	<string name="_adm_form_err_field_checker_params_length_max"><![CDATA[Enter Max Value, non-zero integer number]]></string>
+	<string name="_adm_form_err_field_checker_params_length_min"><![CDATA[Enter Min Value, non-zero integer number]]></string>
+	<string name="_adm_form_err_field_checker_params_preg"><![CDATA[Enter valid regular expression]]></string>
+	<string name="_adm_form_err_field_edit"><![CDATA[Cannot update field]]></string>
+	<string name="_adm_form_err_field_show_to"><![CDATA[Cannot update field]]></string>
+	<string name="_adm_form_err_field_value_doublerange"><![CDATA[Default value should be empty or looks like 12-23]]></string>
+	<string name="_adm_form_err_field_value_number"><![CDATA[Use numeric characters only]]></string>
+	<string name="_adm_form_err_field_values"><![CDATA[You need to select a data set from the list.]]></string>
+	<string name="_adm_form_err_forms_edit"><![CDATA[Cannot update form]]></string>
+	<string name="_adm_form_err_forms_title"><![CDATA[Enter name, more than 3 characters]]></string>
+        <string name="_adm_form_err_labels_add"><![CDATA[Cannot add label]]></string>
+        <string name="_adm_form_err_labels_edit"><![CDATA[Cannot update label]]></string>
+        <string name="_adm_form_err_labels_value"><![CDATA[Label should have unique non-empty value.]]></string>
+	<string name="_adm_form_err_missing_params"><![CDATA[The required parameters are missing.]]></string>
+	<string name="_adm_form_err_pre_lists_create"><![CDATA[Cannot add list]]></string>
+	<string name="_adm_form_err_pre_lists_edit"><![CDATA[Cannot update list]]></string>
+	<string name="_adm_form_err_pre_lists_title"><![CDATA[Enter title, more than 3 characters]]></string>
+	<string name="_adm_form_err_pre_values_create"><![CDATA[Cannot add item]]></string>
+	<string name="_adm_form_err_pre_values_create_forbidden"><![CDATA[This list is already used. It's impossible to add non-numeric, or less than 1, or more than {0} values in it.]]></string>
+	<string name="_adm_form_err_pre_values_delete"><![CDATA[Cannot delete item]]></string>
+	<string name="_adm_form_err_pre_values_edit"><![CDATA[Cannot update item]]></string>
+	<string name="_adm_form_err_pre_values_lkey"><![CDATA[Enter title, more than one character]]></string>
+	<string name="_adm_form_err_search_forms_essential"><![CDATA[The field is essential. Please fill in.]]></string>
+    <string name="_adm_form_err_search_forms_fields_edit"><![CDATA[Cannot update the search form field.]]></string>
+    <string name="_adm_from_err_search_forms_fields_reset"><![CDATA[Cannot reset the search form.]]></string>
+    <string name="_adm_form_err_search_forms_edit"><![CDATA[Cannot update the selected search form.]]></string>
+    <string name="_adm_form_err_search_forms_title"><![CDATA[Enter name, more than 3 characters]]></string>
+	<string name="_adm_form_txt_all_modules"><![CDATA[All Modules]]></string>
+	<string name="_adm_form_txt_confirm_delete"><![CDATA[Are you sure you want to delete this field? It will be deleted from all Displays! You may just turn it off instead.]]></string>
+	<string name="_adm_form_txt_displays_edit_popup"><![CDATA[Edit "{0}" Display]]></string>
+	<string name="_adm_form_txt_displays_gl_fields"><![CDATA[Fields]]></string>
+	<string name="_adm_form_txt_displays_gl_form"><![CDATA[Form]]></string>
+	<string name="_adm_form_txt_displays_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_form_txt_displays_gl_title"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_displays_manage_fields"><![CDATA[Manage fields]]></string>
+	<string name="_adm_form_txt_displays_title"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_field_add_popup"><![CDATA[Add New Field]]></string>
+	<string name="_adm_form_txt_field_attrs_max"><![CDATA[Max Value]]></string>
+	<string name="_adm_form_txt_field_attrs_min"><![CDATA[Min Value]]></string>
+	<string name="_adm_form_txt_field_attrs_src"><![CDATA[Image Source]]></string>
+	<string name="_adm_form_txt_field_attrs_step"><![CDATA[Step]]></string>
+	<string name="_adm_form_txt_field_caption"><![CDATA[Title]]></string>
+	<string name="_adm_form_txt_field_caption_system"><![CDATA[System Title]]></string>
+	<string name="_adm_form_txt_field_checked"><![CDATA[Checked by default]]></string>
+	<string name="_adm_form_txt_field_checked_switcher"><![CDATA[Enabled by default]]></string>
+	<string name="_adm_form_txt_field_checker_avail"><![CDATA[Data Availability (something must be entered) ]]></string>
+	<string name="_adm_form_txt_field_checker_captcha"><![CDATA[Captcha (check for correct security image text input)]]></string>
+        <string name="_adm_form_txt_field_checker_custom"><![CDATA[Custom check]]></string>
+	<string name="_adm_form_txt_field_checker_date"><![CDATA[Date (check for correct date format)]]></string>
+        <string name="_adm_form_txt_field_checker_date_range"><![CDATA[Age's range]]></string>
+	<string name="_adm_form_txt_field_checker_date_time"><![CDATA[Date and Time (check for correct date and time format)]]></string>
+	<string name="_adm_form_txt_field_checker_email"><![CDATA[E-mail (correct email address format)]]></string>
+	<string name="_adm_form_txt_field_checker_empty"><![CDATA[Select...]]></string>
+	<string name="_adm_form_txt_field_checker_error"><![CDATA[Error message if check failed]]></string>
+	<string name="_adm_form_txt_field_checker_func"><![CDATA[Check for]]></string>
+        <string name="_adm_form_txt_field_checker_func_info_custom"><![CDATA[Note. It's not recommended to edit this field without absolute necessity.]]></string>
+	<string name="_adm_form_txt_field_checker_length"><![CDATA[Data Length (limit amount of characters)]]></string>
+	<string name="_adm_form_txt_field_checker_no_spam"><![CDATA[Spam-Free (check if input is SPAM-free)]]></string>
+	<string name="_adm_form_txt_field_checker_params_length_max"><![CDATA[Max Value]]></string>
+	<string name="_adm_form_txt_field_checker_params_length_min"><![CDATA[Min Value]]></string>
+	<string name="_adm_form_txt_field_checker_params_required"><![CDATA[Required]]></string>
+	<string name="_adm_form_txt_field_checker_params_preg"><![CDATA[Expression]]></string>
+	<string name="_adm_form_txt_field_checker_preg"><![CDATA[Regular Expression (something specific must be entered)]]></string>
+	<string name="_adm_form_txt_field_collapsed"><![CDATA[Collapsed]]></string>
+	<string name="_adm_form_txt_field_edit_popup"><![CDATA[Edit "{0}" Field]]></string>
+	<string name="_adm_form_txt_field_html"><![CDATA[HTML Editor]]></string>
+	<string name="_adm_form_txt_field_html_full"><![CDATA[Full]]></string>
+	<string name="_adm_form_txt_field_html_mini"><![CDATA[Mini]]></string>
+	<string name="_adm_form_txt_field_html_none"><![CDATA[No Editor]]></string>
+	<string name="_adm_form_txt_field_html_standard"><![CDATA[Standard]]></string>
+	<string name="_adm_form_txt_field_info"><![CDATA[Description]]></string>
+	<string name="_adm_form_txt_field_module"><![CDATA[Module]]></string>
+	<string name="_adm_form_txt_field_name"><![CDATA[Name]]></string>
+	<string name="_adm_form_txt_field_object"><![CDATA[Form]]></string>
+	<string name="_adm_form_txt_field_required"><![CDATA[Mandatory]]></string>
+	<string name="_adm_form_txt_field_show_to_popup"><![CDATA[Show "{0}" form field to: ]]></string>
+        <string name="_adm_form_txt_field_type_block_end"><![CDATA[block end]]></string>
+	<string name="_adm_form_txt_field_type_block_header"><![CDATA[block header]]></string>
+	<string name="_adm_form_txt_field_type_button"><![CDATA[button]]></string>
+	<string name="_adm_form_txt_field_type_captcha"><![CDATA[captcha]]></string>
+	<string name="_adm_form_txt_field_type_checkbox"><![CDATA[checkbox]]></string>
+	<string name="_adm_form_txt_field_type_checkbox_set"><![CDATA[checkbox set]]></string>
+	<string name="_adm_form_txt_field_type_custom"><![CDATA[custom]]></string>
+	<string name="_adm_form_txt_field_type_datepicker"><![CDATA[date]]></string>
+	<string name="_adm_form_txt_field_type_datepicker_range"><![CDATA[date range]]></string>
+	<string name="_adm_form_txt_field_type_datepicker_range_age"><![CDATA[age range]]></string>
+	<string name="_adm_form_txt_field_type_datetime"><![CDATA[date time]]></string>
+	<string name="_adm_form_txt_field_type_datetime_range"><![CDATA[date time range]]></string>
+	<string name="_adm_form_txt_field_type_datetime_range_age"><![CDATA[age range]]></string>
+	<string name="_adm_form_txt_field_type_display"><![CDATA[Type]]></string>
+	<string name="_adm_form_txt_field_type_doublerange"><![CDATA[double range slider]]></string>
+	<string name="_adm_form_txt_field_type_file"><![CDATA[file]]></string>
+	<string name="_adm_form_txt_field_type_files"><![CDATA[files]]></string>
+	<string name="_adm_form_txt_field_type_hidden"><![CDATA[hidden]]></string>
+	<string name="_adm_form_txt_field_type_image"><![CDATA[image]]></string>
+	<string name="_adm_form_txt_field_type_input_set"><![CDATA[input set]]></string>
+	<string name="_adm_form_txt_field_type_location"><![CDATA[location]]></string>
+	<string name="_adm_form_txt_field_type_number"><![CDATA[number]]></string>
+	<string name="_adm_form_txt_field_type_password"><![CDATA[password]]></string>
+	<string name="_adm_form_txt_field_type_radio_set"><![CDATA[radio set]]></string>
+	<string name="_adm_form_txt_field_type_reset"><![CDATA[reset]]></string>
+	<string name="_adm_form_txt_field_type_select"><![CDATA[select]]></string>
+	<string name="_adm_form_txt_field_type_select_multiple"><![CDATA[select (multiple)]]></string>
+	<string name="_adm_form_txt_field_type_slider"><![CDATA[slider]]></string>
+	<string name="_adm_form_txt_field_type_submit"><![CDATA[submit]]></string>
+	<string name="_adm_form_txt_field_type_switcher"><![CDATA[switcher]]></string>
+	<string name="_adm_form_txt_field_type_text"><![CDATA[text]]></string>
+	<string name="_adm_form_txt_field_type_text_auto"><![CDATA[auto text]]></string>
+	<string name="_adm_form_txt_field_type_textarea"><![CDATA[textarea]]></string>
+	<string name="_adm_form_txt_field_type_value"><![CDATA[info]]></string>
+	<string name="_adm_form_txt_field_unique"><![CDATA[Unique]]></string>
+	<string name="_adm_form_txt_field_value_button"><![CDATA[Title]]></string>
+	<string name="_adm_form_txt_field_value_checkbox"><![CDATA[Value]]></string>
+	<string name="_adm_form_txt_field_value_custom_text"><![CDATA[Custom text]]></string>
+	<string name="_adm_form_txt_field_value_default"><![CDATA[Default value]]></string>
+	<string name="_adm_form_txt_field_value_files"><![CDATA[Enabled uploaders]]></string>
+	<string name="_adm_form_txt_field_value_select_value"><![CDATA[Select value...]]></string>
+	<string name="_adm_form_txt_field_values"><![CDATA[Values]]></string>
+	<string name="_adm_form_txt_field_values_manage"><![CDATA[Manage values]]></string>
+	<string name="_adm_form_txt_field_values_select_list"><![CDATA[Select list...]]></string>
+	<string name="_adm_form_txt_field_visible_for"><![CDATA[Visible For]]></string>
+	<string name="_adm_form_txt_field_visible_for_all"><![CDATA[Anyone]]></string>
+	<string name="_adm_form_txt_field_visible_for_levels"><![CDATA[Select Levels]]></string>
+	<string name="_adm_form_txt_field_visible_for_selected"><![CDATA[Selected levels]]></string>
+	<string name="_adm_form_txt_field_db_pass"><![CDATA[Process data as]]></string>
+	<string name="_adm_form_txt_field_db_pass_date"><![CDATA[Date]]></string>
+        <string name="_adm_form_txt_field_db_pass_date_ts"><![CDATA[Date as Unix Timestamp]]></string>
+        <string name="_adm_form_txt_field_db_pass_date_utc"><![CDATA[UTC Date as Unix Timestamp]]></string>
+	<string name="_adm_form_txt_field_db_pass_date_time"><![CDATA[Date/time]]></string>
+	<string name="_adm_form_txt_field_db_pass_date_time_ts"><![CDATA[Date/time as Unix Timestamp]]></string>
+	<string name="_adm_form_txt_field_db_pass_date_time_utc"><![CDATA[UTC Date/time as Unix Timestamp]]></string>
+        <string name="_adm_form_txt_field_db_pass_select_value"><![CDATA[Select value...]]></string>
+	<string name="_adm_form_txt_fields_caption_system"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_fields_manage_visibility"><![CDATA[Manage visibility settings]]></string>
+	<string name="_adm_form_txt_fields_module"><![CDATA[Module]]></string>
+	<string name="_adm_form_txt_fields_type"><![CDATA[Type]]></string>
+	<string name="_adm_form_txt_fields_visible"><![CDATA[Visible For]]></string>
+	<string name="_adm_form_txt_forms_edit_popup"><![CDATA[Edit "{0}" Form]]></string>
+	<string name="_adm_form_txt_forms_gl_displays"><![CDATA[Displays]]></string>
+	<string name="_adm_form_txt_forms_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_form_txt_forms_gl_title"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_forms_manage_displays"><![CDATA[Manage displays]]></string>
+	<string name="_adm_form_txt_forms_n_displays"><![CDATA[{0} displays]]></string>
+	<string name="_adm_form_txt_forms_n_fields"><![CDATA[{0} fields]]></string>
+	<string name="_adm_form_txt_forms_title"><![CDATA[System Name]]></string>
+        <string name="_adm_form_txt_labels_add_popup"><![CDATA[Add label]]></string>
+        <string name="_adm_form_txt_labels_edit_popup"><![CDATA[Edit "{0}" label]]></string>
+        <string name="_adm_form_txt_labels_items"><![CDATA[Items]]></string>
+        <string name="_adm_form_txt_labels_manage_items"><![CDATA[Manage child labels]]></string>
+        <string name="_adm_form_txt_labels_n_items"><![CDATA[{0} items]]></string>
+        <string name="_adm_form_txt_labels_parent"><![CDATA[Parent]]></string>
+        <string name="_adm_form_txt_labels_parent_empty"><![CDATA[No Parent]]></string>
+        <string name="_adm_form_txt_labels_grandparent_label"><![CDATA[Grandparent Label]]></string>
+        <string name="_adm_form_txt_labels_parent_label"><![CDATA[Parent Label]]></string>
+        <string name="_adm_form_txt_labels_sibling_labels"><![CDATA[Sibling Labels]]></string>
+        <string name="_adm_form_txt_labels_value"><![CDATA[Label]]></string>
+	<string name="_adm_form_txt_pre_lists_country"><![CDATA[Country]]></string>
+	<string name="_adm_form_txt_pre_lists_create_popup"><![CDATA[Add New List]]></string>
+	<string name="_adm_form_txt_pre_lists_edit_popup"><![CDATA[Edit "{0}" List]]></string>
+	<string name="_adm_form_txt_pre_lists_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_form_txt_pre_lists_gl_title"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_pre_lists_gl_use_for_sets"><![CDATA[Use For Sets]]></string>
+	<string name="_adm_form_txt_pre_lists_gl_values"><![CDATA[Values]]></string>
+	<string name="_adm_form_txt_pre_lists_language"><![CDATA[Language]]></string>
+	<string name="_adm_form_txt_pre_lists_manage_values"><![CDATA[Manage values]]></string>
+	<string name="_adm_form_txt_pre_lists_n_values"><![CDATA[{0} items]]></string>
+	<string name="_adm_form_txt_pre_lists_no"><![CDATA[No]]></string>
+	<string name="_adm_form_txt_pre_lists_sex"><![CDATA[Sex]]></string>
+	<string name="_adm_form_txt_pre_lists_title"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_pre_lists_yes"><![CDATA[Yes]]></string>
+	<string name="_adm_form_txt_pre_values_create_popup"><![CDATA[Add New Item]]></string>
+	<string name="_adm_form_txt_pre_values_edit_popup"><![CDATA[Edit "{0}" Item]]></string>
+	<string name="_adm_form_txt_pre_values_empty"><![CDATA[Use empty value for this item]]></string>
+	<string name="_adm_form_txt_pre_values_gl_lkey"><![CDATA[Title]]></string>
+	<string name="_adm_form_txt_pre_values_lkey"><![CDATA[Title]]></string>
+    <string name="_adm_form_txt_search_forms_edit_popup"><![CDATA[Edit "{0}" Search Form]]></string>
+    <string name="_adm_form_txt_search_forms_fields"><![CDATA[Fields]]></string>
+    <string name="_adm_form_txt_search_forms_fields_type"><![CDATA[Type]]></string>
+    <string name="_adm_form_txt_search_forms_fields_caption"><![CDATA[Caption]]></string>
+    <string name="_adm_form_txt_search_forms_fields_info"><![CDATA[Description]]></string>
+    <string name="_adm_form_txt_search_forms_fields_search_type"><![CDATA[Search Type]]></string>
+    <string name="_adm_form_txt_search_forms_fields_select_object"><![CDATA[Select Form...]]></string>
+    <string name="_adm_form_txt_search_forms_fields_edit_popup"><![CDATA[Edit "{0}" Search Field]]></string>
+    <string name="_adm_form_txt_search_forms_manage_fields"><![CDATA[Manage fields]]></string>
+    <string name="_adm_form_txt_search_forms_module"><![CDATA[Module]]></string>
+    <string name="_adm_form_txt_search_forms_n_fields"><![CDATA[{0} fields]]></string>
+    <string name="_adm_form_txt_search_forms_title"><![CDATA[System Name]]></string>
+	<string name="_adm_form_txt_select_display"><![CDATA[Select Display...]]></string>
+	<string name="_adm_form_txt_select_form"><![CDATA[Select Form...]]></string>
+	<string name="_adm_form_txt_select_list"><![CDATA[Select List...]]></string>
+	<string name="_adm_from_err_field_delete"><![CDATA[Cannot delete field]]></string>
+	<string name="_adm_from_err_pre_lists_delete"><![CDATA[Cannot delete list]]></string>
+	<string name="_adm_ipbl_Date_of_finish"><![CDATA[Expiration date]]></string>
+	<string name="_adm_ipbl_IP_Role"><![CDATA[IP Role]]></string>
+	<string name="_adm_ipbl_Stored_members_caption"><![CDATA[Stored Logged Members IPs]]></string>
+	<string name="_adm_ipbl_Type0_desc"><![CDATA[IP List Type is 0 : disabled]]></string>
+	<string name="_adm_ipbl_Type1_desc"><![CDATA[IP List Type is 1 : All IPs allowed except listed]]></string>
+	<string name="_adm_ipbl_Type2_desc"><![CDATA[IP List Type is 2 : All IPs blocked except listed]]></string>
+	<string name="_adm_ipbl_sample"><![CDATA[sample]]></string>
+    <string name="_adm_lang_cnf_uninstall"><![CDATA[<h3>Uninstall "{0}" language?</h3><p>Uninstalling "{0}" language will also delete all of its data. Do you want to continue?</p>]]></string>
+	<string name="_adm_lmi_cpt_actions"><![CDATA[Actions]]></string>
+	<string name="_adm_lmi_cpt_categories"><![CDATA[Categories]]></string>
+	<string name="_adm_lmi_cpt_checkout"><![CDATA[Checkout {checkout_counter}]]></string>
+	<string name="_adm_lmi_cpt_cover"><![CDATA[Cover]]></string>
+	<string name="_adm_lmi_cpt_search"><![CDATA[Search]]></string>
+	<string name="_adm_lmi_cpt_search_forms"><![CDATA[Search Forms]]></string>
+	<string name="_adm_lmi_cpt_search_fields"><![CDATA[Search Fields]]></string>
+	<string name="_adm_lmi_cpt_splash"><![CDATA[Splash]]></string>
+	<string name="_adm_lmi_cpt_displays"><![CDATA[Displays]]></string>
+	<string name="_adm_lmi_cpt_downloaded"><![CDATA[Downloaded]]></string>
+	<string name="_adm_lmi_cpt_etemplates"><![CDATA[Emails]]></string>
+	<string name="_adm_lmi_cpt_etemplates_hf"><![CDATA[Email Template]]></string>
+	<string name="_adm_lmi_cpt_featured"><![CDATA[Featured]]></string>
+	<string name="_adm_lmi_cpt_fields"><![CDATA[Fields]]></string>
+	<string name="_adm_lmi_cpt_files"><![CDATA[Files]]></string>
+	<string name="_adm_lmi_cpt_forms"><![CDATA[Forms]]></string>
+	<string name="_adm_lmi_cpt_general"><![CDATA[General]]></string>
+	<string name="_adm_lmi_cpt_goodies"><![CDATA[Storefront]]></string>
+	<string name="_adm_lmi_cpt_icon"><![CDATA[Site Icon]]></string>
+	<string name="_adm_lmi_cpt_injections"><![CDATA[Injections]]></string>
+	<string name="_adm_lmi_cpt_images"><![CDATA[Images]]></string>
+	<string name="_adm_lmi_cpt_items"><![CDATA[Items]]></string>
+	<string name="_adm_lmi_cpt_keys"><![CDATA[Keys]]></string>
+        <string name="_adm_lmi_cpt_labels"><![CDATA[Labels]]></string>
+	<string name="_adm_lmi_cpt_latest"><![CDATA[Latest]]></string>
+	<string name="_adm_lmi_cpt_levels"><![CDATA[Levels]]></string>
+	<string name="_adm_lmi_cpt_logo"><![CDATA[Logo]]></string>
+	<string name="_adm_lmi_cpt_menus"><![CDATA[Menus]]></string>
+	<string name="_adm_lmi_cpt_pre_lists"><![CDATA[Data Lists]]></string>
+	<string name="_adm_lmi_cpt_pre_values"><![CDATA[Data Items]]></string>
+	<string name="_adm_lmi_cpt_popular"><![CDATA[Popular]]></string>
+	<string name="_adm_lmi_cpt_purchases"><![CDATA[Purchases]]></string>
+	<string name="_adm_lmi_cpt_sets"><![CDATA[Sets]]></string>
+	<string name="_adm_lmi_cpt_settings"><![CDATA[Settings]]></string>
+	<string name="_adm_lmi_cpt_updates"><![CDATA[Updates]]></string>
+	<string name="_adm_mobile_page_homepage"><![CDATA[Homepage]]></string>
+	<string name="_adm_mobile_page_profile"><![CDATA[Profile]]></string>
+    <string name="_adm_mod_cnf_uninstall"><![CDATA[<h3>Uninstall "{0}" module?</h3><p>Uninstalling "{0}" module will also delete all of its data. Do you want to continue?</p>]]></string>
+	<string name="_adm_mod_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+    <string name="_adm_mod_err_only_admin_can_perform_operations_with_modules"><![CDATA[Only admin can perform operations with modules]]></string>
+	<string name="_adm_mod_err_process_operation_failed"><![CDATA[Cannot {0} module from "{1}" directory]]></string>
+	<string name="_adm_mod_msg_process_operation_scheduled"><![CDATA[Operation was scheduled and will be performed in a few minutes. Please wait.]]></string>	
+	<string name="_adm_msg_modules_success_added_to_cart"><![CDATA[The product was successfully added to shopping cart.]]></string>
+	<string name="_adm_msg_modules_success_checkouted"><![CDATA[The payment was successfully accepted and should be processed automatically in a few minutes. Then the purchased product(s) will be available in Apps -> Purchases. If it doesn't happen for some reason, please contact product's vendor with your payment details.]]></string>
+	<string name="_adm_msg_modules_success_delete"><![CDATA[The package was deleted successfully]]></string>
+	<string name="_adm_msg_modules_success_disable"><![CDATA[The package was disabled successfully]]></string>
+	<string name="_adm_msg_modules_success_enable"><![CDATA[The package was enabled successfully]]></string>
+	<string name="_adm_msg_modules_success_install"><![CDATA[The package was installed successfully]]></string>
+	<string name="_adm_msg_modules_success_uninstall"><![CDATA[The package was uninstalled successfully]]></string>
+	<string name="_adm_msg_oauth_need_authorize"><![CDATA[You need to to login into your <b>UNA</b> account to get data. Click <a href="{0}">here</a> to login.]]></string>
+        <string name="_adm_msg_oauth_non_owner_logged"><![CDATA[WARNING: You are logged in to an <a href="{0}">UNA.IO</a> account which is different from the account that generated UNA Key & Secret for your domain.]]></string>
+	<string name="_adm_nav_btn_current_icon_image_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_nav_btn_items_add"><![CDATA[Add]]></string>
+	<string name="_adm_nav_btn_items_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_nav_btn_items_delete"><![CDATA[Delete item]]></string>
+	<string name="_adm_nav_btn_items_done"><![CDATA[Done]]></string>
+	<string name="_adm_nav_btn_items_edit"><![CDATA[Edit item]]></string>
+	<string name="_adm_nav_btn_items_gl_create"><![CDATA[Add New Item]]></string>
+	<string name="_adm_nav_btn_items_gl_import"><![CDATA[Import Items]]></string>
+	<string name="_adm_nav_btn_items_gl_visible"><![CDATA[Visible For]]></string>
+	<string name="_adm_nav_btn_items_import"><![CDATA[Import item]]></string>
+	<string name="_adm_nav_btn_items_save"><![CDATA[Save]]></string>
+	<string name="_adm_nav_btn_menus_add"><![CDATA[Add]]></string>
+	<string name="_adm_nav_btn_menus_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_nav_btn_menus_create"><![CDATA[Add New Menu]]></string>
+	<string name="_adm_nav_btn_menus_delete"><![CDATA[Delete Menu]]></string>
+	<string name="_adm_nav_btn_menus_edit"><![CDATA[Edit Menu]]></string>
+	<string name="_adm_nav_btn_menus_save"><![CDATA[Save]]></string>
+	<string name="_adm_nav_btn_sets_add"><![CDATA[Add]]></string>
+	<string name="_adm_nav_btn_sets_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_nav_btn_sets_create"><![CDATA[Add New Set]]></string>
+	<string name="_adm_nav_btn_sets_delete"><![CDATA[Delete set]]></string>
+	<string name="_adm_nav_btn_sets_edit"><![CDATA[Edit set]]></string>
+	<string name="_adm_nav_dsc_items_icon"><![CDATA[You may use font icon here]]></string>
+	<string name="_adm_nav_dsc_items_icon_image"><![CDATA[or upload a small image to be displayed near the link.]]></string>
+	<string name="_adm_nav_dsc_items_icon_image_current"><![CDATA[No icon uploaded. Text is used in menu item.]]></string>
+	<string name="_adm_nav_dsc_items_link"><![CDATA[Enter the link URL]]></string>
+	<string name="_adm_nav_dsc_items_onclick"><![CDATA[Enter a correct JavaScript code for the link]]></string>
+	<string name="_adm_nav_dsc_items_submenu"><![CDATA[Select if you want the link to have a submenu.]]></string>
+	<string name="_adm_nav_dsc_items_target"><![CDATA[Select if you want the link to open as a new page or within current page.]]></string>
+	<string name="_adm_nav_dsc_items_title"><![CDATA[Link name displayed in site menus. Use at least 3 characters.]]></string>
+	<string name="_adm_nav_dsc_items_title_system"><![CDATA[Item name, displayed in Studio only.]]></string>
+	<string name="_adm_nav_dsc_items_visible_for_levels"><![CDATA[Select user levels that can see this menu item]]></string>
+	<string name="_adm_nav_dsc_menus_set_name"><![CDATA[Assign a Set of menu Items]]></string>
+	<string name="_adm_nav_dsc_menus_set_title"><![CDATA[Descriptive name displayed in Studio only. Use at least 3 characters.]]></string>
+	<string name="_adm_nav_dsc_menus_style"><![CDATA[Select presentation style - the way this menu will be displayed on site]]></string>
+	<string name="_adm_nav_dsc_menus_title"><![CDATA[Descriptive name displayed in Studio only. Use at least 3 characters.]]></string>
+	<string name="_adm_nav_dsc_sets_title"><![CDATA[Descriptive name displayed in Studio only. Use at least 3 characters.]]></string>
+	<string name="_adm_nav_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_nav_err_items_create"><![CDATA[Cannot create item]]></string>
+	<string name="_adm_nav_err_items_delete"><![CDATA[Cannot delete item]]></string>
+	<string name="_adm_nav_err_items_edit"><![CDATA[Cannot update item]]></string>
+	<string name="_adm_nav_err_items_icon"><![CDATA[You need to enter font icon name here.]]></string>
+	<string name="_adm_nav_err_items_icon_image"><![CDATA[Cannot process image: ]]></string>
+	<string name="_adm_nav_err_items_icon_image_remove"><![CDATA[Cannot remove icon image: ]]></string>
+	<string name="_adm_nav_err_items_import"><![CDATA[Cannot import item(s)]]></string>
+	<string name="_adm_nav_err_items_link"><![CDATA[You need to enter item URL]]></string>
+	<string name="_adm_nav_err_items_onclick"><![CDATA[You need to enter item OnClick]]></string>
+	<string name="_adm_nav_err_items_show_to"><![CDATA[Cannot update item]]></string>
+	<string name="_adm_nav_err_items_title_system"><![CDATA[A name with at least 3 characters is required.]]></string>
+	<string name="_adm_nav_err_menus_create"><![CDATA[Cannot create menu]]></string>
+	<string name="_adm_nav_err_menus_delete"><![CDATA[Cannot delete menu]]></string>
+	<string name="_adm_nav_err_menus_edit"><![CDATA[Cannot update menu]]></string>
+	<string name="_adm_nav_err_menus_set_name"><![CDATA[Please, assign a Set.]]></string>
+	<string name="_adm_nav_err_menus_set_title"><![CDATA[A unique title with at least 3 characters is required.]]></string>
+	<string name="_adm_nav_err_menus_style"><![CDATA[Please, select a presentation style.]]></string>
+	<string name="_adm_nav_err_menus_title"><![CDATA[A title with at least 3 characters is required.]]></string>
+	<string name="_adm_nav_err_missing_params"><![CDATA[The required parameters are missing.]]></string>
+	<string name="_adm_nav_err_sets_create"><![CDATA[Cannot create set]]></string>
+	<string name="_adm_nav_err_sets_delete"><![CDATA[Cannot delete set]]></string>
+	<string name="_adm_nav_err_sets_delete_used"><![CDATA[Set can't be deleted because it is in use]]></string>
+	<string name="_adm_nav_err_sets_edit"><![CDATA[Cannot update set]]></string>
+	<string name="_adm_nav_err_sets_title"><![CDATA[A title with at least 3 characters is required.]]></string>
+	<string name="_adm_nav_txt_all_modules"><![CDATA[All Modules]]></string>
+	<string name="_adm_nav_txt_items_create_popup"><![CDATA[Add New Item]]></string>
+	<string name="_adm_nav_txt_items_edit_popup"><![CDATA[Edit {0} Item]]></string>
+	<string name="_adm_nav_txt_items_gl_icon"><![CDATA[Icon]]></string>
+	<string name="_adm_nav_txt_items_gl_link"><![CDATA[URL]]></string>
+	<string name="_adm_nav_txt_items_gl_link_custom"><![CDATA[Custom Action]]></string>
+	<string name="_adm_nav_txt_items_gl_link_menu"><![CDATA[Menu:]]></string>
+	<string name="_adm_nav_txt_items_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_nav_txt_items_gl_title_system"><![CDATA[System Name]]></string>
+	<string name="_adm_nav_txt_items_gl_visible"><![CDATA[Visible For]]></string>
+	<string name="_adm_nav_txt_items_icon"><![CDATA[Icon]]></string>
+	<string name="_adm_nav_txt_items_icon_image"><![CDATA[]]></string>
+	<string name="_adm_nav_txt_items_icon_image_new"><![CDATA[]]></string>
+	<string name="_adm_nav_txt_items_icon_image_old"><![CDATA[Current Icon]]></string>
+	<string name="_adm_nav_txt_items_import_popup"><![CDATA[Import Items]]></string>
+	<string name="_adm_nav_txt_items_link"><![CDATA[URL]]></string>
+	<string name="_adm_nav_txt_items_onclick"><![CDATA[OnClick]]></string>
+	<string name="_adm_nav_txt_items_show_to_popup"><![CDATA[Show "{0}" menu item to: ]]></string>
+	<string name="_adm_nav_txt_items_submenu"><![CDATA[Submenu]]></string>
+	<string name="_adm_nav_txt_items_submenu_empty"><![CDATA[No Submenu]]></string>
+	<string name="_adm_nav_txt_items_submenu_popup"><![CDATA[Show submenu in popup]]></string>
+	<string name="_adm_nav_txt_items_target"><![CDATA[Target]]></string>
+	<string name="_adm_nav_txt_items_target_blank"><![CDATA[New Page]]></string>
+	<string name="_adm_nav_txt_items_target_self"><![CDATA[Same Page]]></string>
+	<string name="_adm_nav_txt_items_title"><![CDATA[Title]]></string>
+	<string name="_adm_nav_txt_items_title_system"><![CDATA[System Name]]></string>
+	<string name="_adm_nav_txt_items_visible_for"><![CDATA[Visible For]]></string>
+	<string name="_adm_nav_txt_items_visible_for_all"><![CDATA[Anyone]]></string>
+	<string name="_adm_nav_txt_items_visible_for_levels"><![CDATA[Select Levels]]></string>
+	<string name="_adm_nav_txt_items_visible_for_selected"><![CDATA[Selected levels]]></string>
+	<string name="_adm_nav_txt_manage_items"><![CDATA[Manage items]]></string>
+	<string name="_adm_nav_txt_manage_visibility"><![CDATA[Manage visibility settings]]></string>
+	<string name="_adm_nav_txt_menus_create_popup"><![CDATA[Add New Menu]]></string>
+	<string name="_adm_nav_txt_menus_edit_popup"><![CDATA[Edit "{0}" Menu]]></string>
+	<string name="_adm_nav_txt_menus_gl_items"><![CDATA[Items]]></string>
+	<string name="_adm_nav_txt_menus_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_nav_txt_menus_gl_set_title"><![CDATA[Set]]></string>
+	<string name="_adm_nav_txt_menus_gl_template_title"><![CDATA[Style]]></string>
+	<string name="_adm_nav_txt_menus_gl_title"><![CDATA[System Name]]></string>
+	<string name="_adm_nav_txt_menus_set_name"><![CDATA[Set]]></string>
+	<string name="_adm_nav_txt_menus_set_name_new"><![CDATA[Create New]]></string>
+	<string name="_adm_nav_txt_menus_set_name_select"><![CDATA[Select Set...]]></string>
+	<string name="_adm_nav_txt_menus_set_title"><![CDATA[Set Title]]></string>
+	<string name="_adm_nav_txt_menus_style"><![CDATA[Style]]></string>
+	<string name="_adm_nav_txt_menus_style_select"><![CDATA[Select Style...]]></string>
+	<string name="_adm_nav_txt_menus_title"><![CDATA[System Name]]></string>
+	<string name="_adm_nav_txt_n_items"><![CDATA[{0} items]]></string>
+	<string name="_adm_nav_txt_select_set"><![CDATA[Select Set...]]></string>
+	<string name="_adm_nav_txt_sets_create_popup"><![CDATA[Add New Set]]></string>
+	<string name="_adm_nav_txt_sets_edit_popup"><![CDATA[Edit "{0}" Set]]></string>
+	<string name="_adm_nav_txt_sets_gl_items"><![CDATA[Items]]></string>
+	<string name="_adm_nav_txt_sets_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_nav_txt_sets_gl_title"><![CDATA[System Name]]></string>
+	<string name="_adm_nav_txt_sets_title"><![CDATA[System Name]]></string>
+        <string name="_adm_nav_txt_block_hidden_on"><![CDATA[Hidden on]]></string>
+        <string name="_adm_nav_txt_block_hidden_on_phone"><![CDATA[phone]]></string>
+        <string name="_adm_nav_txt_block_hidden_on_tablet"><![CDATA[tablet]]></string>
+        <string name="_adm_nav_txt_block_hidden_on_desktop"><![CDATA[desktop]]></string>
+        <string name="_adm_nav_txt_block_hidden_on_mobile"><![CDATA[mobile app]]></string>
+	<string name="_adm_page_cpt_builder_forms"><![CDATA[Forms]]></string>
+	<string name="_adm_page_cpt_builder_menus"><![CDATA[Navigation]]></string>
+	<string name="_adm_page_cpt_builder_mobile"><![CDATA[Mobile Builder]]></string>
+	<string name="_adm_page_cpt_builder_pages"><![CDATA[Pages]]></string>
+	<string name="_adm_page_cpt_builder_permissions"><![CDATA[Permissions]]></string>
+	<string name="_adm_page_cpt_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_adm_page_cpt_designer"><![CDATA[Designer]]></string>
+	<string name="_adm_page_cpt_home"><![CDATA[Studio]]></string>
+	<string name="_adm_page_cpt_login"><![CDATA[Login]]></string>
+	<string name="_adm_page_cpt_polyglot"><![CDATA[Polyglot]]></string>
+	<string name="_adm_page_cpt_settings"><![CDATA[Settings]]></string>
+	<string name="_adm_page_cpt_storages"><![CDATA[Storage]]></string>
+	<string name="_adm_page_cpt_store"><![CDATA[Apps]]></string>
+	<string name="_adm_pgt_btn_add_new_key"><![CDATA[Create New Key]]></string>
+	<string name="_adm_pgt_btn_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_pgt_btn_delete_title"><![CDATA[Delete key]]></string>
+	<string name="_adm_pgt_btn_edit_title"><![CDATA[Edit key]]></string>
+	<string name="_adm_pgt_btn_etemplates_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_pgt_btn_etemplates_gl_edit_title"><![CDATA[Edit template]]></string>
+	<string name="_adm_pgt_btn_etemplates_save"><![CDATA[Save]]></string>
+	<string name="_adm_pgt_btn_nkp_close"><![CDATA[Close]]></string>
+	<string name="_adm_pgt_btn_nkp_create"><![CDATA[Create]]></string>
+	<string name="_adm_pgt_btn_nkp_save"><![CDATA[Save]]></string>
+	<string name="_adm_pgt_dsc_etemplates_body"><![CDATA[Body of a message]]></string>
+	<string name="_adm_pgt_dsc_etemplates_name_system"><![CDATA[Name of the template. Displayed in Studio only.]]></string>
+	<string name="_adm_pgt_dsc_etemplates_subject"><![CDATA[Subject of a message]]></string>
+	<string name="_adm_pgt_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_pgt_err_cannot_recompile_lang"><![CDATA[Cannot recompile language(s).]]></string>
+	<string name="_adm_pgt_err_cannot_restore_lang"><![CDATA[Cannot restore language(s).]]></string>
+	<string name="_adm_pgt_err_create_key"><![CDATA[Cannot create key]]></string>
+	<string name="_adm_pgt_err_create_key_empty_fields"><![CDATA[You need to fill in the form.]]></string>
+	<string name="_adm_pgt_err_deactivate_default"><![CDATA[You cannot deactivate language which was selected as Default]]></string>
+	<string name="_adm_pgt_err_etemplates_body"><![CDATA[Enter body]]></string>
+	<string name="_adm_pgt_err_etemplates_edit"><![CDATA[Cannot update template]]></string>
+	<string name="_adm_pgt_err_etemplates_name_system"><![CDATA[Enter name, more than 3 characters]]></string>
+	<string name="_adm_pgt_err_etemplates_subject"><![CDATA[Enter subject]]></string>
+	<string name="_adm_pgt_err_last_active"><![CDATA[You need to have at least one active language.]]></string>
+	<string name="_adm_pgt_err_save"><![CDATA[Cannot save changes]]></string>
+	<string name="_adm_pgt_scs_recompiled"><![CDATA[Language(s) was successfully recompiled.]]></string>
+	<string name="_adm_pgt_scs_restored"><![CDATA[Language(s) was successfully restored.]]></string>
+	<string name="_adm_pgt_txt_all_modules"><![CDATA[All Modules]]></string>
+	<string name="_adm_pgt_txt_etemplates_body"><![CDATA[Body]]></string>
+	<string name="_adm_pgt_txt_etemplates_edit_popup"><![CDATA[Edit "{0}" Template]]></string>
+	<string name="_adm_pgt_txt_etemplates_gl_module"><![CDATA[Module]]></string>
+	<string name="_adm_pgt_txt_etemplates_gl_name_system"><![CDATA[System Title]]></string>
+	<string name="_adm_pgt_txt_etemplates_name_system"><![CDATA[System Name]]></string>
+	<string name="_adm_pgt_txt_etemplates_subject"><![CDATA[Subject]]></string>
+	<string name="_adm_pgt_txt_key"><![CDATA[Key]]></string>
+	<string name="_adm_pgt_txt_keyword"><![CDATA[Keyword...]]></string>
+	<string name="_adm_pgt_txt_languages"><![CDATA[Languages]]></string>
+	<string name="_adm_pgt_txt_module"><![CDATA[Module]]></string>
+	<string name="_adm_pgt_txt_nkp_add_popup"><![CDATA[Create New Key]]></string>
+	<string name="_adm_pgt_txt_nkp_edit_popup"><![CDATA[Edit "{0}" Key]]></string>
+	<string name="_adm_pgt_txt_nkp_key_name"><![CDATA[Key Name]]></string>
+	<string name="_adm_pgt_txt_nkp_module"><![CDATA[Module]]></string>
+	<string name="_adm_pgt_txt_text"><![CDATA[Text]]></string>
+	<string name="_adm_pgt_txt_et_hf_inf"><![CDATA[Note, that improper use of HTML may break the email message's layout. Also make sure that {unsubscribe} marker presents in at least one of the templates (header and/or footer).]]></string>
+	<string name="_adm_pgt_btn_et_hf_submit"><![CDATA[Submit]]></string>
+	<string name="_adm_pgt_scs_et_hf_save"><![CDATA[The changes were successfully saved.]]></string>
+	<string name="_adm_pgt_err_et_hf_save"><![CDATA[Cannot save changes.]]></string>
+	<string name="_adm_pgt_err_et_hf_save_unsubscribe"><![CDATA[Cannot save changes, because {unsubscribe} marker was removed from both templates, header and footer.]]></string>
+	<string name="_adm_prm_btn_actions_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_prm_btn_actions_options"><![CDATA[Edit options]]></string>
+	<string name="_adm_prm_btn_actions_save"><![CDATA[Save]]></string>
+	<string name="_adm_prm_btn_add_level"><![CDATA[Add New Level]]></string>
+	<string name="_adm_prm_btn_add_price"><![CDATA[Add New Pricing Option]]></string>
+	<string name="_adm_prm_btn_level_add"><![CDATA[Add Level]]></string>
+	<string name="_adm_prm_btn_level_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_prm_btn_level_delete"><![CDATA[Delete level]]></string>
+	<string name="_adm_prm_btn_level_edit"><![CDATA[Edit level]]></string>
+	<string name="_adm_prm_btn_level_save"><![CDATA[Save]]></string>
+	<string name="_adm_prm_btn_price_add"><![CDATA[Add]]></string>
+	<string name="_adm_prm_btn_price_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_prm_btn_price_delete"><![CDATA[Delete pricing option]]></string>
+	<string name="_adm_prm_btn_price_edit"><![CDATA[Edit pricing option]]></string>
+	<string name="_adm_prm_btn_price_save"><![CDATA[Save]]></string>
+	<string name="_adm_prm_dsc_actions_avail"><![CDATA[Leave it blank if the action is always available]]></string>
+	<string name="_adm_prm_dsc_actions_number"><![CDATA[Leave it blank for unlimited actions]]></string>
+	<string name="_adm_prm_dsc_actions_reset"><![CDATA[In hours. Leave it blank if you don't want to reset counter]]></string>
+	<string name="_adm_prm_dsc_level_description"><![CDATA[Brief overview of terms and advantages of this level.]]></string>
+	<string name="_adm_prm_dsc_level_icon"><![CDATA[You may use font icon here]]></string>
+	<string name="_adm_prm_dsc_level_icon_image"><![CDATA[or upload an image.]]></string>
+	<string name="_adm_prm_dsc_level_name"><![CDATA[Short name for the membership level (i.e Premium, Gold, Newcomer, etc.)]]></string>
+	<string name="_adm_prm_dsc_level_quota_max_file_size"><![CDATA[Limit max file size for user with this level across all modules (0 - unlimited, other system limits may apply).]]></string>
+	<string name="_adm_prm_dsc_level_quota_number"><![CDATA[Limit  amount of files a user with this level can upload (0 - unlimited).]]></string>
+	<string name="_adm_prm_dsc_level_quota_size"><![CDATA[Limit how much space can be used by user with this level across all modules (0 - unlimited).]]></string>
+	<string name="_adm_prm_dsc_price_add_days"><![CDATA[Use 0 for life-time]]></string>
+	<string name="_adm_prm_err_level_create"><![CDATA[Cannot create membership level]]></string>
+	<string name="_adm_prm_err_level_delete"><![CDATA[Cannot delete membership level]]></string>
+	<string name="_adm_prm_err_level_edit"><![CDATA[Cannot update membership level]]></string>
+	<string name="_adm_prm_err_level_icon"><![CDATA[You need to enter font icon name here.]]></string>
+	<string name="_adm_prm_err_level_icon_image"><![CDATA[Cannot upload icon: ]]></string>
+	<string name="_adm_prm_err_level_icon_image_remove"><![CDATA[Cannot remove icon]]></string>
+	<string name="_adm_prm_err_level_id"><![CDATA[Membership levels limit is reached.]]></string>
+	<string name="_adm_prm_err_level_name"><![CDATA[You need to enter name(3, 100) for all languages]]></string>
+	<string name="_adm_prm_err_level_quota_max_file_size"><![CDATA[You need to enter a numeric value, leave 0 for unlimited]]></string>
+	<string name="_adm_prm_err_level_quota_number"><![CDATA[You need to enter a numeric value, leave 0 for unlimited]]></string>
+	<string name="_adm_prm_err_level_quota_size"><![CDATA[You need to enter a numeric value, leave 0 for unlimited]]></string>
+	<string name="_adm_prm_err_price_create"><![CDATA[Cannot create pricing option]]></string>
+	<string name="_adm_prm_err_price_duplicate"><![CDATA[The similar pricing option already exists for this level.]]></string>
+	<string name="_adm_prm_err_price_update"><![CDATA[Cannot update pricing option]]></string>
+	<string name="_adm_prm_txt_actions"><![CDATA[Actions]]></string>
+	<string name="_adm_prm_txt_actions_avail_end"><![CDATA[This action is available until]]></string>
+	<string name="_adm_prm_txt_actions_avail_start"><![CDATA[This action is available since]]></string>
+	<string name="_adm_prm_txt_actions_number"><![CDATA[Number of allowed actions]]></string>
+	<string name="_adm_prm_txt_actions_options_popup"><![CDATA[Edit "{0}" Action]]></string>
+	<string name="_adm_prm_txt_actions_reset"><![CDATA[Number of actions is reset every]]></string>
+	<string name="_adm_prm_txt_all_modules"><![CDATA[All Modules]]></string>
+	<string name="_adm_prm_txt_description"><![CDATA[Description]]></string>
+	<string name="_adm_prm_txt_enable"><![CDATA[Enable]]></string>
+	<string name="_adm_prm_txt_icon"><![CDATA[Icon]]></string>
+	<string name="_adm_prm_txt_level_account"><![CDATA[Account]]></string>
+	<string name="_adm_prm_txt_level_actions_copy"><![CDATA[Copy actions from]]></string>
+	<string name="_adm_prm_txt_level_administrator"><![CDATA[Administrator]]></string>
+	<string name="_adm_prm_txt_level_create_popup"><![CDATA[Add New Level]]></string>
+	<string name="_adm_prm_txt_level_description"><![CDATA[Description]]></string>
+	<string name="_adm_prm_txt_level_edit_popup"><![CDATA[Edit "{0}" Level]]></string>
+	<string name="_adm_prm_txt_level_icon"><![CDATA[Icon]]></string>
+	<string name="_adm_prm_txt_level_icon_image"><![CDATA[]]></string>
+	<string name="_adm_prm_txt_level_icon_image_new"><![CDATA[]]></string>
+	<string name="_adm_prm_txt_level_icon_image_old"><![CDATA[Current Icon]]></string>
+	<string name="_adm_prm_txt_level_moderator"><![CDATA[Moderator]]></string>
+	<string name="_adm_prm_txt_level_name"><![CDATA[Title]]></string>
+	<string name="_adm_prm_txt_level_pending"><![CDATA[Pending]]></string>
+	<string name="_adm_prm_txt_level_premium"><![CDATA[Premium]]></string>
+	<string name="_adm_prm_txt_level_quota_max_file_size"><![CDATA[Max File Size Limit(Mb)]]></string>
+	<string name="_adm_prm_txt_level_quota_number"><![CDATA[Max Files Limit]]></string>
+	<string name="_adm_prm_txt_level_quota_size"><![CDATA[Storage Limit(Mb)]]></string>
+	<string name="_adm_prm_txt_level_standard"><![CDATA[Standard]]></string>
+	<string name="_adm_prm_txt_level_suspended"><![CDATA[Suspended]]></string>
+	<string name="_adm_prm_txt_level_unauthenticated"><![CDATA[Unauthenticated]]></string>
+	<string name="_adm_prm_txt_level_unconfirmed"><![CDATA[Unconfirmed]]></string>
+	<string name="_adm_prm_txt_manage_actions"><![CDATA[Manage actions]]></string>
+	<string name="_adm_prm_txt_max_file_size"><![CDATA[Max File Size]]></string>
+	<string name="_adm_prm_txt_max_files"><![CDATA[Max Files]]></string>
+	<string name="_adm_prm_txt_module"><![CDATA[Module]]></string>
+	<string name="_adm_prm_txt_n_actions"><![CDATA[{0} actions]]></string>
+	<string name="_adm_prm_txt_price"><![CDATA[Price]]></string>
+	<string name="_adm_prm_txt_price_add_days"><![CDATA[Number of days]]></string>
+	<string name="_adm_prm_txt_price_add_popup"><![CDATA[Add New Pricing Option]]></string>
+	<string name="_adm_prm_txt_price_add_price"><![CDATA[Price]]></string>
+	<string name="_adm_prm_txt_price_edit_popup"><![CDATA[Edit "{0} days" Pricing Option]]></string>
+	<string name="_adm_prm_txt_select_level"><![CDATA[Select Level]]></string>
+	<string name="_adm_prm_txt_storage"><![CDATA[Storage]]></string>
+	<string name="_adm_prm_txt_term"><![CDATA[Term]]></string>
+	<string name="_adm_prm_txt_title"><![CDATA[Title]]></string>
+	<string name="_adm_prm_txt_visibility_items_anyone"><![CDATA[Anyone]]></string>
+	<string name="_adm_prm_txt_visibility_items_n_user_levels"><![CDATA[{0} User Levels]]></string>
+	<string name="_adm_prm_txt_visibility_items_nobody"><![CDATA[Nobody]]></string>
+	<string name="_adm_scs_operation_done"><![CDATA[]]></string>
+	<string name="_adm_stg_cpt_category_account"><![CDATA[Account]]></string>
+	<string name="_adm_stg_cpt_category_acl"><![CDATA[ACL]]></string>
+	<string name="_adm_stg_cpt_category_notifications"><![CDATA[Notifications]]></string>
+	<string name="_adm_stg_cpt_category_notifications_push"><![CDATA[Push Notifications]]></string>
+	<string name="_adm_stg_cpt_category_cache"><![CDATA[Cache]]></string>
+	<string name="_adm_stg_cpt_category_general"><![CDATA[General]]></string>
+	<string name="_adm_stg_cpt_category_hidden"><![CDATA[Hidden]]></string>
+	<string name="_adm_stg_cpt_category_languages"><![CDATA[Languages]]></string>
+	<string name="_adm_stg_cpt_category_permalinks"><![CDATA[Permalinks]]></string>
+	<string name="_adm_stg_cpt_category_security"><![CDATA[Security]]></string>
+	<string name="_adm_stg_cpt_category_site_settings"><![CDATA[Site Settings]]></string>
+	<string name="_adm_stg_cpt_category_storage"><![CDATA[Storage]]></string>
+	<string name="_adm_stg_cpt_category_system"><![CDATA[System]]></string>
+	<string name="_adm_stg_cpt_category_templates"><![CDATA[Templates]]></string>
+    <string name="_adm_stg_cpt_category_twilio_gate"><![CDATA[Twilio]]></string>
+    <string name="_adm_stg_cpt_option_client_image_resize_width"><![CDATA[Image width to resize before upload (0 - disable)]]></string>
+    <string name="_adm_stg_cpt_option_client_image_resize_height"><![CDATA[Image height to resize before upload (0 - disable)]]></string>
+	<string name="_adm_stg_cpt_option_currency_code"><![CDATA[Currency code (for checkout system)]]></string>
+	<string name="_adm_stg_err_option_currency_code"><![CDATA[Cannot be empty.]]></string>
+	<string name="_adm_stg_cpt_option_currency_sign"><![CDATA[Currency sign (for display purposes only)]]></string>
+	<string name="_adm_stg_err_option_currency_sign"><![CDATA[Cannot be empty.]]></string>
+	<string name="_adm_stg_cpt_option_enable_gd"><![CDATA[Use GD library for image processing]]></string>
+	<string name="_adm_stg_cpt_option_enable_notification_account"><![CDATA[Notify about new accounts]]></string>
+	<string name="_adm_stg_cpt_option_enable_notification_pruning"><![CDATA[Notify about pruning results]]></string>
+	<string name="_adm_stg_cpt_option_expire_notification_days"><![CDATA[Number of days before membership expiration to notify members ( -1 = after expiration )]]></string>
+	<string name="_adm_stg_cpt_option_expire_notify_once"><![CDATA[Notify members about membership expiration only once (every day otherwise)]]></string>
+	<string name="_adm_stg_cpt_option_lang_default"><![CDATA[Default Language]]></string>
+	<string name="_adm_stg_cpt_option_lang_subst_from_en"><![CDATA[Substitute (during compilation) missing translations with english ones]]></string>	
+	<string name="_adm_stg_cpt_option_permalinks_modules"><![CDATA[Enable friendly permalinks for Modules]]></string>
+    <string name="_adm_stg_cpt_option_permalinks_pages"><![CDATA[Enable friendly permalinks for Pages]]></string>
+	<string name="_adm_stg_cpt_option_permalinks_storage"><![CDATA[Enable friendly permalinks for local Storage]]></string>
+	<string name="_adm_stg_cpt_option_site_email"><![CDATA[Email to receive critical site notifications]]></string>
+	<string name="_adm_stg_cpt_option_site_email_notify"><![CDATA[Email to send site messages from]]></string>
+	<string name="_adm_stg_cpt_option_site_email_html_template_header"><![CDATA[Email template header]]></string>
+	<string name="_adm_stg_cpt_option_site_email_html_template_footer"><![CDATA[Email template footer]]></string>
+	<string name="_adm_stg_cpt_option_site_login_social_compact"><![CDATA[Enable compact view for social login]]></string>
+	<string name="_adm_stg_cpt_option_site_title"><![CDATA[Site title]]></string>
+	<string name="_adm_stg_cpt_option_site_tour_home"><![CDATA[Site home page tour]]></string>
+    <string name="_adm_stg_cpt_option_site_tour_studio"><![CDATA[Studio home page tour]]></string>
+    <string name="_adm_stg_cpt_option_add_to_mobile_homepage"><![CDATA[Add to mobile homepage widget]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_activation_letter"><![CDATA[Enable account activation letter]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_confirmation_type"><![CDATA[Account is confirmed when]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_2fa_enable"><![CDATA[Enable 2FA]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_autoapproval"><![CDATA[Automatic account activation after creation]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_auto_profile_creation"><![CDATA[Automatic profile creation from account name]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_online_time"><![CDATA[Online status timeframe (minutes)]]></string>
+    <string name="_adm_stg_err_option_sys_account_online_time"><![CDATA[You need to enter a value greater than zero.]]></string>
+    <string name="_adm_stg_cpt_option_sys_account_default_profile_type"><![CDATA[Default profile type]]></string>
+	<string name="_adm_stg_cpt_option_sys_account_limit_profiles_number"><![CDATA[Limit number of profiles (0 - no limit)]]></string>
+  <string name="_adm_stg_cpt_option_sys_account_limit_incorrect_login_attempts"><![CDATA[Max number of logins attempts (0 - no limit)]]></string>
+	<string name="_adm_stg_cpt_option_sys_acl_expire_notification_days"><![CDATA[Number of days before membership expiration to notify members (-1 = after expiration)]]></string>
+	<string name="_adm_stg_cpt_option_sys_acl_expire_notify_once"><![CDATA[Notify members about membership expiration only once (every day otherwise)]]></string>
+	<string name="_adm_stg_cpt_option_sys_add_nofollow"><![CDATA[Add "nofollow" attribute for external links]]></string>
+	<string name="_adm_stg_cpt_option_sys_autoupdate_force_modified_files"><![CDATA[Force auto-update, even if some files were modified]]></string>
+	<string name="_adm_stg_cpt_option_sys_autoupdate"><![CDATA[Enable auto-update]]></string>
+	<string name="_adm_stg_cpt_option_sys_cache_memcache_host"><![CDATA[Memcached server host]]></string>
+	<string name="_adm_stg_cpt_option_sys_cache_memcache_port"><![CDATA[Memcached server port]]></string>
+	<string name="_adm_stg_cpt_option_sys_captcha_default"><![CDATA[Default Сaptcha]]></string>
+	<string name="_adm_stg_cpt_option_sys_email_attachable_email_templates"><![CDATA[Attachable email templates list]]></string>
+	<string name="_adm_stg_cpt_option_sys_db_cache_enable"><![CDATA[Enable DB cache]]></string>
+	<string name="_adm_stg_cpt_option_sys_db_cache_engine"><![CDATA[DB cache engine (other than File option may require custom server setup)]]></string>
+	<string name="_adm_stg_cpt_option_sys_default_payment"><![CDATA[Payment module]]></string>
+    <string name="_adm_stg_cpt_option_sys_editor_default"><![CDATA[Default HTML editor]]></string>
+	<string name="_adm_stg_cpt_option_sys_player_default"><![CDATA[Default Player]]></string>
+	<string name="_adm_stg_cpt_option_sys_player_default_format"><![CDATA[Default video format]]></string>
+	<string name="_adm_stg_cpt_option_sys_format_date"><![CDATA[Date Format]]></string>
+	<string name="_adm_stg_cpt_option_sys_format_datetime"><![CDATA[Datetime Format]]></string>
+	<string name="_adm_stg_cpt_option_sys_format_time"><![CDATA[Time Format]]></string>
+	<string name="_adm_stg_cpt_option_sys_format_timeago"><![CDATA[Use 'time ago' format for dates less than this number of seconds]]></string>
+	<string name="_adm_stg_cpt_option_sys_ftp_dir"><![CDATA[Path to the script on FTP server]]></string>
+	<string name="_adm_stg_cpt_option_sys_ftp_login"><![CDATA[FTP server login]]></string>
+	<string name="_adm_stg_cpt_option_sys_ftp_password"><![CDATA[FTP server password]]></string>
+	<string name="_adm_stg_cpt_option_sys_cron_time"><![CDATA[Last cron execution time]]></string>
+	<string name="_adm_stg_cpt_option_sys_install_time"><![CDATA[Installation date]]></string>
+	<string name="_adm_stg_cpt_option_sys_live_updates_interval"><![CDATA[Live updates interval (in milliseconds)]]></string>
+	<string name="_adm_stg_cpt_option_sys_maps_api_key"><![CDATA[Google Maps API key]]></string>
+	<string name="_adm_stg_cpt_option_sys_embed_default"><![CDATA[Embeds provider]]></string>
+	<string name="_adm_stg_cpt_option_sys_embedly_api_key"><![CDATA[Embed.ly API key (fill in to use instead of Iframely)]]></string>
+	<string name="_adm_stg_cpt_option_sys_embedly_api_pattern"><![CDATA[Embed.ly API pattern (fill in to use instead of Iframely)]]></string>
+	<string name="_adm_stg_cpt_option_sys_iframely_api_key"><![CDATA[Iframely API key]]></string>
+        <string name="_adm_stg_cpt_option_sys_eq_time"><![CDATA[Email queue execution flag]]></string>
+	<string name="_adm_stg_cpt_option_sys_eq_send_per_start"><![CDATA[Number of messages to send from mail queue per run]]></string>
+        <string name="_adm_stg_cpt_option_sys_eq_send_per_start_to_recipient"><![CDATA[Number of messages to send from mail queue per run to the same recipient]]></string>
+	<string name="_adm_stg_cpt_option_sys_oauth_key"><![CDATA[UNA account key]]></string>
+	<string name="_adm_stg_cpt_option_sys_oauth_secret"><![CDATA[UNA account secret]]></string>
+	<string name="_adm_stg_cpt_option_sys_page_cache_enable"><![CDATA[Enable Page cache]]></string>
+	<string name="_adm_stg_cpt_option_sys_page_cache_engine"><![CDATA[Page cache engine (other than File option may require custom server setup)]]></string>
+	<string name="_adm_stg_cpt_option_sys_pb_cache_enable"><![CDATA[Enable page blocks cache]]></string>
+	<string name="_adm_stg_cpt_option_sys_pb_cache_engine"><![CDATA[Page blocks cache engine (other than File option may require custom server setup)]]></string>
+	<string name="_adm_stg_cpt_option_sys_per_page_search_keyword_single"><![CDATA[Number of items in Keyword Search results]]></string>
+	<string name="_adm_stg_cpt_option_sys_per_page_search_keyword_plural"><![CDATA[Number of items in Site Search results]]></string>
+	<string name="_adm_stg_cpt_option_sys_push_app_id"><![CDATA[OneSignal App ID]]></string>
+    <string name="_adm_stg_cpt_option_sys_push_rest_api"><![CDATA[REST API Key]]></string>
+    <string name="_adm_stg_cpt_option_sys_push_short_name"><![CDATA[Short name (required only for http sites. It must match the Subdomain you entered on the Web Push settings on the OneSignal dashboard)]]></string>
+    <string name="_adm_stg_cpt_option_sys_push_safari_id"><![CDATA[Apple Safari Web ID on the Web Push settings]]></string>
+    <string name="_adm_stg_cpt_option_sys_push_queue_time"><![CDATA[Push queue execution flag]]></string>
+    <string name="_adm_stg_cpt_option_sys_push_queue_send_per_start"><![CDATA[Number of messages to send from Push queue per run]]></string>
+    <string name="_adm_stg_cpt_option_sys_push_queue_send_per_start_to_recipient"><![CDATA[Number of messages to send from Push queue per run to some recipient]]></string>
+	<string name="_adm_stg_cpt_option_sys_twilio_gate_sid"><![CDATA[Account SID]]></string>
+	<string name="_adm_stg_cpt_option_sys_twilio_gate_token"><![CDATA[Auth token]]></string>
+	<string name="_adm_stg_cpt_option_sys_twilio_gate_from_number"><![CDATA[Default 'From' number for SMS]]></string>    
+	<string name="_adm_stg_cpt_option_sys_recaptcha_key_private"><![CDATA[reCAPTCHA private key]]></string>
+	<string name="_adm_stg_cpt_option_sys_recaptcha_key_public"><![CDATA[reCAPTCHA public key]]></string>
+	<string name="_adm_stg_cpt_option_sys_redirect_after_account_added"><![CDATA[Redirect after account creation to]]></string>
+	<string name="_adm_stg_cpt_option_sys_redirect_after_email_confirmation"><![CDATA[Redirect after email confirmation to]]></string>
+        <string name="_adm_stg_cpt_option_sys_relations"><![CDATA[Enable relationships between]]></string>
+	<string name="_adm_stg_cpt_option_sys_revision"><![CDATA[Revision number]]></string>
+	<string name="_adm_stg_cpt_option_sys_security_form_token_enable"><![CDATA[Enable CSRF token in forms]]></string>
+	<string name="_adm_stg_cpt_option_sys_security_form_token_lifetime"><![CDATA[CSRF token lifetime in seconds(0 - do not track time)]]></string>
+	<string name="_adm_stg_cpt_option_sys_security_impact_threshold_block"><![CDATA[Total security impact threshold to send report and block aggressor]]></string>
+	<string name="_adm_stg_cpt_option_sys_security_impact_threshold_log"><![CDATA[Total security impact threshold to send report]]></string>
+	<string name="_adm_stg_cpt_option_sys_site_logo_height"><![CDATA[Logo Height]]></string>
+	<string name="_adm_stg_cpt_option_sys_site_logo_width"><![CDATA[Logo Width]]></string>
+	<string name="_adm_stg_cpt_option_sys_storage_default"><![CDATA[Default storage engine (other than Local may require custom/additional setup)]]></string>
+	<string name="_adm_stg_cpt_option_sys_storage_s3_access_key"><![CDATA[AWS access key]]></string>
+	<string name="_adm_stg_cpt_option_sys_storage_s3_bucket"><![CDATA[AWS bucket]]></string>
+	<string name="_adm_stg_cpt_option_sys_storage_s3_domain"><![CDATA[AWS custom domain (require custom DNS setup)]]></string>
+	<string name="_adm_stg_cpt_option_sys_storage_s3_secret_key"><![CDATA[AWS secret key]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_image_enable"><![CDATA[Enable cache for images]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_image_max_size"><![CDATA[Cached image max size (in Kb)]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_compress_enable"><![CDATA[Enable compression for JS/CSS files(cache should be enabled)]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_css_enable"><![CDATA[Enable cache for CSS files]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_enable"><![CDATA[Enable cache for HTML files]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_engine"><![CDATA[Template cache engine (other than FileHtml option may require custom server setup)]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_js_enable"><![CDATA[Enable cache for JS files]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_minify_css_enable"><![CDATA[Enable lessening for CSS files (cache should be enabled)]]></string>
+	<string name="_adm_stg_cpt_option_sys_template_cache_minify_js_enable"><![CDATA[Enable lessening for JS files (cache should be enabled)]]></string>
+	<string name="_adm_stg_cpt_option_sys_transcoder_queue_storage"><![CDATA[Remote video transcoding (requires special setup)]]></string>
+	<string name="_adm_stg_cpt_option_template"><![CDATA[Default Template]]></string>
+	<string name="_adm_stg_err_option_template"><![CDATA[Template cannot be empty and must have a valid name.]]></string>
+    <string name="_adm_stg_cpt_option_use_like_operator"><![CDATA[Use operator LIKE for search (recommended for small content)]]></string>
+    <string name="_adm_stg_cpt_option_sys_tinymce_plugins_mini"><![CDATA[TinyMCE plugins for mini editor]]></string>
+    <string name="_adm_stg_cpt_option_sys_tinymce_toolbar_mini"><![CDATA[TinyMCE buttons for mini editor]]></string>
+    <string name="_adm_stg_cpt_option_sys_tinymce_plugins_standard"><![CDATA[TinyMCE plugins for standard editor]]></string>
+    <string name="_adm_stg_cpt_option_sys_tinymce_toolbar_standard"><![CDATA[TinyMCE buttons for standard editor]]></string>
+    <string name="_adm_stg_cpt_option_sys_tinymce_plugins_full"><![CDATA[TinyMCE plugins for full editor]]></string>
+    <string name="_adm_stg_cpt_option_sys_tinymce_toolbar_full"><![CDATA[TinyMCE buttons for full editor]]></string>
+    <string name="_adm_stg_cpt_option_sys_metatags_hashtags_max"><![CDATA[Max number of hashtags per post]]></string>
+    <string name="_adm_stg_cpt_option_sys_metatags_mentions_max"><![CDATA[Max number of mentions per post]]></string>
+    <string name="_adm_stg_cpt_option_sys_search_keyword_min_len"><![CDATA[Keyword min length in site search]]></string>
+	<string name="_adm_stg_cpt_type_system"><![CDATA[System]]></string>
+	<string name="_adm_stg_scs_save"><![CDATA[Settings were successfully saved]]></string>
+	<string name="_adm_stg_err_save_error_message"><![CDATA[Error in '{0}': {1}]]></string>
+	<string name="_adm_stg_err_cannot_perform"><![CDATA[Cannot perform the action.]]></string>
+	<string name="_adm_stg_err_mix_already_exists"><![CDATA[Mix with the same name already exists.]]></string>
+	<string name="_adm_stg_txt_create_mix_popup"><![CDATA[Add New Mix]]></string>
+	<string name="_adm_stg_txt_import_mix_popup"><![CDATA[Import Mix]]></string>
+	<string name="_adm_stg_txt_mix_duplicate"><![CDATA[Duplicate from]]></string>
+	<string name="_adm_stg_txt_mix_duplicate_inf"><![CDATA[Use 'None' to duplicate System values]]></string>
+	<string name="_adm_stg_txt_mix_title"><![CDATA[Mix Title]]></string>
+        <string name="_adm_stg_txt_mix_title_inf"><![CDATA[Create a <b>_sys_template_mixed_[template_name]_[mix_name]</b> language key in Polyglot to customise the publicly-displayed name. <b>[template_name]</b> and <b>[mix_name]</b> are in lowercase, underscore instead of space.]]></string>
+	<string name="_adm_stg_txt_mix_title_err"><![CDATA[Title is essential. Please, fill in this field.]]></string>
+	<string name="_adm_stg_txt_mix_system"><![CDATA[System]]></string>
+	<string name="_adm_stg_err_remove_old_image"><![CDATA[Cannot remove current image.]]></string>
+	<string name="_adm_str_cpt_files_file"><![CDATA[File]]></string>
+	<string name="_adm_str_cpt_files_version"><![CDATA[Version]]></string>
+	<string name="_adm_str_err_cannot_connect_to_ftp"><![CDATA[Cannot connect to FTP server. Please check FTP access details in Settings -> General.]]></string>
+	<string name="_adm_str_err_cannot_unzip_package"><![CDATA[Cannot unarchive ZIP package.]]></string>
+	<string name="_adm_str_err_cannot_write"><![CDATA[Cannot save downloaded file.]]></string>
+	<string name="_adm_str_err_destination_not_valid"><![CDATA[Destination FTP folder doesn't look like a valid the script root folder.]]></string>
+	<string name="_adm_str_err_download_failed"><![CDATA[Download failed. Please report.]]></string>
+	<string name="_adm_str_err_files_copy_failed"><![CDATA[File transfer failed, please check write permissions.]]></string>
+	<string name="_adm_str_err_no_ftp_info"><![CDATA[FTP access info was not specified. You may enter it via Settings -> General.]]></string>
+	<string name="_adm_str_err_no_product_info"><![CDATA[Cannot load product info. Try again later.]]></string>
+	<string name="_adm_str_err_wrong_package_format"><![CDATA[Wrong package format.]]></string>
+	<string name="_adm_str_err_zip_not_available"><![CDATA[ZIP library is not available.]]></string>
+	<string name="_adm_str_msg_download_scheduled"><![CDATA[Download was scheduled, in a few minutes downloaded package will be available to install via Apps &gt; Downloaded]]></string>
+	<string name="_adm_str_msg_download_and_install_scheduled"><![CDATA[Download and subsequent installation were scheduled, it may take a few minutes]]></string>
+	<string name="_adm_str_msg_download_successfully"><![CDATA[Download was successfully finished, you may install it via Apps &gt; Downloaded]]></string>
+	<string name="_adm_str_msg_download_and_install_successfully"><![CDATA[Download and subsequent installation were successfully finished]]></string>
+	<string name="_adm_str_txt_discount_csign"><![CDATA[({0}{1} for Premium)]]></string>
+	<string name="_adm_str_txt_items_by"><![CDATA[item(s) by]]></string>
+	<string name="_adm_str_txt_or"><![CDATA[or]]></string>
+	<string name="_adm_str_txt_per_week"><![CDATA[week]]></string>
+    <string name="_adm_str_txt_per_week_short"><![CDATA[wk]]></string>
+    <string name="_adm_str_txt_per_month"><![CDATA[month]]></string>
+    <string name="_adm_str_txt_per_month_short"><![CDATA[mo]]></string>
+    <string name="_adm_str_txt_per_year"><![CDATA[year]]></string>
+    <string name="_adm_str_txt_per_year_short"><![CDATA[yr]]></string>
+	<string name="_adm_str_txt_price_free"><![CDATA[Free]]></string>
+	<string name="_adm_str_txt_price_recurring"><![CDATA[{0}{1}/{2}]]></string>
+	<string name="_adm_str_txt_price_single"><![CDATA[{0}{1}]]></string>
+	<string name="_adm_str_txt_pv_category"><![CDATA[Category]]></string>
+	<string name="_adm_str_txt_pv_created"><![CDATA[Created]]></string>
+	<string name="_adm_str_txt_pv_description"><![CDATA[Description]]></string>
+	<string name="_adm_str_txt_pv_discount"><![CDATA[Discount]]></string>
+	<string name="_adm_str_txt_pv_discount_off_csign"><![CDATA[{0}% ({1}{2}) off for Premium]]></string>
+	<string name="_adm_str_txt_pv_price"><![CDATA[Price]]></string>
+	<string name="_adm_str_txt_pv_rent"><![CDATA[Rent]]></string>
+	<string name="_adm_str_txt_pv_stats"><![CDATA[Stats]]></string>
+	<string name="_adm_str_txt_pv_stats_votes"><![CDATA[{0} votes]]></string>
+	<string name="_adm_str_txt_pv_stats_reviews"><![CDATA[{0} reviews]]></string>
+	<string name="_adm_str_txt_pv_stats_views"><![CDATA[{0} views]]></string>
+	<string name="_adm_str_txt_pv_tags"><![CDATA[Tags]]></string>
+	<string name="_adm_str_txt_pv_title"><![CDATA[Title]]></string>
+	<string name="_adm_str_txt_pv_updated"><![CDATA[Updated]]></string>
+	<string name="_adm_str_txt_pv_vendor"><![CDATA[Vendor]]></string>
+	<string name="_adm_str_txt_pv_version"><![CDATA[Version]]></string>
+	<string name="_adm_str_txt_pv_version_mask"><![CDATA[{0} ({1} is available)]]></string>
+	<string name="_adm_str_txt_update_from_to"><![CDATA[{0} - {1}]]></string>
+	<string name="_adm_strg_err_cannot_process_action"><![CDATA[Cannot process action. It does not have an associated handler.]]></string>
+	<string name="_adm_strg_err_files_delete"><![CDATA[Cannot delete file(s).]]></string>
+	<string name="_adm_strg_msg_files_delete"><![CDATA[Files were queued for deletion. They will be deleted a little bit later.]]></string>
+	<string name="_adm_strg_err_images_delete"><![CDATA[Cannot delete image(s).]]></string>
+	<string name="_adm_strg_msg_images_delete"><![CDATA[Images were queued for deletion. They will be deleted a little bit later.]]></string>
+	<string name="_adm_strg_err_images_resize"><![CDATA[Cannot resize image.]]></string>
+	<string name="_adm_strg_txt_file_name"><![CDATA[Name]]></string>
+	<string name="_adm_strg_txt_path"><![CDATA[URL]]></string>
+	<string name="_adm_strg_txt_mime_type"><![CDATA[Type]]></string>
+	<string name="_adm_strg_txt_added"><![CDATA[Date]]></string>
+	<string name="_adm_strg_btn_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_strg_btn_add"><![CDATA[Add]]></string>
+	<string name="_adm_strg_btn_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_strg_btn_done"><![CDATA[Done]]></string>
+	<string name="_adm_strg_btn_download"><![CDATA[Download]]></string>
+	<string name="_adm_strg_btn_resize"><![CDATA[Resize]]></string>
+	<string name="_adm_strg_txt_files_add_popup"><![CDATA[Add File]]></string>
+	<string name="_adm_strg_txt_images_add_popup"><![CDATA[Add Image]]></string>
+	<string name="_adm_strg_txt_images_resize_popup"><![CDATA[Resize Image]]></string>
+	<string name="_adm_strg_txt_size_mime_type"><![CDATA[{0}x{1}, {2}]]></string>
+	<string name="_adm_strg_txt_width"><![CDATA[Width]]></string>
+	<string name="_adm_strg_err_width"><![CDATA[Width is essential. Please, fill in this field.]]></string>
+	<string name="_adm_strg_txt_height"><![CDATA[Height]]></string>
+	<string name="_adm_strg_err_height"><![CDATA[Height is essential. Please, fill in this field.]]></string>
+	<string name="_adm_tmi_cpt_edit"><![CDATA[Manage Launcher]]></string>
+	<string name="_adm_tmi_cpt_extensions"><![CDATA[Add Apps]]></string>
+	<string name="_adm_tmi_cpt_favorite"><![CDATA[Show Favorite Only]]></string>
+	<string name="_adm_tmi_cpt_logout"><![CDATA[Sign out]]></string>
+	<string name="_adm_tmi_cpt_site"><![CDATA[Go To Site]]></string>
+	<string name="_adm_tmi_cpt_tour"><![CDATA[Tour]]></string>
+	<string name="_adm_tmi_cpt_launcher"><![CDATA[Back to Launcher]]></string>
+	<string name="_adm_txt_confirm_cancel"><![CDATA[Cancel]]></string>
+	<string name="_adm_txt_confirm_ok"><![CDATA[OK]]></string>
+	<string name="_adm_txt_forgot_password"><![CDATA[Forgot password?]]></string>
+	<string name="_adm_txt_form_view_iu_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_txt_form_view_iu_preview"><![CDATA[Current Image]]></string>
+	<string name="_adm_txt_form_view_iu_preview_empty"><![CDATA[No image uploaded.]]></string>
+	<string name="_adm_txt_form_view_missing"><![CDATA[missing]]></string>
+	<string name="_adm_txt_login_password"><![CDATA[password]]></string>
+	<string name="_adm_txt_login_email"><![CDATA[email]]></string>
+	<string name="_adm_txt_module_custom"><![CDATA[Custom]]></string>
+	<string name="_adm_txt_module_skeletons"><![CDATA[Skeletons]]></string>
+	<string name="_adm_txt_module_system"><![CDATA[System]]></string>
+	<string name="_adm_txt_modules_check_dependencies"><![CDATA[Check module dependencies:]]></string>
+	<string name="_adm_txt_modules_check_module_exists"><![CDATA[Check module for existence:]]></string>
+	<string name="_adm_txt_modules_check_module_matches"><![CDATA[Check module to match:]]></string>
+	<string name="_adm_txt_modules_check_module_hash"><![CDATA[Check module hash:]]></string>
+	<string name="_adm_txt_modules_check_module_version"><![CDATA[Check module version:]]></string>
+	<string name="_adm_txt_modules_check_script_version"><![CDATA[Check the script version for compatibility:]]></string>
+	<string name="_adm_txt_modules_clear_db_cache"><![CDATA[Clear database cache:]]></string>
+	<string name="_adm_txt_modules_clear_template_cache"><![CDATA[Clear template cache:]]></string>
+	<string name="_adm_txt_modules_delete"><![CDATA[Delete]]></string>
+	<string name="_adm_txt_modules_disable"><![CDATA[Disable]]></string>
+	<string name="_adm_txt_modules_enable"><![CDATA[Enable]]></string>
+	<string name="_adm_txt_modules_executable"><![CDATA[Executable]]></string>
+	<string name="_adm_txt_modules_execute_sql"><![CDATA[Changing database:]]></string>
+	<string name="_adm_txt_modules_ftp_access"><![CDATA[FTP access]]></string>
+	<string name="_adm_txt_modules_install"><![CDATA[Install]]></string>
+	<string name="_adm_txt_modules_install_language"><![CDATA[Install language:]]></string>
+	<string name="_adm_txt_modules_login"><![CDATA[Login]]></string>
+	<string name="_adm_txt_modules_market"><![CDATA[UNA Market]]></string>
+	<string name="_adm_txt_modules_move_sources"><![CDATA[Move source files:]]></string>
+	<string name="_adm_txt_modules_operation_update"><![CDATA[Installation of update <b>{0}</b> from {1} up to {2}]]></string>
+	<string name="_adm_txt_modules_package_module"><![CDATA[Module]]></string>
+	<string name="_adm_txt_modules_package_to_upload"><![CDATA[Package to upload]]></string>
+	<string name="_adm_txt_modules_params_used"><![CDATA[A module with similar unique parameters is already installed.]]></string>
+	<string name="_adm_txt_modules_password"><![CDATA[Password]]></string>
+	<string name="_adm_txt_modules_process_action_success"><![CDATA[Done]]></string>
+	<string name="_adm_txt_modules_process_connections"><![CDATA[Process connections:]]></string>
+	<string name="_adm_txt_modules_process_deleted_profiles"><![CDATA[Process deleted profiles:]]></string>
+	<string name="_adm_txt_modules_process_menu_triggers"><![CDATA[Process menu triggers:]]></string>
+	<string name="_adm_txt_modules_process_page_triggers"><![CDATA[Process page triggers:]]></string>
+	<string name="_adm_txt_modules_process_storages"><![CDATA[Process storages:]]></string>
+	<string name="_adm_txt_modules_process_failed"><![CDATA[Failed]]></string>
+	<string name="_adm_txt_modules_process_success"><![CDATA[Done]]></string>
+	<string name="_adm_txt_modules_process_esearches"><![CDATA[Process search forms:]]></string>
+	<string name="_adm_txt_modules_register_transcoders"><![CDATA[Register transcoders:]]></string>
+	<string name="_adm_txt_modules_unregister_transcoders"><![CDATA[Unregister transcoders:]]></string>
+	<string name="_adm_txt_modules_show_conclusion"><![CDATA[Conclusion from vendor:]]></string>
+	<string name="_adm_txt_modules_show_introduction"><![CDATA[Introduction from vendor:]]></string>
+	<string name="_adm_txt_modules_update_files"><![CDATA[Update files:]]></string>
+	<string name="_adm_txt_modules_update_relations"><![CDATA[Update relations:]]></string>
+	<string name="_adm_txt_modules_update_relations_for_all"><![CDATA[Update relations for all dependent modules:]]></string>
+	<string name="_adm_txt_modules_update_languages"><![CDATA[Update languages:]]></string>
+	<string name="_adm_txt_modules_update_latest"><![CDATA[You have the most current version.]]></string>
+	<string name="_adm_txt_modules_update_text"><![CDATA[New version {0} is available.]]></string>
+	<string name="_adm_txt_modules_updates"><![CDATA[Available Updates]]></string>
+	<string name="_adm_txt_modules_upload"><![CDATA[Add New Module]]></string>
+	<string name="_adm_txt_modules_writable"><![CDATA[Writable]]></string>
+	<string name="_adm_txt_pca_active"><![CDATA[Active]]></string>
+	<string name="_adm_txt_pca_favorite"><![CDATA[Favorite]]></string>
+	<string name="_adm_txt_remember_me"><![CDATA[Remember me]]></string>
+	<string name="_adm_txt_select_module"><![CDATA[Select Module...]]></string>
+	<string name="_adm_txt_show_actions"><![CDATA[Actions]]></string>
+	<string name="_adm_txt_show_help"><![CDATA[Help]]></string>
+	<string name="_adm_txt_show_help_content_empty"><![CDATA[Help is not available]]></string>
+	<string name="_adm_txt_uninstall"><![CDATA[Uninstall]]></string>
+	<string name="_adm_wgt_cpt_builder_forms"><![CDATA[Forms]]></string>
+	<string name="_adm_wgt_cpt_builder_menus"><![CDATA[Navigation]]></string>
+	<string name="_adm_wgt_cpt_builder_pages"><![CDATA[Pages]]></string>
+	<string name="_adm_wgt_cpt_builder_permissions"><![CDATA[Permissions]]></string>
+	<string name="_adm_wgt_cpt_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_adm_wgt_cpt_designer"><![CDATA[Designer]]></string>
+	<string name="_adm_wgt_cpt_polyglot"><![CDATA[Polyglot]]></string>
+	<string name="_adm_wgt_cpt_settings"><![CDATA[Settings]]></string>
+	<string name="_adm_wgt_cpt_storages"><![CDATA[Storage]]></string>
+	<string name="_adm_wgt_cpt_store"><![CDATA[Apps Market]]></string>
+	<string name="_cmt_block_comments_title"><![CDATA[Comments ({0})]]></string>
+	<string name="_cmt_browse_all"><![CDATA[All]]></string>
+	<string name="_cmt_browse_friends"><![CDATA[Friends]]></string>
+	<string name="_cmt_browse_head"><![CDATA[Oldest]]></string>
+	<string name="_cmt_browse_popular"><![CDATA[Popular]]></string>
+	<string name="_cmt_browse_subscriptions"><![CDATA[Subscriptions]]></string>
+	<string name="_cmt_browse_tail"><![CDATA[Newest]]></string>
+	<string name="_cmt_display_flat"><![CDATA[Flat]]></string>
+	<string name="_cmt_display_threaded"><![CDATA[Threaded]]></string>
+	<string name="_cmt_err_cannot_perform_action"><![CDATA[Cannot perform action. Please report.]]></string>
+	<string name="_cmt_msg_login_required"><![CDATA[<a href="{0}">Login</a> or <a href="{1}">Join</a> to comment.]]></string>
+	<string name="_cmt_page_view_header"><![CDATA[Comment to '{0}']]></string>
+	<string name="_cmt_page_view_title"><![CDATA[Comment to <a href="{0}">{1}</a>]]></string>
+	<string name="_cmt_download_attached_file"><![CDATA[Download file]]></string>
+	<string name="_cmt_view_attached_image"><![CDATA[View image]]></string>
+	<string name="_cmt_load_more_comments_head"><![CDATA[See newer comments...]]></string>
+	<string name="_cmt_load_more_comments_tail"><![CDATA[See older comments...]]></string>
+	<string name="_cmt_load_more_comments_popular"><![CDATA[See more comments...]]></string>
+	<string name="_cmt_load_more_replies_head"><![CDATA[See newer replies...]]></string>
+	<string name="_cmt_load_more_replies_tail"><![CDATA[See older replies...]]></string>
+	<string name="_cmt_load_more_replies_popular"><![CDATA[See more replies...]]></string>
+        <string name="_cmt_txt_new_content"><![CDATA[New content]]></string>
+	<string name="_cmt_txt_link_show"><![CDATA[Show]]></string>
+	<string name="_cmt_txt_link_reply"><![CDATA[Reply]]></string>
+        <string name="_cmt_txt_added_sample"><![CDATA[added a new comment]]></string>
+	<string name="_cmt_txt_or"><![CDATA[or]]></string>
+	<string name="_cmt_txt_sample_comment_single"><![CDATA[comment]]></string>
+	<string name="_cmt_txt_sample_reply_to"><![CDATA[reply to comment]]></string>
+	<string name="_cmt_txt_n_comments"><![CDATA[{0} comments]]></string>
+        <string name="_cmt_txt_do"><![CDATA[Comment]]></string>
+        <string name="_cmt_txt_counter"><![CDATA[{0}]]></string>
+	<string name="_cmt_txt_counter_empty"><![CDATA[Comment]]></string>
+        <string name="_cmt_txt_min_form_placeholder"><![CDATA[{0}, leave your comment here.]]></string>
+	<string name="_copyright"><![CDATA[&copy; {0} Company]]></string>
+	<string name="_delete"><![CDATA[delete]]></string>
+	<string name="_error occured"><![CDATA[Error occurred]]></string>
+	<string name="_from"><![CDATA[from]]></string>
+	<string name="_hidden_comment"><![CDATA[Comment by <b>{0}</b> is hidden.]]></string>
+	<string name="_in_reply_to"><![CDATA[In reply to {0}]]></string>
+	<string name="_item"><![CDATA[item]]></string>
+	<string name="_items"><![CDATA[items]]></string>
+	<string name="_member_banned"><![CDATA[Sorry, you've been banned]]></string>
+	<string name="_message_subject"><![CDATA[Message subject]]></string>
+	<string name="_mma_comments_edit_own"><![CDATA[comments edit own]]></string>
+	<string name="_mma_comments_post"><![CDATA[comments post]]></string>
+	<string name="_mma_comments_remove_own"><![CDATA[comments remove own]]></string>
+	<string name="_mma_comments_vote"><![CDATA[comments vote]]></string>
+	<string name="_mma_get_other_members_emails"><![CDATA[get other members emails]]></string>
+	<string name="_mma_send_greetings"><![CDATA[send greetings]]></string>
+	<string name="_mma_send_messages"><![CDATA[send messages]]></string>
+	<string name="_mma_view_profiles"><![CDATA[view profiles]]></string>
+	<string name="_mma_vote"><![CDATA[vote]]></string>
+	<string name="_month_next"><![CDATA[Next Month]]></string>
+	<string name="_month_prev"><![CDATA[Previous Month]]></string>
+	<string name="_no limit"><![CDATA[no limit]]></string>
+	<string name="_powered_by"><![CDATA[Powered by]]></string>
+	<string name="_see_more"><![CDATA[see more]]></string>
+	<string name="_show_replacement"><![CDATA[Show]]></string>
+	<string name="_sys_accept"><![CDATA[Accept]]></string>
+	<string name="_sys_accounts"><![CDATA[Accounts]]></string>
+	<string name="_sys_access_denied_to_private_content"><![CDATA[Access denied. This is private content.]]></string>
+	<string name="_sys_actions"><![CDATA[Actions]]></string>
+	<string name="_sys_active"><![CDATA[Active]]></string>
+	<string name="_sys_acc_confirmation_type_none"><![CDATA[No confirmation]]></string>
+	<string name="_sys_acc_confirmation_type_email"><![CDATA[email is confirmed]]></string>
+	<string name="_sys_acc_confirmation_type_phone"><![CDATA[phone is confirmed]]></string>
+	<string name="_sys_acc_confirmation_type_email_and_phone"><![CDATA[email and phone are confirmed]]></string>
+	<string name="_sys_acl_action_account"><![CDATA[You didn't created any profiles, so you can't '{1}'.]]></string>
+	<string name="_sys_acl_action_chart_view"><![CDATA[View charts]]></string>
+	<string name="_sys_acl_action_chart_view_desc"><![CDATA[View statistical charts]]></string>
+	<string name="_sys_acl_action_comments_edit_all"><![CDATA[Comments Edit All]]></string>
+	<string name="_sys_acl_action_comments_edit_own"><![CDATA[Comments Edit Own]]></string>
+	<string name="_sys_acl_action_comments_post"><![CDATA[Comments Post]]></string>
+	<string name="_sys_acl_action_comments_remove_all"><![CDATA[Comments Remove All]]></string>
+	<string name="_sys_acl_action_comments_remove_own"><![CDATA[Comments Remove Own]]></string>
+	<string name="_sys_acl_action_connect"><![CDATA[Connect (befriend, follow, etc)]]></string>
+	<string name="_sys_acl_action_create_account"><![CDATA[Create Account]]></string>
+	<string name="_sys_acl_action_create_account_desc"><![CDATA[It make sense for guests only, you can temporary disable it or set limit by time for example.]]></string>
+	<string name="_sys_acl_action_delete_account"><![CDATA[Delete Account]]></string>
+	<string name="_sys_acl_action_delete_account_desc"><![CDATA[Delete account also deletes account's content.]]></string>
+	<string name="_sys_acl_action_every_period"><![CDATA[ every {4} hours]]></string>
+	<string name="_sys_acl_action_favorite"><![CDATA[Favorite]]></string>
+	<string name="_sys_acl_action_favorite_view"><![CDATA[View favorites]]></string>
+	<string name="_sys_acl_action_feature"><![CDATA[Feature]]></string>
+	<string name="_sys_acl_action_view_view"><![CDATA[View views]]></string>
+	<string name="_sys_acl_action_view_view_viewers_own"><![CDATA[View viewers for own content]]></string>
+	<string name="_sys_acl_action_limit_reached"><![CDATA[You have reached your limit for now. Your current membership ({2}) allows you to {1} no more than {3} times]]></string>
+	<string name="_sys_acl_action_not_allowed"><![CDATA[Your current membership ({2}) doesn't allow you to '{1}'.]]></string>
+	<string name="_sys_acl_action_not_allowed_after"><![CDATA[Your current membership ({2}) stopped to allow you to '{1}' {5}.]]></string>
+	<string name="_sys_acl_action_not_allowed_before"><![CDATA[Your current membership ({2}) will allow you to '{1}' {6}.]]></string>
+    <string name="_sys_acl_action_pending"><![CDATA[You are currently not an active member. Please, ask the site <a href="mailto:{7}">administrator</a> to make you an active member so you would be able to <b>{1}</b>.]]></string>
+	<string name="_sys_acl_action_post_links"><![CDATA[Post links]]></string>
+	<string name="_sys_acl_action_post_links_desc"><![CDATA[Post links in text and textarea form fields]]></string>    
+	<string name="_sys_acl_action_set_acl_level"><![CDATA[Set membership level]]></string>
+	<string name="_sys_acl_action_set_acl_level_desc"><![CDATA[Set membership level for profiles]]></string>
+        <string name="_sys_acl_action_set_acl_as_privacy"><![CDATA[Choose membership level as privacy]]></string>
+	<string name="_sys_acl_action_set_acl_as_privacy_desc"><![CDATA[Choose membership level as privacy in add content forms]]></string>
+	<string name="_sys_acl_action_suspended"><![CDATA[You can't '{1}' because your profile was suspended, if you don't know why - try to send message to <a href="mailto:{7}">administrator</a>.]]></string>
+	<string name="_sys_acl_action_unauthenticated"><![CDATA[Not logged in users can't '{1}'.]]></string>
+	<string name="_sys_acl_action_unconfirmed"><![CDATA[You didn't confirm your profile. Please check your email with profile activation link. Unconfirmed members can't <b>{1}</b>.]]></string>
+	<string name="_sys_acl_action_vote"><![CDATA[Vote]]></string>
+        <string name="_sys_acl_action_vote_view"><![CDATA[View votes]]></string>
+        <string name="_sys_acl_action_vote_view_voters"><![CDATA[View voters]]></string>
+	<string name="_sys_acl_action_report"><![CDATA[Report]]></string>
+	<string name="_sys_acl_action_report_view"><![CDATA[View reports]]></string>
+	<string name="_sys_acl_start"><![CDATA[Start: ]]></string>
+	<string name="_sys_acl_expire"><![CDATA[Expire: ]]></string>
+	<string name="_sys_acl_expire_never"><![CDATA[never]]></string>
+	<string name="_sys_add_friend"><![CDATA[Add friend]]></string>
+        <string name="_sys_add_relation"><![CDATA[Add relationship]]></string>
+	<string name="_sys_adm_installed"><![CDATA[Installed]]></string>
+	<string name="_sys_admin_apply"><![CDATA[Apply]]></string>
+	<string name="_sys_admin_filter"><![CDATA[Filter:]]></string>
+	<string name="_sys_audit_cron_jobs"><![CDATA[Cron jobs]]></string>
+	<string name="_sys_audit_cron_jobs_exec_time"><![CDATA[Last cron jobs execution]]></string>
+	<string name="_sys_audit_header_manual_audit"><![CDATA[Manual Server Audit]]></string>
+	<string name="_sys_audit_header_requirements"><![CDATA[Requirements]]></string>
+	<string name="_sys_audit_header_site_optimization"><![CDATA[Site optimization]]></string>
+	<string name="_sys_audit_header_site_setup"><![CDATA[Site setup]]></string>
+	<string name="_sys_audit_mail_sending"><![CDATA[Mail sending]]></string>
+	<string name="_sys_audit_msg_apache_module_fail"><![CDATA[you will need to install {0} for Apache]]></string>
+	<string name="_sys_audit_msg_apache_module_undef"><![CDATA[try to check manually: apachectl -M 2>&1 | grep {0}]]></string>
+	<string name="_sys_audit_msg_cron_jobs"><![CDATA[<pre class="code">{0}</pre> if you are unsure if output is correct then <a href="#manual_audit">manual server audit</a> may be required]]></string>
+	<string name="_sys_audit_msg_optimization_fail"><![CDATA[please enable this cache in Studio &gt; Settings &gt; Cache]]></string>
+	<string name="_sys_audit_msg_optimization_warn"><![CDATA[installing PHP accelerator will speed-up file cache]]></string>
+	<string name="_sys_audit_msg_x_based_cache_engine"><![CDATA[ ({0} based cache engine)]]></string>
+	<string name="_sys_audit_msg_ffmpeg"><![CDATA[<pre class="code">{0}</pre>if you don't know if output is correct then <a href="#manual_audit">manual server audit</a> may be required.]]></string>
+	<string name="_sys_audit_msg_hardware_requirements"><![CDATA[Hardware requirements can not be determined automatically - <a href="#manual_audit">manual server audit</a> may be required.]]></string>
+	<string name="_sys_audit_msg_mail_send_failed"><![CDATA[mail send failed]]></string>
+	<string name="_sys_audit_msg_mail_sending"><![CDATA[<span id="bx-sys-adm-audit-test-email"><a href="javascript:void(0);" onclick="bx_sys_adm_audit_test_email()">click here</a> to send test email</span>]]></string>
+	<string name="_sys_audit_msg_mail_sent"><![CDATA[test mail was send, please check {0} mailbox]]></string>
+	<string name="_sys_audit_msg_manual_audit"><![CDATA[<p>
+Some things can not be determined automatically, manual server audit is required to check it. 
+If you don't know how to do it by yourself you can submit <a target="_blank" href="mailto:support@una.io?subject=Server Audit Request">Server Audit Request</a>.
+</p>]]></string>
+	<string name="_sys_audit_msg_must_be"><![CDATA[must be {0} {1}]]></string>
+	<string name="_sys_audit_msg_optimization_apache_module"><![CDATA[To apply this optimization you need to have <b>{0}</b> - {1}]]></string>
+	<string name="_sys_audit_msg_permissions"><![CDATA[please <a href="javascript:void(0);" onclick="oBxDolStudioDashboard.permissions()">click here</a> to find out if permissions are correct.]]></string>
+	<string name="_sys_audit_msg_php_accelerator_missing"><![CDATA[The script can be much faster if you install some PHP accelerator]]></string>
+	<string name="_sys_audit_msg_php_setup_inefficient"><![CDATA[your PHP setup maybe very inefficient, <a href="javascript:void(0)" onclick="bx_sys_adm_audit_phpinfo()">please check it for sure</a> and try to switch to mod_php, apache dso module or FastCGI]]></string>
+	<string name="_sys_audit_msg_serverside_compression"><![CDATA[
+can be checked <a href="#manual_audit">manually</a> or in "Page Speed" tool build-in into browser.<br />
+If it is not enabled then please consider implement this optimization, since it improve perceived site speed and save the bandwidth, refer to <a href="http://www.boonex.com/trac/dolphin/wiki/HostingServerSetupRecommendations#Serversidecontentcompression">this tutorial</a> on how to do this.<br />{0}]]></string>
+	<string name="_sys_audit_msg_should_be"><![CDATA[should be {0} {1}]]></string>
+	<string name="_sys_audit_msg_userside_caching"><![CDATA[
+<a href="{0}">click here to check it in Google Page Speed</a><br />
+If it is not enabled then please consider implement this optimization, since it improve perceived site speed and save the bandwidth, refer to <a target="_blank" href="http://www.boonex.com/trac/dolphin/wiki/HostingServerSetupRecommendations#Usersidecachingforstaticcontent">this tutorial</a> on how to do this.<br />{1}]]></string>
+	<string name="_sys_audit_msg_value_checking_failed"><![CDATA[value checking failed]]></string>
+	<string name="_sys_audit_msg_version_is_incompatible"><![CDATA[your version is incompatible with UNA, must be at least {0}]]></string>
+	<string name="_sys_audit_msg_version_is_outdated"><![CDATA[your version is outdated, upgrade to the latest {0} maybe required]]></string>
+	<string name="_sys_audit_permissions"><![CDATA[Files and folders permissions]]></string>
+	<string name="_sys_audit_php_accelerator"><![CDATA[PHP accelerator]]></string>
+	<string name="_sys_audit_php_setup"><![CDATA[PHP setup]]></string>
+	<string name="_sys_audit_section_hardware"><![CDATA[Hardware]]></string>
+	<string name="_sys_audit_section_os"><![CDATA[OS]]></string>
+	<string name="_sys_audit_section_webserver"><![CDATA[Web-server]]></string>
+	<string name="_sys_audit_serverside_compression"><![CDATA[Server-side content compression]]></string>
+	<string name="_sys_audit_title_fail"><![CDATA[FAIL]]></string>
+	<string name="_sys_audit_title_ok"><![CDATA[OK]]></string>
+	<string name="_sys_audit_title_undef"><![CDATA[UNDEFINED]]></string>
+	<string name="_sys_audit_title_warn"><![CDATA[WARNING]]></string>
+	<string name="_sys_audit_userside_caching"><![CDATA[User-side caching for static content]]></string>
+	<string name="_sys_audit_version"><![CDATA[version]]></string>
+	<string name="_sys_audit_version_script"><![CDATA[UNA version]]></string>
+	<string name="_sys_block_type_html"><![CDATA[html]]></string>
+	<string name="_sys_block_type_image"><![CDATA[image]]></string>
+	<string name="_sys_block_type_lang"><![CDATA[lang]]></string>
+	<string name="_sys_block_type_menu"><![CDATA[menu]]></string>
+	<string name="_sys_block_type_raw"><![CDATA[raw]]></string>
+	<string name="_sys_block_type_rss"><![CDATA[rss]]></string>
+	<string name="_sys_block_type_service"><![CDATA[service]]></string>
+	<string name="_sys_block_types_custom"><![CDATA[Custom]]></string>
+	<string name="_sys_block_types_skeletons"><![CDATA[Skeletons]]></string>
+	<string name="_sys_block_types_system"><![CDATA[System]]></string>
+  
+  <string name="_sys_cmts_administration_grid_column_title_adm_cmt_text"><![CDATA[Text]]></string>
+  <string name="_sys_cmts_administration_grid_column_title_adm_cmt_time"><![CDATA[Added]]></string>
+  <string name="_sys_cmts_administration_grid_column_title_adm_cmt_author_id"><![CDATA[Author]]></string>
+  <string name="_sys_cmts_administration_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+  
+  <string name="_sys_chart_growth_object"><![CDATA[Display]]></string>
+	<string name="_sys_chart_growth_date_from"><![CDATA[From]]></string>
+	<string name="_sys_chart_growth_date_to"><![CDATA[To]]></string>
+	<string name="_sys_chart_accounts_growth"><![CDATA[Accounts: Growth]]></string>
+	<string name="_sys_chart_accounts_growth_speed"><![CDATA[Accounts: Growth Speed]]></string>
+	<string name="_sys_close"><![CDATA[Close]]></string>
+        <string name="_sys_confirm"><![CDATA[Confirm]]></string>
+        <string name="_sys_confirmed"><![CDATA[Confirmed]]></string>
+	<string name="_sys_conn_err_connection_already_exists"><![CDATA[Connection already exists]]></string>
+	<string name="_sys_conn_err_connection_does_not_exists"><![CDATA[Connection doesn't exist]]></string>
+	<string name="_sys_conn_err_connection_is_awaiting_confirmation"><![CDATA[Connection request is awaiting confirmation]]></string>
+	<string name="_sys_conn_err_input_data_is_not_defined"><![CDATA[Input data isn't defined]]></string>
+    <string name="_sys_conn_msg_success"><![CDATA[Operation has beed successfully completed]]></string>
+
+    <string name="_sys_connect_information"><![CDATA[Configuration info]]></string>
+    <string name="_sys_connect_error_join_unavailable"><![CDATA[Sorry but join is unavailable now. Please try again later.]]></string>
+    <string name="_sys_connect_profile_error_info"><![CDATA[Can't define your profile information]]></string>
+    <string name="_sys_connect_state_invalid"><![CDATA[State parameter isn't matching]]></string>
+    <string name="_sys_connect_adm_stg_cpt_category_general"><![CDATA[General]]></string>
+    <string name="_sys_connect_option_redirect"><![CDATA[Redirect page after first sign in]]></string>
+    <string name="_sys_connect_option_module"><![CDATA[Module to create profile in]]></string>
+    <string name="_sys_connect_option_confirm_email"><![CDATA[Always confirm emails when joined using this module]]></string>
+    <string name="_sys_connect_option_approve"><![CDATA[Always approve profiles when joined using this module]]></string>
+    <string name="_sys_connect_option_privacy"><![CDATA[Default privacy for created profiles]]></string>
+
+	<string name="_sys_currency"><![CDATA[{0}{1}]]></string>
+        <string name="_sys_decline"><![CDATA[Decline]]></string>
+	<string name="_sys_designbox_0"><![CDATA[Content]]></string>
+	<string name="_sys_designbox_1"><![CDATA[Content + Title + Background]]></string>
+	<string name="_sys_designbox_10"><![CDATA[Content + Padding]]></string>
+	<string name="_sys_designbox_11"><![CDATA[Content + Title + Background + Padding]]></string>
+	<string name="_sys_designbox_13"><![CDATA[Content + Background + Padding]]></string>
+	<string name="_sys_designbox_14"><![CDATA[Content + Title + Padding]]></string>
+	<string name="_sys_designbox_2"><![CDATA[Empty box]]></string>
+	<string name="_sys_designbox_3"><![CDATA[Content + Background]]></string>
+	<string name="_sys_designbox_4"><![CDATA[Content + Title]]></string>
+	<string name="_sys_done"><![CDATA[Done]]></string>    
+	<string name="_sys_et_txt_about_us"><![CDATA[About us]]></string>
+	<string name="_sys_et_txt_body_admin_email"><![CDATA[{email_header}
+<p>Message from <a href="{site_url}">{site_name}</a> admin:</p>
+<p> </p>
+<p>{MessageText}</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_comment_replied"><![CDATA[{email_header}
+<p>User {sender_display_name} posted reply to your comment: </p>
+<p> </p>
+<p>{reply_text}</p>
+<p> </p>
+<p>View and reply here: <a href="{page_url}">{page_title}</a>.</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_system_reported"><![CDATA[{email_header}
+<p>New <b>{report_type}</b> report received:</p>
+<p> </p>
+<p>{report_text}</p>
+<p> </p>
+<p><a href="{report_url}">View report</a>.</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_confirmation"><![CDATA[{email_header}
+<p>Hello, {name}.</p>
+<p>Click the link below to verify your email address, please:</p>
+<p> </p>
+<p><a href="{conf_link}">{conf_link}</a></p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_delayed_module_uninstall"><![CDATA[{email_header}
+<p>Module: <b>{Module}</b></p>
+<p>Uninstallation result: {Result}</p>
+<p> </p>
+<p>{Message}</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_forgot"><![CDATA[{email_header}
+<p>Click the link below to reset your password, please:</p>
+<p> </p>
+<p><a href="{forgot_password_url}">Reset my password</a>.</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_mem_changed"><![CDATA[{email_header}
+<p><b>{profile_name}</b> profile membership level is now <b>{membership_level}</b>.</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_mem_expiration"><![CDATA[{email_header}
+<p>Your {membership_name} membership will expire in {expire_days} days (-1 means already expired).</p>
+<p>Click the link below to renew your membership:</p>
+<p> </p>
+<p><a href="{page_url}">Renew my membership</a></p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_password_reset"><![CDATA[{email_header}
+<p>Your new password is:</p>
+<p> </p>
+<p><b>{password}</b></p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_profile_change_status_active"><![CDATA[{email_header}
+<p>Your {site_name} account details:</p>
+<p> </p>
+<p>Name: {account_name}</p>
+<p>Email: {account_email}</p>
+<p>URL: <a href="{site_url}">{site_url}</a></p>
+<p></p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_profile_change_status_pending"><![CDATA[{email_header}
+<p>Your profile is pending review. We will send you the review result shortly.</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_profile_change_status_suspended"><![CDATA[{email_header}
+<p>Your profile is currently suspended.</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_account"><![CDATA[{email_header}
+<p>{account_output}</p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_pruning"><![CDATA[{email_header}
+<p>{pruning_output}</p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_upgrade_failed"><![CDATA[{email_header}
+<p>Upgrade failed due to the following error:</p>
+<p> </p>
+<p>{error_msg}</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_upgrade_modules_failed"><![CDATA[{email_header}
+<p>The following errors appeared during modules upgrade:</p>
+<p> </p>
+<p>{conclusion}</p>
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_upgrade_success"><![CDATA[{email_header}
+<p>Site was successfully upgraded to {new_version}.</p>
+<p>Please go to <b>Studio &gt; Apps Market &gt; Updates</b> to check for modules updates.</p>
+<p> </p>
+{conclusion}
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_upgrade_modules_success"><![CDATA[{email_header}
+<p>The following modules were successfully upgraded.</p>
+<p> </p>
+{conclusion}
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_bg_operation_failed"><![CDATA[{email_header}
+<p>Background operation failed with the following message.</p>
+<p> </p>
+{conclusion}
+<p> </p>
+{email_footer}]]></string>
+	<string name="_sys_et_txt_body_modules_upgrade_success"><![CDATA[<b>{0}</b> module: up to {1} version.<br />]]></string>
+	<string name="_sys_et_txt_body_modules_upgrade_failed"><![CDATA[<b>{0}</b> module: {1}<br />]]></string>
+	<string name="_sys_et_txt_name_system_admin_email"><![CDATA[Message sending from the Admin Panel]]></string>
+	<string name="_sys_et_txt_name_system_comment_replied"><![CDATA[The letter is sent to members whose comment was replied]]></string>
+	<string name="_sys_et_txt_name_system_reported"><![CDATA[New report notification]]></string>
+	<string name="_sys_et_txt_name_system_confirmation"><![CDATA[Profile e-mail confirmation message]]></string>
+	<string name="_sys_et_txt_name_system_delayed_module_uninstall"><![CDATA[Delayed module uninstall notification]]></string>
+	<string name="_sys_et_txt_name_system_forgot"><![CDATA[Reset password message]]></string>
+	<string name="_sys_et_txt_name_system_mem_changed"><![CDATA[The letter is sent to members whose membership level was changed]]></string>
+	<string name="_sys_et_txt_name_system_mem_expiration"><![CDATA[Membership expiration letter sent to members whose membership level expires]]></string>
+	<string name="_sys_et_txt_name_system_password_reset"><![CDATA[New password message]]></string>
+	<string name="_sys_et_txt_name_profile_change_status_active"><![CDATA[Profile status changed to active]]></string>
+	<string name="_sys_et_txt_name_profile_change_status_pending"><![CDATA[Profile status changed to pending]]></string>
+	<string name="_sys_et_txt_name_profile_change_status_suspended"><![CDATA[Profile status changed to suspended]]></string>
+	<string name="_sys_et_txt_name_system_account"><![CDATA[New Accounts]]></string>
+	<string name="_sys_et_txt_name_system_pruning"><![CDATA[Pruning result]]></string>
+	<string name="_sys_et_txt_name_upgrade_failed"><![CDATA[Upgrade failed]]></string>
+	<string name="_sys_et_txt_name_upgrade_modules_failed"><![CDATA[Modules upgrade failed]]></string>
+	<string name="_sys_et_txt_name_upgrade_success"><![CDATA[Site upgrade success]]></string>
+	<string name="_sys_et_txt_name_upgrade_modules_success"><![CDATA[Modules upgrade success]]></string>
+	<string name="_sys_et_txt_name_bg_operation_failed"><![CDATA[Background operation failed]]></string>
+	<string name="_sys_et_txt_subject_admin_email"><![CDATA[Message from <SiteName> Admin: <MessageSubject>]]></string>
+	<string name="_sys_et_txt_subject_comment_replied"><![CDATA[User {sender_display_name} replied to your comment.]]></string>
+	<string name="_sys_et_txt_subject_system_reported"><![CDATA[New report notification]]></string>
+	<string name="_sys_et_txt_subject_confirmation"><![CDATA[Confirm your Email, please. (ACTION REQUIRED)]]></string>
+	<string name="_sys_et_txt_subject_delayed_module_uninstall"><![CDATA[Delayed {Module} module uninstall: {Result}]]></string>
+	<string name="_sys_et_txt_subject_forgot"><![CDATA[Reset your password]]></string>
+	<string name="_sys_et_txt_subject_mem_changed"><![CDATA[Your membership level was changed]]></string>
+	<string name="_sys_et_txt_subject_mem_expiration"><![CDATA[Your membership is about to expire]]></string>
+	<string name="_sys_et_txt_subject_password_reset"><![CDATA[Your new password]]></string>
+	<string name="_sys_et_txt_subject_profile_change_status_active"><![CDATA[Profile activated]]></string>
+	<string name="_sys_et_txt_subject_profile_change_status_pending"><![CDATA[Profile pending review]]></string>
+	<string name="_sys_et_txt_subject_profile_change_status_suspended"><![CDATA[Profile suspended]]></string>
+	<string name="_sys_et_txt_subject_account"><![CDATA[{site_name} {account_count} accounts created yesterday]]></string>
+	<string name="_sys_et_txt_subject_pruning"><![CDATA[{site_name} pruning result]]></string>
+	<string name="_sys_et_txt_subject_upgrade_failed"><![CDATA[{site_name} upgrade failed]]></string>
+	<string name="_sys_et_txt_subject_upgrade_modules_failed"><![CDATA[Modules upgrade failed on {site_name}]]></string>
+	<string name="_sys_et_txt_subject_upgrade_success"><![CDATA[{site_name} upgrade success]]></string>
+	<string name="_sys_et_txt_subject_upgrade_modules_success"><![CDATA[Modules upgrade success on {site_name}]]></string>
+	<string name="_sys_et_txt_subject_bg_operation_failed"><![CDATA[Background operation failed]]></string>
+    <string name="_sys_et_txt_unsubscribe"><![CDATA[Unsubscribe]]></string>
+	<string name="_sys_file_handlers_ms_viewer"><![CDATA[Microsoft Office Viewer]]></string>
+	<string name="_sys_file_handlers_google_viewer"><![CDATA[Google Viewer]]></string>
+	<string name="_sys_file_handlers_images_viewer"><![CDATA[Images Viewer]]></string>
+	<string name="_sys_file_handlers_code_viewer"><![CDATA[Code Viewer]]></string>
+	<string name="_sys_form_account"><![CDATA[Account]]></string>
+	<string name="_sys_form_account_input_agreement"><![CDATA[]]></string>
+	<string name="_sys_form_account_input_agreement_value"><![CDATA[<div class="bx-def-font-small bx-def-font-grayed">By signing up, you agree to the <a href="{0}">Terms of Service</a> and <a href="{1}">Privacy Policy</a>.</div>]]></string>
+	<string name="_sys_form_account_input_captcha"><![CDATA[Security Image]]></string>
+	<string name="_sys_form_account_input_captcha_error"><![CDATA[Security image input failed. Please, try again.]]></string>
+	<string name="_sys_form_account_input_captcha_label_text_image"><![CDATA[Type the text:]]></string>
+	<string name="_sys_form_account_input_captcha_label_text_audio"><![CDATA[Type the text you hear:]]></string>
+	<string name="_sys_form_account_input_captcha_action_refresh"><![CDATA[refresh]]></string>
+	<string name="_sys_form_account_input_captcha_action_title_refresh"><![CDATA[Get another CAPTCHA]]></string>
+	<string name="_sys_form_account_input_captcha_action_audio"><![CDATA[audio]]></string>
+	<string name="_sys_form_account_input_captcha_action_title_audio"><![CDATA[Get an audio CAPTCHA]]></string>
+	<string name="_sys_form_account_input_captcha_action_image"><![CDATA[image]]></string>
+	<string name="_sys_form_account_input_captcha_action_title_image"><![CDATA[Get an image CAPTCHA]]></string>
+	<string name="_sys_form_account_input_captcha_action_help"><![CDATA[help]]></string>
+	<string name="_sys_form_account_input_captcha_action_title_help"><![CDATA[Get Help]]></string>
+	<string name="_sys_form_account_input_delete_confirm"><![CDATA[I'm sure that I want to delete the account with content.]]></string>
+	<string name="_sys_form_account_input_delete_confirm_error"><![CDATA[Please check this checkbox if you really want to delete your account and your content.]]></string>
+	<string name="_sys_form_account_input_delete_confirm_info"><![CDATA[This action can not be undone.]]></string>
+	<string name="_sys_form_account_input_email"><![CDATA[Email]]></string>
+	<string name="_sys_form_account_input_email_error"><![CDATA[Email is not valid]]></string>
+	<string name="_sys_form_account_input_email_uniq_error"><![CDATA[This email address is already registered. Please, use <a href="{0}">Forgot password</a> to restore access to your account.]]></string>
+	<string name="_sys_form_account_input_email_uniq_error_loggedin"><![CDATA[This email is already used by someone.]]></string>
+	<string name="_sys_form_account_input_name"><![CDATA[Account name]]></string>
+	<string name="_sys_form_account_input_name_error"><![CDATA[This is a required field.]]></string>
+	<string name="_sys_form_account_input_password"><![CDATA[Create a password]]></string>
+	<string name="_sys_form_account_input_password_confirm"><![CDATA[Confirm a password]]></string>
+	<string name="_sys_form_account_input_password_confirm_error"><![CDATA[Password confirmation failed]]></string>
+	<string name="_sys_form_account_input_password_current"><![CDATA[Current Password]]></string>
+	<string name="_sys_form_account_input_password_current_error"><![CDATA[Current password isn't correct, please enter password you are using to login to this site.]]></string>
+	<string name="_sys_form_account_input_password_error"><![CDATA[The password must at least 8 characters long and contain at least 1 uppercase letter, 1 lowercase letter and 1 digit.]]></string>
+	<string name="_sys_form_account_input_receive_news"><![CDATA[Receive Newsletters]]></string>
+	<string name="_sys_form_account_input_receive_updates"><![CDATA[Receive Site Updates]]></string>
+	<string name="_sys_form_account_input_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_checkbox_value_off"><![CDATA[No]]></string>
+	<string name="_sys_form_checkbox_value_on"><![CDATA[Yes]]></string>
+	<string name="_sys_form_comment"><![CDATA[Comment]]></string>
+	<string name="_sys_form_comment_input_caption_cmt_author_id"><![CDATA[Author]]></string>
+	<string name="_sys_form_comment_input_caption_cmt_text"><![CDATA[Text]]></string>
+	<string name="_sys_form_comment_input_caption_system_action"><![CDATA[Action]]></string>
+        <string name="_sys_form_comment_input_caption_system_cmt_author_id"><![CDATA[Author]]></string>
+	<string name="_sys_form_comment_input_caption_system_cmt_id"><![CDATA[Comment ID]]></string>
+	<string name="_sys_form_comment_input_caption_system_cmt_image"><![CDATA[Image]]></string>
+	<string name="_sys_form_comment_input_caption_system_cmt_parent_id"><![CDATA[Parent ID]]></string>
+	<string name="_sys_form_comment_input_caption_system_cmt_submit"><![CDATA[Post]]></string>
+	<string name="_sys_form_comment_input_caption_system_cmt_text"><![CDATA[Text]]></string>
+	<string name="_sys_form_comment_input_caption_system_id"><![CDATA[Object ID]]></string>
+	<string name="_sys_form_comment_input_caption_system_sys"><![CDATA[Object Type]]></string>
+	<string name="_sys_form_comment_input_submit"><![CDATA[Post]]></string>
+	<string name="_sys_form_confirm_email"><![CDATA[Email Confirmation]]></string>
+	<string name="_sys_form_confirm_email_input_caption_system_code"><![CDATA[Verification Code]]></string>
+	<string name="_sys_form_confirm_email_input_caption_system_do_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_confirm_email_input_code"><![CDATA[Verification Code]]></string>
+	<string name="_sys_form_confirm_email_input_code_error"><![CDATA[Verification code is invalid or expired, please login to your account and resend verification email.]]></string>
+	<string name="_sys_form_confirm_email_input_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_confirm_phone"><![CDATA[Phone Confirmation]]></string>
+	<string name="_sys_form_confirm_phone_input_caption_system_phone"><![CDATA[Phone]]></string>
+	<string name="_sys_form_confirm_phone_input_phone"><![CDATA[Phone]]></string>
+        <string name="_sys_form_confirm_phone_input_phone_info"><![CDATA[Enter your phone with country code]]></string>
+	<string name="_sys_form_confirm_phone_input_phone_error_format"><![CDATA[Wrong phone number, allowed digits only and start from '+']]></string>
+	<string name="_sys_form_confirm_phone_input_phone_error_not_unique"><![CDATA[This phone is already used by someone.]]></string>
+	<string name="_sys_form_confirm_phone_input_caption_system_code"><![CDATA[Code]]></string>
+	<string name="_sys_form_confirm_phone_confirmation_input_code"><![CDATA[Code]]></string>
+	<string name="_sys_form_confirm_phone_input_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_confirm_phone_input_caption_system_do_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_confirm_phone_input_sendsms"><![CDATA[Send SMS]]></string>
+	<string name="_sys_form_confirm_phone_input_caption_system_do_sendsms"><![CDATA[Send SMS]]></string>
+	<string name="_sys_form_confirm_phone_input_code_error_empty"><![CDATA[Cannot be empty.]]></string>
+	<string name="_sys_form_confirm_phone_input_code_error_invalid"><![CDATA[Wrong verification code. Please, repeat code or <a href="{0}">change the phone number and repeat from the beginning</a>.]]></string>
+	<string name="_sys_form_account_input_phone_error"><![CDATA[Phone is not valid]]></string>
+	<string name="_sys_form_display_account_create"><![CDATA[Create Account]]></string>
+	<string name="_sys_form_display_account_settings_delete"><![CDATA[Delete Account]]></string>
+	<string name="_sys_form_display_account_settings_email"><![CDATA[Email Settings]]></string>
+	<string name="_sys_form_display_account_settings_info"><![CDATA[Edit Account]]></string>
+	<string name="_sys_form_display_account_settings_password"><![CDATA[Change Password]]></string>
+	<string name="_sys_form_display_comment_edit"><![CDATA[Comment Edit Form]]></string>
+	<string name="_sys_form_display_comment_post"><![CDATA[Comment Post Form]]></string>
+	<string name="_sys_form_display_confirm_email"><![CDATA[Email Confirmation]]></string>
+	<string name="_sys_form_display_confirm_phone_set_phone"><![CDATA[Set phone]]></string>
+	<string name="_sys_form_display_confirm_phone_confirmation"><![CDATA[Phone confirmation]]></string>
+	<string name="_sys_form_display_forgot_password"><![CDATA[Forgot Password]]></string>
+	<string name="_sys_form_display_login"><![CDATA[Log in]]></string>
+	<string name="_sys_form_display_login_step2"><![CDATA[Log in - step 2]]></string>
+	<string name="_sys_form_display_login_step3"><![CDATA[Log in - step 3]]></string>
+	<string name="_sys_form_display_report_post"><![CDATA[Report From Post]]></string>
+	<string name="_sys_form_display_unsubscribe_news"><![CDATA[Unsubscribe From Newsletters]]></string>
+	<string name="_sys_form_display_unsubscribe_updates"><![CDATA[Unsubscribe From Updates]]></string>
+	<string name="_sys_form_forgot_password"><![CDATA[Forgot Password]]></string>
+	<string name="_sys_form_forgot_password_email_not_recognized"><![CDATA[This email doesn't belong to any account. Please make sure that it is typed correctly.]]></string>
+	<string name="_sys_form_forgot_password_phone_not_recognized"><![CDATA[This phone doesn't belong to any account. Please make sure that it is typed correctly.]]></string>
+	<string name="_sys_form_forgot_password_phone_error_format"><![CDATA[Wrong phone number, allowed digits only and start from '+']]></string>
+	<string name="_sys_form_forgot_password_phone_and_email_empty_error"><![CDATA[Please, fill phone or email field]]></string>
+	<string name="_sys_form_forgot_password_input_caption_system_do_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_forgot_password_input_caption_system_email"><![CDATA[Email]]></string>
+	<string name="_sys_form_forgot_password_input_email"><![CDATA[Email]]></string>
+	<string name="_sys_form_forgot_password_input_caption_system_phone"><![CDATA[Phone]]></string>
+	<string name="_sys_form_forgot_password_input_phone"><![CDATA[Phone]]></string>
+	<string name="_sys_form_forgot_password_input_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_input_age"><![CDATA[Age]]></string>
+	<string name="_sys_form_input_sys_location"><![CDATA[Location]]></string>
+	<string name="_sys_form_input_location"><![CDATA[Location]]></string>
+	<string name="_sys_form_input_sys_labels"><![CDATA[Labels]]></string>
+    <string name="_sys_form_input_labels"><![CDATA[Labels]]></string>
+	<string name="_sys_form_input_sys_anonymous"><![CDATA[Post as anonymous]]></string>
+	<string name="_sys_form_input_anonymous"><![CDATA[Post as anonymous]]></string>
+	<string name="_sys_form_login"><![CDATA[Log in]]></string>
+	<string name="_sys_form_login_input_caption_system_agreement"><![CDATA[Agreement]]></string>
+	<string name="_sys_form_login_input_caption_system_captcha"><![CDATA[Captcha]]></string>
+	<string name="_sys_form_login_input_caption_system_checkcode"><![CDATA[Submit]]></string>
+	<string name="_sys_form_login_input_caption_system_code"><![CDATA[Code from SMS]]></string>
+	<string name="_sys_form_login_input_caption_system_back"><![CDATA[<a href="javascript:history.back()">Send new code</a>]]></string>
+	<string name="_sys_form_login_input_caption_system_delete_confirm"><![CDATA[Confirm Delete]]></string>
+	<string name="_sys_form_login_input_caption_system_delete_content"><![CDATA[Delete with Content]]></string>
+	<string name="_sys_form_login_input_caption_system_do_submit"><![CDATA[Sign up]]></string>
+	<string name="_sys_form_login_input_caption_system_email"><![CDATA[Email]]></string>
+	<string name="_sys_form_login_input_caption_system_id"><![CDATA[ID]]></string>
+	<string name="_sys_form_login_input_caption_system_name"><![CDATA[Account name]]></string>
+	<string name="_sys_form_login_input_caption_system_password"><![CDATA[Password]]></string>
+	<string name="_sys_form_login_input_caption_system_password_confirm"><![CDATA[Confirm Password]]></string>
+	<string name="_sys_form_login_input_caption_system_phone"><![CDATA[Phone]]></string>
+	<string name="_sys_form_login_input_caption_system_password_current"><![CDATA[Current Password]]></string>
+	<string name="_sys_form_login_input_caption_system_receive_news"><![CDATA[Receive News]]></string>
+	<string name="_sys_form_login_input_caption_system_receive_updates"><![CDATA[Receive Updates]]></string>
+	<string name="_sys_form_login_input_caption_system_relocate"><![CDATA[Relocate]]></string>
+	<string name="_sys_form_login_input_caption_system_remember_me"><![CDATA[Remember me]]></string>
+	<string name="_sys_form_login_input_caption_system_role"><![CDATA[Role]]></string>
+	<string name="_sys_form_login_input_caption_system_sendsms"><![CDATA[Send SMS]]></string>
+	<string name="_sys_form_login_input_caption_system_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_login_input_caption_system_submit_text"><![CDATA[Submit Text]]></string>
+	<string name="_sys_form_login_input_code"><![CDATA[Code from SMS]]></string>
+	<string name="_sys_form_login_input_back"><![CDATA[<a href="javascript:history.back()">Send new code</a>]]></string>
+	<string name="_sys_form_login_input_checkcode"><![CDATA[Submit]]></string>
+	<string name="_sys_form_login_input_email"><![CDATA[Email]]></string>
+	<string name="_sys_form_login_input_password"><![CDATA[Password]]></string>
+	<string name="_sys_form_login_input_phone"><![CDATA[Phone]]></string>
+        <string name="_sys_form_login_input_phone_info"><![CDATA[Enter your phone with country code]]></string>
+	<string name="_sys_form_login_input_remember_me"><![CDATA[Remember me]]></string>
+	<string name="_sys_form_login_input_sendsms"><![CDATA[Send SMS]]></string>
+	<string name="_sys_form_login_input_submit"><![CDATA[Log in]]></string>
+	<string name="_sys_form_login_input_code_error_empty"><![CDATA[Cannot be empty.]]></string>
+	<string name="_sys_form_login_input_phone_error_format"><![CDATA[Wrong phone number, allowed digits only and start from '+']]></string>
+	<string name="_sys_form_login_input_phone_error_not_unique"><![CDATA[This phone is already used by someone.]]></string>
+	<string name="_sys_form_login_input_code_error_invalid"><![CDATA[Wrong verification code. Please, repeat code or <a href="{0}">change the phone number and repeat from the beginning</a>.]]></string>
+	
+	<string name="_sys_form_paceholder_profiles_suggestions"><![CDATA[Type name here...]]></string>
+	<string name="_sys_form_report"><![CDATA[Report]]></string>
+	<string name="_sys_form_report_input_caption_submit"><![CDATA[Post]]></string>
+	<string name="_sys_form_report_input_caption_text"><![CDATA[Report Text]]></string>
+	<string name="_sys_form_report_input_caption_type"><![CDATA[Report Type]]></string>
+	<string name="_sys_form_report_input_caption_system_action"><![CDATA[Action]]></string>
+	<string name="_sys_form_report_input_caption_system_object_id"><![CDATA[Object ID]]></string>	
+	<string name="_sys_form_report_input_caption_system_id"><![CDATA[Report ID]]></string>
+	<string name="_sys_form_report_input_caption_system_submit"><![CDATA[Post Report]]></string>
+	<string name="_sys_form_report_input_caption_system_text"><![CDATA[Report Text]]></string>
+	<string name="_sys_form_report_input_caption_system_type"><![CDATA[Report Type]]></string>
+	<string name="_sys_form_report_input_caption_system_sys"><![CDATA[Object Type]]></string>
+	<string name="_sys_form_unsubscribe"><![CDATA[Unsubscribe]]></string>
+	<string name="_sys_form_unsubscribe_input_caption_system_code"><![CDATA[Security Code]]></string>
+	<string name="_sys_form_unsubscribe_input_caption_system_do_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_unsubscribe_input_caption_system_id"><![CDATA[Account ID]]></string>
+	<string name="_sys_form_unsubscribe_input_caption_system_receive_news"><![CDATA[Receive Newsletters]]></string>
+	<string name="_sys_form_unsubscribe_input_caption_system_receive_updates"><![CDATA[Receive Site Updates]]></string>
+	<string name="_sys_form_unsubscribe_input_receive_news"><![CDATA[Receive Newsletters]]></string>
+	<string name="_sys_form_unsubscribe_input_receive_updates"><![CDATA[Receive Site Updates]]></string>
+	<string name="_sys_form_unsubscribe_input_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_form_err_not_unique_value"><![CDATA[The field should have unique value]]></string>
+	<string name="_sys_form_txt_select_file"><![CDATA[Select a file]]></string>
+	<string name="_sys_format_size_b"><![CDATA[{0} bytes]]></string>
+	<string name="_sys_format_size_gb"><![CDATA[{0} GB]]></string>
+	<string name="_sys_format_size_kb"><![CDATA[{0} KB]]></string>
+	<string name="_sys_format_size_mb"><![CDATA[{0} MB]]></string>
+	<string name="_sys_format_size_tb"><![CDATA[{0} TB]]></string>
+	<string name="_sys_grid_confirmation"><![CDATA[Are you sure?]]></string>
+	<string name="_sys_grid_delete_failed"><![CDATA[Delete failed]]></string>
+  <string name="_sys_grid_search"><![CDATA[Search...]]></string>
+  <string name="_sys_grid_txt_account_manager"><![CDATA[Redirect to manage account.]]></string>
+	<string name="_sys_inst_conf_desc"><![CDATA[{0}{1}<br />Example: {2}]]></string>
+	<string name="_sys_inst_conf_desc_admin_email"><![CDATA[Admin user e-mail address.]]></string>
+	<string name="_sys_inst_conf_desc_admin_pwd"><![CDATA[Admin user password here.]]></string>
+	<string name="_sys_inst_conf_desc_admin_username"><![CDATA[Admin user name here.]]></string>
+	<string name="_sys_inst_conf_desc_db_host"><![CDATA[Your MySQL database host name here.]]></string>
+	<string name="_sys_inst_conf_desc_db_name"><![CDATA[Your MySQL database name here.]]></string>
+	<string name="_sys_inst_conf_desc_db_port"><![CDATA[Leave blank or specify custom MySQL database host port number.]]></string>
+	<string name="_sys_inst_conf_desc_db_pwd"><![CDATA[Your MySQL database password here.]]></string>
+	<string name="_sys_inst_conf_desc_db_sock"><![CDATA[Leave blank or specify MySQL database socket path.]]></string>
+	<string name="_sys_inst_conf_desc_db_user"><![CDATA[Your MySQL database user name with read/write access.]]></string>
+	<string name="_sys_inst_conf_desc_language"><![CDATA[Language to install by default.]]></string>
+	<string name="_sys_inst_conf_desc_profiles"><![CDATA[Profiles module to install by default.]]></string>
+	<string name="_sys_inst_conf_desc_oauth_key_secret"><![CDATA[<a target="_blank" href="http://www.una.io/page/kands-manage">Get UNA Key & Secret</a>]]></string>
+	<string name="_sys_inst_conf_desc_path_to_binary"><![CDATA[If '{0}' binary doesn't exist, you need to install <a target="_blank" href="http://www.imagemagick.org/">ImageMagick</a>.]]></string>
+	<string name="_sys_inst_conf_desc_root_dir"><![CDATA[Path to directory where UNA files are stored.]]></string>
+	<string name="_sys_inst_conf_desc_site_email"><![CDATA[Email to send site messages from.]]></string>
+	<string name="_sys_inst_conf_desc_site_title"><![CDATA[The name of your site.]]></string>
+	<string name="_sys_inst_conf_desc_site_url"><![CDATA[Your site URL here (slash at the end is required).]]></string>
+	<string name="_sys_inst_conf_desc_template"><![CDATA[Template to install by default.]]></string>
+	<string name="_sys_inst_conf_error"><![CDATA[Please, input valid data here.]]></string>
+	<string name="_sys_inst_conf_field_admin_email"><![CDATA[Admin e-mail]]></string>
+	<string name="_sys_inst_conf_field_admin_pwd"><![CDATA[Admin password]]></string>
+	<string name="_sys_inst_conf_field_admin_username"><![CDATA[Admin user name]]></string>
+	<string name="_sys_inst_conf_field_db_host"><![CDATA[Database host name]]></string>
+	<string name="_sys_inst_conf_field_db_name"><![CDATA[Database name]]></string>
+	<string name="_sys_inst_conf_field_db_port"><![CDATA[Database host port number]]></string>
+	<string name="_sys_inst_conf_field_db_pwd"><![CDATA[Database password]]></string>
+	<string name="_sys_inst_conf_field_db_sock"><![CDATA[Database socket path]]></string>
+	<string name="_sys_inst_conf_field_db_user"><![CDATA[Database user]]></string>
+	<string name="_sys_inst_conf_field_language"><![CDATA[Language]]></string>
+	<string name="_sys_inst_conf_field_profiles"><![CDATA[Profiles]]></string>
+	<string name="_sys_inst_conf_field_oauth_key"><![CDATA[UNA key]]></string>
+	<string name="_sys_inst_conf_field_oauth_secret"><![CDATA[UNA secret]]></string>
+	<string name="_sys_inst_conf_field_path_to_binary"><![CDATA[Path to '{0}' binary]]></string>
+	<string name="_sys_inst_conf_field_root_dir"><![CDATA[Site directory]]></string>
+	<string name="_sys_inst_conf_field_site_email"><![CDATA[Site e-mail]]></string>
+	<string name="_sys_inst_conf_field_site_title"><![CDATA[Site title]]></string>
+	<string name="_sys_inst_conf_field_site_url"><![CDATA[Site URL]]></string>
+	<string name="_sys_inst_conf_field_template"><![CDATA[Template]]></string>
+	<string name="_sys_inst_conf_found"><![CDATA[<span style="color:green">Found</span>]]></string>
+	<string name="_sys_inst_conf_no_example"><![CDATA[no example]]></string>
+	<string name="_sys_inst_conf_not_found"><![CDATA[<span style="color:red">Not found</span>]]></string>
+	<string name="_sys_inst_conf_section_db_config"><![CDATA[DB config]]></string>
+	<string name="_sys_inst_conf_section_link_with_market"><![CDATA[Link with UNA market]]></string>
+	<string name="_sys_inst_conf_section_modules"><![CDATA[Modules]]></string>
+	<string name="_sys_inst_conf_section_paths"><![CDATA[Site paths]]></string>
+	<string name="_sys_inst_conf_section_site_info"><![CDATA[Site info]]></string>
+	<string name="_sys_inst_continue"><![CDATA[Continue]]></string>
+	<string name="_sys_inst_finish"><![CDATA[Installation has been successfully completed]]></string>
+	<string name="_sys_inst_help_finish"><![CDATA[Help with cron jobs]]></string>
+	<string name="_sys_inst_help_permissions"><![CDATA[Setting permissions help]]></string>
+	<string name="_sys_inst_help_site_config"><![CDATA[Creating database help]]></string>
+	<string name="_sys_inst_hosting_fails"><![CDATA[Your hosting doesn't meet minimal requirements:]]></string>
+	<string name="_sys_inst_hosting_warnings"><![CDATA[Your hosting setup has some warnings, for the complete report go to <a href="?action=audit">server audit page</a>.]]></string>
+	<string name="_sys_inst_msg_admin_account_not_found"><![CDATA[Admin account wasn't found by email - {0}]]></string>
+	<string name="_sys_inst_msg_db_err_connect"><![CDATA[Database connect failed]]></string>
+	<string name="_sys_inst_msg_db_err_select"><![CDATA[Database select failed]]></string>
+	<string name="_sys_inst_msg_file_read_failed"><![CDATA[File read failed: {0}]]></string>
+	<string name="_sys_inst_msg_file_write_failed"><![CDATA[File write failed: {0}]]></string>
+	<string name="_sys_inst_msg_finish"><![CDATA[But some additional manual steps are required:]]></string>
+	<string name="_sys_inst_msg_finish_cron_jobs"><![CDATA[Setup the following cron jobs command:]]></string>
+	<string name="_sys_inst_msg_finish_delete_install_folder"><![CDATA[Remove <b>/install/</b> folder from the script root folder.]]></string>
+	<string name="_sys_inst_msg_finish_goto_studio"><![CDATA[<a href="{0}studio/">Go to Studio</a> to add additional modules and customize the site.]]></string>
+	<string name="_sys_inst_msg_form_error"><![CDATA[Please fix form errors.]]></string>
+	<string name="_sys_inst_msg_module_error"><![CDATA[{0} - {1}]]></string>
+	<string name="_sys_inst_msg_permissions_wrong"><![CDATA[Some files or folders rights aren't correct, please set necessary permissions then click "Continue".]]></string>
+	<string name="_sys_inst_msg_remove_install"><![CDATA[Please, remove INSTALL directory from your server and reload this page to activate your site.<br />After deletion you can safely go <a href="../studio/">to the site Studio</a> to add additional modules and customize the site.]]></string>
+	<string name="_sys_inst_msg_script_isnt_installed"><![CDATA[Script isn't installed]]></string>
+	<string name="_sys_inst_refresh"><![CDATA[Refresh]]></string>
+	<string name="_sys_inst_server_audit"><![CDATA[Server audit]]></string>
+	<string name="_sys_inst_site_config"><![CDATA[Site configuration]]></string>
+	<string name="_sys_inst_start_installation"><![CDATA[Start installation]]></string>
+	<string name="_sys_inst_title"><![CDATA[UNA {0} Installation]]></string>
+	<string name="_sys_layout_1_column"><![CDATA[1 column]]></string>
+	<string name="_sys_layout_2_columns"><![CDATA[2 columns]]></string>
+	<string name="_sys_layout_3_columns"><![CDATA[3 columns]]></string>
+	<string name="_sys_layout_bar_left"><![CDATA[With left bar]]></string>
+	<string name="_sys_layout_bar_content_bar"><![CDATA[With left and right bars]]></string>
+	<string name="_sys_layout_bar_right"><![CDATA[With right bar]]></string>
+	<string name="_sys_layout_bottom_area_2_columns"><![CDATA[Bottom area with 2 columns at top]]></string>
+	<string name="_sys_layout_top_area_2_columns"><![CDATA[Top area with 2 columns]]></string>
+	<string name="_sys_layout_top_area_3_columns"><![CDATA[Top area with 3 columns]]></string>
+	<string name="_sys_layout_top_area_bar_left"><![CDATA[Top area with left bar]]></string>
+	<string name="_sys_layout_top_area_bar_content_bar"><![CDATA[Top area with left and right bars]]></string>
+	<string name="_sys_layout_top_area_bar_right"><![CDATA[Top area with right bar]]></string>
+	<string name="_sys_layout_topbottom_area_2_columns"><![CDATA[Top&bottom areas with 2 columns in the middle]]></string>
+	<string name="_sys_layout_topbottom_area_bar_left"><![CDATA[Top&bottom areas with left bar in the middle]]></string>
+	<string name="_sys_layout_topbottom_area_bar_right"><![CDATA[Top&bottom areas with right bar in the middle]]></string>	
+	<string name="_sys_loading"><![CDATA[Loading...]]></string>
+	<string name="_sys_location_country"><![CDATA[<i class="sys-icon location-arrow"></i> {0}]]></string>
+	<string name="_sys_location_country_city"><![CDATA[<i class="sys-icon location-arrow"></i> {2}, {1}, {0}]]></string>
+    <string name="_sys_location_country_city_street"><![CDATA[<i class="sys-icon location-arrow"></i> {4} {3}, {2}, {1}, {0} ]]></string>
+	<string name="_sys_location_determining"><![CDATA[Determining location...]]></string>
+	<string name="_sys_location_geolocation_not_supported_by_browser"><![CDATA[Geolocation is not supported by this browser]]></string>
+	<string name="_sys_location_undefined"><![CDATA[Location off]]></string>
+	<string name="_sys_menu_item_title_about"><![CDATA[About]]></string>
+        <string name="_sys_menu_item_title_copyright"><![CDATA[Copyright]]></string>
+	<string name="_sys_menu_item_title_privacy"><![CDATA[Privacy]]></string>
+	<string name="_sys_menu_item_title_search"><![CDATA[Search]]></string>
+	<string name="_sys_menu_item_title_switch_language"><![CDATA[Language]]></string>
+	<string name="_sys_menu_item_title_switch_language_mask"><![CDATA[{1} {0}]]></string>
+	<string name="_sys_menu_item_title_switch_template"><![CDATA[Design]]></string>
+	<string name="_sys_menu_item_title_switch_template_mask"><![CDATA[{0}]]></string>
+	<string name="_sys_menu_item_title_terms"><![CDATA[Terms]]></string>
+	<string name="_sys_menu_item_title_account_menu"><![CDATA[{member_display_name}]]></string>
+	<string name="_sys_menu_item_title_account_profile_context"><![CDATA[Profiles]]></string>
+	<string name="_sys_menu_item_title_account_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_sys_menu_item_title_account_dashboard_administration"><![CDATA[Administration]]></string>
+	<string name="_sys_menu_item_title_account_settings"><![CDATA[Settings]]></string>
+	<string name="_sys_menu_item_title_account_settings_delete"><![CDATA[Delete]]></string>
+	<string name="_sys_menu_item_title_account_settings_email"><![CDATA[Email]]></string>
+	<string name="_sys_menu_item_title_account_settings_info"><![CDATA[Account]]></string>
+	<string name="_sys_menu_item_title_account_settings_pwd"><![CDATA[Password]]></string>
+	<string name="_sys_menu_item_title_add_content"><![CDATA[Add...]]></string>
+	<string name="_sys_menu_item_title_cart"><![CDATA[Shopping Cart]]></string>
+  <string name="_sys_menu_item_title_cmts_administration"><![CDATA[Comments]]></string>
+	<string name="_sys_menu_item_title_cmts_item_delete"><![CDATA[Delete]]></string>
+	<string name="_sys_menu_item_title_cmts_item_edit"><![CDATA[Edit]]></string>
+	<string name="_sys_menu_item_title_cmts_item_reply"><![CDATA[]]></string>
+	<string name="_sys_menu_item_title_cmts_item_score"><![CDATA[]]></string>
+	<string name="_sys_menu_item_title_cmts_item_vote"><![CDATA[]]></string>
+	<string name="_sys_menu_item_title_cmts_item_more"><![CDATA[]]></string>
+	<string name="_sys_menu_item_title_dashboard"><![CDATA[Dash]]></string>
+	<string name="_sys_menu_item_title_home"><![CDATA[Home]]></string>
+	<string name="_sys_menu_item_title_logout"><![CDATA[Sign out]]></string>
+	<string name="_sys_menu_item_title_more"><![CDATA[More]]></string>
+	<string name="_sys_menu_item_title_orders"><![CDATA[Orders]]></string>
+	<string name="_sys_menu_item_title_profile"><![CDATA[Profile]]></string>
+	<string name="_sys_menu_item_title_set_acl_level"><![CDATA[Set membership]]></string>
+	<string name="_sys_menu_item_title_studio"><![CDATA[Studio]]></string>
+	<string name="_sys_menu_item_title_subscriptions"><![CDATA[Subscriptions]]></string>
+	<string name="_sys_menu_item_title_social_sharing_facebook"><![CDATA[Share in Facebook]]></string>
+    <string name="_sys_menu_item_title_social_sharing_twitter"><![CDATA[Share in Twitter]]></string>
+    <string name="_sys_menu_item_title_social_sharing_pinterest"><![CDATA[Share in Pinterest]]></string>
+    <string name="_sys_menu_item_title_sm_author"><![CDATA[Author]]></string>
+    <string name="_sys_menu_item_title_sm_date"><![CDATA[Date]]></string>
+    <string name="_sys_menu_item_title_sm_category"><![CDATA[Category]]></string>
+    <string name="_sys_menu_item_title_sm_tags"><![CDATA[Tags]]></string>
+    <string name="_sys_menu_item_title_sm_views"><![CDATA[Views]]></string>
+    <string name="_sys_menu_item_title_sm_votes"><![CDATA[Votes]]></string>
+    <string name="_sys_menu_item_title_sm_rating"><![CDATA[Rating]]></string>
+    <string name="_sys_menu_item_title_sm_comments"><![CDATA[Comments]]></string>
+    <string name="_sys_menu_item_title_sm_actions"><![CDATA[Actions]]></string>
+    <string name="_sys_menu_item_title_sm_befriend"><![CDATA[Add friend]]></string>
+    <string name="_sys_menu_item_title_sm_befriend_confirm"><![CDATA[Accept friend request]]></string>
+    <string name="_sys_menu_item_title_sm_unfriend"><![CDATA[Remove friend]]></string>
+    <string name="_sys_menu_item_title_sm_unfriend_cancel"><![CDATA[Cancel friend request]]></string>
+    <string name="_sys_menu_item_title_sm_unfriend_reject"><![CDATA[Reject friend request]]></string>
+    <string name="_sys_menu_item_title_sm_join"><![CDATA[Join]]></string>
+    <string name="_sys_menu_item_title_sm_join_confirm"><![CDATA[Accept join request]]></string>
+    <string name="_sys_menu_item_title_sm_leave"><![CDATA[Leave]]></string>
+    <string name="_sys_menu_item_title_sm_leave_cancel"><![CDATA[Cancel join request]]></string>
+    <string name="_sys_menu_item_title_sm_leave_reject"><![CDATA[Reject join request]]></string>
+    <string name="_sys_menu_item_title_sm_nl"><![CDATA[New line]]></string>
+    <string name="_sys_menu_item_title_sm_subscribe"><![CDATA[Follow]]></string>
+    <string name="_sys_menu_item_title_sm_unsubscribe"><![CDATA[Unfollow]]></string>
+    <string name="_sys_menu_item_title_sm_friends"><![CDATA[{0} friends]]></string>
+    <string name="_sys_menu_item_title_sm_members"><![CDATA[{0} members]]></string>
+    <string name="_sys_menu_item_title_sm_membership"><![CDATA[Membership]]></string>
+    <string name="_sys_menu_item_title_sm_subscribers"><![CDATA[{0} followers]]></string>
+    <string name="_sys_menu_item_title_sm_country"><![CDATA[Country]]></string>
+    <string name="_sys_menu_item_title_sm_country_city"><![CDATA[Country and City]]></string>
+	<string name="_sys_menu_item_title_system_about"><![CDATA[About]]></string>
+        <string name="_sys_menu_item_title_system_copyright"><![CDATA[Copyright]]></string>
+	<string name="_sys_menu_item_title_system_privacy"><![CDATA[Privacy]]></string>
+	<string name="_sys_menu_item_title_system_switch_language"><![CDATA[Language]]></string>
+	<string name="_sys_menu_item_title_system_switch_template"><![CDATA[Template]]></string>
+	<string name="_sys_menu_item_title_system_terms"><![CDATA[Terms]]></string>
+	<string name="_sys_menu_item_title_system_account_menu"><![CDATA[Account]]></string>
+	<string name="_sys_menu_item_title_system_account_profile_context"><![CDATA[Profiles]]></string>
+	<string name="_sys_menu_item_title_system_account_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_sys_menu_item_title_system_account_dashboard_administration"><![CDATA[Administration]]></string>
+	<string name="_sys_menu_item_title_system_account_settings"><![CDATA[Settings]]></string>
+	<string name="_sys_menu_item_title_system_account_settings_delete"><![CDATA[Delete]]></string>
+	<string name="_sys_menu_item_title_system_account_settings_email"><![CDATA[Email]]></string>
+	<string name="_sys_menu_item_title_system_account_settings_info"><![CDATA[Account]]></string>
+	<string name="_sys_menu_item_title_system_account_settings_pwd"><![CDATA[Password]]></string>
+	<string name="_sys_menu_item_title_system_add_content"><![CDATA[Add Content]]></string>
+	<string name="_sys_menu_item_title_system_cart"><![CDATA[Shopping Cart]]></string>
+  <string name="_sys_menu_item_title_system_cmts_administration"><![CDATA[Comments]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_delete"><![CDATA[Delete]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_edit"><![CDATA[Edit]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_reply"><![CDATA[Reply]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_report"><![CDATA[Report]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_score"><![CDATA[Score]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_vote"><![CDATA[Plus]]></string>
+	<string name="_sys_menu_item_title_system_cmts_item_more"><![CDATA[More]]></string>
+	<string name="_sys_menu_item_title_system_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_sys_menu_item_title_system_home"><![CDATA[Home]]></string>
+	<string name="_sys_menu_item_title_system_login"><![CDATA[Log in]]></string>
+	<string name="_sys_menu_item_title_system_logout"><![CDATA[Log out]]></string>
+	<string name="_sys_menu_item_title_system_main_menu"><![CDATA[Main Menu]]></string>
+	<string name="_sys_menu_item_title_system_more"><![CDATA[More]]></string>
+	<string name="_sys_menu_item_title_system_orders"><![CDATA[Orders]]></string>
+	<string name="_sys_menu_item_title_system_powered_by"><![CDATA[Powered By]]></string>
+	<string name="_sys_menu_item_title_system_profile"><![CDATA[Profile]]></string>
+	<string name="_sys_menu_item_title_system_search"><![CDATA[Search]]></string>
+	<string name="_sys_menu_item_title_system_set_acl_level"><![CDATA[Set membership]]></string>
+	<string name="_sys_menu_item_title_system_studio"><![CDATA[Studio]]></string>
+	<string name="_sys_menu_item_title_system_subscriptions"><![CDATA[Subscriptions]]></string>
+        <string name="_sys_menu_title_view_actions"><![CDATA[View Actions]]></string>
+        <string name="_sys_menu_set_title_view_actions"><![CDATA[View Actions]]></string>
+        <string name="_sys_menu_item_title_system_va_comment"><![CDATA[Comment]]></string>
+        <string name="_sys_menu_item_title_system_va_view"><![CDATA[View]]></string>
+        <string name="_sys_menu_item_title_system_va_vote"><![CDATA[Vote (for)]]></string>
+        <string name="_sys_menu_item_title_system_va_score"><![CDATA[Vote (for/against)]]></string>
+        <string name="_sys_menu_item_title_system_va_favorite"><![CDATA[Favorite]]></string>
+        <string name="_sys_menu_item_title_system_va_feature"><![CDATA[Feature]]></string>
+        <string name="_sys_menu_item_title_system_va_reaction"><![CDATA[Reaction]]></string>
+        <string name="_sys_menu_item_title_system_va_repost"><![CDATA[Repost]]></string>
+        <string name="_sys_menu_item_title_system_va_report"><![CDATA[Report]]></string>
+        <string name="_sys_menu_item_title_system_va_more_auto"><![CDATA[More]]></string>
+        <string name="_sys_menu_item_title_va_more_auto"><![CDATA[]]></string>
+	<string name="_sys_menu_item_title_system_social_sharing_facebook"><![CDATA[Share in Facebook]]></string>
+    <string name="_sys_menu_item_title_system_social_sharing_twitter"><![CDATA[Share in Twitter]]></string>
+    <string name="_sys_menu_item_title_system_social_sharing_pinterest"><![CDATA[Share in Pinterest]]></string>
+    <string name="_sys_menu_item_title_system_sm_author"><![CDATA[Author]]></string>
+    <string name="_sys_menu_item_title_system_sm_date"><![CDATA[Date]]></string>
+    <string name="_sys_menu_item_title_system_sm_category"><![CDATA[Category]]></string>
+    <string name="_sys_menu_item_title_system_sm_tags"><![CDATA[Tags]]></string>
+    <string name="_sys_menu_item_title_system_sm_views"><![CDATA[Views]]></string>
+    <string name="_sys_menu_item_title_system_sm_votes"><![CDATA[Votes]]></string>
+    <string name="_sys_menu_item_title_system_sm_rating"><![CDATA[Rating]]></string>
+    <string name="_sys_menu_item_title_system_sm_comments"><![CDATA[Comments]]></string>
+    <string name="_sys_menu_item_title_system_sm_actions"><![CDATA[Actions]]></string>
+    <string name="_sys_menu_item_title_system_sm_befriend"><![CDATA[Add Friend]]></string>
+    <string name="_sys_menu_item_title_system_sm_unfriend"><![CDATA[Remove Friend]]></string>
+    <string name="_sys_menu_item_title_system_sm_join"><![CDATA[Join]]></string>
+    <string name="_sys_menu_item_title_system_sm_leave"><![CDATA[Leave]]></string>
+    <string name="_sys_menu_item_title_system_sm_nl"><![CDATA[New Line]]></string>
+    <string name="_sys_menu_item_title_system_sm_subscribe"><![CDATA[Follow]]></string>
+    <string name="_sys_menu_item_title_system_sm_friends"><![CDATA[Friends]]></string>
+    <string name="_sys_menu_item_title_system_sm_members"><![CDATA[Members]]></string>
+    <string name="_sys_menu_item_title_system_sm_membership"><![CDATA[Membership]]></string>
+    <string name="_sys_menu_item_title_system_sm_subscribers"><![CDATA[Followers]]></string>
+    <string name="_sys_menu_item_title_system_sm_unsubscribe"><![CDATA[Unfollow]]></string>
+    <string name="_sys_menu_item_title_system_sm_country"><![CDATA[Country]]></string>
+    <string name="_sys_menu_item_title_system_sm_country_city"><![CDATA[Country and City]]></string>
+	<string name="_sys_menu_set_title_account_dashboard"><![CDATA[Account Dashboard]]></string>
+	<string name="_sys_menu_set_title_account_dashboard_manage_tools"><![CDATA[Account Dashboard Manage Tools]]></string>
+	<string name="_sys_menu_set_title_account_settings"><![CDATA[Account Settings]]></string>
+	<string name="_sys_menu_set_title_account_settings_more"><![CDATA[Account Settings More]]></string>
+	<string name="_sys_menu_set_title_account_notifications"><![CDATA[Notifications]]></string>
+	<string name="_sys_menu_set_title_add_content"><![CDATA[Add Content]]></string>
+	<string name="_sys_menu_set_title_add_profile"><![CDATA[Add Profile]]></string>
+	<string name="_sys_menu_set_title_cmts_item_actions"><![CDATA[Comment Actions]]></string>
+	<string name="_sys_menu_set_title_cmts_item_manage"><![CDATA[Manage Comment]]></string>
+        <string name="_sys_menu_set_title_cmts_item_meta"><![CDATA[Comment Meta Info]]></string>
+	<string name="_sys_menu_set_title_switch_language"><![CDATA[Switch Language]]></string>
+	<string name="_sys_menu_set_title_switch_template"><![CDATA[Switch Template]]></string>
+	<string name="_sys_menu_set_title_sys_social_sharing"><![CDATA[Social Sharing]]></string>
+	<string name="_sys_menu_set_title_footer"><![CDATA[Footer]]></string>
+	<string name="_sys_menu_set_title_profile_create_links"><![CDATA[Create Profile Links]]></string>
+	<string name="_sys_menu_set_title_profile_stats"><![CDATA[Profile Stats]]></string>
+	<string name="_sys_menu_set_title_site"><![CDATA[Site]]></string>
+	<string name="_sys_menu_set_title_homepage"><![CDATA[Content modules]]></string>
+	<string name="_sys_menu_set_title_toolbar_member"><![CDATA[Toolbar Member]]></string>
+	<string name="_sys_menu_set_title_toolbar_site"><![CDATA[Toolbar Site]]></string>
+	<string name="_sys_menu_set_title_snippet_meta"><![CDATA[Snippet Meta Info]]></string>
+	<string name="_sys_menu_template_title_buttons_hor"><![CDATA[Horizontal Buttons]]></string>
+        <string name="_sys_menu_template_title_buttons_icon_hor"><![CDATA[Horizontal Buttons (icons only)]]></string>
+	<string name="_sys_menu_template_title_buttons_ver"><![CDATA[Vertical Buttons]]></string>
+	<string name="_sys_menu_template_title_floating_blocks"><![CDATA[Floating Blocks]]></string>
+	<string name="_sys_menu_template_title_floating_blocks_wide"><![CDATA[Wide Floating Blocks with Notifications]]></string>
+	<string name="_sys_menu_template_title_floating_blocks_big"><![CDATA[Floating Blocks Big]]></string>
+	<string name="_sys_menu_template_title_floating_blocks_dash"><![CDATA[Floating Blocks with icons & captions]]></string>
+	<string name="_sys_menu_template_title_footer"><![CDATA[Footer Links]]></string>
+	<string name="_sys_menu_template_title_hor"><![CDATA[Horizontal Links]]></string>
+	<string name="_sys_menu_template_title_icon_buttons_hor"><![CDATA[Horizontal Icon Buttons]]></string>
+	<string name="_sys_menu_template_title_inline"><![CDATA[Inline]]></string>
+	<string name="_sys_menu_template_title_inline_sbtn"><![CDATA[Inline ('special' buttons)]]></string>
+	<string name="_sys_menu_template_title_interactive"><![CDATA[Interactive Horizontal Links]]></string>
+	<string name="_sys_menu_template_title_interactive_vertical"><![CDATA[Interactive Vertical Links]]></string>
+	<string name="_sys_menu_template_title_empty"><![CDATA[Empty Menu]]></string>
+	<string name="_sys_menu_template_title_main_submenu"><![CDATA[Site Navigation Submenu]]></string>
+	<string name="_sys_menu_template_title_toolbar"><![CDATA[Toolbar Buttons]]></string>
+	<string name="_sys_menu_template_title_ver"><![CDATA[Vertical Links]]></string>
+	<string name="_sys_menu_template_title_ver_lite"><![CDATA[Vertical Links (lite)]]></string>
+	<string name="_sys_menu_template_title_account_notifications"><![CDATA[Account notifications]]></string>
+	<string name="_sys_menu_template_title_account_popup"><![CDATA[Account popup]]></string>
+	<string name="_sys_menu_template_title_custom_hor"><![CDATA[Horizontal menu with custom items]]></string>
+	<string name="_sys_menu_template_title_custom_ver"><![CDATA[Vertical menu with custom items]]></string>
+	<string name="_sys_menu_template_title_profile_stats"><![CDATA[Profile Stats Menu]]></string>
+	<string name="_sys_menu_title_account_dashboard"><![CDATA[Account Dashboard Menu]]></string>
+	<string name="_sys_menu_title_account_dashboard_manage_tools"><![CDATA[Account Dashboard Manage Tools Menu]]></string>
+	<string name="_sys_menu_title_account_notifications"><![CDATA[Notifications Items]]></string>
+	<string name="_sys_menu_title_account_popup"><![CDATA[Account Popup]]></string>
+	<string name="_sys_menu_title_account_settings"><![CDATA[Account Settings Menu]]></string>
+	<string name="_sys_menu_title_account_settings_more"><![CDATA[Account Settings More Menu]]></string>
+	<string name="_sys_menu_title_add_content"><![CDATA[Add Content Menu]]></string>
+	<string name="_sys_menu_title_add_profile"><![CDATA[Add Profile Menu]]></string>
+	<string name="_sys_menu_title_add_profile_vertical"><![CDATA[Add Profile Menu (vertical)]]></string>
+	<string name="_sys_menu_title_cmts_item_actions"><![CDATA[Comment Actions]]></string>
+	<string name="_sys_menu_title_cmts_item_manage"><![CDATA[Manage Comment]]></string>
+        <string name="_sys_menu_title_cmts_item_meta"><![CDATA[Comment Meta Info]]></string>
+	<string name="_sys_menu_title_footer"><![CDATA[Footer Links]]></string>
+	<string name="_sys_menu_title_main"><![CDATA[Site Navigation]]></string>
+	<string name="_sys_menu_title_homepage"><![CDATA[Homepage Menu]]></string>
+        <string name="_sys_menu_title_homepage_submenu"><![CDATA[Homepage Submenu]]></string>
+	<string name="_sys_menu_set_title_homepage_submenu"><![CDATA[Homepage Submenu]]></string>
+	<string name="_sys_menu_item_title_system_explore"><![CDATA[Explore]]></string>
+	<string name="_sys_menu_item_title_explore"><![CDATA[Explore]]></string>
+	<string name="_sys_menu_item_title_system_updates"><![CDATA[Updates]]></string>
+	<string name="_sys_menu_item_title_updates"><![CDATA[Updates]]></string>
+	<string name="_sys_menu_item_title_system_trends"><![CDATA[Trends]]></string>
+	<string name="_sys_menu_item_title_trends"><![CDATA[Trends]]></string>
+	<string name="_sys_menu_title_profiles_create"><![CDATA[Create Profiles]]></string>
+	<string name="_sys_menu_title_profile_stats"><![CDATA[Profile Stats]]></string>
+	<string name="_sys_menu_title_rss"><![CDATA[RSS]]></string>
+	<string name="_sys_menu_title_set_acl_level"><![CDATA[ACL Levels]]></string>
+	<string name="_sys_menu_title_social_sharing"><![CDATA[Social Sharing]]></string>
+        <string name="_sys_menu_title_create_post"><![CDATA[Create Post Menu]]></string>
+        <string name="_sys_menu_title_add_relation"><![CDATA[Add Relationship Menu]]></string>
+	<string name="_sys_menu_title_submenu"><![CDATA[Site Submenu]]></string>
+	<string name="_sys_menu_title_toolbar_member"><![CDATA[Member Toolbar]]></string>
+	<string name="_sys_menu_title_toolbar_site"><![CDATA[Site Toolbar]]></string>
+	<string name="_sys_menu_title_switch_language_popup"><![CDATA[Language Switcher (popup)]]></string>
+	<string name="_sys_menu_title_switch_language_inline"><![CDATA[Language Switch (inline)]]></string>
+	<string name="_sys_menu_title_switch_template"><![CDATA[Switch Template]]></string>
+	<string name="_sys_menu_title_snippet_meta"><![CDATA[Snippet Meta Info]]></string>
+  <string name="_sys_menu_dashboard_manage_tools_addon_counter1_caption_default"><![CDATA[hidden]]></string>
+  <string name="_sys_menu_dashboard_manage_tools_addon_counter1_caption_profile_default"><![CDATA[unapproved]]></string>
+  <string name="_sys_menu_dashboard_manage_tools_addon_counter2_caption_default"><![CDATA[reported]]></string>
+	<string name="_sys_metatags_mention_added"><![CDATA[<b class="bx-ntfs-content-profile">{owner_name}</b> mentioned <b class="bx-ntfs-content-entry">{entry_caption}</b>]]></string>
+	<string name="_sys_mobile_friends"><![CDATA[Friends]]></string>
+	<string name="_sys_mobile_info"><![CDATA[Info]]></string>
+	<string name="_sys_mobile_mail"><![CDATA[Messages]]></string>
+	<string name="_sys_mobile_profile_contact"><![CDATA[Contact]]></string>
+	<string name="_sys_mobile_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_sys_mobile_profile_info"><![CDATA[Profile Info]]></string>
+	<string name="_sys_mobile_search"><![CDATA[Search]]></string>
+	<string name="_sys_mobile_status"><![CDATA[Status]]></string>
+    <string name="_sys_name"><![CDATA[Name]]></string>
+    <string name="_sys_next"><![CDATA[Next]]></string>
+    <string name="_sys_notification_account"><![CDATA[Accounts created in the last 24 hours:]]></string>
+    <string name="_sys_not_available"><![CDATA[n/a]]></string>
+    <string name="_sys_not_specified"><![CDATA[Not Specified]]></string>
+    <string name="_sys_on"><![CDATA[on]]></string>
+    <string name="_sys_off"><![CDATA[off]]></string>
+	<string name="_sys_page_block_title_about"><![CDATA[About]]></string>
+	<string name="_sys_page_block_title_account_profile_create"><![CDATA[Create a profile...]]></string>
+	<string name="_sys_page_block_title_account_profile_switcher"><![CDATA[Use site as ...]]></string>
+	<string name="_sys_page_block_title_account_settings_delete"><![CDATA[Delete Account]]></string>
+	<string name="_sys_page_block_title_account_settings_email"><![CDATA[Email Settings]]></string>
+	<string name="_sys_page_block_title_account_settings_info"><![CDATA[Edit Account]]></string>
+	<string name="_sys_page_block_title_account_settings_menu"><![CDATA[Account Settings]]></string>
+	<string name="_sys_page_block_title_account_settings_pwd"><![CDATA[Change Password]]></string>
+	<string name="_sys_page_block_title_add_content"><![CDATA[Add Content]]></string>
+	<string name="_sys_page_block_title_chart_growth"><![CDATA[Growth Charts]]></string>
+	<string name="_sys_page_block_title_chart_stats"><![CDATA[Content]]></string>
+	<string name="_sys_page_block_title_cmts_administration"><![CDATA[Manage Comments]]></string>
+	<string name="_sys_page_block_title_confirm_email"><![CDATA[Email Confirmation]]></string>
+	<string name="_sys_page_block_title_confirm_phone"><![CDATA[Phone Confirmation]]></string>
+	<string name="_sys_page_block_title_create_account"><![CDATA[Sign up]]></string>
+	<string name="_sys_page_block_title_sys_create_post_context"><![CDATA[Create Post (Context)]]></string>
+	<string name="_sys_page_block_title_create_post_context"><![CDATA[Add new...]]></string>
+	<string name="_sys_page_block_title_sys_create_post_public"><![CDATA[Create Post (Public)]]></string>
+	<string name="_sys_page_block_title_create_post_public"><![CDATA[Add new...]]></string>
+	<string name="_sys_page_block_title_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_sys_page_block_title_homepage_menu"><![CDATA[Content modules menu]]></string>
+        <string name="_sys_page_block_title_homepage_splash"><![CDATA[Splash]]></string>
+	<string name="_sys_page_block_title_forgot_password"><![CDATA[Forgot Password]]></string>
+	<string name="_sys_page_block_system_title_login"><![CDATA[Log in with Sign up link]]></string>
+	<string name="_sys_page_block_system_title_login_step2"><![CDATA[Log in - step2]]></string>
+	<string name="_sys_page_block_system_title_login_step3"><![CDATA[Log in - step3]]></string>
+	<string name="_sys_page_block_system_title_login_only"><![CDATA[Log in]]></string>
+	<string name="_sys_page_block_title_system_cmts_administration"><![CDATA[Manage Comments]]></string>
+	<string name="_sys_page_block_title_login"><![CDATA[Log in]]></string>
+	<string name="_sys_page_block_title_login_step2"><![CDATA[Log in - step 2]]></string>
+	<string name="_sys_page_block_title_login_step3"><![CDATA[Log in - step 3]]></string>
+	<string name="_sys_page_block_title_manage_tools"><![CDATA[Manage]]></string>
+	<string name="_sys_page_block_title_privacy"><![CDATA[Privacy Policy]]></string>
+	<string name="_sys_page_block_title_profile_stats"><![CDATA[Profile stats]]></string>
+	<string name="_sys_page_block_title_profile_membership"><![CDATA[Membership]]></string>
+	<string name="_sys_page_block_title_unsubscribe_news"><![CDATA[Unsubscribe From Site Newsletters]]></string>
+	<string name="_sys_page_block_title_unsubscribe_notifications"><![CDATA[Unsubscribe From Site Notifications]]></string>
+	<string name="_sys_page_block_title_std_dash_version"><![CDATA[Version]]></string>
+	<string name="_sys_page_block_title_std_dash_space"><![CDATA[Space Usage]]></string>
+	<string name="_sys_page_block_title_std_dash_host_tools"><![CDATA[Host Tools]]></string>
+	<string name="_sys_page_block_title_std_dash_cache"><![CDATA[Cache]]></string>
+	<string name="_sys_page_block_title_terms"><![CDATA[Terms of Service]]></string>
+	<string name="_sys_page_lang_block_about"><![CDATA[This site is powered by UNA. The rest is a mystery.]]></string>
+	<string name="_sys_page_lang_block_terms"><![CDATA[Our terms of use.]]></string>
+	<string name="_sys_page_lang_block_privacy"><![CDATA[Our privacy policy.]]></string>
+	<string name="_sys_page_title_about"><![CDATA[About]]></string>
+	<string name="_sys_page_title_account_profile_switcher"><![CDATA[My Profiles]]></string>
+	<string name="_sys_page_title_account_settings_delete"><![CDATA[Delete Account]]></string>
+	<string name="_sys_page_title_account_settings_email"><![CDATA[Email Settings]]></string>
+	<string name="_sys_page_title_account_settings_info"><![CDATA[Edit Account]]></string>
+	<string name="_sys_page_title_account_settings_pwd"><![CDATA[Change Password]]></string>
+	<string name="_sys_page_title_add_content"><![CDATA[Add Content]]></string>
+  <string name="_sys_page_title_cmts_administration"><![CDATA[Manage Comments]]></string>
+	<string name="_sys_page_title_confirm_email"><![CDATA[Email Confirmation]]></string>
+	<string name="_sys_page_title_confirm_phone"><![CDATA[Phone Confirmation]]></string>
+	<string name="_sys_page_title_create_account"><![CDATA[Sign up]]></string>
+	<string name="_sys_page_title_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_sys_page_title_forgot_password"><![CDATA[Forgot Password]]></string>
+	<string name="_sys_page_title_home"><![CDATA[{site_title} :: Homepage]]></string>
+	<string name="_sys_page_title_login"><![CDATA[Log in]]></string>
+	<string name="_sys_page_title_login_step2"><![CDATA[Log in - step 2]]></string>
+	<string name="_sys_page_title_login_step3"><![CDATA[Log in - step 3]]></string>
+	<string name="_sys_page_title_privacy"><![CDATA[Privacy Policy]]></string>
+        <string name="_sys_page_title_explore"><![CDATA[Explore]]></string>
+        <string name="_sys_page_title_updates"><![CDATA[Updates]]></string>
+        <string name="_sys_page_title_trends"><![CDATA[Trends]]></string>
+	<string name="_sys_page_title_terms"><![CDATA[Terms of Service]]></string>
+	<string name="_sys_page_title_system_about"><![CDATA[About]]></string>
+	<string name="_sys_page_title_system_account_profile_switcher"><![CDATA[My Profiles]]></string>
+	<string name="_sys_page_title_system_account_settings_delete"><![CDATA[Delete Account]]></string>
+	<string name="_sys_page_title_system_account_settings_email"><![CDATA[Email Settings]]></string>
+	<string name="_sys_page_title_system_account_settings_info"><![CDATA[Edit Account]]></string>
+	<string name="_sys_page_title_system_account_settings_pwd"><![CDATA[Change Password]]></string>
+	<string name="_sys_page_title_system_add_content"><![CDATA[Add Content]]></string>
+  <string name="_sys_page_title_system_cmts_administration"><![CDATA[Manage Comments]]></string>
+  <string name="_sys_page_title_system_confirm_email"><![CDATA[Email Confirmation]]></string>
+	<string name="_sys_page_title_system_confirm_phone"><![CDATA[Phone Confirmation]]></string>
+	<string name="_sys_page_title_system_create_account"><![CDATA[Sign up]]></string>
+	<string name="_sys_page_title_system_dashboard"><![CDATA[Dashboard]]></string>
+	<string name="_sys_page_title_system_forgot_password"><![CDATA[Forgot Password]]></string>
+	<string name="_sys_page_title_system_home"><![CDATA[Homepage]]></string>
+	<string name="_sys_page_title_system_login"><![CDATA[Log in]]></string>
+	<string name="_sys_page_title_system_login_step2"><![CDATA[Log in - step 2]]></string>
+	<string name="_sys_page_title_system_login_step3"><![CDATA[Log in - step 3]]></string>
+	<string name="_sys_page_title_system_privacy"><![CDATA[Privacy Policy]]></string>
+        <string name="_sys_page_title_sys_explore"><![CDATA[Explore]]></string>
+	<string name="_sys_page_title_sys_updates"><![CDATA[Updates]]></string>
+	<string name="_sys_page_title_sys_trends"><![CDATA[Trends]]></string>
+	<string name="_sys_page_title_system_terms"><![CDATA[Terms of Service]]></string>
+	<string name="_sys_page_title_system_unsubscribe_news"><![CDATA[Unsubscribe From Newsletters]]></string>
+	<string name="_sys_page_title_system_unsubscribe_notifications"><![CDATA[Unsubscribe From Notifications]]></string>
+	<string name="_sys_page_title_system_studio_dashboard"><![CDATA[Studio Dashboard]]></string>
+	<string name="_sys_page_title_unsubscribe_news"><![CDATA[Unsubscribe From Site Newsletters]]></string>
+	<string name="_sys_page_title_unsubscribe_notifications"><![CDATA[Unsubscribe From Site Notifications]]></string>
+	<string name="_sys_page_title_studio_dashboard"><![CDATA[Studio Dashboard]]></string>
+	<string name="_sys_page_type_default"><![CDATA[Default]]></string>
+	<string name="_sys_page_type_default_wo_hf"><![CDATA[Without header/footer]]></string>
+	<string name="_sys_paginate_info"><![CDATA[{0}-{1}]]></string>
+	<string name="_sys_paginate_view_all"><![CDATA[View All]]></string>
+	<string name="_sys_please_select"><![CDATA[Please select...]]></string>
+        <string name="_sys_pre_lists_relations"><![CDATA[Relationships]]></string>
+        <string name="_sys_pre_lists_relations_husband"><![CDATA[husband]]></string>
+        <string name="_sys_pre_lists_relations_wife"><![CDATA[wife]]></string>
+        <string name="_sys_pre_lists_relations_father"><![CDATA[father]]></string>
+        <string name="_sys_pre_lists_relations_mother"><![CDATA[mother]]></string>
+        <string name="_sys_pre_lists_relations_son"><![CDATA[son]]></string>
+        <string name="_sys_pre_lists_relations_daughter"><![CDATA[daughter]]></string>
+        <string name="_sys_pre_lists_relations_brother"><![CDATA[brother]]></string>
+        <string name="_sys_pre_lists_relations_sister"><![CDATA[sister]]></string>
+	<string name="_sys_pre_lists_report_types"><![CDATA[Report Types]]></string>
+	<string name="_sys_pre_lists_report_types_spam"><![CDATA[spam]]></string>
+	<string name="_sys_pre_lists_report_types_scam"><![CDATA[scam]]></string>
+	<string name="_sys_pre_lists_report_types_fraud"><![CDATA[fraud]]></string>
+	<string name="_sys_pre_lists_report_types_nude"><![CDATA[nude]]></string>
+	<string name="_sys_pre_lists_report_types_other"><![CDATA[other]]></string>
+        <string name="_sys_pre_lists_vote_reactions"><![CDATA[Reactions]]></string>
+        <string name="_sys_pre_lists_vote_reactions_like"><![CDATA[Like]]></string>
+        <string name="_sys_pre_lists_vote_reactions_love"><![CDATA[Love]]></string>
+        <string name="_sys_pre_lists_vote_reactions_joy"><![CDATA[Haha]]></string>
+        <string name="_sys_pre_lists_vote_reactions_surprise"><![CDATA[Wow]]></string>
+        <string name="_sys_pre_lists_vote_reactions_sadness"><![CDATA[Sad]]></string>
+        <string name="_sys_pre_lists_vote_reactions_anger"><![CDATA[Angry]]></string>
+	<string name="_sys_profile_sample_single"><![CDATA[profile]]></string>
+        <string name="_sys_profile_friend_request_added"><![CDATA[<b class="bx-ntfs-content-profile">{owner_name}</b> befriended <b class="bx-ntfs-content-entry">{entry_caption}</b>]]></string>
+	<string name="_sys_profile_friendship_added"><![CDATA[Now <b class="bx-ntfs-content-profile">{owner_name}</b> and <b class="bx-ntfs-content-entry">{entry_caption}</b> are friends]]></string>
+	<string name="_sys_profile_subscription_added"><![CDATA[<b class="bx-ntfs-content-profile">{owner_name}</b> followed <b class="bx-ntfs-content-entry">{entry_caption}</b>]]></string>
+	<string name="_sys_profile_status_active"><![CDATA[Active]]></string>
+	<string name="_sys_profile_status_pending"><![CDATA[Pending]]></string>
+	<string name="_sys_profile_status_suspended"><![CDATA[Suspended]]></string>
+	<string name="_sys_private"><![CDATA[Private]]></string>
+        <string name="_sys_privacy_groups_acl"><![CDATA[Membership Levels]]></string>
+    <string name="_sys_pruning_db"><![CDATA[<h3>Database pruning:</h3>
+        <ul>
+            <li><b>{0}</b> deleted expired membership levels</li>
+            <li><b>{1}</b> deleted expired sessions</li>
+            <li><b>{2}</b> deleted expired keys</li>
+            <li><b>{3}</b> deleted expired storage tokens</li>
+            <li><b>{4}</b> deleted outdated transcoded images</li>
+        </ul>]]></string>
+    <string name="_sys_pruning_files"><![CDATA[<h3>Files pruning:</h3>
+        <ul>
+            <li><b>{0}</b> total</li>
+            <li><b>{1}</b> deleted</li>
+        </ul>]]></string>
+        <string name="_sys_ps_group_title_followers"><![CDATA[Followers]]></string>
+	<string name="_sys_ps_group_title_friends"><![CDATA[Friends]]></string>
+	<string name="_sys_ps_group_title_me_only"><![CDATA[Me only]]></string>
+	<string name="_sys_ps_group_title_members"><![CDATA[Members]]></string>
+	<string name="_sys_ps_group_title_public"><![CDATA[Public]]></string>
+        <string name="_sys_ps_group_title_participants"><![CDATA[Participants]]></string>
+	<string name="_sys_ps_group_title_closed"><![CDATA[Closed]]></string>
+	<string name="_sys_ps_group_title_secret"><![CDATA[Secret]]></string>
+    <string name="_sys_ps_ferr_incorrect_select"><![CDATA[You need to select some value]]></string>
+    <string name="_sys_ps_space_title_friend"><![CDATA[friend]]></string>
+    <string name="_sys_push_notification_request"><![CDATA[Would you like to get notifications from {0}?]]></string>  
+    <string name="_sys_push_notification_request_yes"><![CDATA[Yes]]></string>  
+    <string name="_sys_push_notification_request_no"><![CDATA[No, thanks]]></string>
+    <string name="_sys_read_more"><![CDATA[Continue reading "{0}"]]></string>
+    <string name="_sys_relation"><![CDATA[Relationship]]></string>
+	<string name="_sys_request_module_not_found_cpt"><![CDATA[Module was not found]]></string>
+	<string name="_sys_request_module_not_found_cnt"><![CDATA[Module({0}) was not found]]></string>
+	<string name="_sys_request_page_not_found_cpt"><![CDATA[Page was not found]]></string>
+	<string name="_sys_request_page_not_found_cnt"><![CDATA[Page({0}) was not found in module({1})]]></string>
+	<string name="_sys_request_method_not_found_cpt"><![CDATA[Method was not found]]></string>
+	<string name="_sys_request_method_not_found_cnt"><![CDATA[Method({0}) was not found in module({1})]]></string>
+	<string name="_sys_score_counter"><![CDATA[{0}]]></string>
+	<string name="_sys_score_counter_empty"><![CDATA[Vote]]></string>
+	<string name="_sys_score_do_up"><![CDATA[Up vote]]></string>
+	<string name="_sys_score_do_down"><![CDATA[Down vote]]></string>
+	<string name="_sys_score_do_by"><![CDATA[Voted by]]></string>
+	<string name="_sys_score_err_not_enabled"><![CDATA[The feature is not available right now. Please, try again later.]]></string>
+    <string name="_sys_score_err_duplicate_vote"><![CDATA[Duplicate vote]]></string>
+	<string name="_sys_search_main_title"><![CDATA[Search Home]]></string>
+	<string name="_sys_select"><![CDATA[Select]]></string>
+	<string name="_sys_send"><![CDATA[Send]]></string>
+    <string name="_sys_search_placeholder"><![CDATA[Search...]]></string>
+	<string name="_sys_show_more"><![CDATA[Show more]]></string>    
+	<string name="_sys_spam_detected"><![CDATA[Your activity triggered automated block]]></string>
+	<string name="_sys_spam_detected_contact"><![CDATA[Your activity triggered automated block, please contact us to investigate: {0}]]></string>
+	<string name="_sys_splash_btn_start"><![CDATA[Start]]></string>
+	<string name="_sys_splash_err_domain_incorrect"><![CDATA[Domain is essential. Please, fill in this field, for example, my-first-site.]]></string>
+	<string name="_sys_splash_err_domain_is_used"><![CDATA[The domain name is already used. Try to select another one.]]></string>
+	<string name="_sys_splash_err_service_not_available"><![CDATA[The service is currently not available. Try it later, please.]]></string>
+	<string name="_sys_splash_inp_placeholder"><![CDATA[site address]]></string>
+	<string name="_sys_splash_inp_postfix"><![CDATA[.online.me]]></string>
+	<string name="_sys_splash_slogan"><![CDATA[The easiest way to create your own social website.]]></string>
+        <string name="_sys_status"><![CDATA[Status]]></string>
+        <string name="_sys_status_awaiting"><![CDATA[awaiting]]></string>
+        <string name="_sys_status_failed"><![CDATA[failed]]></string>
+	<string name="_sys_storage_err_db"><![CDATA[database error]]></string>
+	<string name="_sys_storage_err_engine_add"><![CDATA[error occurred]]></string>
+	<string name="_sys_storage_err_engine_get"><![CDATA[error occurred]]></string>
+	<string name="_sys_storage_err_file_not_found"><![CDATA[file not found]]></string>
+	<string name="_sys_storage_err_file_too_big"><![CDATA[file is too big]]></string>
+	<string name="_sys_storage_err_filesystem_perm"><![CDATA[permissions error]]></string>
+	<string name="_sys_storage_err_no_file"><![CDATA[no file to upload]]></string>
+	<string name="_sys_storage_err_no_input_method"><![CDATA[so such input method available]]></string>
+	<string name="_sys_storage_err_object_quota_exceeded"><![CDATA[quota exceeded]]></string>
+	<string name="_sys_storage_err_permission_denied"><![CDATA[permission denied]]></string>
+	<string name="_sys_storage_err_site_quota_exceeded"><![CDATA[quota exceeded]]></string>
+	<string name="_sys_storage_err_unlink"><![CDATA[file deletion failed]]></string>
+	<string name="_sys_storage_err_user_quota_exceeded"><![CDATA[user quota exceeded]]></string>
+	<string name="_sys_storage_err_wrong_ext"><![CDATA[wrong file extension]]></string>
+	<string name="_sys_storage_invalid_file"><![CDATA[file is invalid]]></string>
+	<string name="_sys_storage_restriction_ext_all_allowed"><![CDATA[Wow, files of all types are allowed!]]></string>
+	<string name="_sys_storage_restriction_ext_all_denied"><![CDATA[Sorry, adding all file types is currently restricted.]]></string>
+	<string name="_sys_storage_restriction_ext_allowed"><![CDATA[Please, upload only files of these types: {0}]]></string>
+	<string name="_sys_storage_restriction_ext_denied"><![CDATA[You may upload any types of files except for {0}]]></string>
+	<string name="_sys_storage_restriction_size"><![CDATA[Maximum file size limit is {0}]]></string>
+	<string name="_sys_switch_profile"><![CDATA[Switch profile]]></string>
+	<string name="_sys_submit"><![CDATA[Submit]]></string>
+	<string name="_sys_subscribe"><![CDATA[Follow]]></string>
+        <string name="_sys_template_mixed_mask"><![CDATA[{0} ({1})]]></string>
+
+	<string name="_sys_tour_launcher_welcome_title"><![CDATA[Welcome to UNA Studio!]]></string>
+	<string name="_sys_tour_launcher_welcome_txt"><![CDATA[Studio is where you customise your site; add and manage apps; control languages and design; set membership levels and permissions; build pages and navigation, and a lot more. You are now in Studio Launcher.]]></string>
+	<string name="_sys_tour_launcher_apps_title"><![CDATA[Add and manage Apps]]></string>
+	<string name="_sys_tour_launcher_apps_txt"><![CDATA[Apps are modules, languages, tools, templates - all the bits and pieces that make your site unique. You can download and install Apps and they will appear in Studio Launcher. Apps add and change functionality of your site.]]></string>
+	<string name="_sys_tour_launcher_designer_title"><![CDATA[Start making your site special]]></string>
+    <string name="_sys_tour_launcher_designer_txt"><![CDATA[Designer is the best place to start customisation. Change the site logo, choose design template and manage the “Cover Page”. Your site now shows Cover Page to all guest visitors. You can either customise it to turn it off to display a full homepage with content of your choice.]]></string>
+    <string name="_sys_tour_launcher_accounts_title"><![CDATA[You are more than Admin]]></string>
+    <string name="_sys_tour_launcher_accounts_txt"><![CDATA[UNA content and profiles are controlled by Admins and Moderators right on the site front-end, so you don’t have to worry about that in Studio. You do need to appoint your Admins and Moderators, though. And this is where you do it. If you also want to be the site Admin, just create your profile use “Set Membership” to upgrade it.]]></string>
+	<string name="_sys_tour_launcher_dashboard_title"><![CDATA[One look and you know it]]></string>
+	<string name="_sys_tour_launcher_dashboard_txt"><![CDATA[Dashboard gives a quick overview of the site status. UNA version, space usage, hosting tools and cache.  Different Apps will add their blocks to Dashboard.]]></string>
+	<string name="_sys_tour_launcher_builder_page_title"><![CDATA[Build your site the way you want it]]></string>
+	<string name="_sys_tour_launcher_builder_page_txt"><![CDATA[Pages allow you to edit the site by rearranging, adding and removing blocks on site pages. You can even create new custom pages of different types. You can also control visibility settings, SEO data, cacheing and page layouts.]]></string>
+	<string name="_sys_tour_launcher_builder_permissions_title"><![CDATA[Define who can do what]]></string>
+	<string name="_sys_tour_launcher_builder_permissions_txt"><![CDATA[Create and edit Membership Levels and associated Actions permissions.]]></string>
+	<string name="_sys_tour_launcher_builder_forms_title"><![CDATA[Form and re-form your forms]]></string>
+	<string name="_sys_tour_launcher_builder_forms_txt"><![CDATA[Forms builder is a powerful tool that allows deep customisation of site database and forms. You can create and manage data lists, form fields and even display types (like Add/Edit/Delete). Your Forms will define the structure and theme of the site.]]></string>
+	<string name="_sys_tour_launcher_builder_menus_title"><![CDATA[Show them around]]></string>
+	<string name="_sys_tour_launcher_builder_menus_txt"><![CDATA[Add and manage site navigation menus. You can edit links, re-order them, add new ones, change icons and control visibility according to membership permissions.]]></string>
+	<string name="_sys_tour_launcher_polyglot_title"><![CDATA[Speak their language]]></string>
+	<string name="_sys_tour_launcher_polyglot_txt"><![CDATA["If you talk to a man in a language he understands, that goes to his head. If you talk to him in his language, that goes to his heart." Polyglot allows you to set site language and data format, edit site texts in all installed languages and even translate email templates.]]></string>
+	<string name="_sys_tour_launcher_reorganize_title"><![CDATA[Move the Apps around]]></string>
+	<string name="_sys_tour_launcher_reorganize_txt"><![CDATA[Activate reorganisation mode to rearrange Apps in Launcher or delete inactive ones altogether.]]></string>
+	<string name="_sys_tour_launcher_favourites_title"><![CDATA[Choose wisely]]></string>
+	<string name="_sys_tour_launcher_favourites_txt"><![CDATA[Your Studio may have hundreds of installed Apps. Choose the ones you access most often and use the Star to bring them up.]]></string>
+	<string name="_sys_tour_launcher_add_apps_title"><![CDATA[Now DO add new Apps!]]></string>
+	<string name="_sys_tour_launcher_add_apps_txt"><![CDATA[UNA comes with only a handful of core Apps. Choose, download and install Apps to add profiles types, modules, system tools, plugins, languages and design templates. You can activate and deactivate installed Apps. UNA is super-modular and incredibly flexible, letting you choose your own combination of functionality, settings and database structure to make the social site of your dreams real. Even without changing anything you will have the perfectly functioning social site!]]></string>
+
+	<string name="_sys_tour_homepage_welcome_title"><![CDATA[This is the Homepage]]></string>
+	<string name="_sys_tour_homepage_welcome_txt"><![CDATA[At first there isn't much here. Install more Apps via Studio, add more blocks via Studio > Pages > Homepage, create profiles, appoint admins, post some content and your site will come alive!]]></string>
+	<string name="_sys_tour_homepage_account_menu_title"><![CDATA[Get to know your Account Menu]]></string>
+	<string name="_sys_tour_homepage_account_menu_txt"><![CDATA[Add and manage profiles, check notifications, access account settings. Admins and Moderators can use it to access Dash with links to site content and profiles management.]]></string>
+
+	<string name="_sys_txt_access_denied"><![CDATA[Access denied]]></string>
+	<string name="_sys_txt_account_pending"><![CDATA[Your account is pending approval, please wait until it is activated.]]></string>
+	<string name="_sys_txt_account_profile_context_change_suggestion"><![CDATA[This is your profile, you can <a href="{0}">change your current profile</a> to this profile]]></string>
+	<string name="_sys_txt_account_profile_context_changed_success"><![CDATA[Current profile has been successfully changed to: <b>{0}</b>]]></string>
+	<string name="_sys_txt_account_suspended"><![CDATA[Your account is suspended.]]></string>
+	<string name="_sys_txt_account_unconfirmed_email"><![CDATA[Your email address is unconfirmed. Please, check your email ({1}) for a confirmation letter and click email confirmation link. Can't find the letter? Check your SPAM folder or <a href="{0}">send the verification letter again</a>.]]></string>
+	<string name="_sys_txt_account_unconfirmed_phone"><![CDATA[Your phone is unconfirmed. Please, confirm it on <a href="{0}">verification page</a>.]]></string>
+	<string name="_sys_txt_account_profile_system"><![CDATA[Please <a href="{0}">create a profile</a> to start using the site.]]></string>
+	<string name="_sys_txt_captcha_not_available"><![CDATA[CAPTCHA not available]]></string>
+    <string name="_sys_txt_change_image"><![CDATA[Change Picture]]></string>
+    <string name="_sys_txt_cmt_loading"><![CDATA[Loading...]]></string>
+	<string name="_sys_txt_confirm_email_already_confirmed"><![CDATA[Your email address is already confirmed.]]></string>
+	<string name="_sys_txt_confirm_email_desc"><![CDATA[Please enter confirmation code which was sent to your email address, or just click confirmation link in the same email message.]]></string>
+	<string name="_sys_txt_confirm_email_error_occured"><![CDATA[Error occurred, please try to login to your account and resend verification email.]]></string>
+	<string name="_sys_txt_confirm_email_sent"><![CDATA[Email verification letter was sent, please check your inbox.]]></string>
+	<string name="_sys_txt_confirm_email_sent_failed"><![CDATA[Error occurred, please report error to site administrator.]]></string>
+	<string name="_sys_txt_confirm_email_success"><![CDATA[You email address was successfully confirmed.]]></string>
+	
+	<string name="_sys_txt_confirm_phone_already_confirmed"><![CDATA[Your phone is already confirmed.]]></string>
+	<string name="_sys_txt_confirm_phone_set_phone_error_occured"><![CDATA[Error occurred, please try to login to your account and repeat verification.]]></string>
+	<string name="_sys_txt_confirm_phone_send_sms_error_occured"><![CDATA[Error occurred, please report error to site administrator.]]></string>
+	<string name="_sys_txt_confirm_phone_sms_text"><![CDATA[Your phone's verification code is {0}.]]></string>
+	<string name="_sys_txt_confirm_phone_confirm_success"><![CDATA[Your phone number has been confirmed.]]></string>
+	<string name="_sys_txt_confirm_phone_set_phone_desc_set_phone"><![CDATA[Please enter a phone number for sending verification SMS.]]></string>
+	<string name="_sys_txt_confirm_phone_set_phone_desc_phone_confirmation"><![CDATA[Please enter verification code from the SMS.]]></string>
+
+	<string name="_sys_txt_create_post_placeholder"><![CDATA[What's happening, {0}]]></string>
+
+    <string name="_sys_txt_current_picture"><![CDATA[Current Picture]]></string>
+	<string name="_sys_txt_data_successfully_submitted"><![CDATA[Done]]></string>
+    <string name="_sys_txt_delete"><![CDATA[Delete]]></string>
+    <string name="_sys_txt_discard"><![CDATA[Discard]]></string>
+	<string name="_sys_txt_empty"><![CDATA[Empty]]></string>
+	<string name="_sys_txt_error_account_creation"><![CDATA[Account creation failed]]></string>
+	<string name="_sys_txt_error_account_delete"><![CDATA[Account delete failed]]></string>
+	<string name="_sys_txt_error_account_is_not_defined"><![CDATA[Account is not defined]]></string>
+	<string name="_sys_txt_error_account_update"><![CDATA[Account update failed]]></string>
+	<string name="_sys_txt_error_entry_creation"><![CDATA[Entry creation error]]></string>
+	<string name="_sys_txt_error_entry_delete"><![CDATA[Entry delete failed]]></string>
+	<string name="_sys_txt_error_entry_is_not_defined"><![CDATA[Requested resource doesn't exist]]></string>
+	<string name="_sys_txt_error_entry_update"><![CDATA[Entry update failed]]></string>
+    <string name="_sys_txt_error_occured"><![CDATA[Error Occurred]]></string>
+    <string name="_sys_txt_field_created"><![CDATA[Created:]]></string>
+    <string name="_sys_txt_field_updated"><![CDATA[Updated:]]></string>
+	<string name="_sys_txt_forgot_pasword"><![CDATA[Forgot password?]]></string>
+	<string name="_sys_txt_forgot_pasword_check_email"><![CDATA[Email was sent, please follow instructions in the email message.]]></string>
+	<string name="_sys_txt_forgot_pasword_check_phone"><![CDATA[SMS was sent, please follow instructions in the SMS.]]></string>
+	<string name="_sys_txt_forgot_pasword_desc"><![CDATA[Enter your account email address to get a password-reset link.]]></string>
+	<string name="_sys_txt_forgot_pasword_by_both_desc"><![CDATA[Enter your account email address or phone to get a password-reset link.]]></string>
+	<string name="_sys_txt_forgot_pasword_by_phone_desc"><![CDATA[Enter your account phone to get a password-reset link.]]></string>
+	<string name="_sys_txt_forgot_pasword_email_send_failed"><![CDATA[Email send failed, please try again later.]]></string>
+    <string name="_sys_txt_forgot_pasword_error_occured"><![CDATA[Error occurred, please report error to the site administrator.]]></string>
+	<string name="_sys_txt_forgot_pasword_sms_text"><![CDATA[Click the link below to reset your password {0}]]></string>
+    
+    <string name="_sys_txt_form_entry_input_picture_delete"><![CDATA[Delete]]></string>
+    <string name="_sys_txt_form_entry_input_picture_insert"><![CDATA[Insert to Post]]></string>
+	<string name="_sys_txt_form_entry_input_picture_pic_url"><![CDATA[Attachment URL:]]></string>
+    <string name="_sys_txt_form_entry_input_picture_use_as_thumb"><![CDATA[Use as Thumbnail]]></string>
+	<string name="_sys_txt_form_submission_error"><![CDATA[Incorrect info. Please, check your inputs and try to submit again.]]></string>
+	<string name="_sys_txt_form_submission_error_csrf_expired"><![CDATA[Token expired. Please try again.]]></string>
+
+    <string name="_sys_txt_homepage_cover"><![CDATA[Unity is strength... when there is teamwork and collaboration, wonderful things can be achieved.<br /><button class="bx-btn bx-hide-when-logged-in bx-def-margin-top" onclick="document.location='{0}'">Join Now!</button>]]></string>
+	<string name="_sys_txt_login_2fa_description"><![CDATA[Two-factor authentication is enabled, please specify the phone number to send verification code to.]]></string>
+	
+	<string name="_sys_txt_login_2fa_sms_text"><![CDATA[Your verification code is {0}.]]></string>
+	<string name="_sys_txt_login_2fa_sms_error_occured"><![CDATA[An error occurred, please report error to the site administrator.]]></string>
+    <string name="_sys_txt_join_description"><![CDATA[Already a member? <a href="{0}">Log in.</a>]]></string>
+	<string name="_sys_txt_login_description"><![CDATA[Not a member yet? <a href="{0}">Sign up.</a>]]></string>
+	<string name="_sys_txt_login_error"><![CDATA[Entered email or password is incorrect. Please try again.]]></string>
+  <string name="_sys_txt_login_locked"><![CDATA[Your account is locked and needs to be unlocked using <a href="{0}">forgot password page</a>.]]></string>
+  
+	<string name="_sys_txt_login_invalid_role"><![CDATA[Access denied]]></string>
+    <string name="_sys_txt_my_profiles"><![CDATA[Create a new profile]]></string>
+    <string name="_sys_txt_new_picture"><![CDATA[New Picture]]></string>
+    <string name="_sys_txt_no_picture_uploaded"><![CDATA[No picture uploaded]]></string>
+    <string name="_sys_txt_no_title"><![CDATA[No title]]></string>
+    <string name="_sys_txt_n_by"><![CDATA[{0} by]]></string>
+    <string name="_sys_txt_n_friends"><![CDATA[{0} friends]]></string>
+    <string name="_sys_txt_n_mutual_friends"><![CDATA[{0} mutual friends]]></string>
+    <string name="_sys_txt_one_mutual_friend"><![CDATA[<a href="{0}">{1}</a> mutual friend]]></string>
+    <string name="_sys_txt_powered_by"><![CDATA[Powered by UNA Community Management System]]></string>
+	<string name="_sys_txt_reset_pasword_email_send_failed"><![CDATA[Your new password is <b>{0}</b>, please make sure to save it somewhere because we wasn't able to send it to your email. You can change it to any other password after first login.]]></string>
+	<string name="_sys_txt_reset_pasword_email_sent"><![CDATA[Your new password - <b>{0}</b> - was sent to your email. You can change it once you login to your account.]]></string>
+	<string name="_sys_txt_reset_pasword_error_occured"><![CDATA[Error occurred, please <a href="{0}">try again</a>.]]></string>
+        <string name="_sys_txt_splash_btn_join"><![CDATA[Join Now]]></string>
+	<string name="_sys_txt_splash_slide01_title"><![CDATA[Connect with people that share your passion.]]></string>
+	<string name="_sys_txt_splash_slide01_desc"><![CDATA[Stories, ideas, photos, videos, questions, jokes, discussions, anything.<br />Follow inspiring people and inspire your followers.]]></string>
+	<string name="_sys_txt_splash_slide02_txt"><![CDATA["Pull up a chair. Take a taste.<br />Come join us. Life is so endlessly<br />delicious."]]></string>
+	<string name="_sys_txt_splash_slide03_txt"><![CDATA["The only way to have a friend is to be one."]]></string>
+	<string name="_sys_txt_splash_slide04_txt"><![CDATA[Already one of us?]]></string>
+	<string name="_sys_txt_splash_title"><![CDATA[Connect. Share. Create.]]></string>
+	<string name="_sys_txt_splash_slogan"><![CDATA[Join our community now to connect with like-minded people, share exciting news and create inspiring content.]]></string>
+        <string name="_sys_txt_splash_login"><![CDATA[Login]]></string>
+        <string name="_sys_txt_splash_join"><![CDATA[Join]]></string>
+        <string name="_sys_txt_splash_connect"><![CDATA[Connect]]></string>
+        <string name="_sys_txt_splash_connect_text"><![CDATA[Find like-minded people, make new friends, follow interesting authors and stay in touch anywhere.]]></string>
+        <string name="_sys_txt_splash_share"><![CDATA[Share]]></string>
+        <string name="_sys_txt_splash_share_text"><![CDATA[Bring up the latest news, share interesting articles, exciting websites, cool photos and awesome videos.]]></string>
+        <string name="_sys_txt_splash_create"><![CDATA[Create]]></string>
+        <string name="_sys_txt_splash_create_text"><![CDATA[Build your social profile, post status updates, write notes, create polls and upload media albums.]]></string>
+	<string name="_sys_txt_switch_profile_context"><![CDATA[Switch]]></string>
+	<string name="_sys_txt_unsubscribe_email_settings_update_success"><![CDATA[Your email preferences has been successfully updated.]]></string>
+	<string name="_sys_txt_unsubscribe_error_occured"><![CDATA[Error occurred, please login to your account and update email references there or contact site administrator to unsubscribe you manually.]]></string>
+	<string name="_sys_txt_unsubscribe_info"><![CDATA[Update email preferences for <b>{0}</b>]]></string>
+        <string name="_sys_txt_unsubscribe_wrong_link"><![CDATA[Unsubscribe link is wrong.]]></string>
+        <string name="_sys_txt_user_n"><![CDATA[User #{0}]]></string>
+        <string name="_sys_txt_reports_title"><![CDATA[Reports]]></string>
+        <string name="_sys_unconfirmed"><![CDATA[Unconfirmed]]></string>
+	<string name="_sys_upgrade_conclusion"><![CDATA[<h3>Important info:</h3><p>{0}</p>]]></string>
+	<string name="_sys_upgrade_db_and_files_versions_different"><![CDATA[Database and files versions are different, probably previous patch wasn't applied correctly.]]></string>
+	<string name="_sys_upgrade_files_checksum_failed"><![CDATA[Can't apply upgrade because the following files were modified: {0}]]></string>
+	<string name="_sys_upgrade_files_checksum_failed_too_many"><![CDATA[Can't apply upgrade because too many files({0}%) were modified]]></string>
+	<string name="_sys_upgrade_files_checksum_failed_too_many_module"><![CDATA[Can't apply upgrade because too many files({0}%) were modified in {1} module]]></string>
+	<string name="_sys_upgrade_get_version_info_failed"><![CDATA[Get version info failed, please check internet connection on the web-server or web-server firewall]]></string>
+	<string name="_sys_upgrade_patch_checksum_failed"><![CDATA[Downloaded patch file checksum is invalid]]></string>
+	<string name="_sys_upgrade_patch_download_failed"><![CDATA[Patch download failed, or downloaded file can't be saved]]></string>
+	<string name="_sys_upgrade_patch_invalid"><![CDATA[Invalid patch, it can't be applied to your version or incorrect files structure in the patch.]]></string>
+	<string name="_sys_upgrade_patch_unpack_failed"><![CDATA[Patch unpack failed]]></string>
+	<string name="_sys_uploader_button_name_single"><![CDATA[Upload File]]></string>
+	<string name="_sys_uploader_close"><![CDATA[Close]]></string>
+	<string name="_sys_uploader_confirm_close_popup"><![CDATA[Oh no! Are you sure? This may discard uploading files, seriously.]]></string>
+    <string name="_sys_uploader_confirm_leaving_page"><![CDATA[Upload is in progress! Stay cool and don't close this page, or it will cut off half-way.]]></string>
+    <string name="_sys_uploader_crop_button_name"><![CDATA[Upload and Crop]]></string>
+    <string name="_sys_uploader_crop_rotate_left"><![CDATA[Rotate Left]]></string>
+	<string name="_sys_uploader_crop_rotate_right"><![CDATA[Rotate Right]]></string>
+	<string name="_sys_uploader_crop_submit_button"><![CDATA[Upload]]></string>
+    <string name="_sys_uploader_crop_title"><![CDATA[Crop Image]]></string>
+    <string name="_sys_uploader_crop_err_upload"><![CDATA[Error Uploading.]]></string>
+    <string name="_sys_uploader_crop_wrong_ext"><![CDATA[Wrong file extension, only images with the following extensions are allowed: jpg, jpeg, png, gif.]]></string>
+	<string name="_sys_uploader_err_msg"><![CDATA[Oops! An error occurred with {0} file: {1}]]></string>
+	<string name="_sys_uploader_html5_button_name"><![CDATA[Multiple Upload]]></string>
+	<string name="_sys_uploader_html5_drop_area"><![CDATA[Drag and Drop files here to upload]]></string>
+	<string name="_sys_uploader_html5_shoose_file"><![CDATA[Select a file]]></string>
+    <string name="_sys_uploader_html5_title"><![CDATA[Multiple Upload]]></string>
+    <string name="_sys_uploader_html5_default_message"><![CDATA[Drop files here to upload or click here to select files]]></string>
+    <string name="_sys_uploader_html5_file_is_too_big"><![CDATA[File is too big - {{filesize}} MB, max filesize is {{maxFilesize}} MB.]]></string>
+    <string name="_sys_uploader_html5_number_of_files_exceeded"><![CDATA[You can not upload any more files.]]></string>
+    <string name="_sys_uploader_html5_invalid_file_type"><![CDATA[You can't upload files of this type.]]></string>
+	<string name="_sys_uploader_simple_attach_one_more_file"><![CDATA[+ Add more files]]></string>
+	<string name="_sys_uploader_simple_button_name"><![CDATA[Simple Upload]]></string>
+	<string name="_sys_uploader_simple_submit_button"><![CDATA[Upload]]></string>
+	<string name="_sys_uploader_simple_title"><![CDATA[Simple Upload]]></string>
+	<string name="_sys_uploader_upload_canceled"><![CDATA[Too bad. Upload canceled.]]></string>
+	<string name="_sys_edit_profile"><![CDATA[Edit profile]]></string>    
+	<string name="_sys_exit"><![CDATA[Exit]]></string>    
+	<string name="_sys_warn"><![CDATA[warning]]></string>
+	<string name="_sys_x_days"><![CDATA[{0} days]]></string>
+	<string name="_to"><![CDATA[to]]></string>
+	<string name="_top"><![CDATA[Top]]></string>
+	<string name="_uknown"><![CDATA[unknown]]></string>
+	<string name="_undefined"><![CDATA[undefined]]></string>
+	<string name="_view_counter"><![CDATA[{0}]]></string>
+	<string name="_view_do_view"><![CDATA[View]]></string>
+	<string name="_view_do_view_by"><![CDATA[Viewed by]]></string>
+	<string name="_view_do_view_by_counter"><![CDATA[{0} views]]></string>
+	<string name="_view_n_views"><![CDATA[{0} views]]></string>
+	<string name="_vote_counter"><![CDATA[{0}]]></string>
+	<string name="_vote_do_like"><![CDATA[Thank you!]]></string>
+	<string name="_vote_do_unlike"><![CDATA[No thank you]]></string>
+	<string name="_vote_do_by"><![CDATA[Thanked by]]></string>
+        <string name="_vote_do_by_reactions"><![CDATA["{0}" by]]></string>
+	<string name="_vote_err_not_enabled"><![CDATA[The feature is not available right now. Please, try again later.]]></string>
+	<string name="_vote_err_duplicate_vote"><![CDATA[Duplicate vote]]></string>
+        <string name="_vote_n_votes"><![CDATA[{0} votes]]></string>
+	<string name="_week_fri"><![CDATA[Friday]]></string>
+	<string name="_week_mon"><![CDATA[Monday]]></string>
+	<string name="_week_sat"><![CDATA[Saturday]]></string>
+	<string name="_week_sun"><![CDATA[Sunday]]></string>
+	<string name="_week_thu"><![CDATA[Thursday]]></string>
+	<string name="_week_tue"><![CDATA[Tuesday]]></string>
+	<string name="_week_wed"><![CDATA[Wednesday]]></string>
+	<string name="_sys_option_labels"><![CDATA[Labels]]></string>
+	<string name="_sys_option_per_page_browse_showcase"><![CDATA[Number of items in showcase view]]></string>
+	<string name="_sys_option_per_page_browse_recommended"><![CDATA[Number of items in recommended view]]></string>
+	<string name="_sys_javascript_requred"><![CDATA[This site requires JavaScript! Please, enable it in the browser!]]></string>
+	
+</resources>

+ 72 - 0
modules/boonex/english/updates/9.0.14_10.0.0/source/install/config.php

@@ -0,0 +1,72 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    English English language
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_LANGUAGE,
+    'name' => 'bx_en',
+    'title' => 'English',
+    'note' => 'Language file',
+    'version' => '10.0.0',
+    'vendor' => 'Boonex',
+	'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+		'9.0.x',
+        '10.0.x'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/english/',
+    'home_uri' => 'en',
+
+    'db_prefix' => 'bx_eng_',
+    'class_prefix' => 'BxEng',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'BoonEx English',
+
+    /**
+     * Installation/Uninstallation Section.
+     * NOTE. The sequence of actions is critical. Don't change the order.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'install_language' => 1,
+    	'clear_db_cache' => 1
+    ),
+    'uninstall' => array (
+        'update_languages' => 1,
+        'execute_sql' => 1,
+    	'clear_db_cache' => 1
+    ),
+    'enable' => array(
+        'execute_sql' => 1
+    ),
+    'disable' => array(
+        'execute_sql' => 1
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+
+);
+
+/** @} */

+ 34 - 0
modules/boonex/english/updates/9.0.14_10.0.0/source/template/images/icons/std-icon.svg

@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg width="64px" height="64px" viewBox="0 0 64 64" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+    <!-- Generator: Sketch 55 (78076) - https://sketchapp.com -->
+    <title>english</title>
+    <desc>Created with Sketch.</desc>
+    <defs>
+        <path d="M32,64 C46.0222222,64 53.8173667,64 58.9086889,58.9086889 C64,53.8173667 64,46.0222222 64,32 C64,17.9777778 64,10.1826333 58.9086889,5.09131111 C53.8173667,0 46.0222222,0 32,0 C17.9777778,0 10.1826333,0 5.09131111,5.09131111 C0,10.1826333 0,17.9777778 0,32 C0,46.0222222 0,53.8173667 5.09131111,58.9086889 C10.1826333,64 17.9777778,64 32,64 Z" id="path-1"></path>
+        <linearGradient x1="50%" y1="0%" x2="50%" y2="100%" id="linearGradient-3">
+            <stop stop-color="#FDFEFF" offset="0%"></stop>
+            <stop stop-color="#FBFCFD" stop-opacity="0.9" offset="100%"></stop>
+        </linearGradient>
+        <path d="M14.768,43 C13.893329,43 13.2213357,42.7653357 12.752,42.296 C12.2826643,41.8266643 12.048,41.154671 12.048,40.28 L12.048,23.16 C12.048,22.285329 12.2826643,21.6133357 12.752,21.144 C13.2213357,20.6746643 13.893329,20.44 14.768,20.44 L25.84,20.44 C26.7573379,20.44 27.4506643,20.6319981 27.92,21.016 C28.3893357,21.4000019 28.624,21.954663 28.624,22.68 C28.624,24.2160077 27.6960093,24.984 25.84,24.984 L17.776,24.984 L17.776,29.272 L25.2,29.272 C27.0560093,29.272 27.984,30.0293258 27.984,31.544 C27.984,32.269337 27.7493357,32.8239981 27.28,33.208 C26.8106643,33.5920019 26.1173379,33.784 25.2,33.784 L17.776,33.784 L17.776,38.456 L25.84,38.456 C27.6960093,38.456 28.624,39.2239923 28.624,40.76 C28.624,41.485337 28.3893357,42.0399981 27.92,42.424 C27.4506643,42.8080019 26.7573379,43 25.84,43 L14.768,43 Z M48.496,20.28 C49.3066707,20.28 49.9733307,20.546664 50.496,21.08 C51.0186693,21.613336 51.28,22.3066624 51.28,23.16 L51.28,40.28 C51.28,41.154671 51.0240026,41.858664 50.512,42.392 C49.9999974,42.925336 49.3386707,43.192 48.528,43.192 C47.5679952,43.192 46.8426691,42.8720032 46.352,42.232 L36.624,30.104 L36.624,40.28 C36.624,41.154671 36.3786691,41.858664 35.888,42.392 C35.3973309,42.925336 34.7360042,43.192 33.904,43.192 C33.0933293,43.192 32.4320026,42.925336 31.92,42.392 C31.4079974,41.858664 31.152,41.154671 31.152,40.28 L31.152,23.16 C31.152,22.3066624 31.4079974,21.613336 31.92,21.08 C32.4320026,20.546664 33.0933293,20.28 33.904,20.28 C34.8213379,20.28 35.5359974,20.5999968 36.048,21.24 L45.776,33.336 L45.776,23.16 C45.776,22.285329 46.0266642,21.5866693 46.528,21.064 C47.0293358,20.5413307 47.6853293,20.28 48.496,20.28 Z" id="path-4"></path>
+        <filter x="-5.1%" y="-4.4%" width="110.2%" height="117.5%" filterUnits="objectBoundingBox" id="filter-5">
+            <feOffset dx="0" dy="1" in="SourceAlpha" result="shadowOffsetOuter1"></feOffset>
+            <feGaussianBlur stdDeviation="0.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
+            <feColorMatrix values="0 0 0 0 0   0 0 0 0 0   0 0 0 0 0  0 0 0 0.1 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
+        </filter>
+    </defs>
+    <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
+        <g id="Artboard" transform="translate(-340.000000, -266.000000)">
+            <g id="english" transform="translate(340.000000, 266.000000)">
+                <mask id="mask-2" fill="white">
+                    <use xlink:href="#path-1"></use>
+                </mask>
+                <use id="Path" fill="#8B73AE" xlink:href="#path-1"></use>
+                <g id="EN" fill-rule="nonzero" mask="url(#mask-2)">
+                    <use fill="black" fill-opacity="1" filter="url(#filter-5)" xlink:href="#path-4"></use>
+                    <use fill="#323C46" xlink:href="#path-4"></use>
+                    <use fill="url(#linearGradient-3)" xlink:href="#path-4"></use>
+                </g>
+            </g>
+        </g>
+    </g>
+</svg>

+ 7 - 3
modules/boonex/posts/updates/9.0.11_10.0.0/install/installer.php

@@ -27,11 +27,15 @@ class BxPostsUpdater extends BxDolStudioUpdater
 
         $aResult = parent::update($aParams);
         if($aResult['result']) {
-            if($aStorage['engine'] == 'Local')
-                rename(BX_DIRECTORY_PATH_ROOT . 'storage/bx_posts_files/', BX_DIRECTORY_PATH_ROOT . 'storage/bx_posts_covers/');
+            if($aStorage['engine'] == 'Local') {
+                $sSrc = BX_DIRECTORY_PATH_ROOT . 'storage/bx_posts_files/';
+                $sDst = BX_DIRECTORY_PATH_ROOT . 'storage/bx_posts_covers/';
+                if(file_exists($sSrc))
+                    rename($sSrc, $sDst);
+            }
         }
 
-        return $bResult;
+        return $aResult;
     }
 
     public function actionExecuteSql($sOperation)

+ 77 - 0
modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/install/config.php

@@ -0,0 +1,77 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    QuoteOfTheDay Quote of the Day
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_quoteofday',
+    'title' => 'Quote of the Day',
+    'note' => 'Quote of the Day module.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+    'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/quoteofday/',
+    'home_uri' => 'quoteofday',
+
+    'db_prefix' => 'bx_quoteofday_',
+    'class_prefix' => 'BxQuoteOfDay',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Quote Of Day',
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'uninstall' => array (
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable_success' => array(
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable_failed' => array (
+        'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+);
+
+/** @} */

+ 38 - 0
modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+	<string name="_bx_quoteofday"><![CDATA[Quote of the Day]]></string>
+	<string name="_bx_quoteofday_option_rss_url"><![CDATA[Url of external RSS feed]]></string>
+	<string name="_bx_quoteofday_lmi_cpt_quotes"><![CDATA[Quotes List]]></string>
+	<string name="_bx_quoteofday_source"><![CDATA[Source]]></string>
+	<string name="_bx_quoteofday_rss_max_items"><![CDATA[Max number of items from RSS]]></string>
+	<string name="_bx_quoteofday_source_internal"><![CDATA[Internal List]]></string>
+	<string name="_bx_quoteofday_source_rss"><![CDATA[Rss feed]]></string>
+	
+	<string name="_bx_quoteofday_grid_column_title_adm_active"><![CDATA[Active]]></string>
+	<string name="_bx_quoteofday_grid_column_title_adm_text"><![CDATA[Text]]></string>
+	<string name="_bx_quoteofday_grid_column_title_adm_added"><![CDATA[Added]]></string>
+	<string name="_bx_quoteofday_grid_action_title_adm_add"><![CDATA[Add new]]></string>
+	<string name="_bx_quoteofday_grid_action_title_adm_edit"><![CDATA[Edit]]></string>
+	<string name="_bx_quoteofday_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+	<string name="_bx_quoteofday_grid_action_title_adm_publish"><![CDATA[Mark as Today Quote]]></string>
+	<string name="_bx_quoteofday_grid_action_title_adm_publish_text"><![CDATA[Item set as Today Quote]]></string>
+	
+	<string name="_bx_quoteofday_form_entry"><![CDATA[Quote of the Day]]></string>
+	<string name="_bx_quoteofday_form_entry_input_do_submit"><![CDATA[Save]]></string>
+	<string name="_bx_quoteofday_form_add_title"><![CDATA[Add new]]></string>
+	<string name="_bx_quoteofday_form_entry_input_text"><![CDATA[Text]]></string>
+	<string name="_bx_quoteofday_form_edit_title"><![CDATA[Edit]]></string>
+	<string name="_bx_quoteofday_form_entry_input_cancel"><![CDATA[Cancel]]></string>
+	<string name="_bx_quoteofday_form_entry_input_text_err"><![CDATA[Text field can't be empty]]></string>
+	
+	<string name="_bx_quoteofday_page_title_manage"><![CDATA[Quote of the Day management]]></string>
+	<string name="_bx_quoteofday_page_block_title_manage"><![CDATA[Quote of the Day management]]></string>
+	<string name="_bx_quoteofday_page_block_title"><![CDATA[Quote of the Day]]></string>
+	
+	<string name="_bx_quoteofday_menu_item_title_system_admt_manage"><![CDATA[Quotes of the day]]></string>
+	<string name="_bx_quoteofday_adm_stg_cpt_type"><![CDATA[Quote of the Day]]></string>
+	
+	<string name="_bx_quoteofday_selection_mode"><![CDATA[Quote of the Day selected by]]></string>
+	<string name="_bx_quoteofday_selection_mode_by_order"><![CDATA[By order]]></string>
+	<string name="_bx_quoteofday_selection_mode_by_random"><![CDATA[By random]]></string>
+</resources>

+ 59 - 0
modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,59 @@
+SET @sName = 'bx_quoteofday';
+
+-- SETTINGS
+SET @iTypeOrder = (SELECT IFNULL(MAX(`order`), 0) + 1 FROM `sys_options_types` WHERE `group` = 'modules');
+
+INSERT INTO `sys_options_types` (`group`, `name`, `caption`, `icon`, `order`) 
+VALUES('modules', @sName, '_bx_quoteofday_adm_stg_cpt_type', 'bx_quoteofday@modules/boonex/quoteofday/|std-icon.svg', IF(ISNULL(@iTypeOrder), 1, @iTypeOrder + 1));
+
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `hidden`, `order`) VALUES(@iTypeId,  'bx_quoteofday_general', '_bx_quoteofday_adm_stg_cpt_category_general', 0, 1);
+SET @iCategoryId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`category_id`, `name`, `caption`, `value`, `type`, `extra`, `check`, `check_params`, `check_error`, `order`) VALUES
+(@iCategoryId, 'bx_quoteofday_source', '_bx_quoteofday_source', 'internal', 'list', 'a:2:{s:6:"module";s:13:"bx_quoteofday";s:6:"method";s:11:"get_sources";}', '', '', '', 1),
+(@iCategoryId, 'bx_quoteofday_rss_url', '_bx_quoteofday_option_rss_url', '', 'digit', '', '', '', '', 2),
+(@iCategoryId, 'bx_quoteofday_rss_max_items', '_bx_quoteofday_rss_max_items', '5', 'digit', '', '', '', '', 3),
+(@iCategoryId, 'bx_quoteofday_selection_mode', '_bx_quoteofday_selection_mode', 'byrandom', 'select', 'a:2:{s:6:"module";s:13:"bx_quoteofday";s:6:"method";s:18:"get_selection_mode";}', '', '', '', 4);
+
+-- GRIDS: moderation tools
+INSERT INTO `sys_objects_grid` (object, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) 
+VALUES('bx_quoteofday_internal', 'Sql', 'SELECT * FROM `bx_quoteofday_internal` WHERE 1 ', 'bx_quoteofday_internal', 'id', 'added', 'status', '', 20, NULL, 'start', '', 'text', '', 'auto', '', '', 192, 'BxQuoteOfDayGridInternal', 'modules/boonex/quoteofday/classes/BxQuoteOfDayGridInternal.php');
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
+('bx_quoteofday_internal', 'checkbox', '_sys_select', '2%', 0, 0, '', 1),
+('bx_quoteofday_internal', 'switcher', '_bx_quoteofday_grid_column_title_adm_active', '8%', 0, 0, '', 2),
+('bx_quoteofday_internal', 'text', '_bx_quoteofday_grid_column_title_adm_text', '70%', 0, 100, '', 3),
+('bx_quoteofday_internal', 'actions', '', '20%', 0, 0, '', 5);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon_only`, `confirm`, `order`) VALUES
+('bx_quoteofday_internal', 'single', 'edit', '_bx_quoteofday_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_quoteofday_internal', 'single', 'publish', '_bx_quoteofday_grid_action_title_adm_publish', 'quote-right', 1, 0, 3),
+('bx_quoteofday_internal', 'single', 'delete', '_bx_quoteofday_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_quoteofday_internal', 'bulk', 'delete', '_bx_quoteofday_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_quoteofday_internal', 'independent', 'add', '_bx_quoteofday_grid_action_title_adm_add', '', 0, 0, 1);
+
+-- PAGE: add block to homepage
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = 'sys_home' AND `cell_id` = 1 ORDER BY `order` DESC LIMIT 1);
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `hidden_on`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES('sys_home', 1, @sName, '', '_bx_quoteofday_page_block_title', 11, 2147483647, '0', 'service', 'a:2:{s:6:"module";s:13:"bx_quoteofday";s:6:"method";s:9:"get_quote";}', 1, 1, 1, IFNULL(@iBlockOrder, 0) + 1);
+
+-- PAGE: create entry
+INSERT INTO `sys_objects_page` (`object`, `uri`, `title_system`, `title`, `module`, `cover`, `cover_image`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES('bx_quoteofday_manage', 'quoteofday-manage', '_bx_quoteofday_page_title_manage', '_bx_quoteofday_page_title_manage', @sName, 1, 0, 5, 2147483647, 1, 'page.php?i=quoteofday-manage', '', '', '', 0, 1, 0, '', '');
+
+INSERT INTO `sys_pages_blocks` (object, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `hidden_on`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES('bx_quoteofday_manage', 1, @sName, '_bx_quoteofday_page_block_title_manage', '_bx_quoteofday_page_block_title_manage', 11, 2147483647, '0', 'service', 'a:2:{s:6:"module";s:13:"bx_quoteofday";s:6:"method";s:17:"get_quotes_manage";}', 0, 1, 1, 1);
+
+-- MENU: dashboard manage tools
+SET @iManageMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard_manage_tools' LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) 
+VALUES('sys_account_dashboard_manage_tools', @sName, 'quoteofday-manage', '_bx_quoteofday_menu_item_title_system_admt_manage', '_bx_quoteofday_menu_item_title_system_admt_manage', 'page.php?i=quoteofday-manage', '', '_self', 'quote-right', 'a:2:{s:6:"module";s:13:"bx_quoteofday";s:6:"method";s:27:"get_menu_addon_manage_tools";}', '', 0, 2147483647, 1, 0, 1, 6);
+
+-- ALERTS
+INSERT INTO `sys_alerts_handlers` (`name`, `class`, `file`, `service_call`) VALUES 
+(@sName, 'BxQuoteOfDayAlertsResponse', 'modules/boonex/quoteofday/classes/BxQuoteOfDayAlertsResponse.php', '');
+SET @iHandler := LAST_INSERT_ID();
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('system', 'save_setting', @iHandler);
+

+ 37 - 0
modules/boonex/quoteofday/updates/9.0.4_10.0.0/source/template/images/icons/std-icon.svg

@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg width="64px" height="64px" viewBox="0 0 64 64" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+    <!-- Generator: Sketch 55 (78076) - https://sketchapp.com -->
+    <title>quotes</title>
+    <desc>Created with Sketch.</desc>
+    <defs>
+        <path d="M32,64 C46.0222222,64 53.8173667,64 58.9086889,58.9086889 C64,53.8173667 64,46.0222222 64,32 C64,17.9777778 64,10.1826333 58.9086889,5.09131111 C53.8173667,0 46.0222222,0 32,0 C17.9777778,0 10.1826333,0 5.09131111,5.09131111 C0,10.1826333 0,17.9777778 0,32 C0,46.0222222 0,53.8173667 5.09131111,58.9086889 C10.1826333,64 17.9777778,64 32,64 Z" id="path-1"></path>
+        <linearGradient x1="50%" y1="0%" x2="50%" y2="100%" id="linearGradient-3">
+            <stop stop-color="#FDFEFF" offset="0%"></stop>
+            <stop stop-color="#FBFCFD" stop-opacity="0.9" offset="100%"></stop>
+        </linearGradient>
+        <path d="M35.34375,0 L25.59375,0 C23.5751953,0 21.9375,1.63769531 21.9375,3.65625 L21.9375,13.40625 C21.9375,15.4248047 23.5751953,17.0625 25.59375,17.0625 L31.6875,17.0625 L31.6875,21.9375 C31.6875,24.6263672 29.5013672,26.8125 26.8125,26.8125 L26.203125,26.8125 C25.1900391,26.8125 24.375,27.6275391 24.375,28.640625 L24.375,32.296875 C24.375,33.3099609 25.1900391,34.125 26.203125,34.125 L26.8125,34.125 C33.5460938,34.125 39,28.6710938 39,21.9375 L39,3.65625 C39,1.63769531 37.3623047,0 35.34375,0 Z M13.40625,0 L3.65625,0 C1.63769531,0 0,1.63769531 0,3.65625 L0,13.40625 C0,15.4248047 1.63769531,17.0625 3.65625,17.0625 L9.75,17.0625 L9.75,21.9375 C9.75,24.6263672 7.56386719,26.8125 4.875,26.8125 L4.265625,26.8125 C3.25253906,26.8125 2.4375,27.6275391 2.4375,28.640625 L2.4375,32.296875 C2.4375,33.3099609 3.25253906,34.125 4.265625,34.125 L4.875,34.125 C11.6085938,34.125 17.0625,28.6710938 17.0625,21.9375 L17.0625,3.65625 C17.0625,1.63769531 15.4248047,0 13.40625,0 Z" id="path-4"></path>
+        <filter x="-5.1%" y="-2.9%" width="110.3%" height="111.7%" filterUnits="objectBoundingBox" id="filter-5">
+            <feOffset dx="0" dy="1" in="SourceAlpha" result="shadowOffsetOuter1"></feOffset>
+            <feGaussianBlur stdDeviation="0.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
+            <feColorMatrix values="0 0 0 0 0   0 0 0 0 0   0 0 0 0 0  0 0 0 0.1 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
+        </filter>
+    </defs>
+    <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
+        <g id="Artboard" transform="translate(-1879.000000, -430.000000)">
+            <g id="quotes" transform="translate(1879.000000, 430.000000)">
+                <mask id="mask-2" fill="white">
+                    <use xlink:href="#path-1"></use>
+                </mask>
+                <use id="Path" fill="#00B356" xlink:href="#path-1"></use>
+                <g id="quote-right" mask="url(#mask-2)" fill-rule="nonzero">
+                    <g transform="translate(13.000000, 16.000000)" id="Shape">
+                        <g>
+                            <use fill="black" fill-opacity="1" filter="url(#filter-5)" xlink:href="#path-4"></use>
+                            <use fill="url(#linearGradient-3)" xlink:href="#path-4"></use>
+                        </g>
+                    </g>
+                </g>
+            </g>
+        </g>
+    </g>
+</svg>

+ 186 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/classes/BxShopifyConfig.php

@@ -0,0 +1,186 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Shopify Shopify
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxShopifyConfig extends BxBaseModTextConfig
+{
+    protected $_aHtmlIds;
+
+    function __construct($aModule)
+    {
+        parent::__construct($aModule);
+
+        $aMenuItems2Methods = array (
+            'edit-shopify-entry' => 'checkAllowedEdit',
+            'delete-shopify-entry' => 'checkAllowedDelete',
+        );
+
+        $this->CNF = array (
+
+            // module icon
+            'ICON' => 'shopping-cart col-green1',
+
+            // database tables
+            'TABLE_ENTRIES' => $aModule['db_prefix'] . 'entries',
+            'TABLE_SETTINGS' => $aModule['db_prefix'] . 'settings',
+            'TABLE_ENTRIES_FULLTEXT' => 'title_text',
+
+            // database fields
+            'FIELD_ID' => 'id',
+            'FIELD_AUTHOR' => 'author',
+            'FIELD_ADDED' => 'added',
+            'FIELD_CHANGED' => 'changed',
+            'FIELD_CODE' => 'code',
+            'FIELD_TITLE' => 'title',
+            'FIELD_TEXT' => 'text',
+            'FIELD_TEXT_ID' => 'shopify-entry-text',
+            'FIELD_CATEGORY' => 'cat',
+            'FIELD_ALLOW_VIEW_TO' => 'allow_view_to',
+            'FIELD_PHOTO' => '',
+            'FIELD_THUMB' => '',
+            'FIELD_VIEWS' => 'views',
+            'FIELD_COMMENTS' => 'comments',
+            'FIELD_STATUS' => 'status',
+            'FIELD_STATUS_ADMIN' => 'status_admin',
+            'FIELD_LOCATION_PREFIX' => 'location',
+            'FIELDS_WITH_KEYWORDS' => 'auto', // can be 'auto', array of fields or comma separated string of field names, works only when OBJECT_METATAGS is specified
+
+            // page URIs
+            'URI_VIEW_ENTRY' => 'view-shopify-entry',
+            'URI_AUTHOR_ENTRIES' => 'shopify-author',
+            'URI_ENTRIES_BY_CONTEXT' => 'shopify-context',
+            'URI_ADD_ENTRY' => 'create-shopify-entry',
+            'URI_EDIT_ENTRY' => 'edit-shopify-entry',
+            'URI_MANAGE_COMMON' => 'shopify-manage',
+
+            'URL_HOME' => 'page.php?i=shopify-home',
+            'URL_POPULAR' => 'page.php?i=shopify-popular',
+            'URL_UPDATED' => 'page.php?i=shopify-updated',
+            'URL_MANAGE_COMMON' => 'page.php?i=shopify-manage',
+            'URL_MANAGE_ADMINISTRATION' => 'page.php?i=shopify-administration',
+            'URL_SETTINGS' => 'page.php?i=shopify-settings',
+
+            // some params
+            'PARAM_CHARS_SUMMARY' => 'bx_shopify_summary_chars',
+            'PARAM_CHARS_SUMMARY_PLAIN' => 'bx_shopify_plain_summary_chars',
+            'PARAM_NUM_RSS' => 'bx_shopify_rss_num',
+            'PARAM_SEARCHABLE_FIELDS' => 'bx_shopify_searchable_fields',
+
+            // objects
+            'OBJECT_STORAGE' => 'bx_shopify_files',
+            'OBJECT_IMAGES_TRANSCODER_PREVIEW' => 'bx_shopify_preview',
+            'OBJECT_IMAGES_TRANSCODER_GALLERY' => 'bx_shopify_gallery',
+            'OBJECT_VIDEOS_TRANSCODERS' => array(),
+            'OBJECT_REPORTS' => 'bx_shopify',
+            'OBJECT_VIEWS' => 'bx_shopify',
+            'OBJECT_VOTES' => 'bx_shopify',
+            'OBJECT_REACTIONS' => 'bx_shopify_reactions',
+            'OBJECT_SCORES' => 'bx_shopify',
+            'OBJECT_FAVORITES' => 'bx_shopify',
+            'OBJECT_FEATURED' => 'bx_shopify',
+            'OBJECT_METATAGS' => 'bx_shopify',
+            'OBJECT_COMMENTS' => 'bx_shopify',
+            'OBJECT_CATEGORY' => 'bx_shopify_cats',
+            'OBJECT_PRIVACY_VIEW' => 'bx_shopify_allow_view_to',
+            'OBJECT_FORM_ENTRY' => 'bx_shopify',
+            'OBJECT_FORM_ENTRY_DISPLAY_VIEW' => 'bx_shopify_entry_view',
+            'OBJECT_FORM_ENTRY_DISPLAY_ADD' => 'bx_shopify_entry_add',
+            'OBJECT_FORM_ENTRY_DISPLAY_EDIT' => 'bx_shopify_entry_edit',
+            'OBJECT_FORM_ENTRY_DISPLAY_DELETE' => 'bx_shopify_entry_delete',
+            'OBJECT_FORM_SETTINGS' => 'bx_shopify_settings',
+            'OBJECT_FORM_SETTINGS_DISPLAY_EDIT' => 'bx_shopify_settings_edit',
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY' => 'bx_shopify_view', // actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY_ALL' => 'bx_shopify_view_actions', // all actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_MY_ENTRIES' => 'bx_shopify_my', // actions menu on my entries page
+            'OBJECT_MENU_SUBMENU' => 'bx_shopify_submenu', // main module submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY' => 'bx_shopify_view_submenu', // view entry submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY_MAIN_SELECTION' => 'shopify-home', // first item in view entry submenu from main module submenu
+            'OBJECT_MENU_SNIPPET_META' => 'bx_shopify_snippet_meta', // menu for snippet meta info
+            'OBJECT_MENU_MANAGE_TOOLS' => 'bx_shopify_menu_manage_tools', //manage menu in content administration tools
+            'OBJECT_GRID_ADMINISTRATION' => 'bx_shopify_administration',
+            'OBJECT_GRID_COMMON' => 'bx_shopify_common',
+            'OBJECT_UPLOADERS' => array('sys_simple', 'sys_html5'),
+
+            // menu items which visibility depends on custom visibility checking
+            'MENU_ITEM_TO_METHOD' => array (
+                'bx_shopify_my' => array (
+                    'create-shopify-entry' => 'checkAllowedAdd',
+                ),
+                'bx_shopify_view' => $aMenuItems2Methods,
+            ),
+
+            // some language keys
+            'T' => array (
+                'txt_sample_single' => '_bx_shopify_txt_sample_single',
+            	'txt_sample_single_with_article' => '_bx_shopify_txt_sample_single_with_article',
+            	'txt_sample_comment_single' => '_bx_shopify_txt_sample_comment_single',
+            	'txt_sample_vote_single' => '_bx_shopify_txt_sample_vote_single',
+                'txt_sample_score_up_single' => '_bx_shopify_txt_sample_score_up_single',
+                'txt_sample_score_down_single' => '_bx_shopify_txt_sample_score_down_single',
+            	'form_field_author' => '_bx_shopify_form_entry_input_author',
+            	'grid_action_err_delete' => '_bx_shopify_grid_action_err_delete',
+            	'grid_txt_account_manager' => '_bx_shopify_grid_txt_account_manager',
+                'filter_item_active' => '_bx_shopify_grid_filter_item_title_adm_active',
+            	'filter_item_hidden' => '_bx_shopify_grid_filter_item_title_adm_hidden',
+            	'filter_item_select_one_filter1' => '_bx_shopify_grid_filter_item_title_adm_select_one_filter1',
+            	'menu_item_manage_my' => '_bx_shopify_menu_item_title_manage_my',
+            	'menu_item_manage_all' => '_bx_shopify_menu_item_title_manage_all',
+                'txt_all_entries_by' => '_bx_shopify_txt_all_entries_by',
+                'txt_all_entries_in' => '_bx_shopify_txt_all_entries_in',
+                'txt_all_entries_by_author' => '_bx_shopify_page_title_browse_by_author',
+                'txt_all_entries_by_context' => '_bx_shopify_page_title_browse_by_context',
+            	'txt_pict_use_as_thumb' => '_bx_shopify_form_entry_input_picture_use_as_thumb'
+            ),
+        );
+
+        $this->_aJsClasses = array(
+            'shop' => 'BxShopifyShop', 
+        	'manage_tools' => 'BxShopifyManageTools'
+        );
+
+        $this->_aJsObjects = array(
+        	'shop' => 'oBxShopifyShop{profile_id}',
+        	'manage_tools' => 'oBxShopifyManageTools'
+        );
+
+        $this->_aGridObjects = array(
+        	'common' => $this->CNF['OBJECT_GRID_COMMON'],
+        	'administration' => $this->CNF['OBJECT_GRID_ADMINISTRATION'],
+        	
+        );
+
+        $sHtmlPrefix = str_replace('_', '-', $this->_sName);
+        $this->_aHtmlIds = array(
+        	'entry_buy' => $sHtmlPrefix . '-entry-buy',
+        	'entry_content' => $sHtmlPrefix . '-entry-content',
+        	'entry_attachments' => $sHtmlPrefix . '-entry-attachments',
+            'entry_attachment_sample' => $sHtmlPrefix . '-entry-attachment-sample',
+
+            'unit' => $sHtmlPrefix . '-unit-',
+        );
+    }
+
+    public function getHtmlIds($sKey = '')
+    {
+        if(empty($sKey))
+            return $this->_aHtmlIds;
+
+        return isset($this->_aHtmlIds[$sKey]) ? $this->_aHtmlIds[$sKey] : '';
+    }
+
+    public function getJsObjectShop($iProfileId)
+    {
+        return bx_replace_markers($this->getJsObject('shop'), array(
+            'profile_id' => $iProfileId
+        ));
+    }
+}
+
+/** @} */

+ 121 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/classes/BxShopifyTemplate.php

@@ -0,0 +1,121 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Shopify Shopify
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+/*
+ * Module representation.
+ */
+class BxShopifyTemplate extends BxBaseModTextTemplate
+{
+    /**
+     * Constructor
+     */
+    function __construct(&$oConfig, &$oDb)
+    {
+        $this->MODULE = 'bx_shopify';
+        parent::__construct($oConfig, $oDb);
+    }
+
+    public function getIncludeCssJs()
+    {
+        $this->addCss(array(
+            'unit.css'
+        ));
+
+        $sProto = bx_proto();
+        $this->addJs(array(
+            $sProto . '://sdks.shopifycdn.com/js-buy-sdk/v1/latest/index.umd.min.js',
+            'shop.js'
+        ));
+    }
+
+    public function getIncludeCode($iProfileId, $aSettings)
+    {
+        if(empty($aSettings))
+            return '';
+
+        $sCode = $this->getJsCode('shop', array(
+            'sDomain' => $aSettings['domain'],
+            'sAccessToken' => $aSettings['access_token'],
+        ));
+
+        $this->addJsTranslation(array(
+            '_bx_shopify_err_load_product',
+            '_bx_shopify_err_load_collection'
+        ));
+
+        return bx_replace_markers($sCode, array(
+            'profile_id' => $iProfileId
+        ));
+    }
+
+    public function entryBuy($aData)
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        return $this->parseHtmlByName('entry-buy.html', array(
+            'js_object' => $this->_oConfig->getJsObjectShop($aData[$CNF['FIELD_AUTHOR']]),
+            'html_id' => $this->_oConfig->getHtmlIds('entry_buy'),
+            'entry_code' => $aData[$CNF['FIELD_CODE']]
+        ));
+    }
+
+    public function entryText ($aData, $sTemplateName = 'entry-text.html')
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $aVars = parent::getTmplVarsText($aData);
+        $aVars = array_merge($aVars, array(
+            'js_object' => $this->_oConfig->getJsObjectShop($aData[$CNF['FIELD_AUTHOR']]),
+            'html_id' => $this->_oConfig->getHtmlIds('entry_content'),
+            'entry_title' => $this->getTitle($aData),
+            'entry_code' => $aData[$CNF['FIELD_CODE']]
+        ));
+
+        return $this->parseHtmlByName($sTemplateName, $aVars);
+    }
+
+    public function entryAttachments ($aData, $aParams = array())
+    {
+        $sPopupId = 'bx-messages-atachment-popup-{id}';
+        return $this->parseHtmlByName('attachments.html', array(
+            'html_id' => $this->_oConfig->getHtmlIds('entry_attachments'),
+            'html_id_sample' => $this->_oConfig->getHtmlIds('entry_attachment_sample'),
+            'popup_id' => $sPopupId,
+            'popup' => BxTemplFunctions::getInstance()->transBox($sPopupId, '<img class="bx-spf-attachment-popup-img" src="" />', true, true),
+        ));
+    }
+
+    public function getJsCode($sType, $aParams = array(), $bWrap = true)
+    {
+        $aParams = array_merge(array(
+            'aHtmlIds' => $this->_oConfig->getHtmlIds()
+        ), $aParams);
+
+        return parent::getJsCode($sType, $aParams, $bWrap);
+    }
+
+    protected function getUnit($aData, $aParams = array())
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $iProfileId = $aData[$CNF['FIELD_AUTHOR']];
+        $sCode = $aData[$CNF['FIELD_CODE']];
+        $sClass = $this->_getUnitClass($aData,(isset($aParams['template_name']) ? $aParams['template_name'] : ''));
+        return array_merge(parent::getUnit($aData, $aParams), array(
+            'js_object' => $this->_oConfig->getJsObjectShop($iProfileId),
+            'js_content' => $this->_oModule->serviceIncludeCode($iProfileId),
+            'class' => (!empty($sClass) ? $sClass . ' ' : '') . $this->_oConfig->getHtmlIds('unit') . $sCode,
+            'entry_code' => $sCode
+        ));
+    }
+}
+
+/** @} */

+ 116 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/config.php

@@ -0,0 +1,116 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Shopify Shopify
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_shopify',
+    'title' => 'Shopify',
+    'note' => 'Shopify shopping module.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+	'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/shopify/',
+    'home_uri' => 'shopify',
+
+    'db_prefix' => 'bx_shopify_',
+    'class_prefix' => 'BxShopify',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Shopify',
+
+    /**
+     * List of page triggers.
+     */
+    'page_triggers' => array (
+    	'trigger_page_profile_view_entry',
+    ),
+    
+    /**
+     * Menu triggers.
+     */
+    'menu_triggers' => array(
+    	'trigger_profile_view_submenu',
+        'trigger_group_view_submenu'
+    ),
+
+	/**
+     * Extended Search Forms.
+     */
+    'esearches' => array(
+        'bx_shopify',
+    	'bx_shopify_cmts',
+    ),
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'uninstall' => array (
+    	'process_esearches' => 1,
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    	'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+    	'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable_success' => array(
+        'process_menu_triggers' => 1,
+        'process_page_triggers' => 1,
+    	'process_esearches' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+    	'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable_failed' => array (
+    	'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+
+    /**
+     * Relations Section
+     */
+    'relations' => array(
+    	'bx_timeline',
+    	'bx_notifications'
+    ),
+
+);
+
+/** @} */

+ 242 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,242 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+
+	<string name="_bx_shopify"><![CDATA[Shopify]]></string>
+	<string name="_bx_shopify_cmts"><![CDATA[Shopify's Reviews]]></string>
+
+	<string name="_bx_shopify_option_per_page_browse"><![CDATA[Number of items per page]]></string>
+	<string name="_bx_shopify_option_per_page_profile"><![CDATA[Number of items on profile page]]></string>
+	<string name="_bx_shopify_option_rss_num"><![CDATA[Number of items in RSS feed]]></string>
+	<string name="_bx_shopify_option_searchable_fields"><![CDATA[Searchable fields for keyword search]]></string>
+
+	<string name="_bx_shopify_form_entry"><![CDATA[Goods]]></string>
+	<string name="_bx_shopify_form_entry_display_add"><![CDATA[Add Goods]]></string>
+	<string name="_bx_shopify_form_entry_display_edit"><![CDATA[Edit Goods]]></string>
+	<string name="_bx_shopify_form_entry_display_delete"><![CDATA[Delete Goods]]></string>
+	<string name="_bx_shopify_form_entry_display_view"><![CDATA[View Goods]]></string>
+	<string name="_bx_shopify_form_entry_input_author"><![CDATA[Author]]></string>
+	<string name="_bx_shopify_form_entry_input_sys_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_shopify_form_entry_input_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_shopify_form_entry_input_sys_do_publish"><![CDATA[Publish]]></string>
+	<string name="_bx_shopify_form_entry_input_do_publish"><![CDATA[Publish]]></string>
+	<string name="_bx_shopify_form_entry_input_sys_code"><![CDATA[Product handle]]></string>
+    <string name="_bx_shopify_form_entry_input_code"><![CDATA[Product handle]]></string>
+    <string name="_bx_shopify_form_entry_input_code_inf"><![CDATA[The Product handle can be found in 'Search engine listing preview' section when you are editing the product in Products section of your Shopify dashboard.]]></string>
+    <string name="_bx_shopify_form_entry_input_code_err"><![CDATA[Product ID is essential. Please, fill in this field.]]></string>
+	<string name="_bx_shopify_form_entry_input_sys_title"><![CDATA[Title]]></string>
+	<string name="_bx_shopify_form_entry_input_title"><![CDATA[Title]]></string>
+	<string name="_bx_shopify_form_entry_input_title_err"><![CDATA[Title is essential. Please, fill in this field]]></string>
+	<string name="_bx_shopify_form_entry_input_sys_cat"><![CDATA[Category]]></string>
+	<string name="_bx_shopify_form_entry_input_cat"><![CDATA[Category]]></string>
+    <string name="_bx_shopify_form_entry_input_cat_err"><![CDATA[Please select category]]></string>
+	<string name="_bx_shopify_form_entry_input_sys_delete_confirm"><![CDATA[Delete confirmation]]></string>
+	<string name="_bx_shopify_form_entry_input_delete_confirm"><![CDATA[I am sure I want to delete this product]]></string>
+	<string name="_bx_shopify_form_entry_input_delete_confirm_info"><![CDATA[This action can not be undone]]></string>
+	<string name="_bx_shopify_form_entry_input_delete_confirm_error"><![CDATA[Please check this checkbox if you really want to delete the product]]></string>
+    <string name="_bx_shopify_form_entry_input_sys_allow_view_to"><![CDATA[Visibility]]></string>
+    <string name="_bx_shopify_form_entry_input_allow_view_to"><![CDATA[Visibility]]></string>
+    <string name="_bx_shopify_form_entry_input_picture_use_as_thumb"><![CDATA[Cover Image]]></string>
+    <string name="_bx_shopify_form_entry_input_sys_date_added"><![CDATA[Created]]></string>
+    <string name="_bx_shopify_form_entry_input_date_added"><![CDATA[Created]]></string>
+    <string name="_bx_shopify_form_entry_input_sys_date_changed"><![CDATA[Updated]]></string>
+    <string name="_bx_shopify_form_entry_input_date_changed"><![CDATA[Updated]]></string>
+
+    <string name="_bx_shopify_form_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_form_settings_display_edit"><![CDATA[Edit Settings]]></string>
+    <string name="_bx_shopify_form_settings_input_sys_domain"><![CDATA[Domain]]></string>
+    <string name="_bx_shopify_form_settings_input_domain"><![CDATA[Domain]]></string>
+    <string name="_bx_shopify_form_settings_input_domain_err"><![CDATA[This field can't be empty]]></string>
+    <string name="_bx_shopify_form_settings_input_sys_access_token"><![CDATA[Storefront access token]]></string>
+    <string name="_bx_shopify_form_settings_input_access_token"><![CDATA[Storefront access token]]></string>
+    <string name="_bx_shopify_form_settings_input_access_token_err"><![CDATA[This field can't be empty]]></string>
+    <string name="_bx_shopify_form_settings_input_sys_do_submit"><![CDATA[Submit]]></string>
+    <string name="_bx_shopify_form_settings_input_do_submit"><![CDATA[Submit]]></string>
+
+	<string name="_bx_shopify_acl_action_create_entry"><![CDATA[Create Goods]]></string>
+	<string name="_bx_shopify_acl_action_delete_entry"><![CDATA[Delete Goods]]></string>
+	<string name="_bx_shopify_acl_action_view_entry"><![CDATA[View Goods]]></string>
+	<string name="_bx_shopify_acl_action_set_thumb"><![CDATA[Set Goods Thumbnail]]></string>
+	<string name="_bx_shopify_acl_action_edit_any_entry"><![CDATA[Edit Any Goods]]></string>
+
+	<string name="_bx_shopify_page_title_sys_create_entry"><![CDATA[New Goods]]></string>
+	<string name="_bx_shopify_page_title_create_entry"><![CDATA[New Item]]></string>
+	<string name="_bx_shopify_page_block_title_create_entry"><![CDATA[New Item]]></string>
+	<string name="_bx_shopify_page_title_sys_edit_entry"><![CDATA[Edit]]></string>
+	<string name="_bx_shopify_page_title_edit_entry"><![CDATA[Edit]]></string>
+	<string name="_bx_shopify_page_block_title_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_shopify_page_title_sys_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_shopify_page_title_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_shopify_page_block_title_delete_entry"><![CDATA[Delete]]></string>
+	<string name="_bx_shopify_page_title_sys_view_entry"><![CDATA[View Goods]]></string>
+	<string name="_bx_shopify_page_title_view_entry"><![CDATA[{title}]]></string>
+	<string name="_bx_shopify_page_block_title_entry_text"><![CDATA[Item Text]]></string>
+	<string name="_bx_shopify_page_title_browse"><![CDATA[Goods]]></string>
+	<string name="_bx_shopify_page_title_search_results"><![CDATA[Goods matching "{0}"]]></string>
+	<string name="_bx_shopify_page_title_browse_by_author"><![CDATA[Goods of {display_name}]]></string>
+  <string name="_bx_shopify_page_title_browse_by_context"><![CDATA[Goods in {display_name}]]></string>
+	<string name="_bx_shopify_page_title_browse_featured"><![CDATA[Featured Goods]]></string>
+    <string name="_bx_shopify_page_title_browse_recent"><![CDATA[Latest Goods]]></string>
+    <string name="_bx_shopify_page_title_browse_popular"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_shopify_page_title_browse_updated"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_shopify_page_title_sys_home"><![CDATA[Goods Home]]></string>
+    <string name="_bx_shopify_page_title_home"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_page_block_title_featured_entries_view_extended"><![CDATA[Featured Goods]]></string>
+    <string name="_bx_shopify_page_block_title_recent_entries"><![CDATA[Latest Goods (Gallery View)]]></string>
+    <string name="_bx_shopify_page_block_title_recent_entries_view_extended"><![CDATA[Latest Goods]]></string>
+    <string name="_bx_shopify_page_block_title_recent_entries_view_full"><![CDATA[Latest Goods (Full View)]]></string>
+    <string name="_bx_shopify_page_block_title_entry_social_sharing"><![CDATA[Share]]></string>
+    <string name="_bx_shopify_page_block_title_entry_author"><![CDATA[Author]]></string>
+    <string name="_bx_shopify_page_block_title_entry_actions"><![CDATA[Actions]]></string>
+    <string name="_bx_shopify_page_block_title_entry_comments"><![CDATA[Comments]]></string>
+    <string name="_bx_shopify_page_block_title_entry_comments_link"><![CDATA[Comments to <a href="{entry_link}">{title}</a>]]></string>
+    <string name="_bx_shopify_page_block_title_entry_location"><![CDATA[Location]]></string>
+    <string name="_bx_shopify_page_block_title_entry_attachments"><![CDATA[Attachments]]></string>
+    <string name="_bx_shopify_page_block_title_entry_all_actions"><![CDATA[All Actions]]></string>
+    <string name="_bx_shopify_page_title_sys_entries_popular"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_shopify_page_title_entries_popular"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_shopify_page_title_sys_entries_updated"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_shopify_page_title_entries_updated"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_shopify_page_block_title_popular_entries"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_shopify_page_block_title_popular_entries_view_extended"><![CDATA[Popular Goods (Extended View)]]></string>
+    <string name="_bx_shopify_page_block_title_popular_entries_view_full"><![CDATA[Popular Goods (Full View)]]></string>
+    <string name="_bx_shopify_page_block_title_updated_entries"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_shopify_page_title_sys_view_entry_comments"><![CDATA[Goods Comments]]></string>
+    <string name="_bx_shopify_page_title_view_entry_comments"><![CDATA[Comments to {title}]]></string>
+    <string name="_bx_shopify_page_title_sys_entries_of_author"><![CDATA[Goods of author]]></string>
+    <string name="_bx_shopify_page_title_entries_of_author"><![CDATA[Goods by {display_name}]]></string>
+    <string name="_bx_shopify_page_title_sys_entries_in_context"><![CDATA[Goods in context]]></string>
+    <string name="_bx_shopify_page_title_entries_in_context"><![CDATA[Goods in {display_name}]]></string>
+    <string name="_bx_shopify_page_block_title_favorites_of_author"><![CDATA[Favorites by <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_shopify_page_block_title_sys_favorites_of_author"><![CDATA[Favorites of author]]></string>
+    <string name="_bx_shopify_page_block_title_entries_of_author"><![CDATA[Goods by <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_shopify_page_block_title_sys_entries_of_author"><![CDATA[Goods of author]]></string>
+    <string name="_bx_shopify_page_block_title_entries_in_context"><![CDATA[Goods in <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_shopify_page_block_title_sys_entries_in_context"><![CDATA[Goods in context]]></string>
+    <string name="_bx_shopify_page_block_title_entries_actions"><![CDATA[Goods actions]]></string>
+    <string name="_bx_shopify_page_block_title_browse_cmts"><![CDATA[Goods' Comments]]></string>
+	<string name="_bx_shopify_page_title_sys_manage"><![CDATA[Manage Own]]></string>
+	<string name="_bx_shopify_page_title_sys_manage_administration"><![CDATA[Manage All]]></string>
+	<string name="_bx_shopify_page_title_manage"><![CDATA[Manage]]></string>
+	<string name="_bx_shopify_page_block_title_system_manage"><![CDATA[Manage Own]]></string>
+	<string name="_bx_shopify_page_block_title_system_manage_administration"><![CDATA[Manage All]]></string>
+	<string name="_bx_shopify_page_block_title_manage"><![CDATA[Manage]]></string>    
+	<string name="_bx_shopify_page_block_title_popular_keywords"><![CDATA[Popular Hashtags]]></string>
+	<string name="_bx_shopify_page_block_title_cats"><![CDATA[Goods Categories]]></string>
+	<string name="_bx_shopify_page_block_title_entry_info"><![CDATA[Info]]></string>
+	<string name="_bx_shopify_page_block_title_my_entries"><![CDATA[My Goods]]></string>
+    <string name="_bx_shopify_page_title_sys_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_page_title_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_page_block_title_system_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_page_block_title_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_page_title_sys_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_shopify_page_title_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_shopify_page_block_title_search_form"><![CDATA[Search Form]]></string>
+    <string name="_bx_shopify_page_block_title_search_results"><![CDATA[Search Results]]></string>
+    <string name="_bx_shopify_page_block_title_search_form_cmts"><![CDATA[Comments Search Form]]></string>
+    <string name="_bx_shopify_page_block_title_search_results_cmts"><![CDATA[Comments Search Results]]></string>
+    <string name="_bx_shopify_page_block_title_sys_recent_entries_view_showcase"><![CDATA[Latest Goods (Showcase View)]]></string>
+    <string name="_bx_shopify_page_block_title_recent_entries_view_showcase"><![CDATA[Latest Goods]]></string>
+    <string name="_bx_shopify_page_block_title_sys_popular_entries_view_showcase"><![CDATA[Popular Goods (Showcase View)]]></string>
+    <string name="_bx_shopify_page_block_title_popular_entries_view_showcase"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_shopify_page_block_title_sys_featured_entries_view_showcase"><![CDATA[Featured Goods (Showcase View)]]></string>
+    <string name="_bx_shopify_page_block_title_featured_entries_view_showcase"><![CDATA[Featured Goods]]></string>
+    <string name="_bx_shopify_page_block_title_sys_entry_context"><![CDATA[Posted in]]></string>
+    <string name="_bx_shopify_page_block_title_entry_context"><![CDATA[Posted in]]></string>
+
+    <string name="_bx_shopify_menu_set_title_view_entry"><![CDATA[Goods Actions]]></string>
+    <string name="_bx_shopify_menu_title_view_entry"><![CDATA[Goods Actions]]></string>
+    <string name="_bx_shopify_menu_title_submenu"><![CDATA[Goods Submenu]]></string>
+    <string name="_bx_shopify_menu_set_title_submenu"><![CDATA[Goods Submenu]]></string>
+    <string name="_bx_shopify_menu_item_title_system_buy_entry"><![CDATA[Buy]]></string>
+    <string name="_bx_shopify_menu_item_title_buy_entry"><![CDATA[Buy]]></string>
+    <string name="_bx_shopify_menu_item_title_system_create_entry"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_item_title_create_entry"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_item_title_system_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_shopify_menu_item_title_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_shopify_menu_item_title_system_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_shopify_menu_item_title_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_shopify_menu_item_title_system_view_entry"><![CDATA[View Goods]]></string>
+    <string name="_bx_shopify_menu_item_title_system_entries_home"><![CDATA[Shop]]></string>
+    <string name="_bx_shopify_menu_item_title_entries_home"><![CDATA[Shop]]></string>
+    <string name="_bx_shopify_menu_item_title_system_entries_public"><![CDATA[Latest]]></string>
+    <string name="_bx_shopify_menu_item_title_entries_public"><![CDATA[Latest]]></string>
+    <string name="_bx_shopify_menu_item_title_system_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_shopify_menu_item_title_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_shopify_menu_item_title_system_entries_manage"><![CDATA[Manage]]></string>
+    <string name="_bx_shopify_menu_item_title_entries_manage"><![CDATA[Manage]]></string>
+    <string name="_bx_shopify_menu_item_title_system_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_menu_item_title_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_shopify_menu_item_title_system_dashboard"><![CDATA[Dashboard]]></string>
+    <string name="_bx_shopify_menu_item_title_dashboard"><![CDATA[Dashboard]]></string>
+    <string name="_bx_shopify_menu_item_title_system_entries_popular"><![CDATA[Popular]]></string>
+    <string name="_bx_shopify_menu_item_title_entries_popular"><![CDATA[Popular]]></string>
+    <string name="_bx_shopify_menu_title_view_entry_submenu"><![CDATA[View Goods Submenu]]></string>
+    <string name="_bx_shopify_menu_set_title_view_entry_submenu"><![CDATA[View Goods Submenu]]></string>
+    <string name="_bx_shopify_menu_item_title_view_entry_submenu_entry"><![CDATA[Item]]></string>
+    <string name="_bx_shopify_menu_item_title_view_entry_submenu_comments"><![CDATA[Comments]]></string>
+    <string name="_bx_shopify_menu_item_title_system_view_entry_comments"><![CDATA[Goods Comments]]></string>
+    <string name="_bx_shopify_menu_item_title_system_view_entries_author"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_item_title_view_entries_author"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_item_title_system_view_entries_in_context"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_item_title_view_entries_in_context"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_title_entries_my"><![CDATA[My Goods Action Menu]]></string>
+    <string name="_bx_shopify_menu_set_title_entries_my"><![CDATA[My Goods Menu]]></string>
+	<string name="_bx_shopify_menu_item_title_system_manage_my_entries"><![CDATA[My goods]]></string>
+    <string name="_bx_shopify_menu_item_title_manage_my_entries"><![CDATA[Goods]]></string>
+    <string name="_bx_shopify_menu_set_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+    <string name="_bx_shopify_menu_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+    <string name="_bx_shopify_menu_item_title_system_manage_account"><![CDATA[Manage account]]></string>
+    <string name="_bx_shopify_menu_item_title_manage_account"><![CDATA[Manage account]]></string>
+	<string name="_bx_shopify_menu_item_title_system_admt_entries"><![CDATA[Goods]]></string>
+	<string name="_bx_shopify_menu_item_title_admt_entries"><![CDATA[Goods]]></string>
+	<string name="_bx_shopify_menu_item_title_manage_my"><![CDATA[My Goods]]></string>
+	<string name="_bx_shopify_menu_item_title_manage_all"><![CDATA[All Goods]]></string>
+	<string name="_bx_shopify_menu_item_title_buy_for"><![CDATA[Buy for {price}]]></string>
+
+	<string name="_bx_shopify_grid_filter_item_title_adm_select_one_filter1"><![CDATA[All Statuses]]></string>
+	<string name="_bx_shopify_grid_filter_item_title_adm_active"><![CDATA[Active]]></string>
+	<string name="_bx_shopify_grid_filter_item_title_adm_hidden"><![CDATA[Hidden]]></string>
+	<string name="_bx_shopify_grid_column_title_adm_active"><![CDATA[Active]]></string>
+    <string name="_bx_shopify_grid_column_title_adm_title"><![CDATA[Title]]></string>
+    <string name="_bx_shopify_grid_column_title_adm_added"><![CDATA[Added]]></string>
+    <string name="_bx_shopify_grid_column_title_adm_author"><![CDATA[Author]]></string>
+    <string name="_bx_shopify_grid_action_title_adm_edit"><![CDATA[Edit]]></string>
+    <string name="_bx_shopify_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+    <string name="_bx_shopify_grid_action_title_adm_more_actions"><![CDATA[More Actions]]></string>
+    <string name="_bx_shopify_grid_action_err_delete"><![CDATA[Cannot delete the selected product(s).]]></string>
+    <string name="_bx_shopify_grid_txt_account_manager"><![CDATA[Redirect to manage account.]]></string>
+
+    <string name="_bx_shopify_chart_growth"><![CDATA[Shopify: Growth]]></string>
+    <string name="_bx_shopify_chart_growth_speed"><![CDATA[Shopify: Growth Speed]]></string>
+
+    <string name="_bx_shopify_search_extended"><![CDATA[Shopify Search]]></string>
+    <string name="_bx_shopify_search_extended_cmts"><![CDATA[Shopify Comments Search]]></string>
+
+    <string name="_bx_shopify_pre_lists_cats"><![CDATA[Goods categories]]></string>
+    <string name="_bx_shopify_cat_automotive_and_industrial"><![CDATA[Automotive & Industrial]]></string>
+    <string name="_bx_shopify_cat_beauty_health_food"><![CDATA[Beauty, Health & Food]]></string>
+    <string name="_bx_shopify_cat_books"><![CDATA[Books]]></string>
+    <string name="_bx_shopify_cat_clothing_shoes_jewelry"><![CDATA[Clothing, Shoes & Jewelry]]></string>
+    <string name="_bx_shopify_cat_electronics_and_computers"><![CDATA[Electronics & Computers]]></string>
+    <string name="_bx_shopify_cat_handmade"><![CDATA[Handmade]]></string>
+    <string name="_bx_shopify_cat_home_garden_tools"><![CDATA[Home, Garden & Tools]]></string>
+    <string name="_bx_shopify_cat_movies_music_games"><![CDATA[Movies, Music & Games]]></string>
+    <string name="_bx_shopify_cat_sports_and_outdoors"><![CDATA[Sports & Outdoors]]></string>
+    <string name="_bx_shopify_cat_toys_kids_baby"><![CDATA[Toys, Kids & Baby]]></string>
+
+    <string name="_bx_shopify_msg_save_settings"><![CDATA[Settings were successfully saved.]]></string>
+    <string name="_bx_shopify_err_save_settings"><![CDATA[Cannot save settings.]]></string>
+    <string name="_bx_shopify_err_not_configured"><![CDATA[You need to configure shop settings first. <a href="{0}">Click here</a>.]]></string>
+    <string name="_bx_shopify_err_load_product"><![CDATA[Cannot load product. Please check your shop settings and product handle.]]></string>
+    <string name="_bx_shopify_err_load_collection"><![CDATA[Cannot load collection. Please check your shop settings.]]></string>
+    <string name="_bx_shopify_err_purchase_product"><![CDATA[Cannot purchase the product.]]></string>
+
+    <string name="_bx_shopify_txt_all_entries_by"><![CDATA[<a href="{0}">All Goods by {1} ({2})</a>]]></string>
+    <string name="_bx_shopify_txt_all_entries_in"><![CDATA[<a href="{0}">All Goods in {1} ({2})</a>]]></string>
+    <string name="_bx_shopify_txt_sample_single"><![CDATA[shop item]]></string>
+    <string name="_bx_shopify_txt_sample_single_with_article"><![CDATA[a shop item]]></string>
+    <string name="_bx_shopify_txt_sample_comment_single"><![CDATA[comment to shop item]]></string>
+    <string name="_bx_shopify_txt_sample_vote_single"><![CDATA[vote to shop item]]></string>
+    <string name="_bx_shopify_txt_sample_score_up_single"><![CDATA[score up vote to shop item]]></string>
+    <string name="_bx_shopify_txt_sample_score_down_single"><![CDATA[score down vote to shop item]]></string>
+</resources>

+ 424 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,424 @@
+
+-- SETTINGS
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types`(`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_shopify', '_bx_shopify', 'bx_shopify@modules/boonex/shopify/|std-icon.svg', IF(ISNULL(@iTypeOrder), 1, @iTypeOrder + 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order`)
+VALUES (@iTypeId, 'bx_shopify', '_bx_shopify', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `check`, `check_error`, `extra`, `order`) VALUES
+('bx_shopify_per_page_browse', '12', @iCategId, '_bx_shopify_option_per_page_browse', 'digit', '', '', '', 10),
+('bx_shopify_per_page_profile', '6', @iCategId, '_bx_shopify_option_per_page_profile', 'digit', '', '', '', 12),
+('bx_shopify_per_page_browse_showcase', '32', @iCategId, '_sys_option_per_page_browse_showcase', 'digit', '', '', '', 15),
+('bx_shopify_rss_num', '10', @iCategId, '_bx_shopify_option_rss_num', 'digit', '', '', '', 20),
+('bx_shopify_searchable_fields', 'title', @iCategId, '_bx_shopify_option_searchable_fields', 'list', '', '', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:21:"get_searchable_fields";}', 30);
+
+-- PAGE: create entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_create_entry', '_bx_shopify_page_title_sys_create_entry', '_bx_shopify_page_title_create_entry', 'bx_shopify', 5, 2147483647, 1, 'create-shopify-entry', 'page.php?i=create-shopify-entry', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_shopify_create_entry', 1, 'bx_shopify', '_bx_shopify_page_block_title_create_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"entity_create";}', 0, 1, 1);
+
+-- PAGE: edit entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_edit_entry', '_bx_shopify_page_title_sys_edit_entry', '_bx_shopify_page_title_edit_entry', 'bx_shopify', 5, 2147483647, 1, 'edit-shopify-entry', '', '', '', '', 0, 1, 0, 'BxShopifyPageEntry', 'modules/boonex/shopify/classes/BxShopifyPageEntry.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_shopify_edit_entry', 1, 'bx_shopify', '_bx_shopify_page_block_title_edit_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:11:"entity_edit";}', 0, 0, 0);
+
+-- PAGE: delete entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_delete_entry', '_bx_shopify_page_title_sys_delete_entry', '_bx_shopify_page_title_delete_entry', 'bx_shopify', 5, 2147483647, 1, 'delete-shopify-entry', '', '', '', '', 0, 1, 0, 'BxShopifyPageEntry', 'modules/boonex/shopify/classes/BxShopifyPageEntry.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_shopify_delete_entry', 1, 'bx_shopify', '_bx_shopify_page_block_title_delete_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"entity_delete";}', 0, 0, 0);
+
+-- PAGE: view entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_view_entry', '_bx_shopify_page_title_sys_view_entry', '_bx_shopify_page_title_view_entry', 'bx_shopify', 12, 2147483647, 1, 'view-shopify-entry', '', '', '', '', 0, 1, 0, 'BxShopifyPageEntry', 'modules/boonex/shopify/classes/BxShopifyPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_shopify_view_entry', 2, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_text', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:17:"entity_text_block";}', 0, 0, 1, 1),
+('bx_shopify_view_entry', 2, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_attachments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:18:"entity_attachments";}', 0, 0, 1, 2),
+('bx_shopify_view_entry', 3, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_author', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"entity_author";}', 0, 0, 1, 3),
+('bx_shopify_view_entry', 3, 'bx_shopify', '_bx_shopify_page_block_title_sys_entry_context', '_bx_shopify_page_block_title_entry_context', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:10:\"bx_shopify\";s:6:\"method\";s:14:\"entity_context\";}', 0, 0, 1, 1),
+('bx_shopify_view_entry', 3, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_info', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:11:"entity_info";}', 0, 0, 1, 2),
+('bx_shopify_view_entry', 3, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_location', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:15:"entity_location";}', 0, 0, 0, 0),
+('bx_shopify_view_entry', 2, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_all_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:18:"entity_all_actions";}', 0, 0, 1, 3),
+('bx_shopify_view_entry', 4, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:14:"entity_actions";}', 0, 0, 0, 0),
+('bx_shopify_view_entry', 4, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_social_sharing', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:21:"entity_social_sharing";}', 0, 0, 0, 0),
+('bx_shopify_view_entry', 2, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_comments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:15:"entity_comments";}', 0, 0, 1, 4),
+('bx_shopify_view_entry', 3, 'bx_shopify', '', '_bx_shopify_page_block_title_entry_location', 3, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:13:"locations_map";s:6:"params";a:2:{i:0;s:10:"bx_shopify";i:1;s:4:"{id}";}s:5:"class";s:20:"TemplServiceMetatags";}', 0, 0, 1, 4);
+
+-- PAGE: view entry comments
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_view_entry_comments', '_bx_shopify_page_title_sys_view_entry_comments', '_bx_shopify_page_title_view_entry_comments', 'bx_shopify', 5, 2147483647, 1, 'view-shopify-entry-comments', '', '', '', '', 0, 1, 0, 'BxShopifyPageEntry', 'modules/boonex/shopify/classes/BxShopifyPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_shopify_view_entry_comments', 1, 'bx_shopify', '_bx_shopify_page_block_title_entry_comments', '_bx_shopify_page_block_title_entry_comments_link', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:15:"entity_comments";}', 0, 0, 1);
+
+-- PAGE: popular entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_popular', '_bx_shopify_page_title_sys_entries_popular', '_bx_shopify_page_title_entries_popular', 'bx_shopify', 5, 2147483647, 1, 'shopify-popular', 'page.php?i=shopify-popular', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_shopify_popular', 1, 'bx_shopify', '_bx_shopify_page_block_title_popular_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:14:"browse_popular";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, 1);
+
+-- PAGE: recently updated entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_updated', '_bx_shopify_page_title_sys_entries_updated', '_bx_shopify_page_title_entries_updated', 'bx_shopify', 5, 2147483647, 1, 'shopify-updated', 'page.php?i=shopify-updated', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_shopify_updated', 1, 'bx_shopify', '_bx_shopify_page_block_title_updated_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:14:"browse_updated";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, 1);
+
+-- PAGE: entries of author
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_author', 'shopify-author', '_bx_shopify_page_title_sys_entries_of_author', '_bx_shopify_page_title_entries_of_author', 'bx_shopify', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxShopifyPageAuthor', 'modules/boonex/shopify/classes/BxShopifyPageAuthor.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_shopify_author', 1, 'bx_shopify', '', '_bx_shopify_page_block_title_entries_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:18:"my_entries_actions";}', 0, 0, 1, 1),
+('bx_shopify_author', 1, 'bx_shopify', '_bx_shopify_page_block_title_sys_favorites_of_author', '_bx_shopify_page_block_title_favorites_of_author', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:15:"browse_favorite";s:6:"params";a:1:{i:0;s:12:"{profile_id}";}}', 0, 1, 1, 2),
+('bx_shopify_author', 1, 'bx_shopify', '_bx_shopify_page_block_title_sys_entries_of_author', '_bx_shopify_page_block_title_entries_of_author', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"browse_author";}', 0, 0, 1, 3);
+
+-- PAGE: entries in context
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_context', 'shopify-context', '_bx_shopify_page_title_sys_entries_in_context', '_bx_shopify_page_title_entries_in_context', 'bx_shopify', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxShopifyPageAuthor', 'modules/boonex/shopify/classes/BxShopifyPageAuthor.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_shopify_context', 1, 'bx_shopify', '_bx_shopify_page_block_title_sys_entries_in_context', '_bx_shopify_page_block_title_entries_in_context', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:10:\"bx_shopify\";s:6:\"method\";s:14:\"browse_context\";}', 0, 0, 1, 1);
+
+-- PAGE: module home
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_home', 'shopify-home', '_bx_shopify_page_title_sys_home', '_bx_shopify_page_title_home', 'bx_shopify', 2, 2147483647, 1, 'page.php?i=shopify-home', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_shopify_home', 1, 'bx_shopify', '', '_bx_shopify_page_block_title_featured_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, 1, 0),
+('bx_shopify_home', 1, 'bx_shopify', '', '_bx_shopify_page_block_title_recent_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, 1, 1),
+('bx_shopify_home', 2, 'bx_shopify', '', '_bx_shopify_page_block_title_popular_keywords', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:14:"keywords_cloud";s:6:"params";a:2:{i:0;s:10:"bx_shopify";i:1;s:10:"bx_shopify";}s:5:"class";s:20:"TemplServiceMetatags";}', 0, 1, 1, 0),
+('bx_shopify_home', 2, 'bx_shopify', '', '_bx_shopify_page_block_title_cats', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:15:"categories_list";s:6:"params";a:2:{i:0;s:15:"bx_shopify_cats";i:1;a:1:{s:10:"show_empty";b:1;}}s:5:"class";s:20:"TemplServiceCategory";}', 0, 1, 1, 1);
+
+-- PAGE: search for entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_search', '_bx_shopify_page_title_sys_entries_search', '_bx_shopify_page_title_entries_search', 'bx_shopify', 5, 2147483647, 1, 'shopify-search', 'page.php?i=shopify-search', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_shopify_search', 1, 'bx_shopify', '_bx_shopify_page_block_title_search_form', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:10:"bx_shopify";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 1),
+('bx_shopify_search', 1, 'bx_shopify', '_bx_shopify_page_block_title_search_results', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:27:"get_results_search_extended";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:10:"bx_shopify";s:10:"show_empty";b:1;}}}', 0, 1, 1, 2),
+('bx_shopify_search', 1, 'bx_shopify', '_bx_shopify_page_block_title_search_form_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:15:"bx_shopify_cmts";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 3),
+('bx_shopify_search', 1, 'bx_shopify', '_bx_shopify_page_block_title_search_results_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:15:"bx_shopify_cmts";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 4);
+
+-- PAGE: module manage own
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_manage', '_bx_shopify_page_title_sys_manage', '_bx_shopify_page_title_manage', 'bx_shopify', 5, 2147483647, 1, 'shopify-manage', 'page.php?i=shopify-manage', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_shopify_manage', 1, 'bx_shopify', '_bx_shopify_page_block_title_system_manage', '_bx_shopify_page_block_title_manage', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:12:"manage_tools";}}', 0, 1, 0);
+
+-- PAGE: module manage all
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_administration', '_bx_shopify_page_title_sys_manage_administration', '_bx_shopify_page_title_manage', 'bx_shopify', 5, 192, 1, 'shopify-administration', 'page.php?i=shopify-administration', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_shopify_administration', 1, 'bx_shopify', '_bx_shopify_page_block_title_system_manage_administration', '_bx_shopify_page_block_title_manage', 11, 192, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:12:"manage_tools";s:6:"params";a:1:{i:0;s:14:"administration";}}', 0, 1, 0);
+
+-- PAGE: module settings
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_settings', '_bx_shopify_page_title_sys_settings', '_bx_shopify_page_title_settings', 'bx_shopify', 5, 2147483647, 1, 'shopify-settings', 'page.php?i=shopify-settings', '', '', '', 0, 1, 0, 'BxShopifyPageBrowse', 'modules/boonex/shopify/classes/BxShopifyPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_shopify_settings', 1, 'bx_shopify', '_bx_shopify_page_block_title_system_settings', '_bx_shopify_page_block_title_settings', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:8:"settings";}}', 0, 1, 0);
+
+-- PAGE: add block to homepage
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = 'sys_home' AND `cell_id` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('sys_home', 1, 'bx_shopify', '_bx_shopify_page_block_title_recent_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"browse_public";s:6:"params";a:2:{i:0;b:0;i:1;b:0;}}', 1, 0, 0, IFNULL(@iBlockOrder, 0) + 1);
+
+-- PAGES: add page block to profiles modules (trigger* page objects are processed separately upon modules enable/disable)
+SET @iPBCellProfile = 3;
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('trigger_page_profile_view_entry', @iPBCellProfile, 'bx_shopify', '_bx_shopify_page_block_title_my_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"browse_author";s:6:"params";a:2:{i:0;s:12:"{profile_id}";i:1;a:2:{s:8:"per_page";s:27:"bx_shopify_per_page_profile";s:13:"empty_message";b:0;}}}', 0, 0, 0);
+
+-- PAGE: service blocks
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = '' AND `cell_id` = 0 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('', 0, 'bx_shopify', '', '_bx_shopify_page_block_title_recent_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"browse_public";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 1),
+
+('', 0, 'bx_shopify', '', '_bx_shopify_page_block_title_recent_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 2),
+('', 0, 'bx_shopify', '', '_bx_shopify_page_block_title_popular_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:14:"browse_popular";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 3),
+('', 0, 'bx_shopify', '', '_bx_shopify_page_block_title_popular_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:14:"browse_popular";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 4),
+('', 0, 'bx_shopify', '_bx_shopify_page_block_title_sys_recent_entries_view_showcase', '_bx_shopify_page_block_title_recent_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:10:\"bx_shopify\";s:6:\"method\";s:13:\"browse_public\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 5),
+('', 0, 'bx_shopify', '_bx_shopify_page_block_title_sys_popular_entries_view_showcase', '_bx_shopify_page_block_title_popular_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:10:\"bx_shopify\";s:6:\"method\";s:14:\"browse_popular\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 6),
+('', 0, 'bx_shopify', '_bx_shopify_page_block_title_sys_featured_entries_view_showcase', '_bx_shopify_page_block_title_featured_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:10:\"bx_shopify\";s:6:\"method\";s:15:\"browse_featured\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 7);
+
+
+-- MENU: add to site menu
+SET @iSiteMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_site' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_site', 'bx_shopify', 'shopify-home', '_bx_shopify_menu_item_title_system_entries_home', '_bx_shopify_menu_item_title_entries_home', 'page.php?i=shopify-home', '', '', 'shopping-cart col-green1', 'bx_shopify_submenu', 2147483647, 1, 1, IFNULL(@iSiteMenuOrder, 0) + 1);
+
+-- MENU: add to homepage menu
+SET @iHomepageMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_homepage' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_homepage', 'bx_shopify', 'shopify-home', '_bx_shopify_menu_item_title_system_entries_home', '_bx_shopify_menu_item_title_entries_home', 'page.php?i=shopify-home', '', '', 'shopping-cart col-green1', 'bx_shopify_submenu', 2147483647, 1, 1, IFNULL(@iHomepageMenuOrder, 0) + 1);
+
+-- MENU: add to "add content" menu
+SET @iAddMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_add_content_links' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_add_content_links', 'bx_shopify', 'create-shopify-entry', '_bx_shopify_menu_item_title_system_create_entry', '_bx_shopify_menu_item_title_create_entry', 'page.php?i=create-shopify-entry', '', '', 'shopping-cart col-green1', '', 2147483647, 1, 1, IFNULL(@iAddMenuOrder, 0) + 1);
+
+-- MENU: actions menu for view entry 
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_view', '_bx_shopify_menu_title_view_entry', 'bx_shopify_view', 'bx_shopify', 9, 0, 1, 'BxShopifyMenuView', 'modules/boonex/shopify/classes/BxShopifyMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_view', 'bx_shopify', '_bx_shopify_menu_set_title_view_entry', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_shopify_view', 'bx_shopify', 'edit-shopify-entry', '_bx_shopify_menu_item_title_system_edit_entry', '_bx_shopify_menu_item_title_edit_entry', 'page.php?i=edit-shopify-entry&id={content_id}', '', '', 'pencil-alt', '', 2147483647, 1, 0, 1),
+('bx_shopify_view', 'bx_shopify', 'delete-shopify-entry', '_bx_shopify_menu_item_title_system_delete_entry', '_bx_shopify_menu_item_title_delete_entry', 'page.php?i=delete-shopify-entry&id={content_id}', '', '', 'remove', '', 2147483647, 1, 0, 2);
+
+-- MENU: all actions menu for view entry 
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_view_actions', '_sys_menu_title_view_actions', 'bx_shopify_view_actions', 'bx_shopify', 15, 0, 1, 'BxShopifyMenuViewActions', 'modules/boonex/shopify/classes/BxShopifyMenuViewActions.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_view_actions', 'bx_shopify', '_sys_menu_set_title_view_actions', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_shopify_view_actions', 'bx_shopify', 'buy-shopify-entry', '_bx_shopify_menu_item_title_system_buy_entry', '_bx_shopify_menu_item_title_buy_entry', '', '', '', '', '', '', 0, 2147483647, 1, 0, 0),
+('bx_shopify_view_actions', 'bx_shopify', 'edit-shopify-entry', '_bx_shopify_menu_item_title_system_edit_entry', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 10),
+('bx_shopify_view_actions', 'bx_shopify', 'delete-shopify-entry', '_bx_shopify_menu_item_title_system_delete_entry', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 20),
+('bx_shopify_view_actions', 'bx_shopify', 'comment', '_sys_menu_item_title_system_va_comment', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 200),
+('bx_shopify_view_actions', 'bx_shopify', 'view', '_sys_menu_item_title_system_va_view', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 210),
+('bx_shopify_view_actions', 'bx_shopify', 'vote', '_sys_menu_item_title_system_va_vote', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 220),
+('bx_shopify_view_actions', 'bx_shopify', 'reaction', '_sys_menu_item_title_system_va_reaction', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 225),
+('bx_shopify_view_actions', 'bx_shopify', 'score', '_sys_menu_item_title_system_va_score', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 230),
+('bx_shopify_view_actions', 'bx_shopify', 'favorite', '_sys_menu_item_title_system_va_favorite', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 240),
+('bx_shopify_view_actions', 'bx_shopify', 'feature', '_sys_menu_item_title_system_va_feature', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 250),
+('bx_shopify_view_actions', 'bx_shopify', 'repost', '_sys_menu_item_title_system_va_repost', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 260),
+('bx_shopify_view_actions', 'bx_shopify', 'report', '_sys_menu_item_title_system_va_report', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 270),
+('bx_shopify_view_actions', 'bx_shopify', 'social-sharing-facebook', '_sys_menu_item_title_system_social_sharing_facebook', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 300),
+('bx_shopify_view_actions', 'bx_shopify', 'social-sharing-twitter', '_sys_menu_item_title_system_social_sharing_twitter', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 320),
+('bx_shopify_view_actions', 'bx_shopify', 'social-sharing-pinterest', '_sys_menu_item_title_system_social_sharing_pinterest', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 330),
+('bx_shopify_view_actions', 'bx_shopify', 'more-auto', '_sys_menu_item_title_system_va_more_auto', '_sys_menu_item_title_va_more_auto', 'javascript:void(0)', '', '', 'ellipsis-v', '', '', 0, 2147483647, 1, 0, 9999);
+
+-- MENU: actions menu for my entries
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_my', '_bx_shopify_menu_title_entries_my', 'bx_shopify_my', 'bx_shopify', 9, 0, 1, 'BxShopifyMenu', 'modules/boonex/shopify/classes/BxShopifyMenu.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_my', 'bx_shopify', '_bx_shopify_menu_set_title_entries_my', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_shopify_my', 'bx_shopify', 'create-shopify-entry', '_bx_shopify_menu_item_title_system_create_entry', '_bx_shopify_menu_item_title_create_entry', 'page.php?i=create-shopify-entry', '', '', 'plus', '', 2147483647, 1, 0, 0);
+
+-- MENU: module sub-menu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_submenu', '_bx_shopify_menu_title_submenu', 'bx_shopify_submenu', 'bx_shopify', 8, 0, 1, 'BxShopifyMenuSubmenu', 'modules/boonex/shopify/classes/BxShopifyMenuSubmenu.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_submenu', 'bx_shopify', '_bx_shopify_menu_set_title_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_shopify_submenu', 'bx_shopify', 'shopify-home', '_bx_shopify_menu_item_title_system_entries_public', '_bx_shopify_menu_item_title_entries_public', 'page.php?i=shopify-home', '', '', '', '', 2147483647, 1, 1, 1),
+('bx_shopify_submenu', 'bx_shopify', 'shopify-popular', '_bx_shopify_menu_item_title_system_entries_popular', '_bx_shopify_menu_item_title_entries_popular', 'page.php?i=shopify-popular', '', '', '', '', 2147483647, 1, 1, 2),
+('bx_shopify_submenu', 'bx_shopify', 'shopify-search', '_bx_shopify_menu_item_title_system_entries_search', '_bx_shopify_menu_item_title_entries_search', 'page.php?i=shopify-search', '', '', '', '', 2147483647, 1, 1, 3),
+('bx_shopify_submenu', 'bx_shopify', 'shopify-manage', '_bx_shopify_menu_item_title_system_entries_manage', '_bx_shopify_menu_item_title_entries_manage', 'page.php?i=shopify-manage', '', '', '', '', 2147483646, 1, 1, 4),
+('bx_shopify_submenu', 'bx_shopify', 'shopify-settings', '_bx_shopify_menu_item_title_system_settings', '_bx_shopify_menu_item_title_settings', 'page.php?i=shopify-settings', '', '', '', '', 2147483646, 1, 1, 5),
+('bx_shopify_submenu', 'bx_shopify', 'shopify-dashboard', '_bx_shopify_menu_item_title_system_dashboard', '_bx_shopify_menu_item_title_dashboard', 'https://{domain}/admin', '', '_blank', '', '', 2147483646, 1, 1, 6);
+
+-- MENU: sub-menu for view entry
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_view_submenu', '_bx_shopify_menu_title_view_entry_submenu', 'bx_shopify_view_submenu', 'bx_shopify', 8, 0, 0, 'BxShopifyMenuView', 'modules/boonex/shopify/classes/BxShopifyMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_view_submenu', 'bx_shopify', '_bx_shopify_menu_set_title_view_entry_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_shopify_view_submenu', 'bx_shopify', 'view-shopify-entry', '_bx_shopify_menu_item_title_system_view_entry', '_bx_shopify_menu_item_title_view_entry_submenu_entry', 'page.php?i=view-shopify-entry&id={content_id}', '', '', '', '', 2147483647, 1, 0, 1),
+('bx_shopify_view_submenu', 'bx_shopify', 'view-shopify-entry-comments', '_bx_shopify_menu_item_title_system_view_entry_comments', '_bx_shopify_menu_item_title_view_entry_submenu_comments', 'page.php?i=view-shopify-entry-comments&id={content_id}', '', '', '', '', 2147483647, 1, 0, 2);
+
+-- MENU: custom menu for snippet meta info
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_snippet_meta', '_sys_menu_title_snippet_meta', 'bx_shopify_snippet_meta', 'bx_shopify', 15, 0, 1, 'BxShopifyMenuSnippetMeta', 'modules/boonex/shopify/classes/BxShopifyMenuSnippetMeta.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_snippet_meta', 'bx_shopify', '_sys_menu_set_title_snippet_meta', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
+('bx_shopify_snippet_meta', 'bx_shopify', 'date', '_sys_menu_item_title_system_sm_date', '_sys_menu_item_title_sm_date', '', '', '', '', '', 2147483647, 1, 0, 1, 1),
+('bx_shopify_snippet_meta', 'bx_shopify', 'author', '_sys_menu_item_title_system_sm_author', '_sys_menu_item_title_sm_author', '', '', '', '', '', 2147483647, 1, 0, 1, 2),
+('bx_shopify_snippet_meta', 'bx_shopify', 'category', '_sys_menu_item_title_system_sm_category', '_sys_menu_item_title_sm_category', '', '', '', '', '', 2147483647, 0, 0, 1, 3),
+('bx_shopify_snippet_meta', 'bx_shopify', 'tags', '_sys_menu_item_title_system_sm_tags', '_sys_menu_item_title_sm_tags', '', '', '', '', '', 2147483647, 0, 0, 1, 4),
+('bx_shopify_snippet_meta', 'bx_shopify', 'views', '_sys_menu_item_title_system_sm_views', '_sys_menu_item_title_sm_views', '', '', '', '', '', 2147483647, 0, 0, 1, 5),
+('bx_shopify_snippet_meta', 'bx_shopify', 'comments', '_sys_menu_item_title_system_sm_comments', '_sys_menu_item_title_sm_comments', '', '', '', '', '', 2147483647, 0, 0, 1, 6);
+
+-- MENU: profile stats
+SET @iNotifMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name` = 'sys_profile_stats' AND `active` = 1 LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
+('sys_profile_stats', 'bx_shopify', 'profile-stats-manage-shopify', '_bx_shopify_menu_item_title_system_manage_my_entries', '_bx_shopify_menu_item_title_manage_my_entries', 'page.php?i=shopify-manage', '', '_self', 'shopping-cart col-green1', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:41:"get_menu_addon_manage_tools_profile_stats";}', '', 2147483646, 1, 0, @iNotifMenuOrder + 1);
+
+-- MENU: manage tools submenu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify_menu_manage_tools', '_bx_shopify_menu_title_manage_tools', 'bx_shopify_menu_manage_tools', 'bx_shopify', 6, 0, 1, 'BxShopifyMenuManageTools', 'modules/boonex/shopify/classes/BxShopifyMenuManageTools.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_shopify_menu_manage_tools', 'bx_shopify', '_bx_shopify_menu_set_title_manage_tools', 0);
+
+--INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+--('bx_shopify_menu_manage_tools', 'bx_shopify', 'delete-with-content', '_bx_shopify_menu_item_title_system_delete_with_content', '_bx_shopify_menu_item_title_delete_with_content', 'javascript:void(0)', 'javascript:{js_object}.onClickDeleteWithContent({content_id});', '_self', 'far trash-alt', '', 128, 1, 0, 0);
+
+-- MENU: dashboard manage tools
+SET @iManageMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard_manage_tools' LIMIT 1);
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_account_dashboard_manage_tools', 'bx_shopify', 'shopify-administration', '_bx_shopify_menu_item_title_system_admt_entries', '_bx_shopify_menu_item_title_admt_entries', 'page.php?i=shopify-administration', '', '_self', 'shopping-cart', 'a:2:{s:6:"module";s:10:"bx_shopify";s:6:"method";s:27:"get_menu_addon_manage_tools";}', '', 192, 1, 0, @iManageMenuOrder + 1);
+
+-- MENU: add menu item to profiles modules (trigger* menu sets are processed separately upon modules enable/disable)
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('trigger_profile_view_submenu', 'bx_shopify', 'shopify-author', '_bx_shopify_menu_item_title_system_view_entries_author', '_bx_shopify_menu_item_title_view_entries_author', 'page.php?i=shopify-author&profile_id={profile_id}', '', '', 'shopping-cart col-green1', '', 2147483647, 1, 0, 0),
+('trigger_group_view_submenu', 'bx_shopify', 'shopify-context', '_bx_shopify_menu_item_title_system_view_entries_in_context', '_bx_shopify_menu_item_title_view_entries_in_context', 'page.php?i=shopify-context&profile_id={profile_id}', '', '', 'shopping-cart col-green1', '', 2147483647, 1, 0, 0);
+ 
+-- PRIVACY 
+INSERT INTO `sys_objects_privacy` (`object`, `module`, `action`, `title`, `default_group`, `table`, `table_field_id`, `table_field_author`, `override_class_name`, `override_class_file`) VALUES
+('bx_shopify_allow_view_to', 'bx_shopify', 'view', '_bx_shopify_form_entry_input_allow_view_to', '3', 'bx_shopify_entries', 'id', 'author', '', '');
+
+-- ACL
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_shopify', 'create entry', NULL, '_bx_shopify_acl_action_create_entry', '', 1, 3);
+SET @iIdActionEntryCreate = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_shopify', 'delete entry', NULL, '_bx_shopify_acl_action_delete_entry', '', 1, 3);
+SET @iIdActionEntryDelete = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_shopify', 'view entry', NULL, '_bx_shopify_acl_action_view_entry', '', 1, 0);
+SET @iIdActionEntryView = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_shopify', 'set thumb', NULL, '_bx_shopify_acl_action_set_thumb', '', 1, 3);
+SET @iIdActionSetThumb = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_shopify', 'edit any entry', NULL, '_bx_shopify_acl_action_edit_any_entry', '', 1, 3);
+SET @iIdActionEntryEditAny = LAST_INSERT_ID();
+
+SET @iUnauthenticated = 1;
+SET @iAccount = 2;
+SET @iStandard = 3;
+SET @iUnconfirmed = 4;
+SET @iPending = 5;
+SET @iSuspended = 6;
+SET @iModerator = 7;
+SET @iAdministrator = 8;
+SET @iPremium = 9;
+
+INSERT INTO `sys_acl_matrix` (`IDLevel`, `IDAction`) VALUES
+
+-- entry create
+(@iStandard, @iIdActionEntryCreate),
+(@iModerator, @iIdActionEntryCreate),
+(@iAdministrator, @iIdActionEntryCreate),
+(@iPremium, @iIdActionEntryCreate),
+
+-- entry delete
+(@iStandard, @iIdActionEntryDelete),
+(@iModerator, @iIdActionEntryDelete),
+(@iAdministrator, @iIdActionEntryDelete),
+(@iPremium, @iIdActionEntryDelete),
+
+-- entry view
+(@iUnauthenticated, @iIdActionEntryView),
+(@iAccount, @iIdActionEntryView),
+(@iStandard, @iIdActionEntryView),
+(@iUnconfirmed, @iIdActionEntryView),
+(@iPending, @iIdActionEntryView),
+(@iModerator, @iIdActionEntryView),
+(@iAdministrator, @iIdActionEntryView),
+(@iPremium, @iIdActionEntryView),
+
+-- set entry thumb
+(@iStandard, @iIdActionSetThumb),
+(@iModerator, @iIdActionSetThumb),
+(@iAdministrator, @iIdActionSetThumb),
+(@iPremium, @iIdActionSetThumb),
+
+-- edit any entry
+(@iModerator, @iIdActionEntryEditAny),
+(@iAdministrator, @iIdActionEntryEditAny);
+
+
+-- SEARCH
+SET @iSearchOrder = (SELECT IFNULL(MAX(`Order`), 0) FROM `sys_objects_search`);
+INSERT INTO `sys_objects_search` (`ObjectName`, `Title`, `Order`, `ClassName`, `ClassPath`) VALUES
+('bx_shopify', '_bx_shopify', @iSearchOrder + 1, 'BxShopifySearchResult', 'modules/boonex/shopify/classes/BxShopifySearchResult.php'),
+('bx_shopify_cmts', '_bx_shopify_cmts', @iSearchOrder + 2, 'BxShopifyCmtsSearchResult', 'modules/boonex/shopify/classes/BxShopifyCmtsSearchResult.php');
+
+
+-- METATAGS
+INSERT INTO `sys_objects_metatags` (`object`, `table_keywords`, `table_locations`, `table_mentions`, `override_class_name`, `override_class_file`) VALUES
+('bx_shopify', 'bx_shopify_meta_keywords', 'bx_shopify_meta_locations', 'bx_shopify_meta_mentions', '', '');
+
+
+-- CATEGORY
+INSERT INTO `sys_objects_category` (`object`, `search_object`, `form_object`, `list_name`, `table`, `field`, `join`, `where`, `override_class_name`, `override_class_file`) VALUES
+('bx_shopify_cats', 'bx_shopify', 'bx_shopify', 'bx_shopify_cats', 'bx_shopify_entries', 'cat', 'INNER JOIN `sys_profiles` ON (`sys_profiles`.`id` = `bx_shopify_entries`.`author`)', 'AND `sys_profiles`.`status` = ''active''', '', '');
+
+
+-- STATS
+SET @iMaxOrderStats = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_statistics`);
+INSERT INTO `sys_statistics` (`module`, `name`, `title`, `link`, `icon`, `query`, `order`) VALUES 
+('bx_shopify', 'bx_shopify', '_bx_shopify', 'page.php?i=shopify-home', 'shopping-cart col-green1', 'SELECT COUNT(*) FROM `bx_shopify_entries` WHERE 1 AND `status` = ''active'' AND `status_admin` = ''active''', @iMaxOrderStats + 1);
+
+
+-- CHARTS
+SET @iMaxOrderCharts = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_objects_chart`);
+INSERT INTO `sys_objects_chart` (`object`, `title`, `table`, `field_date_ts`, `field_date_dt`, `field_status`, `query`, `active`, `order`, `class_name`, `class_file`) VALUES
+('bx_shopify_growth', '_bx_shopify_chart_growth', 'bx_shopify_entries', 'added', '', 'status,status_admin', '', 1, @iMaxOrderCharts + 1, 'BxDolChartGrowth', ''),
+('bx_shopify_growth_speed', '_bx_shopify_chart_growth_speed', 'bx_shopify_entries', 'added', '', 'status,status_admin', '', 1, @iMaxOrderCharts + 2, 'BxDolChartGrowthSpeed', '');
+
+
+-- GRIDS: moderation tools
+INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) VALUES
+('bx_shopify_administration', 'Sql', 'SELECT * FROM `bx_shopify_entries` WHERE 1 ', 'bx_shopify_entries', 'id', 'added', 'status_admin', '', 20, NULL, 'start', '', 'title,text', '', 'like', 'reports', '', 192, 'BxShopifyGridAdministration', 'modules/boonex/shopify/classes/BxShopifyGridAdministration.php'),
+('bx_shopify_common', 'Sql', 'SELECT * FROM `bx_shopify_entries` WHERE 1 ', 'bx_shopify_entries', 'id', 'added', 'status', '', 20, NULL, 'start', '', 'title,text', '', 'like', '', '', 2147483647, 'BxShopifyGridCommon', 'modules/boonex/shopify/classes/BxShopifyGridCommon.php');
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
+('bx_shopify_administration', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_shopify_administration', 'switcher', '_bx_shopify_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_shopify_administration', 'reports', '_sys_txt_reports_title', '5%', 0, '', '', 3),
+('bx_shopify_administration', 'title', '_bx_shopify_grid_column_title_adm_title', '25%', 0, '25', '', 4),
+('bx_shopify_administration', 'added', '_bx_shopify_grid_column_title_adm_added', '20%', 1, '25', '', 5),
+('bx_shopify_administration', 'author', '_bx_shopify_grid_column_title_adm_author', '20%', 0, '25', '', 6),
+('bx_shopify_administration', 'actions', '', '20%', 0, '', '', 7),
+
+('bx_shopify_common', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_shopify_common', 'switcher', '_bx_shopify_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_shopify_common', 'title', '_bx_shopify_grid_column_title_adm_title', '40%', 0, '35', '', 3),
+('bx_shopify_common', 'added', '_bx_shopify_grid_column_title_adm_added', '30%', 1, '25', '', 4),
+('bx_shopify_common', 'actions', '', '20%', 0, '', '', 5);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon_only`, `confirm`, `order`) VALUES
+('bx_shopify_administration', 'bulk', 'delete', '_bx_shopify_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_shopify_administration', 'single', 'edit', '_bx_shopify_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_shopify_administration', 'single', 'delete', '_bx_shopify_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_shopify_administration', 'single', 'settings', '_bx_shopify_grid_action_title_adm_more_actions', 'cog', 1, 0, 3),
+
+('bx_shopify_common', 'bulk', 'delete', '_bx_shopify_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_shopify_common', 'single', 'edit', '_bx_shopify_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_shopify_common', 'single', 'delete', '_bx_shopify_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_shopify_common', 'single', 'settings', '_bx_shopify_grid_action_title_adm_more_actions', 'cog', 1, 0, 3);
+
+
+-- ALERTS
+INSERT INTO `sys_alerts_handlers` (`name`, `class`, `file`, `service_call`) VALUES 
+('bx_shopify', 'BxShopifyAlertsResponse', 'modules/boonex/shopify/classes/BxShopifyAlertsResponse.php', '');
+SET @iHandler := LAST_INSERT_ID();
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('system', 'save_setting', @iHandler),
+('profile', 'delete', @iHandler);

+ 326 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/sql/install.sql

@@ -0,0 +1,326 @@
+SET @sStorageEngine = (SELECT `value` FROM `sys_options` WHERE `name` = 'sys_storage_default');
+
+
+-- TABLE: entries
+CREATE TABLE IF NOT EXISTS `bx_shopify_entries` (
+  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+  `author` int(10) unsigned NOT NULL,
+  `added` int(11) NOT NULL,
+  `changed` int(11) NOT NULL,
+  `title` varchar(255) NOT NULL,
+  `code` varchar(16) NOT NULL default '',
+  `cat` int(11) NOT NULL,
+  `views` int(11) NOT NULL default '0',
+  `rate` float NOT NULL default '0',
+  `votes` int(11) NOT NULL default '0',
+  `rrate` float NOT NULL default '0',
+  `rvotes` int(11) NOT NULL default '0',
+  `score` int(11) NOT NULL default '0',
+  `sc_up` int(11) NOT NULL default '0',
+  `sc_down` int(11) NOT NULL default '0',
+  `favorites` int(11) NOT NULL default '0',
+  `comments` int(11) NOT NULL default '0',
+  `reports` int(11) NOT NULL default '0',
+  `featured` int(11) NOT NULL default '0',
+  `allow_view_to` varchar(16) NOT NULL DEFAULT '3',
+  `status` enum('active','hidden') NOT NULL DEFAULT 'active',
+  `status_admin` enum('active','hidden') NOT NULL DEFAULT 'active',
+  PRIMARY KEY (`id`),
+  FULLTEXT KEY `title_text` (`title`)
+);
+
+-- TABLE: settings
+CREATE TABLE IF NOT EXISTS `bx_shopify_settings` (
+  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+  `author` int(10) unsigned NOT NULL,
+  `domain` varchar(255) NOT NULL,
+  `access_token` varchar(255) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `author` (`author`)
+);
+
+-- TABLE: comments
+CREATE TABLE IF NOT EXISTS `bx_shopify_cmts` (
+  `cmt_id` int(11) NOT NULL AUTO_INCREMENT,
+  `cmt_parent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_vparent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_object_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_author_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_level` int(11) NOT NULL DEFAULT '0',
+  `cmt_text` text NOT NULL,
+  `cmt_mood` tinyint(4) NOT NULL DEFAULT '0',
+  `cmt_rate` int(11) NOT NULL DEFAULT '0',
+  `cmt_rate_count` int(11) NOT NULL DEFAULT '0',
+  `cmt_time` int(11) unsigned NOT NULL DEFAULT '0',
+  `cmt_replies` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`cmt_id`),
+  KEY `cmt_object_id` (`cmt_object_id`,`cmt_parent_id`),
+  FULLTEXT KEY `search_fields` (`cmt_text`)
+);
+
+-- TABLE: votes
+CREATE TABLE IF NOT EXISTS `bx_shopify_votes` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_votes_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_reactions` (
+  `object_id` int(11) NOT NULL default '0',
+  `reaction` varchar(32) NOT NULL default '',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `reaction` (`object_id`, `reaction`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_reactions_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `reaction` varchar(32) NOT NULL default '',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+-- TABLE: views
+CREATE TABLE IF NOT EXISTS `bx_shopify_views_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `viewer_id` int(11) NOT NULL default '0',
+  `viewer_nip` int(11) unsigned NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`viewer_id`,`viewer_nip`)
+);
+
+-- TABLE: metas
+CREATE TABLE IF NOT EXISTS `bx_shopify_meta_keywords` (
+  `object_id` int(10) unsigned NOT NULL,
+  `keyword` varchar(255) NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `keyword` (`keyword`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_meta_locations` (
+  `object_id` int(10) unsigned NOT NULL,
+  `lat` double NOT NULL,
+  `lng` double NOT NULL,
+  `country` varchar(2) NOT NULL,
+  `state` varchar(255) NOT NULL,
+  `city` varchar(255) NOT NULL,
+  `zip` varchar(255) NOT NULL,
+  `street` varchar(255) NOT NULL,
+  `street_number` varchar(255) NOT NULL,
+  PRIMARY KEY (`object_id`),
+  KEY `country_state_city` (`country`,`state`(8),`city`(8))
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_meta_mentions` (
+  `object_id` int(10) unsigned NOT NULL,
+  `profile_id` int(10) unsigned NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `profile_id` (`profile_id`)
+);
+
+-- TABLE: reports
+CREATE TABLE IF NOT EXISTS `bx_shopify_reports` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_reports_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(32) NOT NULL default '',
+  `text` text NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `report` (`object_id`, `author_nip`)
+);
+
+-- TABLE: favorites
+CREATE TABLE IF NOT EXISTS `bx_shopify_favorites_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`author_id`)
+);
+
+-- TABLE: scores
+CREATE TABLE IF NOT EXISTS `bx_shopify_scores` (
+  `object_id` int(11) NOT NULL default '0',
+  `count_up` int(11) NOT NULL default '0',
+  `count_down` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_shopify_scores_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(8) NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+
+-- FORMS
+INSERT INTO `sys_objects_form`(`object`, `module`, `title`, `action`, `form_attrs`, `table`, `key`, `uri`, `uri_title`, `submit_name`, `params`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_shopify', 'bx_shopify', '_bx_shopify_form_entry', '', 'a:1:{s:7:"enctype";s:19:"multipart/form-data";}', 'bx_shopify_entries', 'id', '', '', 'a:2:{i:0;s:9:"do_submit";i:1;s:10:"do_publish";}', '', 0, 1, 'BxShopifyFormEntry', 'modules/boonex/shopify/classes/BxShopifyFormEntry.php'),
+('bx_shopify_settings', 'bx_shopify', '_bx_shopify_form_settings', '', 'a:1:{s:7:"enctype";s:19:"multipart/form-data";}', 'bx_shopify_settings', 'id', '', '', 'do_submit', '', 0, 1, 'BxShopifyFormSettings', 'modules/boonex/shopify/classes/BxShopifyFormSettings.php');
+
+INSERT INTO `sys_form_displays`(`object`, `display_name`, `module`, `view_mode`, `title`) VALUES 
+('bx_shopify', 'bx_shopify_entry_add', 'bx_shopify', 0, '_bx_shopify_form_entry_display_add'),
+('bx_shopify', 'bx_shopify_entry_delete', 'bx_shopify', 0, '_bx_shopify_form_entry_display_delete'),
+('bx_shopify', 'bx_shopify_entry_edit', 'bx_shopify', 0, '_bx_shopify_form_entry_display_edit'),
+('bx_shopify', 'bx_shopify_entry_view', 'bx_shopify', 1, '_bx_shopify_form_entry_display_view'),
+
+('bx_shopify_settings', 'bx_shopify_settings_edit', 'bx_shopify', 0, '_bx_shopify_form_settings_display_edit');
+
+INSERT INTO `sys_form_inputs`(`object`, `module`, `name`, `value`, `values`, `checked`, `type`, `caption_system`, `caption`, `info`, `required`, `collapsed`, `html`, `attrs`, `attrs_tr`, `attrs_wrapper`, `checker_func`, `checker_params`, `checker_error`, `db_pass`, `db_params`, `editable`, `deletable`) VALUES 
+('bx_shopify', 'bx_shopify', 'allow_view_to', '', '', 0, 'custom', '_bx_shopify_form_entry_input_sys_allow_view_to', '_bx_shopify_form_entry_input_allow_view_to', '', 1, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'delete_confirm', 1, '', 0, 'checkbox', '_bx_shopify_form_entry_input_sys_delete_confirm', '_bx_shopify_form_entry_input_delete_confirm', '_bx_shopify_form_entry_input_delete_confirm_info', 1, 0, 0, '', '', '', 'Avail', '', '_bx_shopify_form_entry_input_delete_confirm_error', '', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'do_publish', '_bx_shopify_form_entry_input_do_publish', '', 0, 'submit', '_bx_shopify_form_entry_input_sys_do_publish', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'do_submit', '_bx_shopify_form_entry_input_do_submit', '', 0, 'submit', '_bx_shopify_form_entry_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'location', '', '', 0, 'location', '_sys_form_input_sys_location', '_sys_form_input_location', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'title', '', '', 0, 'text', '_bx_shopify_form_entry_input_sys_title', '_bx_shopify_form_entry_input_title', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_shopify_form_entry_input_title_err', 'Xss', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'code', '', '', 0, 'text', '_bx_shopify_form_entry_input_sys_code', '_bx_shopify_form_entry_input_code', '_bx_shopify_form_entry_input_code_inf', 1, 0, 0, '', '', '', 'Avail', '', '_bx_shopify_form_entry_input_code_err', 'Xss', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'cat', '', '#!bx_shopify_cats', 0, 'select', '_bx_shopify_form_entry_input_sys_cat', '_bx_shopify_form_entry_input_cat', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_shopify_form_entry_input_cat_err', 'Xss', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'added', '', '', 0, 'datetime', '_bx_shopify_form_entry_input_sys_date_added', '_bx_shopify_form_entry_input_date_added', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_shopify', 'bx_shopify', 'changed', '', '', 0, 'datetime', '_bx_shopify_form_entry_input_sys_date_changed', '_bx_shopify_form_entry_input_date_changed', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+
+('bx_shopify_settings', 'bx_shopify', 'domain', '', '', 0, 'text', '_bx_shopify_form_settings_input_sys_domain', '_bx_shopify_form_settings_input_domain', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_shopify_form_settings_input_domain_err', 'Xss', '', 1, 0),
+('bx_shopify_settings', 'bx_shopify', 'access_token', '', '', 0, 'text', '_bx_shopify_form_settings_input_sys_access_token', '_bx_shopify_form_settings_input_access_token', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_shopify_form_settings_input_access_token_err', 'Xss', '', 1, 0),
+('bx_shopify_settings', 'bx_shopify', 'do_submit', '_bx_shopify_form_settings_input_do_submit', '', 0, 'submit', '_bx_shopify_form_settings_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0);
+
+INSERT INTO `sys_form_display_inputs`(`display_name`, `input_name`, `visible_for_levels`, `active`, `order`) VALUES 
+('bx_shopify_entry_add', 'code', 2147483647, 1, 1),
+('bx_shopify_entry_add', 'title', 2147483647, 1, 2),
+('bx_shopify_entry_add', 'cat', 2147483647, 1, 3),
+('bx_shopify_entry_add', 'allow_view_to', 2147483647, 1, 4),
+('bx_shopify_entry_add', 'location', 2147483647, 1, 5),
+('bx_shopify_entry_add', 'do_publish', 2147483647, 1, 6),
+
+('bx_shopify_entry_delete', 'delete_confirm', 2147483647, 1, 1),
+('bx_shopify_entry_delete', 'do_submit', 2147483647, 1, 2),
+
+('bx_shopify_entry_edit', 'code', 2147483647, 1, 1),
+('bx_shopify_entry_edit', 'title', 2147483647, 1, 2),
+('bx_shopify_entry_edit', 'cat', 2147483647, 1, 3),
+('bx_shopify_entry_edit', 'allow_view_to', 2147483647, 1, 4),
+('bx_shopify_entry_edit', 'location', 2147483647, 1, 5),
+('bx_shopify_entry_edit', 'do_submit', 2147483647, 1, 6),
+
+('bx_shopify_entry_view', 'cat', 2147483647, 1, 1),
+('bx_shopify_entry_view', 'added', 2147483647, 1, 2),
+('bx_shopify_entry_view', 'changed', 2147483647, 1, 3),
+
+('bx_shopify_entry_view_full', 'cat', 2147483647, 1, 1),
+('bx_shopify_entry_view_full', 'added', 2147483647, 1, 2),
+('bx_shopify_entry_view_full', 'changed', 2147483647, 1, 3),
+
+('bx_shopify_settings_edit', 'mode', 2147483647, 1, 1),
+('bx_shopify_settings_edit', 'domain', 2147483647, 1, 2),
+('bx_shopify_settings_edit', 'access_token', 2147483647, 1, 3),
+('bx_shopify_settings_edit', 'do_submit', 2147483647, 1, 4);
+
+
+-- PRE-VALUES
+INSERT INTO `sys_form_pre_lists`(`key`, `title`, `module`, `use_for_sets`, `extendable`) VALUES
+('bx_shopify_cats', '_bx_shopify_pre_lists_cats', 'bx_shopify', '0', '1');
+
+INSERT INTO `sys_form_pre_values`(`Key`, `Value`, `Order`, `LKey`, `LKey2`) VALUES
+('bx_shopify_cats', '', 0, '_sys_please_select', ''),
+('bx_shopify_cats', '1', 1, '_bx_shopify_cat_automotive_and_industrial', ''),
+('bx_shopify_cats', '2', 2, '_bx_shopify_cat_beauty_health_food', ''),
+('bx_shopify_cats', '3', 3, '_bx_shopify_cat_books', ''),
+('bx_shopify_cats', '4', 4, '_bx_shopify_cat_clothing_shoes_jewelry', ''),
+('bx_shopify_cats', '5', 5, '_bx_shopify_cat_electronics_and_computers', ''),
+('bx_shopify_cats', '6', 6, '_bx_shopify_cat_handmade', ''),
+('bx_shopify_cats', '7', 7, '_bx_shopify_cat_home_garden_tools', ''),
+('bx_shopify_cats', '8', 8, '_bx_shopify_cat_movies_music_games', ''),
+('bx_shopify_cats', '9', 9, '_bx_shopify_cat_sports_and_outdoors', ''),
+('bx_shopify_cats', '10', 10, '_bx_shopify_cat_toys_kids_baby', '');
+
+
+-- COMMENTS
+INSERT INTO `sys_objects_cmts` (`Name`, `Module`, `Table`, `CharsPostMin`, `CharsPostMax`, `CharsDisplayMax`, `Html`, `PerView`, `PerViewReplies`, `BrowseType`, `IsBrowseSwitch`, `PostFormPosition`, `NumberOfLevels`, `IsDisplaySwitch`, `IsRatable`, `ViewingThreshold`, `IsOn`, `RootStylePrefix`, `BaseUrl`, `ObjectVote`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldTitle`, `TriggerFieldComments`, `ClassName`, `ClassFile`) VALUES
+('bx_shopify', 'bx_shopify', 'bx_shopify_cmts', 1, 5000, 1000, 3, 5, 3, 'tail', 1, 'bottom', 1, 1, 1, -3, 1, 'cmt', 'page.php?i=view-shopify-entry&id={object_id}', '', 'bx_shopify_entries', 'id', 'author', 'title', 'comments', '', '');
+
+
+-- VOTES
+INSERT INTO `sys_objects_vote` (`Name`, `TableMain`, `TableTrack`, `PostTimeout`, `MinValue`, `MaxValue`, `IsUndo`, `IsOn`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldRate`, `TriggerFieldRateCount`, `ClassName`, `ClassFile`) VALUES 
+('bx_shopify', 'bx_shopify_votes', 'bx_shopify_votes_track', '604800', '1', '1', '0', '1', 'bx_shopify_entries', 'id', 'author', 'rate', 'votes', '', ''),
+('bx_shopify_reactions', 'bx_shopify_reactions', 'bx_shopify_reactions_track', '604800', '1', '1', '1', '1', 'bx_shopify_entries', 'id', 'author', 'rrate', 'rvotes', 'BxTemplVoteReactions', '');
+
+
+-- SCORES
+INSERT INTO `sys_objects_score` (`name`, `module`, `table_main`, `table_track`, `post_timeout`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_score`, `trigger_field_cup`, `trigger_field_cdown`, `class_name`, `class_file`) VALUES 
+('bx_shopify', 'bx_shopify', 'bx_shopify_scores', 'bx_shopify_scores_track', '604800', '0', 'bx_shopify_entries', 'id', 'author', 'score', 'sc_up', 'sc_down', '', '');
+
+
+-- REPORTS
+INSERT INTO `sys_objects_report` (`name`, `table_main`, `table_track`, `is_on`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_shopify', 'bx_shopify_reports', 'bx_shopify_reports_track', '1', 'page.php?i=view-shopify-entry&id={object_id}', 'bx_shopify_entries', 'id', 'author', 'reports', '', '');
+
+
+-- VIEWS
+INSERT INTO `sys_objects_view` (`name`, `table_track`, `period`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_shopify', 'bx_shopify_views_track', '86400', '1', 'bx_shopify_entries', 'id', 'author', 'views', '', '');
+
+
+-- FAFORITES
+INSERT INTO `sys_objects_favorite` (`name`, `table_track`, `is_on`, `is_undo`, `is_public`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_shopify', 'bx_shopify_favorites_track', '1', '1', '1', 'page.php?i=view-shopify-entry&id={object_id}', 'bx_shopify_entries', 'id', 'author', 'favorites', '', '');
+
+
+-- FEATURED
+INSERT INTO `sys_objects_feature` (`name`, `is_on`, `is_undo`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_flag`, `class_name`, `class_file`) VALUES 
+('bx_shopify', '1', '1', 'page.php?i=view-shopify-entry&id={object_id}', 'bx_shopify_entries', 'id', 'author', 'featured', '', '');
+
+
+-- CONTENT INFO
+INSERT INTO `sys_objects_content_info` (`name`, `title`, `alert_unit`, `alert_action_add`, `alert_action_update`, `alert_action_delete`, `class_name`, `class_file`) VALUES
+('bx_shopify', '_bx_shopify', 'bx_shopify', 'added', 'edited', 'deleted', '', ''),
+('bx_shopify_cmts', '_bx_shopify_cmts', 'bx_shopify', 'commentPost', 'commentUpdated', 'commentRemoved', 'BxDolContentInfoCmts', '');
+
+INSERT INTO `sys_content_info_grids` (`object`, `grid_object`, `grid_field_id`, `condition`, `selection`) VALUES
+('bx_shopify', 'bx_shopify_administration', 'id', '', ''),
+('bx_shopify', 'bx_shopify_common', 'id', '', '');
+
+
+-- SEARCH EXTENDED
+INSERT INTO `sys_objects_search_extended` (`object`, `object_content_info`, `module`, `title`, `active`, `class_name`, `class_file`) VALUES
+('bx_shopify', 'bx_shopify', 'bx_shopify', '_bx_shopify_search_extended', 1, '', ''),
+('bx_shopify_cmts', 'bx_shopify_cmts', 'bx_shopify', '_bx_shopify_search_extended_cmts', 1, 'BxTemplSearchExtendedCmts', '');
+
+
+-- STUDIO: page & widget
+INSERT INTO `sys_std_pages`(`index`, `name`, `header`, `caption`, `icon`) VALUES
+(3, 'bx_shopify', '_bx_shopify', '_bx_shopify', 'bx_shopify@modules/boonex/shopify/|std-icon.svg');
+SET @iPageId = LAST_INSERT_ID();
+
+SET @iParentPageId = (SELECT `id` FROM `sys_std_pages` WHERE `name` = 'home');
+SET @iParentPageOrder = (SELECT MAX(`order`) FROM `sys_std_pages_widgets` WHERE `page_id` = @iParentPageId);
+INSERT INTO `sys_std_widgets` (`page_id`, `module`, `url`, `click`, `icon`, `caption`, `cnt_notices`, `cnt_actions`) VALUES
+(@iPageId, 'bx_shopify', '{url_studio}module.php?name=bx_shopify', '', 'bx_shopify@modules/boonex/shopify/|std-icon.svg', '_bx_shopify', '', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_actions";s:6:"params";a:0:{}s:5:"class";s:18:"TemplStudioModules";}');
+INSERT INTO `sys_std_pages_widgets` (`page_id`, `widget_id`, `order`) VALUES
+(@iParentPageId, LAST_INSERT_ID(), IF(ISNULL(@iParentPageOrder), 1, @iParentPageOrder + 1));

+ 59 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/install/sql/uninstall.sql

@@ -0,0 +1,59 @@
+
+-- TABLES
+DROP TABLE IF EXISTS `bx_shopify_entries`, `bx_shopify_settings`, `bx_shopify_cmts`, `bx_shopify_votes`, `bx_shopify_votes_track`, `bx_shopify_reactions`, `bx_shopify_reactions_track`, `bx_shopify_views_track`, `bx_shopify_meta_keywords`, `bx_shopify_meta_locations`, `bx_shopify_meta_mentions`, `bx_shopify_reports`, `bx_shopify_reports_track`, `bx_shopify_favorites_track`, `bx_shopify_scores`, `bx_shopify_scores_track`;
+
+
+-- FORMS
+DELETE FROM `sys_objects_form` WHERE `module` = 'bx_shopify';
+DELETE FROM `sys_form_displays` WHERE `module` = 'bx_shopify';
+DELETE FROM `sys_form_inputs` WHERE `module` = 'bx_shopify';
+DELETE FROM `sys_form_display_inputs` WHERE `display_name` IN ('bx_shopify_entry_add', 'bx_shopify_entry_edit', 'bx_shopify_entry_view', 'bx_shopify_entry_view_full', 'bx_shopify_entry_delete', 'bx_shopify_settings_edit');
+
+
+-- PRE-VALUES
+DELETE FROM `sys_form_pre_lists` WHERE `module` = 'bx_shopify';
+DELETE FROM `sys_form_pre_values` WHERE `Key` IN('bx_shopify_cats');
+
+
+-- COMMENTS
+DELETE FROM `sys_objects_cmts` WHERE `Name` = 'bx_shopify';
+
+
+-- VOTES
+DELETE FROM `sys_objects_vote` WHERE `Name` IN ('bx_shopify', 'bx_shopify_reactions');
+
+
+-- SCORES
+DELETE FROM `sys_objects_score` WHERE `name` = 'bx_shopify';
+
+
+-- REPORTS
+DELETE FROM `sys_objects_report` WHERE `name` = 'bx_shopify';
+
+
+-- VIEWS
+DELETE FROM `sys_objects_view` WHERE `name` = 'bx_shopify';
+
+
+-- FAFORITES
+DELETE FROM `sys_objects_favorite` WHERE `name` = 'bx_shopify';
+
+
+-- FEATURED
+DELETE FROM `sys_objects_feature` WHERE `name` = 'bx_shopify';
+
+
+-- CONTENT INFO
+DELETE FROM `sys_objects_content_info` WHERE `name` IN ('bx_shopify', 'bx_shopify_cmts');
+
+DELETE FROM `sys_content_info_grids` WHERE `object` IN ('bx_shopify');
+
+
+-- SEARCH EXTENDED
+DELETE FROM `sys_objects_search_extended` WHERE `module` = 'bx_shopify';
+
+
+-- STUDIO: page & widget
+DELETE FROM `tp`, `tw`, `tpw`
+USING `sys_std_pages` AS `tp`, `sys_std_widgets` AS `tw`, `sys_std_pages_widgets` AS `tpw`
+WHERE `tp`.`id` = `tw`.`page_id` AND `tw`.`id` = `tpw`.`widget_id` AND `tp`.`name` = 'bx_shopify';

+ 14 - 0
modules/boonex/shopify/updates/9.0.7_10.0.0/source/template/entry-text.html

@@ -0,0 +1,14 @@
+<div class="bx-content-description-before">__content_description_before__</div>
+<div class="bx-content-description">
+    <div id="__html_id__" class="bx-base-text-entity-content bx-def-constraint-list bx-def-constraint-pre bx-def-constraint-object bx-def-constraint-iframe bx-def-constraint-img">
+        <h1 class="bx-spf-title">__entry_title__</h1>
+        <div class="bx-spf-text"></div>
+        <div class="bx-spf-images"></div>
+        <script type="text/javascript">
+        $(document).ready(function() {
+            __js_object__.getEntry('__entry_code__');
+        });
+        </script>
+    </div>
+</div>
+<div class="bx-content-description-after">__content_description_after__</div>

+ 51 - 0
modules/boonex/smtpmailer/updates/9.0.4_10.0.0/install/config.php

@@ -0,0 +1,51 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'title' => 'SMTP Mailer',
+    'version_from' => '9.0.4',
+    'version_to' => '10.0.0',
+    'vendor' => 'BoonEx',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/smtpmailer/updates/update_9.0.4_10.0.0/',
+    'home_uri' => 'smtpmailer_update_904_1000',
+
+    'module_dir' => 'boonex/smtpmailer/',
+    'module_uri' => 'smtpmailer',
+
+    'db_prefix' => 'bx_smtp_',
+    'class_prefix' => 'BxSMTP',
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 0,
+        'update_files' => 1,
+        'update_languages' => 0,
+        'clear_db_cache' => 0,
+    ),
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'SMTP Mailer',
+
+    /**
+     * Files Section
+     */
+    'delete_files' => array(),
+);

+ 13 - 0
modules/boonex/smtpmailer/updates/9.0.4_10.0.0/install/installer.php

@@ -0,0 +1,13 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ */
+
+class BxSMTPUpdater extends BxDolStudioUpdater
+{
+    function __construct($aConfig)
+    {
+        parent::__construct($aConfig);
+    }
+}

+ 210 - 0
modules/boonex/smtpmailer/updates/9.0.4_10.0.0/source/classes/BxSMTPModule.php

@@ -0,0 +1,210 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    SMTPMailer SMTP Mailer
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+require_once (BX_DIRECTORY_PATH_PLUGINS . "phpmailer/Exception.php");
+require_once (BX_DIRECTORY_PATH_PLUGINS . "phpmailer/PHPMailer.php");
+require_once (BX_DIRECTORY_PATH_PLUGINS . "phpmailer/SMTP.php");
+
+class BxSMTPModule extends BxDolModule
+{
+    function __construct(&$aModule)
+    {
+        parent::__construct($aModule);
+    }
+
+    function serviceSend ($sRecipientEmail, $sMailSubject, $sMailBody, $sMailHeader, $sMailParameters, $isHtml, $aRecipientInfo = array(), $aCustomHeaders = array())
+    {
+        $iRet = true;
+        $sErrorMessage = '';
+
+        if ($sRecipientEmail) {
+
+            try {
+
+                $mail = new PHPMailer\PHPMailer\PHPMailer(true);
+
+                if ('on' == getParam('bx_smtp_on'))
+                    $mail->IsSMTP();
+                // $mail->SMTPDebug = 2;
+
+                $mail->CharSet = 'UTF-8';
+
+                // smtp server auth or not
+                $mail->SMTPAuth = 'on' == getParam('bx_smtp_auth') ? true : false;
+
+                // from settings, smtp server secure ssl/tls
+                $sParamSecure = getParam('bx_smtp_secure');
+                if ('SSL' == $sParamSecure || 'TLS' == $sParamSecure) {
+
+                    $mail->SMTPSecure = strtolower($sParamSecure);
+
+                    if ('on' == getParam('bx_smtp_allow_selfsigned')) {
+                        $mail->SMTPOptions = array(
+                            'ssl' => array(
+                                'verify_peer' => false,
+                                'verify_peer_name' => false,
+                                'allow_self_signed' => true
+                            )
+                        );
+                    }
+                }
+
+                // from settings, smtp server
+                $sParamHost = getParam('bx_smtp_host');
+                if ($sParamHost)
+                    $mail->Host = $sParamHost;
+
+                // smtp port 25, 465
+                $sParamPort = getParam('bx_smtp_port');
+                if ((int)$sParamPort > 0)
+                    $mail->Port = $sParamPort;
+
+                // from settings, username and passord of smtp server
+                $mail->Username = getParam ('bx_smtp_username');
+                $mail->Password = getParam ('bx_smtp_password');
+
+                if (!isset($aCustomHeaders['From'])) {
+                    $sParamSender = trim(getParam('bx_smtp_from_email'));
+                    if ($sParamSender)
+                        $mail->From = $sParamSender;
+                    else
+                        $mail->From = getParam('site_email_notify');
+
+                    // get site name or some other name as sender's name
+                    $mail->FromName = getParam ('bx_smtp_from_name');
+                } 
+
+                if (!isset($aCustomHeaders['Subject']))
+                    $mail->Subject = $sMailSubject;
+
+                if ($isHtml) {
+                    $mail->Body = $sMailBody;
+                    $mail->AltBody = $isHtml ? strip_tags($sMailBody) : $sMailBody;
+                } else {
+                    $mail->Body = $sMailBody;
+                }
+
+                $mail->WordWrap = 50; // set word wrap
+
+                $mail->AddAddress($sRecipientEmail);
+
+                $mail->IsHTML($isHtml ? true : false);
+
+                foreach ($aCustomHeaders as $sHeaderName => $sHeaderValue) {
+                    if ('From' == $sHeaderName) {
+                        if (preg_match('/(.+)<(.+)>/', $sHeaderValue, $m)) {
+                            $mail->setFrom($m[2], trim($m[1]), false);
+                        }
+                        else {
+                            $mail->setFrom($sHeaderValue, '', false);
+                        }
+                    } 
+                    else {
+                        $mail->addCustomHeader($sHeaderName, $sHeaderValue);
+                    }
+                }
+
+                $mail->Send();
+                
+            } catch (PHPMailer\PHPMailer\Exception $e) {
+                $iRet = false;
+                $sErrorMessage = $e->getMessage();
+                $this->log("Mailer Error ($sRecipientEmail): " . $sErrorMessage);
+            }
+        }
+
+        //--- create system event [begin]
+        $aAlertData = array(
+            'email'     => $sRecipientEmail,
+            'subject'   => $sMailSubject,
+            'body'      => $sMailBody,
+            'header'    => $sMailHeader,
+            'params'    => $sMailParameters,
+            'recipient' => $aRecipientInfo,
+            'html'      => $isHtml,
+            'ret'       => $iRet,
+            'error_message' => $sErrorMessage,
+        );
+        bx_alert('profile', 'send_mail', $aRecipientInfo && isset($aRecipientInfo['ID']) ? $aRecipientInfo['ID'] : 0, '', $aAlertData);
+        //--- create system event [ end ]
+
+        return $iRet;
+    }
+
+    function formTester()
+    {
+        $sMsg  = '';
+        if (isset($_POST['tester_submit']) && $_POST['tester_submit']) {
+
+            $isHTML = bx_get('html') == 'on' ? true : false;
+            $sRecipient = bx_process_pass(bx_get('recipient'));
+            $sSubj = bx_get('subject');
+            $sBody = bx_process_pass(bx_get('body'), $isHTML ? BX_DATA_HTML : BX_DATA_TEXT);
+
+            if (sendMail($sRecipient, $sSubj, $sBody, 0, array(), BX_EMAIL_SYSTEM, $isHTML ? 'html' : ''))
+                $sMsg = MsgBox(_t('_bx_smtp_send_ok'));
+            else
+                $sMsg = MsgBox(_t('_bx_smtp_send_fail'));
+        }
+
+        $aForm = array(
+            'form_attrs' => array(
+                'method'   => 'post',
+            ),
+            'inputs' => array (
+                'recipient' => array(
+                    'type' => 'text',
+                    'name' => 'recipient',
+                    'caption' => _t('_bx_smtp_recipient'),
+                    'value' => '',
+                ),
+                'subject' => array(
+                    'type' => 'text',
+                    'name' => 'subject',
+                    'caption' => _t('_bx_smtp_subject'),
+                    'value' => '',
+                ),
+                'body' => array(
+                    'type' => 'textarea',
+                    'name' => 'body',
+                    'caption' => _t('_bx_smtp_body'),
+                    'value' => '',
+                ),
+                'html' => array(
+                    'type' => 'checkbox',
+                    'name' => 'html',
+                    'caption' => _t('_bx_smtp_is_html'),
+                    'checked' => false,
+                ),
+                'Submit' => array(
+                    'type' => 'submit',
+                    'name' => 'tester_submit',
+                    'value' => _t("_Submit"),
+                ),
+            )
+        );
+
+        $oForm = new BxTemplFormView($aForm);
+        return $sMsg . $oForm->getCode();
+    }
+
+    function log ($s)
+    {
+        $fn = BX_DIRECTORY_PATH_ROOT . "logs/smtp_mailer.log";
+        $f = @fopen ($fn, 'a');
+        if (!$f)
+            return;
+        fwrite ($f, date(DATE_RFC822) . "\t" . $s . "\n");
+        fclose ($f);
+    }
+}
+
+/** @} */

+ 68 - 0
modules/boonex/smtpmailer/updates/9.0.4_10.0.0/source/install/config.php

@@ -0,0 +1,68 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    SMTPMailer SMTP Mailer
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_smtp',
+    'title' => 'SMTP Mailer',
+    'note' => 'Use remote SMTP server for sending mails.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+	'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/smtpmailer/',
+    'home_uri' => 'smtpmailer',
+
+    'db_prefix' => 'bx_smtp_',
+    'class_prefix' => 'BxSMTP',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'SMTP Mailer',
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    ),
+    'uninstall' => array (
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array(
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+);
+
+/** @} */

+ 37 - 0
modules/boonex/smtpmailer/updates/9.0.4_10.0.0/source/template/images/icons/std-icon.svg

@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg width="64px" height="64px" viewBox="0 0 64 64" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+    <!-- Generator: Sketch 55 (78076) - https://sketchapp.com -->
+    <title>smtp mailer</title>
+    <desc>Created with Sketch.</desc>
+    <defs>
+        <path d="M32,64 C46.0222222,64 53.8173667,64 58.9086889,58.9086889 C64,53.8173667 64,46.0222222 64,32 C64,17.9777778 64,10.1826333 58.9086889,5.09131111 C53.8173667,0 46.0222222,0 32,0 C17.9777778,0 10.1826333,0 5.09131111,5.09131111 C0,10.1826333 0,17.9777778 0,32 C0,46.0222222 0,53.8173667 5.09131111,58.9086889 C10.1826333,64 17.9777778,64 32,64 Z" id="path-1"></path>
+        <linearGradient x1="50%" y1="0%" x2="50%" y2="100%" id="linearGradient-3">
+            <stop stop-color="#FDFEFF" offset="0%"></stop>
+            <stop stop-color="#FBFCFD" stop-opacity="0.9" offset="100%"></stop>
+        </linearGradient>
+        <path d="M35.7142857,0 L4.28571429,0 C1.91875,0 0,1.91875 0,4.28571429 L0,35.7142857 C0,38.08125 1.91875,40 4.28571429,40 L35.7142857,40 C38.08125,40 40,38.08125 40,35.7142857 L40,4.28571429 C40,1.91875 38.08125,0 35.7142857,0 Z M15.9033036,20.545 C7.80616071,14.6684821 7.88866071,14.6536607 5.71428571,12.9613393 L5.71428571,10.7142857 C5.71428571,9.53080357 6.67366071,8.57142857 7.85714286,8.57142857 L32.1428571,8.57142857 C33.3263393,8.57142857 34.2857143,9.53080357 34.2857143,10.7142857 L34.2857143,12.9613393 C32.1097321,14.655 32.1933929,14.6688393 24.0966964,20.5450893 C23.1591964,21.2285714 21.2938393,22.8772321 20,22.8570536 C18.7050893,22.8765179 16.8422321,21.2296429 15.9033036,20.545 L15.9033036,20.545 Z M34.2857143,16.5870536 L34.2857143,29.2857143 C34.2857143,30.4691964 33.3263393,31.4285714 32.1428571,31.4285714 L7.85714286,31.4285714 C6.67366071,31.4285714 5.71428571,30.4691964 5.71428571,29.2857143 L5.71428571,16.5870536 C6.96053571,17.5508036 8.69008929,18.8402679 14.2234821,22.8561607 C15.4879464,23.7794643 17.6141071,25.72625 19.9997321,25.7141964 C22.4003571,25.7261607 24.5566071,23.74625 25.7783036,22.8548214 C31.3102679,18.8400893 33.0394643,17.5507143 34.2857143,16.5870536 Z" id="path-4"></path>
+        <filter x="-5.0%" y="-2.5%" width="110.0%" height="110.0%" filterUnits="objectBoundingBox" id="filter-5">
+            <feOffset dx="0" dy="1" in="SourceAlpha" result="shadowOffsetOuter1"></feOffset>
+            <feGaussianBlur stdDeviation="0.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
+            <feColorMatrix values="0 0 0 0 0   0 0 0 0 0   0 0 0 0 0  0 0 0 0.1 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
+        </filter>
+    </defs>
+    <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
+        <g id="Artboard" transform="translate(-502.000000, -184.000000)">
+            <g id="smtp-mailer" transform="translate(502.000000, 184.000000)">
+                <mask id="mask-2" fill="white">
+                    <use xlink:href="#path-1"></use>
+                </mask>
+                <use id="Path" fill="#738088" xlink:href="#path-1"></use>
+                <g id="envelope-square" mask="url(#mask-2)" fill-rule="nonzero">
+                    <g transform="translate(12.000000, 12.000000)" id="Shape">
+                        <g>
+                            <use fill="black" fill-opacity="1" filter="url(#filter-5)" xlink:href="#path-4"></use>
+                            <use fill="url(#linearGradient-3)" xlink:href="#path-4"></use>
+                        </g>
+                    </g>
+                </g>
+            </g>
+        </g>
+    </g>
+</svg>

+ 185 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/classes/BxSnipcartConfig.php

@@ -0,0 +1,185 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Snipcart Snipcart
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxSnipcartConfig extends BxBaseModTextConfig
+{
+    function __construct($aModule)
+    {
+        parent::__construct($aModule);
+
+        $aMenuItems2Methods = array (
+            'edit-snipcart-entry' => 'checkAllowedEdit',
+            'delete-snipcart-entry' => 'checkAllowedDelete',
+        );
+
+        $this->CNF = array (
+
+            // module icon
+            'ICON' => 'shopping-cart col-green2',
+
+            // database tables
+            'TABLE_ENTRIES' => $aModule['db_prefix'] . 'entries',
+            'TABLE_SETTINGS' => $aModule['db_prefix'] . 'settings',
+            'TABLE_ENTRIES_FULLTEXT' => 'title_text',
+
+            // database fields
+            'FIELD_ID' => 'id',
+            'FIELD_AUTHOR' => 'author',
+            'FIELD_ADDED' => 'added',
+            'FIELD_CHANGED' => 'changed',
+            'FIELD_TITLE' => 'title',
+            'FIELD_TEXT' => 'text',
+            'FIELD_TEXT_ID' => 'snipcart-entry-text',
+            'FIELD_CATEGORY' => 'cat',
+            'FIELD_PRICE' => 'price',
+            'FIELD_WEIGHT' => 'weight',
+            'FIELD_ALLOW_VIEW_TO' => 'allow_view_to',
+            'FIELD_PHOTO' => 'pictures',
+            'FIELD_THUMB' => 'thumb',
+            'FIELD_VIEWS' => 'views',
+            'FIELD_COMMENTS' => 'comments',
+            'FIELD_STATUS' => 'status',
+            'FIELD_STATUS_ADMIN' => 'status_admin',
+            'FIELD_LOCATION_PREFIX' => 'location',
+            'FIELDS_WITH_KEYWORDS' => 'auto', // can be 'auto', array of fields or comma separated string of field names, works only when OBJECT_METATAGS is specified
+
+            // page URIs
+            'URI_VIEW_ENTRY' => 'view-snipcart-entry',
+            'URI_AUTHOR_ENTRIES' => 'snipcart-author',
+            'URI_ENTRIES_BY_CONTEXT' => 'snipcart-context',
+            'URI_ADD_ENTRY' => 'create-snipcart-entry',
+            'URI_EDIT_ENTRY' => 'edit-snipcart-entry',
+            'URI_MANAGE_COMMON' => 'snipcart-manage',
+
+            'URL_HOME' => 'page.php?i=snipcart-home',
+            'URL_POPULAR' => 'page.php?i=snipcart-popular',
+            'URL_UPDATED' => 'page.php?i=snipcart-updated',
+            'URL_MANAGE_COMMON' => 'page.php?i=snipcart-manage',
+            'URL_MANAGE_ADMINISTRATION' => 'page.php?i=snipcart-administration',
+            'URL_SETTINGS' => 'page.php?i=snipcart-settings',
+
+            // some params
+            'PARAM_CHARS_SUMMARY' => 'bx_snipcart_summary_chars',
+            'PARAM_CHARS_SUMMARY_PLAIN' => 'bx_snipcart_plain_summary_chars',
+            'PARAM_NUM_RSS' => 'bx_snipcart_rss_num',
+            'PARAM_SEARCHABLE_FIELDS' => 'bx_snipcart_searchable_fields',
+
+            // objects
+            'OBJECT_STORAGE' => 'bx_snipcart_files',
+            'OBJECT_IMAGES_TRANSCODER_PREVIEW' => 'bx_snipcart_preview',
+            'OBJECT_IMAGES_TRANSCODER_GALLERY' => 'bx_snipcart_gallery',
+            'OBJECT_IMAGES_TRANSCODER_COVER' => 'bx_snipcart_cover',
+            'OBJECT_VIDEOS_TRANSCODERS' => array(),
+            'OBJECT_REPORTS' => 'bx_snipcart',
+            'OBJECT_VIEWS' => 'bx_snipcart',
+            'OBJECT_VOTES' => 'bx_snipcart',
+            'OBJECT_REACTIONS' => 'bx_snipcart_reactions',
+            'OBJECT_SCORES' => 'bx_snipcart',
+            'OBJECT_FAVORITES' => 'bx_snipcart',
+            'OBJECT_FEATURED' => 'bx_snipcart',
+            'OBJECT_METATAGS' => 'bx_snipcart',
+            'OBJECT_COMMENTS' => 'bx_snipcart',
+            'OBJECT_CATEGORY' => 'bx_snipcart_cats',
+            'OBJECT_PRIVACY_VIEW' => 'bx_snipcart_allow_view_to',
+            'OBJECT_FORM_ENTRY' => 'bx_snipcart',
+            'OBJECT_FORM_ENTRY_DISPLAY_VIEW' => 'bx_snipcart_entry_view',
+            'OBJECT_FORM_ENTRY_DISPLAY_ADD' => 'bx_snipcart_entry_add',
+            'OBJECT_FORM_ENTRY_DISPLAY_EDIT' => 'bx_snipcart_entry_edit',
+            'OBJECT_FORM_ENTRY_DISPLAY_DELETE' => 'bx_snipcart_entry_delete',
+            'OBJECT_FORM_SETTINGS' => 'bx_snipcart_settings',
+            'OBJECT_FORM_SETTINGS_DISPLAY_EDIT' => 'bx_snipcart_settings_edit',
+            'OBJECT_FORM_PRELISTS_CURRENCIES' => 'bx_snipcart_currencies',
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY' => 'bx_snipcart_view', // actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY_ALL' => 'bx_snipcart_view_actions', // all actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_MY_ENTRIES' => 'bx_snipcart_my', // actions menu on my entries page
+            'OBJECT_MENU_SUBMENU' => 'bx_snipcart_submenu', // main module submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY' => 'bx_snipcart_view_submenu', // view entry submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY_MAIN_SELECTION' => 'snipcart-home', // first item in view entry submenu from main module submenu
+            'OBJECT_MENU_SNIPPET_META' => 'bx_snipcart_snippet_meta', // menu for snippet meta info
+            'OBJECT_MENU_MANAGE_TOOLS' => 'bx_snipcart_menu_manage_tools', //manage menu in content administration tools
+            'OBJECT_GRID_ADMINISTRATION' => 'bx_snipcart_administration',
+            'OBJECT_GRID_COMMON' => 'bx_snipcart_common',
+            'OBJECT_UPLOADERS' => array('sys_simple', 'sys_html5'),
+
+            // menu items which visibility depends on custom visibility checking
+            'MENU_ITEM_TO_METHOD' => array (
+                'bx_snipcart_my' => array (
+                    'create-snipcart-entry' => 'checkAllowedAdd',
+                ),
+                'bx_snipcart_view' => $aMenuItems2Methods,
+            ),
+
+            // some language keys
+            'T' => array (
+                'txt_sample_single' => '_bx_snipcart_txt_sample_single',
+            	'txt_sample_single_with_article' => '_bx_snipcart_txt_sample_single_with_article',
+            	'txt_sample_comment_single' => '_bx_snipcart_txt_sample_comment_single',
+            	'txt_sample_vote_single' => '_bx_snipcart_txt_sample_vote_single',
+                'txt_sample_score_up_single' => '_bx_snipcart_txt_sample_score_up_single',
+                'txt_sample_score_down_single' => '_bx_snipcart_txt_sample_score_down_single',
+            	'form_field_author' => '_bx_snipcart_form_entry_input_author',
+            	'grid_action_err_delete' => '_bx_snipcart_grid_action_err_delete',
+            	'grid_txt_account_manager' => '_bx_snipcart_grid_txt_account_manager',
+                'filter_item_active' => '_bx_snipcart_grid_filter_item_title_adm_active',
+            	'filter_item_hidden' => '_bx_snipcart_grid_filter_item_title_adm_hidden',
+            	'filter_item_select_one_filter1' => '_bx_snipcart_grid_filter_item_title_adm_select_one_filter1',
+            	'menu_item_manage_my' => '_bx_snipcart_menu_item_title_manage_my',
+            	'menu_item_manage_all' => '_bx_snipcart_menu_item_title_manage_all',
+                'txt_all_entries_by' => '_bx_snipcart_txt_all_entries_by',
+                'txt_all_entries_in' => '_bx_snipcart_txt_all_entries_in',
+                'txt_all_entries_by_author' => '_bx_snipcart_page_title_browse_by_author',
+                'txt_all_entries_by_context' => '_bx_snipcart_page_title_browse_by_context',
+            	'txt_pict_use_as_thumb' => '_bx_snipcart_form_entry_input_picture_use_as_thumb'
+            ),
+        );
+
+        $this->_aJsClasses = array(
+            'manage_tools' => 'BxSnipcartManageTools'
+        );
+
+        $this->_aJsObjects = array(
+            'manage_tools' => 'oBxSnipcartManageTools'
+        );
+
+        $this->_aGridObjects = array(
+            'common' => $this->CNF['OBJECT_GRID_COMMON'],
+            'administration' => $this->CNF['OBJECT_GRID_ADMINISTRATION'],
+        );
+    }
+
+    public function getViewUrl($iContentId)
+    {
+        return BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink('page.php?i=' . $this->CNF['URI_VIEW_ENTRY'] . '&id=' . $iContentId);
+    }
+
+    public function getApiKey($aSettings)
+    {
+        if(empty($aSettings['mode']) || !in_array($aSettings['mode'], array(BX_SNIPCART_MODE_TEST, BX_SNIPCART_MODE_LIVE)))
+            return '';
+
+        return $aSettings['api_key_' . $aSettings['mode']]; 
+    }
+
+    public function getCurrency($aSettings)
+    {
+        $sCurrency = !empty($aSettings['currency']) ? $aSettings['currency'] : 'USD';
+
+        $aCurrencies = BxDolForm::getDataItems($this->CNF['OBJECT_FORM_PRELISTS_CURRENCIES']);
+        $sCurrencyCode = $aCurrencies[$sCurrency];
+
+        $aCurrencies = BxDolForm::getDataItems($this->CNF['OBJECT_FORM_PRELISTS_CURRENCIES'], false, BX_DATA_VALUES_ADDITIONAL);
+        $sCurrencySign = $aCurrencies[$sCurrency];
+
+        return array('code' => $sCurrencyCode, 'sign' => $sCurrencySign);
+    }
+}
+
+/** @} */

+ 197 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/classes/BxSnipcartModule.php

@@ -0,0 +1,197 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Snipcart Snipcart
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+define('BX_SNIPCART_MODE_TEST', 'test');
+define('BX_SNIPCART_MODE_LIVE', 'live');
+
+/**
+ * Snipcart module
+ */
+class BxSnipcartModule extends BxBaseModTextModule
+{
+    function __construct(&$aModule)
+    {
+        parent::__construct($aModule);
+
+        $CNF = &$this->_oConfig->CNF;
+        $this->_aSearchableNamesExcept = array_merge($this->_aSearchableNamesExcept, array(
+             $CNF['FIELD_PRICE'],
+             $CNF['FIELD_WEIGHT']
+        ));
+    }
+
+    public function getSettings($iProfileId = 0)
+    {
+        if(empty($iProfileId))
+            $iProfileId = bx_get_logged_profile_id();
+
+        $aSettings = $this->_oDb->getSettings(array('type' => 'author', 'author' => $iProfileId));
+        if(empty($aSettings) || !is_array($aSettings))
+            return array();
+
+        return $aSettings;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_snipcart Snipcart
+     * @subsection bx_snipcart-other Other
+     * @subsubsection bx_snipcart-get_searchable_fields get_searchable_fields
+     * 
+     * @code bx_srv('bx_snipcart', 'get_searchable_fields', [...]); @endcode
+     * 
+     * Get a list of searchable fields. Is used in common search engine. 
+     *
+     * @return an array with a list of searchable fields.
+     * 
+     * @see BxSnipcartModule::serviceGetSearchableFields
+     */
+    /** 
+     * @ref bx_snipcart-get_searchable_fields "get_searchable_fields"
+     */
+    public function serviceGetSearchableFields ($aInputsAdd = array())
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $aResult = parent::serviceGetSearchableFields($aInputsAdd);
+        unset($aResult[$CNF['FIELD_PRICE']], $aResult[$CNF['FIELD_WEIGHT']]);
+
+        return $aResult;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_snipcart Snipcart
+     * @subsection bx_snipcart-integration Integration
+     * @subsubsection bx_snipcart-include_css_js include_css_js
+     * 
+     * @code bx_srv('bx_snipcart', 'include_css_js', [...]); @endcode
+     * 
+     * Get integration code with all necessary CSS and JS includes. 
+     *
+     * @return HTML sting with integration code to display on the site, all necessary CSS and JS files are automatically added to the HEAD section of the site HTML. Empty string is returned if there is no enough input data.
+     * 
+     * @see BxSnipcartModule::serviceIncludeCssJs
+     */
+    /** 
+     * @ref bx_snipcart-include_css_js "include_css_js"
+     */
+    public function serviceIncludeCssJs($iProfileId = 0)
+    {
+        $iProfileId = !empty($iProfileId) ? $iProfileId : $this->_iProfileId;
+        if(empty($iProfileId))
+            return '';
+
+        return $this->_oTemplate->getSctInclude($iProfileId);
+    }
+
+	/**
+     * @page service Service Calls
+     * @section bx_snipcart Snipcart
+     * @subsection bx_snipcart-page_blocks Page Blocks
+     * @subsubsection bx_snipcart-entity_create entity_create
+     * 
+     * @code bx_srv('bx_snipcart', 'entity_create', [...]); @endcode
+     * 
+     * Get page block with product creation form or an error message if something wasn't configured correctly.
+     *
+     * @param $sDisplay form display name to use
+     * @return HTML string with block content to display on the site, all necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxSnipcartModule::serviceEntityCreate
+     */
+    /** 
+     * @ref bx_snipcart-entity_create "entity_create"
+     */
+    public function serviceEntityCreate ($sDisplay = false)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+    	$aSettings = $this->_oDb->getSettings(array('type' => 'author', 'author' => $this->_iProfileId));
+        if(empty($aSettings) || !is_array($aSettings))
+    		return MsgBox(_t('_bx_snipcart_err_not_configured', BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink($CNF['URL_SETTINGS'])));
+
+    	return parent::serviceEntityCreate($sDisplay);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_snipcart Snipcart
+     * @subsection bx_snipcart-page_blocks Page Blocks
+     * @subsubsection bx_snipcart-settings settings
+     * 
+     * @code bx_srv('bx_snipcart', 'settings', [...]); @endcode
+     * 
+     * Get page block with configuration settings form.
+     *
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxSnipcartModule::serviceSettings
+     */
+    /** 
+     * @ref bx_snipcart-settings "settings"
+     */
+    public function serviceSettings()
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        if(!$this->_iProfileId)
+            return MsgBox(_t('_Access denied'));
+
+        $oForm = BxDolForm::getObjectInstance($CNF['OBJECT_FORM_SETTINGS'], $CNF['OBJECT_FORM_SETTINGS_DISPLAY_EDIT'], $this->_oTemplate);
+        if(!$oForm)
+            return MsgBox(_t('_sys_txt_error_occured'));       
+
+        $aSettings = $this->_oDb->getSettings(array('type' => 'author', 'author' => $this->_iProfileId));
+        $bSettings = !empty($aSettings) && is_array($aSettings);
+
+        $sResultTimer = 0;
+        $sResultMessage = '';
+
+        $oForm->initChecker($aSettings);
+        if($oForm->isSubmittedAndValid()) {         
+            if(!$bSettings) {
+                if((int)$oForm->insert(array('author' => $this->_iProfileId)) > 0) {
+                    $sResultTimer = 3;
+                    $sResultMessage = '_bx_snipcart_msg_save_settings';
+                }
+                else 
+                    $sResultMessage = '_bx_snipcart_err_save_settings';
+                
+            }
+            else {
+                if($oForm->update($aSettings['id']) !== false) {
+                    $sResultTimer = 3;
+                    $sResultMessage = '_bx_snipcart_msg_save_settings';
+                }
+                else 
+                    $sResultMessage = '_bx_snipcart_err_save_settings';
+            }
+        }
+
+        return array(
+        	'content' => (!empty($sResultMessage) ? MsgBox(_t($sResultMessage), $sResultTimer) : '') . $oForm->getCode()
+        );
+    }
+
+    protected function _getContentForTimelinePost($aEvent, $aContentInfo, $aBrowseParams = array())
+    {
+        $aResult = parent::_getContentForTimelinePost($aEvent, $aContentInfo, $aBrowseParams);
+
+        $aResult['raw'] = $this->_oTemplate->getBuyButton($aContentInfo);
+        if(isset($aBrowseParams['dynamic_mode']) && (bool)$aBrowseParams['dynamic_mode'] === true)
+            $aResult['raw'] .= $this->_oTemplate->addCss(array('timeline.css'), true);
+
+        return $aResult;
+    }
+}
+
+/** @} */

+ 136 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/config.php

@@ -0,0 +1,136 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Snipcart Snipcart
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_snipcart',
+    'title' => 'Snipcart',
+    'note' => 'Snipcart shopping module.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+	'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/snipcart/',
+    'home_uri' => 'snipcart',
+
+    'db_prefix' => 'bx_snipcart_',
+    'class_prefix' => 'BxSnipcart',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Snipcart',
+
+    /**
+     * List of page triggers.
+     */
+    'page_triggers' => array (
+    	'trigger_page_profile_view_entry',
+    ),
+    
+    /**
+     * Menu triggers.
+     */
+    'menu_triggers' => array(
+    	'trigger_profile_view_submenu',
+        'trigger_group_view_submenu'
+    ),
+
+	/**
+     * Storage objects to automatically delete files from upon module uninstallation.
+     * Note. Don't add storage objects used in transcoder objects.
+     */
+    'storages' => array(
+    	'bx_snipcart_files'
+    ),
+
+    /**
+     * Transcoders.
+     */
+    'transcoders' => array(
+		'bx_snipcart_preview',
+        'bx_snipcart_gallery',
+        'bx_snipcart_cover'
+    ),
+
+    /**
+     * Extended Search Forms.
+     */
+    'esearches' => array(
+        'bx_snipcart',
+    	'bx_snipcart_cmts',
+    ),
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'uninstall' => array (
+    	'process_esearches' => 1,
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    	'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+    	'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable_success' => array(
+        'process_menu_triggers' => 1,
+        'process_page_triggers' => 1,
+    	'process_esearches' => 1,
+    	'register_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+    	'update_relations' => 1,
+    	'unregister_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable_failed' => array (
+    	'register_transcoders' => 1,
+    	'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+
+    /**
+     * Relations Section
+     */
+    'relations' => array(
+    	'bx_timeline',
+    	'bx_notifications'
+    ),
+
+);
+
+/** @} */

+ 261 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,261 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+
+	<string name="_bx_snipcart"><![CDATA[Snipcart]]></string>
+	<string name="_bx_snipcart_cmts"><![CDATA[Snipcart's Reviews]]></string>
+
+	<string name="_bx_snipcart_option_summary_chars"><![CDATA[Number of characters in auto-cropped item summary]]></string>
+	<string name="_bx_snipcart_option_plain_summary_chars"><![CDATA[Number of characters in plain item description when item hasn't thumb]]></string>
+	<string name="_bx_snipcart_option_per_page_browse"><![CDATA[Number of items per page]]></string>
+	<string name="_bx_snipcart_option_per_page_profile"><![CDATA[Number of items on profile page]]></string>
+	<string name="_bx_snipcart_option_rss_num"><![CDATA[Number of items in RSS feed]]></string>
+	<string name="_bx_snipcart_option_searchable_fields"><![CDATA[Searchable fields for keyword search]]></string>
+
+	<string name="_bx_snipcart_form_entry"><![CDATA[Goods]]></string>
+	<string name="_bx_snipcart_form_entry_display_add"><![CDATA[Add Goods]]></string>
+	<string name="_bx_snipcart_form_entry_display_edit"><![CDATA[Edit Goods]]></string>
+	<string name="_bx_snipcart_form_entry_display_delete"><![CDATA[Delete Goods]]></string>
+	<string name="_bx_snipcart_form_entry_display_view"><![CDATA[View Goods]]></string>
+	<string name="_bx_snipcart_form_entry_input_author"><![CDATA[Author]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_snipcart_form_entry_input_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_do_publish"><![CDATA[Publish]]></string>
+	<string name="_bx_snipcart_form_entry_input_do_publish"><![CDATA[Publish]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_title"><![CDATA[Title]]></string>
+	<string name="_bx_snipcart_form_entry_input_title"><![CDATA[Title]]></string>
+	<string name="_bx_snipcart_form_entry_input_title_err"><![CDATA[Title is essential. Please, fill in this field]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_cat"><![CDATA[Category]]></string>
+	<string name="_bx_snipcart_form_entry_input_cat"><![CDATA[Category]]></string>
+    <string name="_bx_snipcart_form_entry_input_cat_err"><![CDATA[Please select category]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_text"><![CDATA[Text]]></string>
+	<string name="_bx_snipcart_form_entry_input_text"><![CDATA[Text]]></string>
+	<string name="_bx_snipcart_form_entry_input_text_err"><![CDATA[Text field can't be empty]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_price"><![CDATA[Price]]></string>
+    <string name="_bx_snipcart_form_entry_input_price"><![CDATA[Price]]></string>
+    <string name="_bx_snipcart_form_entry_input_price_inf"><![CDATA[The value is indicated in %s.]]></string>
+    <string name="_bx_snipcart_form_entry_input_price_err"><![CDATA[Price field can't be empty]]></string>
+    <string name="_bx_snipcart_form_entry_input_sys_weight"><![CDATA[Weight]]></string>
+    <string name="_bx_snipcart_form_entry_input_weight"><![CDATA[Weight]]></string>
+    <string name="_bx_snipcart_form_entry_input_weight_inf"><![CDATA[The value is indicated in Kg.]]></string>
+    <string name="_bx_snipcart_form_entry_input_weight_err"><![CDATA[Weight field can't be empty]]></string>
+    <string name="_bx_snipcart_form_entry_input_weight_value"><![CDATA[{0} Kg]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_delete_confirm"><![CDATA[Delete confirmation]]></string>
+	<string name="_bx_snipcart_form_entry_input_delete_confirm"><![CDATA[I am sure I want to delete this product]]></string>
+	<string name="_bx_snipcart_form_entry_input_delete_confirm_info"><![CDATA[This action can not be undone]]></string>
+	<string name="_bx_snipcart_form_entry_input_delete_confirm_error"><![CDATA[Please check this checkbox if you really want to delete the product]]></string>
+	<string name="_bx_snipcart_form_entry_input_sys_pictures"><![CDATA[Pictures]]></string>
+	<string name="_bx_snipcart_form_entry_input_pictures"><![CDATA[Pictures]]></string>
+    <string name="_bx_snipcart_form_entry_input_sys_allow_view_to"><![CDATA[Visibility]]></string>
+    <string name="_bx_snipcart_form_entry_input_allow_view_to"><![CDATA[Visibility]]></string>
+    <string name="_bx_snipcart_form_entry_input_picture_use_as_thumb"><![CDATA[Cover Image]]></string>
+    <string name="_bx_snipcart_form_entry_input_sys_date_added"><![CDATA[Created]]></string>
+    <string name="_bx_snipcart_form_entry_input_date_added"><![CDATA[Created]]></string>
+    <string name="_bx_snipcart_form_entry_input_sys_date_changed"><![CDATA[Updated]]></string>
+    <string name="_bx_snipcart_form_entry_input_date_changed"><![CDATA[Updated]]></string>
+
+    <string name="_bx_snipcart_form_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_form_settings_display_edit"><![CDATA[Edit Settings]]></string>
+    <string name="_bx_snipcart_form_settings_input_sys_mode"><![CDATA[Mode]]></string>
+    <string name="_bx_snipcart_form_settings_input_mode"><![CDATA[Mode]]></string>
+    <string name="_bx_snipcart_form_settings_input_mode_err"><![CDATA[Mode is essential. Please, fill in this field.]]></string>
+    <string name="_bx_snipcart_form_settings_input_sys_api_key_test"><![CDATA[API Key (test)]]></string>
+    <string name="_bx_snipcart_form_settings_input_api_key_test"><![CDATA[API Key (test)]]></string>
+    <string name="_bx_snipcart_form_settings_input_sys_api_key_live"><![CDATA[API Key (live)]]></string>
+    <string name="_bx_snipcart_form_settings_input_api_key_live"><![CDATA[API Key (live)]]></string>
+    <string name="_bx_snipcart_form_settings_input_sys_currency"><![CDATA[Currency]]></string>
+    <string name="_bx_snipcart_form_settings_input_currency"><![CDATA[Currency]]></string>
+    <string name="_bx_snipcart_form_settings_input_currency_inf"><![CDATA[Select the default Currency from your Snipcart account.]]></string>
+    <string name="_bx_snipcart_form_settings_input_currency_err"><![CDATA[Currency is essential. Please, fill in this field.]]></string>    
+    <string name="_bx_snipcart_form_settings_input_sys_do_submit"><![CDATA[Submit]]></string>
+    <string name="_bx_snipcart_form_settings_input_do_submit"><![CDATA[Submit]]></string>
+
+	<string name="_bx_snipcart_acl_action_create_entry"><![CDATA[Create Goods]]></string>
+	<string name="_bx_snipcart_acl_action_delete_entry"><![CDATA[Delete Goods]]></string>
+	<string name="_bx_snipcart_acl_action_view_entry"><![CDATA[View Goods]]></string>
+	<string name="_bx_snipcart_acl_action_set_thumb"><![CDATA[Set Goods Thumbnail]]></string>
+	<string name="_bx_snipcart_acl_action_edit_any_entry"><![CDATA[Edit Any Goods]]></string>
+
+	<string name="_bx_snipcart_page_title_sys_create_entry"><![CDATA[New Goods]]></string>
+	<string name="_bx_snipcart_page_title_create_entry"><![CDATA[New Item]]></string>
+	<string name="_bx_snipcart_page_block_title_create_entry"><![CDATA[New Item]]></string>
+	<string name="_bx_snipcart_page_title_sys_edit_entry"><![CDATA[Edit]]></string>
+	<string name="_bx_snipcart_page_title_edit_entry"><![CDATA[Edit]]></string>
+	<string name="_bx_snipcart_page_block_title_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_snipcart_page_title_sys_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_snipcart_page_title_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_snipcart_page_block_title_delete_entry"><![CDATA[Delete]]></string>
+	<string name="_bx_snipcart_page_title_sys_view_entry"><![CDATA[View Goods]]></string>
+	<string name="_bx_snipcart_page_title_view_entry"><![CDATA[{title}]]></string>
+	<string name="_bx_snipcart_page_block_title_entry_text"><![CDATA[Item Text]]></string>
+	<string name="_bx_snipcart_page_title_browse"><![CDATA[Goods]]></string>
+	<string name="_bx_snipcart_page_title_search_results"><![CDATA[Goods matching "{0}"]]></string>
+	<string name="_bx_snipcart_page_title_browse_by_author"><![CDATA[Goods of {display_name}]]></string>
+  <string name="_bx_snipcart_page_title_browse_by_context"><![CDATA[Goods in {display_name}]]></string>
+	<string name="_bx_snipcart_page_title_browse_featured"><![CDATA[Featured Goods]]></string>
+    <string name="_bx_snipcart_page_title_browse_recent"><![CDATA[Latest Goods]]></string>
+    <string name="_bx_snipcart_page_title_browse_popular"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_snipcart_page_title_browse_updated"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_snipcart_page_title_sys_home"><![CDATA[Goods Home]]></string>
+    <string name="_bx_snipcart_page_title_home"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_featured_entries_view_extended"><![CDATA[Featured Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_recent_entries"><![CDATA[Latest Goods (Gallery View)]]></string>
+    <string name="_bx_snipcart_page_block_title_recent_entries_view_extended"><![CDATA[Latest Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_recent_entries_view_full"><![CDATA[Latest Goods (Full View)]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_social_sharing"><![CDATA[Share]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_author"><![CDATA[Author]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_actions"><![CDATA[Actions]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_comments"><![CDATA[Comments]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_comments_link"><![CDATA[Comments to <a href="{entry_link}">{title}</a>]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_location"><![CDATA[Location]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_attachments"><![CDATA[Attachments]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_all_actions"><![CDATA[All Actions]]></string>
+    <string name="_bx_snipcart_page_title_sys_entries_popular"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_snipcart_page_title_entries_popular"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_snipcart_page_title_sys_entries_updated"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_snipcart_page_title_entries_updated"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_popular_entries"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_popular_entries_view_extended"><![CDATA[Popular Goods (Extended View)]]></string>
+    <string name="_bx_snipcart_page_block_title_popular_entries_view_full"><![CDATA[Popular Goods (Full View)]]></string>
+    <string name="_bx_snipcart_page_block_title_updated_entries"><![CDATA[Updated Goods]]></string>
+    <string name="_bx_snipcart_page_title_sys_view_entry_comments"><![CDATA[Goods Comments]]></string>
+    <string name="_bx_snipcart_page_title_view_entry_comments"><![CDATA[Comments to {title}]]></string>
+    <string name="_bx_snipcart_page_title_sys_entries_of_author"><![CDATA[Goods of author]]></string>
+    <string name="_bx_snipcart_page_title_entries_of_author"><![CDATA[Goods by {display_name}]]></string>
+    <string name="_bx_snipcart_page_title_sys_entries_in_context"><![CDATA[Goods in context]]></string>
+    <string name="_bx_snipcart_page_title_entries_in_context"><![CDATA[Goods in {display_name}]]></string>
+    <string name="_bx_snipcart_page_block_title_favorites_of_author"><![CDATA[Favorites by <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_favorites_of_author"><![CDATA[Favorites of author]]></string>
+    <string name="_bx_snipcart_page_block_title_entries_of_author"><![CDATA[Goods by <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_entries_of_author"><![CDATA[Goods of author]]></string>
+    <string name="_bx_snipcart_page_block_title_entries_in_context"><![CDATA[Goods in <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_entries_in_context"><![CDATA[Goods in context]]></string>
+    <string name="_bx_snipcart_page_block_title_entries_actions"><![CDATA[Goods actions]]></string>
+    <string name="_bx_snipcart_page_block_title_browse_cmts"><![CDATA[Goods' Comments]]></string>
+	<string name="_bx_snipcart_page_title_sys_manage"><![CDATA[Manage Own]]></string>
+	<string name="_bx_snipcart_page_title_sys_manage_administration"><![CDATA[Manage All]]></string>
+	<string name="_bx_snipcart_page_title_manage"><![CDATA[Manage]]></string>
+	<string name="_bx_snipcart_page_block_title_system_manage"><![CDATA[Manage Own]]></string>
+	<string name="_bx_snipcart_page_block_title_system_manage_administration"><![CDATA[Manage All]]></string>
+	<string name="_bx_snipcart_page_block_title_manage"><![CDATA[Manage]]></string>    
+	<string name="_bx_snipcart_page_block_title_popular_keywords"><![CDATA[Popular Hashtags]]></string>
+	<string name="_bx_snipcart_page_block_title_cats"><![CDATA[Goods Categories]]></string>
+	<string name="_bx_snipcart_page_block_title_entry_info"><![CDATA[Info]]></string>
+	<string name="_bx_snipcart_page_block_title_my_entries"><![CDATA[My Goods]]></string>
+    <string name="_bx_snipcart_page_title_sys_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_page_title_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_page_block_title_system_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_page_block_title_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_page_title_sys_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_snipcart_page_title_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_snipcart_page_block_title_search_form"><![CDATA[Search Form]]></string>
+    <string name="_bx_snipcart_page_block_title_search_results"><![CDATA[Search Results]]></string>
+    <string name="_bx_snipcart_page_block_title_search_form_cmts"><![CDATA[Comments Search Form]]></string>
+    <string name="_bx_snipcart_page_block_title_search_results_cmts"><![CDATA[Comments Search Results]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_recent_entries_view_showcase"><![CDATA[Latest Goods (Showcase View)]]></string>
+    <string name="_bx_snipcart_page_block_title_recent_entries_view_showcase"><![CDATA[Latest Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_popular_entries_view_showcase"><![CDATA[Popular Goods (Showcase View)]]></string>
+    <string name="_bx_snipcart_page_block_title_popular_entries_view_showcase"><![CDATA[Popular Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_featured_entries_view_showcase"><![CDATA[Featured Goods (Showcase View)]]></string>
+    <string name="_bx_snipcart_page_block_title_featured_entries_view_showcase"><![CDATA[Featured Goods]]></string>
+    <string name="_bx_snipcart_page_block_title_sys_entry_context"><![CDATA[Posted in]]></string>
+    <string name="_bx_snipcart_page_block_title_entry_context"><![CDATA[Posted in]]></string>
+
+    <string name="_bx_snipcart_menu_set_title_view_entry"><![CDATA[Goods Actions]]></string>
+    <string name="_bx_snipcart_menu_title_view_entry"><![CDATA[Goods Actions]]></string>
+    <string name="_bx_snipcart_menu_title_submenu"><![CDATA[Goods Submenu]]></string>
+    <string name="_bx_snipcart_menu_set_title_submenu"><![CDATA[Goods Submenu]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_create_entry"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_create_entry"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_snipcart_menu_item_title_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_snipcart_menu_item_title_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_view_entry"><![CDATA[View Goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_entries_home"><![CDATA[Shop]]></string>
+    <string name="_bx_snipcart_menu_item_title_entries_home"><![CDATA[Shop]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_entries_public"><![CDATA[Latest]]></string>
+    <string name="_bx_snipcart_menu_item_title_entries_public"><![CDATA[Latest]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_snipcart_menu_item_title_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_entries_manage"><![CDATA[Manage]]></string>
+    <string name="_bx_snipcart_menu_item_title_entries_manage"><![CDATA[Manage]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_menu_item_title_settings"><![CDATA[Settings]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_dashboard"><![CDATA[Dashboard]]></string>
+    <string name="_bx_snipcart_menu_item_title_dashboard"><![CDATA[Dashboard]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_entries_popular"><![CDATA[Popular]]></string>
+    <string name="_bx_snipcart_menu_item_title_entries_popular"><![CDATA[Popular]]></string>
+    <string name="_bx_snipcart_menu_title_view_entry_submenu"><![CDATA[View Goods Submenu]]></string>
+    <string name="_bx_snipcart_menu_set_title_view_entry_submenu"><![CDATA[View Goods Submenu]]></string>
+    <string name="_bx_snipcart_menu_item_title_view_entry_submenu_entry"><![CDATA[Item]]></string>
+    <string name="_bx_snipcart_menu_item_title_view_entry_submenu_comments"><![CDATA[Comments]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_view_entry_comments"><![CDATA[Goods Comments]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_view_entries_author"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_view_entries_author"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_view_entries_in_context"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_view_entries_in_context"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_title_entries_my"><![CDATA[My Goods Action Menu]]></string>
+    <string name="_bx_snipcart_menu_set_title_entries_my"><![CDATA[My Goods Menu]]></string>
+	<string name="_bx_snipcart_menu_item_title_system_manage_my_entries"><![CDATA[My goods]]></string>
+    <string name="_bx_snipcart_menu_item_title_manage_my_entries"><![CDATA[Goods]]></string>
+    <string name="_bx_snipcart_menu_set_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+    <string name="_bx_snipcart_menu_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+    <string name="_bx_snipcart_menu_item_title_system_manage_account"><![CDATA[Manage account]]></string>
+    <string name="_bx_snipcart_menu_item_title_manage_account"><![CDATA[Manage account]]></string>
+	<string name="_bx_snipcart_menu_item_title_system_admt_entries"><![CDATA[Goods]]></string>
+	<string name="_bx_snipcart_menu_item_title_admt_entries"><![CDATA[Goods]]></string>
+	<string name="_bx_snipcart_menu_item_title_manage_my"><![CDATA[My Goods]]></string>
+	<string name="_bx_snipcart_menu_item_title_manage_all"><![CDATA[All Goods]]></string>
+        <string name="_bx_snipcart_menu_item_title_system_buy_for"><![CDATA[Buy]]></string>
+	<string name="_bx_snipcart_menu_item_title_buy_for"><![CDATA[Buy for {1}{0}]]></string>
+
+	<string name="_bx_snipcart_grid_filter_item_title_adm_select_one_filter1"><![CDATA[All Statuses]]></string>
+	<string name="_bx_snipcart_grid_filter_item_title_adm_active"><![CDATA[Active]]></string>
+	<string name="_bx_snipcart_grid_filter_item_title_adm_hidden"><![CDATA[Hidden]]></string>
+	<string name="_bx_snipcart_grid_column_title_adm_active"><![CDATA[Active]]></string>
+    <string name="_bx_snipcart_grid_column_title_adm_title"><![CDATA[Title]]></string>
+    <string name="_bx_snipcart_grid_column_title_adm_added"><![CDATA[Added]]></string>
+    <string name="_bx_snipcart_grid_column_title_adm_author"><![CDATA[Author]]></string>
+    <string name="_bx_snipcart_grid_action_title_adm_edit"><![CDATA[Edit]]></string>
+    <string name="_bx_snipcart_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+    <string name="_bx_snipcart_grid_action_title_adm_more_actions"><![CDATA[More Actions]]></string>
+    <string name="_bx_snipcart_grid_action_err_delete"><![CDATA[Cannot delete the selected product(s).]]></string>
+    <string name="_bx_snipcart_grid_txt_account_manager"><![CDATA[Redirect to manage account.]]></string>
+
+    <string name="_bx_snipcart_chart_growth"><![CDATA[Snipcart: Growth]]></string>
+    <string name="_bx_snipcart_chart_growth_speed"><![CDATA[Snipcart: Growth Speed]]></string>
+
+    <string name="_bx_snipcart_search_extended"><![CDATA[Snipcart Search]]></string>
+    <string name="_bx_snipcart_search_extended_cmts"><![CDATA[Snipcart Comments Search]]></string>
+
+    <string name="_bx_snipcart_pre_lists_cats"><![CDATA[Goods categories]]></string>
+    <string name="_bx_snipcart_cat_automotive_and_industrial"><![CDATA[Automotive & Industrial]]></string>
+    <string name="_bx_snipcart_cat_beauty_health_food"><![CDATA[Beauty, Health & Food]]></string>
+    <string name="_bx_snipcart_cat_books"><![CDATA[Books]]></string>
+    <string name="_bx_snipcart_cat_clothing_shoes_jewelry"><![CDATA[Clothing, Shoes & Jewelry]]></string>
+    <string name="_bx_snipcart_cat_electronics_and_computers"><![CDATA[Electronics & Computers]]></string>
+    <string name="_bx_snipcart_cat_handmade"><![CDATA[Handmade]]></string>
+    <string name="_bx_snipcart_cat_home_garden_tools"><![CDATA[Home, Garden & Tools]]></string>
+    <string name="_bx_snipcart_cat_movies_music_games"><![CDATA[Movies, Music & Games]]></string>
+    <string name="_bx_snipcart_cat_sports_and_outdoors"><![CDATA[Sports & Outdoors]]></string>
+    <string name="_bx_snipcart_cat_toys_kids_baby"><![CDATA[Toys, Kids & Baby]]></string>
+
+    <string name="_bx_snipcart_pre_lists_modes"><![CDATA[Modes]]></string>
+    <string name="_bx_snipcart_mode_test"><![CDATA[test]]></string>
+    <string name="_bx_snipcart_mode_live"><![CDATA[live]]></string>
+
+    <string name="_bx_snipcart_pre_lists_currencies"><![CDATA[Currencies]]></string>
+
+    <string name="_bx_snipcart_msg_save_settings"><![CDATA[Settings were successfully saved.]]></string>
+    <string name="_bx_snipcart_err_save_settings"><![CDATA[Cannot save settings.]]></string>
+    <string name="_bx_snipcart_err_not_configured"><![CDATA[You need to configure shop settings first. <a href="{0}">Click here</a>.]]></string>
+
+    <string name="_bx_snipcart_txt_all_entries_by"><![CDATA[<a href="{0}">All Goods by {1} ({2})</a>]]></string>
+    <string name="_bx_snipcart_txt_all_entries_in"><![CDATA[<a href="{0}">All Goods in {1} ({2})</a>]]></string>
+    <string name="_bx_snipcart_txt_sample_single"><![CDATA[shop item]]></string>
+    <string name="_bx_snipcart_txt_sample_single_with_article"><![CDATA[a shop item]]></string>
+    <string name="_bx_snipcart_txt_sample_comment_single"><![CDATA[comment to shop item]]></string>
+    <string name="_bx_snipcart_txt_sample_vote_single"><![CDATA[vote to shop item]]></string>
+    <string name="_bx_snipcart_txt_sample_score_up_single"><![CDATA[score up vote to shop item]]></string>
+    <string name="_bx_snipcart_txt_sample_score_down_single"><![CDATA[score down vote to shop item]]></string>
+</resources>

+ 425 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,425 @@
+
+-- SETTINGS
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types`(`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_snipcart', '_bx_snipcart', 'bx_snipcart@modules/boonex/snipcart/|std-icon.svg', IF(ISNULL(@iTypeOrder), 1, @iTypeOrder + 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order`)
+VALUES (@iTypeId, 'bx_snipcart', '_bx_snipcart', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `check`, `check_error`, `extra`, `order`) VALUES
+('bx_snipcart_summary_chars', '700', @iCategId, '_bx_snipcart_option_summary_chars', 'digit', '', '', '', 1),
+('bx_snipcart_plain_summary_chars', '240', @iCategId, '_bx_snipcart_option_plain_summary_chars', 'digit', '', '', '', 2),
+('bx_snipcart_per_page_browse', '12', @iCategId, '_bx_snipcart_option_per_page_browse', 'digit', '', '', '', 10),
+('bx_snipcart_per_page_profile', '6', @iCategId, '_bx_snipcart_option_per_page_profile', 'digit', '', '', '', 12),
+('bx_snipcart_per_page_browse_showcase', '32', @iCategId, '_sys_option_per_page_browse_showcase', 'digit', '', '', '', 15),
+('bx_snipcart_rss_num', '10', @iCategId, '_bx_snipcart_option_rss_num', 'digit', '', '', '', 20),
+('bx_snipcart_searchable_fields', 'title,text', @iCategId, '_bx_snipcart_option_searchable_fields', 'list', '', '', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:21:"get_searchable_fields";}', 30);
+
+-- PAGE: create entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_create_entry', '_bx_snipcart_page_title_sys_create_entry', '_bx_snipcart_page_title_create_entry', 'bx_snipcart', 5, 2147483647, 1, 'create-snipcart-entry', 'page.php?i=create-snipcart-entry', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_snipcart_create_entry', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_create_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"entity_create";}', 0, 1, 1);
+
+-- PAGE: edit entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_edit_entry', '_bx_snipcart_page_title_sys_edit_entry', '_bx_snipcart_page_title_edit_entry', 'bx_snipcart', 5, 2147483647, 1, 'edit-snipcart-entry', '', '', '', '', 0, 1, 0, 'BxSnipcartPageEntry', 'modules/boonex/snipcart/classes/BxSnipcartPageEntry.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_snipcart_edit_entry', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_edit_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:11:"entity_edit";}', 0, 0, 0);
+
+-- PAGE: delete entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_delete_entry', '_bx_snipcart_page_title_sys_delete_entry', '_bx_snipcart_page_title_delete_entry', 'bx_snipcart', 5, 2147483647, 1, 'delete-snipcart-entry', '', '', '', '', 0, 1, 0, 'BxSnipcartPageEntry', 'modules/boonex/snipcart/classes/BxSnipcartPageEntry.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_snipcart_delete_entry', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_delete_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"entity_delete";}', 0, 0, 0);
+
+-- PAGE: view entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_view_entry', '_bx_snipcart_page_title_sys_view_entry', '_bx_snipcart_page_title_view_entry', 'bx_snipcart', 12, 2147483647, 1, 'view-snipcart-entry', '', '', '', '', 0, 1, 0, 'BxSnipcartPageEntry', 'modules/boonex/snipcart/classes/BxSnipcartPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_snipcart_view_entry', 2, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_text', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:17:"entity_text_block";}', 0, 0, 1, 1),
+('bx_snipcart_view_entry', 2, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_attachments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:18:"entity_attachments";}', 0, 0, 1, 2),
+('bx_snipcart_view_entry', 3, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_author', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"entity_author";}', 0, 0, 1, 3),
+('bx_snipcart_view_entry', 3, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_entry_context', '_bx_snipcart_page_block_title_entry_context', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:11:\"bx_snipcart\";s:6:\"method\";s:14:\"entity_context\";}', 0, 0, 1, 1),
+('bx_snipcart_view_entry', 3, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_info', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:11:"entity_info";}', 0, 0, 1, 2),
+('bx_snipcart_view_entry', 3, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_location', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:15:"entity_location";}', 0, 0, 0, 0),
+('bx_snipcart_view_entry', 2, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_all_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:18:"entity_all_actions";}', 0, 0, 1, 3),
+('bx_snipcart_view_entry', 4, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:14:"entity_actions";}', 0, 0, 0, 0),
+('bx_snipcart_view_entry', 4, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_social_sharing', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:21:"entity_social_sharing";}', 0, 0, 0, 0),
+('bx_snipcart_view_entry', 2, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_comments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:15:"entity_comments";}', 0, 0, 1, 4),
+('bx_snipcart_view_entry', 3, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entry_location', 3, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:13:"locations_map";s:6:"params";a:2:{i:0;s:11:"bx_snipcart";i:1;s:4:"{id}";}s:5:"class";s:20:"TemplServiceMetatags";}', 0, 0, 1, 4);
+
+-- PAGE: view entry comments
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_view_entry_comments', '_bx_snipcart_page_title_sys_view_entry_comments', '_bx_snipcart_page_title_view_entry_comments', 'bx_snipcart', 5, 2147483647, 1, 'view-snipcart-entry-comments', '', '', '', '', 0, 1, 0, 'BxSnipcartPageEntry', 'modules/boonex/snipcart/classes/BxSnipcartPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_snipcart_view_entry_comments', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_entry_comments', '_bx_snipcart_page_block_title_entry_comments_link', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:15:"entity_comments";}', 0, 0, 1);
+
+-- PAGE: popular entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_popular', '_bx_snipcart_page_title_sys_entries_popular', '_bx_snipcart_page_title_entries_popular', 'bx_snipcart', 5, 2147483647, 1, 'snipcart-popular', 'page.php?i=snipcart-popular', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_snipcart_popular', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_popular_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:14:"browse_popular";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, 1);
+
+-- PAGE: recently updated entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_updated', '_bx_snipcart_page_title_sys_entries_updated', '_bx_snipcart_page_title_entries_updated', 'bx_snipcart', 5, 2147483647, 1, 'snipcart-updated', 'page.php?i=snipcart-updated', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_snipcart_updated', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_updated_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:14:"browse_updated";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, 1);
+
+-- PAGE: entries of author
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_author', 'snipcart-author', '_bx_snipcart_page_title_sys_entries_of_author', '_bx_snipcart_page_title_entries_of_author', 'bx_snipcart', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxSnipcartPageAuthor', 'modules/boonex/snipcart/classes/BxSnipcartPageAuthor.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_snipcart_author', 1, 'bx_snipcart', '', '_bx_snipcart_page_block_title_entries_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:18:"my_entries_actions";}', 0, 0, 1, 1),
+('bx_snipcart_author', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_favorites_of_author', '_bx_snipcart_page_block_title_favorites_of_author', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:15:"browse_favorite";s:6:"params";a:1:{i:0;s:12:"{profile_id}";}}', 0, 1, 1, 2),
+('bx_snipcart_author', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_entries_of_author', '_bx_snipcart_page_block_title_entries_of_author', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"browse_author";}', 0, 0, 1, 3);
+
+-- PAGE: entries in context
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_context', 'snipcart-context', '_bx_snipcart_page_title_sys_entries_in_context', '_bx_snipcart_page_title_entries_in_context', 'bx_snipcart', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxSnipcartPageAuthor', 'modules/boonex/snipcart/classes/BxSnipcartPageAuthor.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_snipcart_context', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_entries_in_context', '_bx_snipcart_page_block_title_entries_in_context', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:11:\"bx_snipcart\";s:6:\"method\";s:14:\"browse_context\";}', 0, 0, 1, 1);
+
+-- PAGE: module home
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_home', 'snipcart-home', '_bx_snipcart_page_title_sys_home', '_bx_snipcart_page_title_home', 'bx_snipcart', 2, 2147483647, 1, 'page.php?i=snipcart-home', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_snipcart_home', 1, 'bx_snipcart', '', '_bx_snipcart_page_block_title_featured_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, 1, 0),
+('bx_snipcart_home', 1, 'bx_snipcart', '', '_bx_snipcart_page_block_title_recent_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, 1, 1),
+('bx_snipcart_home', 2, 'bx_snipcart', '', '_bx_snipcart_page_block_title_popular_keywords', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:14:"keywords_cloud";s:6:"params";a:2:{i:0;s:11:"bx_snipcart";i:1;s:11:"bx_snipcart";}s:5:"class";s:20:"TemplServiceMetatags";}', 0, 1, 1, 0),
+('bx_snipcart_home', 2, 'bx_snipcart', '', '_bx_snipcart_page_block_title_cats', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:15:"categories_list";s:6:"params";a:2:{i:0;s:16:"bx_snipcart_cats";i:1;a:1:{s:10:"show_empty";b:1;}}s:5:"class";s:20:"TemplServiceCategory";}', 0, 1, 1, 1);
+
+-- PAGE: search for entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_search', '_bx_snipcart_page_title_sys_entries_search', '_bx_snipcart_page_title_entries_search', 'bx_snipcart', 5, 2147483647, 1, 'snipcart-search', 'page.php?i=snipcart-search', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_snipcart_search', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_search_form', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:11:"bx_snipcart";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 1),
+('bx_snipcart_search', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_search_results', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:11:"bx_snipcart";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 2),
+('bx_snipcart_search', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_search_form_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:16:"bx_snipcart_cmts";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 3),
+('bx_snipcart_search', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_search_results_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:16:"bx_snipcart_cmts";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 4);
+
+-- PAGE: module manage own
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_manage', '_bx_snipcart_page_title_sys_manage', '_bx_snipcart_page_title_manage', 'bx_snipcart', 5, 2147483647, 1, 'snipcart-manage', 'page.php?i=snipcart-manage', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_snipcart_manage', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_system_manage', '_bx_snipcart_page_block_title_manage', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:12:"manage_tools";}}', 0, 1, 0);
+
+-- PAGE: module manage all
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_administration', '_bx_snipcart_page_title_sys_manage_administration', '_bx_snipcart_page_title_manage', 'bx_snipcart', 5, 192, 1, 'snipcart-administration', 'page.php?i=snipcart-administration', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_snipcart_administration', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_system_manage_administration', '_bx_snipcart_page_block_title_manage', 11, 192, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:12:"manage_tools";s:6:"params";a:1:{i:0;s:14:"administration";}}', 0, 1, 0);
+
+-- PAGE: module settings
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_settings', '_bx_snipcart_page_title_sys_settings', '_bx_snipcart_page_title_settings', 'bx_snipcart', 5, 2147483647, 1, 'snipcart-settings', 'page.php?i=snipcart-settings', '', '', '', 0, 1, 0, 'BxSnipcartPageBrowse', 'modules/boonex/snipcart/classes/BxSnipcartPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_snipcart_settings', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_system_settings', '_bx_snipcart_page_block_title_settings', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:8:"settings";}}', 0, 1, 0);
+
+-- PAGE: add block to homepage
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = 'sys_home' AND `cell_id` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('sys_home', 1, 'bx_snipcart', '_bx_snipcart_page_block_title_recent_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"browse_public";s:6:"params";a:2:{i:0;b:0;i:1;b:0;}}', 1, 0, 0, IFNULL(@iBlockOrder, 0) + 1);
+
+-- PAGES: add page block to profiles modules (trigger* page objects are processed separately upon modules enable/disable)
+SET @iPBCellProfile = 3;
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('trigger_page_profile_view_entry', @iPBCellProfile, 'bx_snipcart', '_bx_snipcart_page_block_title_my_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"browse_author";s:6:"params";a:2:{i:0;s:12:"{profile_id}";i:1;a:2:{s:8:"per_page";s:28:"bx_snipcart_per_page_profile";s:13:"empty_message";b:0;}}}', 0, 0, 0);
+
+-- PAGE: service blocks
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = '' AND `cell_id` = 0 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system` , `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('', 0, 'bx_snipcart', '', '_bx_snipcart_page_block_title_recent_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"browse_public";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 1),
+
+('', 0, 'bx_snipcart', '', '_bx_snipcart_page_block_title_recent_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 2),
+('', 0, 'bx_snipcart', '', '_bx_snipcart_page_block_title_popular_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:14:"browse_popular";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 3),
+('', 0, 'bx_snipcart', '', '_bx_snipcart_page_block_title_popular_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:14:"browse_popular";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 4),
+('', 0, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_recent_entries_view_showcase', '_bx_snipcart_page_block_title_recent_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:11:\"bx_snipcart\";s:6:\"method\";s:13:\"browse_public\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 5),
+('', 0, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_popular_entries_view_showcase',  '_bx_snipcart_page_block_title_popular_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:11:\"bx_snipcart\";s:6:\"method\";s:14:\"browse_popular\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 6),
+('', 0, 'bx_snipcart', '_bx_snipcart_page_block_title_sys_featured_entries_view_showcase', '_bx_snipcart_page_block_title_featured_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:11:\"bx_snipcart\";s:6:\"method\";s:15:\"browse_featured\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 7);
+
+
+-- MENU: add to site menu
+SET @iSiteMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_site' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_site', 'bx_snipcart', 'snipcart-home', '_bx_snipcart_menu_item_title_system_entries_home', '_bx_snipcart_menu_item_title_entries_home', 'page.php?i=snipcart-home', '', '', 'shopping-cart col-green2', 'bx_snipcart_submenu', 2147483647, 1, 1, IFNULL(@iSiteMenuOrder, 0) + 1);
+
+-- MENU: add to homepage menu
+SET @iHomepageMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_homepage' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_homepage', 'bx_snipcart', 'snipcart-home', '_bx_snipcart_menu_item_title_system_entries_home', '_bx_snipcart_menu_item_title_entries_home', 'page.php?i=snipcart-home', '', '', 'shopping-cart col-green2', 'bx_snipcart_submenu', 2147483647, 1, 1, IFNULL(@iHomepageMenuOrder, 0) + 1);
+
+-- MENU: add to "add content" menu
+SET @iAddMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_add_content_links' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_add_content_links', 'bx_snipcart', 'create-snipcart-entry', '_bx_snipcart_menu_item_title_system_create_entry', '_bx_snipcart_menu_item_title_create_entry', 'page.php?i=create-snipcart-entry', '', '', 'shopping-cart col-green2', '', 2147483647, 1, 1, IFNULL(@iAddMenuOrder, 0) + 1);
+
+-- MENU: actions menu for view entry 
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_view', '_bx_snipcart_menu_title_view_entry', 'bx_snipcart_view', 'bx_snipcart', 9, 0, 1, 'BxSnipcartMenuView', 'modules/boonex/snipcart/classes/BxSnipcartMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_view', 'bx_snipcart', '_bx_snipcart_menu_set_title_view_entry', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_snipcart_view', 'bx_snipcart', 'edit-snipcart-entry', '_bx_snipcart_menu_item_title_system_edit_entry', '_bx_snipcart_menu_item_title_edit_entry', 'page.php?i=edit-snipcart-entry&id={content_id}', '', '', 'pencil-alt', '', 2147483647, 1, 0, 1),
+('bx_snipcart_view', 'bx_snipcart', 'delete-snipcart-entry', '_bx_snipcart_menu_item_title_system_delete_entry', '_bx_snipcart_menu_item_title_delete_entry', 'page.php?i=delete-snipcart-entry&id={content_id}', '', '', 'remove', '', 2147483647, 1, 0, 2);
+
+-- MENU: all actions menu for view entry 
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_view_actions', '_sys_menu_title_view_actions', 'bx_snipcart_view_actions', 'bx_snipcart', 15, 0, 1, 'BxSnipcartMenuViewActions', 'modules/boonex/snipcart/classes/BxSnipcartMenuViewActions.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_view_actions', 'bx_snipcart', '_sys_menu_set_title_view_actions', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_snipcart_view_actions', 'bx_snipcart', 'buy-snipcart-entry', '_bx_snipcart_menu_item_title_system_buy_for', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 10),
+('bx_snipcart_view_actions', 'bx_snipcart', 'edit-snipcart-entry', '_bx_snipcart_menu_item_title_system_edit_entry', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 20),
+('bx_snipcart_view_actions', 'bx_snipcart', 'delete-snipcart-entry', '_bx_snipcart_menu_item_title_system_delete_entry', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 30),
+('bx_snipcart_view_actions', 'bx_snipcart', 'comment', '_sys_menu_item_title_system_va_comment', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 200),
+('bx_snipcart_view_actions', 'bx_snipcart', 'view', '_sys_menu_item_title_system_va_view', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 210),
+('bx_snipcart_view_actions', 'bx_snipcart', 'vote', '_sys_menu_item_title_system_va_vote', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 220),
+('bx_snipcart_view_actions', 'bx_snipcart', 'reaction', '_sys_menu_item_title_system_va_reaction', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 225),
+('bx_snipcart_view_actions', 'bx_snipcart', 'score', '_sys_menu_item_title_system_va_score', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 230),
+('bx_snipcart_view_actions', 'bx_snipcart', 'favorite', '_sys_menu_item_title_system_va_favorite', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 240),
+('bx_snipcart_view_actions', 'bx_snipcart', 'feature', '_sys_menu_item_title_system_va_feature', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 250),
+('bx_snipcart_view_actions', 'bx_snipcart', 'repost', '_sys_menu_item_title_system_va_repost', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 260),
+('bx_snipcart_view_actions', 'bx_snipcart', 'report', '_sys_menu_item_title_system_va_report', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 270),
+('bx_snipcart_view_actions', 'bx_snipcart', 'social-sharing-facebook', '_sys_menu_item_title_system_social_sharing_facebook', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 300),
+('bx_snipcart_view_actions', 'bx_snipcart', 'social-sharing-twitter', '_sys_menu_item_title_system_social_sharing_twitter', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 320),
+('bx_snipcart_view_actions', 'bx_snipcart', 'social-sharing-pinterest', '_sys_menu_item_title_system_social_sharing_pinterest', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 330),
+('bx_snipcart_view_actions', 'bx_snipcart', 'more-auto', '_sys_menu_item_title_system_va_more_auto', '_sys_menu_item_title_va_more_auto', 'javascript:void(0)', '', '', 'ellipsis-v', '', '', 0, 2147483647, 1, 0, 9999);
+
+-- MENU: actions menu for my entries
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_my', '_bx_snipcart_menu_title_entries_my', 'bx_snipcart_my', 'bx_snipcart', 9, 0, 1, 'BxSnipcartMenu', 'modules/boonex/snipcart/classes/BxSnipcartMenu.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_my', 'bx_snipcart', '_bx_snipcart_menu_set_title_entries_my', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_snipcart_my', 'bx_snipcart', 'create-snipcart-entry', '_bx_snipcart_menu_item_title_system_create_entry', '_bx_snipcart_menu_item_title_create_entry', 'page.php?i=create-snipcart-entry', '', '', 'plus', '', 2147483647, 1, 0, 0);
+
+-- MENU: module sub-menu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_submenu', '_bx_snipcart_menu_title_submenu', 'bx_snipcart_submenu', 'bx_snipcart', 8, 0, 1, '', '');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_submenu', 'bx_snipcart', '_bx_snipcart_menu_set_title_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_snipcart_submenu', 'bx_snipcart', 'snipcart-home', '_bx_snipcart_menu_item_title_system_entries_public', '_bx_snipcart_menu_item_title_entries_public', 'page.php?i=snipcart-home', '', '', '', '', 2147483647, 1, 1, 1),
+('bx_snipcart_submenu', 'bx_snipcart', 'snipcart-popular', '_bx_snipcart_menu_item_title_system_entries_popular', '_bx_snipcart_menu_item_title_entries_popular', 'page.php?i=snipcart-popular', '', '', '', '', 2147483647, 1, 1, 2),
+('bx_snipcart_submenu', 'bx_snipcart', 'snipcart-search', '_bx_snipcart_menu_item_title_system_entries_search', '_bx_snipcart_menu_item_title_entries_search', 'page.php?i=snipcart-search', '', '', '', '', 2147483647, 1, 1, 3),
+('bx_snipcart_submenu', 'bx_snipcart', 'snipcart-manage', '_bx_snipcart_menu_item_title_system_entries_manage', '_bx_snipcart_menu_item_title_entries_manage', 'page.php?i=snipcart-manage', '', '', '', '', 2147483646, 1, 1, 4),
+('bx_snipcart_submenu', 'bx_snipcart', 'snipcart-settings', '_bx_snipcart_menu_item_title_system_settings', '_bx_snipcart_menu_item_title_settings', 'page.php?i=snipcart-settings', '', '', '', '', 2147483646, 1, 1, 5),
+('bx_snipcart_submenu', 'bx_snipcart', 'snipcart-dashboard', '_bx_snipcart_menu_item_title_system_dashboard', '_bx_snipcart_menu_item_title_dashboard', 'https://app.snipcart.com', '', '_blank', '', '', 2147483646, 1, 1, 6);
+
+-- MENU: sub-menu for view entry
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_view_submenu', '_bx_snipcart_menu_title_view_entry_submenu', 'bx_snipcart_view_submenu', 'bx_snipcart', 8, 0, 0, 'BxSnipcartMenuView', 'modules/boonex/snipcart/classes/BxSnipcartMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_view_submenu', 'bx_snipcart', '_bx_snipcart_menu_set_title_view_entry_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_snipcart_view_submenu', 'bx_snipcart', 'view-snipcart-entry', '_bx_snipcart_menu_item_title_system_view_entry', '_bx_snipcart_menu_item_title_view_entry_submenu_entry', 'page.php?i=view-snipcart-entry&id={content_id}', '', '', '', '', 2147483647, 1, 0, 1),
+('bx_snipcart_view_submenu', 'bx_snipcart', 'view-snipcart-entry-comments', '_bx_snipcart_menu_item_title_system_view_entry_comments', '_bx_snipcart_menu_item_title_view_entry_submenu_comments', 'page.php?i=view-snipcart-entry-comments&id={content_id}', '', '', '', '', 2147483647, 0, 0, 2);
+
+-- MENU: custom menu for snippet meta info
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_snippet_meta', '_sys_menu_title_snippet_meta', 'bx_snipcart_snippet_meta', 'bx_snipcart', 15, 0, 1, 'BxSnipcartMenuSnippetMeta', 'modules/boonex/snipcart/classes/BxSnipcartMenuSnippetMeta.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_snippet_meta', 'bx_snipcart', '_sys_menu_set_title_snippet_meta', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
+('bx_snipcart_snippet_meta', 'bx_snipcart', 'date', '_sys_menu_item_title_system_sm_date', '_sys_menu_item_title_sm_date', '', '', '', '', '', 2147483647, 1, 0, 1, 1),
+('bx_snipcart_snippet_meta', 'bx_snipcart', 'author', '_sys_menu_item_title_system_sm_author', '_sys_menu_item_title_sm_author', '', '', '', '', '', 2147483647, 1, 0, 1, 2),
+('bx_snipcart_snippet_meta', 'bx_snipcart', 'category', '_sys_menu_item_title_system_sm_category', '_sys_menu_item_title_sm_category', '', '', '', '', '', 2147483647, 0, 0, 1, 3),
+('bx_snipcart_snippet_meta', 'bx_snipcart', 'tags', '_sys_menu_item_title_system_sm_tags', '_sys_menu_item_title_sm_tags', '', '', '', '', '', 2147483647, 0, 0, 1, 4),
+('bx_snipcart_snippet_meta', 'bx_snipcart', 'views', '_sys_menu_item_title_system_sm_views', '_sys_menu_item_title_sm_views', '', '', '', '', '', 2147483647, 0, 0, 1, 5),
+('bx_snipcart_snippet_meta', 'bx_snipcart', 'comments', '_sys_menu_item_title_system_sm_comments', '_sys_menu_item_title_sm_comments', '', '', '', '', '', 2147483647, 0, 0, 1, 6);
+
+-- MENU: profile stats
+SET @iNotifMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name` = 'sys_profile_stats' AND `active` = 1 LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
+('sys_profile_stats', 'bx_snipcart', 'profile-stats-manage-snipcart', '_bx_snipcart_menu_item_title_system_manage_my_entries', '_bx_snipcart_menu_item_title_manage_my_entries', 'page.php?i=snipcart-manage', '', '_self', 'shopping-cart col-green2', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:41:"get_menu_addon_manage_tools_profile_stats";}', '', 2147483646, 1, 0, @iNotifMenuOrder + 1);
+
+-- MENU: manage tools submenu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart_menu_manage_tools', '_bx_snipcart_menu_title_manage_tools', 'bx_snipcart_menu_manage_tools', 'bx_snipcart', 6, 0, 1, 'BxSnipcartMenuManageTools', 'modules/boonex/snipcart/classes/BxSnipcartMenuManageTools.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_snipcart_menu_manage_tools', 'bx_snipcart', '_bx_snipcart_menu_set_title_manage_tools', 0);
+
+--INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+--('bx_snipcart_menu_manage_tools', 'bx_snipcart', 'delete-with-content', '_bx_snipcart_menu_item_title_system_delete_with_content', '_bx_snipcart_menu_item_title_delete_with_content', 'javascript:void(0)', 'javascript:{js_object}.onClickDeleteWithContent({content_id});', '_self', 'far trash-alt', '', 128, 1, 0, 0);
+
+-- MENU: dashboard manage tools
+SET @iManageMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard_manage_tools' LIMIT 1);
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_account_dashboard_manage_tools', 'bx_snipcart', 'snipcart-administration', '_bx_snipcart_menu_item_title_system_admt_entries', '_bx_snipcart_menu_item_title_admt_entries', 'page.php?i=snipcart-administration', '', '_self', 'shopping-cart', 'a:2:{s:6:"module";s:11:"bx_snipcart";s:6:"method";s:27:"get_menu_addon_manage_tools";}', '', 192, 1, 0, @iManageMenuOrder + 1);
+
+-- MENU: add menu item to profiles modules (trigger* menu sets are processed separately upon modules enable/disable)
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('trigger_profile_view_submenu', 'bx_snipcart', 'snipcart-author', '_bx_snipcart_menu_item_title_system_view_entries_author', '_bx_snipcart_menu_item_title_view_entries_author', 'page.php?i=snipcart-author&profile_id={profile_id}', '', '', 'shopping-cart col-green2', '', 2147483647, 1, 0, 0),
+('trigger_group_view_submenu', 'bx_snipcart', 'snipcart-context', '_bx_snipcart_menu_item_title_system_view_entries_in_context', '_bx_snipcart_menu_item_title_view_entries_in_context', 'page.php?i=snipcart-context&profile_id={profile_id}', '', '', 'shopping-cart col-green2', '', 2147483647, 1, 0, 0);
+  
+-- PRIVACY 
+INSERT INTO `sys_objects_privacy` (`object`, `module`, `action`, `title`, `default_group`, `table`, `table_field_id`, `table_field_author`, `override_class_name`, `override_class_file`) VALUES
+('bx_snipcart_allow_view_to', 'bx_snipcart', 'view', '_bx_snipcart_form_entry_input_allow_view_to', '3', 'bx_snipcart_entries', 'id', 'author', '', '');
+
+
+-- ACL
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_snipcart', 'create entry', NULL, '_bx_snipcart_acl_action_create_entry', '', 1, 3);
+SET @iIdActionEntryCreate = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_snipcart', 'delete entry', NULL, '_bx_snipcart_acl_action_delete_entry', '', 1, 3);
+SET @iIdActionEntryDelete = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_snipcart', 'view entry', NULL, '_bx_snipcart_acl_action_view_entry', '', 1, 0);
+SET @iIdActionEntryView = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_snipcart', 'set thumb', NULL, '_bx_snipcart_acl_action_set_thumb', '', 1, 3);
+SET @iIdActionSetThumb = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_snipcart', 'edit any entry', NULL, '_bx_snipcart_acl_action_edit_any_entry', '', 1, 3);
+SET @iIdActionEntryEditAny = LAST_INSERT_ID();
+
+SET @iUnauthenticated = 1;
+SET @iAccount = 2;
+SET @iStandard = 3;
+SET @iUnconfirmed = 4;
+SET @iPending = 5;
+SET @iSuspended = 6;
+SET @iModerator = 7;
+SET @iAdministrator = 8;
+SET @iPremium = 9;
+
+INSERT INTO `sys_acl_matrix` (`IDLevel`, `IDAction`) VALUES
+
+-- entry create
+(@iStandard, @iIdActionEntryCreate),
+(@iModerator, @iIdActionEntryCreate),
+(@iAdministrator, @iIdActionEntryCreate),
+(@iPremium, @iIdActionEntryCreate),
+
+-- entry delete
+(@iStandard, @iIdActionEntryDelete),
+(@iModerator, @iIdActionEntryDelete),
+(@iAdministrator, @iIdActionEntryDelete),
+(@iPremium, @iIdActionEntryDelete),
+
+-- entry view
+(@iUnauthenticated, @iIdActionEntryView),
+(@iAccount, @iIdActionEntryView),
+(@iStandard, @iIdActionEntryView),
+(@iUnconfirmed, @iIdActionEntryView),
+(@iPending, @iIdActionEntryView),
+(@iModerator, @iIdActionEntryView),
+(@iAdministrator, @iIdActionEntryView),
+(@iPremium, @iIdActionEntryView),
+
+-- set entry thumb
+(@iStandard, @iIdActionSetThumb),
+(@iModerator, @iIdActionSetThumb),
+(@iAdministrator, @iIdActionSetThumb),
+(@iPremium, @iIdActionSetThumb),
+
+-- edit any entry
+(@iModerator, @iIdActionEntryEditAny),
+(@iAdministrator, @iIdActionEntryEditAny);
+
+
+-- SEARCH
+SET @iSearchOrder = (SELECT IFNULL(MAX(`Order`), 0) FROM `sys_objects_search`);
+INSERT INTO `sys_objects_search` (`ObjectName`, `Title`, `Order`, `ClassName`, `ClassPath`) VALUES
+('bx_snipcart', '_bx_snipcart', @iSearchOrder + 1, 'BxSnipcartSearchResult', 'modules/boonex/snipcart/classes/BxSnipcartSearchResult.php'),
+('bx_snipcart_cmts', '_bx_snipcart_cmts', @iSearchOrder + 2, 'BxSnipcartCmtsSearchResult', 'modules/boonex/snipcart/classes/BxSnipcartCmtsSearchResult.php');
+
+
+-- METATAGS
+INSERT INTO `sys_objects_metatags` (`object`, `table_keywords`, `table_locations`, `table_mentions`, `override_class_name`, `override_class_file`) VALUES
+('bx_snipcart', 'bx_snipcart_meta_keywords', 'bx_snipcart_meta_locations', 'bx_snipcart_meta_mentions', '', '');
+
+
+-- CATEGORY
+INSERT INTO `sys_objects_category` (`object`, `search_object`, `form_object`, `list_name`, `table`, `field`, `join`, `where`, `override_class_name`, `override_class_file`) VALUES
+('bx_snipcart_cats', 'bx_snipcart', 'bx_snipcart', 'bx_snipcart_cats', 'bx_snipcart_entries', 'cat', 'INNER JOIN `sys_profiles` ON (`sys_profiles`.`id` = `bx_snipcart_entries`.`author`)', 'AND `sys_profiles`.`status` = ''active''', '', '');
+
+
+-- STATS
+SET @iMaxOrderStats = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_statistics`);
+INSERT INTO `sys_statistics` (`module`, `name`, `title`, `link`, `icon`, `query`, `order`) VALUES 
+('bx_snipcart', 'bx_snipcart', '_bx_snipcart', 'page.php?i=snipcart-home', 'shopping-cart col-green2', 'SELECT COUNT(*) FROM `bx_snipcart_entries` WHERE 1 AND `status` = ''active'' AND `status_admin` = ''active''', @iMaxOrderStats + 1);
+
+-- CHARTS
+SET @iMaxOrderCharts = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_objects_chart`);
+INSERT INTO `sys_objects_chart` (`object`, `title`, `table`, `field_date_ts`, `field_date_dt`, `field_status`, `query`, `active`, `order`, `class_name`, `class_file`) VALUES
+('bx_snipcart_growth', '_bx_snipcart_chart_growth', 'bx_snipcart_entries', 'added', '', 'status,status_admin', '', 1, @iMaxOrderCharts + 1, 'BxDolChartGrowth', ''),
+('bx_snipcart_growth_speed', '_bx_snipcart_chart_growth_speed', 'bx_snipcart_entries', 'added', '', 'status,status_admin', '', 1, @iMaxOrderCharts + 2, 'BxDolChartGrowthSpeed', '');
+
+-- GRIDS: moderation tools
+INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) VALUES
+('bx_snipcart_administration', 'Sql', 'SELECT * FROM `bx_snipcart_entries` WHERE 1 ', 'bx_snipcart_entries', 'id', 'added', 'status_admin', '', 20, NULL, 'start', '', 'title,text', '', 'like', 'reports', '', 192, 'BxSnipcartGridAdministration', 'modules/boonex/snipcart/classes/BxSnipcartGridAdministration.php'),
+('bx_snipcart_common', 'Sql', 'SELECT * FROM `bx_snipcart_entries` WHERE 1 ', 'bx_snipcart_entries', 'id', 'added', 'status', '', 20, NULL, 'start', '', 'title,text', '', 'like', '', '', 2147483647, 'BxSnipcartGridCommon', 'modules/boonex/snipcart/classes/BxSnipcartGridCommon.php');
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
+('bx_snipcart_administration', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_snipcart_administration', 'switcher', '_bx_snipcart_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_snipcart_administration', 'reports', '_sys_txt_reports_title', '5%', 0, '', '', 3),
+('bx_snipcart_administration', 'title', '_bx_snipcart_grid_column_title_adm_title', '25%', 0, '25', '', 4),
+('bx_snipcart_administration', 'added', '_bx_snipcart_grid_column_title_adm_added', '20%', 1, '25', '', 5),
+('bx_snipcart_administration', 'author', '_bx_snipcart_grid_column_title_adm_author', '20%', 0, '25', '', 6),
+('bx_snipcart_administration', 'actions', '', '20%', 0, '', '', 7),
+
+('bx_snipcart_common', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_snipcart_common', 'switcher', '_bx_snipcart_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_snipcart_common', 'title', '_bx_snipcart_grid_column_title_adm_title', '40%', 0, '35', '', 3),
+('bx_snipcart_common', 'added', '_bx_snipcart_grid_column_title_adm_added', '30%', 1, '25', '', 4),
+('bx_snipcart_common', 'actions', '', '20%', 0, '', '', 5);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon_only`, `confirm`, `order`) VALUES
+('bx_snipcart_administration', 'bulk', 'delete', '_bx_snipcart_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_snipcart_administration', 'single', 'edit', '_bx_snipcart_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_snipcart_administration', 'single', 'delete', '_bx_snipcart_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_snipcart_administration', 'single', 'settings', '_bx_snipcart_grid_action_title_adm_more_actions', 'cog', 1, 0, 3),
+
+('bx_snipcart_common', 'bulk', 'delete', '_bx_snipcart_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_snipcart_common', 'single', 'edit', '_bx_snipcart_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_snipcart_common', 'single', 'delete', '_bx_snipcart_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_snipcart_common', 'single', 'settings', '_bx_snipcart_grid_action_title_adm_more_actions', 'cog', 1, 0, 3);
+
+
+-- ALERTS
+INSERT INTO `sys_alerts_handlers` (`name`, `class`, `file`, `service_call`) VALUES 
+('bx_snipcart', 'BxSnipcartAlertsResponse', 'modules/boonex/snipcart/classes/BxSnipcartAlertsResponse.php', '');
+SET @iHandler := LAST_INSERT_ID();
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('system', 'save_setting', @iHandler),
+('profile', 'delete', @iHandler);

+ 406 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/sql/install.sql

@@ -0,0 +1,406 @@
+SET @sStorageEngine = (SELECT `value` FROM `sys_options` WHERE `name` = 'sys_storage_default');
+
+
+-- TABLE: entries
+CREATE TABLE IF NOT EXISTS `bx_snipcart_entries` (
+  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+  `author` int(10) unsigned NOT NULL,
+  `added` int(11) NOT NULL,
+  `changed` int(11) NOT NULL,
+  `thumb` int(11) NOT NULL,
+  `title` varchar(255) NOT NULL,
+  `cat` int(11) NOT NULL,
+  `text` text NOT NULL,
+  `price` float NOT NULL default '0',
+  `weight` float NOT NULL default '0',
+  `views` int(11) NOT NULL default '0',
+  `rate` float NOT NULL default '0',
+  `votes` int(11) NOT NULL default '0',
+  `rrate` float NOT NULL default '0',
+  `rvotes` int(11) NOT NULL default '0',
+  `score` int(11) NOT NULL default '0',
+  `sc_up` int(11) NOT NULL default '0',
+  `sc_down` int(11) NOT NULL default '0',
+  `favorites` int(11) NOT NULL default '0',
+  `comments` int(11) NOT NULL default '0',
+  `reports` int(11) NOT NULL default '0',
+  `featured` int(11) NOT NULL default '0',
+  `allow_view_to` varchar(16) NOT NULL DEFAULT '3',
+  `status` enum('active','hidden') NOT NULL DEFAULT 'active',
+  `status_admin` enum('active','hidden') NOT NULL DEFAULT 'active',
+  PRIMARY KEY (`id`),
+  FULLTEXT KEY `title_text` (`title`,`text`)
+);
+
+-- TABLE: settings
+CREATE TABLE IF NOT EXISTS `bx_snipcart_settings` (
+  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+  `author` int(10) unsigned NOT NULL,
+  `mode` varchar(8) NOT NULL DEFAULT '',
+  `api_key_test` varchar(255) NOT NULL DEFAULT '',
+  `api_key_live` varchar(255) NOT NULL DEFAULT '',
+  `currency` varchar(4) NOT NULL DEFAULT '',
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `author` (`author`)
+);
+
+-- TABLE: storages & transcoders
+CREATE TABLE IF NOT EXISTS `bx_snipcart_files` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_photos_resized` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+-- TABLE: comments
+CREATE TABLE IF NOT EXISTS `bx_snipcart_cmts` (
+  `cmt_id` int(11) NOT NULL AUTO_INCREMENT,
+  `cmt_parent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_vparent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_object_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_author_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_level` int(11) NOT NULL DEFAULT '0',
+  `cmt_text` text NOT NULL,
+  `cmt_mood` tinyint(4) NOT NULL DEFAULT '0',
+  `cmt_rate` int(11) NOT NULL DEFAULT '0',
+  `cmt_rate_count` int(11) NOT NULL DEFAULT '0',
+  `cmt_time` int(11) unsigned NOT NULL DEFAULT '0',
+  `cmt_replies` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`cmt_id`),
+  KEY `cmt_object_id` (`cmt_object_id`,`cmt_parent_id`),
+  FULLTEXT KEY `search_fields` (`cmt_text`)
+);
+
+-- TABLE: votes
+CREATE TABLE IF NOT EXISTS `bx_snipcart_votes` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_votes_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_reactions` (
+  `object_id` int(11) NOT NULL default '0',
+  `reaction` varchar(32) NOT NULL default '',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `reaction` (`object_id`, `reaction`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_reactions_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `reaction` varchar(32) NOT NULL default '',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+-- TABLE: views
+CREATE TABLE IF NOT EXISTS `bx_snipcart_views_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `viewer_id` int(11) NOT NULL default '0',
+  `viewer_nip` int(11) unsigned NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`viewer_id`,`viewer_nip`)
+);
+
+-- TABLE: metas
+CREATE TABLE IF NOT EXISTS `bx_snipcart_meta_keywords` (
+  `object_id` int(10) unsigned NOT NULL,
+  `keyword` varchar(255) NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `keyword` (`keyword`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_meta_locations` (
+  `object_id` int(10) unsigned NOT NULL,
+  `lat` double NOT NULL,
+  `lng` double NOT NULL,
+  `country` varchar(2) NOT NULL,
+  `state` varchar(255) NOT NULL,
+  `city` varchar(255) NOT NULL,
+  `zip` varchar(255) NOT NULL,
+  `street` varchar(255) NOT NULL,
+  `street_number` varchar(255) NOT NULL,
+  PRIMARY KEY (`object_id`),
+  KEY `country_state_city` (`country`,`state`(8),`city`(8))
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_meta_mentions` (
+  `object_id` int(10) unsigned NOT NULL,
+  `profile_id` int(10) unsigned NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `profile_id` (`profile_id`)
+);
+
+-- TABLE: reports
+CREATE TABLE IF NOT EXISTS `bx_snipcart_reports` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_reports_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(32) NOT NULL default '',
+  `text` text NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `report` (`object_id`, `author_nip`)
+);
+
+-- TABLE: favorites
+CREATE TABLE IF NOT EXISTS `bx_snipcart_favorites_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`author_id`)
+);
+
+-- TABLE: scores
+CREATE TABLE IF NOT EXISTS `bx_snipcart_scores` (
+  `object_id` int(11) NOT NULL default '0',
+  `count_up` int(11) NOT NULL default '0',
+  `count_down` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_snipcart_scores_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(8) NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+
+-- STORAGES & TRANSCODERS
+INSERT INTO `sys_objects_storage` (`object`, `engine`, `params`, `token_life`, `cache_control`, `levels`, `table_files`, `ext_mode`, `ext_allow`, `ext_deny`, `quota_size`, `current_size`, `quota_number`, `current_number`, `max_file_size`, `ts`) VALUES
+('bx_snipcart_files', @sStorageEngine, '', 360, 2592000, 3, 'bx_snipcart_files', 'allow-deny', 'jpg,jpeg,jpe,gif,png', '', 0, 0, 0, 0, 0, 0),
+('bx_snipcart_photos_resized', @sStorageEngine, '', 360, 2592000, 3, 'bx_snipcart_photos_resized', 'allow-deny', 'jpg,jpeg,jpe,gif,png', '', 0, 0, 0, 0, 0, 0);
+
+INSERT INTO `sys_objects_transcoder` (`object`, `storage_object`, `source_type`, `source_params`, `private`, `atime_tracking`, `atime_pruning`, `ts`) VALUES 
+('bx_snipcart_preview', 'bx_snipcart_photos_resized', 'Storage', 'a:1:{s:6:"object";s:17:"bx_snipcart_files";}', 'no', '1', '2592000', '0'),
+('bx_snipcart_gallery', 'bx_snipcart_photos_resized', 'Storage', 'a:1:{s:6:"object";s:17:"bx_snipcart_files";}', 'no', '1', '2592000', '0'), 
+('bx_snipcart_cover', 'bx_snipcart_photos_resized', 'Storage', 'a:1:{s:6:"object";s:17:"bx_snipcart_files";}', 'no', '1', '2592000', '0');
+
+INSERT INTO `sys_transcoder_filters` (`transcoder_object`, `filter`, `filter_params`, `order`) VALUES 
+('bx_snipcart_preview', 'Resize', 'a:3:{s:1:"w";s:3:"300";s:1:"h";s:3:"200";s:11:"crop_resize";s:1:"1";}', '0'),
+('bx_snipcart_gallery', 'Resize', 'a:1:{s:1:"w";s:3:"500";}', '0'),
+('bx_snipcart_cover', 'Resize', 'a:1:{s:1:"w";s:4:"2000";}', '0');
+
+
+-- FORMS
+INSERT INTO `sys_objects_form`(`object`, `module`, `title`, `action`, `form_attrs`, `table`, `key`, `uri`, `uri_title`, `submit_name`, `params`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_snipcart', 'bx_snipcart', '_bx_snipcart_form_entry', '', 'a:1:{s:7:"enctype";s:19:"multipart/form-data";}', 'bx_snipcart_entries', 'id', '', '', 'a:2:{i:0;s:9:"do_submit";i:1;s:10:"do_publish";}', '', 0, 1, 'BxSnipcartFormEntry', 'modules/boonex/snipcart/classes/BxSnipcartFormEntry.php'),
+('bx_snipcart_settings', 'bx_snipcart', '_bx_snipcart_form_settings', '', 'a:1:{s:7:"enctype";s:19:"multipart/form-data";}', 'bx_snipcart_settings', 'id', '', '', 'do_submit', '', 0, 1, 'BxSnipcartFormSettings', 'modules/boonex/snipcart/classes/BxSnipcartFormSettings.php');
+
+INSERT INTO `sys_form_displays`(`object`, `display_name`, `module`, `view_mode`, `title`) VALUES 
+('bx_snipcart', 'bx_snipcart_entry_add', 'bx_snipcart', 0, '_bx_snipcart_form_entry_display_add'),
+('bx_snipcart', 'bx_snipcart_entry_delete', 'bx_snipcart', 0, '_bx_snipcart_form_entry_display_delete'),
+('bx_snipcart', 'bx_snipcart_entry_edit', 'bx_snipcart', 0, '_bx_snipcart_form_entry_display_edit'),
+('bx_snipcart', 'bx_snipcart_entry_view', 'bx_snipcart', 1, '_bx_snipcart_form_entry_display_view'),
+
+('bx_snipcart_settings', 'bx_snipcart_settings_edit', 'bx_snipcart', 0, '_bx_snipcart_form_settings_display_edit');
+
+INSERT INTO `sys_form_inputs`(`object`, `module`, `name`, `value`, `values`, `checked`, `type`, `caption_system`, `caption`, `info`, `required`, `collapsed`, `html`, `attrs`, `attrs_tr`, `attrs_wrapper`, `checker_func`, `checker_params`, `checker_error`, `db_pass`, `db_params`, `editable`, `deletable`) VALUES 
+('bx_snipcart', 'bx_snipcart', 'allow_view_to', '', '', 0, 'custom', '_bx_snipcart_form_entry_input_sys_allow_view_to', '_bx_snipcart_form_entry_input_allow_view_to', '', 1, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'delete_confirm', 1, '', 0, 'checkbox', '_bx_snipcart_form_entry_input_sys_delete_confirm', '_bx_snipcart_form_entry_input_delete_confirm', '_bx_snipcart_form_entry_input_delete_confirm_info', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_entry_input_delete_confirm_error', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'do_publish', '_bx_snipcart_form_entry_input_do_publish', '', 0, 'submit', '_bx_snipcart_form_entry_input_sys_do_publish', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'do_submit', '_bx_snipcart_form_entry_input_do_submit', '', 0, 'submit', '_bx_snipcart_form_entry_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'location', '', '', 0, 'location', '_sys_form_input_sys_location', '_sys_form_input_location', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'pictures', 'a:1:{i:0;s:9:"sys_html5";}', 'a:2:{s:10:"sys_simple";s:26:"_sys_uploader_simple_title";s:9:"sys_html5";s:25:"_sys_uploader_html5_title";}', 0, 'files', '_bx_snipcart_form_entry_input_sys_pictures', '_bx_snipcart_form_entry_input_pictures', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'text', '', '', 0, 'textarea', '_bx_snipcart_form_entry_input_sys_text', '_bx_snipcart_form_entry_input_text', '', 1, 0, 2, '', '', '', 'Avail', '', '_bx_snipcart_form_entry_input_text_err', 'XssHtml', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'title', '', '', 0, 'text', '_bx_snipcart_form_entry_input_sys_title', '_bx_snipcart_form_entry_input_title', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_entry_input_title_err', 'Xss', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'cat', '', '#!bx_snipcart_cats', 0, 'select', '_bx_snipcart_form_entry_input_sys_cat', '_bx_snipcart_form_entry_input_cat', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_entry_input_cat_err', 'Xss', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'price', '', '', 0, 'text', '_bx_snipcart_form_entry_input_sys_price', '_bx_snipcart_form_entry_input_price', '_bx_snipcart_form_entry_input_price_inf', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_entry_input_price_err', 'Float', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'weight', '', '', 0, 'text', '_bx_snipcart_form_entry_input_sys_weight', '_bx_snipcart_form_entry_input_weight', '_bx_snipcart_form_entry_input_weight_inf', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_entry_input_weight_err', 'Float', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'added', '', '', 0, 'datetime', '_bx_snipcart_form_entry_input_sys_date_added', '_bx_snipcart_form_entry_input_date_added', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_snipcart', 'bx_snipcart', 'changed', '', '', 0, 'datetime', '_bx_snipcart_form_entry_input_sys_date_changed', '_bx_snipcart_form_entry_input_date_changed', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+
+('bx_snipcart_settings', 'bx_snipcart', 'mode', '', '#!bx_snipcart_modes', 0, 'select', '_bx_snipcart_form_settings_input_sys_mode', '_bx_snipcart_form_settings_input_mode', '', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_settings_input_mode_err', 'Xss', '', 0, 0),
+('bx_snipcart_settings', 'bx_snipcart', 'api_key_test', '', '', 0, 'text', '_bx_snipcart_form_settings_input_sys_api_key_test', '_bx_snipcart_form_settings_input_api_key_test', '', 0, 0, 0, '', '', '', '', '', '', 'Xss', '', 1, 0),
+('bx_snipcart_settings', 'bx_snipcart', 'api_key_live', '', '', 0, 'text', '_bx_snipcart_form_settings_input_sys_api_key_live', '_bx_snipcart_form_settings_input_api_key_live', '', 0, 0, 0, '', '', '', '', '', '', 'Xss', '', 1, 0),
+('bx_snipcart_settings', 'bx_snipcart', 'currency', '', '#!bx_snipcart_currencies', 0, 'select', '_bx_snipcart_form_settings_input_sys_currency', '_bx_snipcart_form_settings_input_currency', '_bx_snipcart_form_settings_input_currency_inf', 1, 0, 0, '', '', '', 'Avail', '', '_bx_snipcart_form_settings_input_currency_err', 'Xss', '', 1, 0),
+('bx_snipcart_settings', 'bx_snipcart', 'do_submit', '_bx_snipcart_form_settings_input_do_submit', '', 0, 'submit', '_bx_snipcart_form_settings_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0);
+
+INSERT INTO `sys_form_display_inputs`(`display_name`, `input_name`, `visible_for_levels`, `active`, `order`) VALUES 
+('bx_snipcart_entry_add', 'title', 2147483647, 1, 1),
+('bx_snipcart_entry_add', 'cat', 2147483647, 1, 2),
+('bx_snipcart_entry_add', 'text', 2147483647, 1, 3),
+('bx_snipcart_entry_add', 'price', 2147483647, 1, 4),
+('bx_snipcart_entry_add', 'weight', 2147483647, 1, 5),
+('bx_snipcart_entry_add', 'pictures', 2147483647, 1, 6),
+('bx_snipcart_entry_add', 'allow_view_to', 2147483647, 1, 7),
+('bx_snipcart_entry_add', 'location', 2147483647, 1, 8),
+('bx_snipcart_entry_add', 'do_publish', 2147483647, 1, 9),
+
+('bx_snipcart_entry_delete', 'delete_confirm', 2147483647, 1, 1),
+('bx_snipcart_entry_delete', 'do_submit', 2147483647, 1, 2),
+
+('bx_snipcart_entry_edit', 'title', 2147483647, 1, 1),
+('bx_snipcart_entry_edit', 'cat', 2147483647, 1, 2),
+('bx_snipcart_entry_edit', 'text', 2147483647, 1, 3),
+('bx_snipcart_entry_edit', 'price', 2147483647, 1, 4),
+('bx_snipcart_entry_edit', 'weight', 2147483647, 1, 5),
+('bx_snipcart_entry_edit', 'pictures', 2147483647, 1, 6),
+('bx_snipcart_entry_edit', 'allow_view_to', 2147483647, 1, 7),
+('bx_snipcart_entry_edit', 'location', 2147483647, 1, 8),
+('bx_snipcart_entry_edit', 'do_submit', 2147483647, 1, 9),
+
+('bx_snipcart_entry_view', 'cat', 2147483647, 1, 1),
+('bx_snipcart_entry_view', 'weight', 2147483647, 1, 2),
+('bx_snipcart_entry_view', 'added', 2147483647, 1, 3),
+('bx_snipcart_entry_view', 'changed', 2147483647, 1, 4),
+
+('bx_snipcart_entry_view_full', 'cat', 2147483647, 1, 1),
+('bx_snipcart_entry_view_full', 'text', 2147483647, 1, 2),
+('bx_snipcart_entry_view_full', 'weight', 2147483647, 1, 3),
+('bx_snipcart_entry_view_full', 'added', 2147483647, 1, 4),
+('bx_snipcart_entry_view_full', 'changed', 2147483647, 1, 5),
+
+('bx_snipcart_settings_edit', 'mode', 2147483647, 1, 1),
+('bx_snipcart_settings_edit', 'api_key_test', 2147483647, 1, 2),
+('bx_snipcart_settings_edit', 'api_key_live', 2147483647, 1, 3),
+('bx_snipcart_settings_edit', 'currency', 2147483647, 1, 4),
+('bx_snipcart_settings_edit', 'do_submit', 2147483647, 1, 5);
+
+
+-- PRE-VALUES
+INSERT INTO `sys_form_pre_lists`(`key`, `title`, `module`, `use_for_sets`, `extendable`) VALUES
+('bx_snipcart_cats', '_bx_snipcart_pre_lists_cats', 'bx_snipcart', '0', '1'),
+('bx_snipcart_modes', '_bx_snipcart_pre_lists_modes', 'bx_snipcart', '0', '0'),
+('bx_snipcart_currencies', '_bx_snipcart_pre_lists_currencies', 'bx_snipcart', '0', '0');
+
+INSERT INTO `sys_form_pre_values`(`Key`, `Value`, `Order`, `LKey`, `LKey2`) VALUES
+('bx_snipcart_cats', '', 0, '_sys_please_select', ''),
+('bx_snipcart_cats', '1', 1, '_bx_snipcart_cat_automotive_and_industrial', ''),
+('bx_snipcart_cats', '2', 2, '_bx_snipcart_cat_beauty_health_food', ''),
+('bx_snipcart_cats', '3', 3, '_bx_snipcart_cat_books', ''),
+('bx_snipcart_cats', '4', 4, '_bx_snipcart_cat_clothing_shoes_jewelry', ''),
+('bx_snipcart_cats', '5', 5, '_bx_snipcart_cat_electronics_and_computers', ''),
+('bx_snipcart_cats', '6', 6, '_bx_snipcart_cat_handmade', ''),
+('bx_snipcart_cats', '7', 7, '_bx_snipcart_cat_home_garden_tools', ''),
+('bx_snipcart_cats', '8', 8, '_bx_snipcart_cat_movies_music_games', ''),
+('bx_snipcart_cats', '9', 9, '_bx_snipcart_cat_sports_and_outdoors', ''),
+('bx_snipcart_cats', '10', 10, '_bx_snipcart_cat_toys_kids_baby', ''),
+
+('bx_snipcart_modes', '', 0, '_sys_please_select', ''),
+('bx_snipcart_modes', 'test', 1, '_bx_snipcart_mode_test', ''),
+('bx_snipcart_modes', 'live', 2, '_bx_snipcart_mode_live', ''),
+
+('bx_snipcart_currencies', '', 0, '_sys_please_select', ''),
+('bx_snipcart_currencies', 'CAD', 1, 'CAD', 'C&#36;'),
+('bx_snipcart_currencies', 'EUR', 2, 'EUR', '&#128;'),
+('bx_snipcart_currencies', 'USD', 3, 'USD', '&#36;');
+
+
+-- COMMENTS
+INSERT INTO `sys_objects_cmts` (`Name`, `Module`, `Table`, `CharsPostMin`, `CharsPostMax`, `CharsDisplayMax`, `Html`, `PerView`, `PerViewReplies`, `BrowseType`, `IsBrowseSwitch`, `PostFormPosition`, `NumberOfLevels`, `IsDisplaySwitch`, `IsRatable`, `ViewingThreshold`, `IsOn`, `RootStylePrefix`, `BaseUrl`, `ObjectVote`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldTitle`, `TriggerFieldComments`, `ClassName`, `ClassFile`) VALUES
+('bx_snipcart', 'bx_snipcart', 'bx_snipcart_cmts', 1, 5000, 1000, 3, 5, 3, 'tail', 1, 'bottom', 1, 1, 1, -3, 1, 'cmt', 'page.php?i=view-snipcart-entry&id={object_id}', '', 'bx_snipcart_entries', 'id', 'author', 'title', 'comments', '', '');
+
+
+-- VOTES
+INSERT INTO `sys_objects_vote` (`Name`, `TableMain`, `TableTrack`, `PostTimeout`, `MinValue`, `MaxValue`, `IsUndo`, `IsOn`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldRate`, `TriggerFieldRateCount`, `ClassName`, `ClassFile`) VALUES 
+('bx_snipcart', 'bx_snipcart_votes', 'bx_snipcart_votes_track', '604800', '1', '1', '0', '1', 'bx_snipcart_entries', 'id', 'author', 'rate', 'votes', '', ''),
+('bx_snipcart_reactions', 'bx_snipcart_reactions', 'bx_snipcart_reactions_track', '604800', '1', '1', '1', '1', 'bx_snipcart_entries', 'id', 'author', 'rrate', 'rvotes', 'BxTemplVoteReactions', '');
+
+
+-- SCORES
+INSERT INTO `sys_objects_score` (`name`, `module`, `table_main`, `table_track`, `post_timeout`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_score`, `trigger_field_cup`, `trigger_field_cdown`, `class_name`, `class_file`) VALUES 
+('bx_snipcart', 'bx_snipcart', 'bx_snipcart_scores', 'bx_snipcart_scores_track', '604800', '0', 'bx_snipcart_entries', 'id', 'author', 'score', 'sc_up', 'sc_down', '', '');
+
+
+-- REPORTS
+INSERT INTO `sys_objects_report` (`name`, `table_main`, `table_track`, `is_on`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_snipcart', 'bx_snipcart_reports', 'bx_snipcart_reports_track', '1', 'page.php?i=view-snipcart-entry&id={object_id}', 'bx_snipcart_entries', 'id', 'author', 'reports', '', '');
+
+
+-- VIEWS
+INSERT INTO `sys_objects_view` (`name`, `table_track`, `period`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_snipcart', 'bx_snipcart_views_track', '86400', '1', 'bx_snipcart_entries', 'id', 'author', 'views', '', '');
+
+
+-- FAFORITES
+INSERT INTO `sys_objects_favorite` (`name`, `table_track`, `is_on`, `is_undo`, `is_public`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_snipcart', 'bx_snipcart_favorites_track', '1', '1', '1', 'page.php?i=view-snipcart-entry&id={object_id}', 'bx_snipcart_entries', 'id', 'author', 'favorites', '', '');
+
+
+-- FEATURED
+INSERT INTO `sys_objects_feature` (`name`, `is_on`, `is_undo`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_flag`, `class_name`, `class_file`) VALUES 
+('bx_snipcart', '1', '1', 'page.php?i=view-snipcart-entry&id={object_id}', 'bx_snipcart_entries', 'id', 'author', 'featured', '', '');
+
+
+-- CONTENT INFO
+INSERT INTO `sys_objects_content_info` (`name`, `title`, `alert_unit`, `alert_action_add`, `alert_action_update`, `alert_action_delete`, `class_name`, `class_file`) VALUES
+('bx_snipcart', '_bx_snipcart', 'bx_snipcart', 'added', 'edited', 'deleted', '', ''),
+('bx_snipcart_cmts', '_bx_snipcart_cmts', 'bx_snipcart', 'commentPost', 'commentUpdated', 'commentRemoved', 'BxDolContentInfoCmts', '');
+
+INSERT INTO `sys_content_info_grids` (`object`, `grid_object`, `grid_field_id`, `condition`, `selection`) VALUES
+('bx_snipcart', 'bx_snipcart_administration', 'id', '', ''),
+('bx_snipcart', 'bx_snipcart_common', 'id', '', '');
+
+
+-- SEARCH EXTENDED
+INSERT INTO `sys_objects_search_extended` (`object`, `object_content_info`, `module`, `title`, `active`, `class_name`, `class_file`) VALUES
+('bx_snipcart', 'bx_snipcart', 'bx_snipcart', '_bx_snipcart_search_extended', 1, '', ''),
+('bx_snipcart_cmts', 'bx_snipcart_cmts', 'bx_snipcart', '_bx_snipcart_search_extended_cmts', 1, 'BxTemplSearchExtendedCmts', '');
+
+
+-- STUDIO: page & widget
+INSERT INTO `sys_std_pages`(`index`, `name`, `header`, `caption`, `icon`) VALUES
+(3, 'bx_snipcart', '_bx_snipcart', '_bx_snipcart', 'bx_snipcart@modules/boonex/snipcart/|std-icon.svg');
+SET @iPageId = LAST_INSERT_ID();
+
+SET @iParentPageId = (SELECT `id` FROM `sys_std_pages` WHERE `name` = 'home');
+SET @iParentPageOrder = (SELECT MAX(`order`) FROM `sys_std_pages_widgets` WHERE `page_id` = @iParentPageId);
+INSERT INTO `sys_std_widgets` (`page_id`, `module`, `url`, `click`, `icon`, `caption`, `cnt_notices`, `cnt_actions`) VALUES
+(@iPageId, 'bx_snipcart', '{url_studio}module.php?name=bx_snipcart', '', 'bx_snipcart@modules/boonex/snipcart/|std-icon.svg', '_bx_snipcart', '', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_actions";s:6:"params";a:0:{}s:5:"class";s:18:"TemplStudioModules";}');
+INSERT INTO `sys_std_pages_widgets` (`page_id`, `widget_id`, `order`) VALUES
+(@iParentPageId, LAST_INSERT_ID(), IF(ISNULL(@iParentPageOrder), 1, @iParentPageOrder + 1));

+ 68 - 0
modules/boonex/snipcart/updates/9.0.6_10.0.0/source/install/sql/uninstall.sql

@@ -0,0 +1,68 @@
+
+-- TABLES
+DROP TABLE IF EXISTS `bx_snipcart_entries`, `bx_snipcart_settings`, `bx_snipcart_files`, `bx_snipcart_photos_resized`, `bx_snipcart_cmts`, `bx_snipcart_votes`, `bx_snipcart_votes_track`, `bx_snipcart_reactions`, `bx_snipcart_reactions_track`, `bx_snipcart_views_track`, `bx_snipcart_meta_keywords`, `bx_snipcart_meta_locations`, `bx_snipcart_meta_mentions`, `bx_snipcart_reports`, `bx_snipcart_reports_track`, `bx_snipcart_favorites_track`, `bx_snipcart_scores`, `bx_snipcart_scores_track`;
+
+
+-- STORAGES & TRANSCODERS
+DELETE FROM `sys_objects_storage` WHERE `object` = 'bx_snipcart_files' OR `object` = 'bx_snipcart_photos_resized';
+DELETE FROM `sys_storage_tokens` WHERE `object` = 'bx_snipcart_files' OR `object` = 'bx_snipcart_photos_resized';
+
+DELETE FROM `sys_objects_transcoder` WHERE `object` IN('bx_snipcart_preview', 'bx_snipcart_gallery', 'bx_snipcart_cover');
+DELETE FROM `sys_transcoder_filters` WHERE `transcoder_object` IN('bx_snipcart_preview', 'bx_snipcart_gallery', 'bx_snipcart_cover');
+DELETE FROM `sys_transcoder_images_files` WHERE `transcoder_object` IN('bx_snipcart_preview', 'bx_snipcart_gallery', 'bx_snipcart_cover');
+
+
+-- FORMS
+DELETE FROM `sys_objects_form` WHERE `module` = 'bx_snipcart';
+DELETE FROM `sys_form_displays` WHERE `module` = 'bx_snipcart';
+DELETE FROM `sys_form_inputs` WHERE `module` = 'bx_snipcart';
+DELETE FROM `sys_form_display_inputs` WHERE `display_name` IN ('bx_snipcart_entry_add', 'bx_snipcart_entry_edit', 'bx_snipcart_entry_view', 'bx_snipcart_entry_view_full', 'bx_snipcart_entry_delete', 'bx_snipcart_settings_edit');
+
+
+-- PRE-VALUES
+DELETE FROM `sys_form_pre_lists` WHERE `module` = 'bx_snipcart';
+DELETE FROM `sys_form_pre_values` WHERE `Key` IN('bx_snipcart_cats', 'bx_snipcart_modes', 'bx_snipcart_currencies');
+
+
+-- COMMENTS
+DELETE FROM `sys_objects_cmts` WHERE `Name` = 'bx_snipcart';
+
+
+-- VOTES
+DELETE FROM `sys_objects_vote` WHERE `Name` IN ('bx_snipcart', 'bx_snipcart_reactions');
+
+
+-- SCORES
+DELETE FROM `sys_objects_score` WHERE `name` = 'bx_snipcart';
+
+
+-- REPORTS
+DELETE FROM `sys_objects_report` WHERE `name` = 'bx_snipcart';
+
+
+-- VIEWS
+DELETE FROM `sys_objects_view` WHERE `name` = 'bx_snipcart';
+
+
+-- FAFORITES
+DELETE FROM `sys_objects_favorite` WHERE `name` = 'bx_snipcart';
+
+
+-- FEATURED
+DELETE FROM `sys_objects_feature` WHERE `name` = 'bx_snipcart';
+
+
+-- CONTENT INFO
+DELETE FROM `sys_objects_content_info` WHERE `name` IN ('bx_snipcart', 'bx_snipcart_cmts');
+
+DELETE FROM `sys_content_info_grids` WHERE `object` IN ('bx_snipcart');
+
+
+-- SEARCH EXTENDED
+DELETE FROM `sys_objects_search_extended` WHERE `module` = 'bx_snipcart';
+
+
+-- STUDIO: page & widget
+DELETE FROM `tp`, `tw`, `tpw`
+USING `sys_std_pages` AS `tp`, `sys_std_widgets` AS `tw`, `sys_std_pages_widgets` AS `tpw`
+WHERE `tp`.`id` = `tw`.`page_id` AND `tw`.`id` = `tpw`.`widget_id` AND `tp`.`name` = 'bx_snipcart';

+ 217 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesConfig.php

@@ -0,0 +1,217 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+class BxSpacesConfig extends BxBaseModProfileConfig
+{
+    function __construct($aModule)
+    {
+        parent::__construct($aModule);
+
+        $aMenuItems2Methods = array (
+            'view-space-profile' => 'checkAllowedView',
+            'edit-space-profile' => 'checkAllowedEdit',
+            'edit-space-cover' => 'checkAllowedChangeCover',
+            'invite-to-space' => 'checkAllowedInvite',
+            'delete-space-profile' => 'checkAllowedDelete',
+            'profile-fan-add' => 'checkAllowedFanAdd',
+            'profile-fan-remove' => 'checkAllowedFanRemove',
+            'profile-subscribe-add' => 'checkAllowedSubscribeAdd',
+            'profile-subscribe-remove' => 'checkAllowedSubscribeRemove',
+            'profile-actions-more' => 'checkAllowedViewMoreMenu',
+            'convos-compose' => 'checkAllowedCompose',
+        );
+
+        $this->CNF = array (
+
+            // module icon
+            'ICON' => 'object-group col-red2',
+
+            // database tables
+            'TABLE_ENTRIES' => $aModule['db_prefix'] . 'data',
+            'TABLE_ENTRIES_FULLTEXT' => 'search_fields',
+            'TABLE_ADMINS' => $aModule['db_prefix'] . 'admins',
+
+            // database fields
+            'FIELD_ID' => 'id',
+            'FIELD_AUTHOR' => 'author',
+            'FIELD_ADDED' => 'added',
+            'FIELD_CHANGED' => 'changed',
+            'FIELD_NAME' => 'space_name',
+            'FIELD_PARENT' => 'parent_space',
+            'FIELD_LEVEL' => 'level',
+            'FIELD_TITLE' => 'space_name',
+            'FIELD_TEXT' => 'space_desc',
+            'FIELD_PICTURE' => 'picture',
+            'FIELD_COVER' => 'cover',
+            'FIELD_JOIN_CONFIRMATION' => 'join_confirmation',
+            'FIELD_ALLOW_VIEW_TO' => 'allow_view_to',
+            'FIELD_ALLOW_POST_TO' => 'allow_post_to',
+            'FIELD_VIEWS' => 'views',
+            'FIELD_COMMENTS' => 'comments',
+            'FIELDS_QUICK_SEARCH' => array('space_name'),
+            'FIELD_LOCATION_PREFIX' => 'location',
+            'FIELDS_WITH_KEYWORDS' => 'auto', // can be 'auto', array of fields or comma separated string of field names, works only when OBJECT_METATAGS is specified
+            'FIELD_LABELS' => 'labels',
+
+            // page URIs
+            'URI_VIEW_ENTRY' => 'view-space-profile',
+            'URI_EDIT_ENTRY' => 'edit-space-profile',
+            'URI_EDIT_COVER' => 'edit-space-cover',
+            'URI_JOINED_ENTRIES' => 'joined-spaces',
+            'URI_MANAGE_COMMON' => 'spaces-manage',
+
+            'URL_HOME' => 'page.php?i=spaces-home',
+            'URL_ENTRY_FANS' => 'page.php?i=space-fans',
+            'URL_MANAGE_COMMON' => 'page.php?i=spaces-manage',
+            'URL_MANAGE_ADMINISTRATION' => 'page.php?i=spaces-administration',
+
+            'PARAM_MULTILEVEL_HIERARCHY' => 'bx_spaces_enable_multilevel_hierarchy',
+            'PARAM_NUM_RSS' => 'bx_spaces_num_rss',
+            'PARAM_NUM_CONNECTIONS_QUICK' => 'bx_spaces_num_connections_quick',
+            'PARAM_SEARCHABLE_FIELDS' => 'bx_spaces_searchable_fields',
+            'PARAM_PER_PAGE_BROWSE_SHOWCASE' => 'bx_spaces_per_page_browse_showcase',
+            'PARAM_PER_PAGE_BROWSE_RECOMMENDED' => 'bx_spaces_per_page_browse_recommended',
+
+            // objects
+            'OBJECT_STORAGE' => 'bx_spaces_pics',
+            'OBJECT_STORAGE_COVER' => 'bx_spaces_pics',
+            'OBJECT_IMAGES_TRANSCODER_THUMB' => 'bx_spaces_thumb',
+            'OBJECT_IMAGES_TRANSCODER_ICON' => 'bx_spaces_icon',
+            'OBJECT_IMAGES_TRANSCODER_AVATAR' => 'bx_spaces_avatar',
+            'OBJECT_IMAGES_TRANSCODER_AVATAR_BIG' => 'bx_spaces_avatar_big',
+            'OBJECT_IMAGES_TRANSCODER_PICTURE' => 'bx_spaces_picture',
+            'OBJECT_IMAGES_TRANSCODER_COVER' => 'bx_spaces_cover',
+            'OBJECT_IMAGES_TRANSCODER_COVER_THUMB' => 'bx_spaces_cover_thumb',
+            'OBJECT_IMAGES_TRANSCODER_GALLERY' => 'bx_spaces_gallery',
+            'OBJECT_VIEWS' => 'bx_spaces',
+            'OBJECT_VOTES' => 'bx_spaces',
+            'OBJECT_SCORES' => 'bx_spaces',
+            'OBJECT_FAVORITES' => 'bx_spaces',
+            'OBJECT_FEATURED' => 'bx_spaces',
+            'OBJECT_COMMENTS' => 'bx_spaces',
+            'OBJECT_REPORTS' => 'bx_spaces',
+            'OBJECT_METATAGS' => 'bx_spaces',
+            'OBJECT_FORM_ENTRY' => 'bx_space',
+            'OBJECT_FORM_ENTRY_DISPLAY_VIEW' => 'bx_space_view',
+            'OBJECT_FORM_ENTRY_DISPLAY_VIEW_FULL' => 'bx_space_view_full', // for "info" tab on view space page
+            'OBJECT_FORM_ENTRY_DISPLAY_ADD' => 'bx_space_add',
+            'OBJECT_FORM_ENTRY_DISPLAY_EDIT' => 'bx_space_edit',
+            'OBJECT_FORM_ENTRY_DISPLAY_EDIT_COVER' => 'bx_space_edit_cover',
+            'OBJECT_FORM_ENTRY_DISPLAY_DELETE' => 'bx_space_delete',
+            'OBJECT_FORM_ENTRY_DISPLAY_INVITE' => 'bx_space_invite',
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY' => 'bx_spaces_view_actions', // actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY_MORE' => 'bx_spaces_view_actions_more', // actions menu on view entry page for "more" popup
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY_ALL' => 'bx_spaces_view_actions_all', // all actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_MY_ENTRIES' => 'bx_spaces_my', // actions menu on profile entries page
+            'OBJECT_MENU_SUBMENU' => 'bx_spaces_submenu', // main module submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY' => 'bx_spaces_view_submenu',  // view entry submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY_COVER' => 'bx_spaces_view_submenu_cover',  // view entry submenu displayed in cover
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY_MAIN_SELECTION' => 'spaces-home', // first item in view entry submenu from main module submenu
+            'OBJECT_MENU_SNIPPET_META' => 'bx_spaces_snippet_meta', // menu for snippet meta info
+            'OBJECT_MENU_MANAGE_TOOLS' => 'bx_spaces_menu_manage_tools', //manage menu in content administration tools
+            'OBJECT_PAGE_VIEW_ENTRY' => 'bx_spaces_view_profile',
+            'OBJECT_PAGE_VIEW_ENTRY_CLOSED' => 'bx_spaces_view_profile_closed',
+            'OBJECT_PRIVACY_VIEW' => 'bx_spaces_allow_view_to',
+            'OBJECT_PRIVACY_VIEW_NOTIFICATION_EVENT' => 'bx_spaces_allow_view_notification_to',
+            'OBJECT_PRIVACY_POST' => 'bx_spaces_allow_post_to',
+            'OBJECT_GRID_ADMINISTRATION' => 'bx_spaces_administration',
+            'OBJECT_GRID_COMMON' => 'bx_spaces_common',
+            'OBJECT_GRID_CONNECTIONS' => 'bx_spaces_fans',
+            'OBJECT_CONNECTIONS' => 'bx_spaces_fans',
+            'OBJECT_UPLOADERS_COVER' => array('bx_spaces_cover_crop'),
+            'OBJECT_UPLOADERS_PICTURE' => array('bx_spaces_picture_crop'),
+
+            'EMAIL_INVITATION' => 'bx_spaces_invitation',
+            'EMAIL_JOIN_REQUEST' => 'bx_spaces_join_request',
+            'EMAIL_JOIN_CONFIRM' => 'bx_spaces_join_confirm',
+            'EMAIL_FAN_BECOME_ADMIN' => 'bx_spaces_fan_become_admin',
+            'EMAIL_ADMIN_BECOME_FAN' => 'bx_spaces_admin_become_fan',
+            'EMAIL_FAN_REMOVE' => 'bx_spaces_fan_remove',
+            'EMAIL_JOIN_REJECT' => 'bx_spaces_join_reject',
+
+            'TRIGGER_MENU_PROFILE_VIEW_SUBMENU' => 'trigger_group_view_submenu',
+            'TRIGGER_MENU_PROFILE_SNIPPET_META' => 'trigger_group_snippet_meta',
+            'TRIGGER_MENU_PROFILE_VIEW_ACTIONS' => 'trigger_group_view_actions',
+            'TRIGGER_PAGE_VIEW_ENTRY' => 'trigger_page_group_view_entry',
+
+            // menu items which visibility depends on custom visibility checking
+            'MENU_ITEM_TO_METHOD' => array (
+                'bx_spaces_view_actions' => $aMenuItems2Methods,
+                'bx_spaces_view_actions_more' => $aMenuItems2Methods,
+                'bx_spaces_view_actions_all' => $aMenuItems2Methods,
+            ),
+
+            // informer messages
+            'INFORMERS' => array (
+                'status' => array (
+                    'name' => 'bx-spaces-status-not-active',
+                    'map' => array (
+                        BX_PROFILE_STATUS_PENDING => '_bx_spaces_txt_account_pending',
+                        BX_PROFILE_STATUS_SUSPENDED => '_bx_spaces_txt_account_suspended',
+                    ),
+                ),
+            ),
+
+            // some language keys
+            'T' => array (
+                'txt_sample_single' => '_bx_spaces_txt_sample_single',
+                'txt_sample_single_with_article' => '_bx_spaces_txt_sample_single_with_article',
+                'txt_sample_comment_single' => '_bx_spaces_txt_sample_comment_single',
+                'txt_sample_vote_single' => '_bx_spaces_txt_sample_vote_single',
+                'txt_sample_score_up_single' => '_bx_spaces_txt_sample_score_up_single',
+                'txt_sample_score_down_single' => '_bx_spaces_txt_sample_score_down_single',
+                'txt_private_group' => '_bx_spaces_txt_private_space',
+                'txt_N_fans' => '_bx_spaces_txt_N_fans',
+                'txt_ntfs_join_request' => '_bx_spaces_txt_ntfs_join_request',
+                'txt_ntfs_fan_added' => '_bx_spaces_txt_ntfs_fan_added',
+                'txt_ntfs_timeline_post_common' => '_bx_spaces_txt_ntfs_timeline_post_common',
+                'form_field_author' => '_bx_spaces_form_entry_input_author',
+                'menu_item_title_befriend_sent' => '_bx_spaces_menu_item_title_befriend_sent',
+                'menu_item_title_unfriend_cancel_request' => '_bx_spaces_menu_item_title_unfriend_cancel_request',
+                'menu_item_title_befriend_confirm' => '_bx_spaces_menu_item_title_befriend_confirm',
+                'menu_item_title_unfriend_reject_request' => '_bx_spaces_menu_item_title_unfriend_reject_request',
+                'menu_item_title_befriend' => '_bx_spaces_menu_item_title_befriend',
+                'menu_item_title_unfriend' => '_bx_spaces_menu_item_title_unfriend',
+                'grid_action_err_delete' => '_bx_spaces_grid_action_err_delete',
+                'grid_txt_account_manager' => '_bx_spaces_grid_txt_account_manager',
+                'filter_item_active' => '_bx_spaces_grid_filter_item_title_adm_active',
+                'filter_item_pending' => '_bx_spaces_grid_filter_item_title_adm_pending',
+                'filter_item_suspended' => '_bx_spaces_grid_filter_item_title_adm_suspended',
+                'filter_item_select_one_filter1' => '_bx_spaces_grid_filter_item_title_adm_select_one_filter1',
+                'menu_item_manage_my' => '_bx_spaces_menu_item_title_manage_my',
+                'menu_item_manage_all' => '_bx_spaces_menu_item_title_manage_all',
+                'menu_item_title_become_fan_sent' => '_bx_spaces_menu_item_title_become_fan_sent',
+                'menu_item_title_leave_group_cancel_request' => '_bx_spaces_menu_item_title_leave_space_cancel_request',
+                'menu_item_title_become_fan' => '_bx_spaces_menu_item_title_become_fan',
+                'menu_item_title_leave_group' => '_bx_spaces_menu_item_title_leave_space',
+                'txt_all_entries_by_author' => '_bx_spaces_page_title_browse_by_author'
+            ),
+
+        );
+
+        $this->_aJsClasses = array(
+            'manage_tools' => 'BxSpacesManageTools'
+        );
+
+        $this->_aJsObjects = array(
+            'manage_tools' => 'oBxSpacesManageTools'
+        );
+
+        $this->_aGridObjects = array(
+            'common' => $this->CNF['OBJECT_GRID_COMMON'],
+            'administration' => $this->CNF['OBJECT_GRID_ADMINISTRATION'],
+            
+        );
+    }
+
+}
+
+/** @} */

+ 25 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesMenuView.php

@@ -0,0 +1,25 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * 'View space' menu.
+ */
+class BxSpacesMenuView extends BxBaseModGroupsMenuView
+{
+    public function __construct($aObject, $oTemplate = false)
+    {
+        $this->_sModule = 'bx_spaces';
+
+        parent::__construct($aObject, $oTemplate);
+    }
+}
+
+/** @} */

+ 24 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesMenuViewActions.php

@@ -0,0 +1,24 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * 'View space' actions menu.
+ */
+class BxSpacesMenuViewActions extends BxBaseModGroupsMenuViewActions
+{
+    public function __construct($aObject, $oTemplate = false)
+    {
+        $this->MODULE = 'bx_spaces';
+        parent::__construct($aObject, $oTemplate);
+    }
+}
+
+/** @} */

+ 97 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesModule.php

@@ -0,0 +1,97 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * Spaces profiles module.
+ */
+define('BX_SPS_LEVELS_LIMIT', 1);
+
+class BxSpacesModule extends BxBaseModGroupsModule
+{
+    function __construct(&$aModule)
+    {
+        parent::__construct($aModule);
+       
+        $this->_aSearchableNamesExcept[] = $this->_oConfig->CNF['FIELD_JOIN_CONFIRMATION'];
+    }
+    
+    public function serviceEntityDelete ($iContentId = 0)
+    {
+        $iContentId = $this->_getContent($iContentId, false);
+        if($iContentId === false)
+            return false;
+        $iCount = $this->_oDb->getCountEntriesByParent($iContentId);
+        if ($iCount > 0)
+            return MsgBox(_t('_bx_spaces_err_delete_child_presend'));
+        return $this->_serviceEntityForm ('deleteDataForm', $iContentId);
+    }
+    
+    public function serviceEntityParent ($iContentId = 0)
+    {
+        return $this->_serviceTemplateFunc ('entryParent', $iContentId);
+    }
+    
+    public function serviceEntityChilds ($iContentId = 0)
+    {
+        return $this->_serviceTemplateFunc ('entryChilds', $iContentId);
+    }
+    
+    public function serviceBrowseTopLevel ($bDisplayEmptyMsg = false)
+    {
+        return $this->_serviceBrowse ('top_level', false, BX_DB_PADDING_DEF, $bDisplayEmptyMsg);
+    }
+    
+    /**
+     * Get possible recipients for start conversation form
+     */
+    public function actionAjaxGetParentSpace ()
+    {
+        $sTerm = bx_get('term');
+        $iContentId = bx_get('id');
+        $a = $this->getListSpacesForParent($sTerm, $iContentId, 10);
+        header('Content-Type:text/javascript; charset=utf-8');
+        echo(json_encode($a));
+    }
+
+    public function checkAllowedSubscribeAdd (&$aDataEntry, $isPerformAction = false)
+    {
+        return parent::_checkAllowedSubscribeAdd ($aDataEntry, $isPerformAction);
+    }
+    
+    public function getListSpacesForParent ($sTerm, $iContentId, $iLimit)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        if (!isLogged())
+            return false;
+
+        $iLevelsLimit = BX_SPS_LEVELS_LIMIT;
+        if(getParam($CNF['PARAM_MULTILEVEL_HIERARCHY']) == 'on')
+            $iLevelsLimit = 0;
+
+        $aRv = array();
+        $aTmp = $this->_oDb->searchByTermForParentSpace(bx_get_logged_profile_id(), $iContentId, $iLevelsLimit, $sTerm, $iLimit);
+        foreach ($aTmp as $aSpace) {
+            $oProfile = BxDolProfile::getInstance($aSpace['profile_id']);
+
+            $aRv[] = array (
+                'label' => $this->serviceProfileName($aSpace['content_id']),
+                'value' => $aSpace['profile_id'],
+                'url' => $oProfile->getUrl(),
+                'thumb' => $oProfile->getThumb(),
+                'unit' => $oProfile->getUnit(0, array('template' => 'unit_wo_info'))
+            );
+        }
+        return $aRv;
+    }
+}
+
+/** @} */

+ 22 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesPrivacyPost.php

@@ -0,0 +1,22 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+class BxSpacesPrivacyPost extends BxBaseModGroupsPrivacyPost
+{
+    public function __construct($aOptions, $oTemplate = false)
+    {
+        $this->_sModule = 'bx_spaces';
+
+        parent::__construct($aOptions, $oTemplate);
+    }
+}
+
+/** @} */

+ 55 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/classes/BxSpacesTemplate.php

@@ -0,0 +1,55 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+/*
+ * Spaces module representation.
+ */
+class BxSpacesTemplate extends BxBaseModGroupsTemplate
+{
+    function __construct(&$oConfig, &$oDb)
+    {
+        $this->MODULE = 'bx_spaces';
+        parent::__construct($oConfig, $oDb);
+    }
+    
+    public function entryChilds($aData)
+    {
+        $CNF = $this->_oConfig->CNF;
+        $aChild = $this->_oModule->_oDb->getChildEntriesIdByProfileId($aData[$CNF['FIELD_ID']]);
+        
+        if (count($aChild) == 0)
+            return false;
+
+        return $this->parseHtmlByName('entry-childs.html', array('content' => $this->getBrowseQuick($aChild)));
+    }
+    
+    public function entryParent($aData)
+    {
+        $CNF = $this->_oConfig->CNF;
+        if ($aData[$CNF['FIELD_PARENT']] == 0)
+            return false;
+        return $this->parseHtmlByName('entry-parent.html', array('content' => $this->getBrowseQuick(array($aData[$CNF['FIELD_PARENT']]))));
+    }
+    
+    private function getBrowseQuick($aProfiles)
+    {
+        $sRv = '';
+        foreach ($aProfiles as $iProfileId) {
+            $oProfile = BxDolProfile::getInstance($iProfileId);
+            if(!$oProfile)
+                continue;
+            $sRv .= $oProfile->getUnit(false, array('template' => 'unit_wo_cover'));
+        }
+        return $sRv;
+    }
+}
+
+/** @} */

+ 152 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/config.php

@@ -0,0 +1,152 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defdroup    Spaces Spaces
+ * @indroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_spaces',
+    'title' => 'Spaces',
+    'note' => 'Spaces functionality.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+    'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/spaces/',
+    'home_uri' => 'spaces',
+
+    'db_prefix' => 'bx_spaces_',
+    'class_prefix' => 'BxSpaces',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Spaces',
+
+    /**
+     * Connections.
+     */
+    'connections' => array(
+        'sys_profiles_friends' => array ('type' => 'profiles'),
+        'sys_profiles_subscriptions' => array ('type' => 'profiles'),
+    ),
+
+    /**
+     * Menu triggers.
+     */
+    'menu_triggers' => array(
+        'trigger_profile_view_submenu',
+        'trigger_group_view_submenu',
+        'trigger_group_snippet_meta',
+        'trigger_group_view_actions',
+    ),
+
+    /**
+     * Page triggers.
+     */
+    'page_triggers' => array (
+        'trigger_page_group_view_entry',
+    ),
+
+    /**
+     * Storage objects to automatically delete files from upon module uninstallation.
+     * Note. Don't add storage objects used in transcoder objects.
+     */
+    'storages' => array(
+        'bx_spaces_pics'
+    ),
+
+    /**
+     * Transcoders.
+     */
+    'transcoders' => array(
+        'bx_spaces_icon',
+        'bx_spaces_thumb',
+        'bx_spaces_avatar',
+        'bx_spaces_avatar_big',
+        'bx_spaces_picture',
+        'bx_spaces_cover',
+        'bx_spaces_cover_thumb',
+        'bx_spaces_gallery'
+    ),
+
+    /**
+     * Extended Search Forms.
+     */
+    'esearches' => array(
+        'bx_spaces',
+        'bx_spaces_cmts',
+    ),
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'uninstall' => array (
+        'process_esearches' => 1,
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'process_connections' => 1,
+        'process_deleted_profiles' => 1,
+        'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+        'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable_success' => array(
+        'process_menu_triggers' => 1,
+        'process_page_triggers' => 1,
+        'process_esearches' => 1,
+        'register_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+        'unregister_transcoders' => 1,
+        'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable_failed' => array (
+        'register_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+
+    /**
+     * Connections Section
+     */
+    'relations' => array(
+        'bx_timeline',
+        'bx_notifications',
+    ),
+);
+
+/** @} */

+ 323 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,323 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+	<string name="_bx_spaces"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_cmts"><![CDATA[Spaces' Comments]]></string>
+
+        <string name="_bx_spaces_option_enable_multilevel_hierarchy"><![CDATA[Allow multilevel hierarchy (experimental)]]></string>
+	<string name="_bx_spaces_option_num_connections_quick"><![CDATA[Number of items in friends block]]></string>
+	<string name="_bx_spaces_option_per_page_browse"><![CDATA[Number of items per page]]></string>
+	<string name="_bx_spaces_option_num_rss"><![CDATA[Number of items in RSS feed]]></string>
+	<string name="_bx_spaces_option_searchable_fields"><![CDATA[Searchable fields]]></string>
+
+	<string name="_bx_spaces_form_profile"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_form_profile_display_add"><![CDATA[Add Space]]></string>
+	<string name="_bx_spaces_form_profile_display_edit"><![CDATA[Edit Space]]></string>
+	<string name="_bx_spaces_form_profile_display_edit_cover"><![CDATA[Edit Cover]]></string>
+	<string name="_bx_spaces_form_profile_display_delete"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_form_profile_display_view"><![CDATA[View Space]]></string>
+	<string name="_bx_spaces_form_profile_display_view_full"><![CDATA[Full View Space]]></string>
+	<string name="_bx_spaces_form_profile_display_invite"><![CDATA[Invite to Space]]></string>
+	<string name="_bx_spaces_form_entry_input_author"><![CDATA[Author]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_join_confirm"><![CDATA[Join confirmation]]></string>
+	<string name="_bx_spaces_form_profile_input_join_confirm"><![CDATA[Join confirmation]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_allow_view_to"><![CDATA[Visible to]]></string>
+	<string name="_bx_spaces_form_profile_input_allow_view_to"><![CDATA[Visible to]]></string>
+	<string name="_bx_spaces_form_profile_input_allow_view_to_desc"><![CDATA[Closed - anyone can find the space and see who's in it, only members can see posts. Secret - only members can find the space and see posts.]]></string>
+        <string name="_bx_spaces_form_profile_input_sys_allow_post_to"><![CDATA[Who can post]]></string>
+        <string name="_bx_spaces_form_profile_input_allow_post_to"><![CDATA[Who can post]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_initial_members"><![CDATA[Invite Members]]></string>
+	<string name="_bx_spaces_form_profile_input_initial_members"><![CDATA[Invite Members]]></string>
+  <string name="_bx_spaces_form_profile_input_sys_parent_space"><![CDATA[Parent Space]]></string>
+  <string name="_bx_spaces_form_profile_input_parent_space"><![CDATA[Parent Space]]></string>
+  <string name="_bx_spaces_form_profile_input_sys_space_name"><![CDATA[Space Name]]></string>
+	<string name="_bx_spaces_form_profile_input_space_name"><![CDATA[Space Name]]></string>
+	<string name="_bx_spaces_form_profile_input_space_name_err"><![CDATA[This information is essential. Please, fill in this field.]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_space_desc"><![CDATA[Description]]></string>
+	<string name="_bx_spaces_form_profile_input_space_desc"><![CDATA[Description]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_space_cat"><![CDATA[Category]]></string>
+	<string name="_bx_spaces_form_profile_input_space_cat"><![CDATA[Category]]></string>
+	<string name="_bx_spaces_form_profile_input_space_cat_err"><![CDATA[Category field is mandatory]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_picture"><![CDATA[Space Picture]]></string>
+	<string name="_bx_spaces_form_profile_input_picture"><![CDATA[Upload New Space Picture]]></string>
+	<string name="_bx_spaces_form_profile_input_picture_err"><![CDATA[Space picture is mandatory.]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_cover"><![CDATA[Cover Picture]]></string>
+	<string name="_bx_spaces_form_profile_input_cover"><![CDATA[Upload New Cover Picture]]></string>
+	<string name="_bx_spaces_form_profile_input_sys_delete_confirm"><![CDATA[Delete confirmation]]></string>
+	<string name="_bx_spaces_form_profile_input_delete_confirm"><![CDATA[I am sure I want to delete this space]]></string>
+	<string name="_bx_spaces_form_profile_input_delete_confirm_info"><![CDATA[This action can not be undone.]]></string>
+	<string name="_bx_spaces_form_profile_input_delete_confirm_error"><![CDATA[Please check this checkbox if you really want to delete space.]]></string>
+	
+	<string name="_bx_spaces_acl_action_create_profile"><![CDATA[Create Space]]></string>
+	<string name="_bx_spaces_acl_action_delete_profile"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_acl_action_view_profile"><![CDATA[View Space]]></string>
+	<string name="_bx_spaces_acl_action_edit_any_profile"><![CDATA[Edit Any Space]]></string>
+	
+	<string name="_bx_spaces_page_title_sys_joined_entries"><![CDATA[Profile Spaces]]></string>
+	<string name="_bx_spaces_page_title_joined_entries"><![CDATA[Profile Spaces]]></string>
+	<string name="_bx_spaces_page_title_sys_create_profile"><![CDATA[Create Space]]></string>
+	<string name="_bx_spaces_page_title_create_profile"><![CDATA[Create Space]]></string>
+	<string name="_bx_spaces_page_title_sys_edit_profile"><![CDATA[Edit Space]]></string>
+	<string name="_bx_spaces_page_title_edit_profile"><![CDATA[Edit Space]]></string>
+	<string name="_bx_spaces_page_title_sys_edit_profile_cover"><![CDATA[Edit Space Cover]]></string>
+	<string name="_bx_spaces_page_title_edit_profile_cover"><![CDATA[Edit Cover]]></string>
+	<string name="_bx_spaces_page_title_sys_delete_profile"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_page_title_delete_profile"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_page_title_sys_view_profile_closed"><![CDATA[View Closed Space]]></string>
+	<string name="_bx_spaces_page_title_sys_view_profile"><![CDATA[View Space]]></string>
+	<string name="_bx_spaces_page_title_view_profile"><![CDATA[{display_name}]]></string>
+	<string name="_bx_spaces_page_title_browse"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_page_title_browse_by_author"><![CDATA[Spaces of {display_name}]]></string>
+	<string name="_bx_spaces_page_title_browse_featured"><![CDATA[Featured Spaces]]></string>
+	<string name="_bx_spaces_page_title_browse_top"><![CDATA[Top Spaces]]></string>
+	<string name="_bx_spaces_page_title_browse_recent"><![CDATA[New Spaces]]></string>
+	<string name="_bx_spaces_page_title_browse_connections"><![CDATA[{0} connections]]></string>
+	<string name="_bx_spaces_page_title_browse_connections_mutual"><![CDATA[{0} and {1} mutual connections]]></string>
+	<string name="_bx_spaces_page_title_sys_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_page_title_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_page_title_sys_space_fans"><![CDATA[Members]]></string>
+	<string name="_bx_spaces_page_title_space_fans"><![CDATA[Members]]></string>
+	<string name="_bx_spaces_page_title_sys_profile_comments"><![CDATA[Comments]]></string>
+	<string name="_bx_spaces_page_title_profile_comments"><![CDATA[Comments]]></string>
+	<string name="_bx_spaces_page_title_sys_profile_info"><![CDATA[Space Info]]></string>
+	<string name="_bx_spaces_page_title_profile_info"><![CDATA[Info about {display_name}]]></string>
+	<string name="_bx_spaces_page_title_sys_recent"><![CDATA[New Spaces]]></string>
+	<string name="_bx_spaces_page_title_recent"><![CDATA[New Spaces]]></string>
+	<string name="_bx_spaces_page_title_sys_manage"><![CDATA[Manage Own Spaces]]></string>
+	<string name="_bx_spaces_page_title_sys_manage_administration"><![CDATA[Manage All Spaces]]></string>
+	<string name="_bx_spaces_page_title_manage"><![CDATA[Manage Spaces]]></string>
+	<string name="_bx_spaces_page_title_sys_top"><![CDATA[Top Spaces]]></string>
+	<string name="_bx_spaces_page_title_top"><![CDATA[Top Spaces]]></string>
+	<string name="_bx_spaces_page_title_sys_invite_to_space"><![CDATA[Invite Members to the Space]]></string>
+	<string name="_bx_spaces_page_title_invite_to_space"><![CDATA[Invite Members to the Space]]></string>
+	<string name="_bx_spaces_page_title_sys_entries_search"><![CDATA[Search]]></string>
+	<string name="_bx_spaces_page_title_entries_search"><![CDATA[Search]]></string>
+	
+	<string name="_bx_spaces_page_block_title_sys_entries_actions"><![CDATA[Spaces actions]]></string>
+	<string name="_bx_spaces_page_block_title_entries_actions"><![CDATA[Spaces actions]]></string>
+	<string name="_bx_spaces_page_block_title_sys_entries_of_author"><![CDATA[Spaces of author]]></string>
+	<string name="_bx_spaces_page_block_title_entries_of_author"><![CDATA[Spaces by {display_name}]]></string>
+	<string name="_bx_spaces_page_block_title_favorites_of_author"><![CDATA[Favorite Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_sys_favorites_of_author"><![CDATA[Favorite Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_sys_joined_entries"><![CDATA[Joined Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_joined_entries"><![CDATA[Joined Spaces]]></string>
+  <string name="_bx_spaces_page_block_title_parent"><![CDATA[Parent Space]]></string>
+  <string name="_bx_spaces_page_block_title_childs"><![CDATA[Child Spaces]]></string>
+  <string name="_bx_spaces_page_block_title_create_profile"><![CDATA[Create Space]]></string>
+	<string name="_bx_spaces_page_block_title_edit_profile"><![CDATA[Edit Space]]></string>
+	<string name="_bx_spaces_page_block_title_edit_profile_cover"><![CDATA[Edit Cover]]></string>
+	<string name="_bx_spaces_page_block_title_delete_profile"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_page_block_title_profile_info_link"><![CDATA[About <a href="{profile_link}">{display_name}</a>]]></string>
+	<string name="_bx_spaces_page_block_title_profile_info"><![CDATA[Info]]></string>
+	<string name="_bx_spaces_page_block_title_system_profile_info"><![CDATA[Info]]></string>
+	<string name="_bx_spaces_page_block_title_profile_description"><![CDATA[Description]]></string>
+	<string name="_bx_spaces_page_block_title_profile_friends_link"><![CDATA[Friends of <a href="{profile_link}">{display_name}</a>]]></string>
+	<string name="_bx_spaces_page_block_title_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_page_block_title_system_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_page_block_title_admins"><![CDATA[Administrators]]></string>
+	<string name="_bx_spaces_page_block_title_fans_link"><![CDATA[Members of <a href="{profile_link}">{display_name}</a>]]></string>
+	<string name="_bx_spaces_page_block_title_fans"><![CDATA[Members]]></string>
+	<string name="_bx_spaces_page_block_title_system_fans"><![CDATA[Members]]></string>
+        <string name="_bx_spaces_page_block_title_profile_location"><![CDATA[Location]]></string>
+	<string name="_bx_spaces_page_block_title_profile_comments"><![CDATA[Comments]]></string>
+	<string name="_bx_spaces_page_block_title_profile_comments_link"><![CDATA[Comments to <a href="{entry_link}">{title}</a>]]></string>
+	<string name="_bx_spaces_page_block_title_profile_actions"><![CDATA[Actions]]></string>
+	<string name="_bx_spaces_page_block_title_featured_profiles"><![CDATA[Featured Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_latest_profiles"><![CDATA[New Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_system_manage"><![CDATA[Manage Own Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_system_manage_administration"><![CDATA[Manage All Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_manage"><![CDATA[Manage Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_top_profiles"><![CDATA[Top Spaces]]></string>
+        <string name="_bx_spaces_page_block_title_entry_all_actions"><![CDATA[All Actions]]></string>
+	<string name="_bx_spaces_page_block_title_entry_social_sharing"><![CDATA[Share]]></string>
+	<string name="_bx_spaces_page_block_title_categories"><![CDATA[Spaces Categories]]></string>
+	<string name="_bx_spaces_page_block_title_invite_to_space"><![CDATA[Invite Members to the Space]]></string>
+	<string name="_bx_spaces_page_block_title_search_form"><![CDATA[Search Form]]></string>
+	<string name="_bx_spaces_page_block_title_search_results"><![CDATA[Search Results]]></string>
+	<string name="_bx_spaces_page_block_title_search_form_cmts"><![CDATA[Comments Search Form]]></string>
+	<string name="_bx_spaces_page_block_title_search_results_cmts"><![CDATA[Comments Search Results]]></string>
+	<string name="_bx_spaces_page_block_title_sys_featured_entries_view_showcase"><![CDATA[Featured Spaces (Showcase View)]]></string>
+	<string name="_bx_spaces_page_block_title_featured_entries_view_showcase"><![CDATA[Featured Spaces]]></string>
+	<string name="_bx_spaces_page_block_title_sys_recommended_entries_view_showcase"><![CDATA[Recommended Spaces (Showcase View)]]></string>
+	<string name="_bx_spaces_page_block_title_recommended_entries_view_showcase"><![CDATA[Recommended Spaces]]></string>
+  <string name="_bx_spaces_page_block_title_top_level_spaces"><![CDATA[Top Level Spaces]]></string>
+
+  <string name="_bx_spaces_menu_title_submenu"><![CDATA[Spaces Submenu]]></string>
+	<string name="_bx_spaces_menu_set_title_submenu"><![CDATA[Spaces Submenu]]></string>
+	<string name="_bx_spaces_menu_set_title_view_profile_actions"><![CDATA[Space Actions]]></string>
+	<string name="_bx_spaces_menu_title_view_profile_actions"><![CDATA[Space Actions]]></string>
+	<string name="_bx_spaces_menu_set_title_view_profile_actions_more"><![CDATA[Space More Actions]]></string>
+	<string name="_bx_spaces_menu_title_view_profile_actions_more"><![CDATA[Space More Actions]]></string>
+	<string name="_bx_spaces_menu_set_title_view_profile_submenu"><![CDATA[View Space Submenu]]></string>
+	<string name="_bx_spaces_menu_title_view_profile_submenu"><![CDATA[View Space Submenu]]></string>
+	<string name="_bx_spaces_menu_title_view_profile_submenu_cover"><![CDATA[Space Cover Submenu]]></string>
+	<string name="_bx_spaces_menu_title_entries_my"><![CDATA[Profile Spaces Action Menu]]></string>
+	<string name="_bx_spaces_menu_set_title_entries_my"><![CDATA[Profile Spaces Menu]]></string>
+	<string name="_bx_spaces_menu_set_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+	<string name="_bx_spaces_menu_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+	<string name="_bx_spaces_menu_item_title_system_delete"><![CDATA[Delete]]></string>
+	<string name="_bx_spaces_menu_item_title_delete"><![CDATA[Delete]]></string>
+	<string name="_bx_spaces_menu_item_title_system_delete_with_content"><![CDATA[Delete With Content]]></string>
+	<string name="_bx_spaces_menu_item_title_delete_with_content"><![CDATA[Delete With Content]]></string>
+	<string name="_bx_spaces_menu_item_title_system_edit_cover"><![CDATA[Edit Cover]]></string>
+	<string name="_bx_spaces_menu_item_title_edit_cover"><![CDATA[Edit Cover]]></string>
+	<string name="_bx_spaces_menu_item_title_system_edit_profile"><![CDATA[Edit Space]]></string>
+	<string name="_bx_spaces_menu_item_title_edit_profile"><![CDATA[Edit Space]]></string>
+	<string name="_bx_spaces_menu_item_title_system_delete_profile"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_menu_item_title_delete_profile"><![CDATA[Delete Space]]></string>
+	<string name="_bx_spaces_menu_item_title_system_delete_account"><![CDATA[Delete Account]]></string>
+	<string name="_bx_spaces_menu_item_title_delete_account"><![CDATA[Delete Account]]></string>
+	<string name="_bx_spaces_menu_item_title_system_profile_type"><![CDATA[Space]]></string>
+	<string name="_bx_spaces_menu_item_title_profile_type"><![CDATA[Space]]></string>
+	<string name="_bx_spaces_menu_item_title_system_create_profile"><![CDATA[Space]]></string>
+	<string name="_bx_spaces_menu_item_title_create_profile"><![CDATA[Space]]></string>
+	<string name="_bx_spaces_menu_item_title_system_view_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_menu_item_title_view_profile_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_menu_item_title_system_view_joined_spaces"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_view_joined_spaces"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_system_view_fans"><![CDATA[Members]]></string>
+	<string name="_bx_spaces_menu_item_title_view_fans"><![CDATA[Members]]></string>
+	<string name="_bx_spaces_menu_item_title_system_view_profile_comments"><![CDATA[Comments]]></string>
+	<string name="_bx_spaces_menu_item_title_view_profile_comments"><![CDATA[Comments]]></string>
+	<string name="_bx_spaces_menu_item_title_system_view_profile_info"><![CDATA[Info]]></string>
+	<string name="_bx_spaces_menu_item_title_view_profile_info"><![CDATA[Info]]></string>
+	<string name="_bx_spaces_menu_item_title_system_view_profile_view"><![CDATA[Space]]></string>
+	<string name="_bx_spaces_menu_item_title_view_profile_view"><![CDATA[Space]]></string>
+        <string name="_bx_spaces_menu_item_title_system_view_profile_more_auto"><![CDATA[More]]></string>
+        <string name="_bx_spaces_menu_item_title_view_profile_more_auto"><![CDATA[More]]></string>
+	<string name="_bx_spaces_menu_item_title_system_invite"><![CDATA[Invite]]></string>
+	<string name="_bx_spaces_menu_item_title_invite"><![CDATA[Invite]]></string>
+	
+	<string name="_bx_spaces_menu_item_title_system_befriend"><![CDATA[Add friend]]></string>
+	<string name="_bx_spaces_menu_item_title_befriend"><![CDATA[Add friend]]></string>
+	<string name="_bx_spaces_menu_item_title_befriend_sent"><![CDATA[Add friend (requested)]]></string>
+	<string name="_bx_spaces_menu_item_title_befriend_confirm"><![CDATA[Accept friend request]]></string>
+	<string name="_bx_spaces_menu_item_title_system_unfriend"><![CDATA[Unfriend]]></string>
+	<string name="_bx_spaces_menu_item_title_unfriend"><![CDATA[Unfriend]]></string>
+	<string name="_bx_spaces_menu_item_title_unfriend_cancel_request"><![CDATA[Cancel friend request]]></string>
+	<string name="_bx_spaces_menu_item_title_unfriend_reject_request"><![CDATA[Reject friend request]]></string>
+	
+	<string name="_bx_spaces_menu_item_title_system_become_fan"><![CDATA[Join Space]]></string>
+	<string name="_bx_spaces_menu_item_title_become_fan"><![CDATA[Join Space]]></string>
+	<string name="_bx_spaces_menu_item_title_become_fan_sent"><![CDATA[Join Space (requested)]]></string>
+	<string name="_bx_spaces_menu_item_title_become_fan_confirm"><![CDATA[Accept Request]]></string>
+	<string name="_bx_spaces_menu_item_title_system_leave_space"><![CDATA[Leave Space]]></string>
+	<string name="_bx_spaces_menu_item_title_leave_space"><![CDATA[Leave Space]]></string>
+	<string name="_bx_spaces_menu_item_title_leave_space_cancel_request"><![CDATA[Cancel Request]]></string>
+	<string name="_bx_spaces_menu_item_title_leave_space_reject_request"><![CDATA[Reject Request]]></string>
+	
+	<string name="_bx_spaces_menu_item_title_system_subscribe"><![CDATA[Follow]]></string>
+	<string name="_bx_spaces_menu_item_title_subscribe"><![CDATA[Follow]]></string>
+	<string name="_bx_spaces_menu_item_title_system_unsubscribe"><![CDATA[Unfollow]]></string>
+	<string name="_bx_spaces_menu_item_title_unsubscribe"><![CDATA[Unfollow]]></string>
+	<string name="_bx_spaces_menu_item_title_system_more_actions"><![CDATA[More Actions]]></string>
+	<string name="_bx_spaces_menu_item_title_more_actions"><![CDATA[]]></string>
+	<string name="_bx_spaces_menu_item_title_system_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_menu_item_title_friends"><![CDATA[Friends]]></string>
+	<string name="_bx_spaces_menu_item_title_system_manage_my_spaces"><![CDATA[My spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_manage_my_spaces"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_system_entries_recent"><![CDATA[New]]></string>
+	<string name="_bx_spaces_menu_item_title_entries_recent"><![CDATA[New]]></string>
+	<string name="_bx_spaces_menu_item_title_system_entries_search"><![CDATA[Search]]></string>
+	<string name="_bx_spaces_menu_item_title_entries_search"><![CDATA[Search]]></string>
+	<string name="_bx_spaces_menu_item_title_system_entries_manage"><![CDATA[Manage]]></string>
+	<string name="_bx_spaces_menu_item_title_entries_manage"><![CDATA[Manage]]></string>
+	<string name="_bx_spaces_menu_item_title_system_entries_home"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_entries_home"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_system_admt_spaces"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_admt_spaces"><![CDATA[Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_manage_my"><![CDATA[My Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_manage_all"><![CDATA[All Spaces]]></string>
+	<string name="_bx_spaces_menu_item_title_system_entries_top"><![CDATA[Top]]></string>
+	<string name="_bx_spaces_menu_item_title_entries_top"><![CDATA[Top]]></string>
+	
+	<string name="_bx_spaces_grid_filter_item_title_adm_select_one_filter1"><![CDATA[All Statuses]]></string>
+	<string name="_bx_spaces_grid_filter_item_title_adm_active"><![CDATA[Active]]></string>
+	<string name="_bx_spaces_grid_filter_item_title_adm_pending"><![CDATA[Pending]]></string>
+	<string name="_bx_spaces_grid_filter_item_title_adm_suspended"><![CDATA[Suspended]]></string>
+	<string name="_bx_spaces_grid_column_title_adm_active"><![CDATA[Active]]></string>
+	<string name="_bx_spaces_grid_column_title_adm_name"><![CDATA[Name]]></string>
+	<string name="_bx_spaces_grid_column_title_adm_added"><![CDATA[Created]]></string>
+	<string name="_bx_spaces_grid_column_title_adm_account"><![CDATA[Account]]></string>
+	<string name="_bx_spaces_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+	<string name="_bx_spaces_grid_action_title_adm_delete_with_content"><![CDATA[Delete With Content]]></string>
+	<string name="_bx_spaces_grid_action_title_adm_more_actions"><![CDATA[More Actions]]></string>
+	<string name="_bx_spaces_grid_action_err_delete"><![CDATA[Cannot delete the selected space(s).]]></string>
+	<string name="_bx_spaces_grid_txt_account_manager"><![CDATA[Redirect to manage account.]]></string>
+	
+	<string name="_bx_spaces_chart_growth"><![CDATA[Spaces: Growth]]></string>
+	<string name="_bx_spaces_chart_growth_speed"><![CDATA[Spaces: Growth Speed]]></string>
+	
+	<string name="_bx_spaces_search_extended"><![CDATA[Spaces Search]]></string>
+	<string name="_bx_spaces_search_extended_cmts"><![CDATA[Spaces Comments Search]]></string>
+
+  <string name="_bx_spaces_err_delete_child_presend"><![CDATA[Cannot delete this space because there are child elements.]]></string>
+	<string name="_bx_spaces_txt_account_pending"><![CDATA[This space is pending approval, please wait until it is activated.]]></string>
+	<string name="_bx_spaces_txt_account_suspended"><![CDATA[This space is suspended.]]></string>
+	<string name="_bx_spaces_txt_N_fans"><![CDATA[{0} members]]></string>
+	<string name="_bx_spaces_txt_sample_single"><![CDATA[space]]></string>
+	<string name="_bx_spaces_txt_sample_single_with_article"><![CDATA[a space]]></string>
+	<string name="_bx_spaces_txt_sample_comment_single"><![CDATA[comment to space]]></string>
+	<string name="_bx_spaces_txt_sample_vote_single"><![CDATA[vote to space]]></string>
+        <string name="_bx_spaces_txt_sample_score_up_single"><![CDATA[score up vote to space]]></string>
+        <string name="_bx_spaces_txt_sample_score_down_single"><![CDATA[score down vote to space]]></string>
+	<string name="_bx_spaces_txt_to_admins"><![CDATA[To Admins]]></string>
+	<string name="_bx_spaces_txt_from_admins"><![CDATA[From Admins]]></string>
+	<string name="_bx_spaces_txt_private_space"><![CDATA[Private space]]></string>
+	
+	<string name="_bx_spaces_alert_action_fan_added"><![CDATA[member joined]]></string>
+	<string name="_bx_spaces_txt_ntfs_fan_added"><![CDATA[Space <b class="bx-ntfs-content-profile">{owner_name}</b> has got a member <b class="bx-ntfs-content-entry">{subentry_sample}</b>]]></string>
+	<string name="_bx_spaces_alert_action_join_request"><![CDATA[join request]]></string>
+	<string name="_bx_spaces_txt_ntfs_join_request"><![CDATA[Space <b class="bx-ntfs-content-profile">{owner_name}</b> has a join request from <b class="bx-ntfs-content-entry">{subentry_sample}</b>]]></string>
+	<string name="_bx_spaces_txt_ntfs_timeline_post_common"><![CDATA[New post <b class="bx-ntfs-content-entry">{subentry_sample}</b> in <b class="bx-ntfs-content-profile">{owner_name}</b> space timeline]]></string>
+	
+	<string name="_bx_spaces_pre_lists_cats"><![CDATA[Space categories]]></string>
+	<string name="_bx_spaces_cat_General"><![CDATA[General]]></string>
+	<string name="_bx_spaces_cat_Business"><![CDATA[Business]]></string>
+	<string name="_bx_spaces_cat_Interests"><![CDATA[Interests]]></string>
+	<string name="_bx_spaces_cat_Causes"><![CDATA[Causes]]></string>
+	<string name="_bx_spaces_cat_Fun"><![CDATA[Fun]]></string>
+	<string name="_bx_spaces_cat_Uncategorised"><![CDATA[Uncategorised]]></string>
+	
+	<string name="_bx_spaces_email_join_request"><![CDATA[Space join request]]></string>
+	<string name="_bx_spaces_email_join_request_subject"><![CDATA[Request to join your space]]></string>
+	<string name="_bx_spaces_email_join_request_body"><![CDATA[{email_header}
+	<p>New request to join <a href="{EntryUrl}">{EntryTitle}</a> space from <a href="{NewMemberUrl}">{NewMemberDisplayName}</a></p>
+	{email_footer}]]></string>
+	
+	<string name="_bx_spaces_email_join_reject"><![CDATA[Space join request was rejected]]></string>
+	<string name="_bx_spaces_email_join_reject_subject"><![CDATA[Request to join a space was rejected]]></string>
+	<string name="_bx_spaces_email_join_reject_body"><![CDATA[{email_header}
+	<p>Your request to join <a href="{EntryUrl}">{EntryTitle}</a> space was rejected by space admin.</p>
+	{email_footer}]]></string>
+	
+	<string name="_bx_spaces_email_join_confirm"><![CDATA[Space join request was confirmed]]></string>
+	<string name="_bx_spaces_email_join_confirm_subject"><![CDATA[Your request to join a space was confirmed]]></string>
+	<string name="_bx_spaces_email_join_confirm_body"><![CDATA[{email_header}
+	<p>Your request to join <a href="{EntryUrl}">{EntryTitle}</a> space was confirmed by the space admin.</p>
+	{email_footer}]]></string>
+	
+	<string name="_bx_spaces_email_fan_remove"><![CDATA[Profile was removed from space fans]]></string>
+	<string name="_bx_spaces_email_fan_remove_subject"><![CDATA[Your profile was removed from the space]]></string>
+	<string name="_bx_spaces_email_fan_remove_body"><![CDATA[{email_header}
+	<p>Your profile was removed from <a href="{EntryUrl}">{EntryTitle}</a> space by the space admin.</p>
+	{email_footer}]]></string>
+	
+	<string name="_bx_spaces_email_fan_become_admin"><![CDATA[Space admin status was granted]]></string>
+	<string name="_bx_spaces_email_fan_become_admin_subject"><![CDATA[You are a space admin now]]></string>
+	<string name="_bx_spaces_email_fan_become_admin_body"><![CDATA[{email_header}
+	<p>You are an admin of <a href="{EntryUrl}">{EntryTitle}</a> space now.</p>
+	{email_footer}]]></string>
+	
+	<string name="_bx_spaces_email_admin_become_fan"><![CDATA[Space admin status was revoked]]></string>
+	<string name="_bx_spaces_email_admin_become_fan_subject"><![CDATA[Your space admin status was revoked]]></string>
+	<string name="_bx_spaces_email_admin_become_fan_body"><![CDATA[{email_header}
+	<p>Your admin status was revoked from <a href="{EntryUrl}">{EntryTitle}</a> space.</p>
+	{email_footer}]]></string>
+	
+	<string name="_bx_spaces_email_invitation"><![CDATA[Invitation to space]]></string>
+	<string name="_bx_spaces_email_invitation_subject"><![CDATA[Invitation to "{EntryTitle}" space]]></string>
+	<string name="_bx_spaces_email_invitation_body"><![CDATA[{email_header}
+	<p><a href="{InviterUrl}">{InviterDisplayName}</a> invited you to <a href="{EntryUrl}">{EntryTitle} space</a>.</p>
+	{email_footer}]]></string>
+</resources>

+ 57 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/disable.sql

@@ -0,0 +1,57 @@
+
+-- SETTINGS
+SET @iTypeId = (SELECT `ID` FROM `sys_options_types` WHERE `name` = 'bx_spaces' LIMIT 1);
+SET @iCategId = (SELECT `ID` FROM `sys_options_categories` WHERE `type_id` = @iTypeId LIMIT 1);
+DELETE FROM `sys_options` WHERE `category_id` = @iCategId;
+DELETE FROM `sys_options_categories` WHERE `type_id` = @iTypeId;
+DELETE FROM `sys_options_types` WHERE `id` = @iTypeId;
+
+-- PAGES
+DELETE FROM `sys_objects_page` WHERE `module` = 'bx_spaces';
+DELETE FROM `sys_pages_blocks` WHERE `module` = 'bx_spaces' OR `object` IN('bx_spaces_create_profile', 'bx_spaces_delete_profile', 'bx_spaces_edit_profile', 'bx_spaces_edit_profile_cover', 'bx_spaces_invite', 'bx_spaces_view_profile', 'bx_spaces_view_profile_closed', 'bx_spaces_profile_info', 'bx_spaces_profile_comments', 'bx_spaces_home', 'bx_spaces_fans', 'bx_spaces_joined', 'bx_spaces_top', 'bx_spaces_search', 'bx_spaces_manage', 'bx_spaces_administration');
+
+-- MENU
+DELETE FROM `sys_objects_menu` WHERE `module` = 'bx_spaces';
+DELETE FROM `sys_menu_sets` WHERE `module` = 'bx_spaces';
+DELETE FROM `sys_menu_items` WHERE `module` = 'bx_spaces' OR `set_name` IN('bx_spaces_view_submenu', 'bx_spaces_submenu', 'bx_spaces_view_actions', 'bx_spaces_view_actions_more', 'bx_spaces_view_actions_all', 'bx_spaces_my', 'bx_spaces_snippet_meta', 'bx_spaces_menu_manage_tools');
+
+-- ACL
+DELETE `sys_acl_actions`, `sys_acl_matrix` FROM `sys_acl_actions`, `sys_acl_matrix` WHERE `sys_acl_matrix`.`IDAction` = `sys_acl_actions`.`ID` AND `sys_acl_actions`.`Module` = 'bx_spaces';
+DELETE FROM `sys_acl_actions` WHERE `Module` = 'bx_spaces';
+
+-- METATAGS
+DELETE FROM `sys_objects_metatags` WHERE `object` = 'bx_spaces';
+
+-- CATEGORY
+DELETE FROM `sys_objects_category` WHERE `object` = 'bx_spaces_cats';
+
+-- SEARCH
+DELETE FROM `sys_objects_search` WHERE `ObjectName` = 'bx_spaces';
+
+-- CONNECTIONS
+DELETE FROM `sys_objects_connection` WHERE `object` = 'bx_spaces_fans';
+
+-- STATS
+DELETE FROM `sys_statistics` WHERE `name` LIKE 'bx_spaces%';
+
+-- CHARTS
+DELETE FROM `sys_objects_chart` WHERE `object` LIKE 'bx_spaces%';
+
+-- GRIDS
+DELETE FROM `sys_objects_grid` WHERE `object` IN ('bx_spaces_administration', 'bx_spaces_moderation', 'bx_spaces_common', 'bx_spaces_fans');
+DELETE FROM `sys_grid_fields` WHERE `object` IN ('bx_spaces_administration', 'bx_spaces_moderation', 'bx_spaces_common', 'bx_spaces_fans');
+DELETE FROM `sys_grid_actions` WHERE `object` IN ('bx_spaces_administration', 'bx_spaces_moderation', 'bx_spaces_common', 'bx_spaces_fans');
+
+-- ALERTS
+SET @iHandler := (SELECT `id` FROM `sys_alerts_handlers` WHERE `name` = 'bx_spaces' LIMIT 1);
+DELETE FROM `sys_alerts` WHERE `handler_id` = @iHandler;
+DELETE FROM `sys_alerts_handlers` WHERE `id` = @iHandler;
+
+-- PRIVACY 
+DELETE FROM `sys_objects_privacy` WHERE `object` IN ('bx_spaces_allow_view_to', 'bx_spaces_allow_view_notification_to', 'bx_spaces_allow_post_to');
+
+-- EMAIL TEMPLATES
+DELETE FROM `sys_email_templates` WHERE `Module` = 'bx_spaces';
+
+-- UPLOADERS
+DELETE FROM `sys_objects_uploader` WHERE `object` IN ('bx_spaces_cover_crop', 'bx_spaces_picture_crop');

+ 528 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,528 @@
+
+-- SETTINGS
+
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types`(`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_spaces', '_bx_spaces', 'bx_spaces@modules/boonex/spaces/|std-icon.svg', IF(ISNULL(@iTypeOrder), 1, @iTypeOrder + 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order`)
+VALUES (@iTypeId, 'bx_spaces', '_bx_spaces', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `extra`, `check`, `check_error`, `order`) VALUES
+('bx_spaces_enable_multilevel_hierarchy', '', @iCategId, '_bx_spaces_option_enable_multilevel_hierarchy', 'checkbox', '', '', '', 0),
+('bx_spaces_num_connections_quick', '6', @iCategId, '_bx_spaces_option_num_connections_quick', 'digit', '', '', '', 10),
+('bx_spaces_per_page_browse', '24', @iCategId, '_bx_spaces_option_per_page_browse', 'digit', '', '', '', 11),
+('bx_spaces_num_rss', '10', @iCategId, '_bx_spaces_option_num_rss', 'digit', '', '', '', 12),
+('bx_spaces_per_page_browse_showcase', '32', @iCategId, '_sys_option_per_page_browse_showcase', 'digit', '', '', '', 15),
+('bx_spaces_per_page_browse_recommended', '10', @iCategId, '_sys_option_per_page_browse_recommended', 'digit', '', '', '', 16),
+('bx_spaces_searchable_fields', 'space_name,space_desc', @iCategId, '_bx_spaces_option_searchable_fields', 'list', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:21:"get_searchable_fields";}', '', '', 30);
+
+
+-- PAGES
+
+-- PAGE: create profile
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_create_profile', 'create-space-profile', '_bx_spaces_page_title_sys_create_profile', '_bx_spaces_page_title_create_profile', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=create-space-profile', '', '', '', 0, 1, 0, '', '');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_create_profile', 1, 'bx_spaces', '_bx_spaces_page_block_title_create_profile', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:13:\"entity_create\";}', 0, 1, 1);
+
+-- PAGE: view profile
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_view_profile', 'view-space-profile', '_bx_spaces_page_title_sys_view_profile', '_bx_spaces_page_title_view_profile', 'bx_spaces', 10, 2147483647, 1, 'page.php?i=view-space-profile', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('bx_spaces_view_profile', 1, 'bx_spaces', '', '_bx_spaces_page_block_title_entry_social_sharing', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:21:\"entity_social_sharing\";}', 0, 0, 0, 0),
+('bx_spaces_view_profile', 1, 'bx_spaces', '', '_bx_spaces_page_block_title_entry_all_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:18:"entity_all_actions";}', 0, 0, 0, 0),
+('bx_spaces_view_profile', 2, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_info', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:11:\"entity_info\";}', 0, 0, 1, 0),
+('bx_spaces_view_profile', 2, 'bx_spaces', '', '_bx_spaces_page_block_title_parent', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:13:\"entity_parent\";}', 0, 0, 1, 1),
+('bx_spaces_view_profile', 2, 'bx_spaces', '', '_bx_spaces_page_block_title_childs', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:13:\"entity_childs\";}', 0, 0, 1, 2),
+('bx_spaces_view_profile', 3, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_location', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:15:\"entity_location\";}', 0, 0, 0, 0),
+('bx_spaces_view_profile', 3, 'bx_spaces', '', '_bx_spaces_page_block_title_fans', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:4:\"fans\";}', 0, 0, 1, 0),
+('bx_spaces_view_profile', 3, 'bx_spaces', '', '_bx_spaces_page_block_title_admins', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:6:\"admins\";}', 0, 0, 1, 1),
+('bx_spaces_view_profile', 3, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_location', 3, 2147483647, 'service', 'a:4:{s:6:\"module\";s:6:\"system\";s:6:\"method\";s:13:\"locations_map\";s:6:\"params\";a:2:{i:0;s:9:\"bx_spaces\";i:1;s:12:\"{content_id}\";}s:5:\"class\";s:20:\"TemplServiceMetatags\";}', 0, 0, 1, 2),
+('bx_spaces_view_profile', 4, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_description', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:17:\"entity_text_block\";}', 0, 0, 1, 0),
+('bx_spaces_view_profile', 4, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_comments', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:15:\"entity_comments\";}', 0, 0, 0, 0);
+
+-- PAGE: view closed profile 
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_view_profile_closed', 'view-space-profile-closed', '_bx_spaces_page_title_sys_view_profile_closed', '_bx_spaces_page_title_view_profile', 'bx_spaces', 10, 2147483647, 1, 'page.php?i=view-space-profile', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_spaces_view_profile_closed', 2, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_info', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:11:\"entity_info\";}', 0, 0, 1, 0),
+('bx_spaces_view_profile_closed', 3, 'bx_spaces', '', '_bx_spaces_page_block_title_fans', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:4:\"fans\";}', 0, 0, 1, 0);
+
+-- PAGE: edit profile
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_edit_profile', 'edit-space-profile', '_bx_spaces_page_title_sys_edit_profile', '_bx_spaces_page_title_edit_profile', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=edit-space-profile', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_edit_profile', 1, 'bx_spaces', '_bx_spaces_page_block_title_edit_profile', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:11:\"entity_edit\";}', 0, 0, 0);
+
+-- PAGE: edit profile cover
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_edit_profile_cover', 'edit-space-cover', '_bx_spaces_page_title_sys_edit_profile_cover', '_bx_spaces_page_title_edit_profile_cover', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=edit-space-cover', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_edit_profile_cover', 1, 'bx_spaces', '_bx_spaces_page_block_title_edit_profile_cover', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:17:\"entity_edit_cover\";}', 0, 0, 0);
+
+-- PAGE: invite members
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_invite', 'invite-to-space', '_bx_spaces_page_title_sys_invite_to_space', '_bx_spaces_page_title_invite_to_space', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=invite-to-space', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_invite', 1, 'bx_spaces', '_bx_spaces_page_block_title_invite_to_space', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:13:\"entity_invite\";}', 0, 0, 0);
+
+-- PAGE: delete profile
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_delete_profile', 'delete-space-profile', '_bx_spaces_page_title_sys_delete_profile', '_bx_spaces_page_title_delete_profile', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=delete-space-profile', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_delete_profile', 1, 'bx_spaces', '_bx_spaces_page_block_title_delete_profile', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:13:\"entity_delete\";}', 0, 0, 0);
+
+-- PAGE: profile info
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_profile_info', 'space-profile-info', '_bx_spaces_page_title_sys_profile_info', '_bx_spaces_page_title_profile_info', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=space-profile-info', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_spaces_profile_info', 1, 'bx_spaces', '_bx_spaces_page_block_title_system_profile_info', '_bx_spaces_page_block_title_profile_info_link', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:16:\"entity_info_full\";}', 0, 0, 1, 1),
+('bx_spaces_profile_info', 1, 'bx_spaces', '', '_bx_spaces_page_block_title_profile_description', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:17:\"entity_text_block\";}', 0, 0, 1, 2);
+
+-- PAGE: space fans
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_fans', 'space-fans', '_bx_spaces_page_title_sys_space_fans', '_bx_spaces_page_title_space_fans', 'bx_spaces', 5, 2147483647, 1, 'page.php?i=space-fans', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_spaces_fans', 1, 'bx_spaces', '_bx_spaces_page_block_title_system_fans', '_bx_spaces_page_block_title_fans_link', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:10:"fans_table";}', 0, 0, 1, 1);
+
+-- PAGE: view entry comments
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_profile_comments', '_bx_spaces_page_title_sys_profile_comments', '_bx_spaces_page_title_profile_comments', 'bx_spaces', 5, 2147483647, 1, 'space-profile-comments', '', '', '', '', 0, 1, 0, 'BxSpacesPageEntry', 'modules/boonex/spaces/classes/BxSpacesPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_spaces_profile_comments', 1, 'bx_spaces', '_bx_spaces_page_block_title_profile_comments', '_bx_spaces_page_block_title_profile_comments_link', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:15:\"entity_comments\";}', 0, 0, 0, 1);
+
+-- PAGE: module home
+
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_home', '_bx_spaces_page_title_sys_recent', '_bx_spaces_page_title_recent', 'bx_spaces', 5, 2147483647, 1, 'spaces-home', 'page.php?i=spaces-home', '', '', '', 0, 1, 0, 'BxSpacesPageBrowse', 'modules/boonex/spaces/classes/BxSpacesPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`, `active`) VALUES
+('bx_spaces_home', 1, 'bx_spaces', '_bx_spaces_page_block_title_featured_profiles', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:7:"gallery";}}', 0, 1, 0, 1),
+('bx_spaces_home', 1, 'bx_spaces', '_bx_spaces_page_block_title_latest_profiles', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:22:\"browse_recent_profiles\";s:6:"params";a:1:{i:0;b:1;}}', 0, 1, 1, 1),
+('bx_spaces_home', 1, 'bx_spaces', '_bx_spaces_page_block_title_top_level_spaces', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:16:\"browse_top_level\";s:6:"params";a:1:{i:0;b:1;}}', 0, 1, 2, 0);
+
+-- PAGE: top profiles
+
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_top', '_bx_spaces_page_title_sys_top', '_bx_spaces_page_title_top', 'bx_spaces', 5, 2147483647, 1, 'spaces-top', 'page.php?i=spaces-top', '', '', '', 0, 1, 0, 'BxSpacesPageBrowse', 'modules/boonex/spaces/classes/BxSpacesPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_top', 1, 'bx_spaces', '_bx_spaces_page_block_title_top_profiles', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:19:\"browse_top_profiles\";s:6:"params";a:1:{i:0;b:1;}}', 0, 1, 0);
+
+-- PAGE: search for entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_search', '_bx_spaces_page_title_sys_entries_search', '_bx_spaces_page_title_entries_search', 'bx_spaces', 5, 2147483647, 1, 'spaces-search', 'page.php?i=spaces-search', '', '', '', 0, 1, 0, 'BxSpacesPageBrowse', 'modules/boonex/spaces/classes/BxSpacesPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_spaces_search', 1, 'bx_spaces', '_bx_spaces_page_block_title_search_form', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:9:"bx_spaces";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 1),
+('bx_spaces_search', 1, 'bx_spaces', '_bx_spaces_page_block_title_search_results', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:9:"bx_spaces";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 2),
+('bx_spaces_search', 1, 'bx_spaces', '_bx_spaces_page_block_title_search_form_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:14:"bx_spaces_cmts";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 3),
+('bx_spaces_search', 1, 'bx_spaces', '_bx_spaces_page_block_title_search_results_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:14:"bx_spaces_cmts";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 4);
+
+-- PAGE: module manage own
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_manage', '_bx_spaces_page_title_sys_manage', '_bx_spaces_page_title_manage', 'bx_spaces', 5, 2147483647, 1, 'spaces-manage', 'page.php?i=spaces-manage', '', '', '', 0, 1, 0, 'BxSpacesPageBrowse', 'modules/boonex/spaces/classes/BxSpacesPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_manage', 1, 'bx_spaces', '_bx_spaces_page_block_title_system_manage', '_bx_spaces_page_block_title_manage', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:12:\"manage_tools\";}}', 0, 1, 0);
+
+-- PAGE: module manage all
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_administration', '_bx_spaces_page_title_sys_manage_administration', '_bx_spaces_page_title_manage', 'bx_spaces', 5, 192, 1, 'spaces-administration', 'page.php?i=spaces-administration', '', '', '', 0, 1, 0, 'BxSpacesPageBrowse', 'modules/boonex/spaces/classes/BxSpacesPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_spaces_administration', 1, 'bx_spaces', '_bx_spaces_page_block_title_system_manage_administration', '_bx_spaces_page_block_title_manage', 11, 192, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:12:\"manage_tools\";s:6:\"params\";a:1:{i:0;s:14:\"administration\";}}', 0, 1, 0);
+
+-- PAGE: user's spaces
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_joined', 'joined-spaces', '_bx_spaces_page_title_sys_joined_entries', '_bx_spaces_page_title_joined_entries', 'bx_spaces', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxSpacesPageJoinedEntries', 'modules/boonex/spaces/classes/BxSpacesPageJoinedEntries.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('bx_spaces_joined', 1, 'bx_spaces', '_bx_spaces_page_block_title_sys_entries_actions', '_bx_spaces_page_block_title_entries_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:18:"my_entries_actions";}', 0, 0, 1, 1),
+('bx_spaces_joined', 1, 'bx_spaces', '_bx_spaces_page_block_title_sys_entries_of_author', '_bx_spaces_page_block_title_entries_of_author', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:22:"browse_created_entries";}', 0, 0, 0, 2),
+('bx_spaces_joined', 1, 'bx_spaces', '_bx_spaces_page_block_title_sys_favorites_of_author', '_bx_spaces_page_block_title_favorites_of_author', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:15:"browse_favorite";s:6:"params";a:1:{i:0;s:12:"{profile_id}";}}', 0, 1, 1, 3),
+('bx_spaces_joined', 1, 'bx_spaces', '_bx_spaces_page_block_title_sys_joined_entries', '_bx_spaces_page_block_title_joined_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:21:"browse_joined_entries";s:6:"params";a:2:{i:0;i:0;i:1;b:1;}}', 0, 0, 1, 4);
+
+-- PAGE: add block to homepage
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = 'sys_home' AND `cell_id` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('sys_home', 1, 'bx_spaces', '', '_bx_spaces_page_block_title_latest_profiles', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:22:"browse_recent_profiles";}', 1, 0, 0, IFNULL(@iBlockOrder, 0) + 1),
+('sys_home', 1, 'bx_spaces', '_bx_spaces_page_block_title_sys_recommended_entries_view_showcase', '_bx_spaces_page_block_title_recommended_entries_view_showcase', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:18:"browse_recommended";}', 1, 0, 0, IFNULL(@iBlockOrder, 0) + 2);
+-- PAGE: service blocks
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = '' AND `cell_id` = 0 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('', 0, 'bx_spaces', '', '_bx_spaces_page_block_title_categories', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:15:"categories_list";s:6:"params";a:2:{i:0;s:14:"bx_spaces_cats";i:1;a:2:{s:10:\"show_empty\";b:1;s:21:\"show_empty_categories\";b:1;}}s:5:"class";s:20:"TemplServiceCategory";}', 1, 1, 1, IFNULL(@iBlockOrder, 0) + 1),
+('', 0, 'bx_spaces', '_bx_spaces_page_block_title_sys_featured_entries_view_showcase', '_bx_spaces_page_block_title_featured_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:15:\"browse_featured\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, 1, IFNULL(@iBlockOrder, 0) + 2),
+('', 0, 'bx_spaces', '_bx_spaces_page_block_title_sys_recommended_entries_view_showcase', '_bx_spaces_page_block_title_recommended_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_spaces\";s:6:\"method\";s:18:\"browse_recommended\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, 1, IFNULL(@iBlockOrder, 0) + 3);
+
+-- MENU
+
+-- MENU: add to site menu
+
+SET @iSiteMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_site' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_site', 'bx_spaces', 'spaces-home', '_bx_spaces_menu_item_title_system_entries_home', '_bx_spaces_menu_item_title_entries_home', 'page.php?i=spaces-home', '', '', 'object-group col-red2', 'bx_spaces_submenu', 2147483647, 1, 1, IFNULL(@iSiteMenuOrder, 0) + 1);
+
+-- MENU: add to homepage menu
+
+SET @iHomepageMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_homepage' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_homepage', 'bx_spaces', 'spaces-home', '_bx_spaces_menu_item_title_system_entries_home', '_bx_spaces_menu_item_title_entries_home', 'page.php?i=spaces-home', '', '', 'object-group col-red2', 'bx_spaces_submenu', 2147483647, 1, 1, IFNULL(@iHomepageMenuOrder, 0) + 1);
+
+-- MENU: add to "add content" menu
+
+SET @iAddMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_add_content_links' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_add_content_links', 'bx_spaces', 'create-space-profile', '_bx_spaces_menu_item_title_system_create_profile', '_bx_spaces_menu_item_title_create_profile', 'page.php?i=create-space-profile', '', '', 'object-group col-red2', '', 2147483647, 1, 1, IFNULL(@iAddMenuOrder, 0) + 1);
+
+-- MENU: view actions
+
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_view_actions', '_bx_spaces_menu_title_view_profile_actions', 'bx_spaces_view_actions', 'bx_spaces', 9, 0, 1, 'BxSpacesMenuViewActions', 'modules/boonex/spaces/classes/BxSpacesMenuViewActions.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_view_actions', 'bx_spaces', '_bx_spaces_menu_set_title_view_profile_actions', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
+('bx_spaces_view_actions', 'bx_spaces', 'profile-fan-add', '_bx_spaces_menu_item_title_system_become_fan', '{title_add_fan}', 'javascript:void(0)', 'bx_conn_action(this, \'bx_spaces_fans\', \'add\', \'{profile_id}\')', '', 'sign-in-alt', '', 0, 2147483647, 1, 0, 0, 5),
+('bx_spaces_view_actions', 'bx_spaces', 'profile-subscribe-add', '_bx_spaces_menu_item_title_system_subscribe', '_bx_spaces_menu_item_title_subscribe', 'javascript:void(0)', 'bx_conn_action(this, \'sys_profiles_subscriptions\', \'add\', \'{profile_id}\')', '', 'check', '', 0, 2147483647, 1, 0, 1, 20),
+('bx_spaces_view_actions', 'bx_spaces', 'profile-actions-more', '_bx_spaces_menu_item_title_system_more_actions', '_bx_spaces_menu_item_title_more_actions', 'javascript:void(0)', 'bx_menu_popup(''bx_spaces_view_actions_more'', this, {}, {profile_id:{profile_id}});', '', 'cog', 'bx_spaces_view_actions_more', 1, 2147483647, 1, 0, 1, 9999);
+
+-- MENU: view actions more
+
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_view_actions_more', '_bx_spaces_menu_title_view_profile_actions_more', 'bx_spaces_view_actions_more', 'bx_spaces', 6, 0, 1, 'BxSpacesMenuViewActions', 'modules/boonex/spaces/classes/BxSpacesMenuViewActions.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_view_actions_more', 'bx_spaces', '_bx_spaces_menu_set_title_view_profile_actions_more', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_spaces_view_actions_more', 'bx_spaces', 'profile-fan-remove', '_bx_spaces_menu_item_title_system_leave_space', '{title_remove_fan}', 'javascript:void(0)', 'bx_conn_action(this, \'bx_spaces_fans\', \'remove\', \'{profile_id}\')', '', 'sign-out-alt', '', 2147483647, 1, 0, 10),
+('bx_spaces_view_actions_more', 'bx_spaces', 'profile-subscribe-remove', '_bx_spaces_menu_item_title_system_unsubscribe', '_bx_spaces_menu_item_title_unsubscribe', 'javascript:void(0)', 'bx_conn_action(this, \'sys_profiles_subscriptions\', \'remove\', \'{profile_id}\')', '', 'check', '', 2147483647, 1, 0, 20),
+('bx_spaces_view_actions_more', 'bx_spaces', 'edit-space-cover', '_bx_spaces_menu_item_title_system_edit_cover', '_bx_spaces_menu_item_title_edit_cover', 'page.php?i=edit-space-cover&id={content_id}', '', '', 'edit', '', 2147483647, 1, 0, 30),
+('bx_spaces_view_actions_more', 'bx_spaces', 'edit-space-profile', '_bx_spaces_menu_item_title_system_edit_profile', '_bx_spaces_menu_item_title_edit_profile', 'page.php?i=edit-space-profile&id={content_id}', '', '', 'pencil-alt', '', 2147483647, 1, 0, 40),
+('bx_spaces_view_actions_more', 'bx_spaces', 'invite-to-space', '_bx_spaces_menu_item_title_system_invite', '_bx_spaces_menu_item_title_invite', 'page.php?i=invite-to-space&id={content_id}', '', '', 'user-friends', '', 2147483647, 1, 0, 42),
+('bx_spaces_view_actions_more', 'bx_spaces', 'delete-space-profile', '_bx_spaces_menu_item_title_system_delete_profile', '_bx_spaces_menu_item_title_delete_profile', 'page.php?i=delete-space-profile&id={content_id}', '', '', 'remove', '', 2147483647, 1, 0, 50);
+
+-- MENU: all actions menu for view entry 
+
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_view_actions_all', '_sys_menu_title_view_actions', 'bx_spaces_view_actions_all', 'bx_spaces', 15, 0, 1, 'BxSpacesMenuViewActionsAll', 'modules/boonex/spaces/classes/BxSpacesMenuViewActionsAll.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_view_actions_all', 'bx_spaces', '_sys_menu_set_title_view_actions', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_spaces_view_actions_all', 'bx_spaces', 'profile-fan-add', '_bx_spaces_menu_item_title_system_become_fan', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 10),
+('bx_spaces_view_actions_all', 'bx_spaces', 'profile-fan-remove', '_bx_spaces_menu_item_title_system_leave_group', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 20),
+('bx_spaces_view_actions_all', 'bx_spaces', 'profile-subscribe-add', '_bx_spaces_menu_item_title_system_subscribe', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 30),
+('bx_spaces_view_actions_all', 'bx_spaces', 'profile-subscribe-remove', '_bx_spaces_menu_item_title_system_unsubscribe', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 40),
+('bx_spaces_view_actions_all', 'bx_spaces', 'comment', '_sys_menu_item_title_system_va_comment', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 200),
+('bx_spaces_view_actions_all', 'bx_spaces', 'view', '_sys_menu_item_title_system_va_view', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 210),
+('bx_spaces_view_actions_all', 'bx_spaces', 'vote', '_sys_menu_item_title_system_va_vote', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 220),
+('bx_spaces_view_actions_all', 'bx_spaces', 'score', '_sys_menu_item_title_system_va_score', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 230),
+('bx_spaces_view_actions_all', 'bx_spaces', 'favorite', '_sys_menu_item_title_system_va_favorite', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 240),
+('bx_spaces_view_actions_all', 'bx_spaces', 'feature', '_sys_menu_item_title_system_va_feature', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 250),
+('bx_spaces_view_actions_all', 'bx_spaces', 'repost', '_sys_menu_item_title_system_va_repost', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 260),
+('bx_spaces_view_actions_all', 'bx_spaces', 'report', '_sys_menu_item_title_system_va_report', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 270),
+('bx_spaces_view_actions_all', 'bx_spaces', 'social-sharing-facebook', '_sys_menu_item_title_system_social_sharing_facebook', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 300),
+('bx_spaces_view_actions_all', 'bx_spaces', 'social-sharing-twitter', '_sys_menu_item_title_system_social_sharing_twitter', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 320),
+('bx_spaces_view_actions_all', 'bx_spaces', 'social-sharing-pinterest', '_sys_menu_item_title_system_social_sharing_pinterest', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 330),
+('bx_spaces_view_actions_all', 'bx_spaces', 'edit-space-cover', '_bx_spaces_menu_item_title_system_edit_cover', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 400),
+('bx_spaces_view_actions_all', 'bx_spaces', 'edit-space-profile', '_bx_spaces_menu_item_title_system_edit_profile', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 410),
+('bx_spaces_view_actions_all', 'bx_spaces', 'invite-to-space', '_bx_spaces_menu_item_title_system_invite', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 420),
+('bx_spaces_view_actions_all', 'bx_spaces', 'delete-space-profile', '_bx_spaces_menu_item_title_system_delete_profile', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 430),
+('bx_spaces_view_actions_all', 'bx_spaces', 'more-auto', '_sys_menu_item_title_system_va_more_auto', '_sys_menu_item_title_va_more_auto', 'javascript:void(0)', '', '', 'ellipsis-v', '', '', 0, 2147483647, 1, 0, 9999);
+
+-- MENU: actions menu for my entries
+
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_my', '_bx_spaces_menu_title_entries_my', 'bx_spaces_my', 'bx_spaces', 9, 0, 1, 'BxSpacesMenu', 'modules/boonex/spaces/classes/BxSpacesMenu.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_my', 'bx_spaces', '_bx_spaces_menu_set_title_entries_my', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_spaces_my', 'bx_spaces', 'create-space-profile', '_bx_spaces_menu_item_title_system_create_profile', '_bx_spaces_menu_item_title_create_profile', 'page.php?i=create-space-profile', '', '', 'plus', '', 2147483647, 1, 0, 0);
+
+-- MENU: module sub-menu
+
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_submenu', '_bx_spaces_menu_title_submenu', 'bx_spaces_submenu', 'bx_spaces', 8, 0, 1, '', '');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_submenu', 'bx_spaces', '_bx_spaces_menu_set_title_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_spaces_submenu', 'bx_spaces', 'spaces-home', '_bx_spaces_menu_item_title_system_entries_recent', '_bx_spaces_menu_item_title_entries_recent', 'page.php?i=spaces-home', '', '', '', '', 2147483647, 1, 1, 1),
+('bx_spaces_submenu', 'bx_spaces', 'spaces-top', '_bx_spaces_menu_item_title_system_entries_top', '_bx_spaces_menu_item_title_entries_top', 'page.php?i=spaces-top', '', '', '', '', 2147483647, 1, 1, 2),
+('bx_spaces_submenu', 'bx_spaces', 'spaces-search', '_bx_spaces_menu_item_title_system_entries_search', '_bx_spaces_menu_item_title_entries_search', 'page.php?i=spaces-search', '', '', '', '', 2147483647, 1, 1, 3),
+('bx_spaces_submenu', 'bx_spaces', 'spaces-manage', '_bx_spaces_menu_item_title_system_entries_manage', '_bx_spaces_menu_item_title_entries_manage', 'page.php?i=spaces-manage', '', '', '', '', 2147483646, 1, 1, 4);
+
+-- MENU: view submenu
+
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_view_submenu', '_bx_spaces_menu_title_view_profile_submenu', 'bx_spaces_view_submenu', 'bx_spaces', 8, 0, 1, 'BxSpacesMenuView', 'modules/boonex/spaces/classes/BxSpacesMenuView.php'),
+('bx_spaces_view_submenu_cover', '_bx_spaces_menu_title_view_profile_submenu_cover', 'bx_spaces_view_submenu', 'bx_spaces', 7, 0, 1, 'BxSpacesMenuView', 'modules/boonex/spaces/classes/BxSpacesMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_view_submenu', 'bx_spaces', '_bx_spaces_menu_set_title_view_profile_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_spaces_view_submenu', 'bx_spaces', 'view-space-profile', '_bx_spaces_menu_item_title_system_view_profile_view', '_bx_spaces_menu_item_title_view_profile_view', 'page.php?i=view-space-profile&id={content_id}', '', '', 'object-group col-red2', '', '', 0, 2147483647, 1, 0, 1),
+('bx_spaces_view_submenu', 'bx_spaces', 'space-profile-info', '_bx_spaces_menu_item_title_system_view_profile_info', '_bx_spaces_menu_item_title_view_profile_info', 'page.php?i=space-profile-info&id={content_id}', '', '', 'info-circle col-gray', '', '', 0, 2147483647, 1, 0, 2),
+('bx_spaces_view_submenu', 'bx_spaces', 'space-profile-comments', '_bx_spaces_menu_item_title_system_view_profile_comments', '_bx_spaces_menu_item_title_view_profile_comments', 'page.php?i=space-profile-comments&id={content_id}', '', '', '', '', '', 0, 2147483647, 0, 0, 3),
+('bx_spaces_view_submenu', 'bx_spaces', 'space-fans', '_bx_spaces_menu_item_title_system_view_fans', '_bx_spaces_menu_item_title_view_fans', 'page.php?i=space-fans&profile_id={profile_id}', '', '', 'object-group col-blue3', '', '', 0, 2147483647, 1, 0, 4),
+('bx_spaces_view_submenu', 'bx_spaces', 'more-auto', '_bx_spaces_menu_item_title_system_view_profile_more_auto', '_bx_spaces_menu_item_title_view_profile_more_auto', 'javascript:void(0)', '', '', 'ellipsis-v', '', '', 0, 2147483647, 1, 0, 9999);
+
+-- MENU: custom menu for snippet meta info
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_snippet_meta', '_sys_menu_title_snippet_meta', 'bx_spaces_snippet_meta', 'bx_spaces', 15, 0, 1, 'BxSpacesMenuSnippetMeta', 'modules/boonex/spaces/classes/BxSpacesMenuSnippetMeta.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_snippet_meta', 'bx_spaces', '_sys_menu_set_title_snippet_meta', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES
+('bx_spaces_snippet_meta', 'bx_spaces', 'date', '_sys_menu_item_title_system_sm_date', '_sys_menu_item_title_sm_date', '', '', '', '', '', 2147483647, 0, 0, 1, 1),
+('bx_spaces_snippet_meta', 'bx_spaces', 'tags', '_sys_menu_item_title_system_sm_tags', '_sys_menu_item_title_sm_tags', '', '', '', '', '', 2147483647, 0, 0, 1, 2),
+('bx_spaces_snippet_meta', 'bx_spaces', 'views', '_sys_menu_item_title_system_sm_views', '_sys_menu_item_title_sm_views', '', '', '', '', '', 2147483647, 0, 0, 1, 3),
+('bx_spaces_snippet_meta', 'bx_spaces', 'comments', '_sys_menu_item_title_system_sm_comments', '_sys_menu_item_title_sm_comments', '', '', '', '', '', 2147483647, 0, 0, 1, 4),
+('bx_spaces_snippet_meta', 'bx_spaces', 'members', '_sys_menu_item_title_system_sm_members', '_sys_menu_item_title_sm_members', '', '', '', '', '', 2147483647, 1, 0, 1, 5),
+('bx_spaces_snippet_meta', 'bx_spaces', 'subscribers', '_sys_menu_item_title_system_sm_subscribers', '_sys_menu_item_title_sm_subscribers', '', '', '', '', '', 2147483647, 0, 0, 1, 6),
+('bx_spaces_snippet_meta', 'bx_spaces', 'nl', '_sys_menu_item_title_system_sm_nl', '_sys_menu_item_title_sm_nl', '', '', '', '', '', 2147483647, 1, 0, 1, 7),
+('bx_spaces_snippet_meta', 'bx_spaces', 'join', '_sys_menu_item_title_system_sm_join', '_sys_menu_item_title_sm_join', '', '', '', '', '', 2147483647, 1, 0, 1, 8),
+('bx_spaces_snippet_meta', 'bx_spaces', 'leave', '_sys_menu_item_title_system_sm_leave', '_sys_menu_item_title_sm_leave', '', '', '', '', '', 2147483647, 0, 0, 1, 9),
+('bx_spaces_snippet_meta', 'bx_spaces', 'subscribe', '_sys_menu_item_title_system_sm_subscribe', '_sys_menu_item_title_sm_subscribe', '', '', '', '', '', 2147483647, 0, 0, 1, 10),
+('bx_spaces_snippet_meta', 'bx_spaces', 'unsubscribe', '_sys_menu_item_title_system_sm_unsubscribe', '_sys_menu_item_title_sm_unsubscribe', '', '', '', '', '', 2147483647, 0, 0, 1, 11);
+
+-- MENU: profile stats
+SET @iNotifMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name` = 'sys_profile_stats' AND `active` = 1 LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
+('sys_profile_stats', 'bx_spaces', 'profile-stats-manage-spaces', '_bx_spaces_menu_item_title_system_manage_my_spaces', '_bx_spaces_menu_item_title_manage_my_spaces', 'page.php?i=spaces-manage', '', '_self', 'object-group col-red2', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:41:"get_menu_addon_manage_tools_profile_stats";}', '', 2147483646, 1, 0, @iNotifMenuOrder + 2);
+
+-- MENU: manage tools submenu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_spaces_menu_manage_tools', '_bx_spaces_menu_title_manage_tools', 'bx_spaces_menu_manage_tools', 'bx_spaces', 6, 0, 1, 'BxSpacesMenuManageTools', 'modules/boonex/spaces/classes/BxSpacesMenuManageTools.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_spaces_menu_manage_tools', 'bx_spaces', '_bx_spaces_menu_set_title_manage_tools', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_spaces_menu_manage_tools', 'bx_spaces', 'delete', '_bx_spaces_menu_item_title_system_delete', '_bx_spaces_menu_item_title_delete', 'javascript:void(0)', 'javascript:{js_object}.onClickDelete({content_id});', '_self', 'far trash-alt', '', 2147483647, 1, 0, 1),
+('bx_spaces_menu_manage_tools', 'bx_spaces', 'delete-with-content', '_bx_spaces_menu_item_title_system_delete_with_content', '_bx_spaces_menu_item_title_delete_with_content', 'javascript:void(0)', 'javascript:{js_object}.onClickDeleteWithContent({content_id});', '_self', 'far trash-alt', '', 2147483647, 1, 0, 2);
+
+-- MENU: dashboard manage tools
+SET @iManageMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard_manage_tools' LIMIT 1);
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_account_dashboard_manage_tools', 'bx_spaces', 'spaces-administration', '_bx_spaces_menu_item_title_system_admt_spaces', '_bx_spaces_menu_item_title_admt_spaces', 'page.php?i=spaces-administration', '', '_self', 'object-group', 'a:2:{s:6:"module";s:9:"bx_spaces";s:6:"method";s:27:"get_menu_addon_manage_tools";}', '', 192, 1, 0, @iManageMenuOrder + 1);
+
+-- MENU: add menu item to profiles modules (trigger* menu sets are processed separately upon modules enable/disable)
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('trigger_profile_view_submenu', 'bx_spaces', 'joined-spaces', '_bx_spaces_menu_item_title_system_view_joined_spaces', '_bx_spaces_menu_item_title_view_joined_spaces', 'page.php?i=joined-spaces&profile_id={profile_id}', '', '', 'object-group col-red2', '', 2147483647, 1, 0, 0);
+
+-- ACL
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_spaces', 'create entry', NULL, '_bx_spaces_acl_action_create_profile', '', 1, 1);
+SET @iIdActionProfileCreate = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_spaces', 'delete entry', NULL, '_bx_spaces_acl_action_delete_profile', '', 1, 1);
+SET @iIdActionProfileDelete = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_spaces', 'view entry', NULL, '_bx_spaces_acl_action_view_profile', '', 1, 0);
+SET @iIdActionProfileView = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_spaces', 'edit any entry', NULL, '_bx_spaces_acl_action_edit_any_profile', '', 1, 3);
+SET @iIdActionProfileEditAny = LAST_INSERT_ID();
+
+SET @iUnauthenticated = 1;
+SET @iAccount = 2;
+SET @iStandard = 3;
+SET @iUnconfirmed = 4;
+SET @iPending = 5;
+SET @iSuspended = 6;
+SET @iModerator = 7;
+SET @iAdministrator = 8;
+SET @iPremium = 9;
+
+INSERT INTO `sys_acl_matrix` (`IDLevel`, `IDAction`) VALUES
+
+-- profile create
+(@iAccount, @iIdActionProfileCreate),
+(@iStandard, @iIdActionProfileCreate),
+(@iUnconfirmed, @iIdActionProfileCreate),
+(@iPending, @iIdActionProfileCreate),
+(@iModerator, @iIdActionProfileCreate),
+(@iAdministrator, @iIdActionProfileCreate),
+(@iPremium, @iIdActionProfileCreate),
+
+-- profile delete
+(@iAccount, @iIdActionProfileDelete),
+(@iStandard, @iIdActionProfileDelete),
+(@iUnconfirmed, @iIdActionProfileDelete),
+(@iPending, @iIdActionProfileDelete),
+(@iModerator, @iIdActionProfileDelete),
+(@iAdministrator, @iIdActionProfileDelete),
+(@iPremium, @iIdActionProfileDelete),
+
+-- profile view
+(@iUnauthenticated, @iIdActionProfileView),
+(@iAccount, @iIdActionProfileView),
+(@iStandard, @iIdActionProfileView),
+(@iUnconfirmed, @iIdActionProfileView),
+(@iPending, @iIdActionProfileView),
+(@iModerator, @iIdActionProfileView),
+(@iAdministrator, @iIdActionProfileView),
+(@iPremium, @iIdActionProfileView),
+
+-- any profile edit
+(@iModerator, @iIdActionProfileEditAny),
+(@iAdministrator, @iIdActionProfileEditAny);
+
+-- METATAGS
+INSERT INTO `sys_objects_metatags` (`object`, `table_keywords`, `table_locations`, `table_mentions`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces', 'bx_spaces_meta_keywords', 'bx_spaces_meta_locations', 'bx_spaces_meta_mentions', '', '');
+
+-- CATEGORY
+INSERT INTO `sys_objects_category` (`object`, `search_object`, `form_object`, `list_name`, `table`, `field`, `join`, `where`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces_cats', 'bx_spaces', 'bx_space', 'bx_spaces_cats', 'bx_spaces_data', 'space_cat', 'INNER JOIN `sys_profiles` ON (`sys_profiles`.`content_id` = `bx_spaces_data`.`id` AND `sys_profiles`.`type` = ''bx_spaces'')', 'AND `sys_profiles`.`status` = ''active''', '', '');
+
+-- SEARCH
+SET @iSearchOrder = (SELECT IFNULL(MAX(`Order`), 0) FROM `sys_objects_search`);
+INSERT INTO `sys_objects_search` (`ObjectName`, `Title`, `Order`, `ClassName`, `ClassPath`) VALUES
+('bx_spaces', '_bx_spaces', @iSearchOrder + 1, 'BxSpacesSearchResult', 'modules/boonex/spaces/classes/BxSpacesSearchResult.php');
+
+-- CONNECTIONS
+INSERT INTO `sys_objects_connection` (`object`, `table`, `type`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces_fans', 'bx_spaces_fans', 'mutual', '', '');
+
+-- STATS
+SET @iMaxOrderStats = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_statistics`);
+INSERT INTO `sys_statistics` (`module`, `name`, `title`, `link`, `icon`, `query`, `order`) VALUES 
+('bx_spaces', 'bx_spaces', '_bx_spaces', 'page.php?i=spaces-home', 'object-group col-red2', 'SELECT COUNT(*) FROM `bx_spaces_data` AS `td` LEFT JOIN `sys_profiles` AS `tp` ON `td`.`id` = `tp`.`content_id` AND `tp`.`type`=''bx_spaces'' WHERE 1 AND `tp`.`status`=''active''', @iMaxOrderStats + 1);
+
+-- CHARTS
+SET @iMaxOrderCharts = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_objects_chart`);
+INSERT INTO `sys_objects_chart` (`object`, `title`, `table`, `field_date_ts`, `field_date_dt`, `field_status`, `query`, `active`, `order`, `class_name`, `class_file`) VALUES
+('bx_spaces_growth', '_bx_spaces_chart_growth', 'bx_spaces_data', 'added', '', '', 'SELECT {field_date_formatted} AS `period`, COUNT(*) AS {object} FROM {table} LEFT JOIN `sys_profiles` AS `tp` ON {table}.`id` = `tp`.`content_id` AND `tp`.`type`=''bx_spaces'' WHERE 1 AND `tp`.`status`=''active'' {where_inteval} GROUP BY `period` ORDER BY {table}.{field_date} ASC', 1, @iMaxOrderCharts + 1, 'BxDolChartGrowth', ''),
+('bx_spaces_growth_speed', '_bx_spaces_chart_growth_speed', 'bx_spaces_data', 'added', '', '', 'SELECT {field_date_formatted} AS `period`, COUNT(*) AS {object} FROM {table} LEFT JOIN `sys_profiles` AS `tp` ON {table}.`id` = `tp`.`content_id` AND `tp`.`type`=''bx_spaces'' WHERE 1 AND `tp`.`status`=''active'' {where_inteval} GROUP BY `period` ORDER BY {table}.{field_date} ASC', 1, @iMaxOrderCharts + 2, 'BxDolChartGrowthSpeed', '');
+
+-- GRID: connections
+INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces_fans', 'Sql', 'SELECT `p`.`id`, `c`.`added`, `c`.`mutual` FROM `sys_profiles` AS `p` INNER JOIN `sys_accounts` AS `a` ON (`a`.`id` = `p`.`account_id`) {join_connections}', 'sys_profiles', 'id', 'c`.`added', '', '', 10, NULL, 'start', '', 'name,email', '', 'auto', '', '', 2147483647, 'BxSpacesGridConnections', 'modules/boonex/spaces/classes/BxSpacesGridConnections.php');
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `params`, `order`) VALUES
+('bx_spaces_fans', 'name', '_sys_name', '50%', '', 10),
+('bx_spaces_fans', 'actions', '', '50%', '', 20);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `confirm`, `order`) VALUES
+('bx_spaces_fans', 'single', 'accept', '_sys_accept', '', 0, 10),
+('bx_spaces_fans', 'single', 'to_admins', '_bx_spaces_txt_to_admins', '', 0, 20),
+('bx_spaces_fans', 'single', 'from_admins', '_bx_spaces_txt_from_admins', '', 0, 30),
+('bx_spaces_fans', 'single', 'delete', '', 'remove', 1, 40);
+
+-- GRIDS: administration
+
+INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces_administration', 'Sql', 'SELECT `td`.*, `td`.`space_name` AS `name`, `ta`.`email` AS `account`, `td`.`added` AS `added_ts`, `tp`.`status` AS `status` FROM `bx_spaces_data` AS `td` LEFT JOIN `sys_profiles` AS `tp` ON `td`.`id`=`tp`.`content_id` AND `tp`.`type`=''bx_spaces'' LEFT JOIN `sys_accounts` AS `ta` ON `tp`.`account_id`=`ta`.`id` WHERE 1 ', 'bx_spaces_data', 'id', 'added', 'status', '', 20, NULL, 'start', '', 'space_name', '', 'like', 'reports', '', 192, 'BxSpacesGridAdministration', 'modules/boonex/spaces/classes/BxSpacesGridAdministration.php'),
+('bx_spaces_common', 'Sql', 'SELECT `td`.*, `td`.`space_name` AS `name`, `ta`.`email` AS `account`, `td`.`added` AS `added_ts`, `tp`.`status` AS `status` FROM `bx_spaces_data` AS `td` LEFT JOIN `sys_profiles` AS `tp` ON `td`.`id`=`tp`.`content_id` AND `tp`.`type`=''bx_spaces'' LEFT JOIN `sys_accounts` AS `ta` ON `tp`.`account_id`=`ta`.`id` WHERE 1 ', 'bx_spaces_data', 'id', 'added', 'status', '', 20, NULL, 'start', '', 'space_name', '', 'like', '', '', 2147483647, 'BxSpacesGridCommon', 'modules/boonex/spaces/classes/BxSpacesGridCommon.php');
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
+('bx_spaces_administration', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_spaces_administration', 'switcher', '_bx_spaces_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_spaces_administration', 'reports', '_sys_txt_reports_title', '5%', 0, '', '', 3),
+('bx_spaces_administration', 'name', '_bx_spaces_grid_column_title_adm_name', '25%', 0, '', '', 4),
+('bx_spaces_administration', 'added_ts', '_bx_spaces_grid_column_title_adm_added', '20%', 1, '25', '', 5),
+('bx_spaces_administration', 'account', '_bx_spaces_grid_column_title_adm_account', '20%', 0, '25', '', 6),
+('bx_spaces_administration', 'actions', '', '20%', 0, '', '', 7),
+('bx_spaces_common', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_spaces_common', 'name', '_bx_spaces_grid_column_title_adm_name', '48%', 0, '', '', 2),
+('bx_spaces_common', 'added_ts', '_bx_spaces_grid_column_title_adm_added', '30%', 1, '25', '', 3),
+('bx_spaces_common', 'actions', '', '20%', 0, '', '', 4);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon_only`, `confirm`, `order`) VALUES
+('bx_spaces_administration', 'bulk', 'delete', '_bx_spaces_grid_action_title_adm_delete', '', 0, 1, 2),
+('bx_spaces_administration', 'bulk', 'delete_with_content', '_bx_spaces_grid_action_title_adm_delete_with_content', '', 0, 1, 3),
+('bx_spaces_administration', 'single', 'settings', '_bx_spaces_grid_action_title_adm_more_actions', 'cog', 1, 0, 2),
+('bx_spaces_common', 'bulk', 'delete', '_bx_spaces_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_spaces_common', 'bulk', 'delete_with_content', '_bx_spaces_grid_action_title_adm_delete_with_content', '', 0, 1, 2),
+('bx_spaces_common', 'single', 'settings', '_bx_spaces_grid_action_title_adm_more_actions', 'cog', 1, 0, 1);
+
+
+-- ALERTS
+
+INSERT INTO `sys_alerts_handlers` (`name`, `class`, `file`, `service_call`) VALUES 
+('bx_spaces', 'BxSpacesAlertsResponse', 'modules/boonex/spaces/classes/BxSpacesAlertsResponse.php', '');
+SET @iHandler := LAST_INSERT_ID();
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('system', 'save_setting', @iHandler),
+('bx_timeline', 'post_common', @iHandler),
+('bx_spaces_pics', 'file_deleted', @iHandler),
+('bx_spaces_fans', 'connection_added', @iHandler),
+('bx_spaces_fans', 'connection_removed', @iHandler),
+('profile', 'delete', @iHandler),
+('bx_spaces', 'fan_added', @iHandler),
+('bx_spaces', 'join_invitation', @iHandler),
+('bx_spaces', 'join_request', @iHandler),
+('bx_spaces', 'join_request_accepted', @iHandler),
+('bx_spaces', 'timeline_view', @iHandler),
+('bx_spaces', 'timeline_post', @iHandler),
+('bx_spaces', 'timeline_delete', @iHandler),
+('bx_spaces', 'timeline_comment', @iHandler),
+('bx_spaces', 'timeline_vote', @iHandler),
+('bx_spaces', 'timeline_score', @iHandler),
+('bx_spaces', 'timeline_report', @iHandler),
+('bx_spaces', 'timeline_repost', @iHandler),
+('bx_spaces', 'timeline_pin', @iHandler),
+('bx_spaces', 'timeline_promote', @iHandler);
+
+-- PRIVACY 
+
+INSERT INTO `sys_objects_privacy` (`object`, `module`, `action`, `title`, `default_group`, `spaces`, `table`, `table_field_id`, `table_field_author`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces_allow_view_to', 'bx_spaces', 'view', '_bx_spaces_form_profile_input_allow_view_to', '3', '', 'bx_spaces_data', 'id', 'author', 'BxSpacesPrivacy', 'modules/boonex/spaces/classes/BxSpacesPrivacy.php'),
+('bx_spaces_allow_view_notification_to', 'bx_spaces', 'view_event', '_bx_spaces_form_profile_input_allow_view_notification_to', '3', '', 'bx_notifications_events', 'id', 'object_owner_id', 'BxSpacesPrivacyNotifications', 'modules/boonex/spaces/classes/BxSpacesPrivacyNotifications.php'),
+('bx_spaces_allow_post_to', 'bx_spaces', 'post', '_bx_spaces_form_profile_input_allow_post_to', '3', '', 'bx_spaces_data', 'id', 'author', 'BxSpacesPrivacyPost', 'modules/boonex/spaces/classes/BxSpacesPrivacyPost.php');
+
+-- EMAIL TEMPLATES
+
+INSERT INTO `sys_email_templates` (`Module`, `NameSystem`, `Name`, `Subject`, `Body`) VALUES
+('bx_spaces', '_bx_spaces_email_join_request', 'bx_spaces_join_request', '_bx_spaces_email_join_request_subject', '_bx_spaces_email_join_request_body'),
+('bx_spaces', '_bx_spaces_email_join_reject', 'bx_spaces_join_reject', '_bx_spaces_email_join_reject_subject', '_bx_spaces_email_join_reject_body'),
+('bx_spaces', '_bx_spaces_email_join_confirm', 'bx_spaces_join_confirm', '_bx_spaces_email_join_confirm_subject', '_bx_spaces_email_join_confirm_body'),
+('bx_spaces', '_bx_spaces_email_fan_remove', 'bx_spaces_fan_remove', '_bx_spaces_email_fan_remove_subject', '_bx_spaces_email_fan_remove_body'),
+('bx_spaces', '_bx_spaces_email_fan_become_admin', 'bx_spaces_fan_become_admin', '_bx_spaces_email_fan_become_admin_subject', '_bx_spaces_email_fan_become_admin_body'),
+('bx_spaces', '_bx_spaces_email_admin_become_fan', 'bx_spaces_admin_become_fan', '_bx_spaces_email_admin_become_fan_subject', '_bx_spaces_email_admin_become_fan_body'),
+('bx_spaces', '_bx_spaces_email_invitation', 'bx_spaces_invitation', '_bx_spaces_email_invitation_subject', '_bx_spaces_email_invitation_body');
+
+-- UPLOADERS
+
+INSERT INTO `sys_objects_uploader` (`object`, `active`, `override_class_name`, `override_class_file`) VALUES
+('bx_spaces_cover_crop', 1, 'BxSpacesUploaderCoverCrop', 'modules/boonex/spaces/classes/BxSpacesUploaderCoverCrop.php'),
+('bx_spaces_picture_crop', 1, 'BxSpacesUploaderPictureCrop', 'modules/boonex/spaces/classes/BxSpacesUploaderPictureCrop.php');
+

+ 368 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/install.sql

@@ -0,0 +1,368 @@
+SET @sStorageEngine = (SELECT `value` FROM `sys_options` WHERE `name` = 'sys_storage_default');
+
+-- TABLE: PROFILES
+CREATE TABLE IF NOT EXISTS `bx_spaces_data` (
+  `id` int(10) unsigned NOT NULL AUTO_INCREMENT,
+  `author` int(10) unsigned NOT NULL,
+  `parent_space` int(10) unsigned NOT NULL  default '0',
+  `level` int(10) unsigned NOT NULL  default '0',
+  `added` int(11) NOT NULL,
+  `changed` int(11) NOT NULL,
+  `picture` int(11) NOT NULL,
+  `cover` int(11) NOT NULL,
+  `space_name` varchar(255) NOT NULL,
+  `space_cat` int(11) NOT NULL,
+  `space_desc` text NOT NULL,
+  `views` int(11) NOT NULL default '0',
+  `rate` float NOT NULL default '0',
+  `votes` int(11) NOT NULL default '0',
+  `score` int(11) NOT NULL default '0',
+  `sc_up` int(11) NOT NULL default '0',
+  `sc_down` int(11) NOT NULL default '0',
+  `favorites` int(11) NOT NULL default '0',
+  `comments` int(11) NOT NULL default '0',
+  `reports` int(11) NOT NULL default '0',
+  `featured` int(11) NOT NULL default '0',
+  `join_confirmation` tinyint(4) NOT NULL DEFAULT '1',
+  `allow_view_to` varchar(16) NOT NULL DEFAULT '3',
+  `allow_post_to` varchar(16) NOT NULL DEFAULT '3',
+  PRIMARY KEY (`id`),
+  FULLTEXT KEY `search_fields` (`space_name`, `space_desc`)
+);
+
+-- TABLE: STORAGES & TRANSCODERS
+CREATE TABLE `bx_spaces_pics` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+CREATE TABLE `bx_spaces_pics_resized` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+-- TABLE: comments
+CREATE TABLE IF NOT EXISTS `bx_spaces_cmts` (
+  `cmt_id` int(11) NOT NULL AUTO_INCREMENT,
+  `cmt_parent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_vparent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_object_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_author_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_level` int(11) NOT NULL DEFAULT '0',
+  `cmt_text` text NOT NULL,
+  `cmt_mood` tinyint(4) NOT NULL DEFAULT '0',
+  `cmt_rate` int(11) NOT NULL DEFAULT '0',
+  `cmt_rate_count` int(11) NOT NULL DEFAULT '0',
+  `cmt_time` int(11) unsigned NOT NULL DEFAULT '0',
+  `cmt_replies` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`cmt_id`),
+  KEY `cmt_object_id` (`cmt_object_id`,`cmt_parent_id`),
+  FULLTEXT KEY `search_fields` (`cmt_text`)
+);
+
+-- TABLE: VIEWS
+CREATE TABLE `bx_spaces_views_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `viewer_id` int(11) NOT NULL default '0',
+  `viewer_nip` int(11) unsigned NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`viewer_id`,`viewer_nip`)
+);
+
+-- TABLE: VOTES
+CREATE TABLE IF NOT EXISTS `bx_spaces_votes` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_spaces_votes_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+-- TABLE: REPORTS
+CREATE TABLE IF NOT EXISTS `bx_spaces_reports` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_spaces_reports_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(32) NOT NULL default '',
+  `text` text NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `report` (`object_id`, `author_nip`)
+);
+
+-- TABLE: metas
+CREATE TABLE `bx_spaces_meta_keywords` (
+  `object_id` int(10) unsigned NOT NULL,
+  `keyword` varchar(255) NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `keyword` (`keyword`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_spaces_meta_locations` (
+  `object_id` int(10) unsigned NOT NULL,
+  `lat` double NOT NULL,
+  `lng` double NOT NULL,
+  `country` varchar(2) NOT NULL,
+  `state` varchar(255) NOT NULL,
+  `city` varchar(255) NOT NULL,
+  `zip` varchar(255) NOT NULL,
+  `street` varchar(255) NOT NULL,
+  `street_number` varchar(255) NOT NULL,
+  PRIMARY KEY (`object_id`),
+  KEY `country_state_city` (`country`,`state`(8),`city`(8))
+);
+
+CREATE TABLE `bx_spaces_meta_mentions` (
+  `object_id` int(10) unsigned NOT NULL,
+  `profile_id` int(10) unsigned NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `profile_id` (`profile_id`)
+);
+
+-- TABLE: fans
+CREATE TABLE IF NOT EXISTS `bx_spaces_fans` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `initiator` int(11) NOT NULL,
+  `content` int(11) NOT NULL,
+  `mutual` tinyint(4) NOT NULL,
+  `added` int(10) unsigned NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `initiator` (`initiator`,`content`),
+  KEY `content` (`content`)
+);
+
+-- TABLE: admins
+CREATE TABLE IF NOT EXISTS `bx_spaces_admins` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `group_profile_id` int(10) unsigned NOT NULL,
+  `fan_id` int(10) unsigned NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `admin` (`group_profile_id`,`fan_id`)
+);
+
+-- TABLE: favorites
+CREATE TABLE `bx_spaces_favorites_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`author_id`)
+);
+
+-- TABLE: scores
+CREATE TABLE IF NOT EXISTS `bx_spaces_scores` (
+  `object_id` int(11) NOT NULL default '0',
+  `count_up` int(11) NOT NULL default '0',
+  `count_down` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_spaces_scores_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(8) NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+
+-- STORAGES & TRANSCODERS
+INSERT INTO `sys_objects_storage` (`object`, `engine`, `params`, `token_life`, `cache_control`, `levels`, `table_files`, `ext_mode`, `ext_allow`, `ext_deny`, `quota_size`, `current_size`, `quota_number`, `current_number`, `max_file_size`, `ts`) VALUES
+('bx_spaces_pics', @sStorageEngine, '', 360, 2592000, 3, 'bx_spaces_pics', 'allow-deny', 'jpg,jpeg,jpe,gif,png', '', 0, 0, 0, 0, 0, 0),
+('bx_spaces_pics_resized', @sStorageEngine, '', 360, 2592000, 3, 'bx_spaces_pics_resized', 'allow-deny', 'jpg,jpeg,jpe,gif,png', '', 0, 0, 0, 0, 0, 0);
+
+INSERT INTO `sys_objects_transcoder` (`object`, `storage_object`, `source_type`, `source_params`, `private`, `atime_tracking`, `atime_pruning`, `ts`) VALUES 
+('bx_spaces_icon', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_thumb', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_avatar', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_avatar_big', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_picture', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_cover', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_cover_thumb', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0'),
+('bx_spaces_gallery', 'bx_spaces_pics_resized', 'Storage', 'a:1:{s:6:"object";s:14:"bx_spaces_pics";}', 'no', '1', '2592000', '0');
+
+INSERT INTO `sys_transcoder_filters` (`transcoder_object`, `filter`, `filter_params`, `order`) VALUES 
+('bx_spaces_icon', 'Resize', 'a:3:{s:1:"w";s:2:"30";s:1:"h";s:2:"30";s:13:"square_resize";s:1:"1";}', '0'),
+('bx_spaces_thumb', 'Resize', 'a:3:{s:1:"w";s:2:"50";s:1:"h";s:2:"50";s:13:"square_resize";s:1:"1";}', '0'),
+('bx_spaces_avatar', 'Resize', 'a:3:{s:1:"w";s:3:"100";s:1:"h";s:3:"100";s:13:"square_resize";s:1:"1";}', '0'),
+('bx_spaces_avatar_big', 'Resize', 'a:3:{s:1:"w";s:3:"200";s:1:"h";s:3:"200";s:13:"square_resize";s:1:"1";}', '0'),
+('bx_spaces_picture', 'Resize', 'a:3:{s:1:"w";s:4:"1024";s:1:"h";s:4:"1024";s:13:"square_resize";s:1:"0";}', '0'),
+('bx_spaces_cover', 'Resize', 'a:1:{s:1:"w";s:4:"2000";}', '0'),
+('bx_spaces_cover_thumb', 'Resize', 'a:3:{s:1:"w";s:2:"48";s:1:"h";s:2:"48";s:13:"square_resize";s:1:"1";}', '0'),
+('bx_spaces_gallery', 'Resize', 'a:1:{s:1:"w";s:3:"500";}', '0');
+
+-- FORMS
+INSERT INTO `sys_objects_form`(`object`, `module`, `title`, `action`, `form_attrs`, `table`, `key`, `uri`, `uri_title`, `submit_name`, `params`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_space', 'bx_spaces', '_bx_spaces_form_profile', '', 'a:1:{s:7:\"enctype\";s:19:\"multipart/form-data\";}', 'bx_spaces_data', 'id', '', '', 'do_submit', '', 0, 1, 'BxSpacesFormEntry', 'modules/boonex/spaces/classes/BxSpacesFormEntry.php');
+
+INSERT INTO `sys_form_displays`(`object`, `display_name`, `module`, `view_mode`, `title`) VALUES 
+('bx_space', 'bx_space_add', 'bx_spaces', 0, '_bx_spaces_form_profile_display_add'),
+('bx_space', 'bx_space_delete', 'bx_spaces', 0, '_bx_spaces_form_profile_display_delete'),
+('bx_space', 'bx_space_edit', 'bx_spaces', 0, '_bx_spaces_form_profile_display_edit'),
+('bx_space', 'bx_space_edit_cover', 'bx_spaces', 0, '_bx_spaces_form_profile_display_edit_cover'),
+('bx_space', 'bx_space_view', 'bx_spaces', 1, '_bx_spaces_form_profile_display_view'),
+('bx_space', 'bx_space_view_full', 'bx_spaces', 1, '_bx_spaces_form_profile_display_view_full'),
+('bx_space', 'bx_space_invite', 'bx_spaces', 0, '_bx_spaces_form_profile_display_invite');
+
+INSERT INTO `sys_form_inputs`(`object`, `module`, `name`, `value`, `values`, `checked`, `type`, `caption_system`, `caption`, `info`, `required`, `collapsed`, `html`, `attrs`, `attrs_tr`, `attrs_wrapper`, `checker_func`, `checker_params`, `checker_error`, `db_pass`, `db_params`, `editable`, `deletable`) VALUES 
+('bx_space', 'bx_spaces', 'allow_view_to', 3, '', 0, 'custom', '_bx_spaces_form_profile_input_sys_allow_view_to', '_bx_spaces_form_profile_input_allow_view_to', '_bx_spaces_form_profile_input_allow_view_to_desc', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'allow_post_to', 3, '', 0, 'custom', '_bx_spaces_form_profile_input_sys_allow_post_to', '_bx_spaces_form_profile_input_allow_post_to', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'delete_confirm', 1, '', 0, 'checkbox', '_bx_spaces_form_profile_input_sys_delete_confirm', '_bx_spaces_form_profile_input_delete_confirm', '_bx_spaces_form_profile_input_delete_confirm_info', 1, 0, 0, '', '', '', 'avail', '', '_bx_spaces_form_profile_input_delete_confirm_error', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'do_submit', '_sys_form_account_input_submit', '', 0, 'submit', '_bx_spaces_form_profile_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'space_desc', '', '', 0, 'textarea', '_bx_spaces_form_profile_input_sys_space_desc', '_bx_spaces_form_profile_input_space_desc', '', 0, 0, 2, '', '', '', '', '', '', 'XssHtml', '', 1, 1),
+('bx_space', 'bx_spaces', 'space_cat', '', '#!bx_spaces_cats', 0, 'select', '_bx_spaces_form_profile_input_sys_space_cat', '_bx_spaces_form_profile_input_space_cat', '', 1, 0, 0, '', '', '', 'avail', '', '_bx_spaces_form_profile_input_space_cat_err', 'Xss', '', 1, 1),
+('bx_space', 'bx_spaces', 'space_name', '', '', 0, 'text', '_bx_spaces_form_profile_input_sys_space_name', '_bx_spaces_form_profile_input_space_name', '', 1, 0, 0, '', '', '', 'avail', '', '_bx_spaces_form_profile_input_space_name_err', 'Xss', '', 1, 0),
+('bx_space', 'bx_spaces', 'parent_space', '', '', 0, 'custom', '_bx_spaces_form_profile_input_sys_parent_space', '_bx_spaces_form_profile_input_parent_space', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 1),
+('bx_space', 'bx_spaces', 'initial_members', '', '', 0, 'custom', '_bx_spaces_form_profile_input_sys_initial_members', '_bx_spaces_form_profile_input_initial_members', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 1),
+('bx_space', 'bx_spaces', 'join_confirmation', 1, '', 1, 'switcher', '_bx_spaces_form_profile_input_sys_join_confirm', '_bx_spaces_form_profile_input_join_confirm', '', 0, 0, 0, '', '', '', '', '', '', 'Xss', '', 1, 0),
+('bx_space', 'bx_spaces', 'cover', 'a:1:{i:0;s:20:"bx_spaces_cover_crop";}', 'a:1:{s:20:"bx_spaces_cover_crop";s:24:"_sys_uploader_crop_title";}', 0, 'files', '_bx_spaces_form_profile_input_sys_cover', '_bx_spaces_form_profile_input_cover', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'picture', 'a:1:{i:0;s:22:"bx_spaces_picture_crop";}', 'a:1:{s:22:"bx_spaces_picture_crop";s:24:"_sys_uploader_crop_title";}', 0, 'files', '_bx_spaces_form_profile_input_sys_picture', '_bx_spaces_form_profile_input_picture', '', 0, 0, 0, '', '', '', '', '', '_bx_spaces_form_profile_input_picture_err', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'location', '', '', 0, 'location', '_sys_form_input_sys_location', '_sys_form_input_location', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_space', 'bx_spaces', 'labels', '', '', 0, 'custom', '_sys_form_input_sys_labels', '_sys_form_input_labels', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0);
+
+INSERT INTO `sys_form_display_inputs`(`display_name`, `input_name`, `visible_for_levels`, `active`, `order`) VALUES 
+('bx_space_add', 'initial_members', 2147483647, 1, 1),
+('bx_space_add', 'space_name', 2147483647, 1, 2),
+('bx_space_add', 'parent_space', 2147483647, 1, 3),
+('bx_space_add', 'space_cat', 2147483647, 1, 4),
+('bx_space_add', 'space_desc', 2147483647, 1, 5),
+('bx_space_add', 'location', 2147483647, 1, 6),
+('bx_space_add', 'join_confirmation', 2147483647, 1, 7),
+('bx_space_add', 'allow_view_to', 2147483647, 1, 8),
+('bx_space_add', 'allow_post_to', 2147483647, 1, 9),
+('bx_space_add', 'do_submit', 2147483647, 1, 10),
+
+('bx_space_invite', 'initial_members', 2147483647, 1, 1),
+('bx_space_invite', 'do_submit', 2147483647, 1, 2),
+
+('bx_space_delete', 'delete_confirm', 2147483647, 1, 1),
+('bx_space_delete', 'do_submit', 2147483647, 1, 2),
+
+('bx_space_edit', 'space_name', 2147483647, 1, 1),
+('bx_space_edit', 'parent_space', 2147483647, 1, 2),
+('bx_space_edit', 'space_cat', 2147483647, 1, 3),
+('bx_space_edit', 'space_desc', 2147483647, 1, 4),
+('bx_space_edit', 'location', 2147483647, 1, 5),
+('bx_space_edit', 'join_confirmation', 2147483647, 1, 6),
+('bx_space_edit', 'allow_view_to', 2147483647, 1, 7),
+('bx_space_edit', 'allow_post_to', 2147483647, 1, 8),
+('bx_space_edit', 'do_submit', 2147483647, 1, 9),
+
+('bx_space_edit_cover', 'cover', 2147483647, 1, 1),
+('bx_space_edit_cover', 'do_submit', 2147483647, 1, 2),
+
+('bx_space_view', 'space_name', 2147483647, 1, 1),
+('bx_space_view', 'space_cat', 2147483647, 1, 2),
+
+('bx_space_view_full', 'space_name', 2147483647, 1, 1),
+('bx_space_view_full', 'space_cat', 2147483647, 1, 2),
+('bx_space_view_full', 'space_desc', 2147483647, 1, 3);
+
+-- PRE-VALUES
+INSERT INTO `sys_form_pre_lists`(`key`, `title`, `module`, `use_for_sets`) VALUES
+('bx_spaces_cats', '_bx_spaces_pre_lists_cats', 'bx_spaces', '0');
+
+INSERT INTO `sys_form_pre_values`(`Key`, `Value`, `Order`, `LKey`, `LKey2`) VALUES
+('bx_spaces_cats', '', 0, '_sys_please_select', ''),
+('bx_spaces_cats', '1', 1, '_bx_spaces_cat_General', ''),
+('bx_spaces_cats', '2', 2, '_bx_spaces_cat_Business', ''),
+('bx_spaces_cats', '3', 3, '_bx_spaces_cat_Interests', ''),
+('bx_spaces_cats', '4', 4, '_bx_spaces_cat_Causes', ''),
+('bx_spaces_cats', '5', 5, '_bx_spaces_cat_Fun', ''),
+('bx_spaces_cats', '6', 6, '_bx_spaces_cat_Uncategorised', '');
+
+-- COMMENTS
+INSERT INTO `sys_objects_cmts` (`Name`, `Module`, `Table`, `CharsPostMin`, `CharsPostMax`, `CharsDisplayMax`, `Html`, `PerView`, `PerViewReplies`, `BrowseType`, `IsBrowseSwitch`, `PostFormPosition`, `NumberOfLevels`, `IsDisplaySwitch`, `IsRatable`, `ViewingThreshold`, `IsOn`, `RootStylePrefix`, `BaseUrl`, `ObjectVote`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldTitle`, `TriggerFieldComments`, `ClassName`, `ClassFile`) VALUES
+('bx_spaces', 'bx_spaces', 'bx_spaces_cmts', 1, 5000, 1000, 3, 5, 3, 'tail', 1, 'bottom', 1, 1, 1, -3, 1, 'cmt', 'page.php?i=view-space-profile&id={object_id}', '', 'bx_spaces_data', 'id', 'author', 'space_name', 'comments', '', '');
+
+-- VIEWS
+INSERT INTO `sys_objects_view` (`name`, `table_track`, `period`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_spaces', 'bx_spaces_views_track', '86400', '1', 'bx_spaces_data', 'id', 'author', 'views', '', '');
+
+-- VOTES
+INSERT INTO `sys_objects_vote` (`Name`, `TableMain`, `TableTrack`, `PostTimeout`, `MinValue`, `MaxValue`, `IsUndo`, `IsOn`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldRate`, `TriggerFieldRateCount`, `ClassName`, `ClassFile`) VALUES 
+('bx_spaces', 'bx_spaces_votes', 'bx_spaces_votes_track', '604800', '1', '1', '0', '1', 'bx_spaces_data', 'id', 'author', 'rate', 'votes', '', '');
+
+-- SCORES
+INSERT INTO `sys_objects_score` (`name`, `module`, `table_main`, `table_track`, `post_timeout`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_score`, `trigger_field_cup`, `trigger_field_cdown`, `class_name`, `class_file`) VALUES 
+('bx_spaces', 'bx_spaces', 'bx_spaces_scores', 'bx_spaces_scores_track', '604800', '0', 'bx_spaces_data', 'id', 'author', 'score', 'sc_up', 'sc_down', '', '');
+
+-- REPORTS
+INSERT INTO `sys_objects_report` (`name`, `table_main`, `table_track`, `is_on`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_spaces', 'bx_spaces_reports', 'bx_spaces_reports_track', '1', 'page.php?i=view-space-profile&id={object_id}', 'bx_spaces_data', 'id', 'author', 'reports', '', '');
+
+-- FAFORITES
+INSERT INTO `sys_objects_favorite` (`name`, `table_track`, `is_on`, `is_undo`, `is_public`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_spaces', 'bx_spaces_favorites_track', '1', '1', '1', 'page.php?i=view-space-profile&id={object_id}', 'bx_spaces_data', 'id', 'author', 'favorites', '', '');
+
+-- FEATURED
+INSERT INTO `sys_objects_feature` (`name`, `is_on`, `is_undo`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_flag`, `class_name`, `class_file`) VALUES 
+('bx_spaces', '1', '1', 'page.php?i=view-space-profile&id={object_id}', 'bx_spaces_data', 'id', 'author', 'featured', '', '');
+
+-- CONTENT INFO
+INSERT INTO `sys_objects_content_info` (`name`, `title`, `alert_unit`, `alert_action_add`, `alert_action_update`, `alert_action_delete`, `class_name`, `class_file`) VALUES
+('bx_spaces', '_bx_spaces', 'bx_spaces', 'added', 'edited', 'deleted', '', ''),
+('bx_spaces_cmts', '_bx_spaces_cmts', 'bx_spaces', 'commentPost', 'commentUpdated', 'commentRemoved', 'BxDolContentInfoCmts', '');
+
+INSERT INTO `sys_content_info_grids` (`object`, `grid_object`, `grid_field_id`, `condition`, `selection`) VALUES
+('bx_spaces', 'bx_spaces_administration', 'td`.`id', '', ''),
+('bx_spaces', 'bx_spaces_common', 'td`.`id', '', '');
+
+-- SEARCH EXTENDED
+INSERT INTO `sys_objects_search_extended` (`object`, `object_content_info`, `module`, `title`, `active`, `class_name`, `class_file`) VALUES
+('bx_spaces', 'bx_spaces', 'bx_spaces', '_bx_spaces_search_extended', 1, '', ''),
+('bx_spaces_cmts', 'bx_spaces_cmts', 'bx_spaces', '_bx_spaces_search_extended_cmts', 1, 'BxTemplSearchExtendedCmts', '');
+
+-- STUDIO PAGE & WIDGET
+INSERT INTO `sys_std_pages`(`index`, `name`, `header`, `caption`, `icon`) VALUES
+(3, 'bx_spaces', '_bx_spaces', '_bx_spaces', 'bx_spaces@modules/boonex/spaces/|std-icon.svg');
+SET @iPageId = LAST_INSERT_ID();
+
+SET @iParentPageId = (SELECT `id` FROM `sys_std_pages` WHERE `name` = 'home');
+SET @iParentPageOrder = (SELECT MAX(`order`) FROM `sys_std_pages_widgets` WHERE `page_id` = @iParentPageId);
+INSERT INTO `sys_std_widgets` (`page_id`, `module`, `url`, `click`, `icon`, `caption`, `cnt_notices`, `cnt_actions`) VALUES
+(@iPageId, 'bx_spaces', '{url_studio}module.php?name=bx_spaces', '', 'bx_spaces@modules/boonex/spaces/|std-icon.svg', '_bx_spaces', '', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_actions";s:6:"params";a:0:{}s:5:"class";s:18:"TemplStudioModules";}');
+INSERT INTO `sys_std_pages_widgets` (`page_id`, `widget_id`, `order`) VALUES
+(@iParentPageId, LAST_INSERT_ID(), IF(ISNULL(@iParentPageOrder), 1, @iParentPageOrder + 1));
+

+ 64 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/install/sql/uninstall.sql

@@ -0,0 +1,64 @@
+
+-- TABLES
+
+DROP TABLE IF EXISTS `bx_spaces_data`, `bx_spaces_pics`, `bx_spaces_pics_resized`, `bx_spaces_cmts`, `bx_spaces_views_track`, `bx_spaces_meta_keywords`, `bx_spaces_meta_locations`, `bx_spaces_meta_mentions`, `bx_spaces_fans`, `bx_spaces_admins`, `bx_spaces_votes`, `bx_spaces_votes_track`, `bx_spaces_reports`, `bx_spaces_reports_track`, `bx_spaces_favorites_track`, `bx_spaces_scores`, `bx_spaces_scores_track`;
+
+-- PROFILES
+
+DELETE FROM sys_profiles WHERE `type` = 'bx_spaces';
+
+-- STORAGES & TRANSCODERS
+
+DELETE FROM `sys_objects_storage` WHERE `object` IN('bx_spaces_pics', 'bx_spaces_pics_resized');
+DELETE FROM `sys_storage_tokens` WHERE `object` IN('bx_spaces_pics', 'bx_spaces_pics_resized');
+
+DELETE FROM `sys_objects_transcoder` WHERE `object` IN('bx_spaces_icon', 'bx_spaces_thumb', 'bx_spaces_avatar', 'bx_spaces_avatar_big', 'bx_spaces_picture', 'bx_spaces_cover', 'bx_spaces_cover_thumb', 'bx_spaces_gallery');
+DELETE FROM `sys_transcoder_filters` WHERE `transcoder_object` IN('bx_spaces_icon', 'bx_spaces_thumb', 'bx_spaces_avatar', 'bx_spaces_avatar_big', 'bx_spaces_picture', 'bx_spaces_cover', 'bx_spaces_cover_thumb', 'bx_spaces_gallery');
+DELETE FROM `sys_transcoder_images_files` WHERE `transcoder_object` IN('bx_spaces_icon', 'bx_spaces_thumb', 'bx_spaces_avatar', 'bx_spaces_avatar_big', 'bx_spaces_picture', 'bx_spaces_cover', 'bx_spaces_cover_thumb', 'bx_spaces_gallery');
+
+-- FORMS
+
+DELETE FROM `sys_objects_form` WHERE `module` = 'bx_spaces';
+DELETE FROM `sys_form_displays` WHERE `module` = 'bx_spaces';
+DELETE FROM `sys_form_inputs` WHERE `module` = 'bx_spaces';
+DELETE FROM `sys_form_display_inputs` WHERE `display_name` IN('bx_space_add', 'bx_space_delete', 'bx_space_edit', 'bx_space_edit_cover', 'bx_space_view', 'bx_space_view_full', 'bx_space_invite');
+
+-- PRE-VALUES
+DELETE FROM `sys_form_pre_lists` WHERE `module` = 'bx_spaces';
+
+DELETE FROM `sys_form_pre_values` WHERE `Key` IN('bx_spaces_cats');
+
+-- COMMENTS
+DELETE FROM `sys_objects_cmts` WHERE `Name` = 'bx_spaces';
+
+-- VIEWS
+DELETE FROM `sys_objects_view` WHERE `name` = 'bx_spaces';
+
+-- VOTES
+DELETE FROM `sys_objects_vote` WHERE `Name` = 'bx_spaces';
+
+-- SCORES
+DELETE FROM `sys_objects_score` WHERE `name` = 'bx_spaces';
+
+-- REPORTS
+DELETE FROM `sys_objects_report` WHERE `name` = 'bx_spaces';
+
+-- FAFORITES
+DELETE FROM `sys_objects_favorite` WHERE `name` = 'bx_spaces';
+
+-- FEATURED
+DELETE FROM `sys_objects_feature` WHERE `name` = 'bx_spaces';
+
+-- CONTENT INFO
+DELETE FROM `sys_objects_content_info` WHERE `name` IN ('bx_spaces', 'bx_spaces_cmts');
+
+DELETE FROM `sys_content_info_grids` WHERE `object` IN ('bx_spaces');
+
+-- SEARCH EXTENDED
+DELETE FROM `sys_objects_search_extended` WHERE `module` = 'bx_spaces';
+
+-- STUDIO PAGE & WIDGET
+DELETE FROM `tp`, `tw`, `tpw`
+USING `sys_std_pages` AS `tp`, `sys_std_widgets` AS `tw`, `sys_std_pages_widgets` AS `tpw`
+WHERE `tp`.`id` = `tw`.`page_id` AND `tw`.`id` = `tpw`.`widget_id` AND `tp`.`name` = 'bx_spaces';
+

+ 37 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/template/images/icons/std-icon.svg

@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg width="64px" height="64px" viewBox="0 0 64 64" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+    <!-- Generator: Sketch 55 (78076) - https://sketchapp.com -->
+    <title>spaces</title>
+    <desc>Created with Sketch.</desc>
+    <defs>
+        <path d="M32,64 C46.0222222,64 53.8173667,64 58.9086889,58.9086889 C64,53.8173667 64,46.0222222 64,32 C64,17.9777778 64,10.1826333 58.9086889,5.09131111 C53.8173667,0 46.0222222,0 32,0 C17.9777778,0 10.1826333,0 5.09131111,5.09131111 C0,10.1826333 0,17.9777778 0,32 C0,46.0222222 0,53.8173667 5.09131111,58.9086889 C10.1826333,64 17.9777778,64 32,64 Z" id="path-1"></path>
+        <linearGradient x1="50%" y1="0%" x2="50%" y2="100%" id="linearGradient-3">
+            <stop stop-color="#FDFEFF" offset="0%"></stop>
+            <stop stop-color="#FBFCFD" stop-opacity="0.9" offset="100%"></stop>
+        </linearGradient>
+        <path d="M0.921231238,10.9862533 L18.209578,18.8288342 C18.7142606,19.0581668 19.2849972,19.0581668 19.7896798,18.8288342 L37.0780266,10.9862533 C38.3063349,10.4288786 38.3063349,8.5726947 37.0780266,8.01532001 L19.790422,0.171996874 C19.2886845,-0.0573322913 18.7120577,-0.0573322913 18.2103202,0.171996874 L0.921231238,8.01457784 C-0.307077079,8.57195252 -0.307077079,10.4288786 0.921231238,10.9862533 Z M37.0787688,17.538189 L32.7674437,15.5840378 L20.7708421,21.0219663 C20.2097538,21.2765329 19.6137831,21.4056716 19,21.4056716 C18.3862169,21.4056716 17.7909884,21.2765329 17.2291579,21.0219663 L5.2332985,15.5840378 L0.921231238,17.538189 C-0.307077079,18.0948215 -0.307077079,19.9502632 0.921231238,20.5068957 L18.209578,28.3435392 C18.7142606,28.5721297 19.2849972,28.5721297 19.7896798,28.3435392 L37.0787688,20.5068957 C38.3070771,19.9502632 38.3070771,18.0948215 37.0787688,17.538189 Z M37.0787688,27.0232069 L32.7837716,25.0764775 L20.7708421,30.5218278 C20.2097538,30.7763944 19.6137831,30.9055331 19,30.9055331 C18.3862169,30.9055331 17.7909884,30.7763944 17.2291579,30.5218278 L5.21697054,25.0764775 L0.921231238,27.0232069 C-0.307077079,27.5798394 -0.307077079,29.4352811 0.921231238,29.9919136 L18.209578,37.8285572 C18.7142606,38.0571476 19.2849972,38.0571476 19.7896798,37.8285572 L37.0787688,29.9919136 C38.3070771,29.4352811 38.3070771,27.5798394 37.0787688,27.0232069 Z" id="path-4"></path>
+        <filter x="-5.3%" y="-2.6%" width="110.5%" height="110.5%" filterUnits="objectBoundingBox" id="filter-5">
+            <feOffset dx="0" dy="1" in="SourceAlpha" result="shadowOffsetOuter1"></feOffset>
+            <feGaussianBlur stdDeviation="0.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
+            <feColorMatrix values="0 0 0 0 0   0 0 0 0 0   0 0 0 0 0  0 0 0 0.1 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
+        </filter>
+    </defs>
+    <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
+        <g id="Artboard" transform="translate(-1879.000000, -511.000000)">
+            <g id="spaces" transform="translate(1879.000000, 511.000000)">
+                <mask id="mask-2" fill="white">
+                    <use xlink:href="#path-1"></use>
+                </mask>
+                <use id="Path" fill="#00B356" xlink:href="#path-1"></use>
+                <g id="layer-group" mask="url(#mask-2)" fill-rule="nonzero">
+                    <g transform="translate(14.000000, 13.000000)" id="Shape">
+                        <g>
+                            <use fill="black" fill-opacity="1" filter="url(#filter-5)" xlink:href="#path-4"></use>
+                            <use fill="url(#linearGradient-3)" xlink:href="#path-4"></use>
+                        </g>
+                    </g>
+                </g>
+            </g>
+        </g>
+    </g>
+</svg>

+ 1 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/template/menu_main_submenu.html

@@ -0,0 +1 @@
+<bx_include_base:../modules/base/groups/template/menu_main_submenu.html />

+ 1 - 0
modules/boonex/spaces/updates/9.0.5_10.0.0/source/template/unit_wo_cover.html

@@ -0,0 +1 @@
+<bx_include_base:../modules/base/groups/template/unit_wo_cover.html />

+ 3 - 1
modules/boonex/timeline/updates/9.0.14_10.0.0/install/config.php

@@ -58,6 +58,8 @@ $aConfig = array(
     'delete_files' => array(
         'classes/BxTimelineUploaderSimplePhoto.php',
         'classes/BxTimelineUploaderSimpleVideo.php',
-        'classes/BxTimelineVote.php'
+        'classes/BxTimelineVote.php',
+        'template/menu_buttons_hor.html',
+        'template/uploader_button_simple.html',
     ),
 );

+ 20 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineCmts.php

@@ -0,0 +1,20 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineCmts extends BxTemplCmts
+{
+    function __construct($sSystem, $iId, $iInit = 1)
+    {
+        parent::__construct($sSystem, $iId, $iInit);
+    }
+}
+
+/** @} */

+ 578 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineConfig.php

@@ -0,0 +1,578 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+bx_import('BxDolPrivacy');
+
+class BxTimelineConfig extends BxBaseModNotificationsConfig
+{
+    protected $_aTypeToFormDisplay;
+
+    protected $_bAllowEdit;
+    protected $_bAllowDelete;
+    protected $_bShowAll;
+    protected $_bCountAllViews;
+
+    protected $_bCacheItem;
+    protected $_sCacheItemEngine;
+    protected $_iCacheItemLifetime;
+    protected $_bCacheList;
+
+    protected $_iRssLength;
+    protected $_iLiveUpdateLength;
+    protected $_iCharsDisplayMaxTitle;
+
+    protected $_sVideosAutoplay;
+    protected $_iPreloadComments;
+    protected $_iPreloadCommentsMax;
+
+    protected $_bHot;
+    protected $_iHotInterval;
+
+    protected $_bEditorToolbar;
+    protected $_bUnhideRestored;
+
+    protected $_sStorageObject;
+    protected $_sTranscoderObjectPreview;
+    protected $_sTranscoderObjectView;
+    protected $_aPhotoUploaders;
+    protected $_aVideoUploaders;
+
+    protected $_sMenuItemManage;
+    protected $_sMenuItemActions;
+
+    protected $_aRepostDefaults;
+
+    protected $_iTimelineVisibilityThreshold;
+    protected $_aPregPatterns;
+
+    /**
+     * Constructor
+     */
+    public function __construct($aModule)
+    {
+        parent::__construct($aModule);
+
+        $this->CNF = array (
+            'ICON' => 'far clock col-green1',
+
+            // database tables
+            'TABLE_ENTRIES' => $aModule['db_prefix'] . 'events',
+
+            // database fields
+            'FIELD_ID' => 'id',
+            'FIELD_OWNER_ID' => 'owner_id',
+            'FIELD_OBJECT_ID' => 'object_id', //Note. For 'Direct Timeline Posts' this field contains post's author profile ID.
+            'FIELD_OBJECT_PRIVACY_VIEW' => 'object_privacy_view',
+            'FIELD_ADDED' => 'date',
+            'FIELD_PUBLISHED' => 'published',
+            'FIELD_TITLE' => 'title',
+            'FIELD_TEXT' => 'description',
+            'FIELD_STATUS' => 'status',
+            'FIELD_DATE' => 'date',
+            'FIELD_ANONYMOUS' => 'anonymous',
+            'FIELD_CONTROLS' => 'controls',
+            'FIELD_LOCATION_PREFIX' => 'location',
+            'FIELDS_DELAYED_PROCESSING' => 'video', // can be array of fields or comma separated string of field names
+
+            // page URIs
+            'URI_VIEW_LIST' => 'timeline-view',
+            'URI_VIEW_ENTRY' => 'item',
+
+            'URL_HOME' => 'page.php?i=timeline-view-home',
+
+            // objects
+            'OBJECT_STORAGE' => $this->_sName . '_photos',
+            'OBJECT_STORAGE_VIDEOS' => $this->_sName . '_videos',
+            'OBJECT_IMAGES_TRANSCODER_PREVIEW' => $this->_sName . '_photos_preview',
+            'OBJECT_VIDEOS_TRANSCODERS' => array(
+                'poster' => 'bx_timeline_videos_poster', 
+            	'mp4' => 'bx_timeline_videos_mp4', 
+            	'mp4_hd' => 'bx_timeline_videos_mp4_hd'
+            ),
+            'OBJECT_GRID_ADMINISTRATION' => $this->_sName . '_administration',
+            'OBJECT_MENU_ENTRY_ATTACHMENTS' => $this->_sName . '_menu_post_attachments',
+            'OBJECT_METATAGS' => $this->_sName,
+            'OBJECT_COMMENTS' => $this->_sName,
+            'OBJECT_VIEWS' => $this->_sName,
+            'OBJECT_VOTES' => $this->_sName,
+            'OBJECT_REACTIONS' => $this->_sName . '_reactions',
+            'OBJECT_SCORES' => $this->_sName,
+            'OBJECT_REPORTS' => $this->_sName,
+
+            // some language keys
+            'T' => array (
+                'txt_status_deleted' => '_bx_timeline_txt_status_deleted',
+                'txt_sample_single' => '_bx_timeline_txt_sample',
+                'txt_sample_single_ext' => '_bx_timeline_txt_sample_ext',
+            	'txt_sample_comment_single' => '_bx_timeline_txt_sample_comment_single',
+                'txt_sample_vote_single' => '_bx_timeline_txt_sample_vote_single',
+                'txt_sample_score_up_single' => '_bx_timeline_txt_sample_score_up_single',
+                'txt_sample_score_down_single' => '_bx_timeline_txt_sample_score_down_single',
+                'txt_sample_with_link' => '_bx_timeline_txt_sample_with_link',
+                'txt_sample_with_image' => '_bx_timeline_txt_sample_with_image',
+                'txt_sample_with_video' => '_bx_timeline_txt_sample_with_video',
+                'txt_sample_with_media' => '_bx_timeline_txt_sample_with_media',
+                'grid_action_err_delete' => '_bx_timeline_grid_action_err_delete', 
+                'grid_txt_account_manager' => '_bx_timeline_grid_txt_account_manager',
+            ),
+        );
+
+        $this->_aTypeToFormDisplay = array(
+            BX_BASE_MOD_NTFS_TYPE_OWNER => 'form_display_post_add_profile',
+            BX_BASE_MOD_NTFS_TYPE_PUBLIC => 'form_display_post_add_public',
+            BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS => 'form_display_post_add'
+        );
+
+        $this->_aPrefixes = array(
+            'style' => 'bx-tl',
+            'language' => '_bx_timeline',
+            'option' => 'bx_timeline_',
+            'common_post' => 'timeline_common_',
+            'cache_item' => 'bx_timeline_item_'
+        );
+
+        $this->_aObjects = array_merge($this->_aObjects, array(
+            'comment' => $this->CNF['OBJECT_COMMENTS'],
+            'view' => $this->CNF['OBJECT_VIEWS'],
+            'vote' => $this->CNF['OBJECT_VOTES'],
+            'reaction' => $this->CNF['OBJECT_REACTIONS'],
+            'score' => $this->CNF['OBJECT_SCORES'],
+            'report' => $this->CNF['OBJECT_REPORTS'],
+            'metatags' => $this->_sName,
+
+            'storage_photos' => $this->CNF['OBJECT_STORAGE'],
+            'storage_videos' => $this->CNF['OBJECT_STORAGE_VIDEOS'],
+            'transcoder_photos_preview' => $this->CNF['OBJECT_IMAGES_TRANSCODER_PREVIEW'],
+            'transcoder_photos_view' => $this->_sName . '_photos_view',
+            'transcoder_photos_medium' => $this->_sName . '_photos_medium',
+            'transcoder_photos_big' => $this->_sName . '_photos_big',
+            'transcoder_videos_poster' => $this->CNF['OBJECT_VIDEOS_TRANSCODERS']['poster'],
+            'transcoder_videos_mp4' => $this->CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4'],
+            'transcoder_videos_mp4_hd' => $this->CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4_hd'],
+
+            'page_item_brief' => $this->_sName . '_item_brief',
+
+            'menu_item_manage' => $this->_sName . '_menu_item_manage',
+            'menu_item_actions' => $this->_sName . '_menu_item_actions',
+            'menu_item_meta' => $this->_sName . '_menu_item_meta',
+            'menu_post_attachments' => $this->CNF['OBJECT_MENU_ENTRY_ATTACHMENTS'],
+
+            'form_post' => $this->_sName . '_post',
+            'form_attach_link' => $this->_sName . '_attach_link',
+            'form_display_post_add' => $this->_sName . '_post_add',
+            'form_display_post_add_public' => $this->_sName . '_post_add_public',
+            'form_display_post_add_profile' => $this->_sName . '_post_add_profile',
+            'form_display_post_edit' => $this->_sName . '_post_edit',
+            'form_display_attach_link_add' => $this->_sName . '_attach_link_add'
+        ));
+
+        $this->_aHandlerDescriptor = array('module_name' => '', 'module_method' => '', 'module_class' => '', 'groupable' => '', 'group_by' => '');
+        $this->_sHandlersMethod = 'get_timeline_data';
+
+        $this->_aPhotoUploaders = array($this->_sName . '_simple_photo');
+        $this->_aVideoUploaders = array($this->_sName . '_simple_video');
+
+        $this->_bJsMode = false;
+        $this->_aJsClasses = array(
+            'main' => 'BxTimelineMain',
+            'view' => 'BxTimelineView',
+            'post' => 'BxTimelinePost',
+            'repost' => 'BxTimelineRepost',
+            'manage_tools' => 'BxTimelineManageTools'
+        );
+        $this->_aJsObjects = array(
+            'view' => 'oTimelineView',
+            'post' => 'oTimelinePost',
+            'repost' => 'oTimelineRepost',
+            'manage_tools' => 'oBxTimelineManageTools'
+        );
+
+        $this->_aGridObjects = array(
+            'administration' => $this->CNF['OBJECT_GRID_ADMINISTRATION']
+        );
+
+        $sHp = str_replace('_', '-', $this->_sName);
+        $sHpT = BX_TIMELINE_VIEW_TIMELINE;
+        $sHpO = BX_TIMELINE_VIEW_OUTLINE;
+        $this->_aHtmlIds = array(
+            'view' => array(
+                'edit_form' => $sHp . '-edit-',
+
+                'menu_popup' => $sHp . '-menu-popup-',
+
+                'video_iframe' => $sHp . '-video-iframe-',
+                'video' => $sHp . '-video-',
+
+                'live_update_popup' => $sHp . '-live-update-popup-',
+            ),
+            'post' => array(
+                'attach_link_popup' =>  $sHp . '-attach-link-popup',
+                'attach_link_form_field' => $sHp . '-attach-link-form_field',
+                'attach_link_item' => $sHp . '-attach-link-item-',
+                'textarea' => $sHp . '-textarea-',
+
+                'main_' . $sHpT => $sHp . '-' . $sHpT,
+                'main_' . $sHpO => $sHp . '-' . $sHpO,
+            ),
+            'repost' => array(
+                'main' => $sHp . '-repost-',
+                'counter' => $sHp . '-repost-counter-',
+                'by_popup' => $sHp . '-repost-by-',
+            )
+        );
+
+        $this->_aRepostDefaults = array(
+            'show_do_repost_as_button' => false,
+            'show_do_repost_as_button_small' => false,
+            'show_do_repost_image' => false,
+            'show_do_repost_icon' => true,
+            'show_do_repost_text' => false,
+            'show_counter' => true,
+
+            //--- Images
+            'image_do_repost' => '',
+
+            //--- Icons
+            'icon_do_repost' => 'sync-alt',
+
+            //--- Texts
+            'text_do_repost' => '_bx_timeline_txt_do_repost',
+
+            //--- Templates
+            'template_do_repost_label' => '',
+            'template_do_repost_label_name' => 'repost_do_repost_label.html',
+        );
+
+        $this->_iTimelineVisibilityThreshold = 0;
+
+        $this->_aPregPatterns = array(
+            "meta_title" => "/<title>(.*)<\/title>/",
+            "meta_description" => "/<meta[\s]+[^>]*?name[\s]?=[\s\"\']+description[\s\"\']+content[\s]?=[\s\"\']+(.*?)[\"\']+.*?>/",
+        	"url" => "/(([A-Za-z]{3,9}:(?:\/\/)?)(?:[\-;:&=\+\$,\w]+@)?[A-Za-z0-9\.\-]+|(?:www\.|[\-;:&=\+\$,\w]+@)[A-Za-z0-9\.\-]+)((?:\/[\+~%\/\.\w\-_]*)?\??(?:[\-\+=&;%@\.\w_]*)#?(?:[\.\!\/\\\w]*))?/"
+        );
+    }
+
+    public function init(&$oDb)
+    {
+    	parent::init($oDb);
+
+    	$sOptionPrefix = $this->getPrefix('option');
+    	$this->_bAllowEdit = getParam($sOptionPrefix . 'enable_edit') == 'on';
+        $this->_bAllowDelete = getParam($sOptionPrefix . 'enable_delete') == 'on';
+        $this->_bShowAll = getParam($sOptionPrefix . 'enable_show_all') == 'on';
+        $this->_bCountAllViews = getParam($sOptionPrefix . 'enable_count_all_views') == 'on';
+
+        $this->_bCacheItem = getParam($sOptionPrefix . 'enable_cache_item') == 'on';
+        $this->_sCacheItemEngine = getParam($sOptionPrefix . 'cache_item_engine');
+        $this->_iCacheItemLifetime = (int)getParam($sOptionPrefix . 'cache_item_lifetime');
+        $this->_bCacheList = getParam($sOptionPrefix . 'enable_cache_list') == 'on';
+
+        $this->_aPerPage = array(
+            'default' => (int)getParam($sOptionPrefix . 'events_per_page'),
+            'profile' => (int)getParam($sOptionPrefix . 'events_per_page_profile'),
+            'account' => (int)getParam($sOptionPrefix . 'events_per_page_account'),
+            'home' => (int)getParam($sOptionPrefix . 'events_per_page_home')
+    	);
+
+        $this->_iRssLength = (int)getParam($sOptionPrefix . 'rss_length');
+        $this->_iLiveUpdateLength = 10;
+        $this->_iCharsDisplayMaxTitle = 20;
+
+        $this->_sVideosAutoplay = getParam($sOptionPrefix . 'videos_autoplay');
+
+        $this->_iPreloadCommentsMax = 7;
+        $this->_iPreloadComments = (int)getParam($sOptionPrefix . 'preload_comments');
+        if($this->_iPreloadComments > $this->_iPreloadCommentsMax)
+            $this->_iPreloadComments = $this->_iPreloadCommentsMax;
+
+        $this->_bHot = getParam($sOptionPrefix . 'enable_hot') == 'on';
+        $this->_iHotInterval = (int)getParam($sOptionPrefix . 'hot_interval');
+
+        $this->_bEditorToolbar = getParam($sOptionPrefix . 'enable_editor_toolbar') == 'on';
+
+        $this->_bUnhideRestored = false;
+    }
+
+    protected function getNameView($aParams, $bWithOwner = false, $sGlue = '_')
+    {
+        $aAddons = array();
+        if(!empty($aParams['name']))
+            $aAddons[] = $aParams['name'];
+        else {
+            if(!empty($aParams['view']))
+                $aAddons[] = $aParams['view'];
+
+            if(!empty($aParams['type']))
+                $aAddons[] = $aParams['type'];
+        }
+
+        if($bWithOwner)
+            $aAddons[] = $aParams['owner_id'];
+
+        return !empty($aAddons) ? implode('_', $aAddons) : '';
+    }
+
+    /**
+     * Generates unique JS object name for View events block.
+     * 
+     * @param array $aParams - an array with browsing params received in View block service method
+     * @return string with JS object name
+     */
+    public function getJsObjectView($aParams = array())
+    {
+        return parent::getJsObject('view') . bx_gen_method_name($this->getNameView($aParams));
+    }
+
+    public function getHtmlIdView($sKey, $aParams, $bWhole = true)
+    {
+        $sDiv = '_';
+
+        return str_replace($sDiv, '-', $this->_sName  . $sDiv . $sKey . $sDiv . $this->getNameView($aParams) . (!$bWhole ? $sDiv : ''));
+    }
+
+    public function isAllowEdit()
+    {
+        return $this->_bAllowEdit;
+    }
+
+    public function isAllowDelete()
+    {
+        return $this->_bAllowDelete;
+    }
+
+    public function isShowAll()
+    {
+        return $this->_bShowAll;
+    }
+
+    public function isCountAllViews()
+    {
+        return $this->_bCountAllViews;
+    }
+
+    public function isHot()
+    {
+        return $this->_bHot;
+    }
+
+    public function isEditorToolbar()
+    {
+    	return $this->_bEditorToolbar;
+    }
+
+    public function isUnhideRestored()
+    {
+        return $this->_bUnhideRestored;
+    }
+
+    public function isCacheItem()
+    {
+        return $this->_bCacheItem;
+    }
+
+    public function isCacheList()
+    {
+        return $this->_bCacheList;
+    }
+
+    public function getCacheItemEngine()
+    {
+        return $this->_sCacheItemEngine;
+    }
+
+    public function getCacheItemLifetime()
+    {
+        return $this->_iCacheItemLifetime;
+    }
+
+    public function getCacheItemKey($iId, $sPostfix = '')
+    {
+        return $this->getPrefix('cache_item') . $iId . (!empty($sPostfix) ? '_' . $sPostfix : '') . '.php';
+    }
+
+    public function getPostFormDisplay($sType)
+    {
+        if(empty($sType) || !array_key_exists($sType, $this->_aTypeToFormDisplay))
+            $sType = BX_TIMELINE_TYPE_DEFAULT;
+
+        return $this->_aTypeToFormDisplay[$sType];
+    }
+
+    public function getUploaders($sType)
+    {
+        $aResult = array();
+
+        switch($sType) {
+            case 'photo':
+                $aResult = $this->_aPhotoUploaders;
+                break;
+			case 'video':
+                $aResult = $this->_aVideoUploaders;
+                break;
+        }
+
+        return $aResult;
+    }
+
+    public function getRssLength()
+    {
+        return $this->_iRssLength;
+    }
+
+    public function getLiveUpdateLength()
+    {
+        return $this->_iLiveUpdateLength;
+    }
+
+    public function getCharsDisplayMaxTitle()
+    {
+        return $this->_iCharsDisplayMaxTitle;
+    }
+
+    public function getVideosAutoplay()
+    {
+        return $this->_sVideosAutoplay;
+    }
+
+    public function getPreloadComments()
+    {
+        return $this->_iPreloadComments;
+    }
+
+    public function getHotInterval()
+    {
+        return $this->_iHotInterval;
+    }
+
+    public function getRepostDefaults()
+    {
+        return $this->_aRepostDefaults;
+    }
+
+    public function getPregPattern($sType)
+    {
+        return $this->_aPregPatterns[$sType];
+    }
+
+    /**
+     * Ancillary functions
+     */
+    public function getTitle($s, $mixedProfile = false)
+    {
+        if($mixedProfile !== false) {
+            if(is_numeric($mixedProfile))
+                $mixedProfile = BxDolProfile::getInstanceMagic((int)$mixedProfile);
+
+            if($mixedProfile instanceof BxDolProfile)
+                $s = bx_replace_markers($s, array(
+                    'profile_name' => $mixedProfile->getDisplayName()
+                ));
+        }
+
+        return strmaxtextlen($s, $this->getCharsDisplayMaxTitle(), '...');
+    }
+
+    public function getTitleDefault($bL, $bP, $bV)
+    {
+        $sResult = '';
+
+        if($bL && !$bP && !$bV)
+            $sResult = 'link';
+        else if(!$bL && $bP && !$bV)
+            $sResult = 'image';
+        else if(!$bL && !$bP && $bV)
+            $sResult = 'video';
+        else 
+            $sResult = 'media';
+
+        return $this->CNF['T']['txt_sample_with_' . $sResult];
+    }
+
+    public function getViewUrl($iOwnerId)
+    {
+        return BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink('page.php', array(
+        	'i' => $this->CNF['URI_VIEW_LIST'], 
+        	'id' => $iOwnerId
+        ));
+    }
+
+    public function getHomeViewUrl()
+    {
+        return BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink($this->CNF['URL_HOME']);
+    }
+
+    public function getItemViewUrl($aEvent)
+    {
+        return BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink('page.php', array(
+        	'i' => $this->CNF['URI_VIEW_ENTRY'], 
+        	'id' => $aEvent['id']
+        ));
+    }
+
+    public function getLiveUpdateKey($aParams)
+    {
+        return $this->getName() . '_live_update_' . $this->getNameView($aParams, true);
+    }
+
+    public function isCommon($sType, $sAction)
+    {
+        return !$this->isSystem($sType, $sAction);
+    }
+
+    public function isSystem($sType, $sAction)
+    {
+        $sPrefix = $this->getPrefix('common_post');
+        return strpos($sType, $sPrefix) === false && !empty($sAction);
+    }
+
+    public function getSystemData(&$aEvent, $aBrowseParams = array())
+    {
+        $sHandler = $aEvent['type'] . '_' . $aEvent['action'];
+        if(!$this->isHandler($sHandler))
+            return false;
+
+        $aHandler = $this->getHandlers($sHandler);
+        if(empty($aHandler['module_name']) || empty($aHandler['module_class']) || empty($aHandler['module_method']))
+            return false; 
+
+        return BxDolService::call($aHandler['module_name'], $aHandler['module_method'], array($aEvent, $aBrowseParams), $aHandler['module_class']);
+    }
+
+    public function getSystemDataByDescriptor($sType, $sAction, $iObjectId)
+    {
+    	$aDescriptor = array(
+            'type' => $sType, 
+            'action' => $sAction,
+            'object_id' => $iObjectId
+    	);
+    	return $this->getSystemData($aDescriptor);
+    }
+
+    public function isEqualUrls($sUrl1, $sUrl2)
+    {
+        $sUrl1 = trim($sUrl1, "/");
+        $sUrl2 = trim($sUrl2, "/");
+
+        return strncmp($sUrl1, $sUrl2, strlen($sUrl1)) === 0;
+    }
+
+    public function addBrowseParams($sUrl, $aParams, $sKey = 'bp')
+    {
+        return bx_append_url_params($sUrl, array($sKey => urlencode(base64_encode(serialize($aParams)))));
+    }
+
+    public function getBrowseParams($sValue)
+    {
+        return unserialize(base64_decode(urldecode($sValue)));
+    }
+}
+
+/** @} */

+ 36 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineCronPublishing.php

@@ -0,0 +1,36 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Posts Posts
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineCronPublishing extends BxDolCron
+{
+    protected $_sModule;
+    protected $_oModule;
+
+    public function __construct()
+    {
+        parent::__construct();
+
+    	$this->_sModule = 'bx_timeline';
+    	$this->_oModule = BxDolModule::getInstance($this->_sModule);
+    }
+
+    function processing()
+    {
+        $mixedIds = $this->_oModule->_oDb->publishEntries();
+        if($mixedIds === false)
+            return;
+
+        foreach($mixedIds as $iId)
+            $this->_oModule->onPublished($iId);
+    }
+}
+
+/** @} */

+ 853 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineDb.php

@@ -0,0 +1,853 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineDb extends BxBaseModNotificationsDb
+{
+    protected $_sTableCache;
+
+    protected $_sTableEvent2User;
+    protected $_sTablesRepostTrack;
+    protected $_sTableHotTrack;
+
+    protected $_aTablesMedia;
+    protected $_aTablesMedia2Events;
+
+    /*
+     * Constructor.
+     */
+    function __construct(&$oConfig)
+    {
+        parent::__construct($oConfig);
+        $this->_sTableCache = $this->_sPrefix . 'cache';
+
+        $this->_sTableEvent2User = $this->_sPrefix . 'events2users';
+        $this->_sTableRepostsTrack = $this->_sPrefix . 'reposts_track';
+        $this->_sTableHotTrack = $this->_sPrefix . 'hot_track';
+
+        $this->_aTablesMedia = array(
+        	BX_TIMELINE_MEDIA_PHOTO => $this->_sPrefix . 'photos',
+        	BX_TIMELINE_MEDIA_VIDEO => $this->_sPrefix . 'videos' 
+        );
+        $this->_aTablesMedia2Events = array(
+        	BX_TIMELINE_MEDIA_PHOTO => $this->_sPrefix . 'photos2events',
+        	BX_TIMELINE_MEDIA_VIDEO => $this->_sPrefix . 'videos2events'
+        );
+    }
+
+    public function deleteModuleEvents($aData)
+    {
+        foreach($aData['handlers'] as $aHandler) {
+            //Delete system events.
+            $this->deleteEvent(array('type' => $aHandler['alert_unit'], 'action' => $aHandler['alert_action']));
+
+            //Delete reposted events.
+            $aEvents = $this->getEvents(array('browse' => 'reposted_by_descriptor', 'type' => $aHandler['alert_unit'], 'action' => $aHandler['alert_action']));
+                foreach($aEvents as $aEvent) {
+                    $aContent = unserialize($aEvent['content']);
+                    if(isset($aContent['type']) && $aContent['type'] == $aHandler['alert_unit'] && isset($aContent['action']) && $aContent['action'] == $aHandler['alert_action'])
+                        $this->deleteEvent(array('id' => (int)$aEvent['id']));
+                }
+        }
+    }
+
+    public function activateModuleEvents($aData, $bActivate = true)
+    {
+        $iActivate = $bActivate ? 1 : 0;
+
+        foreach($aData['handlers'] as $aHandler) {
+            //Activate (deactivate) system events.
+            $this->updateEvent(array('active' => $iActivate), array('type' => $aHandler['alert_unit'], 'action' => $aHandler['alert_action']));
+
+            //Activate (deactivate) reposted events.
+            $aEvents = $this->getEvents(array('browse' => 'reposted_by_descriptor', 'type' => $aHandler['alert_unit'], 'action' => $aHandler['alert_action']));
+            foreach($aEvents as $aEvent) {
+                $aContent = unserialize($aEvent['content']);
+                if(isset($aContent['type']) && $aContent['type'] == $aHandler['alert_unit'] && isset($aContent['action']) && $aContent['action'] == $aHandler['alert_action'])
+                    $this->updateEvent(array('active' => $iActivate), array('id' => (int)$aEvent['id']));
+            }
+        }
+    }
+
+    public function getMaxDuration($aParams)
+    {
+        $aParams['browse'] = 'last';
+        if(isset($aParams['timeline']))
+            unset($aParams['timeline']);
+
+        $aEvent = $this->getEvents($aParams);
+        if(empty($aEvent) || !is_array($aEvent))
+            return 0;
+
+        $iNowYear = date('Y', time());
+        return (int)$aEvent['year'] < $iNowYear ? (int)$aEvent['year'] : 0;
+    }
+
+    //--- Repost related methods ---//
+    public function insertRepostTrack($iEventId, $iAuthorId, $sAuthorIp, $iRepostedId)
+    {
+        $iNow = time();
+        $iAuthorNip = ip2long($sAuthorIp);
+        $sQuery = $this->prepare("INSERT INTO `{$this->_sTableRepostsTrack}` SET `event_id` = ?, `author_id` = ?, `author_nip` = ?, `reposted_id` = ?, `date` = ?", $iEventId, $iAuthorId, $iAuthorNip, $iRepostedId, $iNow);
+        return (int)$this->query($sQuery) > 0;
+    }
+
+    public function deleteRepostTrack($iEventId)
+    {
+        $sQuery = $this->prepare("DELETE FROM `{$this->_sTableRepostsTrack}` WHERE `event_id` = ?", $iEventId);
+        return (int)$this->query($sQuery) > 0;
+    }
+
+    public function updateRepostCounter($iId, $iCounter, $iIncrement = 1)
+    {
+        return (int)$this->updateEvent(array('reposts' => (int)$iCounter + $iIncrement), array('id' => $iId)) > 0;
+    }
+
+    public function getReposted($sType, $sAction, $iObjectId)
+    {
+    	$bSystem = $this->_oConfig->isSystem($sType, $sAction);
+
+        if($bSystem)
+            $aParams = array('browse' => 'descriptor', 'type' => $sType, 'action' => $sAction, 'object_id' => $iObjectId);
+        else
+            $aParams = array('browse' => 'id', 'value' => $iObjectId);
+
+		$aReposted = $this->getEvents($aParams);
+		if($bSystem && (empty($aReposted) || !is_array($aReposted))) {
+			$iOwnerId = 0;
+			$iDate = 0;
+			$sStatus = BX_TIMELINE_STATUS_DELETED;
+
+			$mixedResult = $this->_oConfig->getSystemDataByDescriptor($sType, $sAction, $iObjectId);
+			if(is_array($mixedResult)) {
+                            $iOwnerId = !empty($mixedResult['owner_id']) ? (int)$mixedResult['owner_id'] : 0;
+                            $iDate = !empty($mixedResult['date']) ? (int)$mixedResult['date'] : 0;
+                            if($this->_oConfig->isUnhideRestored() && !empty($iOwnerId) && !empty($iDate))
+                                $sStatus = BX_TIMELINE_STATUS_ACTIVE;
+			}
+
+			$iId = $this->insertEvent(array(
+                            'owner_id' => $iOwnerId,
+                            'type' => $sType,
+                            'action' => $sAction,
+                            'object_id' => $iObjectId,
+                            'object_privacy_view' => $this->_oConfig->getPrivacyViewDefault('object'),
+                            'content' => '',
+                            'title' => '',
+                            'description' => '',
+                            'date' => $iDate,
+                            'status' => $sStatus
+			));
+
+			$aReposted = $this->getEvents(array('browse' => 'id', 'value' => $iId));
+		}
+
+        return $aReposted;
+    }
+
+    function getRepostedBy($iRepostedId)
+    {
+        $sQuery = $this->prepare("SELECT `author_id` FROM `{$this->_sTableRepostsTrack}` WHERE `reposted_id`=?", $iRepostedId);
+        return $this->getColumn($sQuery);
+    }
+
+    function isReposted($iRepostedId, $iOwnerId, $iAuthorId)
+    {
+    	$sQuery = $this->prepare("SELECT 
+    			`te`.`id`
+    		FROM `{$this->_sTableRepostsTrack}` AS `tst` 
+    		LEFT JOIN `{$this->_sTable}` AS `te` ON `tst`.`event_id`=`te`.`id` 
+    		WHERE `tst`.`author_id`=? AND `tst`.`reposted_id`=? AND `te`.`owner_id`=?", $iAuthorId, $iRepostedId, $iOwnerId);
+
+    	return (int)$this->getOne($sQuery) > 0;
+    }
+
+    //--- Photo uploader related methods ---//
+    public function saveMedia($sType, $iEventId, $iItemId)
+    {
+    	$sTable = $this->_aTablesMedia2Events[$sType];
+
+        $sQuery = $this->prepare("INSERT INTO `" . $sTable . "` SET `event_id`=?, `media_id`=?", $iEventId, $iItemId);
+        return (int)$this->query($sQuery) > 0;
+    }
+
+    public function deleteMedia($sType, $iEventId)
+    {
+    	$sTable = $this->_aTablesMedia2Events[$sType];
+
+        $sQuery = $this->prepare("DELETE FROM `" . $sTable . "` WHERE `event_id` = ?", $iEventId);
+        return (int)$this->query($sQuery) > 0;
+    }
+
+    public function getMedia($sType, $iEventId, $iOffset = 0)
+    {
+    	$sTableMedia = $this->_aTablesMedia[$sType];
+    	$sTableMedia2Events = $this->_aTablesMedia2Events[$sType];
+
+        $sLimitAddon = '';
+        if($iOffset != 0)
+            $sLimitAddon = $this->prepareAsString(" OFFSET ?", $iOffset);
+
+        $sQuery = $this->prepare("SELECT
+                 `tme`.`media_id` AS `id`
+            FROM `" . $sTableMedia2Events . "` AS `tme`
+            LEFT JOIN `" . $sTableMedia . "` AS `tm` ON `tme`.`media_id`=`tm`.`id`
+            WHERE `tme`.`event_id`=?" . $sLimitAddon, $iEventId);
+
+        return $this->getColumn($sQuery);
+    }
+
+    public function getMediaById($sType, $iMediaId)
+    {
+        $sTableMedia = $this->_aTablesMedia[$sType];
+    	$sTableMedia2Events = $this->_aTablesMedia2Events[$sType];
+
+        return $this->getRow("SELECT `tm`.*, `tme`.`event_id` AS `event_id` FROM `" . $sTableMedia2Events . "` AS `tme` LEFT JOIN `" . $sTableMedia . "` AS `tm` ON `tme`.`media_id`=`tm`.`id` WHERE `tme`.`media_id`=:media_id LIMIT 1", array(
+            'media_id' => $iMediaId
+        ));
+    }
+
+    //--- Link attach related methods ---//
+    public function getUnusedLinks($iUserId, $iLinkId = 0)
+    {
+        $aMethod = array('name' => 'getAll', 'params' => array(0 => 'query'));
+        $aMethod['params'][1] = array(
+			'profile_id' => $iUserId
+		);
+
+        $sWhereAddon = '';
+        if(!empty($iLinkId)) {
+            $aMethod['name'] = 'getRow';
+            $aMethod['params'][1]['id'] = $iLinkId;
+
+            $sWhereAddon = " AND `tl`.`id`=:id";
+        }
+
+        $aMethod['params'][0] = "SELECT
+                `tl`.`id` AS `id`,
+                `tl`.`profile_id` AS `profile_id`,
+                `tl`.`media_id` AS `media_id`,
+                `tl`.`url` AS `url`,
+                `tl`.`title` AS `title`,
+                `tl`.`text` AS `text`,
+                `tl`.`added` AS `added`
+            FROM `" . $this->_sPrefix . "links` AS `tl`
+            LEFT JOIN `" . $this->_sPrefix . "links2events` AS `tle` ON `tl`.`id`=`tle`.`link_id`
+            WHERE `tl`.`profile_id`=:profile_id AND ISNULL(`tle`.`event_id`)" . $sWhereAddon . "
+            ORDER BY `tl`.`added` DESC";
+
+        return call_user_func_array(array($this, $aMethod['name']), $aMethod['params']);;
+    }
+
+    public function deleteUnusedLinks($iUserId, $iLinkId = 0)
+    {
+    	$aBindings = array(
+    		'profile_id' => $iUserId
+    	);
+
+        $sWhereAddon = '';
+        if(!empty($iLinkId)) {
+        	$aBindings['id'] = $iLinkId;
+
+            $sWhereAddon = " AND `id`=:id";
+        }
+
+        return $this->query("DELETE FROM `" . $this->_sPrefix . "links` WHERE `profile_id`=:profile_id" . $sWhereAddon, $aBindings);
+    }
+
+    public function saveLink($iEventId, $iLinkId)
+    {
+        $sQuery = $this->prepare("INSERT INTO `" . $this->_sPrefix . "links2events` SET `event_id`=?, `link_id`=?", $iEventId, $iLinkId);
+        return (int)$this->query($sQuery) > 0;
+    }
+
+    public function deleteLinks($iEventId)
+    {
+        $sQuery = $this->prepare("DELETE FROM `tl`, `tle` USING `" . $this->_sPrefix . "links` AS `tl` LEFT JOIN `" . $this->_sPrefix . "links2events` AS `tle` ON `tl`.`id`=`tle`.`link_id` WHERE `tle`.`event_id` = ?", $iEventId);
+        return (int)$this->query($sQuery) > 0;
+    }
+
+    public function getLinks($iEventId)
+    {
+        $sQuery = $this->prepare("SELECT
+                `tl`.`id` AS `id`,
+                `tl`.`profile_id` AS `profile_id`,
+                `tl`.`media_id` AS `media_id`,
+                `tl`.`url` AS `url`,
+                `tl`.`title` AS `title`,
+                `tl`.`text` AS `text`,
+                `tl`.`added` AS `added`
+            FROM `" . $this->_sPrefix . "links` AS `tl`
+            LEFT JOIN `" . $this->_sPrefix . "links2events` AS `tle` ON `tl`.`id`=`tle`.`link_id`
+            WHERE `tle`.`event_id`=?", $iEventId);
+
+        return $this->getAll($sQuery);
+    }
+
+    public function getHot()
+    {
+        return $this->getColumn("SELECT `event_id` FROM `" . $this->_sTableHotTrack . "`");
+    }
+
+    public function clearHot()
+    {
+        return $this->query("TRUNCATE TABLE `" . $this->_sTableHotTrack . "`");
+    }
+
+    public function getHotTrackByDate($iInterval = 24)
+    {
+        $sQuery = "SELECT 
+                `te`.`id` AS `event_id`,
+    			`te`.`date` AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		WHERE `te`.`date` > (UNIX_TIMESTAMP() - 3600 * :interval)";
+
+        return $this->getPairs($sQuery, 'event_id', 'value', array('interval' => $iInterval));
+    }
+
+    public function getHotTrackByCommentsDate($sModule, $sTableTrack, $iInterval = 24)
+    {
+        $sQuery = "SELECT 
+    			`te`.`id` as `event_id`,
+    			MAX(`tt`.`cmt_time`) AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		INNER JOIN `" . $sTableTrack . "` AS `tt` ON `te`.`id`=`tt`.`cmt_object_id` AND `te`.`type`=:module 
+    		WHERE `tt`.`cmt_time` > (UNIX_TIMESTAMP() - 3600 * :interval) 
+    		GROUP BY `te`.`id`";
+
+        return $this->getPairs($sQuery, 'event_id', 'value', array('module' => $sModule, 'interval' => $iInterval));
+    }
+
+    public function getHotTrackByCommentsDateModule($sModule, $sTableTrack, $iInterval = 24)
+    {
+        $sQuery = "SELECT 
+    			`te`.`id` as `event_id`,
+    			MAX(`tt`.`cmt_time`) AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		INNER JOIN `" . $sTableTrack . "` AS `tt` ON `te`.`object_id`=`tt`.`cmt_object_id` AND `te`.`type`=:module 
+    		WHERE `tt`.`cmt_time` > (UNIX_TIMESTAMP() - 3600 * :interval) 
+    		GROUP BY `te`.`object_id`";
+
+        return $this->getPairs($sQuery, 'event_id', 'value', array('module' => $sModule, 'interval' => $iInterval));
+    }
+
+    public function getHotTrackByVotesDate($sModule, $sTableTrack, $iInterval = 24)
+    {
+        $sQuery = "SELECT 
+    			`te`.`id` as `event_id`,
+    			MAX(`tt`.`date`) AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		INNER JOIN `" . $sTableTrack . "` AS `tt` ON `te`.`id`=`tt`.`object_id` AND `te`.`type`=:module 
+    		WHERE `tt`.`date` > (UNIX_TIMESTAMP() - 3600 * :interval) 
+    		GROUP BY `te`.`id`";
+
+        return $this->getPairs($sQuery, 'event_id', 'value', array('module' => $sModule, 'interval' => $iInterval));
+    }
+
+    public function getHotTrackByVotesDateModule($sModule, $sTableTrack, $iInterval = 24)
+    {
+        $sQuery = "SELECT 
+    			`te`.`id` as `event_id`,
+    			MAX(`tt`.`date`) AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		INNER JOIN `" . $sTableTrack . "` AS `tt` ON `te`.`object_id`=`tt`.`object_id` AND `te`.`type`=:module 
+    		WHERE `tt`.`date` > (UNIX_TIMESTAMP() - 3600 * :interval) 
+    		GROUP BY `te`.`object_id`";
+
+        return $this->getPairs($sQuery, 'event_id', 'value', array('module' => $sModule, 'interval' => $iInterval));
+    }
+
+    /**
+     * Hot Track by Sum of Votes during specified Period is currently disabled.
+     */
+    public function getHotTrackByVotesSum($sModule, $sTableTrack, $iInterval = 24)
+    {
+        $sQuery = "SELECT 
+    			`te`.`id` as `event_id`,
+    			SUM(`tt`.`value`) AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		INNER JOIN `" . $sTableTrack . "` AS `tt` ON `te`.`id`=`tt`.`object_id` AND `te`.`type`=:module 
+    		WHERE `tt`.`date` > (UNIX_TIMESTAMP() - 3600 * :interval) 
+    		GROUP BY `te`.`id`";
+
+        return $this->getAll($sQuery, array('module' => $sModule, 'interval' => $iInterval));
+    }
+
+    /**
+     * Hot Track by Sum of Votes during specified Period is currently disabled.
+     */
+    public function getHotTrackByVotesSumModule($sModule, $sTableTrack, $iInterval = 24)
+    {
+        $sQuery = "SELECT 
+    			`te`.`id` as `event_id`,
+    			SUM(`tt`.`value`) AS `value`
+    		FROM `" . $this->_sTable . "` AS `te`
+    		INNER JOIN `" . $sTableTrack . "` AS `tt` ON `te`.`object_id`=`tt`.`object_id` AND `te`.`type`=:module 
+    		WHERE `tt`.`date` > (UNIX_TIMESTAMP() - 3600 * :interval) 
+    		GROUP BY `te`.`object_id`";
+
+        return $this->getAll($sQuery, array('module' => $sModule, 'interval' => $iInterval));
+    }
+
+    public function updateHotTrack($aTrack)
+    {
+        return (int)$this->query("REPLACE INTO `" . $this->_sTableHotTrack . "` SET " . $this->arrayToSQL($aTrack)) > 0;
+    }
+
+    public function insertCache($aParamsSet)
+    {
+        if(empty($aParamsSet))
+            return false;
+
+        return (int)$this->query("REPLACE INTO `{$this->_sTableCache}` SET " . $this->arrayToSQL($aParamsSet)) > 0;
+    }
+
+    public function deleteCache($aParamsWhere)
+    {
+        if(empty($aParamsWhere))
+            return false;
+
+        return (int)$this->query("DELETE FROM `{$this->_sTableCache}` WHERE " . $this->arrayToSQL($aParamsWhere, ' AND ')) > 0;
+    }
+
+    public function clearCache()
+    {
+        return (int)$this->query("DELETE FROM `{$this->_sTableCache}` WHERE 1") > 0;
+    }
+
+    public function getCache($aParams)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+    	$aMethod = array('name' => 'getAll', 'params' => array(0 => 'query'));
+        
+        $sFieldsClause = '*';
+        $sWhereClause = $sLimitClause = '';
+
+        if(isset($aParams['start']) && !empty($aParams['per_page']))
+            $sLimitClause = $aParams['start'] . ", " . $aParams['per_page'];
+
+        switch($aParams['browse']) {
+            case 'list': // by type + owner profile (context) + viewer profile
+                $aMethod['name'] = 'getAllWithKey';
+                $aMethod['params'][1] = 'event_id';
+                $aMethod['params'][2] = array(
+                    'type' => $aParams['type'],
+                    'context_id' => $aParams['context_id'],
+                    'profile_id' => $aParams['profile_id']
+                );
+
+                //--- Apply custom check depending on Type
+                switch($aParams['type']) {
+                    case BX_BASE_MOD_NTFS_TYPE_PUBLIC:
+                        $aMethod['params'][2]['context_id'] = 0;
+                        break;
+
+                    case BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS:
+                        $aMethod['params'][2]['context_id'] = $aParams['profile_id'];
+                        break;
+                }
+
+                $sWhereClause .= " AND `type`=:type AND `context_id`=:context_id  AND `profile_id`=:profile_id";
+                break;
+        }
+
+        $sLimitClause = $sLimitClause ? "LIMIT " . $sLimitClause : "";
+
+        $aMethod['params'][0] = "SELECT " . $sFieldsClause . " 
+        FROM `{$this->_sTableCache}` 
+        WHERE 1" . $sWhereClause . " ORDER BY `date` DESC " . $sLimitClause;
+
+        return call_user_func_array(array($this, $aMethod['name']), $aMethod['params']);
+    }
+
+    public function getEvents($aParams, $bReturnCount = false)
+    {
+        list($sMethod, $sSelectClause, $mixedJoinClause, $mixedWhereClause, $sOrderClause, $sLimitClause) = $this->_getSqlPartsEvents($aParams);
+
+        $bCount = isset($aParams['count']) && $aParams['count'] === true;
+        if($bCount) {
+            $sMethod = 'getOne';
+            $sSelectClause = 'COUNT(*)';
+            $sOrderClause = '';
+            $sLimitClause = '';
+        }
+
+        $aAlertParams = $aParams;
+        unset($aAlertParams['browse']);
+
+        bx_alert($this->_oConfig->getName(), 'get_events', 0, 0, array(
+            'browse' => $aParams['browse'],
+            'params' => $aAlertParams,
+            'table' => $this->_sTable,
+            'method' => &$sMethod,
+            'select_clause' => &$sSelectClause,
+            'join_clause' => &$mixedJoinClause,
+            'where_clause' => &$mixedWhereClause,
+            'order_clause' => &$sOrderClause,
+            'limit_clause' => &$sLimitClause
+        ));
+
+        $sSqlMask = "SELECT {select}
+            FROM `{$this->_sTable}`
+            LEFT JOIN `{$this->_sTableHandlers}` ON `{$this->_sTable}`.`type`=`{$this->_sTableHandlers}`.`alert_unit` AND `{$this->_sTable}`.`action`=`{$this->_sTableHandlers}`.`alert_action` {join}
+            WHERE 1 {where} {order} {limit}";
+
+        if(is_string($mixedWhereClause)) {
+            $aSqlMarkers = array(
+                'select' => $sSelectClause, 
+                'join' => $mixedJoinClause, 
+                'where' => $mixedWhereClause, 
+                'order' => $sOrderClause, 
+                'limit' => $sLimitClause
+            );
+
+            $aEntries = $this->$sMethod(bx_replace_markers($sSqlMask, $aSqlMarkers));
+
+            return !$bReturnCount ? $aEntries : array($aEntries, (int)$this->getOne(bx_replace_markers($sSqlMask, array_merge($aSqlMarkers, array(
+                'select' => 'COUNT(*)',
+                'order' => '',
+                'limit' => ''
+            )))));
+        }
+
+        $bJoinAsArray = !empty($mixedJoinClause) && is_array($mixedJoinClause);
+
+        $sOrderSubclause = $sLimitSubclause = '';
+        if(!$bCount) {
+            $sOrderSubclause = $sOrderClause;
+            $sLimitSubclause = isset($aParams['per_page']) ? 'LIMIT 0, ' . ($aParams['start'] + $aParams['per_page']) : '';
+        }
+
+        $iEntries = 0;
+        $aSqlParts = array();
+        foreach($mixedWhereClause as $sKey => $sValue) {
+            $aSqlMarkers = array(
+                'select' => $sSelectClause, 
+                'join' => $bJoinAsArray ? (isset($mixedJoinClause[$sKey]) ? $mixedJoinClause[$sKey] : '') : $mixedJoinClause, 
+                'where' => $sValue, 
+                'order' => $sOrderSubclause, 
+                'limit' => $sLimitSubclause
+            );
+            $sSqlPart = bx_replace_markers($sSqlMask, $aSqlMarkers);
+
+            $aSqlParts[] = !$bCount ? $sSqlPart : (int)$this->$sMethod($sSqlPart);
+            if(!$bReturnCount)
+                continue;
+
+            $iEntries += (int)$this->getOne(bx_replace_markers($sSqlMask, array_merge($aSqlMarkers, array(
+                'select' => 'COUNT(*)',
+                'order' => '',
+                'limit' => ''
+            ))));
+        }
+
+        $aEntries = $bCount ? array_sum($aSqlParts) : $this->$sMethod(bx_replace_markers('(' . implode(') UNION (', $aSqlParts) . ') {order} {limit}', array(
+            'order' => str_replace('`' . $this->_sTable . '`.', '', $sOrderClause),
+            'limit' => str_replace('`' . $this->_sTable . '`.', '', $sLimitClause),
+        )));
+
+        return !$bReturnCount ? $aEntries : array($aEntries, $iEntries);
+    }
+
+    protected function _getFilterAddon($iOwnerId, $sFilter)
+    {
+        switch($sFilter) {
+            /**
+             * Direct posts in Timeline made by a timeline owner ($iOwnerId)
+             */
+            case BX_TIMELINE_FILTER_OWNER:
+                $sFilterAddon = $this->prepareAsString(" AND `{$this->_sTable}`.`action`='' AND `{$this->_sTable}`.`object_id`=? ", $iOwnerId);
+                break;
+
+            /**
+             * Direct posts in Timeline made by users except a timeline owner ($iOwnerId)
+             */
+            case BX_TIMELINE_FILTER_OTHER:
+                $sFilterAddon = $this->prepareAsString(" AND `{$this->_sTable}`.`action`='' AND `{$this->_sTable}`.`object_id`<>? ", $iOwnerId);
+                break;
+
+            /**
+             * All (Direct and System) posts in Timeline (owned by $iOwnerId) made by users except the viewer
+             */
+            case BX_TIMELINE_FILTER_OTHER_VIEWER:
+                $sFilterAddon = $this->prepareAsString(" AND (`{$this->_sTable}`.`action`<>'' OR (`{$this->_sTable}`.`action`='' AND `{$this->_sTable}`.`object_id`<>?)) ", bx_get_logged_profile_id());
+                break;
+                
+
+            case BX_TIMELINE_FILTER_ALL:
+            default:
+                $sFilterAddon = "";
+        }
+        return $sFilterAddon;
+    }
+
+    protected function _getSqlPartsEvents($aParams)
+    {
+    	$sMethod = 'getAll';
+    	$sSelectClause = "`{$this->_sTable}`.*";
+        $sJoinClause = $sWhereClause = $sOrderClause = $sLimitClause = "";
+
+        switch($aParams['browse']) {
+            case 'owner_id':
+                $sWhereClause = $this->prepareAsString("AND `{$this->_sTable}`.`owner_id`=? ", $aParams['value']);
+                break;
+
+            case 'common_by_object':
+                $sCommonPostPrefix = $this->_oConfig->getPrefix('common_post');
+                $sWhereClause = $this->prepareAsString("AND SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ")='" . $sCommonPostPrefix . "' AND `{$this->_sTable}`.`object_id`=? ", $aParams['value']);
+                break;
+
+            case 'descriptor':
+                $sMethod = 'getRow';
+                $sWhereClause = "";
+
+                if(isset($aParams['type']))
+                    $sWhereClause .= $this->prepareAsString("AND `{$this->_sTable}`.`type`=? ", $aParams['type']);
+                if(isset($aParams['action']))
+                    $sWhereClause .= $this->prepareAsString("AND `{$this->_sTable}`.`action`=? ", $aParams['action']);
+                if(isset($aParams['object_id']))
+                    $sWhereClause .= $this->prepareAsString("AND `{$this->_sTable}`.`object_id`=? ", $aParams['object_id']);
+
+                $sLimitClause = "LIMIT 1";
+                break;
+
+            case 'reposted_by_descriptor':
+            	$sWhereClause = "";
+
+            	if(isset($aParams['type']))
+                    $sWhereClause .= "AND `{$this->_sTable}`.`content` LIKE " . $this->escape('%' . $aParams['type'] . '%');
+
+                if(isset($aParams['action']))
+                    $sWhereClause .= "AND `{$this->_sTable}`.`content` LIKE " . $this->escape('%' . $aParams['action'] . '%');
+                break;
+
+            case 'list':
+                list($sMethod, $sSelectClause, $sJoinClause, $sWhereClause, $sOrderClause, $sLimitClause) = parent::_getSqlPartsEvents($aParams);
+                if(in_array($aParams['type'], array(BX_BASE_MOD_NTFS_TYPE_CONNECTIONS, BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS)))
+                    $sSelectClause  = "DISTINCT " . $sSelectClause;
+                break;
+
+            case 'ids':
+                $sWhereClause = "AND `{$this->_sTable}`.`id` IN (" . $this->implode_escape($aParams['ids']) . ") ";
+                break;
+
+            default:
+            	list($sMethod, $sSelectClause, $sJoinClause, $sWhereClause, $sOrderClause, $sLimitClause) = parent::_getSqlPartsEvents($aParams);
+        }
+
+        $sSelectClause .= ", DAYOFYEAR(FROM_UNIXTIME(`{$this->_sTable}`.`date`)) AS `days`, DAYOFYEAR(NOW()) AS `today`, ROUND((UNIX_TIMESTAMP() - `{$this->_sTable}`.`date`)/86400) AS `ago_days`, YEAR(FROM_UNIXTIME(`{$this->_sTable}`.`date`)) AS `year`";
+        if(in_array($aParams['browse'], array('list', 'ids'))) {
+            $sOrderClause = "";
+
+            switch($aParams['type']) {
+                case BX_TIMELINE_TYPE_HOT:
+                    $sOrderClause = "`{$this->_sTableHotTrack}`.`value` DESC, ";
+                    break;
+
+                    case BX_BASE_MOD_NTFS_TYPE_PUBLIC:
+                    case BX_BASE_MOD_NTFS_TYPE_CONNECTIONS:
+                    case BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS:
+                        $sOrderClause = "`{$this->_sTable}`.`sticked` DESC, ";
+                        break;
+
+                    case BX_BASE_MOD_NTFS_TYPE_OWNER:
+                        $sOrderClause = "`{$this->_sTable}`.`pinned` DESC, ";
+                        break;
+            }
+
+            $sOrderClause = "ORDER BY " . $sOrderClause . "`{$this->_sTable}`.`date` DESC";
+        }
+
+        return array($sMethod, $sSelectClause, $sJoinClause, $sWhereClause, $sOrderClause, $sLimitClause);
+    }
+
+    protected function _getSqlPartsEventsList($aParams)
+    {
+        $sCommonPostPrefix = $this->_oConfig->getPrefix('common_post');
+
+    	$mixedJoinClause = $mixedWhereClause = "";
+
+        $sWhereClauseStatus = "AND `{$this->_sTable}`.`active`='1' ";
+        $sWhereClauseStatus .= $this->prepareAsString("AND `{$this->_sTable}`.`status`=? ", isset($aParams['status']) ? $aParams['status'] : BX_TIMELINE_STATUS_ACTIVE);
+
+        //--- Apply filter
+        $sWhereClauseFilter = "";
+        if(isset($aParams['filter']))
+            $sWhereClauseFilter = $this->_getFilterAddon($aParams['owner_id'], $aParams['filter']);
+
+        //--- Apply timeline
+        $sWhereClauseTimeline = "";
+        if(isset($aParams['timeline']) && !empty($aParams['timeline']))
+            $sWhereClauseTimeline = $this->prepareAsString("AND `date`<=? ", mktime(23, 59, 59, 12, 31, (int)$aParams['timeline']));
+
+        //--- Apply modules or handlers filter
+        $sWhereClauseModules = "";
+        if(!empty($aParams['modules']) && is_array($aParams['modules']))
+            $sWhereClauseModules = "AND `" . $this->_sTable . "`.`type` IN (" . $this->implode_escape($aParams['modules']) . ") ";
+        
+        $sWhereClauseHidden = "";
+        if(empty($sWhereClauseModules)) {
+            $aHidden = $this->_oConfig->getHandlersHidden();
+            $sWhereClauseHidden = !empty($aHidden) && is_array($aHidden) ? "AND `" . $this->_sTableHandlers . "`.`id` NOT IN (" . $this->implode_escape($aHidden) . ") " : "";
+        }
+
+        //--- Apply unpublished (date in future) filter
+        $sWhereClauseUnpublished = $this->prepareAsString("AND IF(SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "' AND `{$this->_sTable}`.`object_id` = ?, 1, `{$this->_sTable}`.`date` <= UNIX_TIMESTAMP()) ", bx_get_logged_profile_id());
+
+        //--- Check type
+        $mixedWhereSubclause = "";
+        switch($aParams['type']) {
+            case BX_TIMELINE_TYPE_HOT: //--- Hot (Public) Feed.
+                $mixedJoinClause .= " INNER JOIN `{$this->_sTableHotTrack}` ON `{$this->_sTable}`.`id`=`{$this->_sTableHotTrack}`.`event_id`";
+
+            case BX_BASE_MOD_NTFS_TYPE_PUBLIC: //--- Site (Public) Feed.
+                //--- Apply privacy filter
+                $aPrivacyGroups = array(BX_DOL_PG_ALL);
+                if(isLogged())
+                    $aPrivacyGroups[] = BX_DOL_PG_MEMBERS;
+
+                $aQueryParts = BxDolPrivacy::getObjectInstance($this->_oConfig->getObject('privacy_view'))->getContentByGroupAsSQLPart($aPrivacyGroups);
+                $mixedWhereClause .= $aQueryParts['where'] . " ";
+
+                if($this->_oConfig->isShowAll())
+                    break;
+
+                //--- Select All System posts
+                $mixedWhereSubclause = "SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ") <> '" . $sCommonPostPrefix . "'";
+
+                //--- Select Public (Direct) posts created on Home Page Timeline (Public Feed) 
+                $mixedWhereSubclause .= $this->prepareAsString(" OR `{$this->_sTable}`.`owner_id`=?", 0);
+
+                //--- Select Promoted posts.
+                $mixedWhereSubclause .= " OR `{$this->_sTable}`.`promoted` <> '0'";
+                break;
+
+            //--- Profile Feed
+            case BX_BASE_MOD_NTFS_TYPE_OWNER:
+                if(empty($aParams['owner_id']))
+                    break;
+
+                //--- Select Own (System and Direct) posts from Profile's Timeline.
+                $mixedWhereSubclause = $this->prepareAsString("(`{$this->_sTable}`.`owner_id` = ?)", $aParams['owner_id']);
+
+                //--- Select Own Public (Direct) posts from Home Page Timeline (Public Feed).
+                $mixedWhereSubclause .= $this->prepareAsString(" OR (`{$this->_sTable}`.`owner_id` = '0' AND IF(SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "', `{$this->_sTable}`.`object_id` = ?, 1))", $aParams['owner_id']);
+                break;
+
+            //--- Profile Connections Feed
+            case BX_BASE_MOD_NTFS_TYPE_CONNECTIONS:
+                if(empty($aParams['owner_id']))
+                    break;
+
+                $oConnection = BxDolConnection::getObjectInstance($this->_oConfig->getObject('conn_subscriptions'));
+
+                $aQueryParts = $oConnection->getConnectedContentAsSQLPartsExt($this->_sPrefix . 'events', 'owner_id', $aParams['owner_id']);
+                $aJoin1 = $aQueryParts['join'];
+
+                $aQueryParts = $oConnection->getConnectedContentAsSQLPartsExt($this->_sPrefix . 'events', 'object_id', $aParams['owner_id']);
+                $aJoin2 = $aQueryParts['join'];
+
+                //--- Join System and Direct posts made by following members.  
+                $mixedJoinClause .= " " . $aJoin1['type'] . " JOIN `" . $aJoin1['table'] . "` AS `" . $aJoin1['table_alias'] . "` ON ((" . $aJoin1['condition'] . ") OR (SUBSTRING(`" . $this->_sTable . "`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "' AND " . $aJoin2['condition'] . "))";
+
+                //--- Exclude Own (Direct) posts on timelines of following members.
+                //--- Note. Disabled for now.
+                //$mixedWhereSubclause = $this->prepareAsString("IF(SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "', `{$this->_sTable}`.`object_id` <> ?, 1)", $aParams['owner_id']);
+                $mixedWhereSubclause = "0";
+
+                //--- Select Promoted posts.
+                $mixedWhereSubclause .= " OR `{$this->_sTable}`.`promoted` <> '0'";
+                break;
+
+            //--- Profile + Profile Connections Feed
+            case BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS:
+                if(empty($aParams['owner_id']))
+                    break;
+
+                $mixedJoinClause = array();
+                $mixedWhereSubclause = array();
+
+                $oConnection = BxDolConnection::getObjectInstance($this->_oConfig->getObject('conn_subscriptions'));
+
+                //--- Select Own (System and Direct) posts from Profile's Timeline.
+                $sWhereSubclauseOwnProfile = $this->prepareAsString("(`{$this->_sTable}`.`owner_id` = ?)", $aParams['owner_id']);
+
+                //--- Select Own Public (Direct) posts from Home Page Timeline (Public Feed).
+                $sWhereSubclauseOwnPublic = $this->prepareAsString("(`{$this->_sTable}`.`owner_id` = '0' AND IF(SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "', `{$this->_sTable}`.`object_id` = ?, 1))", $aParams['owner_id']);
+
+                $mixedWhereSubclause['p1'] = "(" . $sWhereSubclauseOwnProfile . " OR " . $sWhereSubclauseOwnPublic . ")";
+
+                //--- Exclude Own (Direct) posts on timelines of following members.
+                //--- Note. Disabled for now and next check is used instead. 
+                //$mixedWhereSubclause['pX'] = $this->prepareAsString(" OR (NOT ISNULL(`c`.`content`) AND IF(SUBSTRING(`{$this->_sTable}`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "', `{$this->_sTable}`.`object_id` <> ?, 1))", $aParams['owner_id']);
+
+                //--- Join System and Direct posts received by and made by following members. 'LEFT' join is essential to apply different conditions.
+                $aQueryParts = $oConnection->getConnectedContentAsSQLPartsExt($this->_sPrefix . 'events', 'owner_id', $aParams['owner_id']);
+                $aJoin1 = $aQueryParts['join'];
+
+                $mixedJoinClause['p2'] = "LEFT JOIN `" . $aJoin1['table'] . "` AS `" . $aJoin1['table_alias'] . "` ON " . $aJoin1['condition'];
+                $mixedWhereSubclause['p2'] = "NOT ISNULL(`" . $aJoin1['table_alias'] . "`.`content`)";
+
+                $aQueryParts = $oConnection->getConnectedContentAsSQLPartsExt($this->_sPrefix . 'events', 'object_id', $aParams['owner_id']);
+                $aJoin2 = $aQueryParts['join'];
+                $aJoin2['table_alias'] = 'cc';
+                $aJoin2['condition'] = str_replace('`c`', '`' . $aJoin2['table_alias'] . '`', $aJoin2['condition']);
+
+                $mixedJoinClause['p3'] = "LEFT JOIN `" . $aJoin2['table'] . "` AS `" . $aJoin2['table_alias'] . "` ON SUBSTRING(`" . $this->_sTable . "`.`type`, 1, " . strlen($sCommonPostPrefix) . ") = '" . $sCommonPostPrefix . "' AND " . $aJoin2['condition'];
+                $mixedWhereSubclause['p3'] = "NOT ISNULL(`" . $aJoin2['table_alias'] . "`.`content`)";
+
+                //--- Select Promoted posts.
+                $mixedWhereSubclause['p4'] = "`{$this->_sTable}`.`promoted` <> '0'";
+                break;
+        }
+
+        $aAlertParams = $aParams;
+        unset($aAlertParams['type'], $aAlertParams['owner_id']);
+
+        bx_alert($this->_oConfig->getName(), 'get_list_by_type', 0, 0, array(
+            'type' => $aParams['type'],
+            'owner_id' => $aParams['owner_id'],
+            'params' => $aAlertParams,
+            'table' => $this->_sTable,
+            'join_clause' => &$mixedJoinClause,
+            'where_clause' => &$mixedWhereClause,
+            'where_clause_status' => &$sWhereClauseStatus,
+            'where_clause_filter' => &$sWhereClauseFilter,
+            'where_clause_timeline' => &$sWhereClauseTimeline,
+            'where_clause_modules' => &$sWhereClauseModules,
+            'where_clause_hidden' => &$sWhereClauseHidden,
+            'where_clause_unpublished' => &$sWhereClauseUnpublished,
+            'where_subclause' => &$mixedWhereSubclause
+        ));
+
+        $mixedWhereClause .= $sWhereClauseStatus;
+        $mixedWhereClause .= $sWhereClauseFilter;
+        $mixedWhereClause .= $sWhereClauseTimeline;
+        $mixedWhereClause .= $sWhereClauseModules;
+        $mixedWhereClause .= $sWhereClauseHidden;
+        $mixedWhereClause .= $sWhereClauseUnpublished;
+
+        if(!empty($mixedWhereSubclause)) {
+            if(is_array($mixedWhereSubclause)) {
+                $aWhereClause = array();
+                foreach($mixedWhereSubclause as $sKey => $sValue)
+                    $aWhereClause[$sKey] = $mixedWhereClause . "AND " . $sValue . " ";
+                $mixedWhereClause = $aWhereClause;
+            }
+            else
+                $mixedWhereClause .= "AND (" . $mixedWhereSubclause . ") ";
+        }
+
+        return array($mixedJoinClause, $mixedWhereClause);
+    }
+}
+
+/** @} */

+ 247 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineFormPost.php

@@ -0,0 +1,247 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * Create/Edit entry form
+ */
+class BxTimelineFormPost extends BxBaseModGeneralFormEntry
+{
+    protected $_bAccountMode;
+    protected $_bPublicMode;
+    protected $_bProfileMode;
+
+    protected $_bVisibilityAutoselect;
+
+    public function __construct($aInfo, $oTemplate = false)
+    {
+        $this->MODULE = 'bx_timeline';
+
+        parent::__construct($aInfo, $oTemplate);
+
+        $this->_bAccountMode = isset($this->aParams['display']) && $this->aParams['display'] == $this->_oModule->_oConfig->getObject('form_display_post_add');
+        $this->_bPublicMode = isset($this->aParams['display']) && $this->aParams['display'] == $this->_oModule->_oConfig->getObject('form_display_post_add_public');
+        $this->_bProfileMode = isset($this->aParams['display']) && $this->aParams['display'] == $this->_oModule->_oConfig->getObject('form_display_post_add_profile');
+
+        $this->_bVisibilityAutoselect = true;
+    }
+
+    public function getCode($bDynamicMode = false)
+    {
+    	$sResult = parent::getCode($bDynamicMode);
+
+    	return $this->_oModule->_oTemplate->parseHtmlByContent($sResult, array(
+    		'attachments_menu' => $this->_oModule->getAttachmentsMenuObject()->getCode()
+    	));
+    }
+
+    function initChecker($aValues = array (), $aSpecificValues = array())
+    {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
+        if($this->aParams['display'] == $this->_oModule->_oConfig->getObject('form_display_post_edit') && isset($CNF['FIELD_PUBLISHED']) && isset($this->aInputs[$CNF['FIELD_PUBLISHED']]))
+            if(isset($aValues[$CNF['FIELD_STATUS']]) && in_array($aValues[$CNF['FIELD_STATUS']], array(BX_TIMELINE_STATUS_ACTIVE, BX_TIMELINE_STATUS_HIDDEN)))
+                unset($this->aInputs[$CNF['FIELD_PUBLISHED']]);
+
+        if(isset($CNF['FIELD_ANONYMOUS']) && isset($this->aInputs[$CNF['FIELD_ANONYMOUS']]) && isset($aValues[$CNF['FIELD_OBJECT_ID']]))
+            $this->aInputs[$CNF['FIELD_ANONYMOUS']]['checked'] = $aValues[$CNF['FIELD_OBJECT_ID']] < 0;
+
+        parent::initChecker ($aValues, $aSpecificValues);
+    }
+
+    public function insert($aValsToAdd = array(), $isIgnore = false)
+    {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
+        $aValsToAdd[$CNF['FIELD_OBJECT_ID']] *= isset($CNF['FIELD_ANONYMOUS']) && isset($this->aInputs[$CNF['FIELD_ANONYMOUS']]) && $this->getCleanValue($CNF['FIELD_ANONYMOUS']) ? -1 : 1;
+
+        if(isset($CNF['FIELD_ADDED']) && empty($aValsToAdd[$CNF['FIELD_ADDED']])) {
+            $iAdded = 0;
+            if(isset($this->aInputs[$CNF['FIELD_ADDED']]))
+                $iAdded = $this->getCleanValue($CNF['FIELD_ADDED']);
+            
+            if(empty($iAdded))
+                 $iAdded = time();
+
+            $aValsToAdd[$CNF['FIELD_ADDED']] = $iAdded;
+        }
+
+        if(empty($aValsToAdd[$CNF['FIELD_PUBLISHED']])) {
+            $iPublished = 0;
+            if(isset($this->aInputs[$CNF['FIELD_PUBLISHED']]))
+                $iPublished = $this->getCleanValue($CNF['FIELD_PUBLISHED']);
+                
+             if(empty($iPublished))
+                 $iPublished = time();
+
+             $aValsToAdd[$CNF['FIELD_PUBLISHED']] = $iPublished;
+        }
+
+        $aValsToAdd[$CNF['FIELD_STATUS']] = $aValsToAdd[$CNF['FIELD_PUBLISHED']] > $aValsToAdd[$CNF['FIELD_ADDED']] ? BX_TIMELINE_STATUS_AWAITING : BX_TIMELINE_STATUS_ACTIVE;
+
+        return parent::insert ($aValsToAdd, $isIgnore);
+    }
+
+    function update($iContentId, $aValsToAdd = array(), &$aTrackTextFieldsChanges = null)
+    {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
+        if (isset($CNF['FIELD_ANONYMOUS']) && isset($this->aInputs[$CNF['FIELD_ANONYMOUS']])) {
+            $aContentInfo = $this->_oModule->_oDb->getContentInfoById($iContentId);
+
+            $aValsToAdd[$CNF['FIELD_OBJECT_ID']] = ($this->getCleanValue($CNF['FIELD_ANONYMOUS']) ? -1 : 1) * abs($aContentInfo[$CNF['FIELD_OBJECT_ID']]);
+        }
+
+        if(empty($aValsToAdd[$CNF['FIELD_PUBLISHED']]) && isset($this->aInputs[$CNF['FIELD_PUBLISHED']])) {
+            $iPublished = $this->getCleanValue($CNF['FIELD_PUBLISHED']);
+            if(empty($iPublished))
+                $iPublished = time();
+
+            $aValsToAdd[$CNF['FIELD_PUBLISHED']] = $iPublished;
+        }
+
+        return parent::update($iContentId, $aValsToAdd, $aTrackTextFieldsChanges);
+    }
+
+    public function addHtmlEditor($iViewMode, &$aInput)
+    {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
+        $oEditor = BxDolEditor::getObjectInstance(false, $this->oTemplate);
+        if (!$oEditor)
+            return false;
+
+        if(in_array($this->aParams['display'], array($this->_oModule->_oConfig->getObject('form_display_post_add'), $this->_oModule->_oConfig->getObject('form_display_post_add_public'))))
+            $oEditor->setCustomConf("
+                placeholderText: '" . _t('_bx_timeline_txt_some_text_here') . "',
+                initOnClick: false,
+            ");
+
+        if(!$this->_oModule->_oConfig->isEditorToolbar())
+        	$oEditor->setCustomToolbarButtons('');
+
+        $this->_sCodeAdd .= $oEditor->attachEditor ('#' . $this->aFormAttrs['id'] . ' [name='.$aInput['name'].']', $iViewMode, $this->_bDynamicMode);
+
+        return true;
+    }
+
+    public function init()
+    {
+        $iUserId = $this->_oModule->getUserId();
+        $iOwnerId = $this->_oModule->getOwnerId();
+
+        $this->aFormAttrs['action'] = BX_DOL_URL_ROOT . $this->_oModule->_oConfig->getBaseUri() . 'post/';
+
+        $this->aInputs['owner_id']['value'] = $iOwnerId;
+
+        if(isset($this->aInputs['text'])) {
+            if(empty($this->aInputs['text']['attrs']) || !is_array($this->aInputs['text']['attrs']))
+                $this->aInputs['text']['attrs'] = array();
+
+            $this->aInputs['text']['attrs']['id'] = $this->_oModule->_oConfig->getHtmlIds('post', 'textarea') . time();
+        }
+
+        if(isset($this->aInputs['object_privacy_view']))
+            $this->aInputs['object_privacy_view'] = $this->_updateFieldObjectPrivacyView($this->aInputs['object_privacy_view']);
+
+        if(isset($this->aInputs['link']))
+            $this->aInputs['link']['content'] = $this->_oModule->_oTemplate->getAttachLinkField($iUserId);
+
+        if(isset($this->aInputs['photo'])) {
+            $aFormNested = array(
+                'params' =>array(
+                    'nested_form_template' => 'uploader_nfw.html'
+                ),
+                'inputs' => array(),
+            );
+
+            $oFormNested = new BxDolFormNested('photo', $aFormNested, 'tlb_do_submit', $this->_oModule->_oTemplate);
+
+            $this->aInputs['photo']['storage_object'] = $this->_oModule->_oConfig->getObject('storage_photos');
+            $this->aInputs['photo']['images_transcoder'] = $this->_oModule->_oConfig->getObject('transcoder_photos_preview');
+            $this->aInputs['photo']['uploaders'] = !empty($this->aInputs['photo']['value']) ? unserialize($this->aInputs['photo']['value']) : $this->_oModule->_oConfig->getUploaders('photo');
+            $this->aInputs['photo']['upload_buttons_titles'] = array('Simple' => 'camera');
+            $this->aInputs['photo']['multiple'] = true;
+            $this->aInputs['photo']['ghost_template'] = $oFormNested;
+        }
+
+        if(isset($this->aInputs['video'])) {
+            $aFormNested = array(
+                'params' =>array(
+                    'nested_form_template' => 'uploader_nfw.html'
+                ),
+                'inputs' => array(),
+            );
+
+            $oFormNested = new BxDolFormNested('video', $aFormNested, 'tlb_do_submit', $this->_oModule->_oTemplate);
+
+            $this->aInputs['video']['storage_object'] = $this->_oModule->_oConfig->getObject('storage_videos');
+            $this->aInputs['video']['images_transcoder'] = $this->_oModule->_oConfig->getObject('transcoder_videos_poster');
+            $this->aInputs['video']['uploaders'] = !empty($this->aInputs['video']['value']) ? unserialize($this->aInputs['video']['value']) : $this->_oModule->_oConfig->getUploaders('video');
+            $this->aInputs['video']['upload_buttons_titles'] = array('Simple' => 'video');
+            $this->aInputs['video']['multiple'] = true;
+            $this->aInputs['video']['ghost_template'] = $oFormNested;
+        }
+
+        if(isset($this->aInputs['attachments']))
+            $this->aInputs['attachments']['content'] = '__attachments_menu__';
+
+        if (isset($this->_oModule->_oConfig->CNF['FIELD_LOCATION_PREFIX']) && isset($this->aInputs[$this->_oModule->_oConfig->CNF['FIELD_LOCATION_PREFIX']]))
+            $this->aInputs[$this->_oModule->_oConfig->CNF['FIELD_LOCATION_PREFIX']]['manual_input'] = false;
+    }
+
+    public function setVisibilityAutoselect($bVisibilityAutoselect)
+    {
+        $this->_bVisibilityAutoselect = $bVisibilityAutoselect;
+    }
+
+    protected function _updateFieldObjectPrivacyView($aInput)
+    {
+    	$iUserId = $this->_oModule->getUserId();
+        $iOwnerId = $this->_oModule->getOwnerId();
+
+        $aInput = array_merge($aInput, BxDolPrivacy::getGroupChooser($this->_oModule->_oConfig->getObject('privacy_view'), 0, array(
+            'title' => _t('_bx_timeline_form_post_input_object_privacy_view')
+        )));
+
+        //--- Show field as is when 'Autoselect' is disabled.
+        if(!$this->_bVisibilityAutoselect)
+            return $aInput;
+
+        //--- Show default privacy groups and followed contexts on Account (Profile + Connections) post form.
+        if($this->_bAccountMode)
+            return $aInput;
+
+        //--- Preselect Context and hide privacy selector when posting in some context (profile, group, space, etc).
+        if($this->_bProfileMode && $iOwnerId != $iUserId) {
+            $aInput['type'] = 'hidden';
+	    $aInput['value'] = -$iOwnerId;
+
+            return $aInput;
+        }
+
+        if($this->_bPublicMode || $this->_bProfileMode)
+            foreach($aInput['values'] as $iKey => $aValue) {
+                //--- Show 'Public' privacy group only in Public post form. 
+                if($this->_bPublicMode && isset($aValue['key']) && $aValue['key'] == BX_DOL_PG_ALL)
+                    continue;
+
+                //--- Show a default privacy groups in Profile (for Owner) post form.
+                if($this->_bProfileMode && $iOwnerId == $iUserId && isset($aValue['key']) && (int)$aValue['key'] >= 0)
+                    continue;
+
+                unset($aInput['values'][$iKey]);
+            }
+
+        return $aInput;
+    }
+}
+
+/** @} */

+ 112 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineGridAdministration.php

@@ -0,0 +1,112 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ * 
+ * @{
+ */
+
+class BxTimelineGridAdministration extends BxBaseModGeneralGridAdministration
+{
+    public function __construct ($aOptions, $oTemplate = false)
+    {
+    	$this->MODULE = 'bx_timeline';
+        parent::__construct ($aOptions, $oTemplate);
+    }
+
+    protected function _getCellDate($mixedValue, $sKey, $aField, $aRow)
+    {
+        return parent::_getCellDefault(bx_time_js($mixedValue), $sKey, $aField, $aRow);
+    }
+
+    protected function _switcherChecked2State($isChecked)
+    {
+        return $isChecked ? 'active' : 'hidden';
+    }
+
+    protected function _switcherState2Checked($mixedState)
+    {
+        return 'active' == $mixedState ? true : false;
+    }
+
+    public function performActionDelete($aParams = array())
+    {
+    	$CNF = &$this->_oModule->_oConfig->CNF;
+
+        $iAffected = 0;
+        $aIds = bx_get('ids');
+        if(!$aIds || !is_array($aIds)) {
+            echoJson(array());
+            exit;
+        }
+
+        $aIdsAffected = array ();
+        foreach($aIds as $iId) {
+            $aContentInfo = $this->_oModule->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+            if ($this->_oModule->deleteEvent($aContentInfo)){
+                $aIdsAffected[] = $iId;
+                $iAffected++;
+            }
+        }
+
+        echoJson($iAffected ? array('grid' => $this->getCode(false), 'blink' => $aIdsAffected) : array('msg' => _t($CNF['T']['grid_action_err_delete'])));
+    }
+    
+    protected function _getActionDelete($sType, $sKey, $a, $isSmall = false, $isDisabled = false, $aRow = array())
+    {
+        if($this->_sManageType == BX_DOL_MANAGE_TOOLS_ADMINISTRATION && $this->_oModule->isAllowedDelete($aRow) !== true)
+            return '';
+
+    	return $this->_getActionDefault($sType, $sKey, $a, $isSmall, $isDisabled, $aRow);
+    }
+
+    protected function _getCellDescription($mixedValue, $sKey, $aField, $aRow)
+    {
+        $iProfile = $this->_oModule->_oConfig->isSystem($aRow['type'], $aRow['action']) ? $aRow['owner_id'] : $aRow['object_id'];
+        $oProfile = $this->_getProfileObject($iProfile);
+
+        $mixedValue = $this->_oTemplate->parseHtmlByName('grid_link.html', array(
+            'href' => $this->_oModule->serviceGetLink($aRow['id']),
+            'title' => bx_replace_markers($aRow['description'], array(
+                'profile_name' => $oProfile->getDisplayName()
+            ))
+        ));
+
+        return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow);
+    }
+
+    protected function _getCellOwnerId($mixedValue, $sKey, $aField, $aRow)
+    {
+        $iProfile = $this->_oModule->_oConfig->isSystem($aRow['type'], $aRow['action']) ? $aRow['owner_id'] : $aRow['object_id'];
+    	$oProfile = $this->_getProfileObject($iProfile);
+    	$sProfile = $oProfile->getDisplayName();
+
+    	$sAccountEmail = '';
+    	$sManageAccountUrl = '';
+    	if($oProfile && $oProfile instanceof BxDolProfile && BxDolAcl::getInstance()->isMemberLevelInSet(128)) {
+            $sAccountEmail = $oProfile->getAccountObject()->getEmail();
+            $sManageAccountUrl = $this->_getManageAccountUrl($sAccountEmail);
+    	}
+
+        $mixedValue = $this->_oTemplate->parseHtmlByName('author_link.html', array(
+            'href' => $oProfile->getUrl(),
+            'title' => $sProfile,
+            'content' => $sProfile,
+            'bx_if:show_account' => array(
+                'condition' => !empty($sManageAccountUrl), 
+                'content' => array(
+                    'href' => $sManageAccountUrl,
+                    'title' => _t($this->_oModule->_oConfig->CNF['T']['grid_txt_account_manager']),
+                    'content' => $sAccountEmail
+                )
+            )
+        ));
+
+        return parent::_getCellDefault($mixedValue, $sKey, $aField, $aRow);
+    }
+}
+
+/** @} */

+ 279 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineMenuItemActions.php

@@ -0,0 +1,279 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * 'Item' menu.
+ */
+class BxTimelineMenuItemActions extends BxTemplMenuCustom
+{
+    protected $_oModule;
+
+    protected $_iEvent;
+    protected $_aEvent;
+
+    protected $_sType;
+    protected $_sView;
+    protected $_bShowTitles;
+
+    public function __construct($aObject, $oTemplate = false)
+    {
+        $this->_oModule = BxDolModule::getInstance('bx_timeline');
+
+        parent::__construct($aObject, $this->_oModule->_oTemplate);
+
+        $this->_setBrowseParams();
+
+        $this->_bShowTitles = false;
+    }
+
+    public function setEvent($aEvent, $aBrowseParams = array())
+    {
+        if(empty($aEvent) || !is_array($aEvent))
+            return;
+
+        $this->_aEvent = $aEvent;
+        $this->_iEvent = (int)$this->_aEvent['id'];
+
+        $this->_setBrowseParams($aBrowseParams);
+
+        $iCommentsObject = 0;
+        $sCommentsSystem = $sCommentsOnclick = '';
+        if(isset($aEvent['comments']) && is_array($aEvent['comments']) && isset($aEvent['comments']['system'])) {
+            $sCommentsSystem = $aEvent['comments']['system'];
+            $iCommentsObject = $aEvent['comments']['object_id'];
+            $sCommentsOnclick = bx_replace_markers("{js_object_view}.commentItem(this, '" . $sCommentsSystem . "', " . $iCommentsObject . ")", $this->_aMarkers);
+        }
+
+        $this->addMarkers(array(
+            'content_id' => $this->_iEvent,
+
+            'comment_system' => $sCommentsSystem,
+            'comment_object' => $iCommentsObject,
+            'comment_onclick' => $sCommentsOnclick,
+        ));
+    }
+
+    public function setEventById($iEventId, $aBrowseParams = array())
+    {
+    	$aEvent = $this->_oModule->_oDb->getEvents(array('browse' => 'id', 'value' => $iEventId));
+    	if(empty($aEvent) || !is_array($aEvent))
+            return;
+
+    	$aEventData = $this->_oModule->_oTemplate->getDataCached($aEvent);
+    	if($aEventData === false)
+            return;
+
+    	$aEvent['views'] = $aEventData['views'];
+        $aEvent['votes'] = $aEventData['votes'];
+        $aEvent['reactions'] = $aEventData['reactions'];
+        $aEvent['scores'] = $aEventData['scores'];
+        $aEvent['reports'] = $aEventData['reports'];
+        $aEvent['comments'] = $aEventData['comments'];
+
+    	$this->setEvent($aEvent, $aBrowseParams);
+    }
+
+    protected function _setBrowseParams($aBrowseParams = array())
+    {
+        $this->_sType = !empty($aBrowseParams['type']) ? $aBrowseParams['type'] : BX_TIMELINE_TYPE_DEFAULT;
+        $this->_sView = !empty($aBrowseParams['view']) ? $aBrowseParams['view'] : BX_TIMELINE_VIEW_DEFAULT;
+
+        $aMarkers = array();
+        foreach($aBrowseParams as $sKey => $mixedValue)
+            if(!is_array($mixedValue))
+                $aMarkers[$sKey] = $mixedValue;
+
+        $this->addMarkers($aMarkers);
+        $this->addMarkers(array(
+            'js_object_view' => $this->_oModule->_oConfig->getJsObjectView($aBrowseParams)
+        ));
+    }
+
+    protected function _getMenuItemItemView($aItem)
+    {
+        if(!isset($this->_aEvent['views']) || !is_array($this->_aEvent['views']) || !isset($this->_aEvent['views']['system'])) 
+            return false;
+
+        $sViewsSystem = $this->_aEvent['views']['system'];
+        $iViewsObject = $this->_aEvent['views']['object_id'];
+        $aViewsParams = array('dynamic_mode' => $this->_bDynamicMode);
+        if($this->_bShowTitles)
+            $aViewsParams['show_do_view_label'] = true;
+
+        return $this->_oModule->getViewObject($sViewsSystem, $iViewsObject)->getElementInline($aViewsParams);
+    }
+
+    protected function _getMenuItemItemComment($aItem)
+    {
+        if($this->_sView == BX_TIMELINE_VIEW_ITEM)
+            return false;
+
+        $aItem = BxTemplMenu::_getMenuItem($aItem);
+        if($aItem === false)
+            return false;
+
+        return $this->_getMenuItemDefault($aItem);
+    }
+
+    protected function _getMenuItemItemVote($aItem)
+    {
+        if(!isset($this->_aEvent['votes']) || !is_array($this->_aEvent['votes']) || !isset($this->_aEvent['votes']['system'])) 
+            return false;
+
+        $sVotesSystem = $this->_aEvent['votes']['system'];
+        $iVotesObject = $this->_aEvent['votes']['object_id'];
+        $aVotesParams = array('dynamic_mode' => $this->_bDynamicMode);
+        if($this->_bShowTitles)
+            $aVotesParams['show_do_vote_label'] = true;
+
+        return $this->_oModule->getVoteObject($sVotesSystem, $iVotesObject)->getElementInline($aVotesParams);
+    }
+
+    protected function _getMenuItemItemReaction($aItem)
+    {
+        if(!isset($this->_aEvent['reactions']) || !is_array($this->_aEvent['reactions']) || !isset($this->_aEvent['reactions']['system'])) 
+            return false;
+
+        $sReactionsSystem = $this->_aEvent['reactions']['system'];
+        $iReactionsObject = $this->_aEvent['reactions']['object_id'];
+        $aReactionsParams = array('dynamic_mode' => $this->_bDynamicMode);
+        if($this->_bShowTitles)
+            $aReactionsParams['show_do_vote_label'] = true;
+
+    	return $this->_oModule->getReactionObject($sReactionsSystem, $iReactionsObject)->getElementInline($aReactionsParams);
+    }
+
+    protected function _getMenuItemItemScore($aItem)
+    {
+        if(!isset($this->_aEvent['scores']) || !is_array($this->_aEvent['scores']) || !isset($this->_aEvent['scores']['system'])) 
+            return false;
+
+        $sScoresSystem = $this->_aEvent['scores']['system'];
+        $iScoresObject = $this->_aEvent['scores']['object_id'];
+        $aScoresParams = array('dynamic_mode' => $this->_bDynamicMode);
+        if($this->_bShowTitles)
+            $aScoresParams['show_do_vote_label'] = true;
+
+        return $this->_oModule->getScoreObject($sScoresSystem, $iScoresObject)->getElementInline($aScoresParams);
+    }
+
+    protected function _getMenuItemItemReport($aItem)
+    {
+        if(!isset($this->_aEvent['reports']) || !is_array($this->_aEvent['reports']) || !isset($this->_aEvent['reports']['system'])) 
+            return false;
+
+        $sReportsSystem = $this->_aEvent['reports']['system'];
+        $iReportsObject = $this->_aEvent['reports']['object_id'];
+        $aReportsParams = array('dynamic_mode' => $this->_bDynamicMode);
+        if($this->_bShowTitles)
+            $aReportsParams['show_do_report_label'] = true;
+
+        return $this->_oModule->getReportObject($sReportsSystem, $iReportsObject)->getElementInline($aReportsParams);
+    }
+
+    protected function _getMenuItemDefault ($aItem)
+    {
+        if(!isset($aItem['class_link']))
+            $aItem['class_link'] = '';
+
+        $aItem['class_link'] = 'bx-menu-item-link' . (!empty($aItem['class_link']) ? ' ' : '') . $aItem['class_link'];
+
+        return parent::_getMenuItemDefault ($aItem);
+    }
+
+    /**
+     * Check if menu items is visible.
+     * @param $a menu item array
+     * @return boolean
+     */
+    protected function _isVisible ($a)
+    {
+        if(!parent::_isVisible($a) || empty($this->_aEvent) || !is_array($this->_aEvent))
+            return false;
+
+        $sCheckFuncName = '';
+        $aCheckFuncParams = array($this->_aEvent);
+        switch ($a['name']) {
+            case 'item-view':
+                $sCheckFuncName = 'isAllowedViewCounter';
+                break;
+
+            case 'item-comment':
+                $sCheckFuncName = 'isAllowedComment';
+                break;
+
+            case 'item-vote':
+                $sCheckFuncName = 'isAllowedVote';
+                break;
+            
+            case 'item-reaction':
+                $sCheckFuncName = 'isAllowedReaction';
+                break;
+
+            case 'item-score':
+                $sCheckFuncName = 'isAllowedScore';
+                break;
+
+            case 'item-report':
+                $sCheckFuncName = 'isAllowedReport';
+                break;
+
+            case 'item-more':
+            	$sCheckFuncName = 'isAllowedMore';
+            	break;
+
+            case 'item-pin':
+                if($this->_sType != BX_BASE_MOD_NTFS_TYPE_OWNER)
+                    return false;
+
+                $sCheckFuncName = 'isAllowedPin';
+                break;
+
+            case 'item-unpin':
+                if($this->_sType != BX_BASE_MOD_NTFS_TYPE_OWNER)
+                    return false;
+
+                $sCheckFuncName = 'isAllowedUnpin';
+                break;
+
+            case 'item-stick':
+                $sCheckFuncName = 'isAllowedStick';
+                break;
+
+            case 'item-unstick':
+                $sCheckFuncName = 'isAllowedUnstick';
+                break;
+
+            case 'item-promote':
+                $sCheckFuncName = 'isAllowedPromote';
+                break;
+
+			case 'item-unpromote':
+                $sCheckFuncName = 'isAllowedUnpromote';
+                break;
+
+            case 'item-edit':
+                $sCheckFuncName = 'isAllowedEdit';
+                break;
+
+            case 'item-delete':
+                $sCheckFuncName = 'isAllowedDelete';
+                break;
+        }
+
+        if(!$sCheckFuncName || !method_exists($this->_oModule, $sCheckFuncName))
+            return true;
+
+        return call_user_func_array(array($this->_oModule, $sCheckFuncName), $aCheckFuncParams) === true;
+    }
+}
+
+/** @} */

+ 40 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineMenuItemManage.php

@@ -0,0 +1,40 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+require_once('BxTimelineMenuItemActions.php');
+
+/**
+ * 'Item' menu.
+ */
+class BxTimelineMenuItemManage extends BxTimelineMenuItemActions
+{
+    public function __construct($aObject, $oTemplate = false)
+    {
+        parent::__construct($aObject, $oTemplate);
+
+        $this->setDynamicMode(true);
+
+        $iContentId = 0;
+        if(bx_get('content_id') !== false)
+            $iContentId = bx_process_input(bx_get('content_id'), BX_DATA_INT);
+
+        $aBrowseParams = array('name' => '', 'view' => '', 'type' => '');
+        foreach($aBrowseParams as $sKey => $sValue)
+            if(bx_get($sKey) !== false)
+                $aBrowseParams[$sKey] = bx_process_input(bx_get($sKey));
+
+        $this->setEventById($iContentId, $aBrowseParams);
+
+        $this->_bShowTitles = true;
+    }
+}
+
+/** @} */

+ 159 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineMenuItemShare.php

@@ -0,0 +1,159 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * 'Item' menu.
+ */
+class BxTimelineMenuItemShare extends BxTemplMenu
+{
+    protected $_oModule;
+
+    protected $_iEvent;
+    protected $_aEvent;
+
+    public function __construct($aObject, $oTemplate = false)
+    {
+        parent::__construct($aObject, $oTemplate);
+
+        $this->_oModule = BxDolModule::getInstance('bx_timeline');
+
+        $iContentId = 0;
+        if(bx_get('content_id') !== false)
+            $iContentId = bx_process_input(bx_get('content_id'), BX_DATA_INT);
+
+        $aBrowseParams = array('name' => '', 'view' => '', 'type' => '');
+        foreach($aBrowseParams as $sKey => $sValue)
+            if(bx_get($sKey) !== false)
+                $aBrowseParams[$sKey] = bx_process_input(bx_get($sKey));
+
+        $this->setEventById($iContentId, $aBrowseParams);
+    }
+
+    public function setEventById($iEventId, $aBrowseParams = array())
+    {
+    	$this->_iEvent = $iEventId;
+    	$this->_aEvent = $this->_oModule->_oDb->getEvents(array('browse' => 'id', 'value' => $this->_iEvent));
+
+        $this->_setBrowseParams($aBrowseParams);
+
+        $sRepostOnclick = $sEtSend = '';
+        if(!empty($this->_aEvent) && is_array($this->_aEvent)) {
+            $sType = $this->_aEvent['type'];
+            $sAction = $this->_aEvent['action'];
+
+            $this->_aEvent['url'] = $this->_oModule->_oConfig->getItemViewUrl($this->_aEvent);
+            if($this->_oModule->_oConfig->isSystem($sType, $sAction)) {
+                $aResult = $this->_oModule->_oConfig->getSystemData($this->_aEvent);
+                if(!empty($aResult['url']))
+                    $this->_aEvent['url'] = $aResult['url'];
+            }
+
+            //--- Repost item
+            $iOwnerId = $this->_oModule->getUserId(); //--- in whose timeline the content will be reposted
+            $iObjectId = $this->_oModule->_oConfig->isSystem($sType, $sAction) ? $this->_aEvent['object_id'] : $this->_aEvent['id'];
+            $sRepostOnclick = $this->_oModule->serviceGetRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId);
+
+            //--- Send item
+    	    $sAetSend = urlencode(base64_encode(serialize(array(
+    	        'name' => 'bx_timeline_send',
+    	        'params' => array(
+    	            'ViewLink' => $this->_aEvent['url']
+    	        )
+    	    )))); 
+        }
+
+    	$this->addMarkers(array(
+            'content_id' => $this->_iEvent,
+            'content_url' => $this->_aEvent['url'],
+
+            'js_onclick_repost' => $sRepostOnclick,
+            'et_send' => $sAetSend
+    	));
+    }
+
+    public function getMenuItems ()
+    {
+        $aItems = parent::getMenuItems();
+
+        $aMarkers = array(
+            'id' => $this->_iEvent,
+            'module' => $this->_oModule->_oConfig->getName(),
+            'url' => $this->_aEvent['url'],
+            'title' => $this->_aEvent['title'],
+            'img_url' => '',
+            'img_url_encoded' => ''
+        );
+
+        $aEventData = $this->_oModule->_oTemplate->getDataCached($this->_aEvent);
+        if(!empty($aEventData['content']['images']) && is_array($aEventData['content']['images'])) {
+            $aImage = array_shift($aEventData['content']['images']);
+
+            $sImgUrl = isset($aImage['src_medium']) ? $aImage['src_medium'] : $aImage['src'];;
+            if(!empty($sImgUrl))
+                $aMarkers = array_merge($aMarkers, array(
+                    'img_url' => $sImgUrl,
+                    'img_url_encoded' => rawurlencode($sImgUrl),
+                ));
+        }
+
+        $oSocial = BxDolMenu::getObjectInstance('sys_social_sharing');
+        $oSocial->addMarkers($aMarkers);
+        return array_merge($aItems, $oSocial->getMenuItems());
+    }
+
+    protected function _setBrowseParams($aBrowseParams = array())
+    {
+        $aMarkers = array();
+        foreach($aBrowseParams as $sKey => $mixedValue)
+            if(!is_array($aMarkers))
+                $aMarkers[$sKey] = $mixedValue;
+
+        $this->addMarkers($aMarkers);
+        $this->addMarkers(array(
+            'js_object_view' => $this->_oModule->_oConfig->getJsObjectView($aBrowseParams)
+        ));
+    }
+
+    /**
+     * Check if menu items is visible.
+     * @param $a menu item array
+     * @return boolean
+     */
+    protected function _isVisible ($a)
+    {
+        if(!parent::_isVisible($a))
+            return false;
+
+        if(empty($this->_aEvent) || !is_array($this->_aEvent))
+            return false;
+
+        $sCheckFuncName = '';
+        $aCheckFuncParams = array();
+        switch ($a['name']) {
+            case 'item-repost':
+                $sCheckFuncName = 'isAllowedRepost';
+                $aCheckFuncParams = array($this->_aEvent);
+                break;
+
+            case 'item-send':
+                $sCheckFuncName = 'isAllowedSend';
+                $aCheckFuncParams = array($this->_aEvent);
+                break;
+        }
+
+        if(!$sCheckFuncName || !method_exists($this->_oModule, $sCheckFuncName))
+            return true;
+
+        return call_user_func_array(array($this->_oModule, $sCheckFuncName), $aCheckFuncParams) === true;
+    }
+}
+
+/** @} */

+ 3640 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineModule.php

@@ -0,0 +1,3640 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+bx_import('BxDolAcl');
+bx_import('BxBaseModNotificationsModule');
+
+define('BX_TIMELINE_TYPE_ITEM', 'view_item');
+define('BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS', 'owner_and_connections');
+define('BX_TIMELINE_TYPE_HOT', 'hot');
+define('BX_TIMELINE_TYPE_DEFAULT', BX_BASE_MOD_NTFS_TYPE_OWNER);
+
+define('BX_TIMELINE_VIEW_ITEM', 'item');
+define('BX_TIMELINE_VIEW_TIMELINE', 'timeline');
+define('BX_TIMELINE_VIEW_OUTLINE', 'outline');
+define('BX_TIMELINE_VIEW_SEARCH', 'search');
+define('BX_TIMELINE_VIEW_DEFAULT', BX_TIMELINE_VIEW_OUTLINE);
+
+define('BX_TIMELINE_FILTER_ALL', 'all');
+define('BX_TIMELINE_FILTER_OWNER', 'owner');
+define('BX_TIMELINE_FILTER_OTHER', 'other');
+define('BX_TIMELINE_FILTER_OTHER_VIEWER', 'other_viewer');
+
+define('BX_TIMELINE_PARSE_TYPE_POST', 'post');
+define('BX_TIMELINE_PARSE_TYPE_REPOST', 'repost');
+define('BX_TIMELINE_PARSE_TYPE_DEFAULT', BX_TIMELINE_PARSE_TYPE_POST);
+
+define('BX_TIMELINE_STATUS_ACTIVE', 'active');
+define('BX_TIMELINE_STATUS_AWAITING', 'awaiting');
+define('BX_TIMELINE_STATUS_FAILED', 'failed');
+define('BX_TIMELINE_STATUS_HIDDEN', 'hidden');
+define('BX_TIMELINE_STATUS_DELETED', 'deleted');
+
+define('BX_TIMELINE_MEDIA_PHOTO', 'photo');
+define('BX_TIMELINE_MEDIA_VIDEO', 'video');
+
+//--- Video Auto Play 
+define('BX_TIMELINE_VAP_OFF', 'off');
+define('BX_TIMELINE_VAP_ON_MUTE', 'on_mute');
+define('BX_TIMELINE_VAP_ON', 'on');
+
+class BxTimelineModule extends BxBaseModNotificationsModule implements iBxDolContentInfoService
+{
+    protected $_sJsPostObject;
+    protected $_sJsViewObject;
+    protected $_aPostElements;
+    protected $_sJsOutlineObject;
+
+    protected $_sDividerTemplate;
+    protected $_sBalloonTemplate;
+    protected $_sCmtPostTemplate;
+    protected $_sCmtViewTemplate;
+    protected $_sCmtTemplate;
+
+    /**
+     * Constructor
+     */
+    function __construct($aModule)
+    {
+        parent::__construct($aModule);
+    }
+
+    /**
+     * ACTION METHODS
+     */
+    public function actionVideo($iEventId, $iVideoId)
+    {
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iEventId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return;
+
+        $aData = $this->_oTemplate->getDataCached($aEvent);
+        if($aData === false || !isset($aData['content']['videos'][$iVideoId]))
+            return;
+
+        $oTemplate = $this->_oTemplate;
+        $oTemplate->setPageNameIndex (BX_PAGE_CLEAR);
+        $oTemplate->setPageContent ('page_main_code', $this->_oTemplate->getVideo($aEvent, $aData['content']['videos'][$iVideoId]));
+        $oTemplate->getPageCode();
+    }
+
+    public function actionPost()
+    {
+        $this->_iOwnerId = bx_process_input(bx_get('owner_id'), BX_DATA_INT);
+
+        $mixedAllowed = $this->isAllowedPost(true);
+        if($mixedAllowed !== true)
+            return echoJson(array('message' => strip_tags($mixedAllowed)));
+
+        echoJson($this->getFormPost());
+    }
+
+    public function actionEdit($iId)
+    {
+        $this->_iOwnerId = bx_process_input(bx_get('owner_id'), BX_DATA_INT);
+
+        $aBrowseParams = array();
+        if(bx_get('bp') !== false)
+            $aBrowseParams = $this->_oConfig->getBrowseParams(bx_process_input(bx_get('bp')));
+
+        $mixedAllowed = $this->isAllowedPost(true);
+        if($mixedAllowed !== true)
+            return echoJson(array('message' => strip_tags($mixedAllowed)));
+
+        echoJson($this->getFormEdit($iId, array('dynamic_mode' => true), $aBrowseParams));
+    }
+
+    function actionPin()
+    {
+        $iId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return echoJson(array('code' => 1));
+
+        $aParams = $this->_prepareParamsGet();
+        $this->_iOwnerId = $aParams['owner_id'];
+        
+        $mixedAllowed = $this->{'isAllowed' . ((int)$aEvent['pinned'] == 0 ? 'Pin' : 'Unpin')}($aEvent, true);
+        if($mixedAllowed !== true)
+            return echoJson(array('code' => 2, 'message' => strip_tags($mixedAllowed)));
+
+        $aEvent['pinned'] = (int)$aEvent['pinned'] == 0 ? time() : 0;
+        if(!$this->_oDb->updateEvent(array('pinned' => $aEvent['pinned']), array('id' => $iId)))
+            return echoJson(array('code' => 3));
+
+        echoJson(array(
+            'code' => 0, 
+            'id' => $iId, 
+            'eval' => $this->_oConfig->getJsObjectView($aParams) . '.onPinPost(oData)'
+        ));
+    }
+
+    function actionStick()
+    {
+    	$iId = bx_process_input(bx_get('id'), BX_DATA_INT);
+    	$aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return echoJson(array('code' => 1));
+
+        $aParams = $this->_prepareParamsGet();
+        $this->_iOwnerId = $aParams['owner_id'];
+
+    	$mixedAllowed = $this->{'isAllowed' . ((int)$aEvent['sticked'] == 0 ? 'Stick' : 'Unstick')}($aEvent, true);
+    	if($mixedAllowed !== true)
+            return echoJson(array('code' => 2, 'message' => strip_tags($mixedAllowed)));
+
+    	$aEvent['sticked'] = (int)$aEvent['sticked'] == 0 ? time() : 0;
+    	if(!$this->_oDb->updateEvent(array('sticked' => $aEvent['sticked']), array('id' => $iId)))
+            return echoJson(array('code' => 3));
+
+    	echoJson(array(
+            'code' => 0,
+            'id' => $iId,
+            'eval' => $this->_oConfig->getJsObjectView($aParams) . '.onStickPost(oData)'
+        ));
+    }
+
+    function actionPromote()
+    {
+        $this->_iOwnerId = bx_process_input(bx_get('owner_id'), BX_DATA_INT);
+
+        $iId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+
+        $sAction = (int)$aEvent['promoted'] == 0 ? 'promote' : 'unpromote';
+
+        $mixedAllowed = $this->{'isAllowed' . ucfirst($sAction)}($aEvent, true);
+        if($mixedAllowed !== true)
+            return echoJson(array('code' => 1, 'message' => strip_tags($mixedAllowed)));
+
+        $aEvent['promoted'] = (int)$aEvent['promoted'] == 0 ? time() : 0;
+        if(!$this->_oDb->updateEvent(array('promoted' => $aEvent['promoted']), array('id' => $iId)))
+            return echoJson(array('code' => 2));
+
+        bx_alert($this->_oConfig->getObject('alert'), $sAction . 'd', $iId, (int)$this->getUserId(), array(
+            'owner_id' => $aEvent['owner_id'],
+            'object_id' => $aEvent['object_id'],
+            'object_author_id' => $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? $aEvent['owner_id'] : $aEvent['object_id']
+        ));
+
+        echoJson(array(
+            'code' => 0, 
+            'message' => _t('_bx_timeline_txt_msg_performed_action')
+        ));
+    }
+
+    function actionDelete()
+    {
+        $iId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return echoJson(array('code' => 1));
+
+        $aParams = $this->_prepareParamsGet();
+        $this->_iOwnerId = $aParams['owner_id'];
+
+        $mixedAllowed = $this->isAllowedDelete($aEvent, true);
+        if($mixedAllowed !== true)
+            return echoJson(array('code' => 2, 'message' => strip_tags($mixedAllowed)));
+
+        if(!$this->deleteEvent($aEvent))
+            return echoJson(array('code' => 3));
+
+        $this->_oDb->deleteCache(array('event_id' => $iId));
+
+        echoJson(array(
+            'code' => 0, 
+            'id' => $aEvent['id'], 
+            'eval' => $this->_oConfig->getJsObjectView($aParams) . '.onDeletePost(oData)'
+        ));
+    }
+
+    public function actionRepost()
+    {
+    	$iAuthorId = $this->getUserId();
+        $iOwnerId = bx_process_input(bx_get('owner_id'), BX_DATA_INT);
+        $sType = bx_process_input(bx_get('type'), BX_DATA_TEXT);
+        $sAction = bx_process_input(bx_get('action'), BX_DATA_TEXT);
+        $iObjectId = bx_process_input(bx_get('object_id'), BX_DATA_INT);
+
+        $aResult = $this->serviceRepost($iAuthorId, $iOwnerId, $sType, $sAction, $iObjectId);
+        if(!empty($aResult) && is_array($aResult))
+            return echoJson($aResult);
+
+        $aReposted = $this->_oDb->getReposted($sType, $sAction, $iObjectId);
+        $sCounter = $this->_oTemplate->getRepostCounter($aReposted);
+
+        echoJson(array(
+            'code' => 0, 
+            'message' => _t('_bx_timeline_txt_msg_success_repost'), 
+            'count' => $aReposted['reposts'], 
+            'countf' => (int)$aReposted['reposts'] > 0 ? $this->_oTemplate->getRepostCounterLabel($aReposted['reposts']) : '',
+            'counter' => $sCounter,
+            'disabled' => true
+        ));
+    }
+
+    function actionGetPost()
+    {
+        $aParams = $this->_prepareParamsGet();
+        $aParams['dynamic_mode'] = true;
+
+        $this->_iOwnerId = $aParams['owner_id'];
+
+        $sJsObject = ''; 
+        if(bx_get('js_object') !== false)
+            $sJsObject = bx_process_input(bx_get('js_object'));
+        if(empty($sJsObject))
+            $sJsObject = $this->_oConfig->getJsObject('post');
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => bx_process_input(bx_get('id'), BX_DATA_INT)));
+        if(empty($aEvent) || !is_array($aEvent))
+            return echoJson(array());
+
+        /**
+         * Note. Disabled for now, because Own posts on Timelines of Following members 
+         * became visible on posts' author Dashboard Timeline.
+         */
+        /*
+        $bAfpsLoading = (int)bx_get('afps_loading') === 1;
+        if($bAfpsLoading && $this->_iOwnerId != $aEvent['owner_id'])
+            return echoJson(array('message' => _t('_bx_timeline_txt_msg_posted')));
+        */
+
+        echoJson(array(
+            'id' => $aEvent['id'],
+            'name' => $aParams['name'],
+            'view' => $aParams['view'],
+            'type' => $aParams['type'],
+            'item' => $this->_oTemplate->getPost($aEvent, $aParams),
+            'eval' => $sJsObject . "._onGetPost(oData)"
+        ));
+    }
+
+    function actionGetPosts()
+    {
+        $aParams = $this->_prepareParamsGet();
+        list($sItems, $sLoadMore, $sBack, $sEmpty) = $this->_oTemplate->getPosts($aParams);
+
+        echoJson(array(
+            'view' => $aParams['view'],
+            'items' => $sItems, 
+            'load_more' => $sLoadMore, 
+            'back' => $sBack,
+            'empty' => $sEmpty,
+            'eval' => $this->_oConfig->getJsObjectView($aParams) . "._onGetPosts(oData)"
+        ));
+    }
+
+    public function actionGetPostForm()
+    {
+        $this->_iOwnerId = bx_process_input(bx_get('owner_id'), BX_DATA_INT);
+        $sType = bx_process_input(bx_get('type'));
+
+        echoJson($this->getFormPost(array(
+            'type' => $sType,
+            'form_display' => $this->_oConfig->getPostFormDisplay($sType)
+        )));
+    }
+
+    public function actionGetEditForm($iId)
+    {
+        $aParams = $this->_prepareParamsGet();
+        $this->_iOwnerId = $aParams['owner_id'];
+
+        echoJson($this->getFormEdit($iId, array('dynamic_mode' => true), $aParams));
+    }
+
+    public function actionGetComments()
+    {
+        $this->_iOwnerId = bx_process_input(bx_get('owner_id'), BX_DATA_INT);
+
+        $sSystem = bx_process_input(bx_get('system'), BX_DATA_TEXT);
+        $iId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        $sComments = $this->_oTemplate->getComments($sSystem, $iId, array('dynamic_mode' => true));
+
+        echoJson(array('content' => $sComments));
+    }
+
+    public function actionAddAttachLink()
+    {
+        $sUrl = bx_process_input(bx_get('url'));
+        if(empty($sUrl))
+            return echoJson(array());
+
+        echoJson($this->addAttachLink(array(
+            'url' => $sUrl
+        )));
+    }
+
+    public function actionDeleteAttachLink()
+    {
+    	$iUserId = $this->getUserId();
+        $iLinkId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        if(empty($iLinkId)) {
+            echoJson(array());
+            return;
+        }
+
+        $aLink = $this->_oDb->getUnusedLinks($iUserId, $iLinkId);
+    	if(empty($aLink) || !is_array($aLink)) {
+            echoJson(array());
+            return;
+        }
+
+		if(!empty($aLink['media_id']))
+			BxDolStorage::getObjectInstance($this->_oConfig->getObject('storage_photos'))->deleteFile($aLink['media_id']);
+
+        $aResult = array();
+        if($this->_oDb->deleteUnusedLinks($iUserId, $iLinkId))
+            $aResult = array('code' => 0);
+        else
+            $aResult = array('code' => 1, 'message' => _t('_bx_timeline_form_post_input_link_err_delete'));
+
+        echoJson($aResult);
+    }
+
+    public function actionGetAttachLinkForm()
+    {
+        echo $this->_oTemplate->getAttachLinkForm();
+    }
+
+    public function actionSubmitAttachLinkForm()
+    {
+        echoJson($this->getFormAttachLink());
+    }
+
+    public function actionGetRepostedBy()
+    {
+        $iRepostedId = bx_process_input(bx_get('id'), BX_DATA_INT);
+
+        echo $this->_oTemplate->getRepostedBy($iRepostedId);
+    }
+
+    public function actionGetItemBrief()
+    {
+        echo BxDolPage::getObjectInstance($this->_oConfig->getObject('page_item_brief'), $this->_oTemplate)->getCode();
+    }
+
+    public function actionResumeLiveUpdate()
+    {
+        $aParams = $this->_prepareParamsGet();
+    	$sKey = $this->_oConfig->getLiveUpdateKey($aParams);
+
+    	bx_import('BxDolSession');
+    	BxDolSession::getInstance()->unsetValue($sKey);
+    }
+
+    public function actionPauseLiveUpdate()
+    {
+        $aParams = $this->_prepareParamsGet();
+    	$sKey = $this->_oConfig->getLiveUpdateKey($aParams);
+
+    	bx_import('BxDolSession');
+    	BxDolSession::getInstance()->setValue($sKey, 1);
+    }
+
+    function actionRss()
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $aArgs = func_get_args();
+
+        $sType = array_shift($aArgs);
+        $iOwnerId = 0;
+
+        switch($sType) {
+            case BX_BASE_MOD_NTFS_TYPE_OWNER:
+                $iOwnerId = array_shift($aArgs);
+                list($sUserName) = $this->getUserInfo($iOwnerId);
+
+                $sRssCaption = _t('_bx_timeline_txt_rss_caption', $sUserName);
+                $sRssLink = $this->_oConfig->getViewUrl($iOwnerId);
+                break;
+
+            case BX_BASE_MOD_NTFS_TYPE_PUBLIC:
+                $sRssCaption = _t('_bx_timeline_page_title_view_home');
+                $sRssLink = $this->_oConfig->getHomeViewUrl();
+                break;
+        }
+
+        $aParams = $this->_prepareParams(array(
+            'view' => BX_TIMELINE_VIEW_DEFAULT,
+            'type' => $sType,
+            'owner_id' => $iOwnerId,
+            'start' => 0, 
+            'per_page' => $this->_oConfig->getRssLength(), 
+            'timeline' => 0, 
+            'filter' => '', 
+            'modules' => array()
+        ));
+        $aEvents = $this->_oDb->getEvents($aParams);
+
+        $oPrivacy = BxDolPrivacy::getObjectInstance($this->_oConfig->getObject('privacy_view'));
+
+        $aRssData = array();
+        foreach($aEvents as $aEvent) {
+            if(empty($aEvent['title'])) 
+                continue;
+
+            $iEventId = (int)$aEvent[$CNF['FIELD_ID']];
+            $sEventFieldAuthor = $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? 'owner_id' : 'object_id';
+
+            if($oPrivacy) {
+                $oPrivacy->setTableFieldAuthor($sEventFieldAuthor);
+                if(!$oPrivacy->check($iEventId))
+                    continue;
+            }
+
+            $iOwner = $aEvent[$sEventFieldAuthor];
+            $oOwner = BxDolProfile::getInstanceMagic($iOwner);
+
+            $aRssData[$iEventId] = array(
+               'UnitID' => $iEventId,
+               'UnitTitle' => $aEvent['title'],
+               'UnitLink' => $this->_oConfig->getItemViewUrl($aEvent),
+               'UnitDesc' => bx_replace_markers($aEvent['description'], array(
+                    'profile_name' => $oOwner->getDisplayName()
+                )),
+               'UnitDateTimeUTS' => $aEvent['date'],
+            );
+        }
+
+        $oRss = new BxDolRssFactory();
+
+        header('Content-Type: application/xml; charset=utf-8');
+        echo $oRss->GenRssByData($aRssData, $sRssCaption, $sRssLink);
+    }
+
+
+    /**
+     * SERVICE METHODS
+     */
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_create_post_form get_create_post_form
+     * 
+     * @code bx_srv('bx_timeline', 'get_create_post_form', [...]); @endcode
+     * 
+     * Get form code for add content. Is needed for United Post Form.
+     * 
+     * @param $aParams optional array with parameters(display name, etc)
+     * @return form code or error
+     * 
+     * @see BxTimelineModule::serviceGetCreatePostForm
+     */
+    /** 
+     * @ref bx_timeline-get_create_post_form "get_create_post_form"
+     */
+    public function serviceGetCreatePostForm($aParams = array())
+    {
+    	$aParams = array_merge($this->_aFormParams, $aParams);
+
+        $this->_iOwnerId = $aParams['context_id'];
+
+    	$oForm = $this->serviceGetObjectForm('add', $aParams);
+    	if(!$oForm)
+            return '';
+
+        if(!empty($aParams['display']))
+            $aParams['form_display'] = $aParams['display'];
+        else if(isset($aParams['context_id'])) {
+            if((int)$aParams['context_id'] == 0)
+                $aParams['form_display'] = 'form_display_post_add_public';
+            else
+                $aParams['form_display'] = 'form_display_post_add_profile';
+        }
+
+    	$aResult = $this->getFormPost($aParams);
+    	if(!empty($aResult['form'])) {
+            $bDynamicMode = isset($aParams['dynamic_mode']) && $aParams['dynamic_mode'];
+
+            $sCode = '';
+            $sCode .= $this->_oTemplate->getCssJs($bDynamicMode);
+            $sCode .= $this->_oTemplate->getJsCodePost($this->_iOwnerId);
+            $sCode .= $aResult['form'];
+            return $sCode;
+        }
+
+        if(!empty($aResult['message']))
+                return $aResult['message'];
+
+        return '';
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_object_form get_object_form
+     * 
+     * @code bx_srv('bx_timeline', 'get_object_form', [...]); @endcode
+     * 
+     * Get form object for add, edit, view or delete the content.
+     * 
+     * @param $sType 'add' is supported only 
+     * @param $aParams optional array with parameters(display name, etc)
+     * @return form object or false on error
+     * 
+     * @see BxTimelineModule::serviceGetObjectForm
+     */
+    /** 
+     * @ref bx_timeline-get_object_form "get_object_form"
+     */
+    public function serviceGetObjectForm ($sType, $aParams = array())
+    {
+    	if (!in_array($sType, array('add')))
+            return false;
+
+        $CNF = &$this->_oConfig->CNF;
+
+        if(!empty($aParams['display']))
+            $aParams['form_display'] = $aParams['display'];
+        else if(isset($aParams['context_id'])) {
+            if((int)$aParams['context_id'] == 0)
+                $aParams['form_display'] = 'form_display_post_add_public';
+            else
+                $aParams['form_display'] = 'form_display_post_add_profile';
+        }
+
+        $oForm = $this->getFormPostObject($aParams);
+
+        bx_alert('system', 'get_object_form', 0, 0, array(
+            'module' => $this->_oConfig->getName(),
+            'type' => $sType,
+            'params' => $aParams,
+            'form' => &$oForm
+        ));
+
+    	return $oForm;
+    }
+    
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection get_timeline_post
+     * @see BxTimelineModule::serviceGetTimelinePost
+     *
+     * Get Timeline post. It's needed for Timeline module.
+     * 
+     * @param $aEvent timeline event array from Timeline module
+     * @return array in special format which is needed specifically for Timeline module to display the data.
+     */
+    public function serviceGetTimelinePost($aEvent, $aBrowseParams = array())
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        /*
+         * Note. For 'Direct Timeline Posts' FIELD_OBJECT_ID contains post's author profile ID.
+         */
+        $CNF['FIELD_AUTHOR'] = $CNF['FIELD_OBJECT_ID'];
+        return parent::serviceGetTimelinePost($aEvent, $aBrowseParams);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_author get_author
+     * 
+     * @code bx_srv('bx_timeline', 'get_author', [...]); @endcode
+     * 
+     * Get author ID from content info by content ID. Is used in "Content Info Objects" system.
+     * 
+     * @param $iContentId integer value with content ID.
+     * @return integer value with author ID.
+     * 
+     * @see BxTimelineModule::serviceGetAuthor
+     */
+    /** 
+     * @ref bx_timeline-get_author "get_author"
+     */
+    public function serviceGetAuthor ($iContentId)
+    {
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return 0;
+
+        return $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? (int)$aEvent['owner_id'] : (int)$aEvent['object_id'];
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_date_changed get_date_changed
+     * 
+     * @code bx_srv('bx_timeline', 'get_date_changed', [...]); @endcode
+     * 
+     * Get date when the content was changed last time. Is used in "Content Info Objects" system.
+     * Note. In case of Timeline event 0 is returned everytime.
+     * 
+     * @param $iContentId integer value with content ID.
+     * @return integer value with changing date.
+     * 
+     * @see BxTimelineModule::serviceGetDateChanged
+     */
+    /** 
+     * @ref bx_timeline-get_date_changed "get_date_changed"
+     */
+    public function serviceGetDateChanged ($iContentId)
+    {
+        return 0;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_link get_link
+     * 
+     * @code bx_srv('bx_timeline', 'get_link', [...]); @endcode
+     * 
+     * Get content view page link. Is used in "Content Info Objects" system.
+     * 
+     * @param $iContentId integer value with content ID.
+     * @return string value with view page link.
+     * 
+     * @see BxTimelineModule::serviceGetLink
+     */
+    /** 
+     * @ref bx_timeline-get_link "get_link"
+     */
+    public function serviceGetLink ($iContentId)
+    {
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return '';
+
+        return $this->_oConfig->getItemViewUrl($aEvent);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_thumb get_thumb
+     * 
+     * @code bx_srv('bx_timeline', 'get_thumb', [...]); @endcode
+     * 
+     * Get content thumbnail link. Is used in "Content Info Objects" system.
+     * Note. In case of Timeline event an empty string is returned everytime.
+     * 
+     * @param $iContentId integer value with content ID.
+     * @param $sTranscoder (optional) string value with transcoder name which should be applied to thumbnail image.
+     * @return string value with thumbnail link.
+     * 
+     * @see BxTimelineModule::serviceGetThumb
+     */
+    /** 
+     * @ref bx_timeline-get_thumb "get_thumb"
+     */
+    public function serviceGetThumb ($iContentId, $sTranscoder = '') 
+    {
+        return '';
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_info get_info
+     * 
+     * @code bx_srv('bx_timeline', 'get_info', [...]); @endcode
+     * 
+     * Get content info by content ID. Is used in "Content Info Objects" system.
+     * 
+     * @param $iContentId integer value with content ID.
+     * @param $bSearchableFieldsOnly (optional) boolean value determining all info or "searchable fields" only will be returned.
+     * @return an array with content info. Empty array is returned if something is wrong.
+     * 
+     * @see BxTimelineModule::serviceGetInfo
+     */
+    /** 
+     * @ref bx_timeline-get_info "get_info"
+     */
+    public function serviceGetInfo ($iContentId, $bSearchableFieldsOnly = true)
+    {
+        $aContentInfo = $this->_oDb->getEvents(array(
+        	'browse' => 'id', 
+        	'value' => $iContentId)
+        );
+
+        return BxDolContentInfo::formatFields($aContentInfo);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_search_result_unit get_search_result_unit
+     * 
+     * @code bx_srv('bx_timeline', 'get_search_result_unit', [...]); @endcode
+     * 
+     * Get search result unit by content ID. Is used in "Content Info Objects" system.
+     * 
+     * @param $iContentId integer value with content ID.
+     * @param $sUnitTemplate (optional) string value with template name.
+     * @return HTML string with search result unit. Empty string is returned if something is wrong.
+     * 
+     * @see BxTimelineModule::serviceGetSearchResultUnit
+     */
+    /** 
+     * @ref bx_timeline-get_search_result_unit "get_search_result_unit"
+     */
+    public function serviceGetSearchResultUnit ($iContentId, $sUnitTemplate = '')
+    {
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return '';
+
+        if(empty($sUnitTemplate))
+            $sUnitTemplate = 'unit.html';
+
+        return $this->_oTemplate->unit($aEvent, true, $sUnitTemplate);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_post get_block_post
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_post', [...]); @endcode
+     * 
+     * Get Post block for a separate page.
+     *
+     * @param $iProfileId (optional) profile ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockPost
+     */
+    /** 
+     * @ref bx_timeline-get_block_post "get_block_post"
+     */
+    public function serviceGetBlockPost($iProfileId = 0)
+    {
+    	if(empty($iProfileId) && bx_get('profile_id') !== false)
+            $iProfileId = bx_process_input(bx_get('profile_id'), BX_DATA_INT);
+
+        if(empty($iProfileId) && isLogged())
+            $iProfileId = bx_get_logged_profile_id();
+
+        if(!$iProfileId)
+            return array();
+
+        $sType = BX_BASE_MOD_NTFS_TYPE_OWNER;
+        return $this->_getBlockPost($iProfileId, array(
+            'type' => $sType,
+            'form_display' => $this->_oConfig->getPostFormDisplay($sType)
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_post_profile get_block_post_profile
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_post_profile', [...]); @endcode
+     * 
+     * Get Post block for the Profile page.
+     *
+     * @param $sProfileModule (optional) string value with profile based module name. Persons module is used by default.
+     * @param $iProfileContentId (optional) profile's content ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockPostProfile
+     */
+    /** 
+     * @ref bx_timeline-get_block_post_profile "get_block_post_profile"
+     */
+    public function serviceGetBlockPostProfile($sProfileModule = 'bx_persons', $iProfileContentId = 0)
+    {
+        if(empty($sProfileModule))
+            return array();
+
+    	if(empty($iProfileContentId) && bx_get('id') !== false)
+            $iProfileContentId = bx_process_input(bx_get('id'), BX_DATA_INT);
+
+        $oProfile = BxDolProfile::getInstanceByContentAndType($iProfileContentId, $sProfileModule);
+        if(empty($oProfile))
+            return array();
+
+        $iProfileId = $oProfile->id();
+        $sType = BX_BASE_MOD_NTFS_TYPE_OWNER;
+        return $this->_getBlockPost($iProfileId, array(
+            'type' => $sType,
+            'form_display' => $this->_oConfig->getPostFormDisplay($sType)
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_post_home get_block_post_home
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_post_home', [...]); @endcode
+     * 
+     * Get Post block for site's Home page.
+     *
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockPostHome
+     */
+    /** 
+     * @ref bx_timeline-get_block_post_home "get_block_post_home"
+     */
+    public function serviceGetBlockPostHome()
+    {
+        $iProfileId = 0;
+        $sType = BX_BASE_MOD_NTFS_TYPE_PUBLIC;
+        return $this->_getBlockPost($iProfileId, array(
+            'type' => $sType,
+            'form_display' => $this->_oConfig->getPostFormDisplay($sType)
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_post_account get_block_post_account
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_post_account', [...]); @endcode
+     * 
+     * Get Post block for the Dashboard page.
+     *
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockPostAccount
+     */
+    /** 
+     * @ref bx_timeline-get_block_post_account "get_block_post_account"
+     */
+    public function serviceGetBlockPostAccount()
+    {
+        if(!isLogged())
+            return '';
+
+        $iProfileId = $this->getProfileId();
+        $sType = BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS;
+        return $this->_getBlockPost($iProfileId, array(
+            'type' => $sType,
+            'form_display' => $this->_oConfig->getPostFormDisplay($sType)
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view get_block_view
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view', [...]); @endcode
+     * 
+     * Get Timeline View block for a separate page.
+     *
+     * @param $iProfileId (optional) profile ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockView
+     */
+    /** 
+     * @ref bx_timeline-get_block_view "get_block_view"
+     */
+    public function serviceGetBlockView($iProfileId = 0)
+    {
+    	return $this->_serviceGetBlockView($iProfileId, array(
+            'view' => BX_TIMELINE_VIEW_TIMELINE, 
+            'type' => BX_BASE_MOD_NTFS_TYPE_OWNER, 
+            'start' => -1, 
+            'per_page' => -1, 
+            'per_page_default' => $this->_oConfig->getPerPage('profile'), 
+            'timeline' => -1, 
+            'filter' => '', 
+            'modules' => array()
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_outline get_block_view_outline
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_outline', [...]); @endcode
+     * 
+     * Get Outline View block for a separate page.
+     * 
+     * @param $iProfileId (optional) profile ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewOutline
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_outline "get_block_view_outline"
+     */
+    public function serviceGetBlockViewOutline($iProfileId = 0)
+    {
+        return $this->_serviceGetBlockView($iProfileId, array(
+            'view' => BX_TIMELINE_VIEW_OUTLINE, 
+            'type' => BX_BASE_MOD_NTFS_TYPE_OWNER, 
+            'start' => -1, 
+            'per_page' => -1, 
+            'per_page_default' => $this->_oConfig->getPerPage('profile'), 
+            'timeline' => -1, 
+            'filter' => '', 
+            'modules' => array()
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_profile get_block_view_profile
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_profile', [...]); @endcode
+     * 
+     * Get Timeline View block for the Profile page.
+     * 
+     * @param $sProfileModule (optional) string value with profile based module name. Persons module is used by default.
+     * @param $iProfileContentId (optional) profile's content ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewProfile
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_profile "get_block_view_profile"
+     */
+    public function serviceGetBlockViewProfile($sProfileModule = 'bx_persons', $iProfileContentId = 0, $iStart = -1, $iPerPage = -1, $sFilter = '', $aModules = array(), $iTimeline = -1)
+    {
+        return $this->_serviceGetBlockViewProfile($sProfileModule, $iProfileContentId, array(
+            'view' => BX_TIMELINE_VIEW_TIMELINE, 
+            'type' => BX_BASE_MOD_NTFS_TYPE_OWNER, 
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('profile'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_profile_outline get_block_view_profile_outline
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_profile_outline', [...]); @endcode
+     * 
+     * Get Outline View block for the Profile page.
+     * 
+     * @param $sProfileModule (optional) string value with profile based module name. Persons module is used by default.
+     * @param $iProfileContentId (optional) profile's content ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewProfileOutline
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_profile_outline "get_block_view_profile_outline"
+     */
+    public function serviceGetBlockViewProfileOutline($sProfileModule = 'bx_persons', $iProfileContentId = 0, $iStart = -1, $iPerPage = -1, $sFilter = '', $aModules = array(), $iTimeline = -1)
+    {
+        return $this->_serviceGetBlockViewProfile($sProfileModule, $iProfileContentId, array(
+            'view' => BX_TIMELINE_VIEW_OUTLINE, 
+            'type' => BX_BASE_MOD_NTFS_TYPE_OWNER, 
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('profile'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_home get_block_view_home
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_home', [...]); @endcode
+     * 
+     * Get Timeline View block for site's Home page.
+     * 
+     * @param $iProfileId (optional) profile ID. 0 should be used here.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewHome
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_home "get_block_view_home"
+     */
+    public function serviceGetBlockViewHome($iProfileId = 0, $iStart = -1, $iPerPage = -1, $iTimeline = -1, $sFilter = '', $aModules = array())
+    {
+        return $this->_serviceGetBlockViewHome(array(
+            'view' => BX_TIMELINE_VIEW_TIMELINE, 
+            'type' => BX_BASE_MOD_NTFS_TYPE_PUBLIC,
+            'owner_id' => $iProfileId,
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('home'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_home_outline get_block_view_home_outline
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_home_outline', [...]); @endcode
+     * 
+     * Get Outline View block for site's Home page.
+     * 
+     * @param $iProfileId (optional) profile ID. 0 should be used here.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewHomeOutline
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_home_outline "get_block_view_home_outline"
+     */
+    public function serviceGetBlockViewHomeOutline($iProfileId = 0, $iStart = -1, $iPerPage = -1, $iTimeline = -1, $sFilter = '', $aModules = array())
+    {
+        return $this->_serviceGetBlockViewHome(array(
+            'view' => BX_TIMELINE_VIEW_OUTLINE, 
+            'type' => BX_BASE_MOD_NTFS_TYPE_PUBLIC,
+            'owner_id' => $iProfileId,
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('home'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+	/**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_hot get_block_view_hot
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_hot', [...]); @endcode
+     * 
+     * Get Timeline View block with Hot public events.
+     * 
+     * @param $iProfileId (optional) profile ID. 0 should be used here.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewHot
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_hot "get_block_view_hot"
+     */
+    public function serviceGetBlockViewHot($iProfileId = 0, $iStart = -1, $iPerPage = -1, $iTimeline = -1, $sFilter = '', $aModules = array())
+    {
+        return $this->_serviceGetBlockViewHot(array(
+            'view' => BX_TIMELINE_VIEW_TIMELINE, 
+            'type' => BX_TIMELINE_TYPE_HOT,
+            'owner_id' => $iProfileId,
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('home'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_hot_outline get_block_view_hot_outline
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_hot_outline', [...]); @endcode
+     * 
+     * Get Outline View block with Hot public events.
+     * 
+     * @param $iProfileId (optional) profile ID. 0 should be used here.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewHotOutline
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_hot_outline "get_block_view_hot_outline"
+     */
+	public function serviceGetBlockViewHotOutline($iProfileId = 0, $iStart = -1, $iPerPage = -1, $iTimeline = -1, $sFilter = '', $aModules = array())
+    {
+        return $this->_serviceGetBlockViewHot(array(
+            'view' => BX_TIMELINE_VIEW_OUTLINE, 
+            'type' => BX_TIMELINE_TYPE_HOT, 
+            'owner_id' => $iProfileId, 
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('home'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_account get_block_view_account
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_account', [...]); @endcode
+     * 
+     * Get Timeline View block for the Dashboard page.
+     * 
+     * @param $iProfileId (optional) profile ID. 0 should be used here.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewAccount
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_account "get_block_view_account"
+     */
+    public function serviceGetBlockViewAccount($iProfileId = 0, $iStart = -1, $iPerPage = -1, $iTimeline = -1, $sFilter = '', $aModules = array())
+    {
+        if(!isLogged())
+            return '';
+
+        return $this->_serviceGetBlockViewByType(array(
+            'view' => BX_TIMELINE_VIEW_TIMELINE, 
+            'type' => BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS, 
+            'owner_id' => $iProfileId, 
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('account'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_account_outline get_block_view_account_outline
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_account_outline', [...]); @endcode
+     * 
+     * Get Outline View block for the Dashboard page.
+     * 
+     * @param $iProfileId (optional) profile ID. 0 should be used here.
+     * @param $iStart (optional) integer value with a page number. Is used in pagination.
+     * @param $iPerPage (optional) integer value with a number of items per page. Is used in pagination.
+     * @param $iTimeline (optional) integer value determining whether the timeline should be displayed or not. 
+     * @param $sFilter (optional) string value with filter name.
+     * @param $aModules (optional) an array of modules from which the events should be displayed. All available modules are used by default.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewAccountOutline
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_account_outline "get_block_view_account_outline"
+     */
+    public function serviceGetBlockViewAccountOutline($iProfileId = 0, $iStart = -1, $iPerPage = -1, $iTimeline = -1, $sFilter = '', $aModules = array())
+    {
+        if(!isLogged())
+            return '';
+
+        return $this->_serviceGetBlockViewByType(array(
+            'view' => BX_TIMELINE_VIEW_OUTLINE, 
+            'type' => BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS,
+            'owner_id' => $iProfileId, 
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'per_page_default' => $this->_oConfig->getPerPage('account'), 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_view_custom get_block_view_custom
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_view_custom', [...]); @endcode
+     * 
+     * Get custom Timeline View block.
+     *
+     * @param $aParams (optional) an array with block parameneters.
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockViewCustom
+     */
+    /** 
+     * @ref bx_timeline-get_block_view_custom "get_block_view_custom"
+     */
+    public function serviceGetBlockViewCustom($aParams = array())
+    {
+    	return $this->_serviceGetBlockViewByType($aParams);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-page_blocks Page Blocks
+     * @subsubsection bx_timeline-get_block_item get_block_item
+     * 
+     * @code bx_srv('bx_timeline', 'get_block_item', [...]); @endcode
+     * 
+     * Get View Item block.
+     * 
+     * @return an array describing a block to display on the site. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetBlockItem
+     */
+    /** 
+     * @ref bx_timeline-get_block_item "get_block_item"
+     */
+    public function serviceGetBlockItem()
+    {
+        $iItemId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        if(!$iItemId)
+            return array();
+
+        $aParams = array(
+            'view' => BX_TIMELINE_VIEW_ITEM, 
+            'type' => BX_TIMELINE_TYPE_ITEM
+        );
+        $aParams = $this->_prepareParams($aParams);
+
+        return $this->_oTemplate->getItemBlock($iItemId, $aParams);
+    }
+
+    public function serviceGetBlockItemContent()
+    {
+        $iItemId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        $sMode = bx_process_input(bx_get('mode'));
+        if(!$iItemId || !$sMode)
+            return '';
+            
+        return $this->_oTemplate->getItemBlockContent($iItemId, $sMode);
+    }
+    
+    public function serviceGetBlockItemInfo()
+    {
+        $iItemId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        if(!$iItemId)
+            return '';
+
+        return $this->_oTemplate->getItemBlockInfo($iItemId);
+    }
+
+    public function serviceGetBlockItemComments()
+    {
+        $iItemId = bx_process_input(bx_get('id'), BX_DATA_INT);
+        if(!$iItemId)
+            return '';
+
+        return $this->_oTemplate->getItemBlockComments($iItemId);
+    }
+    
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_data get_notifications_data
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_data', [...]); @endcode
+     * 
+     * Data for Notifications module.
+     * 
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsData
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_data "get_notifications_data"
+     */
+    public function serviceGetNotificationsData()
+    {
+    	$sModule = $this->_aModule['name'];
+
+        return array(
+            'handlers' => array(
+                array('group' => $sModule . '_object', 'type' => 'insert', 'alert_unit' => $sModule, 'alert_action' => 'post_common', 'module_name' => $sModule, 'module_method' => 'get_notifications_post', 'module_class' => 'Module'),
+                array('group' => $sModule . '_object', 'type' => 'delete', 'alert_unit' => $sModule, 'alert_action' => 'delete'),
+
+                array('group' => $sModule . '_repost', 'type' => 'insert', 'alert_unit' => $sModule, 'alert_action' => 'repost', 'module_name' => $sModule, 'module_method' => 'get_notifications_repost', 'module_class' => 'Module'),
+                array('group' => $sModule . '_repost', 'type' => 'delete', 'alert_unit' => $sModule, 'alert_action' => 'delete_repost'),
+
+                array('group' => $sModule . '_comment', 'type' => 'insert', 'alert_unit' => $sModule, 'alert_action' => 'commentPost', 'module_name' => $sModule, 'module_method' => 'get_notifications_comment', 'module_class' => 'Module'),
+                array('group' => $sModule . '_comment', 'type' => 'delete', 'alert_unit' => $sModule, 'alert_action' => 'commentRemoved'),
+
+                array('group' => $sModule . '_vote', 'type' => 'insert', 'alert_unit' => $sModule, 'alert_action' => 'doVote', 'module_name' => $sModule, 'module_method' => 'get_notifications_vote', 'module_class' => 'Module'),
+                array('group' => $sModule . '_vote', 'type' => 'delete', 'alert_unit' => $sModule, 'alert_action' => 'undoVote'),
+                
+                array('group' => $sModule . '_score_up', 'type' => 'insert', 'alert_unit' => $sModule, 'alert_action' => 'doVoteUp', 'module_name' => $sModule, 'module_method' => 'get_notifications_score_up', 'module_class' => 'Module'),
+
+                array('group' => $sModule . '_score_down', 'type' => 'insert', 'alert_unit' => $sModule, 'alert_action' => 'doVoteDown', 'module_name' => $sModule, 'module_method' => 'get_notifications_score_down', 'module_class' => 'Module'),
+            ),
+            'settings' => array(
+                array('group' => 'content', 'unit' => $sModule, 'action' => 'post_common', 'types' => array('personal', 'follow_member', 'follow_context')),
+                array('group' => 'content', 'unit' => $sModule, 'action' => 'repost', 'types' => array('follow_member', 'follow_context')),
+                array('group' => 'comment', 'unit' => $sModule, 'action' => 'commentPost', 'types' => array('personal', 'follow_member', 'follow_context')),
+                array('group' => 'vote', 'unit' => $sModule, 'action' => 'doVote', 'types' => array('personal', 'follow_member', 'follow_context')),
+                array('group' => 'score_up', 'unit' => $sModule, 'action' => 'doVoteUp', 'types' => array('personal', 'follow_member', 'follow_context')),
+                array('group' => 'score_down', 'unit' => $sModule, 'action' => 'doVoteDown', 'types' => array('personal', 'follow_member', 'follow_context'))
+            ),
+            'alerts' => array(
+                array('unit' => $sModule, 'action' => 'post_common'),
+                array('unit' => $sModule, 'action' => 'delete'),
+                
+                array('unit' => $sModule, 'action' => 'repost'),
+                array('unit' => $sModule, 'action' => 'delete_repost'),
+                
+                array('unit' => $sModule, 'action' => 'commentPost'),
+                array('unit' => $sModule, 'action' => 'commentRemoved'),
+                
+                array('unit' => $sModule, 'action' => 'doVote'),
+                array('unit' => $sModule, 'action' => 'undoVote'),
+
+                array('unit' => $sModule, 'action' => 'doVoteUp'),
+                array('unit' => $sModule, 'action' => 'doVoteDown'),
+            )
+        );
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_repost get_notifications_repost
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_repost', [...]); @endcode
+     * 
+     * Get data for Repost event to display in Notifications module.
+     * 
+     * @param $aEvent an array with event description.
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsRepost
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_repost "get_notifications_repost"
+     */
+    public function serviceGetNotificationsRepost($aEvent)
+    {
+        $aResult = $this->serviceGetNotificationsPost($aEvent);
+        $aResult['lang_key'] = '_bx_timeline_txt_object_reposted';
+
+        return $aResult;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_post get_notifications_post
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_post', [...]); @endcode
+     * 
+     * Get data for Post event to display in Notifications module.
+     * 
+     * @param $aEvent an array with event description.
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsPost
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_post "get_notifications_post"
+     */
+    public function serviceGetNotificationsPost($aEvent)
+    {
+    	$CNF = &$this->_oConfig->CNF;
+
+        $iContent = (int)$aEvent['object_id'];
+        $aContent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContent));
+        if(empty($aContent) || !is_array($aContent))
+            return array();
+
+        if($this->_oConfig->isSystem($aContent['type'], $aContent['action']))
+            $iEntryAuthor = (int)$aContent['owner_id'];
+        else
+            $iEntryAuthor = (int)$aContent['object_id'];
+
+        $sEntryCaption = !empty($aContent['title']) ? $aContent['title'] : $this->_oConfig->getTitle($aContent['description'], $aContent['object_id']);
+
+        return array(
+            'entry_sample' => $CNF['T']['txt_sample_single_ext'],
+            'entry_url' => $this->_oConfig->getItemViewUrl($aContent),
+            'entry_caption' => $sEntryCaption,
+            'entry_author' => $iEntryAuthor,
+            'lang_key' => '' //may be empty or not specified. In this case the default one from Notification module will be used.
+        );
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_comment get_notifications_comment
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_comment', [...]); @endcode
+     * 
+     * Get data for Post Comment event to display in Notifications module.
+     * 
+     * @param $aEvent an array with event description.
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsComment
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_comment "get_notifications_comment"
+     */
+    public function serviceGetNotificationsComment($aEvent)
+    {
+    	$CNF = &$this->_oConfig->CNF;
+
+        $iContent = (int)$aEvent['object_id'];
+        $aContent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContent));
+        if(empty($aContent) || !is_array($aContent))
+            return array();
+
+        $oComment = BxDolCmts::getObjectInstance($CNF['OBJECT_COMMENTS'], $iContent);
+        if(!$oComment || !$oComment->isEnabled())
+            return array();
+
+        $sEntryCaption = !empty($aContent['title']) ? $aContent['title'] : $this->_oConfig->getTitle($aContent['description'], $aContent['object_id']);
+
+        return array(
+            'entry_sample' => $CNF['T']['txt_sample_single'],
+            'entry_url' => $this->_oConfig->getItemViewUrl($aContent),
+            'entry_caption' => $sEntryCaption,
+            'entry_author' => $aContent['owner_id'],
+            'subentry_sample' => $CNF['T']['txt_sample_comment_single'],
+            'subentry_url' => $oComment->getViewUrl((int)$aEvent['subobject_id']),
+            'lang_key' => '', //may be empty or not specified. In this case the default one from Notification module will be used.
+        );
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_vote get_notifications_vote
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_vote', [...]); @endcode
+     * 
+     * Get data for Vote event to display in Notifications module.
+     * 
+     * @param $aEvent an array with event description.
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsVote
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_vote "get_notifications_vote"
+     */
+    public function serviceGetNotificationsVote($aEvent)
+    {
+    	$CNF = &$this->_oConfig->CNF;
+
+        $iContent = (int)$aEvent['object_id'];
+        $aContent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContent));
+        if(empty($aContent) || !is_array($aContent))
+            return array();
+
+        $oVote = BxDolVote::getObjectInstance($CNF['OBJECT_VOTES'], $iContent);
+        if(!$oVote || !$oVote->isEnabled())
+            return array();
+
+        $sEntryCaption = !empty($aContent['title']) ? $aContent['title'] : $this->_oConfig->getTitle($aContent['description'], $aContent['object_id']);
+
+        return array(
+            'entry_sample' => $CNF['T']['txt_sample_single'],
+            'entry_url' => $this->_oConfig->getItemViewUrl($aContent),
+            'entry_caption' => $sEntryCaption,
+            'entry_author' => $aContent['owner_id'],
+            'subentry_sample' => $CNF['T']['txt_sample_vote_single'],
+            'lang_key' => '', //may be empty or not specified. In this case the default one from Notification module will be used.
+        );
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_score_up get_notifications_score_up
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_score_up', [...]); @endcode
+     * 
+     * Get data for Score Up Vote event to display in Notifications module.
+     * 
+     * @param $aEvent an array with event description.
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsScoreUp
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_score_up "get_notifications_score_up"
+     */
+    public function serviceGetNotificationsScoreUp($aEvent)
+    {
+    	return $this->_serviceGetNotificationsScore('up', $aEvent);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-integration_notifications Integration with Notifications
+     * @subsubsection bx_timeline-get_notifications_score_down get_notifications_score_down
+     * 
+     * @code bx_srv('bx_timeline', 'get_notifications_score_down', [...]); @endcode
+     * 
+     * Get data for Score Down Vote event to display in Notifications module.
+     * 
+     * @param $aEvent an array with event description.
+     * @return an array with special format.
+     * 
+     * @see BxTimelineModule::serviceGetNotificationsScoreDown
+     */
+    /** 
+     * @ref bx_timeline-get_notifications_score_down "get_notifications_score_down"
+     */
+    public function serviceGetNotificationsScoreDown($aEvent)
+    {
+    	return $this->_serviceGetNotificationsScore('down', $aEvent);
+    }
+
+
+    protected function _serviceGetNotificationsScore($sType, $aEvent)
+    {
+    	$CNF = &$this->_oConfig->CNF;
+
+        $iContent = (int)$aEvent['object_id'];
+        $aContent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContent));
+        if(empty($aContent) || !is_array($aContent))
+            return array();
+
+        $oScore = BxDolScore::getObjectInstance($CNF['OBJECT_SCORES'], $iContent);
+        if(!$oScore || !$oScore->isEnabled())
+            return array();
+
+        $sEntryCaption = !empty($aContent['title']) ? $aContent['title'] : $this->_oConfig->getTitle($aContent['description'], $aContent['object_id']);
+
+        return array(
+            'entry_sample' => $CNF['T']['txt_sample_single'],
+            'entry_url' => $this->_oConfig->getItemViewUrl($aContent),
+            'entry_caption' => $sEntryCaption,
+            'entry_author' => $aContent['owner_id'],
+            'subentry_sample' => $CNF['T']['txt_sample_score_' . $sType . '_single'],
+            'lang_key' => '', //may be empty or not specified. In this case the default one from Notification module will be used.
+        );
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-repost Repost
+     * @subsubsection bx_timeline-get_repost_element_block get_repost_element_block
+     * 
+     * @code bx_srv('bx_timeline', 'get_repost_element_block', [...]); @endcode
+     * 
+     * Get repost element for content based modules.
+     * 
+     * @param $iOwnerId integer value with owner profile ID.
+     * @param $sType string value with type (module name). 
+     * @param $sAction string value with action (module action). 
+     * @param $iObjectId integer value with object ID to be reposted. 
+     * @param $aParams (optional) an array with additional params.
+     * @return HTML string with repost element to display on the site, all necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetRepostElementBlock
+     */
+    /** 
+     * @ref bx_timeline-get_repost_element_block "get_repost_element_block"
+     */
+    public function serviceGetRepostElementBlock($iOwnerId, $sType, $sAction, $iObjectId, $aParams = array())
+    {
+    	if(!$this->isEnabled())
+    		return '';
+
+        $aParams = array_merge($this->_oConfig->getRepostDefaults(), $aParams);
+        return $this->_oTemplate->getRepostElement($iOwnerId, $sType, $sAction, $iObjectId, $aParams);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-repost Repost
+     * @subsubsection bx_timeline-get_repost_counter get_repost_counter
+     * 
+     * @code bx_srv('bx_timeline', 'get_repost_counter', [...]); @endcode
+     * 
+     * Get repost counter.
+     * 
+     * @param $sType string value with type (module name). 
+     * @param $sAction string value with action (module action). 
+     * @param $iObjectId integer value with object ID to be reposted. 
+     * @return HTML string with repost counter to display on the site, all necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetRepostCounter
+     */
+    /** 
+     * @ref bx_timeline-get_repost_counter "get_repost_counter"
+     */
+    public function serviceGetRepostCounter($sType, $sAction, $iObjectId)
+    {
+    	if(!$this->isEnabled())
+    		return '';
+
+		$aReposted = $this->_oDb->getReposted($sType, $sAction, $iObjectId);
+
+        return $this->_oTemplate->getRepostCounter($aReposted);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-repost Repost
+     * @subsubsection bx_timeline-get_repost_js_script get_repost_js_script
+     * 
+     * @code bx_srv('bx_timeline', 'get_repost_js_script', [...]); @endcode
+     * 
+     * Get repost JavaScript code.
+     * 
+     * @return HTML string with JavaScript code to display on the site, all necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxTimelineModule::serviceGetRepostJsScript
+     */
+    /** 
+     * @ref bx_timeline-get_repost_js_script "get_repost_js_script"
+     */
+    public function serviceGetRepostJsScript()
+    {
+    	if(!$this->isEnabled())
+    		return '';
+
+        return $this->_oTemplate->getRepostJsScript();
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-repost Repost
+     * @subsubsection bx_timeline-get_repost_js_click get_repost_js_click
+     * 
+     * @code bx_srv('bx_timeline', 'get_repost_js_click', [...]); @endcode
+     * 
+     * Get repost JavaScript code for OnClick event.
+     * 
+     * @param $iOwnerId integer value with owner profile ID.
+     * @param $sType string value with type (module name). 
+     * @param $sAction string value with action (module action). 
+     * @param $iObjectId integer value with object ID to be reposted. 
+     * @return HTML string with JavaScript code to display in OnClick events of HTML elements.
+     * 
+     * @see BxTimelineModule::serviceGetRepostJsClick
+     */
+    /** 
+     * @ref bx_timeline-get_repost_js_click "get_repost_js_click"
+     */
+    public function serviceGetRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId)
+    {
+    	if(!$this->isEnabled())
+    		return '';
+
+        return $this->_oTemplate->getRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-repost Repost
+     * @subsubsection bx_timeline-repost repost
+     * 
+     * @code bx_srv('bx_timeline', 'repost', [...]); @endcode
+     * 
+     * Perform repost action.
+     * 
+     * @param $iAuthorId integer value with performer profile ID.
+     * @param $iOwnerId integer value with repost event owner profile ID.
+     * @param $sType string value with type (module name). 
+     * @param $sAction string value with action (module action). 
+     * @param $iObjectId integer value with object ID to be reposted. 
+     * @parem $bForce boolean value force reposting without ACL check.
+     * @return an array with error (code and message) or integer with newly created repost event ID.
+     * 
+     * @see BxTimelineModule::serviceRepost
+     */
+    /** 
+     * @ref bx_timeline-repost "repost"
+     */
+    public function serviceRepost($iAuthorId, $iOwnerId, $sType, $sAction, $iObjectId, $bForce = false)
+    {
+        $aReposted = $this->_oDb->getReposted($sType, $sAction, $iObjectId);
+        if(empty($aReposted) || !is_array($aReposted))
+            return array('code' => 1, 'message' => _t('_bx_timeline_txt_err_cannot_repost'));
+
+        $mixedAllowed = $this->isAllowedRepost($aReposted, true);
+        if(!$bForce && $mixedAllowed !== true)
+            return array('code' => 2, 'message' => strip_tags($mixedAllowed));
+
+        $bReposted = $this->_oDb->isReposted($aReposted['id'], $iOwnerId, $iAuthorId);
+        if($bReposted)
+            return array('code' => 3, 'message' => _t('_bx_timeline_txt_err_already_reposted'));
+
+        $iId = $this->_oDb->insertEvent(array(
+            'owner_id' => $iOwnerId,
+            'type' => $this->_oConfig->getPrefix('common_post') . 'repost',
+            'action' => '',
+            'object_id' => $iAuthorId,
+            'object_privacy_view' => $this->_oConfig->getPrivacyViewDefault('object'),
+            'content' => serialize(array(
+                'type' => $sType,
+                'action' => $sAction,
+                'object_id' => $iObjectId,
+            )),
+            'title' => '',
+            'description' => ''
+        ));
+
+        if(empty($iId))
+            return array('code' => 4, 'message' => _t('_bx_timeline_txt_err_cannot_repost'));
+
+        $this->onRepost($iId, $aReposted);
+
+        return $iId;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-repost Repost
+     * @subsubsection bx_timeline-repost_by_id repost_by_id
+     * 
+     * @code bx_srv('bx_timeline', 'repost_by_id', [...]); @endcode
+     * 
+     * Perform repost action by Timeline event ID.
+     * 
+     * @param $iAuthorId integer value with performer profile ID.
+     * @param $iOwnerId integer value with repost event owner profile ID.
+     * @param $iEventId integer value with event ID which will be reposted.
+     * @parem $bForce boolean value force reposting without ACL check.
+     * @return an array with error (code and message) or integer with newly created repost event ID.
+     * 
+     * @see BxTimelineModule::serviceRepostById
+     */
+    /** 
+     * @ref bx_timeline-repost_by_id "repost_by_id"
+     */
+    public function serviceRepostById($iAuthorId, $iOwnerId, $iEventId, $bForce = false)
+    {
+        $aEvent = $this->_oDb->getEntriesBy(array('type' => 'id', 'id' => $iEventId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return array('code' => 1, 'message' => _t('_bx_timeline_txt_err_cannot_repost'));
+
+        $sType = $aEvent['type'];
+        $sAction = $aEvent['action'];
+        $iObjectId = $this->_oConfig->isSystem($sType, $sAction) ? $aEvent['object_id'] : $aEvent['id'];
+
+        $sCommonPrefix = $this->_oConfig->getPrefix('common_post');
+        if(str_replace($sCommonPrefix, '', $sType) == BX_TIMELINE_PARSE_TYPE_REPOST) {
+            $aReposted = $this->_oDb->getReposted($sType, $sAction, $iObjectId);
+            if(empty($aReposted) || !is_array($aReposted))
+                return array('code' => 1, 'message' => _t('_bx_timeline_txt_err_cannot_repost'));
+
+            $aRepostedData = unserialize($aEvent['content']);
+
+            $sType = $aRepostedData['type'];
+            $sAction = $aRepostedData['action'];
+            $iObjectId = $aRepostedData['object_id'];
+        }
+
+        return $this->serviceRepost($iAuthorId, $iOwnerId, $sType, $sAction, $iObjectId, $bForce);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-update update
+     * 
+     * @code bx_srv('bx_timeline', 'update', [...]); @endcode
+     * 
+     * Update timeline event by ID.
+     * 
+     * @param $iEventId integer value with event ID.
+     * @param $aSet an array with key=>value pairs for fields which should be updated. 
+     * @return boolean value with the result of operation.
+     * 
+     * @see BxTimelineModule::serviceUpdate
+     */
+    /** 
+     * @ref bx_timeline-update "update"
+     */
+    public function serviceUpdate($iEventId, $aSet)
+    {
+        if(empty($iEventId))
+            return false;
+
+        return (int)$this->_oDb->updateEvent($aSet, array('id' => $iEventId)) > 0;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_menu_item_addon_comment get_menu_item_addon_comment
+     * 
+     * @code bx_srv('bx_timeline', 'get_menu_item_addon_comment', [...]); @endcode
+     * 
+     * Get addon for Comment menu item.
+     * 
+     * @param $sSystem string value with comments engine system.
+     * @param $iObjectId integer value with object ID. 
+     * @return HTML string to display in menu item.
+     * 
+     * @see BxTimelineModule::serviceGetMenuItemAddonComment
+     */
+    /** 
+     * @ref bx_timeline-get_menu_item_addon_comment "get_menu_item_addon_comment"
+     */
+    public function serviceGetMenuItemAddonComment($sSystem, $iObjectId, $aBrowseParams = array())
+    {
+        if(empty($sSystem) || empty($iObjectId))
+            return '';
+        
+        $oCmts = $this->getCmtsObject($sSystem, $iObjectId);
+        if($oCmts === false)
+            return '';
+
+        $iCounter = (int)$oCmts->getCommentsCount();
+        if(empty($iCounter))
+            return '';
+
+        return  $this->_oTemplate->parseLink('javascript:void(0)', $iCounter, array(
+            'class' => 'bx-menu-item-addon',
+            'title' => _t('_bx_timeline_menu_item_title_item_comment'),
+            'onclick' => "javascript:" . $this->_oConfig->getJsObjectView($aBrowseParams) . ".commentItem(this, '" . $sSystem . "', " . $iObjectId . ")" 
+        ));
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_settings_checker_helper get_settings_checker_helper
+     * 
+     * @code bx_srv('bx_timeline', 'get_settings_checker_helper', [...]); @endcode
+     * 
+     * Get Checker Helper class name for Forms engine.
+     * 
+     * @return string with Checker Helper class name.
+     * 
+     * @see BxTimelineModule::serviceGetSettingsCheckerHelper
+     */
+    /** 
+     * @ref bx_timeline-get_settings_checker_helper "get_settings_checker_helper"
+     */
+    public function serviceGetSettingsCheckerHelper()
+    {
+        bx_import('FormCheckerHelper', $this->_aModule);
+        return 'BxTimelineFormCheckerHelper';
+    }
+
+	/**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_options_videos_autoplay get_options_videos_autoplay
+     * 
+     * @code bx_srv('bx_timeline', 'get_options_videos_autoplay', [...]); @endcode
+     * 
+     * Get an array with available options for 'Videos autoplay in Timeline' setting.
+     *
+     * @return an array with available options represented as key => value pairs.
+     * 
+     * @see BxTimelineModule::serviceGetOptionsVideosAutoplay
+     */
+    /** 
+     * @ref bx_timeline-get_options_videos_autoplay "get_options_videos_autoplay"
+     */
+    public function serviceGetOptionsVideosAutoplay()
+    {
+        $aOptions = array(BX_TIMELINE_VAP_OFF, BX_TIMELINE_VAP_ON_MUTE, BX_TIMELINE_VAP_ON);
+
+        $aResult = array();
+        foreach($aOptions as $sOption)
+            $aResult[] = array(
+                'key' => $sOption,
+                'value' => _t('_bx_timeline_option_videos_autoplay_' . $sOption)
+            );
+
+        return $aResult;
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_live_update get_live_update
+     * 
+     * @code bx_srv('bx_timeline', 'get_live_update', [...]); @endcode
+     * 
+     * Get an array with actual Live Update info. Only one live update notification for all new events.
+     *
+     * @return an array with Live Update info.
+     * 
+     * @see BxTimelineModule::serviceGetLiveUpdate
+     */
+    /** 
+     * @ref bx_timeline-get_live_update "get_live_update"
+     */
+    public function serviceGetLiveUpdate($aBrowseParams, $iProfileId, $iCount = 0, $iInit = 0)
+    {
+        $sKey = $this->_oConfig->getLiveUpdateKey($aBrowseParams);
+
+        bx_import('BxDolSession');
+        if((int)BxDolSession::getInstance()->getValue($sKey) == 1)
+            return false;
+
+        $aParams = $this->_prepareParams($aBrowseParams);
+        $aParams['filter'] = BX_TIMELINE_FILTER_OTHER_VIEWER;
+        $aParams['count'] = true;
+
+        $iCountNew = $this->_oDb->getEvents($aParams);
+        if($iCountNew == $iCount)
+            return false;
+
+        if((int)$iInit != 0)
+            return array('count' => $iCountNew);
+
+        return array(
+            'count' => $iCountNew, // required (for initialization and visualization)
+            'method' => $this->_oConfig->getJsObjectView($aBrowseParams) . '.showLiveUpdate(oData)', // required (for visualization)
+            'data' => array(
+                'code' => $this->_oTemplate->getLiveUpdate($aBrowseParams, $iProfileId, $iCount, $iCountNew)
+            ),  // optional, may have some additional data to be passed in JS method provided using 'method' param above.
+        );
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Timeline
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_live_updates get_live_updates
+     * 
+     * @code bx_srv('bx_timeline', 'get_live_updates', [...]); @endcode
+     * 
+     * Get an array with actual Live Update info. Separate live update notification for each new Event.
+     * 
+     * Note. This way to display live update notifications isn't used for now. 
+     * See BxTimelineModule::serviceGetLiveUpdate method instead.
+     *
+     * @return an array with Live Update info.
+     * 
+     * @see BxTimelineModule::serviceGetLiveUpdates
+     */
+    /** 
+     * @ref bx_timeline-get_live_updates "get_live_updates"
+     */
+    public function serviceGetLiveUpdates($aBrowseParams, $iProfileId, $iCount = 0, $iInit = 0)
+    {
+        $sKey = $this->_oConfig->getLiveUpdateKey($aBrowseParams);
+
+        bx_import('BxDolSession');
+        if((int)BxDolSession::getInstance()->getValue($sKey) == 1)
+            return false;
+
+        $aParams = $this->_prepareParams($aBrowseParams);
+        $aParams['filter'] = BX_TIMELINE_FILTER_OTHER_VIEWER;
+        $aParams['count'] = true;
+
+        $iCountNew = $this->_oDb->getEvents($aParams);
+        if($iCountNew == $iCount)
+            return false;
+
+        if((int)$iInit != 0)
+            return array('count' => $iCountNew);
+
+        return array(
+            'count' => $iCountNew, // required (for initialization and visualization)
+            'method' => $this->_oConfig->getJsObjectView($aBrowseParams) . '.showLiveUpdates(oData)', // required (for visualization)
+            'data' => array(
+                'code' => $this->_oTemplate->getLiveUpdates($aBrowseParams, $iProfileId, $iCount, $iCountNew)
+            ),  // optional, may have some additional data to be passed in JS method provided using 'method' param above.
+        );
+    }
+    
+    /**
+     * @page service Service Calls
+     * @section bx_timeline Accounts
+     * @subsection bx_timeline-other Other
+     * @subsubsection bx_timeline-get_menu_addon_manage_tools get_menu_addon_manage_tools
+     * 
+     * @code bx_srv('bx_timeline', 'get_menu_addon_manage_tools', [...]); @endcode
+     * 
+     * Get number of 'hidden' events for User End -> Dasboard page -> Manage block.
+     *
+     * @return integer number of 'hidden' events
+     * 
+     * @see BxTimelineModule::serviceGetMenuAddonManageTools
+     */
+    /** 
+     * @ref bx_timeline-get_menu_addon_manage_tools "get_menu_addon_manage_tools"
+     */
+    public function serviceGetMenuAddonManageTools()
+    {
+        bx_import('SearchResult', $this->_aModule);
+        $sClass = $this->_aModule['class_prefix'] . 'SearchResult';
+        $oSearch = new $sClass();
+        $oSearch->fillFilters(array(
+            'status' => BX_TIMELINE_STATUS_HIDDEN
+        ));
+        $oSearch->unsetPaginate();
+
+        return $oSearch->getNum();
+    }
+
+    /*
+     * COMMON METHODS
+     */
+    public function deleteEvent($aEvent)
+    {
+    	if(empty($aEvent) || !is_array($aEvent) || !$this->_oDb->deleteEvent(array('id' => (int)$aEvent['id'])))
+            return false;
+
+        $this->onDelete($aEvent);
+        return true;
+    }
+    
+
+    public function addAttachLink($aValues, $sDisplay = false)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        if(!$sDisplay)
+            $sDisplay = $this->_oConfig->getObject('form_display_attach_link_add');
+
+        $oForm = BxDolForm::getObjectInstance($this->_oConfig->getObject('form_attach_link'), $sDisplay, $this->_oTemplate);
+        if(!$oForm)
+            return array('message' => '_sys_txt_error_occured');
+
+        $oForm->aFormAttrs['method'] = BX_DOL_FORM_METHOD_SPECIFIC;
+        $oForm->aParams['csrf']['disable'] = true;
+        if(!empty($oForm->aParams['db']['submit_name'])) {
+            $sSubmitName = $oForm->aParams['db']['submit_name'];
+            if(!isset($oForm->aInputs[$sSubmitName])) {
+                if(isset($oForm->aInputs[$CNF['FIELD_CONTROLS']]))
+                    foreach($oForm->aInputs[$CNF['FIELD_CONTROLS']] as $mixedIndex => $aInput) {
+                        if(!is_numeric($mixedIndex) || empty($aInput['name']) || $aInput['name'] != $sSubmitName)
+                            continue;
+    
+                        $aValues[$sSubmitName] = $aInput['value'];
+                    }
+            }
+            else            
+                $aValues[$sSubmitName] = $oForm->aInputs[$sSubmitName]['value'];
+        }
+
+        $oForm->aInputs['url']['checker']['params']['preg'] = $this->_oConfig->getPregPattern('url');
+
+        $oForm->initChecker(array(), $aValues);
+        if(!$oForm->isSubmittedAndValid())
+            return array('message' => '_sys_txt_error_occured');
+
+        return $this->_addLink($oForm);
+    }
+
+    public function getFormAttachLink()
+    {
+        $oForm = BxDolForm::getObjectInstance($this->_oConfig->getObject('form_attach_link'), $this->_oConfig->getObject('form_display_attach_link_add'), $this->_oTemplate);
+        $oForm->aFormAttrs['action'] = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'submit_attach_link_form/';
+        $oForm->aInputs['url']['checker']['params']['preg'] = $this->_oConfig->getPregPattern('url');
+
+        $oForm->initChecker();
+        if($oForm->isSubmittedAndValid())
+            return $this->_addLink($oForm);
+
+        return array('form' => $oForm->getCode(), 'form_id' => $oForm->id);
+    }
+
+    public function getFormPost($aParams = array())
+    {
+        $iUserId = $this->getUserId();
+
+        $oForm = $this->getFormPostObject($aParams);
+        $oForm->initChecker();
+
+        $bAjaxMode = $oForm->isAjaxMode();
+        $bDynamicMode = $bAjaxMode;
+
+        if($oForm->isSubmittedAndValid()) {
+            list($sUserName) = $this->getUserInfo($iUserId);
+
+            $sType = $oForm->getCleanValue('type');
+            $sType = $this->_oConfig->getPrefix('common_post') . $sType;
+            BxDolForm::setSubmittedValue('type', $sType, $oForm->aFormAttrs['method']);
+
+            $aContent = array();
+
+            //--- Process Text ---//
+            $sText = $oForm->getCleanValue('text');
+            $sText = $this->_prepareTextForSave($sText);
+            $bText = !empty($sText);
+
+            if($bText)
+            	$aContent['text'] = $sText;
+
+            //--- Process Context and Privacy ---//
+            $iOwnerId = (int)$oForm->getCleanValue('owner_id');
+            $iObjectPrivacyView = (int)$oForm->getCleanValue('object_privacy_view');
+            $iObjectPrivacyViewDefault = $this->_oConfig->getPrivacyViewDefault('object');
+            if(empty($iObjectPrivacyView))
+                $iObjectPrivacyView = $iObjectPrivacyViewDefault;
+            else if($iObjectPrivacyView < 0)
+                $iOwnerId = abs($iObjectPrivacyView);
+
+            //--- Process Link ---//
+            $aLinkIds = $oForm->getCleanValue('link');
+            $bLinkIds = !empty($aLinkIds) && is_array($aLinkIds);
+
+            //--- Process Media ---//
+            $aPhotoIds = $oForm->getCleanValue(BX_TIMELINE_MEDIA_PHOTO);
+            $bPhotoIds = !empty($aPhotoIds) && is_array($aPhotoIds);
+
+            $aVideoIds = $oForm->getCleanValue(BX_TIMELINE_MEDIA_VIDEO);
+            $bVideoIds = !empty($aVideoIds) && is_array($aVideoIds);
+
+            if(!$bText && !$bLinkIds && !$bPhotoIds && !$bVideoIds) {
+                $oForm->aInputs['text']['error'] =  _t('_bx_timeline_txt_err_empty_post');
+                $oForm->setValid(false);
+
+            	return $this->_prepareResponse(array('form' => $oForm->getCode($bDynamicMode), 'form_id' => $oForm->id), $bAjaxMode);
+            }
+
+            $sTitle = $bText ? $this->_oConfig->getTitle($sText) : $this->_oConfig->getTitleDefault($bLinkIds, $bPhotoIds, $bVideoIds);
+            $sDescription = _t('_bx_timeline_txt_user_added_sample', '{profile_name}', _t('_bx_timeline_txt_sample_with_article'));
+
+            /**
+             * Unset 'text' input because its data was already processed 
+             * and will be saved via additional values which were passed 
+             * to BxDolForm::insert method.
+             */
+            unset($oForm->aInputs['text']);
+
+            $iId = $oForm->insert(array(
+                'owner_id' => $iOwnerId,
+                'object_id' => $iUserId,
+                'object_privacy_view' => $iObjectPrivacyView,
+                'content' => serialize($aContent),
+                'title' => $sTitle,
+                'description' => $sDescription
+            ));
+
+            if(!empty($iId)) {
+            	$oMetatags = BxDolMetatags::getObjectInstance($this->_oConfig->getObject('metatags'));
+            	if($bText)
+                    $oMetatags->metaAdd($iId, $sText);
+                $oMetatags->locationsAddFromForm($iId, $this->_oConfig->CNF['FIELD_LOCATION_PREFIX']);
+
+                //--- Process Link ---//
+                if($bLinkIds)
+                    foreach($aLinkIds as $iLinkId)
+                        $this->_oDb->saveLink($iId, $iLinkId);
+
+                //--- Process Media ---//
+                if($bPhotoIds) 
+                    $this->_saveMedia(BX_TIMELINE_MEDIA_PHOTO, $iId, $aPhotoIds);
+
+                if($bVideoIds)
+                    $this->_saveMedia(BX_TIMELINE_MEDIA_VIDEO, $iId, $aVideoIds);
+
+                $this->onPost($iId);
+
+                return $this->_prepareResponse(array('id' => $iId), $bAjaxMode, array(
+                    'redirect' => $this->_oConfig->getItemViewUrl(array('id' => $iId))
+                ));
+            }
+
+            return $this->_prepareResponse(array('message' => _t('_bx_timeline_txt_err_cannot_perform_action')), $bAjaxMode);
+        }
+
+        return $this->_prepareResponse(array('form' => $oForm->getCode($bDynamicMode), 'form_id' => $oForm->id), $bAjaxMode && $oForm->isSubmitted());
+    }
+
+    public function getFormEdit($iId, $aParams = array(), $aBrowseParams = array())
+    {
+        $CNF = &$this->_oConfig->CNF;
+        $sJsObjectView = $this->_oConfig->getJsObjectView($aBrowseParams);
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent) || !is_array($aEvent))
+            return array();
+
+        $aContent = unserialize($aEvent['content']);
+        if(is_array($aContent) && !empty($aContent['text']))
+            $aEvent['text'] = $aContent['text'];
+
+        $bDynamicMode = isset($aParams['dynamic_mode']) ? (bool)$aParams['dynamic_mode'] : false;
+        $sFormObject = !empty($aParams['form_object']) ? $aParams['form_object'] : 'form_post';
+        $sFormDisplay = !empty($aParams['form_display']) ? $aParams['form_display'] : 'form_display_post_edit';
+        $oForm = BxDolForm::getObjectInstance($this->_oConfig->getObject($sFormObject), $this->_oConfig->getObject($sFormDisplay), $this->_oTemplate);
+        $oForm->setId($this->_oConfig->getHtmlIds('view', 'edit_form') . $iId);
+
+        $oForm->aFormAttrs['action'] = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'edit/' . $iId ;
+        if(!empty($aBrowseParams) && is_array($aBrowseParams))
+            $oForm->aFormAttrs['action'] = $this->_oConfig->addBrowseParams($oForm->aFormAttrs['action'], $aBrowseParams);
+
+        foreach($oForm->aInputs[$CNF['FIELD_CONTROLS']] as $mixedIndex => $aInput) {
+            if(!is_numeric($mixedIndex))
+                continue;
+
+            $oForm->aInputs[$CNF['FIELD_CONTROLS']][$mixedIndex]['attrs'] = bx_replace_markers($aInput['attrs'], array(
+                'js_object_view' => $sJsObjectView,
+            	'content_id' => $iId
+            ));
+        }
+
+        $oForm->initChecker($aEvent);
+        if($oForm->isSubmittedAndValid()) {
+            $aContent = array();
+
+            //--- Process Text ---//
+            $sText = $oForm->getCleanValue('text');
+            $sText = $this->_prepareTextForSave($sText);
+            $bText = !empty($sText);
+            unset($oForm->aInputs['text']);
+
+            if($bText)
+            	$aContent['text'] = $sText;
+
+            $aValsToAdd = array(
+            	'content' => serialize($aContent)
+            );
+
+            //--- Process Privacy ---//
+            $iObjectPrivacyView = (int)$oForm->getCleanValue('object_privacy_view');
+            $iObjectPrivacyViewDefault = $this->_oConfig->getPrivacyViewDefault('object');
+            if(empty($iObjectPrivacyView))
+                $aValsToAdd = array_merge($aValsToAdd, array(
+                    'object_privacy_view' => $iObjectPrivacyViewDefault
+                ));
+            else if($iObjectPrivacyView < 0) 
+                $aValsToAdd = array_merge($aValsToAdd, array(
+                    'owner_id' => abs($iObjectPrivacyView),
+                    'object_privacy_view' => $iObjectPrivacyViewDefault
+                ));
+
+            if(!$oForm->update($iId, $aValsToAdd))
+                return array('message' => _t('_bx_timeline_txt_err_cannot_perform_action'));
+
+            $oMetatags = BxDolMetatags::getObjectInstance($this->_oConfig->getObject('metatags'));
+            if($bText)
+                $oMetatags->metaAdd($iId, $sText);
+            $oMetatags->locationsAddFromForm($iId, $this->_oConfig->CNF['FIELD_LOCATION_PREFIX']);
+
+            $this->getCacheItemObject()->removeAllByPrefix($this->_oConfig->getPrefix('cache_item') . $iId);
+            $this->_oDb->deleteCache(array('event_id' => $iId));
+
+            return array(
+                'id' => $iId
+            );
+        }
+
+        return array(
+            'id' => $iId, 
+            'form' => $oForm->getCode($bDynamicMode), 
+            'form_id' => $oForm->id,
+            'eval' => $sJsObjectView . '.onEditPost(oData)'
+        );
+    }
+
+    public function getFormPostObject($aParams)
+    {
+    	$sFormObject = !empty($aParams['form_object']) ? $aParams['form_object'] : 'form_post';
+        $sFormDisplay = !empty($aParams['form_display']) ? $aParams['form_display'] : 'form_display_post_add';
+
+        $oForm = BxDolForm::getObjectInstance($this->_oConfig->getObject($sFormObject), $this->_oConfig->getObject($sFormDisplay), $this->_oTemplate);        
+
+        $sParamsKey = 'ajax_mode';
+        if(isset($aParams[$sParamsKey]) && is_bool($aParams[$sParamsKey]))
+            $oForm->setAjaxMode((bool)$aParams[$sParamsKey]);
+
+        $sParamsKey = 'visibility_autoselect';
+        if(isset($aParams[$sParamsKey]) && is_bool($aParams[$sParamsKey]))
+            $oForm->setVisibilityAutoselect((bool)$aParams[$sParamsKey]);
+
+        $oForm->init();
+        return $oForm;
+    }
+
+    public function getCmtsObject($sSystem, $iId)
+    {
+        if(empty($sSystem) || (int)$iId == 0)
+            return false;
+
+        $oCmts = BxDolCmts::getObjectInstance($sSystem, $iId, true, $this->_oTemplate);
+        if(!$oCmts || !$oCmts->isEnabled())
+            return false;
+
+        return $oCmts;
+    }
+
+    public function getViewObject($sSystem, $iId)
+    {
+        if(empty($sSystem) || (int)$iId == 0)
+            return false;
+
+        $oView = BxDolView::getObjectInstance($sSystem, $iId, true, $this->_oTemplate);
+        if(!$oView || !$oView->isEnabled())
+            return false;
+
+        return $oView;
+    }
+
+    public function getVoteObject($sSystem, $iId)
+    {
+        if(empty($sSystem) || (int)$iId == 0)
+            return false;
+
+        $oVote = BxDolVote::getObjectInstance($sSystem, $iId, true, $this->_oTemplate);
+        if(!$oVote || !$oVote->isEnabled())
+            return false;
+
+        return $oVote;
+    }
+    
+    public function getReactionObject($sSystem, $iId)
+    {
+        if(empty($sSystem) || (int)$iId == 0)
+            return false;
+
+        $oReaction = BxDolVote::getObjectInstance($sSystem, $iId, true, $this->_oTemplate);
+        if(!$oReaction || !$oReaction->isEnabled())
+            return false;
+
+        return $oReaction;
+    }
+
+    public function getScoreObject($sSystem, $iId)
+    {
+        if(empty($sSystem) || (int)$iId == 0)
+            return false;
+
+        $oScore = BxDolScore::getObjectInstance($sSystem, $iId, true, $this->_oTemplate);
+        if(!$oScore || !$oScore->isEnabled())
+            return false;
+
+        return $oScore;
+    }
+
+	public function getReportObject($sSystem, $iId)
+    {
+        if(empty($sSystem) || (int)$iId == 0)
+            return false;
+
+        $oReport = BxDolReport::getObjectInstance($sSystem, $iId, true, $this->_oTemplate);
+        if(!$oReport || !$oReport->isEnabled())
+            return false;
+
+        return $oReport;
+    }
+
+    public function getAttachmentsMenuObject()
+    {
+        $oMenu = BxDolMenu::getObjectInstance($this->_oConfig->getObject('menu_post_attachments'), $this->_oTemplate);
+        $oMenu->addMarkers(array(
+            'js_object' => $this->_oConfig->getJsObject('post'),
+        ));
+
+        return $oMenu;
+    }
+
+    public function getManageMenuObject()
+    {
+        return BxDolMenu::getObjectInstance($this->_oConfig->getObject('menu_item_manage'), $this->_oTemplate);
+    }
+
+    public function getCacheItemObject()
+    {
+        $oCacheEngine = bx_instance('BxDolCache' . $this->_oConfig->getCacheItemEngine());
+        if(!$oCacheEngine->isAvailable())
+            $oCacheEngine = bx_instance('BxDolCacheFile');
+
+        return $oCacheEngine;
+    }
+
+    //--- Check permissions methods ---//
+    public function isModerator()
+    {
+        $sModule = $this->getName();
+        $iUserId = (int)$this->getUserId();
+
+        $aCheckResult = checkActionModule($iUserId, 'edit', $sModule);
+        if($aCheckResult[CHECK_ACTION_RESULT] === CHECK_ACTION_RESULT_ALLOWED)
+            return true;
+
+        $aCheckResult = checkActionModule($iUserId, 'delete', $sModule);
+        if($aCheckResult[CHECK_ACTION_RESULT] === CHECK_ACTION_RESULT_ALLOWED)
+            return true;
+
+        return false;
+    }
+
+    public function isAllowedPost($bPerform = false)
+    {
+        if(isAdmin())
+            return true;
+
+        $iUserId = $this->getUserId();
+
+        $aCheckResult = checkActionModule($iUserId, 'post', $this->getName(), $bPerform);
+        if(!empty($this->_iOwnerId) && ($oProfileOwner = BxDolProfile::getInstance($this->_iOwnerId)) !== false) {
+            if($oProfileOwner->checkAllowedPostInProfile() !== CHECK_ACTION_RESULT_ALLOWED)
+                return _t('_sys_txt_access_denied');
+
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_post', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+        }
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    public function isAllowedView($aEvent, $bPerform = false)
+    {
+        $CNF = $this->_oConfig->CNF;
+
+        $mixedResult = BxDolProfile::getInstance($aEvent[$CNF['FIELD_OWNER_ID']])->checkAllowedProfileView();
+        if($mixedResult !== CHECK_ACTION_RESULT_ALLOWED)
+            return false;
+
+		return true;
+    }
+
+    public function isAllowedEdit($aEvent, $bPerform = false)
+    {
+        if(!isLogged())
+            return false;
+            
+        //--- System posts and Reposts cannot be edited at all.
+        if(!$this->_oConfig->isCommon($aEvent['type'], $aEvent['action']) || $aEvent['type'] == $this->_oConfig->getPrefix('common_post') . 'repost')
+            return false;
+
+        if(isAdmin())
+            return true;
+
+        $iUserId = (int)$this->getUserId();
+        $iOwnerId = (int)$aEvent['owner_id'];
+        $iObjectId = abs((int)$aEvent['object_id']);
+        if($iObjectId == $iUserId && $this->_oConfig->isAllowEdit())
+           return true;
+
+        $aCheckResult = checkActionModule($iUserId, 'edit', $this->getName(), $bPerform);
+        if(!empty($iOwnerId) && ($oProfileOwner = BxDolProfile::getInstance($iOwnerId)) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_edit', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    public function isAllowedDelete($aEvent, $bPerform = false)
+    {
+        if(!isLogged())
+            return false;
+
+        if(isAdmin())
+            return true;
+
+        $iUserId = (int)$this->getUserId();
+        $iOwnerId = (int)$aEvent['owner_id'];
+        $iObjectId = abs((int)$aEvent['object_id']);
+        if((($iOwnerId == $iUserId && $this->_oConfig->isAllowDelete()) || ($this->_oConfig->isCommon($aEvent['type'], $aEvent['action']) && $iObjectId == $iUserId)))
+           return true;
+
+        $aCheckResult = checkActionModule($iUserId, 'delete', $this->getName(), $bPerform);
+        if(!empty($iOwnerId) && ($oProfileOwner = BxDolProfile::getInstance($iOwnerId)) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_delete', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    public function isAllowedComment($aEvent, $bPerform = false)
+    {
+        $mixedComments = $this->getCommentsData($aEvent['comments']);
+        if($mixedComments === false)
+            return false;
+
+        list($sSystem, $iObjectId) = $mixedComments;
+        $oCmts = $this->getCmtsObject($sSystem, $iObjectId);
+        
+        if($oCmts->isViewAllowed() !== CHECK_ACTION_RESULT_ALLOWED)
+            return false;
+        
+        $oCmts->addCssJs();
+
+        $bResult = true;
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false) {
+            if($oProfileOwner->checkAllowedPostInProfile() !== CHECK_ACTION_RESULT_ALLOWED)
+                return false;
+
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_comment', $oProfileOwner->id(), (int)$this->getUserId(), array('result' => &$bResult));
+        }
+
+        return $bResult;
+    }
+
+    public function isAllowedViewCounter($aEvent, $bPerform = false)
+    {
+        $mixedViews = $this->getViewsData($aEvent['views']);
+        if($mixedViews === false)
+            return false;
+
+        list($sSystem, $iObjectId) = $mixedViews;
+        $oView = $this->getViewObject($sSystem, $iObjectId);
+
+        if(!$oView->isAllowedViewView($bPerform))
+        	return false;
+
+        $bResult = true;
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_view_counter', $oProfileOwner->id(), (int)$this->getUserId(), array('result' => &$bResult));
+
+        return $bResult;
+    }
+
+    public function isAllowedVote($aEvent, $bPerform = false)
+    {
+        $mixedVotes = $this->getVotesData($aEvent['votes']);
+        if($mixedVotes === false)
+            return false;
+
+        list($sSystem, $iObjectId) = $mixedVotes;
+        $oVote = $this->getVoteObject($sSystem, $iObjectId);
+
+        if(!$oVote->isAllowedVote($bPerform))
+        	return false;
+
+        $bResult = true;
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_vote', $oProfileOwner->id(), (int)$this->getUserId(), array('result' => &$bResult));
+
+        return $bResult;
+    }
+
+    public function isAllowedReaction($aEvent, $bPerform = false)
+    {
+        $mixedReactions = $this->getReactionsData($aEvent['reactions']);
+        if($mixedReactions === false)
+            return false;
+
+        list($sSystem, $iObjectId) = $mixedReactions;
+        $oReaction = $this->getReactionObject($sSystem, $iObjectId);
+
+        if(!$oReaction->isAllowedVote($bPerform))
+            return false;
+
+        $bResult = true;
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_reaction', $oProfileOwner->id(), (int)$this->getUserId(), array('result' => &$bResult));
+
+        return $bResult;
+    }
+
+    public function isAllowedScore($aEvent, $bPerform = false)
+    {
+        $mixedScores = $this->getScoresData($aEvent['scores']);
+        if($mixedScores === false)
+            return false;
+
+        list($sSystem, $iObjectId) = $mixedScores;
+        $oScore = $this->getScoreObject($sSystem, $iObjectId);
+
+        if(!$oScore->isAllowedVote($bPerform))
+        	return false;
+
+        $bResult = true;
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_score', $oProfileOwner->id(), (int)$this->getUserId(), array('result' => &$bResult));
+
+        return $bResult;
+    }
+
+    public function isAllowedReport($aEvent, $bPerform = false)
+    {
+        $mixedReports = $this->getReportsData($aEvent['reports']);
+        if($mixedReports === false)
+            return false;
+
+        list($sSystem, $iObjectId) = $mixedReports;
+        $oReport = $this->getReportObject($sSystem, $iObjectId);
+
+        if(!$oReport->isAllowedReport($bPerform))
+        	return false;
+
+        $bResult = true;
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_report', $oProfileOwner->id(), (int)$this->getUserId(), array('result' => &$bResult));
+
+        return $bResult;
+    }
+
+    public function isAllowedRepost($aEvent, $bPerform = false)
+    {
+        $iUserId = (int)$this->getUserId();
+        if($iUserId == 0)
+            return false;
+
+        $iPrivacy = (int)$aEvent['object_privacy_view'];
+        if($iPrivacy >= 0 && !in_array($iPrivacy, array(BX_DOL_PG_ALL, BX_DOL_PG_MEMBERS)))
+            return false;      
+
+        if(isAdmin())
+            return true;
+
+        $aCheckResult = checkActionModule($iUserId, 'repost', $this->getName(), $bPerform);
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_repost', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    public function isAllowedSend($aEvent, $bPerform = false)
+    {
+        if(!$this->_oDb->isEnabledByName('bx_convos'))
+            return false;
+
+        if(isAdmin())
+            return true;
+
+        $iUserId = (int)$this->getUserId();
+        if($iUserId == 0)
+            return false;
+
+        $aCheckResult = checkActionModule($iUserId, 'send', $this->getName(), $bPerform);
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_send', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    /**
+     * Pin - "Pin here" - pin the post on Profile Timeline for profile owner.
+     * Can be done by profile owner for himself or by admin for profile owner to see.
+     * @param type $aEvent
+     * @param type $bPerform
+     * @return boolean
+     */
+    public function isAllowedPin($aEvent, $bPerform = false)
+    {
+    	if((int)$aEvent['pinned'] != 0)
+    		return false;
+
+        return $this->_isAllowedPin($aEvent, $bPerform);
+    }
+
+    public function isAllowedUnpin($aEvent, $bPerform = false)
+    {
+    	if((int)$aEvent['pinned'] == 0)
+    		return false;
+
+        return $this->_isAllowedPin($aEvent, $bPerform);
+    }
+
+    /**
+     * Stick - "Pin for All" - pin the post on Public Timeline for everybody to see.
+     * Is available for Administrators/Moderators only.
+     * @param type $aEvent
+     * @param type $bPerform
+     * @return boolean
+     */
+    public function isAllowedStick($aEvent, $bPerform = false)
+    {
+    	if((int)$aEvent['sticked'] != 0)
+    		return false;
+    
+    	return $this->_isAllowedStick($aEvent, $bPerform);
+    }
+    
+    public function isAllowedUnstick($aEvent, $bPerform = false)
+    {
+    	if((int)$aEvent['sticked'] == 0)
+    		return false;
+    
+    	return $this->_isAllowedStick($aEvent, $bPerform);
+    }
+    
+    public function isAllowedPromote($aEvent, $bPerform = false)
+    {
+    	if((int)$aEvent['promoted'] != 0)
+    		return false;
+
+        return $this->_isAllowedPromote($aEvent, $bPerform);
+    }
+
+	public function isAllowedUnpromote($aEvent, $bPerform = false)
+    {
+    	if((int)$aEvent['promoted'] == 0)
+    		return false;
+
+        return $this->_isAllowedPromote($aEvent, $bPerform);
+    }
+
+    public function isAllowedMore($aEvent, $bPerform = false)
+    {
+    	$oMoreMenu = $this->getManageMenuObject();
+    	$oMoreMenu->setEventById($aEvent['id']);
+    	return $oMoreMenu->isVisible();
+    }
+
+    public function checkAllowedView ($aContentInfo, $isPerformAction = false)
+    {
+        if(!$this->isAllowedView($aContentInfo, $isPerformAction))
+            return _t('_sys_txt_access_denied');
+
+        return CHECK_ACTION_RESULT_ALLOWED;
+    }
+
+    public function checkAllowedCommentsView ($aContentInfo, $isPerformAction = false)
+    {
+        $CNF = $this->_oConfig->CNF;
+
+        $iOwner = (int)$aContentInfo[$CNF['FIELD_OWNER_ID']];
+        if($iOwner == 0) //--- in case of Public Timeline.
+            return CHECK_ACTION_RESULT_ALLOWED;
+
+        $oOwner = BxDolProfile::getInstance($iOwner);
+        if(!$oOwner) //--- in case of non-existed Timeline owner.
+            return _t('_sys_txt_access_denied');
+
+        $mixedResult = $oOwner->checkAllowedProfileView();
+        if($mixedResult !== CHECK_ACTION_RESULT_ALLOWED)
+            return $mixedResult;
+
+        return CHECK_ACTION_RESULT_ALLOWED;
+    }
+
+    public function checkAllowedCommentsPost ($aContentInfo, $isPerformAction = false)
+    {
+        $sError = '_sys_txt_access_denied';
+
+        $aContentInfo = $this->_oTemplate->getDataCached($aContentInfo);
+        if($aContentInfo === false)
+            return _t($sError);
+
+        if(!$this->isAllowedComment($aContentInfo, $isPerformAction))
+            return _t($sError);
+
+        return CHECK_ACTION_RESULT_ALLOWED;
+    }
+
+    public function onPost($iContentId)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+
+        if($this->_oConfig->isSystem($aEvent['type'], $aEvent['action'])) {
+            //--- Request event's data from content module and update it in the Timeline DB.
+            $this->_oTemplate->getDataCached($aEvent);
+
+            $sPostType = 'system';
+            $iSenderId = $iObjectAuthorId = (int)$aEvent['owner_id'];
+        } 
+        else {
+            $sPostType = 'common';
+            $iSenderId = $iObjectAuthorId = (int)$aEvent['object_id'];
+        }
+
+        //--- Event -> Post/Defer for Alerts Engine ---//
+        $sAction = ($aEvent[$CNF['FIELD_STATUS']] == BX_TIMELINE_STATUS_AWAITING ? 'defer' : 'post') . '_' . $sPostType;
+        bx_alert($this->_oConfig->getObject('alert'), $sAction, $iContentId, $iSenderId, array(
+            'owner_id' => $aEvent['owner_id'],
+            'object_author_id' => $iObjectAuthorId,
+            'privacy_view' => $aEvent['object_privacy_view'],
+        ));
+        //--- Event -> Post for Alerts Engine ---//
+    }
+
+    public function onPublished($iContentId)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+
+        //--- Clear Item cache
+        $this->getCacheItemObject()->removeAllByPrefix($this->_oConfig->getPrefix('cache_item') . $iContentId);
+        
+        //--- Clear Feed cache
+        $this->_oDb->deleteCache(array('context_id' => $aEvent[$CNF['FIELD_OWNER_ID']]));
+
+        $this->onPost($iContentId);
+    }
+    
+    public function onFailed($iContentId)
+    {
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+
+        //--- Clear Item cache
+        $this->getCacheItemObject()->removeAllByPrefix($this->_oConfig->getPrefix('cache_item') . $iContentId);
+
+        if($this->_oConfig->isSystem($aEvent['type'], $aEvent['action'])) {
+            //--- Request event's data from content module and update it in the Timeline DB.
+            $this->_oTemplate->getDataCached($aEvent);
+
+            $sPostType = 'system';
+            $iSenderId = $iObjectAuthorId = (int)$aEvent['owner_id'];
+        } 
+        else {
+            $sPostType = 'common';
+            $iSenderId = $iObjectAuthorId = (int)$aEvent['object_id'];
+        }
+
+        //--- Event -> Fail for Alerts Engine ---//
+        bx_alert($this->_oConfig->getObject('alert'), 'fail_' . $sPostType, $iContentId, $iSenderId, array(
+            'owner_id' => $aEvent['owner_id'],
+            'object_author_id' => $iObjectAuthorId,
+            'privacy_view' => $aEvent['object_privacy_view'],
+        ));
+        //--- Event -> Post for Alerts Engine ---//
+    }
+
+    public function onRepost($iContentId, $aReposted = array())
+    {
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+
+        if(empty($aReposted)) {
+            $aContent = unserialize($aEvent['content']);
+
+            $aReposted = $this->_oDb->getReposted($aContent['type'], $aContent['action'], $aContent['object_id']);
+            if(empty($aReposted) || !is_array($aReposted))
+                return;
+        }
+
+        $iUserId = $this->getUserId();
+        $this->_oDb->insertRepostTrack($aEvent['id'], $iUserId, $this->getUserIp(), $aReposted['id']);
+        $this->_oDb->updateRepostCounter($aReposted['id'], $aReposted['reposts']);
+
+        //--- Timeline -> Update for Alerts Engine ---//
+        bx_alert($this->_oConfig->getObject('alert'), 'repost', $aReposted['id'], $iUserId, array(
+            'privacy_view' => $aEvent['object_privacy_view'],
+            'object_author_id' => $aReposted['owner_id'],
+            'repost_id' => $iContentId,
+        ));
+        //--- Timeline -> Update for Alerts Engine ---//
+    }
+
+    public function onDelete($aEvent)
+    {
+        $iUserId = $this->getUserId();
+    	$sCommonPostPrefix = $this->_oConfig->getPrefix('common_post');
+    	$sCommonPostComment = $this->_oConfig->getObject('comment');
+    	
+    	//--- Delete comments for Common posts.
+    	if($this->_oConfig->isCommon($aEvent['type'], $aEvent['action'])) {
+            $oComments = $this->getCmtsObject($sCommonPostComment, $aEvent['id']);
+            if($oComments !== false)
+                $oComments->onObjectDelete($aEvent['id']);
+    	}
+
+    	//--- Delete attached photos, videos and links when common event was deleted.
+    	if($aEvent['type'] == $sCommonPostPrefix . BX_TIMELINE_PARSE_TYPE_POST) {
+    		$this->_deleteMedia(BX_TIMELINE_MEDIA_PHOTO, $aEvent['id']);
+    		$this->_deleteMedia(BX_TIMELINE_MEDIA_VIDEO, $aEvent['id']);
+
+	        $this->_deleteLinks($aEvent['id']);
+    	}
+
+    	//--- Update parent event when repost event was deleted.
+    	$bRepost = $aEvent['type'] == $sCommonPostPrefix . BX_TIMELINE_PARSE_TYPE_REPOST;
+        if($bRepost) {
+            $this->_oDb->deleteRepostTrack($aEvent['id']);
+
+            $aContent = unserialize($aEvent['content']);
+            $aReposted = $this->_oDb->getReposted($aContent['type'], $aContent['action'], $aContent['object_id']);
+            if(!empty($aReposted) && is_array($aReposted))
+                $this->_oDb->updateRepostCounter($aReposted['id'], $aReposted['reposts'], -1);
+        }
+
+        //--- Find and delete repost events when parent event was deleted.
+        $bSystem = $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']);
+	    $aRepostEvents = $this->_oDb->getEvents(array('browse' => 'reposted_by_descriptor', 'type' => $aEvent['type']));
+		foreach($aRepostEvents as $aRepostEvent) {
+			$aContent = unserialize($aRepostEvent['content']);
+			if(isset($aContent['type']) && $aContent['type'] == $aEvent['type'] && isset($aContent['object_id']) && (($bSystem && (int)$aContent['object_id'] == (int)$aEvent['object_id']) || (!$bSystem  && (int)$aContent['object_id'] == (int)$aEvent['id'])) && (int)$this->_oDb->deleteEvent(array('id' => (int)$aRepostEvent['id'])) > 0) {
+			    $oComments = $this->getCmtsObject($sCommonPostComment, $aRepostEvent['id']);
+                if($oComments !== false)
+                    $oComments->onObjectDelete($aRepostEvent['id']);
+
+                bx_alert($this->_oConfig->getObject('alert'), 'delete_repost', $aEvent['id'], $iUserId, array(
+                    'repost_id' => $aRepostEvent['id'],
+                ));
+            }
+		}
+
+		//--- Delete associated meta.
+        $oMetatags = BxDolMetatags::getObjectInstance($this->_oConfig->getObject('metatags'));
+        $oMetatags->onDeleteContent($aEvent['id']);
+
+        //--- Event -> Delete for Alerts Engine ---//
+        if($bRepost)
+            bx_alert($this->_oConfig->getObject('alert'), 'delete_repost', $aReposted['id'], $iUserId, array(
+                'repost_id' => $aEvent['id'],
+            ));
+        else
+            bx_alert($this->_oConfig->getObject('alert'), 'delete', $aEvent['id'], $iUserId);
+        //--- Event -> Delete for Alerts Engine ---//
+    }
+
+    public function getParams($sView = '', $sType = '', $iOwnerId = 0, $iStart = 0, $iPerPage = 0, $sFilter = BX_TIMELINE_FILTER_ALL, $aModules = array(), $iTimeline = 0)
+    {
+        return $this->_prepareParams(array(
+            'view' => $sView,
+            'type' => $sType,
+            'owner_id' => $iOwnerId,
+            'start' => $iStart, 
+            'per_page' => $iPerPage, 
+            'timeline' => $iTimeline, 
+            'filter' => $sFilter, 
+            'modules' => $aModules
+        ));
+    }
+
+    public function getParamsExt($aParams = array())
+    {
+        return $this->_prepareParams($aParams);
+    }
+
+    public function getViewsData(&$aViews)
+    {
+        if(empty($aViews) || !is_array($aViews))
+            return false;
+
+        $sSystem = isset($aViews['system']) ? $aViews['system'] : '';
+        $iObjectId = isset($aViews['object_id']) ? (int)$aViews['object_id'] : 0;
+        $iCount = isset($aViews['count']) ? (int)$aViews['count'] : 0;
+        if($sSystem == '' || $iObjectId == 0)
+            return false;
+
+        return array($sSystem, $iObjectId, $iCount);
+    }
+
+    public function getVotesData(&$aVotes)
+    {
+        if(empty($aVotes) || !is_array($aVotes))
+            return false;
+
+        $sSystem = isset($aVotes['system']) ? $aVotes['system'] : '';
+        $iObjectId = isset($aVotes['object_id']) ? (int)$aVotes['object_id'] : 0;
+        $iCount = isset($aVotes['count']) ? (int)$aVotes['count'] : 0;
+        if($sSystem == '' || $iObjectId == 0)
+            return false;
+
+        return array($sSystem, $iObjectId, $iCount);
+    }
+
+    public function getReactionsData(&$aReactions)
+    {
+        if(empty($aReactions) || !is_array($aReactions))
+            return false;
+
+        $sSystem = isset($aReactions['system']) ? $aReactions['system'] : '';
+        $iObjectId = isset($aReactions['object_id']) ? (int)$aReactions['object_id'] : 0;
+        $iCount = isset($aReactions['count']) ? (int)$aReactions['count'] : 0;
+        if($sSystem == '' || $iObjectId == 0)
+            return false;
+
+        return array($sSystem, $iObjectId, $iCount);
+    }
+
+    public function getScoresData(&$aScores)
+    {
+        if(empty($aScores) || !is_array($aScores))
+            return false;
+
+        $sSystem = isset($aScores['system']) ? $aScores['system'] : '';
+        $iObjectId = isset($aScores['object_id']) ? (int)$aScores['object_id'] : 0;
+        $iScore = isset($aScores['score']) ? (int)$aScores['score'] : 0;
+        if($sSystem == '' || $iObjectId == 0)
+            return false;
+
+        return array($sSystem, $iObjectId, $iScore);
+    }
+
+    public function getReportsData(&$aReports)
+    {
+        if(empty($aReports) || !is_array($aReports))
+            return false;
+
+        $sSystem = isset($aReports['system']) ? $aReports['system'] : '';
+        $iObjectId = isset($aReports['object_id']) ? (int)$aReports['object_id'] : 0;
+        $iCount = isset($aReports['count']) ? (int)$aReports['count'] : 0;
+        if($sSystem == '' || $iObjectId == 0)
+            return false;
+
+        return array($sSystem, $iObjectId, $iCount);
+    }
+
+    public function getCommentsData(&$aComments)
+    {
+        if(empty($aComments) || !is_array($aComments))
+            return false;
+
+        $sSystem = isset($aComments['system']) ? $aComments['system'] : '';
+        $iObjectId = isset($aComments['object_id']) ? (int)$aComments['object_id'] : 0;
+        $iCount = isset($aComments['count']) ? (int)$aComments['count'] : 0;
+        if($sSystem == '' || $iObjectId == 0 || ($iCount == 0 && !isLogged()))
+            return false;
+
+        return array($sSystem, $iObjectId, $iCount);
+    }
+
+    public function getUserInfo($iUserId = 0)
+    {
+        $iLoggedId = $this->getUserId();
+        $iUserId = (int)$iUserId;
+        return parent::getUserInfo($iUserId);
+    }
+
+    /**
+     * Protected Methods 
+     */
+    protected function _serviceGetBlockView($iProfileId = 0, $aBrowseParams = array())
+    {
+        if(empty($iProfileId) && bx_get('profile_id') !== false)
+            $iProfileId = bx_process_input(bx_get('profile_id'), BX_DATA_INT);
+
+        if(empty($iProfileId) && isLogged())
+            $iProfileId = bx_get_logged_profile_id();
+
+        $aBrowseParams['owner_id'] = $iProfileId;
+
+        $aBlock = $this->_getBlockView($aBrowseParams);
+        if(!empty($aBlock))
+            return $aBlock;
+
+        return array('content' => MsgBox(_t('_bx_timeline_txt_msg_no_results')));
+    }
+
+    protected function _serviceGetBlockViewProfile($sProfileModule = 'bx_persons', $iProfileContentId = 0, $aBrowseParams = array())
+    {
+        if(empty($sProfileModule))
+            return array();
+
+        if(empty($iProfileContentId) && bx_get('id') !== false)
+            $iProfileContentId = bx_process_input(bx_get('id'), BX_DATA_INT);
+
+        $oProfile = BxDolProfile::getInstanceByContentAndType($iProfileContentId, $sProfileModule);
+        if(empty($oProfile))
+            return array();
+
+        $aBrowseParams['owner_id'] = $oProfile->id();
+
+        return $this->_getBlockView($aBrowseParams);
+    }
+
+    protected function _serviceGetBlockViewHome($aBrowseParams = array())
+    {
+        $sRssUrl = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'rss/' . $aBrowseParams['type'] . '/';
+        BxDolTemplate::getInstance()->addPageRssLink(_t('_bx_timeline_page_title_view_home'), $sRssUrl);
+
+        return $this->_serviceGetBlockViewByType($aBrowseParams);
+    }
+
+    protected function _serviceGetBlockViewHot($aBrowseParams = array())
+    {
+        $sRssUrl = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'rss/' . $aBrowseParams['type'] . '/';
+        BxDolTemplate::getInstance()->addPageRssLink(_t('_bx_timeline_page_title_view_hot'), $sRssUrl);
+
+        return $this->_serviceGetBlockViewByType($aBrowseParams);
+    }
+
+    protected function _serviceGetBlockViewByType($aBrowseParams = array())
+    {
+        $aParams = $this->_prepareParams($aBrowseParams);
+
+        $this->_iOwnerId = $aParams['owner_id'];
+
+        return array(
+            'content' => $this->_oTemplate->getViewBlock($aParams)
+        );
+    }
+
+    protected function _getBlockPost($iProfileId, $aParams = array())
+    {
+        $this->_iOwnerId = $iProfileId;
+
+        if($this->isAllowedPost() !== true)
+            return array();
+
+        return array(
+            'content' => $this->_oTemplate->getPostBlock($this->_iOwnerId, $aParams)
+        );
+    }
+
+    protected function _getBlockView($aBrowseParams = array())
+    {
+        if(empty($aBrowseParams['owner_id']))
+            return array();
+
+        $aParams = $this->_prepareParams($aBrowseParams);
+        if(empty($aParams['per_page']))
+            $aParams['per_page'] = $this->_oConfig->getPerPage('profile');
+
+        $this->_iOwnerId = $aParams['owner_id'];
+        $oProfileOwner = BxDolProfile::getInstance($this->_iOwnerId);
+
+        $mixedResult = $oProfileOwner->checkAllowedProfileView();
+        if($mixedResult !== CHECK_ACTION_RESULT_ALLOWED)
+            return array('content' => MsgBox($mixedResult));
+
+        list($sUserName) = $this->getUserInfo($aParams['owner_id']);
+
+        $sView = $aParams['view'];
+        $sRssUrl = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'rss/' . BX_BASE_MOD_NTFS_TYPE_OWNER . '/' . $this->_iOwnerId . '/';
+        $sJsObject = $this->_oConfig->getJsObjectView($aParams);
+        $aMenu = array(
+            array('id' => $sView . '-view-all', 'name' => $sView . '-view-all', 'class' => '', 'link' => 'javascript:void(0)', 'onclick' => 'javascript:' . $sJsObject . '.changeFilter(this)', 'target' => '_self', 'title' => _t('_bx_timeline_menu_item_view_all'), 'active' => 1),
+            array('id' => $sView . '-view-owner', 'name' => $sView . '-view-owner', 'class' => '', 'link' => 'javascript:void(0)', 'onclick' => 'javascript:' . $sJsObject . '.changeFilter(this)', 'target' => '_self', 'title' => _t('_bx_timeline_menu_item_view_owner', $sUserName)),
+            array('id' => $sView . '-view-other', 'name' => $sView . '-view-other', 'class' => '', 'link' => 'javascript:void(0)', 'onclick' => 'javascript:' . $sJsObject . '.changeFilter(this)', 'target' => '_self', 'title' => _t('_bx_timeline_menu_item_view_other')),
+            array('id' => $sView . '-get-rss', 'name' => $sView . '-get-rss', 'class' => '', 'link' => $sRssUrl, 'onclick' => '', 'target' => '_blank', 'title' => _t('_bx_timeline_menu_item_get_rss')),
+        );
+
+        $sContent = '';
+        bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_view', $this->_iOwnerId, $this->getUserId(), array('override_content' => &$sContent, 'params' => &$aParams, 'menu' => &$aMenu));
+
+        $oMenu = new BxTemplMenuInteractive(array('template' => 'menu_interactive_vertical.html', 'menu_id'=> $sView . '-view-all', 'menu_items' => $aMenu));
+        $oMenu->setSelected('', $sView . '-view-all');
+
+        if (!$sContent)
+            $sContent = $this->_oTemplate->getViewBlock($aParams);
+
+        BxDolTemplate::getInstance()->addPageRssLink(_t('_bx_timeline_page_title_view'), $sRssUrl);
+
+        return array('content' => $sContent, 'menu' => $oMenu);
+    }
+    
+    protected function _getContentForTimelinePost($aEvent, $aContentInfo, $aBrowseParams = array())
+    {
+    	$CNF = &$this->_oConfig->CNF;
+
+    	$sUrl = BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink('page.php?i=' . $CNF['URI_VIEW_ENTRY'] . '&id=' . $aContentInfo[$CNF['FIELD_ID']]);
+
+        $sText = ''; 
+        if(isset($aContentInfo['content'])){
+            $aTmp = unserialize($aContentInfo['content']);
+            if(isset($aTmp['text']))
+                $sText = $aTmp['text'];
+        }
+
+        if(empty($sText) && !empty($aContentInfo[$CNF['FIELD_TITLE']]))
+            $sText = $aContentInfo[$CNF['FIELD_TITLE']];
+
+        if(!empty($CNF['OBJECT_METATAGS']) && !empty($sText)) {
+            $oMetatags = BxDolMetatags::getObjectInstance($CNF['OBJECT_METATAGS']);
+            $sText = $oMetatags->metaParse($aContentInfo[$CNF['FIELD_ID']], $sText);
+        }
+
+        return array(
+            'sample' => isset($CNF['T']['txt_sample_single_with_article']) ? $CNF['T']['txt_sample_single_with_article'] : $CNF['T']['txt_sample_single'],
+            'sample_wo_article' => $CNF['T']['txt_sample_single'],
+            'sample_action' => isset($CNF['T']['txt_sample_action']) ? $CNF['T']['txt_sample_action'] : '',
+            'url' => $sUrl,
+            'title' => '',
+            'text' => $sText,
+            'images' => array(),
+            'videos' => array()
+        );
+    }
+
+	protected function _isAllowedPin($aEvent, $bPerform = false)
+    {
+    	$iUserId = (int)$this->getUserId();
+    	if($iUserId == 0)
+    		return false;
+
+		if(isAdmin() || (int)$aEvent['owner_id'] == $iUserId || ((int)$aEvent['owner_id'] == 0 && $this->_oConfig->isCommon($aEvent['type'], $aEvent['action']) && (int)$aEvent['object_id'] == $iUserId))
+           return true;
+
+        $aCheckResult = checkActionModule($iUserId, 'pin', $this->getName(), $bPerform);
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_pin', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    protected function _isAllowedStick($aEvent, $bPerform = false)
+    {
+    	$iUserId = (int)$this->getUserId();
+    	if($iUserId == 0)
+    		return false;
+
+    	if(isAdmin())
+    		return true;
+
+    	$aCheckResult = checkActionModule($iUserId, 'stick', $this->getName(), $bPerform);
+    	if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_stick', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+    
+    	return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    protected function _isAllowedPromote($aEvent, $bPerform = false)
+    {
+        if(isAdmin())
+            return true;
+
+        $iUserId = (int)$this->getUserId();
+        if($iUserId == 0)
+            return false;
+
+        $aCheckResult = checkActionModule($iUserId, 'promote', $this->getName(), $bPerform);
+        if(!empty($aEvent['owner_id']) && ($oProfileOwner = BxDolProfile::getInstance($aEvent['owner_id'])) !== false)
+            bx_alert($oProfileOwner->getModule(), $this->_oConfig->getUri() . '_promote', $oProfileOwner->id(), $iUserId, array('check_result' => &$aCheckResult));
+
+        return $aCheckResult[CHECK_ACTION_RESULT] !== CHECK_ACTION_RESULT_ALLOWED ? $aCheckResult[CHECK_ACTION_MESSAGE] : true;
+    }
+
+    protected function _addLink(&$oForm)
+    {
+        $iUserId = $this->getUserId();
+
+        $sLink = $oForm->getCleanValue('url');
+
+        $aMatches = array();
+        preg_match($this->_oConfig->getPregPattern('url'), $sLink, $aMatches);
+        $sLink = (empty($aMatches[2]) ? 'http://' : '') . $aMatches[0];
+
+        $aSiteInfo = bx_get_site_info($sLink, array(
+            'thumbnailUrl' => array('tag' => 'link', 'content_attr' => 'href'),
+            'OGImage' => array('name_attr' => 'property', 'name' => 'og:image'),
+        ));
+
+        $sTitle = !empty($aSiteInfo['title']) ? $aSiteInfo['title'] : _t('_Empty');
+        $sDescription = !empty($aSiteInfo['description']) ? $aSiteInfo['description'] : _t('_Empty');
+
+        $sMediaUrl = '';
+        if(!empty($aSiteInfo['thumbnailUrl']))
+        	$sMediaUrl = $aSiteInfo['thumbnailUrl'];
+        else if(!empty($aSiteInfo['OGImage']))
+        	$sMediaUrl = $aSiteInfo['OGImage'];
+
+		$iMediaId = 0;
+		$oStorage = null;
+        if(!empty($sMediaUrl)) {
+        	$oStorage = BxDolStorage::getObjectInstance($this->_oConfig->getObject('storage_' . BX_TIMELINE_MEDIA_PHOTO . 's'));
+
+        	$iMediaId = $oStorage->storeFileFromUrl($sMediaUrl, true, $iUserId);
+        }
+
+        $iId = (int)$oForm->insert(array('profile_id' => $iUserId, 'media_id' => $iMediaId, 'url' => $sLink, 'title' => $sTitle, 'text' => $sDescription, 'added' => time()));
+        if(!empty($iId)) {
+        	if(!empty($oStorage) && !empty($iMediaId))
+        		$oStorage->afterUploadCleanup($iMediaId, $iUserId);
+
+            return array('id' => $iId, 'item' => $this->_oTemplate->getAttachLinkItem($iUserId, $iId));
+        }
+
+        return array('message' => _t('_bx_timeline_txt_err_cannot_perform_action'));
+    }
+
+	protected function _deleteLinks($iId)
+    {
+	    $aLinks = $this->_oDb->getLinks($iId);
+	    if(empty($aLinks) || !is_array($aLinks))
+	    	return;
+
+		$oStorage = BxDolStorage::getObjectInstance($this->_oConfig->getObject('storage_photos'));
+		foreach($aLinks as $aLink)
+			if(!empty($aLink['media_id']))
+				$oStorage->deleteFile($aLink['media_id']);
+
+		$this->_oDb->deleteLinks($iId);
+    }
+
+    protected function _saveMedia($sType, $iId, $aItemIds)
+    {
+    	if(empty($aItemIds) || !is_array($aItemIds))
+    		return; 
+
+    	$iUserId = $this->getUserId();
+
+		$oStorage = BxDolStorage::getObjectInstance($this->_oConfig->getObject('storage_' . strtolower($sType) . 's'));
+		foreach($aItemIds as $iItemId)
+        	if($this->_oDb->saveMedia($sType, $iId, $iItemId))
+            	$oStorage->afterUploadCleanup($iItemId, $iUserId);
+    }
+
+    protected function _deleteMedia($sType, $iId)
+    {
+	    $aItems = $this->_oDb->getMedia($sType, $iId);
+	    if(empty($aItems) || !is_array($aItems))
+	    	return;
+
+		$oStorage = BxDolStorage::getObjectInstance($this->_oConfig->getObject('storage_' . strtolower($sType) . 's'));
+		foreach($aItems as $iItemId)
+			$oStorage->deleteFile($iItemId);
+
+		$this->_oDb->deleteMedia($sType, $iId);
+    }
+
+    protected function _prepareParams($aParams)
+    {
+        if(empty($aParams['name']))
+            $aParams['name'] = '';
+        
+        if(empty($aParams['view']))
+            $aParams['view'] = BX_TIMELINE_VIEW_DEFAULT;
+
+        if(empty($aParams['type']))
+            $aParams['type'] = BX_TIMELINE_TYPE_DEFAULT;
+
+        if(empty($aParams['owner_id']))
+            $aParams['owner_id'] = $this->getUserId();
+
+        if(!isset($aParams['start']) || (int)$aParams['start'] < 0)
+            $aParams['start'] = 0;
+
+        if(!isset($aParams['per_page']) || (int)$aParams['per_page'] <= 0)
+            $aParams['per_page'] = isset($aParams['per_page_default']) && (int)$aParams['per_page_default'] > 0 ? $aParams['per_page_default'] : $this->_oConfig->getPerPage();
+
+        if(empty($aParams['timeline']) || (int)$aParams['timeline'] < 0)
+            $aParams['timeline'] = 0;
+
+        if(empty($aParams['filter']))
+            $aParams['filter'] = BX_TIMELINE_FILTER_ALL;
+
+        if(empty($aParams['modules']) || !is_array($aParams['modules']))
+            $aParams['modules'] = array();
+
+        if(empty($aParams['blink']) || !is_array($aParams['blink']))
+            $aParams['blink'] = array();
+
+        if($this->_oConfig->isHot())
+            $aParams['hot'] = $this->_oDb->getHot();
+
+        $aParams = array_merge($aParams, array(
+            'browse' => 'list',
+            'status' => BX_TIMELINE_STATUS_ACTIVE
+        ));
+
+        return $aParams;
+    }
+
+    protected function _prepareParamsGet()
+    {
+        $aParams = array();
+
+        $aParams['name'] = bx_get('name');
+        $aParams['name'] = $aParams['name'] !== false ? bx_process_input($aParams['name'], BX_DATA_TEXT) : '';
+
+        $aParams['view'] = bx_get('view');
+        $aParams['view'] = $aParams['view'] !== false ? bx_process_input($aParams['view'], BX_DATA_TEXT) : BX_TIMELINE_VIEW_DEFAULT;
+
+        $aParams['type'] = bx_get('type');
+        $aParams['type'] = $aParams['type'] !== false ? bx_process_input($aParams['type'], BX_DATA_TEXT) : BX_TIMELINE_TYPE_DEFAULT;
+
+        $aParams['owner_id'] = bx_get('owner_id');
+        $aParams['owner_id'] = $aParams['owner_id'] !== false ? bx_process_input($aParams['owner_id'], BX_DATA_INT) : $this->getUserId();
+
+        $aParams['start'] = bx_get('start');
+        $aParams['start'] = $aParams['start'] !== false ? bx_process_input($aParams['start'], BX_DATA_INT) : 0;
+
+        $aParams['per_page'] = bx_get('per_page');
+        $aParams['per_page'] = $aParams['per_page'] !== false ? bx_process_input($aParams['per_page'], BX_DATA_INT) : $this->_oConfig->getPerPage();
+
+        $aParams['timeline'] = bx_get('timeline');
+        $aParams['timeline'] = $aParams['timeline'] !== false ? bx_process_input($aParams['timeline'], BX_DATA_INT) : 0;
+
+        $aParams['filter'] = bx_get('filter');
+        $aParams['filter'] = $aParams['filter'] !== false ? bx_process_input($aParams['filter'], BX_DATA_TEXT) : BX_TIMELINE_FILTER_ALL;
+
+        $aParams['modules'] = bx_get('modules');
+        $aParams['modules'] = $aParams['modules'] !== false ? bx_process_input($aParams['modules'], BX_DATA_TEXT) : array();
+
+        $aParams['blink'] = bx_get('blink');
+        $aParams['blink'] = $aParams['blink'] !== false ? explode(',', bx_process_input($aParams['blink'], BX_DATA_TEXT)) : array();
+
+        if($this->_oConfig->isHot())
+            $aParams['hot'] = $this->_oDb->getHot();
+
+        $aParams = array_merge($aParams, array(
+            'browse' => 'list',
+            'status' => BX_TIMELINE_STATUS_ACTIVE,
+            'dynamic_mode' => true,
+        ));
+
+        return $aParams;
+    }
+
+    protected function _prepareTextForSave($s)
+    {
+        return bx_process_input($s, BX_DATA_HTML);
+    }
+
+    protected function _getFieldValue($sField, $iContentId)
+    {
+        $CNF = &$this->_oConfig->CNF;
+        if(empty($CNF[$sField]))
+            return false;
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iContentId));
+        if(empty($aEvent) || empty($aEvent[$CNF[$sField]]))
+            return false;
+
+        return $aEvent[$CNF[$sField]];
+    }
+
+    /**
+     * Returns records for React Jot using OAuth2
+     * @param int $iProfileId
+     * @param string $sPage
+     * @param string $sTab
+     * @param int $iStart
+     * @param int $iPerPage
+     * @return array
+     */
+    public function serviceGetUserPosts($iProfileId = 0, $sPage = 'home', $sTab = 'hot', $iStart = 0, $iPerPage = 0)
+    {
+        $iProfileId = (int)$iProfileId ? (int)$iProfileId : bx_get_logged_profile_id();
+        if(empty($iProfileId))
+            return array(
+                'code' => 1,
+                'result' => array(),
+                'message' => _t('_bx_timeline_txt_msg_no_profile_id'),
+                'page' => $sPage,
+                'tab' => $sTab
+            );
+
+        $sType = BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS;
+        $sView = BX_TIMELINE_VIEW_DEFAULT;
+        $sFilter = BX_TIMELINE_FILTER_ALL;
+
+        $aModules = array();
+
+        switch($sPage){
+            case 'profile':
+                $sType = BX_BASE_MOD_NTFS_TYPE_OWNER;
+                $sFilter = BX_TIMELINE_FILTER_OWNER;
+                break;
+            default:
+                if ($this -> _oDb -> isModuleByName($sPage))
+                   $aModules = array($sPage);
+        }
+
+        switch($sTab)
+        {
+            case 'latest':
+                $sType = BX_BASE_MOD_NTFS_TYPE_PUBLIC;
+                break;
+            case 'popular':
+                $sType = BX_TIMELINE_TYPE_HOT;
+                break;
+            case 'feed':
+                $sType = BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS;
+                break;
+            default:
+                if ($this -> _oDb -> isModuleByName($sTab))
+                    $aModules = array($sTab);
+        }
+
+        $aParams = $this->getParams($sView, $sType, $iProfileId, $iStart, $iPerPage, $sFilter, $aModules);
+        $aData = $this->_oDb->getEvents($aParams, true);
+
+        list($aEvents, $iCount) = $aData;
+
+        if(empty($aEvents) || !is_array($aEvents))
+            return array(
+                'code' => 0,
+                'result' => array(),
+                'message' => _t('_bx_timeline_txt_msg_no_results'),
+                'page' => $sPage,
+                'tab' => $sTab
+            );
+
+        $aBrowseParams = array();
+        $aItems = array();
+
+        foreach($aEvents as $aEvent) {
+            $aResult = $this->_oTemplate->getData($aEvent, $aBrowseParams);
+
+            if($aResult === false)
+                continue;
+
+            $oOwnerProfile = BxDolProfile::getInstance($aResult['owner_id']);
+
+            $aFiles = array();
+            $aContent = &$aResult['content'];
+
+            if (!empty($aContent['image']))
+                $aFiles['images'] = array_values($aContent['images']);
+            if (!empty($aContent['images_attach']))
+                $aFiles['images'] = array_values($aContent['images_attach']);
+
+            if (!empty($aContent['videos']))
+                $aFiles['videos'] = array_values($aContent['videos']);
+            else
+            if (!empty($aContent['videos_attach']))
+                $aFiles['videos'] = array_values($aContent['videos_attach']);
+
+            if (!empty($aContent['files']))
+                $aFiles['files'] = array_values($aContent['files']);
+            else
+                if (!empty($aContent['files_attach']))
+                    $aFiles['files'] = array_values($aContent['files_attach']);
+
+            $aItems[$aEvent['id']] = array_merge(array(
+                'owner' => array(
+                    'icon' => $oOwnerProfile -> getThumb(),
+                    'name' => $oOwnerProfile -> getDisplayName(),
+                    'url' => $oOwnerProfile -> getUrl()
+                ),
+                'sample' => !empty($aResult['sample']) ? _t($aResult['sample']) : _t('_bx_timeline_txt_sample'),
+                'sample_action' => !empty($aResult['sample_action']) ? _t($aResult['sample_action']) : _t('_bx_timeline_txt_added_sample'),
+                'url' => isset($aResult['url']) ? $aResult['url'] : '',
+                'raw' => isset($aContent['raw']) ? strip_tags($aContent['raw']) : '',
+                'text' => isset($aContent['text']) ? strip_tags($aContent['text']) : '',
+                'views' => isset($aResult['views']['count']) ? (int)$aResult['views']['count'] : 0,
+                'votes' => isset($aResult['votes']['count']) ? (int)$aResult['votes']['count'] : 0,
+                'reactions' => isset($aResult['reactions']['count']) ? (int)$aResult['reactions']['count'] : 0,
+                'scores' => isset($aResult['scores']['count']) ? (int)$aResult['scores']['count'] : 0,
+                'reports' => isset($aResult['reports']['count']) ? (int)$aResult['reports']['count'] : 0,
+                'comments' => isset($aResult['comments']['count']) ? (int)$aResult['comments']['count'] : 0,
+                'date' => isset($aResult['date']) ? $aResult['date'] : $aEvent['date'],
+                'type' => stripos($aEvent['type'], 'timeline') !== FALSE ? 'bx_timeline' : $aEvent['type'],
+                'event_type' => $aEvent['type'],
+                'id' => $aEvent['id'],
+                'content' => $aResult['content'],
+                'title' => isset($aResult['title']) ? _t($aResult['title']) : '',
+                'description' => isset($aResult['description']) ? $aResult['description'] : ''
+            ), $aFiles);
+        }
+
+        return array(
+            'result' => $aItems,
+            'code' => 0,
+            'message' => '',
+            'page' => $sPage,
+            'tab' => $sTab,
+            'total' => $iCount,
+            'start' => (int)$iStart
+        );
+    }
+}
+
+/** @} */

+ 61 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelinePrivacy.php

@@ -0,0 +1,61 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelinePrivacy extends BxBaseModNotificationsPrivacy
+{
+    protected $_oModule;
+
+	public function __construct ($aOptions, $oTemplate = false)
+    {
+        parent::__construct ($aOptions, $oTemplate);
+
+        $this->_oModule = BxDolModule::getInstance('bx_timeline');
+    }
+
+    public function addSpaces($aValues, $iOwnerId, $aParams)
+    {
+        if (!$this->_aObject['spaces'])
+            return $aValues;
+
+        if (!($oProfile = BxDolProfile::getInstance($iOwnerId)))
+            return $aValues;
+
+        if (!($aModules = BxDolModuleQuery::getInstance()->getModules()))
+            return $aValues;
+            
+        $oProfileQuery = BxDolProfileQuery::getInstance();
+
+        $sConnections = $this->_oModule->_oConfig->getObject('conn_subscriptions');
+        $aConnections = BxDolConnection::getObjectInstance($sConnections)->getConnectedContent($iOwnerId);
+
+        $aCnnGroups = array();
+        foreach($aConnections as $iId) {
+            $aProfileInfo = $oProfileQuery->getInfoById($iId);
+            if(empty($aProfileInfo) || !is_array($aProfileInfo))
+                continue;
+
+            $aCnnGroups[$aProfileInfo['type']][] = $aProfileInfo['id'];
+        }
+
+        $oProfile = BxDolProfile::getInstance();
+        foreach($aCnnGroups as $sCnnGroup => $aCnnGroup) {
+            $aValues[] = array('type' => 'group_header', 'value' => mb_strtoupper(_t('_bx_timeline_form_post_input_owner_id_following_group', _t('_' . $sCnnGroup))));
+            foreach($aCnnGroup as $iId)
+                $aValues[] = array('key' => -$iId, 'value' => $oProfile->getDisplayName($iId));
+            $aValues[] = array('type' => 'group_end');
+        }
+
+        return $aValues;
+    }
+    
+}
+
+/** @} */

+ 186 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineResponse.php

@@ -0,0 +1,186 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineResponse extends BxBaseModNotificationsResponse
+{
+    public function __construct()
+    {
+        parent::__construct();
+
+        $this->_oModule = BxDolModule::getInstance('bx_timeline');
+    }
+
+    /**
+     * Overwtire the method of parent class.
+     *
+     * @param BxDolAlerts $oAlert an instance of alert.
+     */
+    public function response($oAlert)
+    {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
+        $sMethod = '_process' . bx_gen_method_name($oAlert->sUnit . '_' . $oAlert->sAction);           	
+        if(method_exists($this, $sMethod))
+            return $this->$sMethod($oAlert);
+
+        $iObjectAuthorId = $this->_getObjectOwnerId($oAlert->aExtras);
+    	$iObjectPrivacyView = $this->_getObjectPrivacyView($oAlert->aExtras);
+        if($iObjectPrivacyView == BX_DOL_PG_HIDDEN)
+            return;
+
+        $aHandler = $this->_oModule->_oConfig->getHandlers($oAlert->sUnit . '_' . $oAlert->sAction);
+        switch($aHandler['type']) {
+            case BX_BASE_MOD_NTFS_HANDLER_TYPE_INSERT:
+                $iOwnerId = abs($oAlert->iSender);
+                if($iObjectPrivacyView < 0)
+                    $iOwnerId = abs($iObjectPrivacyView);
+
+                $sContent = !empty($oAlert->aExtras) && is_array($oAlert->aExtras) ? serialize(bx_process_input($oAlert->aExtras)) : '';
+
+                $iId = $this->_oModule->_oDb->insertEvent(array(
+                    'owner_id' => $iOwnerId,
+                    'type' => $oAlert->sUnit,
+                    'action' => $oAlert->sAction,
+                    'object_id' => $oAlert->iObject,
+                    'object_privacy_view' => $iObjectPrivacyView,
+                    'content' => $sContent,
+                    'title' => '',
+                    'description' => ''
+                ));
+
+                if(!empty($iId))
+                    $this->_oModule->onPost($iId);
+                break;
+
+            case BX_BASE_MOD_NTFS_HANDLER_TYPE_UPDATE:
+                $aEvent = $this->_oModule->_oDb->getEvents(array('browse' => 'descriptor', 'type' => $oAlert->sUnit, 'object_id' => $oAlert->iObject));
+                if(empty($aEvent) || !is_array($aEvent))
+                    break;
+
+                $aParamsSet = array(
+                    'content' => !empty($oAlert->aExtras) && is_array($oAlert->aExtras) ? serialize(bx_process_input($oAlert->aExtras)) : ''
+                );
+
+                if($iObjectPrivacyView > 0 && !empty($iObjectAuthorId) && $iObjectAuthorId == $oAlert->iSender)
+                    $aParamsSet = array_merge($aParamsSet, array(
+                        'owner_id' => $oAlert->iSender,
+                        'object_privacy_view' => $iObjectPrivacyView
+                    ));
+                else if($iObjectPrivacyView < 0)
+                    $aParamsSet = array_merge($aParamsSet, array(
+                        'owner_id' => abs($iObjectPrivacyView),
+                        'object_privacy_view' => $this->_oModule->_oConfig->getPrivacyViewDefault('object') 
+                    ));
+
+                $this->_oModule->_oDb->updateEvent($aParamsSet, array('type' => $oAlert->sUnit, 'object_id' => $oAlert->iObject));
+
+                //--- Delete cached
+                $this->_oModule->_oDb->deleteCache(array('context_id' => 0)); //--- Delete cache for Public feed
+                $this->_oModule->_oDb->deleteCache(array('context_id' => $aEvent[$CNF['FIELD_OWNER_ID']])); //--- Delete cache for old context
+                $this->_oModule->_oDb->deleteCache(array('context_id' => $aParamsSet['owner_id'])); //--- Delete cache for new context
+                break;
+
+            case BX_BASE_MOD_NTFS_HANDLER_TYPE_DELETE:
+                if($oAlert->sUnit == 'profile' && $oAlert->sAction == 'delete') {
+                    $aEvents = $this->_oModule->_oDb->getEvents(array('browse' => 'owner_id', 'value' => $oAlert->iObject));
+                    foreach($aEvents as $aEvent)
+                        $this->_oModule->deleteEvent($aEvent);
+
+                    if(isset($oAlert->aExtras['delete_with_content']) && $oAlert->aExtras['delete_with_content']) {
+                        $aEvents = $this->_oModule->_oDb->getEvents(array('browse' => 'common_by_object', 'value' => $oAlert->iObject));
+                        foreach($aEvents as $aEvent)
+                            $this->_oModule->deleteEvent($aEvent);
+                    }
+
+                    //--- Delete cached
+                    $this->_oModule->_oDb->deleteCache(array('context_id' => $oAlert->iObject));
+                    $this->_oModule->_oDb->deleteCache(array('profile_id' => $oAlert->iObject));
+                    break;
+                }
+
+            	$aHandlers = $this->_oModule->_oDb->getHandlers(array('type' => 'by_group_key_type', 'group' => $aHandler['group']));
+
+            	$aEvent = $this->_oModule->_oDb->getEvents(array(
+                    'browse' => 'descriptor', 
+                    'type' => $oAlert->sUnit,
+                    'action' => $aHandlers[BX_BASE_MOD_NTFS_HANDLER_TYPE_INSERT]['alert_action'], 
+                    'object_id' => $oAlert->iObject
+            	));
+                if(empty($aEvent) || !is_array($aEvent))
+                    break;
+
+            	$this->_oModule->deleteEvent($aEvent);
+
+                $this->_oModule->_oDb->deleteCache(array('event_id' => $aEvent[$CNF['FIELD_ID']]));
+                break;
+        }
+    }
+
+    protected function _processSystemClearCache($oAlert)
+    {
+        if($oAlert->aExtras['type'] != 'custom')
+            return;
+
+        //--- Clear item cache.
+        $this->_oModule->getCacheItemObject()->removeAllByPrefix($this->_oModule->_oConfig->getPrefix('cache_item'));
+
+        //--- Clear feed cache.
+        $this->_oModule->_oDb->clearCache();
+                
+    }
+
+    protected function _processBxTimelineVideosMp4Transcoded($oAlert)
+    {
+        $this->_onVideoTranscoded($oAlert->iObject, $oAlert->aExtras['ret']);
+    }
+
+    protected function _onVideoTranscoded($iMediaId, $bResult, $aParams = array())
+    {
+        $CNF = &$this->_oModule->_oConfig->CNF;
+
+        if(!isset($CNF['FIELD_STATUS']))
+            return;
+
+        $aMedia = $this->_oModule->_oDb->getMediaById(BX_TIMELINE_MEDIA_VIDEO, $iMediaId);
+        if(empty($aMedia) || !is_array($aMedia))
+            return;
+
+        $iContentId = (int)$aMedia['event_id'];
+        $aContentInfo = $this->_oModule->_oDb->getContentInfoById($iContentId);
+        if(empty($aContentInfo) || !is_array($aContentInfo))
+            return;
+
+        if(!isset($aContentInfo[$CNF['FIELD_STATUS']]) || $aContentInfo[$CNF['FIELD_STATUS']] != 'awaiting')
+            return;
+
+        if(!$bResult) {
+            if((int)$this->_oModule->_oDb->updateEntriesBy(array($CNF['FIELD_STATUS'] => 'failed'), array($CNF['FIELD_ID'] => $iContentId)) > 0)
+                $this->_oModule->onFailed($iContentId);
+
+            return;
+        }
+
+        $iNow = time();
+        if(isset($CNF['FIELD_PUBLISHED']) && isset($aContentInfo[$CNF['FIELD_PUBLISHED']]) && $aContentInfo[$CNF['FIELD_PUBLISHED']] > $iNow)
+            return;
+
+        $oTranscoder = BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4']);
+        $aMediasToCheck = $this->_oModule->_oDb->getMedia(BX_TIMELINE_MEDIA_VIDEO, $iContentId);
+        foreach($aMediasToCheck as $iMediaToCheck)
+            if(!$oTranscoder->isFileReady($iMediaToCheck))
+                return;
+
+        if((int)$this->_oModule->_oDb->updateEntriesBy(array($CNF['FIELD_STATUS'] => 'active'), array($CNF['FIELD_ID'] => $iContentId)) > 0)
+            $this->_oModule->onPublished($iContentId);
+    }
+}
+
+/** @} */

+ 77 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineSearchResult.php

@@ -0,0 +1,77 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineSearchResult extends BxBaseModNotificationsSearchResult
+{
+    function __construct($sMode = '', $aParams = array())
+    {
+        parent::__construct($sMode, $aParams);
+
+        $this->aCurrent = array(
+            'name' => 'bx_timeline',
+            'module_name' => 'bx_timeline',
+            'object_metatags' => 'bx_timeline',
+            'title' => _t('_bx_timeline_page_title_browse'),
+            'table' => 'bx_timeline_events',
+            'ownFields' => array('id', 'owner_id', 'type', 'action', 'object_id', 'object_privacy_view', 'content', 'title', 'description', 'views', 'rate', 'votes', 'rrate', 'rvotes', 'score', 'sc_up', 'sc_down', 'comments', 'reports', 'reposts', 'date', 'status', 'pinned', 'sticked', 'promoted'),
+            'searchFields' => array('title'),
+            'restriction' => array(
+                'internal' => array('value' => 'timeline_common_post', 'field' => 'type', 'operator' => '='),
+                'status' => array('value' => BX_TIMELINE_STATUS_ACTIVE, 'field' => 'status', 'operator' => '='),
+                'active' => array('value' => '1', 'field' => 'active', 'operator' => '='),
+            ),
+            'paginate' => array('perPage' => getParam('bx_timeline_events_per_page'), 'start' => 0),
+            'sorting' => 'last',
+            'ident' => 'id',
+        );
+
+        $this->sFilterName = 'bx_timeline_filter';
+        $this->oModule = $this->getMain();
+
+        switch ($sMode) {
+
+            case '': // search results
+                $this->sBrowseUrl = BX_DOL_SEARCH_KEYWORD_PAGE;
+                $this->aCurrent['title'] = _t('_bx_timeline');
+                unset($this->aCurrent['paginate']['perPage'], $this->aCurrent['rss']);
+                break;
+
+            default:
+                $sMode = '';
+                $this->isError = true;
+
+        }
+
+        $this->setProcessPrivateContent(false);
+    }
+
+    function displayResultBlock ()
+    {
+        $sResult = parent::displayResultBlock();
+        if(empty($sResult))
+            return $sResult;
+
+        return $this->oModule->_oTemplate->getSearchBlock($sResult);
+    }
+
+    function getAlterOrder()
+    {
+        $aSql = array();
+        switch ($this->aCurrent['sorting']) {
+            case 'last':
+                $aSql['order'] = ' ORDER BY `bx_timeline_events`.`date` DESC';
+                break;
+        }
+        return $aSql;
+    }
+}
+
+/** @} */

+ 2282 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineTemplate.php

@@ -0,0 +1,2282 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineTemplate extends BxBaseModNotificationsTemplate
+{
+    protected static $_aMemoryCacheItems;
+
+    protected static $_sTmplContentItemItem;
+    protected static $_sTmplContentItemOutline;
+    protected static $_sTmplContentItemTimeline;
+    protected static $_sTmplContentItemSearch;
+    protected static $_sTmplContentTypePost;
+    protected static $_sTmplContentTypeRepost;
+
+    protected $_bShowTimelineDividers;
+
+    function __construct(&$oConfig, &$oDb)
+    {
+        parent::__construct($oConfig, $oDb);
+
+        $this->_bShowTimelineDividers = false;
+    }
+
+    public function init()
+    {
+        parent::init();
+
+        self::$_aMemoryCacheItems = array();
+    }
+
+    public function getCss($bDynamic = false)
+    {
+        $mixedResult = parent::getCss($bDynamic);
+        $mixedResult .= $this->addCss(array(
+            BX_DIRECTORY_PATH_PLUGINS_PUBLIC . 'flickity/|flickity.css',
+            BX_DIRECTORY_PATH_PLUGINS_PUBLIC . 'emoji/css/|emoji.css',
+            'jquery-ui/jquery-ui.css',
+            'cmts.css',
+            'post.css',
+            'repost.css',
+        ), $bDynamic);
+
+        if($bDynamic)
+            return $mixedResult; 
+    }
+
+    public function getJs($bDynamic = false)
+    {
+        $mixedResult = parent::getJs($bDynamic);
+        $mixedResult .= $this->addJs(array(
+            'jquery-ui/jquery-ui.custom.min.js',
+            'jquery.form.min.js',
+            'jquery.ba-resize.min.js',
+            'autosize.min.js',
+            'masonry.pkgd.min.js',
+            'flickity/flickity.pkgd.min.js',
+            'embedly-player.min.js',
+            'BxDolCmts.js',            
+            'post.js',
+            'repost.js',
+        ), $bDynamic);
+
+        if($bDynamic)
+            return $mixedResult; 
+    }
+
+    public function getJsCodePost($iOwnerId, $aParams = array())
+    {
+        return $this->getJsCode('post', array(
+            'sVideosAutoplay' => $this->_oConfig->getVideosAutoplay(),
+            'oRequestParams' => array_merge(array(
+                'type' => isset($aParams['type']) ? $aParams['type'] : BX_TIMELINE_TYPE_DEFAULT, 
+                'owner_id' => $iOwnerId
+            ), $aParams)
+        ));
+    }
+
+    public function getPostBlock($iOwnerId, $aParams = array())
+    {
+        $aForm = $this->getModule()->getFormPost($aParams);
+
+        return $this->parseHtmlByName('block_post.html', array (
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'js_object' => $this->_oConfig->getJsObject('post'),
+            'js_content' => $this->getJsCodePost($iOwnerId, $aParams),
+            'form' => $aForm['form']
+        ));
+    }
+
+    public function getViewBlock($aParams)
+    {
+        $oModule = $this->getModule();
+
+        //--- Add live update
+        $oModule->actionResumeLiveUpdate($aParams['type'], $aParams['owner_id']);
+
+        $sMethod = !empty($aParams['get_live_updates']) ? $aParams['get_live_updates'] : 'get_live_update';
+        $sServiceCall = BxDolService::getSerializedService($this->_oConfig->getName(), $sMethod, array($aParams, $oModule->getUserId(), '{count}', '{init}'));
+        $sLiveUpdatesCode = BxDolLiveUpdates::getInstance()->add($this->_oConfig->getLiveUpdateKey($aParams), 1, $sServiceCall);
+        //--- Add live update
+
+        list($sContent, $sLoadMore, $sBack, $sEmpty) = $this->getPosts($aParams);
+
+        $sJsObject = $this->_oConfig->getJsObjectView($aParams);
+        return $sLiveUpdatesCode . $this->parseHtmlByName('block_view.html', array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'html_id' => $this->_oConfig->getHtmlIdView('main', $aParams),
+            'view' => $aParams['view'],
+            'back' => $sBack,
+            'empty' => $sEmpty, 
+            'content' => $sContent,
+            'load_more' =>  $sLoadMore,
+            'show_more' => $this->_getShowMore($aParams),
+            'view_image_popup' => $this->_getImagePopup($aParams),
+            'js_content' => $this->getJsCode('view', array(
+                'sObjName' => $sJsObject,
+                'sVideosAutoplay' => $this->_oConfig->getVideosAutoplay(),
+            	'oRequestParams' => $aParams
+            ), array(
+                'wrap' => true,
+                'mask_markers' => array('object' => $sJsObject)
+            )) . $this->getJsCode('repost')
+        ));
+    }
+
+    public function getSearchBlock($sContent)
+    {
+        $oModule = $this->getModule();
+        $aParams = $oModule->getParams(BX_TIMELINE_VIEW_SEARCH);
+
+        return $this->parseHtmlByName('block_search.html', array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'html_id' => $this->_oConfig->getHtmlIdView('main', $aParams),
+            'view' => $aParams['view'],
+            'content' => $sContent,
+            'view_image_popup' => $this->_getImagePopup($aParams),
+            'js_content' => $this->getJsCode('view', array(
+            	'oRequestParams' => $aParams
+            ))
+        ));
+    }
+
+    public function getItemBlock($iId, $aBrowseParams = array())
+    {
+        $CNF = $this->_oConfig->CNF;
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent))
+            return array('content' => MsgBox(_t('_Empty')), 'designbox_id' => 13);
+
+        $iProfile = (int)$aEvent[$CNF['FIELD_OWNER_ID']];
+        if(!empty($iProfile)) {
+            $oProfile = BxDolProfile::getInstance($iProfile);
+            if(!$oProfile)
+                return array('content' => MsgBox(_t('_Empty')), 'designbox_id' => 13);
+
+            $mixedResult = $oProfile->checkAllowedProfileView();
+            if($mixedResult !== CHECK_ACTION_RESULT_ALLOWED)
+                return array('content' => MsgBox($mixedResult), 'designbox_id' => 13);
+        }
+
+        $sContent = $this->getPost($aEvent, $aBrowseParams);
+
+        $sKey = 'allowed_view';
+        if(isset($aEvent[$sKey]) && $aEvent[$sKey] !== CHECK_ACTION_RESULT_ALLOWED) 
+            return array('content' => MsgBox($aEvent[$sKey]), 'designbox_id' => 13);
+
+        $oModule = $this->getModule();
+        if($oModule->isAllowedView($aEvent) !== true)
+            return array('content' => MsgBox(_t('_Access denied')), 'designbox_id' => 13);
+
+        if(!$this->_oConfig->isSystem($aEvent['type'], $aEvent['action'])) {
+            $mixedViews = $oModule->getViewsData($aEvent['views']);
+            if($mixedViews !== false) {
+                list($sSystem, $iObjectId) = $mixedViews;
+                $oModule->getViewObject($sSystem, $iObjectId)->doView();
+            }
+        }
+
+        list($sAuthorName) = $oModule->getUserInfo($aEvent['object_owner_id']);
+
+        $oTemplate = BxDolTemplate::getInstance();
+        $oTemplate->setPageHeader(strip_tags($sAuthorName . ' ' . _t($aEvent['sample_action'], _t($aEvent['sample']))));
+        $oTemplate->setPageDescription(strip_tags($aEvent['title']));
+
+        $oMetatags = BxDolMetatags::getObjectInstance($this->_oConfig->getObject('metatags'));
+        if($oMetatags)
+            $oMetatags->addPageMetaInfo($aEvent[$CNF['FIELD_ID']]);
+
+        $sReferrer = '';
+        if(isset($_SERVER['HTTP_REFERER']) && mb_stripos($_SERVER['HTTP_REFERER'], BX_DOL_URL_ROOT) === 0)
+            $sReferrer = $_SERVER['HTTP_REFERER'];
+        else 
+            $sReferrer = BX_DOL_URL_ROOT . BxDolPermalinks::getInstance()->permalink($this->_oConfig->CNF['URL_HOME']);
+
+        $sJsObject = $this->_oConfig->getJsObjectView($aBrowseParams);
+        return array('content' => $this->parseHtmlByName('block_item.html', array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'html_id' => $this->_oConfig->getHtmlIdView('main', $aBrowseParams),
+            'content' => $sContent,
+            'show_more' => $this->_getShowMore($aBrowseParams),
+            'view_image_popup' => $this->_getImagePopup($aBrowseParams),
+            'js_content' => $this->getJsCode('view', array(
+                'sObjName' => $sJsObject,
+                'sVideosAutoplay' => $this->_oConfig->getVideosAutoplay(),
+                'sReferrer' => $sReferrer,
+                'oRequestParams' => $aBrowseParams
+            ), array(
+                'wrap' => true,
+                'mask_markers' => array('object' => $sJsObject)
+            )) . $this->getJsCode('repost')
+        )));
+    }
+
+    /**
+     * Get event's content.
+     * @param integer $iId - event ID.
+     * @param string $sMode - 'photo' is only one mode which is available for now.
+     */
+    public function getItemBlockContent($iId, $sMode) {
+        $CNF = $this->_oConfig->CNF;
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent))
+            return '';
+
+        $aTmplVars = array(
+        	'style_prefix' => $sStylePrefix,
+            'bx_if:show_image' => array(
+                'condition' => false,
+                'content' => array()
+            )
+        );
+
+        switch($sMode) {
+            case 'photo':
+                $aTmplVars['bx_if:show_image']['condition'] = true;
+                $aTmplVars['bx_if:show_image']['content'] = array(
+                    'style_prefix' => $sStylePrefix,
+                    'src' => base64_decode(bx_process_input(bx_get('src'))),
+                );
+                break;
+        }
+
+        return $this->parseHtmlByName('block_item_content.html', $aTmplVars);
+    }
+
+    public function getItemBlockInfo($iId) {
+        $CNF = $this->_oConfig->CNF;
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent))
+            return '';
+
+        $aResult = $this->getDataCached($aEvent);
+        if($aResult === false)
+            return '';
+
+        list($sAuthorName, $sAuthorUrl, $sAuthorIcon, $sAuthorUnit) = $this->getModule()->getUserInfo($aResult['object_owner_id']);
+
+        return $this->parseHtmlByName('block_item_info.html', array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'author' => $sAuthorUnit
+        ));
+    }
+
+    public function getItemBlockComments($iId) {
+        $CNF = &$this->_oConfig->CNF;
+
+        $aEvent = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $iId));
+        if(empty($aEvent))
+            return '';
+
+        $aResult = $this->getDataCached($aEvent);
+        if($aResult === false)
+            return '';
+            
+        return $this->_getComments($aResult['comments']);
+    }
+
+    public function getUnit(&$aEvent, $aBrowseParams = array())
+    {
+        $oModule = $this->getModule();
+
+        if(empty($aBrowseParams) || !is_array($aBrowseParams))
+            $aBrowseParams = $oModule->getParams(BX_TIMELINE_VIEW_SEARCH);
+
+        return $this->getPost($aEvent, $aBrowseParams);
+    }
+
+    public function getPost(&$aEvent, $aBrowseParams = array())
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $iEventId = (int)$aEvent[$CNF['FIELD_ID']];
+        if(array_key_exists($iEventId, self::$_aMemoryCacheItems))
+            return self::$_aMemoryCacheItems[$iEventId];
+
+        /**
+         * Add all items in memory cache even if they are empty.
+         */
+        self::$_aMemoryCacheItems[$iEventId] = '';
+
+        $oPrivacy = BxDolPrivacy::getObjectInstance($this->_oConfig->getObject('privacy_view'));
+        if($oPrivacy) {
+            $oPrivacy->setTableFieldAuthor($this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? 'owner_id' : 'object_id');
+            if(!$oPrivacy->check($iEventId)) {
+                if($this->_oConfig->isCacheList())
+                    $this->_oDb->deleteCache(array(
+                        'type' => $aBrowseParams['type'], 
+                        'profile_id' => bx_get_logged_profile_id(),
+                        'event_id' => $iEventId
+                    ));
+
+                return '';
+            }
+        }
+
+        $aResult = $this->getDataCached($aEvent, $aBrowseParams);
+        if($aResult === false)
+            return '';
+
+        /**
+         * If 'updated' Owner ID was returned with data from integrated module,
+         * then save it's original value in 'owner_id_orig' for future usage and 
+         * rewrite with received value.
+         */
+        if(isset($aResult['owner_id'])) {
+            $aEvent['owner_id_orig'] = $aEvent['owner_id'];
+            $aEvent['owner_id'] = $aResult['owner_id'];
+        }
+        $aEvent['object_owner_id'] = $aResult['object_owner_id'];
+        $aEvent['icon'] = !empty($aResult['icon']) ? $aResult['icon'] : '';
+        $aEvent['sample'] = !empty($aResult['sample']) ? $aResult['sample'] : '_bx_timeline_txt_sample';
+        $aEvent['sample_action'] = !empty($aResult['sample_action']) ? $aResult['sample_action'] : '_bx_timeline_txt_added_sample';
+        $aEvent['content'] = $aResult['content'];
+        $aEvent['allowed_view'] = isset($aResult['allowed_view']) ? $aResult['allowed_view'] : CHECK_ACTION_RESULT_ALLOWED;
+        $aEvent['views'] = $aResult['views'];
+        $aEvent['votes'] = $aResult['votes'];
+        $aEvent['reactions'] = $aResult['reactions'];
+        $aEvent['scores'] = $aResult['scores'];
+        $aEvent['reports'] = $aResult['reports'];
+        $aEvent['comments'] = $aResult['comments'];
+
+        $sKey = 'allowed_view';
+        if(isset($aEvent[$sKey]) && $aEvent[$sKey] !== CHECK_ACTION_RESULT_ALLOWED) 
+            return '';
+
+        if($this->_oConfig->isCacheList())
+            $this->_cacheEvent(bx_get_logged_profile_id(), $aEvent, $aBrowseParams);
+
+        $sType = !empty($aResult['content_type']) ? $aResult['content_type'] : BX_TIMELINE_PARSE_TYPE_DEFAULT;
+        self::$_aMemoryCacheItems[$iEventId] = $this->_getPost($sType, $aEvent, $aBrowseParams);
+
+        return self::$_aMemoryCacheItems[$iEventId];
+    }
+
+    public function getPosts($aParams)
+    {
+        $bViewTimeline = $aParams['view'] == BX_TIMELINE_VIEW_TIMELINE;
+
+        $iStart = $aParams['start'];
+        $iPerPage = $aParams['per_page'];
+
+        $aParamsDb = $aParams;
+
+        //--- Before: Check for Previous
+        $iDays = -1;
+        $bPrevious = false;
+        if($iStart - 1 >= 0) {
+            $aParamsDb['start'] -= 1;
+            $aParamsDb['per_page'] += 1;
+            $bPrevious = true;
+        }
+
+        //--- Before: Check for Next
+        $aParamsDb['per_page'] += 1;
+
+        $aEvents = $this->_getPosts($aParamsDb);
+
+        //--- After: Check for Previous
+        if($bPrevious) {
+            $aEvent = array_shift($aEvents);
+            $iDays = (int)$aEvent['days'];
+        }
+
+        //--- After: Check for Next
+        $bNext = false;
+        if(count($aEvents) > $iPerPage) {
+            $aEvent = array_pop($aEvents);
+            $bNext = true;
+        }
+
+        $sContent = '';
+        $sContent .= $this->getSizer($aParams);
+
+        $iEvents = count($aEvents);
+        if($bViewTimeline && $iEvents <= 0)
+        	$sContent .= $this->getDividerToday();
+
+        //--- Check for Visual Grouping
+        $aGroups = array();
+        foreach($aEvents as $iIndex => $aEvent) {
+            $aContent = unserialize($aEvent['content']);
+            if(!isset($aContent['timeline_group']))
+                continue;
+
+            $aGroup = $aContent['timeline_group'];
+            $sGroup = $aGroup['by'];
+            if(!isset($aGroups[$sGroup]))
+               $aGroups[$sGroup] = array('field' => $aGroup['field'], 'indexes' => array(), 'processed' => false);
+
+            $aGroups[$sGroup]['indexes'][] = $iIndex;
+        }
+
+        //--- Perform Visual Grouping
+        foreach($aGroups as $sGroup => $aGroup) {
+            if(empty($aGroup['field']) || empty($aGroup['indexes']))
+                continue;
+
+            switch($aGroup['field']) {
+                case 'owner_id':
+                    $aOwnerIds = array();
+                    foreach($aGroup['indexes'] as $iIndex)
+                        $aOwnerIds[] = $aEvents[$iIndex]['owner_id'];
+
+                    $iGroupIndex = (int)array_shift($aGroup['indexes']);
+                    if(is_null($iGroupIndex))
+                        break;
+
+                    foreach($aGroup['indexes'] as $iIndex)
+                        unset($aEvents[$iIndex]);
+
+                    $aEvents[$iGroupIndex]['owner_id'] = $aOwnerIds;
+                    break;
+            }
+        }
+
+        $bFirst = true;
+        $sEvents = '';
+        foreach($aEvents as $aEvent) {
+            $iEvent = (int)$aEvent['id'];
+
+            $sEvent = $this->getPost($aEvent, $aParams);
+            if(empty($sEvent))
+                continue;
+
+            if($bViewTimeline && $bFirst) {
+                $sEvents .= $this->getDividerToday($aEvent);
+                $bFirst = false;
+            }
+
+            $sEvents .= $bViewTimeline ? $this->getDivider($iDays, $aEvent) : '';
+            $sEvents .= $sEvent;
+        }
+        $sContent .= $sEvents;
+
+        $bEvents = !empty($sEvents);
+
+        $sBack = $this->getBack($aParams);
+        $sLoadMore = $this->getLoadMore($aParams, $bNext, $iEvents > 0 && $bEvents);
+        $sEmpty = $this->getEmpty($iEvents <= 0 || !$bEvents);
+        return array($sContent, $sLoadMore, $sBack, $sEmpty);
+    }
+
+    public function getEmpty($bVisible)
+    {
+        return $this->parseHtmlByName('empty.html', array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'visible' => $bVisible ? 'block' : 'none',
+            'content' => MsgBox(_t('_bx_timeline_txt_msg_no_results'))
+        ));
+    }
+
+    public function getDivider(&$iDays, &$aEvent)
+    {
+        if(!$this->_bShowTimelineDividers || $iDays == $aEvent['days'])
+            return '';
+
+        $iDays = $aEvent['days'];
+        $iDaysAgo = (int)$aEvent['ago_days'];
+        if($aEvent['today'] == $aEvent['days'] || (($aEvent['today'] - $aEvent['days']) == 1 && $iDaysAgo == 0))
+            return '';
+
+        return $this->parseHtmlByName('divider.html', array(
+        	'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'type' => 'common',
+            'bx_if:show_hidden' => array(
+                'condition' => false,
+                'content' => array()
+            ),
+            'content' => bx_time_js($aEvent['date'])
+        ));
+    }
+
+    public function getDividerToday($aEvent = array())
+    {
+        if(!$this->_bShowTimelineDividers)
+            return '';
+
+    	$bToday = !empty($aEvent) && ($aEvent['today'] == $aEvent['days'] || (($aEvent['today'] - $aEvent['days']) == 1 && (int)$aEvent['ago_days'] == 0));
+
+        return $this->parseHtmlByName('divider.html', array(
+        	'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'type' => 'today',
+        	'bx_if:show_hidden' => array(
+                'condition' => !$bToday,
+                'content' => array()
+            ),
+            'content' => _t('_bx_timeline_txt_today')
+        ));
+    }
+
+    public function getSizer($aParams)
+    {
+        if($aParams['view'] != BX_TIMELINE_VIEW_OUTLINE)
+            return '';
+
+        return $this->parseHtmlByName('sizer_' . $aParams['view'] . '.html', array(
+        	'style_prefix' => $this->_oConfig->getPrefix('style')
+        ));
+    }
+
+    public function getBack($aParams)
+    {
+        $iYearSel = (int)$aParams['timeline'];
+        if($iYearSel == 0)
+            return '';
+
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObjectView($aParams);
+
+        $iYearNow = date('Y', time());
+        return $this->parseHtmlByName('back.html', array(
+        	'style_prefix' => $sStylePrefix,
+            'content' => $this->parseLink('javascript:void(0)', _t('_bx_timeline_txt_jump_to_recent'), array(
+                'title' => _t('_bx_timeline_txt_jump_to_n_year', $iYearNow),
+        		'onclick' => 'javascript:' . $sJsObject . '.changeTimeline(this, 0)'
+            ))
+        ));
+    }
+
+    public function getLoadMore($aParams, $bEnabled, $bVisible = true)
+    {
+        $iStart = $aParams['start'];
+        $iPerPage = $aParams['per_page'];
+        $iYearSel = (int)$aParams['timeline'];
+        $iYearMin = $this->_oDb->getMaxDuration($aParams);
+
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObjectView($aParams);
+
+        $sYears = '';
+        if(!empty($iYearMin)) {
+            $iYearMax = date('Y', time()) - 1;
+            for($i = $iYearMax; $i >= $iYearMin; $i--)
+                $sYears .= ($i != $iYearSel ? $this->parseLink('javascript:void(0)', $i, array(
+                    'title' => _t('_bx_timeline_txt_jump_to_n_year', $i),
+                    'onclick' => 'javascript:' . $sJsObject . '.changeTimeline(this, ' . $i . ')'
+                )) : $i) . ', ';
+
+            $sYears = substr($sYears, 0, -2);
+        }
+
+        $aTmplVars = array(
+            'style_prefix' => $sStylePrefix,
+            'visible' => ($aParams['view'] == BX_TIMELINE_VIEW_TIMELINE && $bVisible) || ($aParams['view'] == BX_TIMELINE_VIEW_OUTLINE && $bEnabled && $bVisible) ? 'block' : 'none',
+            'bx_if:is_disabled' => array(
+                'condition' => !$bEnabled,
+                'content' => array()
+            ),
+            'bx_if:show_on_click' => array(
+                'condition' => $bEnabled,
+                'content' => array(
+                    'on_click' => 'javascript:' . $sJsObject . '.changePage(this, ' . ($iStart + $iPerPage) . ', ' . $iPerPage . ')'
+                )
+            ),
+            'bx_if:show_jump_to' => array(
+                'condition' => !empty($sYears),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'years' => $sYears
+                )
+            )
+        );
+        return $this->parseHtmlByName('load_more.html', $aTmplVars);
+    }
+
+    public function getComments($sSystem, $iId, $aBrowseParams = array())
+    {
+        $oModule = $this->getModule();
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $oCmts = $oModule->getCmtsObject($sSystem, $iId);
+        if($oCmts === false)
+            return '';
+
+        $aCmtsBp = array();
+        if(!empty($aBrowseParams['cmts_preload_number']))
+            $aCmtsBp['per_view'] = $aBrowseParams['cmts_preload_number'];
+
+        $aCmtsDp = array(
+            'in_designbox' => false, 
+            'dynamic_mode' => isset($aBrowseParams['dynamic_mode']) && $aBrowseParams['dynamic_mode'] === true
+        );
+        if(!empty($aBrowseParams['cmts_min_post_form']))
+            $aCmtsDp['min_post_form'] = $aBrowseParams['cmts_min_post_form'];
+
+        $aComments = $oCmts->getCommentsBlock($aCmtsBp, $aCmtsDp);
+        return $this->parseHtmlByName('comments.html', array(
+            'style_prefix' => $sStylePrefix,
+            'id' => $iId,
+            'content' => $aComments['content']
+        ));
+    }
+
+    public function getRepostElement($iOwnerId, $sType, $sAction, $iObjectId, $aParams = array())
+    {
+        $aReposted = $this->_oDb->getReposted($sType, $sAction, $iObjectId);
+        if(empty($aReposted) || !is_array($aReposted))
+            return '';
+
+		$oModule = $this->getModule();
+		$bDisabled = $oModule->isAllowedRepost($aReposted) !== true || $this->_oDb->isReposted($aReposted['id'], $iOwnerId, $oModule->getUserId());
+		if($bDisabled && (int)$aReposted['reposts'] == 0)
+            return '';
+
+		$sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sStylePrefixRepost = $sStylePrefix . '-repost-';
+
+        $bDynamicMode = isset($aParams['dynamic_mode']) && $aParams['dynamic_mode'] === true;
+
+        $bShowDoRepostAsButtonSmall = isset($aParams['show_do_repost_as_button_small']) && $aParams['show_do_repost_as_button_small'] == true;
+        $bShowDoRepostAsButton = !$bShowDoRepostAsButtonSmall && isset($aParams['show_do_repost_as_button']) && $aParams['show_do_repost_as_button'] == true;
+
+        $bShowDoRepostImage = isset($aParams['show_do_repost_image']) && $aParams['show_do_repost_image'] == true && !empty($aParams['image_do_repost']);
+        $bShowDoRepostIcon = isset($aParams['show_do_repost_icon']) && $aParams['show_do_repost_icon'] == true && !empty($aParams['icon_do_repost']);
+        $bShowDoRepostText = isset($aParams['show_do_repost_text']) && $aParams['show_do_repost_text'] == true && !empty($aParams['text_do_repost']);
+        $bShowCounter = isset($aParams['show_counter']) && $aParams['show_counter'] === true;
+
+        //--- Do repost link ---//
+		$sClass = $sStylePrefixRepost . 'do-repost';
+		if($bShowDoRepostAsButton)
+			$sClass .= ' bx-btn';
+		else if($bShowDoRepostAsButtonSmall)
+			$sClass .= ' bx-btn bx-btn-small';
+
+                $sOnClick = '';
+                if(!$bDisabled) {
+                    $sCommonPrefix = $this->_oConfig->getPrefix('common_post');
+                    if(str_replace($sCommonPrefix, '', $sType) == BX_TIMELINE_PARSE_TYPE_REPOST) {
+                        $aRepostedData = unserialize($aReposted['content']);
+
+                        $sOnClick = $this->_getRepostJsClick($iOwnerId, $aRepostedData['type'], $aRepostedData['action'], $aRepostedData['object_id']);
+                    }
+                    else
+                        $sOnClick = $this->_getRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId);
+                }
+                else
+                    $sClass .= $bShowDoRepostAsButton || $bShowDoRepostAsButtonSmall ? ' bx-btn-disabled' : ' ' . $sStylePrefixRepost . 'disabled';
+
+		$aOnClickAttrs = array(
+			'title' => _t('_bx_timeline_txt_do_repost')
+		);
+		if(!empty($sClass))
+			$aOnClickAttrs['class'] = $sClass;
+		if(!empty($sOnClick))
+			$aOnClickAttrs['onclick'] = $sOnClick;
+
+		//--- Do repost label ---//
+		$sMethodDoRepostLabel = ''; 
+		$sTemplateDoRepostLabel = '';
+		if(!empty($aParams['template_do_repost_label'])) {
+			$sMethodDoRepostLabel = 'parseHtmlByContent';
+			$sTemplateDoRepostLabel = $aParams['template_do_repost_label'];
+		}
+		else {
+			$sMethodDoRepostLabel = 'parseHtmlByName';
+			$sTemplateDoRepostLabel = $aParams['template_do_repost_label_name'];
+		}
+
+		$sDoRepost = $this->$sMethodDoRepostLabel($sTemplateDoRepostLabel, array(
+        	'bx_if:show_image' => array(
+        		'condition' => $bShowDoRepostImage,
+        		'content' => array(
+        			'src' => $this->getIconUrl($aParams['image_do_repost'])
+        		)
+        	),
+        	'bx_if:show_icon' => array(
+        		'condition' => $bShowDoRepostIcon,
+        		'content' => array(
+        			'name' => $aParams['icon_do_repost']
+        		)
+        	),
+        	'bx_if:show_text' => array(
+        		'condition' => $bShowDoRepostText,
+        		'content' => array(
+        			'text' => _t($aParams['text_do_repost'])
+        		)
+        	)
+        ));
+
+        return $this->parseHtmlByName('repost_element_block.html', array(
+            'style_prefix' => $sStylePrefix,
+            'html_id' => $this->_oConfig->getHtmlIds('repost', 'main') . $aReposted['id'],
+            'class' => ($bShowDoRepostAsButton ? $sStylePrefixRepost . 'button' : '') . ($bShowDoRepostAsButtonSmall ? $sStylePrefixRepost . 'button-small' : ''),
+            'count' => $aReposted['reposts'],
+            'do_repost' => $this->parseLink('javascript:void(0)', $sDoRepost, $aOnClickAttrs),
+            'bx_if:show_counter' => array(
+                'condition' => $bShowCounter,
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+        			'bx_if:show_hidden' => array(
+        				'condition' => (int)$aReposted['reposts'] == 0,
+        				'content' => array()
+        			),
+                    'counter' => $this->getRepostCounter($aReposted, $aParams)
+                )
+            ),
+            'script' => $this->getRepostJsScript($bDynamicMode)
+        ));
+    }
+
+    public function getRepostCounter($aEvent, $aParams = array())
+    {
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObject('repost');
+
+        $bShowDoRepostAsButtonSmall = isset($aParams['show_do_repost_as_button_small']) && $aParams['show_do_repost_as_button_small'] == true;
+        $bShowDoRepostAsButton = !$bShowDoRepostAsButtonSmall && isset($aParams['show_do_repost_as_button']) && $aParams['show_do_repost_as_button'] == true;
+
+        $sClass = $sStylePrefix . '-repost-counter';
+        if($bShowDoRepostAsButtonSmall)
+            $sClass .= ' bx-btn-small-height';
+        if($bShowDoRepostAsButton)
+            $sClass .= ' bx-btn-height';
+
+        return $this->parseLink('javascript:void(0)', !empty($aEvent['reposts']) && (int)$aEvent['reposts'] > 0 ? $this->getRepostCounterLabel($aEvent['reposts']) : '', array(
+            'id' => $this->_oConfig->getHtmlIds('repost', 'counter') . $aEvent['id'],
+            'class' => $sClass,
+            'title' => _t('_bx_timeline_txt_reposted_by'),
+            'onclick' => 'javascript:' . $sJsObject . '.toggleByPopup(this, ' . $aEvent['id'] . ')'
+        ));
+    }
+
+    public function getRepostCounterLabel($iCount)
+    {
+        return $iCount;
+    }
+
+    public function getRepostedBy($iId)
+    {
+        $aTmplUsers = array();
+        $oModule = $this->getModule();
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $aUserIds = $this->_oDb->getRepostedBy($iId);
+        foreach($aUserIds as $iUserId) {
+            list($sUserName, $sUserUrl, $sUserIcon, $sUserUnit) = $oModule->getUserInfo($iUserId);
+            $aTmplUsers[] = array(
+                'style_prefix' => $sStylePrefix,
+                'user_unit' => $sUserUnit
+            );
+        }
+
+        if(empty($aTmplUsers))
+            $aTmplUsers = MsgBox(_t('_Empty'));
+
+        return $this->parseHtmlByName('repost_by_list.html', array(
+            'style_prefix' => $sStylePrefix,
+            'bx_repeat:list' => $aTmplUsers
+        ));
+    }
+
+    public function getRepostJsScript($bDynamicMode = false)
+    {
+        $sCode = $this->getJsCode('repost', array(), array('mask' => '{object} = new {class}({params});', 'wrap' => false));
+
+        if($bDynamicMode) {
+            $sJsObject = $this->_oConfig->getJsObject('repost');
+
+			$sCode = "var " . $sJsObject . " = null; 
+			$.getScript('" . bx_js_string($this->getJsUrl('main.js'), BX_ESCAPE_STR_APOS) . "', function(data, textStatus, jqxhr) {
+				$.getScript('" . bx_js_string($this->getJsUrl('repost.js'), BX_ESCAPE_STR_APOS) . "', function(data, textStatus, jqxhr) {
+    				bx_get_style('" . bx_js_string($this->getCssUrl('repost.css'), BX_ESCAPE_STR_APOS) . "');
+    				" . $sCode . "
+				});
+        	}); ";
+        }
+        else {
+        	$sCode = "var " . $sCode;
+
+        	$this->addCss(array('repost.css'));
+            $this->addJs(array('main.js', 'repost.js'));
+        }
+
+        return $this->_wrapInTagJsCode($sCode);
+    }
+
+    public function getRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId)
+    {
+        $aReposted = $this->_oDb->getReposted($sType, $sAction, $iObjectId);
+        if(empty($aReposted) || !is_array($aReposted))
+            return '';
+
+        $sResult = '';
+        $sCommonPrefix = $this->_oConfig->getPrefix('common_post');
+        if(str_replace($sCommonPrefix, '', $sType) == BX_TIMELINE_PARSE_TYPE_REPOST) {
+            $aRepostedData = unserialize($aReposted['content']);
+
+            $sResult = $this->_getRepostJsClick($iOwnerId, $aRepostedData['type'], $aRepostedData['action'], $aRepostedData['object_id']);
+        }
+        else
+            $sResult = $this->_getRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId);
+
+        return $sResult;
+    }
+
+    public function getAttachLinkForm()
+    {
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObject('post');
+
+        $aForm = $this->getModule()->getFormAttachLink();
+
+        return $this->parseHtmlByName('attach_link_form.html', array(
+            'style_prefix' => $sStylePrefix,
+            'js_object' => $sJsObject,
+            'form_id' => $aForm['form_id'],
+            'form' => $aForm['form'],
+        ));
+    }
+
+    public function getAttachLinkField($iUserId)
+    {
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $aLinks = $this->_oDb->getUnusedLinks($iUserId);
+
+        $sLinks = '';
+        foreach($aLinks as $aLink)
+            $sLinks .= $this->getAttachLinkItem($iUserId, $aLink);
+
+        return $this->parseHtmlByName('attach_link_form_field.html', array(
+            'html_id' => $this->_oConfig->getHtmlIds('post', 'attach_link_form_field'),
+            'style_prefix' => $sStylePrefix,
+            'links' => $sLinks
+        ));
+    }
+
+    public function getAttachLinkItem($iUserId, $mixedLink)
+    {
+        $aLink = is_array($mixedLink) ? $mixedLink : $this->_oDb->getUnusedLinks($iUserId, (int)$mixedLink);
+        if(empty($aLink) || !is_array($aLink))
+            return '';
+
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObject('post');
+        $sLinkIdPrefix = $this->_oConfig->getHtmlIds('post', 'attach_link_item');
+
+        $bTmplVarsEmbed = false;
+        $aTmplVarsEmbed = array();
+        $oEmbed = BxDolEmbed::getObjectInstance();
+        if($oEmbed) {
+            $bTmplVarsEmbed = true;
+            $aTmplVarsEmbed = array(
+                'style_prefix' => $sStylePrefix,
+                'embed' => $oEmbed->getLinkHTML($aLink['url'], $aLink['title'], 300),
+            );
+        }
+        else {
+            $aLinkAttrs = array(
+            	'title' => bx_html_attribute($aLink['title'])
+            );
+            if(!$this->_oConfig->isEqualUrls(BX_DOL_URL_ROOT, $aLink['url'])) {
+                $aLinkAttrs['target'] = '_blank';
+    
+                if($this->_oDb->getParam('sys_add_nofollow') == 'on')
+            	    $aLinkAttrs['rel'] = 'nofollow';
+            }
+
+            $sThumbnail = "";
+            if((int)$aLink['media_id'] != 0)
+                $sThumbnail = BxDolTranscoderImage::getObjectInstance($this->_oConfig->getObject('transcoder_photos_preview'))->getFileUrl($aLink['media_id']);
+
+            $aTmplVarsEmbed = array(
+                'style_prefix' => $sStylePrefix,
+            	'bx_if:show_thumbnail' => array(
+            		'condition' => !empty($sThumbnail),
+            		'content' => array(
+            			'style_prefix' => $sStylePrefix,
+            			'thumbnail' => $sThumbnail
+            		)
+            	),
+    			'url' => $aLink['url'],
+            	'link' => $this->parseLink($aLink['url'], $aLink['title'], $aLinkAttrs)
+            );
+        }
+
+        return $this->parseHtmlByName('attach_link_item.html', array(
+            'html_id' => $sLinkIdPrefix . $aLink['id'],
+            'style_prefix' => $sStylePrefix,
+            'js_object' => $sJsObject,
+            'id' => $aLink['id'],
+        	'bx_if:show_embed_outer' => array(
+        		'condition' => $bTmplVarsEmbed,
+        		'content' => $aTmplVarsEmbed
+        	),
+        	'bx_if:show_embed_inner' => array(
+        		'condition' => !$bTmplVarsEmbed,
+        		'content' => $aTmplVarsEmbed
+            ),
+        ));
+    }
+
+    public function getData(&$aEvent, $aBrowseParams = array())
+    {
+        $aResult = $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? $this->_getSystemData($aEvent, $aBrowseParams) : $this->_getCommonData($aEvent, $aBrowseParams);
+        if(empty($aResult) || empty($aResult['object_owner_id']) || empty($aResult['content']))
+            return false;
+
+        list($sUserName) = $this->getModule()->getUserInfo($aResult['object_owner_id']);
+
+        $sSample = !empty($aResult['sample']) ? $aResult['sample'] : '_bx_timeline_txt_sample';
+        if(empty($aEvent['title']) || empty($aEvent['description'])) {
+            $sTitle = !empty($aResult['title']) ? $this->_oConfig->getTitle($aResult['title']) : _t($sSample);
+
+            $sDescription = !empty($aResult['description']) ? $aResult['description'] : _t('_bx_timeline_txt_user_added_sample', $sUserName, _t($sSample));
+            if($sDescription == '' && !empty($aResult['content']['text']))
+                $sDescription = $aResult['content']['text'];
+
+            $this->_oDb->updateEvent(array(
+                'title' => bx_process_input(strip_tags($sTitle)),
+                'description' => bx_process_input(strip_tags($sDescription))
+            ), array('id' => $aEvent['id']));
+        }
+
+        return $aResult;
+    }
+
+    public function getDataCached($aEvent, $aBrowseParams = array())
+    {
+        if(!$this->_oConfig->isCacheItem()) 
+            return $this->getData($aEvent, $aBrowseParams);
+
+        /**
+         * For now parameters from $aBrowseParams array aren't used during data retrieving.
+         * If they will then the cache should be created depending on their values.
+         */
+        $sCacheKey = $this->_oConfig->getCacheItemKey($aEvent['id']);
+        $iCacheLifetime = $this->_oConfig->getCacheItemLifetime();
+
+        $oCache = $this->getModule()->getCacheItemObject();
+        $aCached = $oCache->getData($sCacheKey, $iCacheLifetime);
+        if(!empty($aCached)) 
+            return unserialize($aCached);
+
+        $aBrowseParams['dynamic_mode'] = true;
+        $aResult = $this->getData($aEvent, $aBrowseParams);
+        $oCache->setData($sCacheKey, serialize($aResult), $iCacheLifetime);           
+
+        return $aResult;
+    }
+
+    public function getVideo($aEvent, $aVideo)
+    {
+        $sVideoId = $this->_oConfig->getHtmlIds('view', 'video') . $aEvent['id'] . '-' . $aVideo['id'];
+        return $this->parseHtmlByName('video_player.html', array(
+            'player' => BxTemplFunctions::getInstance()->videoPlayer($aVideo['src_poster'], $aVideo['src_mp4'], $aVideo['src_mp4_hd'], array('id' => $sVideoId)),
+            'html_id' => $sVideoId
+        ));
+    }
+
+    /*
+     * Show only one Live Update notification for all new Events.
+     */
+    function getLiveUpdate($aBrowseParams, $iProfileId, $iCountOld = 0, $iCountNew = 0)
+    {
+        $oModule = $this->getModule();
+
+    	$iCount = (int)$iCountNew - (int)$iCountOld;
+    	if($iCount < 0)
+            return '';
+
+        $aParams = $oModule->getParamsExt($aBrowseParams);
+        $aParams['start'] = 0;
+        $aParams['per_page'] = 1;
+        $aParams['filter'] = BX_TIMELINE_FILTER_OTHER_VIEWER;
+        $aEvents = $this->_oDb->getEvents($aParams);
+        if(empty($aEvents) || !is_array($aEvents))
+            return '';
+
+        $aEvent = array_shift($aEvents);
+        if(empty($aEvent) || !is_array($aEvent))
+            return '';
+
+        $sJsObject = $this->_oConfig->getJsObjectView($aParams);
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        return $this->parseHtmlByName('live_update_button.html', array(
+            'style_prefix' => $sStylePrefix,
+            'html_id' => $this->_oConfig->getHtmlIds('view', 'live_update_popup') . $aBrowseParams['type'],
+            'onclick_show' => "javascript:" . $sJsObject . ".goToBtn(this, 'timeline-event-" . $aEvent['id'] . "', '" . $aEvent['id'] . "');",
+        ));
+    }
+
+    /*
+     * Show Live Update notification separately for each new Event. Popup Chain is used here.
+     * 
+     * Note. This way to display live update notifications isn't used for now. 
+     * See BxTimelineTemplate::getLiveUpdate method instead.
+     */
+    function getLiveUpdates($aBrowseParams, $iProfileId, $iCountOld = 0, $iCountNew = 0)
+    {
+        $bShowAll = true;
+        $bShowActions = false;
+        $oModule = $this->getModule();
+
+    	$iCount = (int)$iCountNew - (int)$iCountOld;
+    	if($iCount < 0)
+            return '';
+
+        $iCountMax = $this->_oConfig->getLiveUpdateLength();
+        if($iCount > $iCountMax)
+            $iCount = $iCountMax;
+
+        $aParams = $oModule->getParamsExt($aBrowseParams);
+        $aParams['start'] = 0;
+        $aParams['per_page'] = $iCount;
+        $aParams['filter'] = BX_TIMELINE_FILTER_OTHER_VIEWER;
+        $aEvents = $this->_oDb->getEvents($aParams);
+        if(empty($aEvents) || !is_array($aEvents))
+            return '';
+
+        $sJsObject = $this->_oConfig->getJsObjectView($aParams);
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $iUserId = $oModule->getUserId();
+        $bModerator = $oModule->isModerator();
+
+        $aEvents = array_reverse($aEvents);
+        $iEvents = count($aEvents);
+
+        $aTmplVarsItems = array();
+        foreach($aEvents as $iIndex => $aEvent) {
+            $aData = $this->getDataCached($aEvent);
+            if($aData === false)
+                continue;
+
+            $iEventId = $aEvent['id'];
+            $iEventAuthorId = $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? (int)$aEvent['owner_id'] : (int)$aEvent['object_id'];
+            if($iEventAuthorId < 0) {
+                if(abs($iEventAuthorId) == $iUserId)
+                    continue;
+                else if($bModerator)
+                    $iEventAuthorId *= -1;
+            }
+
+            $oAuthor = $oModule->getObjectUser($iEventAuthorId);
+            $sAuthorName = $oAuthor->getDisplayName();
+
+            $aTmplVarsItems[] = array(
+                'bx_if:show_as_hidden' => array(
+                    'condition' => !$bShowAll && $iIndex < ($iEvents - 1),
+                    'content' => array(),
+                ),
+                'item' => $this->parseHtmlByName('live_update_notification.html', array(
+                    'style_prefix' => $sStylePrefix,
+                    'onclick_show' => "javascript:" . $sJsObject . ".goTo(this, 'timeline-event-" . $iEventId . "', '" . $iEventId . "');",
+                    'author_link' => $oAuthor->getUrl(), 
+                    'author_title' => bx_html_attribute($sAuthorName),
+                    'author_name' => $sAuthorName,
+                    'author_unit' => $oAuthor->getUnit(0, array('template' => 'unit_wo_info_links')), 
+                    'text' => _t($aData['sample_action'], _t($aData['sample'])),
+                )),
+                'bx_if:show_previous' => array(
+                    'condition' => $bShowActions && $iIndex > 0,
+                    'content' => array(
+                        'onclick_previous' => $sJsObject . '.previousLiveUpdate(this)'
+                    )
+                ),
+                'bx_if:show_close' => array(
+                    'condition' => $bShowActions,
+                    'content' => array(
+                        'onclick_close' => $sJsObject . '.hideLiveUpdate(this)'
+                    )
+                )
+            );
+        }
+
+        return $this->parseHtmlByName('popup_chain.html', array(
+            'html_id' => $this->_oConfig->getHtmlIds('view', 'live_update_popup') . $aBrowseParams['type'],
+            'bx_repeat:items' => $aTmplVarsItems
+        ));
+    }
+
+    protected function _cacheEvent($iProfileId, &$aEvent, &$aParams)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $aParamsSet = array(
+            'type' => $aParams['type'],
+            'context_id' => $aEvent[$CNF['FIELD_OWNER_ID']], 
+            'profile_id' => $iProfileId, 
+            'event_id' => $aEvent[$CNF['FIELD_ID']], 
+            'date' => $aEvent[$CNF['FIELD_ADDED']]
+        );
+
+        switch ($aParams['type']) {
+            case BX_BASE_MOD_NTFS_TYPE_PUBLIC:
+                $aParamsSet['context_id'] = 0;
+                break;
+
+            case BX_TIMELINE_TYPE_OWNER_AND_CONNECTIONS:
+                $aParamsSet['context_id'] = $iProfileId;
+                break;
+        }
+
+        return $this->_oDb->insertCache($aParamsSet);
+    }
+
+    protected function _cacheEvents($aParams)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $iPerPage = (int)$aParams['per_page'];
+        $aParamsCopy = $aParams;
+
+        $aIds = array();
+        while(count($aIds) < $iPerPage) {
+            $aEvents = $this->_oDb->getEvents($aParamsCopy);
+            if(empty($aEvents))
+                break;
+
+            foreach($aEvents as $aEvent) {
+                if($this->getPost($aEvent, $aParamsCopy) == '')
+                    continue;
+
+                $aIds[] = $aEvent[$CNF['FIELD_ID']];
+                if(count($aIds) == $iPerPage)
+                    break 2;
+            }
+
+            $aParamsCopy['start'] += $iPerPage;
+        }
+
+        return $aIds;
+    }
+            
+    protected function _getCachedEvents($iProfileId, &$aParams)
+    {
+        return $this->_oDb->getCache(array(
+            'browse' => $aParams['browse'], 
+            'type' => $aParams['type'], 
+            'context_id' => $aParams['owner_id'], 
+            'profile_id' => $iProfileId, 
+            'start' => $aParams['start'], 
+            'per_page' => $aParams['per_page']
+        ));
+    }
+
+    protected function _getPosts($aParams)
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        if(!$this->_oConfig->isCacheList())
+            return $this->_oDb->getEvents($aParams);
+
+        $iPerPage = (int)$aParams['per_page'];
+        $iProfileId = (int)bx_get_logged_profile_id(); 
+
+        /*
+         * Get cached data and check it for relevance.
+         */
+        $aCache = $this->_getCachedEvents($iProfileId, $aParams);
+        if(is_array($aCache) && !empty($aCache)) {
+            if(($iCache = count($aCache)) != $iPerPage) {
+                $aRecachedIds = $this->_cacheEvents($aParams);
+                if(is_array($aRecachedIds) && count($aRecachedIds) > $iCache)
+                    $aCache = $this->_getCachedEvents($iProfileId, $aParams);
+            }
+
+            $bFound = false;
+            $bUpdated = false;
+
+            $aCachedItem = current($aCache);
+            $aCachedIds = array_keys($aCache);
+
+            $aParamsCopy = $aParams;
+            while(true) {
+                $aEvents = $this->_oDb->getEvents($aParamsCopy);
+                if(empty($aEvents))
+                    break;
+
+                foreach($aEvents as $aEvent) {
+                    if($aEvent[$CNF['FIELD_ID']] == $aCachedItem['event_id']) {
+                        $bFound = true;
+                        break 2;
+                    }
+
+                    if(!in_array($aEvent[$CNF['FIELD_ID']], $aCachedIds) && $this->getPost($aEvent, $aParamsCopy) == '')
+                        continue;
+
+                    $bUpdated = true;
+                }
+
+                $aParamsCopy['start'] += $iPerPage;
+            }
+
+            /**
+             * If cached event wasn't found in real events list, 
+             * then clear cache and start the process from the beginning.
+             */
+            if(!$bFound) {
+                $this->_oModule->_oDb->deleteCache(array('type' => $aParams['type'], 'profile_id' => $iProfileId));
+
+                return $this->_getPosts($aParams);
+            }
+
+            if($bUpdated)
+                $aCachedIds = array_keys($this->_getCachedEvents($iProfileId, $aParams));
+
+            return $this->_oDb->getEvents(array('browse' => 'ids', 'type' => $aParams['type'], 'ids' => $aCachedIds));
+        }
+
+        /*
+         * Cache data.
+         */
+        $aIds = $this->_cacheEvents($aParams);
+        return $this->_oDb->getEvents(array('browse' => 'ids', 'type' => $aParams['type'], 'ids' => $aIds));
+    }
+
+    protected function _getPost($sType, $aEvent, $aBrowseParams = array())
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        $oModule = $this->getModule();
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObjectView($aBrowseParams);
+
+        $bViewItem = isset($aBrowseParams['view']) && $aBrowseParams['view'] == BX_TIMELINE_VIEW_ITEM;
+        $bViewOutline = isset($aBrowseParams['view']) && $aBrowseParams['view'] == BX_TIMELINE_VIEW_OUTLINE;
+
+        list($sAuthorName, $sAuthorUrl, $sAuthorIcon, $sAuthorUnit, $sAuthorUnitShort) = $oModule->getUserInfo($aEvent['object_owner_id']);
+        $bAuthorIcon = !empty($sAuthorIcon);
+
+        if(($bViewItem || $this->_oConfig->isCountAllViews()) && !empty($aEvent['views']) && is_array($aEvent['views']) && isset($aEvent['views']['system']))
+            $oModule->getViewObject($aEvent['views']['system'], $aEvent['views']['object_id'])->doView();
+
+        $aTmplVarsNote = $this->_getTmplVarsNote($aEvent);
+        $aTmplVarsMenuItemActions = $this->_getTmplVarsMenuItemActions($aEvent, $aBrowseParams);
+        $aTmplVarsMenuItemMeta = $this->_getTmplVarsMenuItemMeta($aEvent, $aBrowseParams);
+
+        $aTmplVarsOwnerActions = $this->_getTmplVarsOwnerActions($aEvent, $aBrowseParams);
+        $bTmplVarsOwnerActions = !empty($aTmplVarsOwnerActions); 
+
+        $aTmplVarsTimelineOwner = $this->_getTmplVarsTimelineOwner($aEvent);
+        
+        $aTmplVarsReactions = $this->_getTmplVarsReactions($aEvent, $aBrowseParams);
+
+        $bPinned = (int)$aEvent['pinned'] > 0;
+        $bSticked = (int)$aEvent['sticked'] > 0;
+        $bPromoted = (int)$aEvent['promoted'] > 0;
+
+        $sClass = $sStylePrefix . '-view-sizer';
+        if($bViewOutline) {
+            $sClass = $sStylePrefix . '-grid-item-sizer';
+            if($bPinned || $bSticked || $bPromoted) {
+                $sClass .= ' ' . $sStylePrefix . '-gis';
+
+            if($bPinned)
+                $sClass .= '-pnd';
+            if($bSticked)
+                $sClass .= '-psd';
+            if($bPromoted)
+                $sClass .= '-pmd';
+            }
+        }
+        if(!empty($aBrowseParams['blink']) && in_array($aEvent['id'], $aBrowseParams['blink']))
+			$sClass .= ' ' . $sStylePrefix . '-blink';
+        if($bPinned)
+            $sClass .= ' ' . $sStylePrefix . '-pinned';
+        if($bSticked)
+            $sClass .= ' ' . $sStylePrefix . '-sticked';
+        if($bPromoted)
+            $sClass .= ' ' . $sStylePrefix . '-promoted';
+
+        $sClassOwner = $bTmplVarsOwnerActions ? $sStylePrefix . '-io-with-actions' : '';
+
+        $oMetatags = BxDolMetatags::getObjectInstance($this->_oConfig->getObject('metatags'));
+        $sLocation = $oMetatags->locationsString($aEvent['id']);
+ 
+        $aTmplVars = array (
+            'style_prefix' => $sStylePrefix,
+            'js_object' => $sJsObject,
+            'html_id' => $this->_oConfig->getHtmlIdView('item', $aBrowseParams, false) . $aEvent['id'],
+            'class' => $sClass,
+            'class_owner' => $sClassOwner,
+            'class_content' => $bViewItem ? 'bx-def-color-bg-block' : 'bx-def-color-bg-box',
+            'id' => $aEvent['id'],
+            'bx_if:show_note' => array(
+                'condition' => !empty($aTmplVarsNote),
+                'content' => $aTmplVarsNote
+            ),
+            'bx_if:show_owner_icon' => array(
+                'condition' => $bAuthorIcon,
+                'content' => array(
+                    'owner_icon' => $sAuthorIcon
+                )
+            ),
+            'bx_if:show_owner_icon_empty' => array(
+                'condition' => !$bAuthorIcon,
+                'content' => array()
+            ),
+            'bx_if:show_owner_actions' => array(
+                'condition' => $bTmplVarsOwnerActions,
+                'content' => $aTmplVarsOwnerActions
+            ),
+            'item_icon' => !empty($aEvent['icon']) ? $aEvent['icon'] : $CNF['ICON'],
+            'item_owner_url' => $sAuthorUrl,
+            'item_owner_title' => bx_html_attribute($sAuthorName),
+            'item_owner_name' => $sAuthorName,
+            'item_owner_unit' => $sAuthorUnitShort,
+            'item_owner_action' => _t($aEvent['sample_action'], _t($aEvent['sample'])),
+            'bx_if:show_timeline_owner' => array(
+                'condition' => !empty($aTmplVarsTimelineOwner),
+                'content' => $aTmplVarsTimelineOwner
+            ),
+            'item_view_url' => $this->_oConfig->getItemViewUrl($aEvent),
+            'item_date' => bx_time_js($aEvent['date']),
+            'bx_if:show_pinned' => array(
+            	'condition' => $bPinned,
+            	'content' => array(
+                    'style_prefix' => $sStylePrefix,
+            	)
+            ),
+            'bx_if:show_sticked' => array(
+            	'condition' => $bSticked,
+            	'content' => array(
+                    'style_prefix' => $sStylePrefix,
+            	)
+            ),
+            'bx_if:show_hot' => array(
+            	'condition' => isset($aBrowseParams['hot']) && is_array($aBrowseParams['hot']) && in_array($aEvent['id'], $aBrowseParams['hot']),
+            	'content' => array(
+                    'style_prefix' => $sStylePrefix,
+            	)
+            ),
+            'content' => is_string($aEvent['content']) ? $aEvent['content'] : $this->_getContent($sType, $aEvent, $aBrowseParams),
+            'bx_if:show_location' => array(
+            	'condition' => !empty($sLocation),
+            	'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'location' => $sLocation
+            	)
+            ),
+            'bx_if:show_reactions' => array(
+                'condition' => !empty($aTmplVarsReactions),
+                'content' => $aTmplVarsReactions
+            ),
+            'bx_if:show_menu_item_actions' => array(
+                'condition' => !empty($aTmplVarsMenuItemActions),
+                'content' => $aTmplVarsMenuItemActions
+            ),
+            'bx_if:show_menu_item_meta' => array(
+                'condition' => !empty($aTmplVarsMenuItemMeta),
+                'content' => $aTmplVarsMenuItemMeta
+            ),
+            'comments' => '',
+        );
+
+        $iPreloadComments = $this->_oConfig->getPreloadComments();
+        if($iPreloadComments > 0 && $oModule->isAllowedComment($aEvent) && in_array($aBrowseParams['view'], array(BX_TIMELINE_VIEW_TIMELINE, BX_TIMELINE_VIEW_OUTLINE)))
+            $aTmplVars['comments'] = $this->_getComments($aEvent['comments'], array_merge($aBrowseParams, array(
+                'cmts_preload_number' => $iPreloadComments,
+                'cmts_min_post_form' => false
+            )));
+
+        $sVariable = '_sTmplContentItem' . bx_gen_method_name($aBrowseParams['view']);
+        if(empty(self::$$sVariable))
+            self::$$sVariable = $this->getHtml('item_' . $aBrowseParams['view'] . '.html');
+
+        $sTmplCode = self::$$sVariable;
+        bx_alert($this->_oConfig->getName(), 'get_post', 0, 0, array(
+            'type' => $sType,
+            'event' => $aEvent,
+            'browse_params' => $aBrowseParams,
+            'tmpl_code' => &$sTmplCode,
+            'tmpl_vars' => &$aTmplVars
+        ));
+
+        return $this->parseHtmlByContent($sTmplCode, $aTmplVars);
+    }
+
+    protected function _getContent($sType, $aEvent, $aBrowseParams = array())
+    {
+        $sMethod = '_getTmplVarsContent' . ucfirst($sType);
+        if(!method_exists($this, $sMethod))
+            return '';
+
+        $sVariable = '_sTmplContentType' . bx_gen_method_name($sType);
+        if(empty(self::$$sVariable))
+            self::$$sVariable = $this->getHtml('type_' . $sType . '.html');
+
+		return $this->parseHtmlByContent(self::$$sVariable, $this->$sMethod($aEvent, $aBrowseParams));
+    }
+
+    protected function _getComments($aComments, $aBrowseParams = array())
+    {
+        $mixedComments = $this->getModule()->getCommentsData($aComments);
+        if($mixedComments === false)
+            return '';
+
+        list($sSystem, $iObjectId, $iCount) = $mixedComments;
+        return $this->getComments($sSystem, $iObjectId, $aBrowseParams);
+    }
+
+    protected function _getShowMore($aParams)
+    {
+        return $this->parseHtmlByName('show_more.html', array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'js_object' => $this->_oConfig->getJsObjectView($aParams),
+        ));
+    }
+
+    protected function _getImagePopup($aParams)
+    {
+        $sViewImagePopupId = $this->_oConfig->getHtmlIdView('photo_popup', $aParams);
+        $sViewImagePopupContent = $this->parseHtmlByName('popup_image.html', array(
+            'image_url' => ''
+    	));
+
+    	return BxTemplFunctions::getInstance()->transBox($sViewImagePopupId, $sViewImagePopupContent, true);
+    }
+
+    protected function _getRepostJsClick($iOwnerId, $sType, $sAction, $iObjectId)
+    {
+        $sJsObject = $this->_oConfig->getJsObject('repost');
+        $sFormat = "%s.repostItem(this, %d, '%s', '%s', %d);";
+
+        $iOwnerId = !empty($iOwnerId) ? (int)$iOwnerId : $this->getModule()->getUserId(); //--- in whose timeline the content will be reposted
+        return sprintf($sFormat, $sJsObject, $iOwnerId, $sType, $sAction, (int)$iObjectId);
+    }
+
+    protected function _getTmplVarsMenuItemActions(&$aEvent, $aBrowseParams = array())
+    {
+        $oMenu = BxDolMenu::getObjectInstance($this->_oConfig->getObject('menu_item_actions'));
+        $oMenu->setEvent($aEvent, $aBrowseParams);
+        $oMenu->setDynamicMode(isset($aBrowseParams['dynamic_mode']) && $aBrowseParams['dynamic_mode'] === true);
+
+        $sMenu = $oMenu->getCode();
+        if(empty($sMenu))
+            return array();
+
+        return array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'js_object' => $this->_oConfig->getJsObjectView($aBrowseParams),
+            'menu_item_actions' => $sMenu
+        );
+    }
+
+    protected function _getTmplVarsMenuItemMeta(&$aEvent, $aBrowseParams = array())
+    {
+        $oMenu = BxDolMenu::getObjectInstance($this->_oConfig->getObject('menu_item_meta'));
+        $oMenu->setEvent($aEvent);
+
+        $sMenu = $oMenu->getCode();
+        if(empty($sMenu))
+            return array();
+
+        return array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'meta' => $sMenu
+        );
+    }
+
+    protected function _getTmplVarsTimelineOwner(&$aEvent)
+    {
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $iUser = bx_get_logged_profile_id();
+        $oModule = $this->getModule();
+
+        $sConnection = $this->_oConfig->getObject('conn_subscriptions');
+        $oConnection = BxDolConnection::getObjectInstance($sConnection);
+        $sConnectionTitle = _t('_sys_menu_item_title_sm_subscribe');
+
+        $sKeyOwnerId = isset($aEvent['owner_id_orig']) ? 'owner_id_orig' : 'owner_id';
+        $aOwnerIds = is_array($aEvent[$sKeyOwnerId]) ? $aEvent[$sKeyOwnerId] : array($aEvent[$sKeyOwnerId]);
+
+        $aTmplVarsOwners = array();
+        foreach($aOwnerIds as $iOwnerId) {
+            $iOwnerId = (int)$iOwnerId;
+            $iObjectOwner = (int)$aEvent['object_owner_id'];
+            if($iObjectOwner < 0 && abs($iObjectOwner) == $iUser)
+                $iObjectOwner *= -1;
+
+            if($iOwnerId == 0 || $iOwnerId == $iObjectOwner)
+                continue;
+
+            list($sToName, $sToUrl, $sToThumb, $sToUnit, $sToUnitWoInfo) = $oModule->getUserInfo($iOwnerId);
+            $sToType = $oModule->getObjectUser($iOwnerId)->getModule();
+
+            $aTmplVarsActions = array();
+            if(!empty($iUser) && $iUser != $iOwnerId && $oConnection->checkAllowedConnect($iUser, $iOwnerId) === CHECK_ACTION_RESULT_ALLOWED) {
+                $aTmplVarsActions[] = array(
+                    'href' => "javascript:void(0)",
+                    'onclick' => "bx_conn_action(this, '" . $sConnection . "', 'add', '" . $iOwnerId . "')",
+                    'title' => bx_html_attribute($sConnectionTitle),
+                    'content' => $sConnectionTitle,
+                    'icon' => 'check'
+                );
+            }
+
+            $aTmplVarsOwners[] =  array(
+                'style_prefix' => $sStylePrefix,
+                'owner_type' => _t('_' . $sToType),
+                'owner_url' => $sToUrl,
+                'owner_username' => $sToName,
+                'owner_thumb' => $sToThumb,
+                'owner_unit' => $sToUnit,
+                'owner_unit_wo_info' => $sToUnitWoInfo,
+                'bx_if:show_timeline_owner_actions' => array(
+                    'condition' => !empty($aTmplVarsActions),
+                    'content' => array(
+                        'style_prefix' => $sStylePrefix,
+                        'bx_repeat:timeline_owner_actions' => $aTmplVarsActions
+                    )
+                )
+            );
+        }
+
+        if(empty($aTmplVarsOwners))
+            return array();
+
+        return array(
+            'style_prefix' => $sStylePrefix,
+            'bx_repeat:owners' => $aTmplVarsOwners
+        );
+    }
+
+    protected function _getTmplVarsContentPost(&$aEvent, $aBrowseParams = array())
+    {
+    	$aContent = &$aEvent['content'];
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $bViewItem = isset($aBrowseParams['view']) && $aBrowseParams['view'] == BX_TIMELINE_VIEW_ITEM;
+
+        //--- Process Raw ---//
+        $sRaw = isset($aContent['raw']) ? $aContent['raw'] : '';
+
+        //--- Process Text ---//
+        $sUrl = isset($aContent['url']) ? bx_html_attribute($aContent['url']) : '';
+        $sTitle = '';
+        if(isset($aContent['title']))
+            $sTitle = bx_process_output($aContent['title']);
+
+        if(!empty($sUrl) && !empty($sTitle))
+            $sTitle = $this->parseLink($sUrl, $sTitle, array(
+            	'class' => $sStylePrefix . '-title',
+                'title' => $sTitle
+            ));
+
+        $sText = isset($aContent['text']) ? $aContent['text'] : '';
+        $sText = $this->_prepareTextForOutput($sText, $aEvent['id']);
+
+        //--- Process Links ---//
+        $bAddNofollow = $this->_oDb->getParam('sys_add_nofollow') == 'on';
+
+        $aTmplVarsLinks = array();
+        if(!empty($aContent['links']))
+            foreach($aContent['links'] as $aLink) {
+                $sLink = '';
+
+                $oEmbed = BxDolEmbed::getObjectInstance();
+                if ($oEmbed) {
+                    $sLink = $this->parseHtmlByName('link_embed_provider.html', array(
+                        'style_prefix' => $sStylePrefix,
+                        'embed' => $oEmbed->getLinkHTML($aLink['url'], $aLink['title']),
+                    ));
+                }
+                else {
+                    $aLinkAttrs = array(
+                    	'title' => $aLink['title']
+                    );
+                    if(!$this->_oConfig->isEqualUrls(BX_DOL_URL_ROOT, $aLink['url'])) {
+                        $aLinkAttrs['target'] = '_blank';
+    
+                        if($bAddNofollow)
+                    	    $aLinkAttrs['rel'] = 'nofollow';
+                    }
+
+                    $sLinkAttrs = '';
+                    foreach($aLinkAttrs as $sKey => $sValue)
+                        $sLinkAttrs .= ' ' . $sKey . '="' . bx_html_attribute($sValue) . '"';
+
+                    $sLink = $this->parseHtmlByName('link_embed_common.html', array(
+                        'bx_if:show_thumbnail' => array(
+                            'condition' => !empty($aLink['thumbnail']),
+                            'content' => array(
+                                'style_prefix' => $sStylePrefix,
+                                'thumbnail' => $aLink['thumbnail'],
+                                'link' => !empty($aLink['url']) ? $aLink['url'] : 'javascript:void(0)',
+                                'attrs' => $sLinkAttrs
+                            )
+                        ),
+                        'link' => !empty($aLink['url']) ? $aLink['url'] : 'javascript:void(0)',
+                        'attrs' => $sLinkAttrs,
+                        'content' => $aLink['title'],
+                        'bx_if:show_text' => array(
+                            'condition' => !empty($aLink['text']),
+                            'content' => array(
+                                'style_prefix' => $sStylePrefix,
+                                'text' => $aLink['text']
+                            )
+                        )
+                    ));
+                }
+
+                $aTmplVarsLinks[] = array(
+                    'style_prefix' => $sStylePrefix,
+                    'link' => $sLink
+                );
+            }
+
+        $aTmplVarsImages = $aTmplVarsVideos = $aTmplVarsAttachments = array();
+
+        //--- Process Photos ---//
+        $bImages = !empty($aContent['images']) && is_array($aContent['images']);
+        if($bImages) {
+            $aImages = $this->_getTmplVarsImages($aContent['images'], $aEvent, $aBrowseParams);
+            if(!empty($aImages))
+                $aTmplVarsImages = array(
+                    'style_prefix' => $sStylePrefix,
+                    'display' => $aImages['display'],
+                    'bx_repeat:items' => $aImages['items']
+                );
+        }
+
+        $bImagesAttach = !empty($aContent['images_attach']) && is_array($aContent['images_attach']);
+        if($bImagesAttach) {
+            $aImagesAttach = $this->_getTmplVarsImages($aContent['images_attach'], $aEvent, $aBrowseParams);
+            if(!empty($aImagesAttach))
+                $aTmplVarsAttachments = array_merge ($aTmplVarsAttachments, $aImagesAttach['items']);
+        }
+            
+        
+        //--- Add Meta Image when Item is viewed on a separate page ---//
+        if($bViewItem) {
+            $sMetaImageSrc = '';
+            if($bImages && !empty($aContent['images'][0]['src']))
+                $sMetaImageSrc = $aContent['images'][0]['src'];
+            else if($bImagesAttach && !empty($aContent['images_attach'][0]['src']))
+                $sMetaImageSrc = $aContent['images_attach'][0]['src'];
+
+            if(!empty($sMetaImageSrc))
+                BxDolTemplate::getInstance()->addPageMetaImage($sMetaImageSrc);
+        }
+
+    	//--- Process Videos ---//
+        $bVideos = !empty($aContent['videos']) && is_array($aContent['videos']);
+        if($bVideos) {
+            $aVideos = $this->_getTmplVarsVideos($aContent['videos'], true, $aEvent, $aBrowseParams);
+            if(!empty($aVideos))
+                $aTmplVarsVideos = array(
+                    'style_prefix' => $sStylePrefix,
+                    'display' => $aVideos['display'],
+                    'bx_repeat:items' => $aVideos['items']
+                );
+        }
+
+        $bVideosAttach = !empty($aContent['videos_attach']) && is_array($aContent['videos_attach']);
+        if($bVideosAttach) {
+            $aVideosAttach = $this->_getTmplVarsVideos($aContent['videos_attach'], false, $aEvent, $aBrowseParams);
+            if(!empty($aVideosAttach))
+                $aTmplVarsAttachments = array_merge($aTmplVarsAttachments, $aVideosAttach['items']);
+        }
+
+        //--- Process Files ---//
+        $bFiles = !empty($aContent['files']) && is_array($aContent['files']);
+        if($bFiles) {
+            $aFiles = $this->_getTmplVarsFiles($aContent['files'], $aEvent, $aBrowseParams);
+            if(!empty($aFiles))
+                $aTmplVarsFiles = array(
+                    'style_prefix' => $sStylePrefix,
+                    'display' => $aFiles['display'],
+                    'bx_repeat:items' => $aFiles['items']
+                );
+        }
+
+        $bFilesAttach = !empty($aContent['files_attach']) && is_array($aContent['files_attach']);
+        if($bFilesAttach) {
+            $aFilesAttach = $this->_getTmplVarsFiles($aContent['files_attach'], $aEvent, $aBrowseParams);
+            if(!empty($aFilesAttach))
+                $aTmplVarsAttachments = array_merge ($aTmplVarsAttachments, $aFilesAttach['items']);
+        }
+
+        return array(
+            'style_prefix' => $sStylePrefix,
+            'bx_if:show_title' => array(
+                'condition' => !empty($sTitle),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'title' => $sTitle,
+                )
+            ),
+            'bx_if:show_content' => array(
+                'condition' => !empty($sText),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'item_content' => $sText
+                )
+            ),
+            'bx_if:show_raw' => array(
+                'condition' => !empty($sRaw),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'item_content_raw' => $sRaw
+                )
+            ),
+            'bx_if:show_links' => array(
+                'condition' => !empty($aTmplVarsLinks),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'bx_repeat:links' => $aTmplVarsLinks
+                )
+            ),
+            'bx_if:show_images' => array(
+                'condition' => !empty($aTmplVarsImages),
+                'content' => $aTmplVarsImages
+            ),
+            'bx_if:show_videos' => array(
+                'condition' => !empty($aTmplVarsVideos),
+                'content' => $aTmplVarsVideos
+            ),
+            'bx_if:show_attachments' => array(
+                'condition' => !empty($aTmplVarsAttachments),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'bx_repeat:items' => $aTmplVarsAttachments
+                )
+            )
+        );
+    }
+
+    protected function _getTmplVarsContentRepost(&$aEvent, $aBrowseParams = array())
+    {
+    	$aContent = &$aEvent['content'];
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $sOwnerLink = $this->parseLink($aContent['owner_url'], $aContent['owner_name']);
+
+        $sSample = _t($aContent['sample']);
+        $sSampleLink = empty($aContent['url']) ? $sSample : $this->parseLink($aContent['url'], $sSample);
+
+        $sTitle = _t('_bx_timeline_txt_reposted', $sOwnerLink, $sSampleLink);
+        $sText = $this->_getContent($aContent['parse_type'], $aEvent);
+
+        return array(
+            'bx_if:show_title' => array(
+                'condition' => !empty($sTitle),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'title' => $sTitle,
+                )
+            ),
+            'bx_if:show_content' => array(
+                'condition' => !empty($sText),
+                'content' => array(
+                    'style_prefix' => $sStylePrefix,
+                    'content' => $sText,
+                )
+            )
+        );
+    }
+
+    protected function _getTmplVarsNote(&$aEvent)
+    {
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $iUser = bx_get_logged_profile_id();
+        $iOwner = $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? $aEvent['owner_id'] : $aEvent['object_id'];
+
+        $aTmplVars = array();
+        if(!empty($iOwner) && !is_array($iOwner) && !empty($aEvent['promoted'])) {
+            $sConnection = $this->_oConfig->getObject('conn_subscriptions');
+            $oConnection = BxDolConnection::getObjectInstance($sConnection);
+            if(!$oConnection->isConnected($iUser, $iOwner))
+                $aTmplVars[] = array(
+                    'style_prefix' => $sStylePrefix,
+                    'class' => '',
+                    'bx_if:show_note_color' => array(
+                        'condition' => false,
+                        'content' => array(
+                            'item_note_color' => 'red1',
+                        )
+                    ),
+                    'item_note' => _t('_bx_timeline_txt_promoted')
+                );
+        }
+
+        //--- Awaiting status related notes.
+        if($aEvent['status'] == BX_TIMELINE_STATUS_AWAITING) {
+            $sNote = '';
+            if((int)$aEvent['published'] > (int)$aEvent['date'])
+                $sNote = _t('_bx_timeline_txt_note_scheduled_awaiting', bx_time_js($aEvent['published'], BX_FORMAT_DATE, true));
+            else
+                $sNote = _t('_bx_timeline_txt_note_processing_awaiting');
+
+            $aTmplVars[] = array(
+                'style_prefix' => $sStylePrefix,
+                'bx_if:show_note_color' => array(
+                    'condition' => true,
+                    'content' => array(
+                        'item_note_color' => 'red3'
+                    )
+                ),
+                'item_note' => $sNote
+            );
+        }
+
+        //--- Failed status related notes.
+        if($aEvent['status'] == BX_TIMELINE_STATUS_FAILED)
+            $aTmplVars[] = array(
+                'style_prefix' => $sStylePrefix,
+                'bx_if:show_note_color' => array(
+                    'condition' => true,
+                    'content' => array(
+                        'item_note_color' => 'red2'
+                    )
+                ),
+                'item_note' => _t('_bx_timeline_txt_note_processing_failed')
+            );
+
+        return empty($aTmplVars) ? array() : array(
+            'style_prefix' => $sStylePrefix,
+            'bx_repeat:notes' => $aTmplVars
+        );
+    }
+
+    protected function _getTmplVarsOwnerActions(&$aEvent, $aBrowseParams = array())
+    {
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $iUser = bx_get_logged_profile_id();
+        $iOwner = $this->_oConfig->isSystem($aEvent['type'], $aEvent['action']) ? $aEvent['object_owner_id'] : $aEvent['object_id'];
+
+        $aTmplVarsActions = array();
+        if(!empty($iUser) && !empty($iOwner) && $iUser != $iOwner) {
+            $sConnection = $this->_oConfig->getObject('conn_subscriptions');
+            if(BxDolConnection::getObjectInstance($sConnection)->checkAllowedConnect($iUser, $iOwner) === CHECK_ACTION_RESULT_ALLOWED) {
+                $sJsObject = $this->_oConfig->getJsObjectView($aBrowseParams);
+
+                $sContent = _t('_sys_menu_item_title_sm_subscribe');
+                $aTmplVarsActions[] = array(
+                    'href' => "javascript:void(0)",
+                    'onclick' => "bx_conn_action(this, '" . $sConnection . "', 'add', '" . $iOwner . "', false, function(oData, eElement) {" . $sJsObject . ".onConnect(eElement, oData);})",
+                    'title' => bx_html_attribute($sContent),
+                    'content' => $sContent,
+                    'icon' => 'check'
+                );
+            }
+        }
+
+        return array(
+            'style_prefix' => $sStylePrefix,
+            'bx_repeat:owner_actions' => $aTmplVarsActions
+        );
+    }
+
+    protected function _getTmplVarsImages($aImages, &$aEvent, &$aBrowseParams)
+    {
+        if(empty($aImages) || !is_array($aImages))
+            return array();
+
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObjectView($aBrowseParams);
+
+        $bViewItem = isset($aBrowseParams['view']) && $aBrowseParams['view'] == BX_TIMELINE_VIEW_ITEM;
+
+        $sDisplay = '';
+        $aTmplVarsImages = array();
+
+        $sImageSrcKey = '';
+        $sImageSrcKeyDefault = 'src';
+        if(count($aImages) == 1) {
+            $sDisplay = 'single';
+            $sImageSrcKey = $bViewItem ? 'src_orig' : 'src_medium';
+        }
+        else {
+            $sDisplay = 'gallery';
+            $sImageSrcKey = 'src';
+        }
+
+        foreach($aImages as $aImage) {
+            $sImageSrc = !empty($aImage[$sImageSrcKey]) ? $aImage[$sImageSrcKey] : $aImage[$sImageSrcKeyDefault];
+            if(empty($sImageSrc))
+                continue;
+
+            $sImage = $this->parseImage($sImageSrc, array(
+                'class' => $sStylePrefix . '-item-image'
+            ));
+
+            $aAttrs = array();
+            if(isset($aImage['onclick']))
+                $aAttrs['onclick'] = $aImage['onclick'];
+            else if(!$bViewItem && !empty($aImage['src_orig']))
+                $aAttrs['onclick'] = 'return ' . $sJsObject . '.showItem(this, \'' . $aEvent['id'] . '\', \'photo\', ' . json_encode(array('src' => base64_encode($aImage['src_orig']))) . ')'; 
+
+            $sImage = $this->parseLink(isset($aImage['url']) ? $aImage['url'] : 'javascript:void(0)', $sImage, $aAttrs);
+
+            $aTmplVarsImages[] = array(
+                'style_prefix' => $sStylePrefix,
+                'item' => $sImage
+            );
+        }
+        
+        return array(
+            'display' => $sDisplay,
+            'items' => $aTmplVarsImages
+        );
+    }
+
+    protected function _getTmplVarsVideos($aVideos, $bMain, &$aEvent, &$aBrowseParams)
+    {
+        if(empty($aVideos) || !is_array($aVideos))
+            return array();
+
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+
+        $sDisplay = count($aVideos) == 1 ? 'single' : 'gallery';
+        $aTmplVarsVideos = array();
+
+        /*
+         * Autoplay feature is available for Main video only.
+         */
+        $sVap = $sVapId = $sVapSrc = $sVapTmpl = '';
+        if($bMain) {
+            $sVap = $this->_oConfig->getVideosAutoplay();
+            if($sVap != BX_TIMELINE_VAP_OFF) {
+                $sVapId = $this->_oConfig->getHtmlIds('view', 'video_iframe') . $aEvent['id'] . '-';
+                $sVapSrc = BX_DOL_URL_ROOT . $this->_oConfig->getBaseUri() . 'video/' . $aEvent['id'] . '/';
+                $sVapTmpl = $this->getHtml('video_iframe.html');
+
+                if(count($aVideos) > 1)
+                    $aVideos = array_slice($aVideos, 0, 1);
+            }
+        }
+
+        foreach($aVideos as $iVideo => $aVideo) {
+            if(!$bMain || $sVap == BX_TIMELINE_VAP_OFF)
+                $aTmplVarsVideos[] = array(
+                    'style_prefix' => $sStylePrefix,
+                    'item' => BxTemplFunctions::getInstance()->videoPlayer($aVideo['src_poster'], $aVideo['src_mp4'], $aVideo['src_mp4_hd'], array(
+                        'preload' => 'auto'
+                    ), '') 
+                );
+            else 
+                $aTmplVarsVideos[] = array(
+                    'style_prefix' => $sStylePrefix,
+                    'item' => $this->parseHtmlByContent($sVapTmpl, array(
+                        'style_prefix' => $sStylePrefix,
+                        'html_id' => $sVapId . $iVideo,
+                        'src' => $sVapSrc . $iVideo . '/'
+                    )) 
+                );
+        }
+
+        return array( 
+            'display' => $sDisplay,
+            'items' => $aTmplVarsVideos
+        );
+    }
+
+    protected function _getTmplVarsFiles($aFiles, &$aEvent, &$aBrowseParams)
+    {
+        if(empty($aFiles) || !is_array($aFiles))
+            return array();
+
+        $sStylePrefix = $this->_oConfig->getPrefix('style');
+        $sJsObject = $this->_oConfig->getJsObjectView($aBrowseParams);
+
+        $bViewItem = isset($aBrowseParams['view']) && $aBrowseParams['view'] == BX_TIMELINE_VIEW_ITEM;
+
+        $sDisplay = '';
+        $aTmplVarsFiles = array();
+
+        $sFileSrcKey = '';
+        $sFileSrcKeyDefault = 'src';
+        if(count($aFiles) == 1) {
+            $sDisplay = 'single';
+            $sFileSrcKey = $bViewItem ? 'src_orig' : 'src_medium';
+        }
+        else {
+            $sDisplay = 'gallery';
+            $sFileSrcKey = 'src';
+        }
+
+        foreach($aFiles as $aFile) {
+            $sFileSrc = !empty($aFile[$sFileSrcKey]) ? $aFile[$sFileSrcKey] : $aFile[$sFileSrcKeyDefault];
+            if(empty($sFileSrc))
+                continue;
+
+            $sImage = $this->parseImage($sFileSrc, array(
+                'class' => $sStylePrefix . '-item-file'
+            ));
+
+            $aAttrs = array();
+            if(isset($aFile['onclick']))
+                $aAttrs['onclick'] = $aFile['onclick'];
+            else if(!$bViewItem && !empty($aFile['src_orig']))
+                $aAttrs['onclick'] = 'return ' . $sJsObject . '.showItem(this, \'' . $aEvent['id'] . '\', \'photo\', ' . json_encode(array('src' => base64_encode($aFile['src_orig']))) . ')'; 
+
+            $sImage = $this->parseLink(isset($aFile['url']) ? $aFile['url'] : 'javascript:void(0)', $sImage, $aAttrs);
+
+            $aTmplVarsFiles[] = array(
+                'style_prefix' => $sStylePrefix,
+                'item' => $sImage
+            );
+        }
+        
+        return array(
+            'display' => $sDisplay,
+            'items' => $aTmplVarsFiles
+        );
+    }
+
+    protected function _getTmplVarsReactions(&$aEvent, $aBrowseParams = array())
+    {
+        if(!isset($aEvent['reactions']) || !is_array($aEvent['reactions']) || !isset($aEvent['reactions']['system']))
+            return array();
+
+        $sReactionsSystem = $aEvent['reactions']['system'];
+        $iReactionsObject = $aEvent['reactions']['object_id'];
+        $aReactionsParams = array(
+            'show_counter' => true, 
+            'dynamic_mode' => isset($aBrowseParams['dynamic_mode']) && $aBrowseParams['dynamic_mode'] === true
+        );
+
+        $oReactions = $this->getModule()->getReactionObject($sReactionsSystem, $iReactionsObject);
+        if(!$oReactions)
+            return array();
+
+        return array(
+            'style_prefix' => $this->_oConfig->getPrefix('style'),
+            'reactions' => $oReactions->getCounter($aReactionsParams)
+        );
+    }
+
+    protected function _getSystemData(&$aEvent, $aBrowseParams = array())
+    {
+        $mixedResult = $this->_oConfig->getSystemData($aEvent, $aBrowseParams);
+        if($mixedResult === false) {
+            $sMethod = 'display' . bx_gen_method_name($aEvent['type'] . '_' . $aEvent['action']);
+            if(method_exists($this, $sMethod))
+                $mixedResult = $this->$sMethod($aEvent);
+        }
+
+        if($mixedResult === false)
+            return '';
+
+        $this->_preparetDataActions($aEvent, $mixedResult);
+        return $mixedResult;
+    }
+
+    protected function _getCommonData(&$aEvent, $aBrowseParams = array())
+    {
+        $CNF = $this->_oConfig->CNF;
+
+        $oModule = $this->getModule();
+        $sJsObject = $this->_oConfig->getJsObjectView($aBrowseParams);
+        $sPrefix = $this->_oConfig->getPrefix('common_post');
+        $sType = str_replace($sPrefix, '', $aEvent['type']);
+
+        $oOwner = BxDolProfile::getInstanceMagic($aEvent['object_id']);
+
+        $aResult = array(
+            'owner_id' => $aEvent['owner_id'],
+            'object_owner_id' => $aEvent['object_id'],
+            'icon' => $CNF['ICON'],
+            'sample' => '_bx_timeline_txt_sample_with_article',
+            'sample_wo_article' => '_bx_timeline_txt_sample',
+            'sample_action' => '_bx_timeline_txt_added_sample',
+            'content_type' => $sType,
+            'content' => array(
+                'sample' => '_bx_timeline_txt_sample_with_article',
+                'sample_wo_article' => '_bx_timeline_txt_sample',
+                'sample_action' => '_bx_timeline_txt_added_sample',
+                'url' => $this->_oConfig->getItemViewUrl($aEvent)
+            ), //a string to display or array to parse default template before displaying.
+            'views' => '',
+            'votes' => '',
+            'reactions' => '',
+            'scores' => '',
+            'reports' => '',
+            'comments' => '',
+            'title' => $aEvent['title'], //may be empty.
+            'description' => bx_replace_markers($aEvent['description'], array(
+                'profile_name' => $oOwner->getDisplayName()
+            )) //may be empty.
+        );
+
+        switch($sType) {
+            case BX_TIMELINE_PARSE_TYPE_POST:
+                if(!empty($aEvent['content']))
+                    $aResult['content'] = array_merge($aResult['content'], unserialize($aEvent['content']));
+
+                $aLinks = $this->_oDb->getLinks($aEvent['id']);
+                if(!empty($aLinks) && is_array($aLinks))
+                    $oTranscoder = BxDolTranscoderImage::getObjectInstance($this->_oConfig->getObject('transcoder_photos_preview'));
+
+                foreach($aLinks as $aLink)
+                    $aResult['content']['links'][] = array(
+                        'url' => $aLink['url'],
+                        'title' => $aLink['title'],
+                        'text' => $aLink['text'],
+                        'thumbnail' => (int)$aLink['media_id'] != 0 ? $oTranscoder->getFileUrl($aLink['media_id']) : ''
+                    );
+
+                $aPhotos = $this->_oDb->getMedia(BX_TIMELINE_MEDIA_PHOTO, $aEvent['id']);
+                if(!empty($aPhotos) && is_array($aPhotos)) {
+                    $oTranscoder = BxDolTranscoderImage::getObjectInstance($this->_oConfig->getObject('transcoder_photos_view'));
+                    $oTranscoderMedium = BxDolTranscoderImage::getObjectInstance($this->_oConfig->getObject('transcoder_photos_medium'));
+                    $oTranscoderBig = BxDolTranscoderImage::getObjectInstance($this->_oConfig->getObject('transcoder_photos_big'));
+
+                    foreach($aPhotos as $iPhotoId) {
+                        $sPhotoSrc = $oTranscoder->getFileUrl($iPhotoId);
+                        $sPhotoSrcMedium = $oTranscoderMedium->getFileUrl($iPhotoId);
+                        $sPhotoSrcBig = $oTranscoderBig->getFileUrl($iPhotoId);
+                        if(empty($sPhotoSrcMedium) && !empty($sPhotoSrc))
+                            $sPhotoSrcMedium = $sPhotoSrc;
+                        if(empty($sPhotoSrcBig) && !empty($sPhotoSrcMedium))
+                            $sPhotoSrcBig = $sPhotoSrcMedium;
+
+                        $aResult['content']['images_attach'][] = array(
+                            'src' => $sPhotoSrc,
+                        	'src_medium' => $sPhotoSrcMedium,
+                            'src_orig' => $sPhotoSrcBig,
+                        );
+                    }
+                }
+
+                $aVideos = $this->_oDb->getMedia(BX_TIMELINE_MEDIA_VIDEO, $aEvent['id']);
+                if(!empty($aVideos) && is_array($aVideos)) {
+                    $oStorage = BxDolStorage::getObjectInstance($this->_oConfig->getObject('storage_videos'));
+
+                    $oTranscoderPoster = BxDolTranscoderVideo::getObjectInstance($this->_oConfig->getObject('transcoder_videos_poster'));
+                    $oTranscoderMp4 = BxDolTranscoderVideo::getObjectInstance($this->_oConfig->getObject('transcoder_videos_mp4'));
+                    $oTranscoderMp4Hd = BxDolTranscoderVideo::getObjectInstance($this->_oConfig->getObject('transcoder_videos_mp4_hd'));
+
+                    foreach($aVideos as $iVideoId) {
+                        $sVideoUrl = $oStorage->getFileUrlById($iVideoId);
+                        $aVideoSize = $oTranscoderMp4Hd->getVideoSize($sVideoUrl);
+
+                        $sVideoUrlHd = '';
+                        if(!empty($aVideoSize) && is_array($aVideoSize) && (int)$aVideoSize['h'] >= 720)
+                            $sVideoUrlHd = $oTranscoderMp4Hd->getFileUrl($iVideoId);
+
+                        $aResult['content']['videos_attach'][$iVideoId] = array(
+                            'id' => $iVideoId,
+                            'src_poster' => $oTranscoderPoster->getFileUrl($iVideoId),
+                            'src_mp4' => $oTranscoderMp4->getFileUrl($iVideoId),
+                            'src_mp4_hd' => $sVideoUrlHd,
+                        );
+                    }
+                }
+                break;
+
+            case BX_TIMELINE_PARSE_TYPE_REPOST:
+                if(empty($aEvent['content']))
+                    return array();
+
+                $aContent = unserialize($aEvent['content']);
+
+                if(!$this->_oConfig->isSystem($aContent['type'] , $aContent['action'])) {
+                    $aReposted = $this->_oDb->getEvents(array('browse' => 'id', 'value' => $aContent['object_id']));
+                    $aReposted = $this->_getCommonData($aReposted, $aBrowseParams);
+                } 
+                else {
+                    $aReposted = $this->_oDb->getEvents(array_merge(array('browse' => 'descriptor'), $aContent));
+                    $aReposted = $this->_getSystemData($aReposted, $aBrowseParams);
+                }
+
+                if(empty($aReposted) || !is_array($aReposted))
+                    return array();
+
+                $aResult['content'] = array_merge($aContent, $aReposted['content']);
+                $aResult['content']['parse_type'] = !empty($aReposted['content_type']) ? $aReposted['content_type'] : BX_TIMELINE_PARSE_TYPE_DEFAULT;
+                $aResult['content']['owner_id'] = $aReposted['object_owner_id'];
+                list($aResult['content']['owner_name'], $aResult['content']['owner_url']) = $oModule->getUserInfo($aReposted['object_owner_id']);
+
+                if(!empty($aReposted['sample']))
+                    $aResult['content']['sample'] = $aReposted['sample'];
+                if(!empty($aReposted['sample_wo_article']))
+                    $aResult['content']['sample'] = $aReposted['sample_wo_article'];
+
+                list($sUserName) = $oModule->getUserInfo($aEvent['object_id']);
+                $aResult['title'] = _t('_bx_timeline_txt_user_repost', $sUserName, _t($aResult['content']['sample']));
+                $aResult['description'] = _t('_bx_timeline_txt_user_reposted_user_sample', $sUserName, $aResult['content']['owner_name'], _t($aResult['content']['sample']));
+                break;
+        }
+
+        $this->_preparetDataActions($aEvent, $aResult);
+        return $aResult;
+    }
+
+    protected function _preparetDataActions(&$aEvent, &$aResult)
+    {
+        if(empty($aEvent) || !is_array($aEvent) || empty($aEvent['id']))
+            return;
+
+        $oModule = $this->getModule();
+
+        $sSystem = $this->_oConfig->getObject('view');
+        if(empty($aResult['views']) && $oModule->getViewObject($sSystem, $aEvent['id']) !== false)
+            $aResult['views'] = array(
+                'system' => $sSystem,
+                'object_id' => $aEvent['id'],
+                'count' => $aEvent['views']
+            );
+
+        $sSystem = $this->_oConfig->getObject('vote');
+        if(empty($aResult['votes']) && $oModule->getVoteObject($sSystem, $aEvent['id']) !== false)
+            $aResult['votes'] = array(
+                'system' => $sSystem,
+                'object_id' => $aEvent['id'],
+                'count' => $aEvent['votes']
+            );
+        
+        $sSystem = $this->_oConfig->getObject('reaction');
+        if(empty($aResult['reactions']) && $oModule->getReactionObject($sSystem, $aEvent['id']) !== false)
+            $aResult['reactions'] = array(
+                'system' => $sSystem,
+                'object_id' => $aEvent['id'],
+                'count' => $aEvent['rvotes']
+            );
+
+        $sSystem = $this->_oConfig->getObject('score');
+        if(empty($aResult['scores']) && $oModule->getScoreObject($sSystem, $aEvent['id']) !== false)
+            $aResult['scores'] = array(
+                'system' => $sSystem,
+                'object_id' => $aEvent['id'],
+                'score' => $aEvent['score']
+            );
+
+		$sSystem = $this->_oConfig->getObject('report');
+        if(empty($aResult['reports']) && $oModule->getReportObject($sSystem, $aEvent['id']) !== false)
+            $aResult['reports'] = array(
+                'system' => $sSystem,
+                'object_id' => $aEvent['id'],
+                'count' => $aEvent['reports']
+            );
+
+        $sSystem = $this->_oConfig->getObject('comment');
+        if(empty($aResult['comments']) && $oModule->getCmtsObject($sSystem, $aEvent['id']) !== false)
+            $aResult['comments'] = array(
+                'system' => $sSystem,
+                'object_id' => $aEvent['id'],
+                'count' => $aEvent['comments']
+            );
+    }
+
+    protected function _prepareTextForOutput($s, $iEventId = 0)
+    {
+    	$s = bx_process_output($s, BX_DATA_HTML);
+
+        $oMetatags = BxDolMetatags::getObjectInstance($this->_oConfig->getObject('metatags'));
+		$s = $oMetatags->metaParse($iEventId, $s);
+
+        return $s;
+    }
+}
+
+/** @} */

+ 22 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineUploaderHTML5Attach.php

@@ -0,0 +1,22 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineUploaderHTML5Attach extends BxBaseModTextUploaderHTML5Attach
+{
+    public function __construct ($aObject, $sStorageObject, $sUniqId, $oTemplate)
+    {
+        $this->_sModule = 'bx_timeline';
+
+        parent::__construct($aObject, $sStorageObject, $sUniqId, $oTemplate);
+    }
+}
+
+/** @} */

+ 22 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineUploaderSimpleAttach.php

@@ -0,0 +1,22 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineUploaderSimpleAttach extends BxBaseModTextUploaderSimpleAttach
+{
+    public function __construct ($aObject, $sStorageObject, $sUniqId, $oTemplate)
+    {
+        $this->_sModule = 'bx_timeline';
+
+        parent::__construct($aObject, $sStorageObject, $sUniqId, $oTemplate);
+    }
+}
+
+/** @} */

+ 20 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/classes/BxTimelineVoteLikes.php

@@ -0,0 +1,20 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+class BxTimelineVoteLikes extends BxTemplVoteLikes
+{
+    function __construct($sSystem, $iId, $iInit = 1)
+    {
+        parent::__construct($sSystem, $iId, $iInit);
+    }
+}
+
+/** @} */

+ 135 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/config.php

@@ -0,0 +1,135 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_timeline',
+    'title' => 'Timeline',
+    'note' => 'Timeline module.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+	'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/timeline/',
+    'home_uri' => 'timeline',
+
+    'db_prefix' => 'bx_timeline_',
+    'class_prefix' => 'BxTimeline',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Timeline',
+
+    /**
+     * List of page triggers.
+     */
+    'page_triggers' => array (
+        'trigger_page_profile_view_entry',
+        'trigger_page_group_view_entry',
+    ),
+
+    /**
+     * Menu triggers.
+     */
+    'menu_triggers' => array(
+    	'trigger_profile_view_submenu',
+    	'trigger_group_view_submenu',
+    ),
+
+	/**
+     * Storage objects to automatically delete files from upon module uninstallation.
+     * Note. Don't add storage objects used in transcoder objects.
+     */
+    'storages' => array(
+    	'bx_timeline_photos',
+    	'bx_timeline_videos'
+    ),
+
+    /**
+     * Transcoders.
+     */
+    'transcoders' => array(
+    	'bx_timeline_photos_preview',
+    	'bx_timeline_photos_view',
+        'bx_timeline_photos_big',
+    	'bx_timeline_videos_poster',
+    	'bx_timeline_videos_mp4',
+    	'bx_timeline_videos_mp4_hd'
+    ),
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'uninstall' => array (
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+    	'update_relations_for_all' => 1,
+    	'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable_success' => array(
+    	'process_page_triggers' => 1,
+		'process_menu_triggers' => 1,
+    	'register_transcoders' => 1,
+    	'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+    	'update_relations_for_all' => 1,
+    	'update_relations' => 1,
+    	'unregister_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable_failed' => array (
+    	'register_transcoders' => 1,
+    	'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+
+    /**
+     * Relations Section
+     */
+    'relation_handlers' => array(
+    	'on_install' => '',
+    	'on_uninstall' => 'delete_module_events',
+	    'on_enable' => 'add_handlers',
+	    'on_disable' => 'delete_handlers',
+    ),
+    'relations' => array(
+    	'bx_notifications'
+    )
+);
+
+/** @} */

+ 268 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,268 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+
+	<string name="_bx_timeline"><![CDATA[Timeline]]></string>
+	<string name="_bx_timeline_cmts"><![CDATA[Timelines' Comments]]></string>
+
+    <string name="_bx_timeline_option_enable_edit"><![CDATA[Allow user to edit his items]]></string>
+	<string name="_bx_timeline_option_enable_delete"><![CDATA[Allow Timeline owner to remove items]]></string>
+	<string name="_bx_timeline_option_enable_show_all"><![CDATA[Show all items in Public Feed including ones which were posted in personal Feeds]]></string>
+        <string name="_bx_timeline_option_enable_count_all_views"><![CDATA[Count views for all items in the Feed]]></string>
+	<string name="_bx_timeline_option_events_per_page_profile"><![CDATA[Number of items on profile page]]></string>
+	<string name="_bx_timeline_option_events_per_page_account"><![CDATA[Number of items on dashboard page]]></string>
+	<string name="_bx_timeline_option_events_per_page_home"><![CDATA[Number of items on site home page]]></string>
+	<string name="_bx_timeline_option_events_per_page"><![CDATA[Number of items per page]]></string>
+	<string name="_bx_timeline_option_rss_length"><![CDATA[The length of RSS feed]]></string>
+	<string name="_bx_timeline_option_events_hide"><![CDATA[Show events]]></string>
+	<string name="_bx_timeline_option_videos_autoplay"><![CDATA[Videos autoplay (for Timeline view only)]]></string>
+	<string name="_bx_timeline_option_videos_autoplay_off"><![CDATA[Disabled]]></string>
+	<string name="_bx_timeline_option_videos_autoplay_on_mute"><![CDATA[Enabled without sound]]></string>
+	<string name="_bx_timeline_option_videos_autoplay_on"><![CDATA[Enabled with sound]]></string>
+        <string name="_bx_timeline_option_preload_comments"><![CDATA[Number of preloaded comments (up to 7 items)]]></string>
+	<string name="_bx_timeline_option_enable_hot"><![CDATA[Enable Hot list aggregation]]></string>
+	<string name="_bx_timeline_option_hot_interval"><![CDATA[Interval of time (in hours) to get Hot events]]></string>
+        <string name="_bx_timeline_option_enable_cache_item"><![CDATA[Enable item cache]]></string>
+        <string name="_bx_timeline_option_cache_item_engine"><![CDATA[Item cache engine (other than File option may require custom server setup)]]></string>
+        <string name="_bx_timeline_option_cache_item_lifetime"><![CDATA[Item cache lifetime]]></string>
+        <string name="_bx_timeline_option_enable_cache_list"><![CDATA[Enable feed cache]]></string>
+	<string name="_bx_timeline_option_enable_editor_toolbar"><![CDATA[Enable post form editor toolbar]]></string>
+
+	<string name="_bx_timeline_form_post"><![CDATA[Post]]></string>
+	<string name="_bx_timeline_form_post_display_add"><![CDATA[Write Post]]></string>
+	<string name="_bx_timeline_form_post_display_add_public"><![CDATA[Write Public Post]]></string>
+	<string name="_bx_timeline_form_post_display_add_profile"><![CDATA[Write Profile Post]]></string>
+	<string name="_bx_timeline_form_post_display_edit"><![CDATA[Edit Post]]></string>
+	<string name="_bx_timeline_form_post_input_sys_owner_id"><![CDATA[Owner ID]]></string>
+	<string name="_bx_timeline_form_post_input_owner_id_own"><![CDATA[Your profile]]></string>
+	<string name="_bx_timeline_form_post_input_owner_id_following_group"><![CDATA[{0}]]></string>
+	<string name="_bx_timeline_form_post_input_sys_action"><![CDATA[Action]]></string>
+	<string name="_bx_timeline_form_post_input_sys_type"><![CDATA[Type]]></string>
+	<string name="_bx_timeline_form_post_input_sys_text"><![CDATA[Content]]></string>
+	<string name="_bx_timeline_form_post_input_text"><![CDATA[]]></string>
+	<string name="_bx_timeline_form_post_input_sys_object_privacy_view"><![CDATA[Visibility]]></string>
+        <string name="_bx_timeline_form_post_input_object_privacy_view"><![CDATA[Visibility]]></string>
+        <string name="_bx_timeline_form_post_input_sys_date"><![CDATA[Created at]]></string>
+        <string name="_bx_timeline_form_post_input_date"><![CDATA[Created at]]></string>
+        <string name="_bx_timeline_form_post_input_sys_date_published"><![CDATA[Publish at]]></string>
+        <string name="_bx_timeline_form_post_input_date_published"><![CDATA[Publish at]]></string>
+        <string name="_bx_timeline_form_post_input_date_published_info"><![CDATA[Leave empty to publish immediately.]]></string>
+	<string name="_bx_timeline_form_post_input_sys_link"><![CDATA[Link]]></string>
+	<string name="_bx_timeline_form_post_input_link_alt"><![CDATA[Add Link]]></string>
+	<string name="_bx_timeline_form_post_input_link_err_delete"><![CDATA[Cannot remove the link. Please report.]]></string>
+	<string name="_bx_timeline_form_post_input_sys_photo"><![CDATA[Photo]]></string>
+	<string name="_bx_timeline_form_post_input_photo"><![CDATA[]]></string>
+	<string name="_bx_timeline_form_post_input_photo_alt"><![CDATA[Add Photo]]></string>
+	<string name="_bx_timeline_form_post_input_sys_video"><![CDATA[Video]]></string>
+	<string name="_bx_timeline_form_post_input_video"><![CDATA[]]></string>
+	<string name="_bx_timeline_form_post_input_video_alt"><![CDATA[Add Video]]></string>
+	<string name="_bx_timeline_form_post_input_sys_attachments"><![CDATA[Attachments]]></string>
+	<string name="_bx_timeline_form_post_input_sys_do_submit"><![CDATA[Post]]></string>
+	<string name="_bx_timeline_form_post_input_do_submit"><![CDATA[Post]]></string>
+	<string name="_bx_timeline_form_post_input_sys_do_cancel"><![CDATA[Cancel]]></string>
+        <string name="_bx_timeline_form_post_input_do_cancel"><![CDATA[Cancel]]></string>
+
+	<string name="_bx_timeline_form_attach_link"><![CDATA[Attach Link]]></string>
+	<string name="_bx_timeline_form_attach_link_display_add"><![CDATA[Attach Link]]></string>
+	<string name="_bx_timeline_form_attach_link_input_sys_url"><![CDATA[Url]]></string>
+	<string name="_bx_timeline_form_attach_link_input_url"><![CDATA[Add Link]]></string>
+	<string name="_bx_timeline_form_attach_link_input_url_err"><![CDATA[Correct Link is essential. Please, fill in this field.]]></string>
+	<string name="_bx_timeline_form_attach_link_input_sys_do_submit"><![CDATA[Add]]></string>
+	<string name="_bx_timeline_form_attach_link_input_do_submit"><![CDATA[Add]]></string>
+	<string name="_bx_timeline_form_attach_link_input_do_cancel"><![CDATA[Close]]></string>
+
+	<string name="_bx_timeline_privacy_view"><![CDATA[View event]]></string>
+
+	<string name="_bx_timeline_acl_action_post"><![CDATA[Post]]></string>
+	<string name="_bx_timeline_acl_action_edit"><![CDATA[Edit Any Post]]></string>
+	<string name="_bx_timeline_acl_action_delete"><![CDATA[Delete Any Post]]></string>
+	<string name="_bx_timeline_acl_action_vote"><![CDATA[Vote]]></string>
+	<string name="_bx_timeline_acl_action_repost"><![CDATA[Repost]]></string>
+	<string name="_bx_timeline_acl_action_send"><![CDATA[Send]]></string>
+	<string name="_bx_timeline_acl_action_pin"><![CDATA['Pin here' Any Post]]></string>
+	<string name="_bx_timeline_acl_action_stick"><![CDATA['Pin for all' Any Post]]></string>
+	<string name="_bx_timeline_acl_action_promote"><![CDATA[Promote Any Post]]></string>
+
+	<string name="_bx_timeline_page_title_sys_view"><![CDATA[Profile Feed]]></string>
+	<string name="_bx_timeline_page_title_view"><![CDATA[Profile Feed]]></string>
+	<string name="_bx_timeline_page_title_sys_view_home"><![CDATA[Public Feed]]></string>
+    <string name="_bx_timeline_page_title_view_home"><![CDATA[Public Feed]]></string>
+    <string name="_bx_timeline_page_title_sys_view_hot"><![CDATA[Hot Feed]]></string>
+    <string name="_bx_timeline_page_title_view_hot"><![CDATA[Hot Feed]]></string>
+	<string name="_bx_timeline_page_title_sys_item"><![CDATA[Feed Item]]></string>
+	<string name="_bx_timeline_page_title_item"><![CDATA[Feed Item]]></string>
+	<string name="_bx_timeline_page_title_sys_item_brief"><![CDATA[Feed Item Preview]]></string>
+    <string name="_bx_timeline_page_title_item_brief"><![CDATA[Feed Item Preview]]></string>
+	<string name="_bx_timeline_page_title_sys_account"><![CDATA[Feed]]></string>
+	<string name="_bx_timeline_page_title_account"><![CDATA[Feed]]></string>
+  <string name="_bx_timeline_page_title_sys_manage_administration"><![CDATA[Manage All]]></string>
+  <string name="_bx_timeline_page_title_manage"><![CDATA[Manage]]></string>
+	<string name="_bx_timeline_page_block_title_system_post_profile"><![CDATA[Post to Feed]]></string>
+	<string name="_bx_timeline_page_block_title_post_profile"><![CDATA[Post to Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_profile"><![CDATA[Profile Feed (Timeline)]]></string>
+	<string name="_bx_timeline_page_block_title_view_profile"><![CDATA[Profile Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_profile_outline"><![CDATA[Profile Feed (Outline)]]></string>
+	<string name="_bx_timeline_page_block_title_view_profile_outline"><![CDATA[Profile Feed]]></string>
+	<string name="_bx_timeline_page_block_title_item"><![CDATA[Item]]></string>
+	<string name="_bx_timeline_page_block_title_item_content"><![CDATA[Content]]></string>
+	<string name="_bx_timeline_page_block_title_item_info"><![CDATA[Info]]></string>
+	<string name="_bx_timeline_page_block_title_item_comments"><![CDATA[Comments]]></string>
+	<string name="_bx_timeline_page_block_title_system_post_account"><![CDATA[Post to Feed]]></string>
+	<string name="_bx_timeline_page_block_title_post_account"><![CDATA[Post to Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_account"><![CDATA[Feed (Timeline)]]></string>
+	<string name="_bx_timeline_page_block_title_view_account"><![CDATA[Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_account_outline"><![CDATA[Feed (Outline)]]></string>
+	<string name="_bx_timeline_page_block_title_view_account_outline"><![CDATA[Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_post_home"><![CDATA[Post to Public Feed]]></string>
+	<string name="_bx_timeline_page_block_title_post_home"><![CDATA[Post to Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_home"><![CDATA[Public Feed (Timeline)]]></string>
+	<string name="_bx_timeline_page_block_title_view_home"><![CDATA[Public Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_home_outline"><![CDATA[Public Feed (Outline)]]></string>
+	<string name="_bx_timeline_page_block_title_view_home_outline"><![CDATA[Public Feed]]></string>
+	<string name="_bx_timeline_page_block_title_system_view_hot"><![CDATA[Hot Feed (Timeline)]]></string>
+    <string name="_bx_timeline_page_block_title_view_hot"><![CDATA[Hot Feed]]></string>
+    <string name="_bx_timeline_page_block_title_system_view_hot_outline"><![CDATA[Hot Feed (Outline)]]></string>
+    <string name="_bx_timeline_page_block_title_view_hot_outline"><![CDATA[Hot Feed]]></string>
+	<string name="_bx_timeline_page_block_title_browse_cmts"><![CDATA[Feeds' Comments]]></string>
+  <string name="_bx_timeline_page_block_title_system_manage_administration"><![CDATA[Manage All]]></string>
+  <string name="_bx_timeline_page_block_title_manage"><![CDATA[Manage]]></string>
+
+  <string name="_bx_timeline_menu_item_view_all"><![CDATA[All posts]]></string>
+    <string name="_bx_timeline_menu_item_view_owner"><![CDATA[Posts by {0}]]></string>
+    <string name="_bx_timeline_menu_item_view_other"><![CDATA[Posts by others]]></string>
+    <string name="_bx_timeline_menu_item_get_rss"><![CDATA[RSS]]></string>
+
+    <string name="_bx_timeline_menu_title_item_share"><![CDATA[Share Item]]></string>
+    <string name="_bx_timeline_menu_set_title_item_share"><![CDATA[Share Item]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_repost"><![CDATA[Repost]]></string>
+    <string name="_bx_timeline_menu_item_title_item_repost"><![CDATA[Repost]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_send"><![CDATA[Send]]></string>
+    <string name="_bx_timeline_menu_item_title_item_send"><![CDATA[Send to Friend]]></string>
+    <string name="_bx_timeline_menu_item_title_system_admt_timeline"><![CDATA[Timeline]]></string>
+    <string name="_bx_timeline_menu_item_title_admt_timeline"><![CDATA[Timeline]]></string>
+    
+    <string name="_bx_timeline_menu_title_item_manage"><![CDATA[Manage Item]]></string>
+    <string name="_bx_timeline_menu_set_title_item_manage"><![CDATA[Manage Item]]></string>
+	<string name="_bx_timeline_menu_item_title_system_item_pin"><![CDATA[Pin here]]></string>
+    <string name="_bx_timeline_menu_item_title_item_pin"><![CDATA[Pin here]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_unpin"><![CDATA[Unpin here]]></string>
+    <string name="_bx_timeline_menu_item_title_item_unpin"><![CDATA[Unpin here]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_stick"><![CDATA[Pin for all]]></string>
+    <string name="_bx_timeline_menu_item_title_item_stick"><![CDATA[Pin for all]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_unstick"><![CDATA[Unpin for all]]></string>
+    <string name="_bx_timeline_menu_item_title_item_unstick"><![CDATA[Unpin for all]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_promote"><![CDATA[Promote]]></string>
+    <string name="_bx_timeline_menu_item_title_item_promote"><![CDATA[Promote]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_unpromote"><![CDATA[Unpromote]]></string>
+    <string name="_bx_timeline_menu_item_title_item_unpromote"><![CDATA[Unpromote]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_edit"><![CDATA[Edit]]></string>
+    <string name="_bx_timeline_menu_item_title_item_edit"><![CDATA[Edit]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_delete"><![CDATA[Hide]]></string>
+    <string name="_bx_timeline_menu_item_title_item_delete"><![CDATA[Hide from feeds]]></string>
+
+	<string name="_bx_timeline_menu_title_item_actions"><![CDATA[Item Actions]]></string>
+    <string name="_bx_timeline_menu_set_title_item_actions"><![CDATA[Item Actions]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_comment"><![CDATA[Comment]]></string>
+    <string name="_bx_timeline_menu_item_title_item_comment"><![CDATA[]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_view"><![CDATA[View]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_vote"><![CDATA[Vote (Like)]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_score"><![CDATA[Vote (Up/Down)]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_reaction"><![CDATA[Reaction]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_share"><![CDATA[Share]]></string>
+    <string name="_bx_timeline_menu_item_title_item_share"><![CDATA[]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_report"><![CDATA[Report]]></string>
+    <string name="_bx_timeline_menu_item_title_system_item_more"><![CDATA[More Actions]]></string>
+    <string name="_bx_timeline_menu_item_title_item_more"><![CDATA[]]></string>
+
+    <string name="_bx_timeline_menu_title_post_attachments"><![CDATA[Form Attachments]]></string>
+    <string name="_bx_timeline_menu_set_title_post_attachments"><![CDATA[Form Attachments]]></string>
+    <string name="_bx_timeline_menu_item_title_system_add_emoji"><![CDATA[Add Emoji]]></string>
+    <string name="_bx_timeline_menu_item_title_add_emoji"><![CDATA[Add Emoji]]></string>
+    <string name="_bx_timeline_menu_item_title_system_add_link"><![CDATA[Add Link]]></string>
+    <string name="_bx_timeline_menu_item_title_add_link"><![CDATA[Add Link]]></string>
+    <string name="_bx_timeline_menu_item_title_system_add_photo_simple"><![CDATA[Add Photo (Simple)]]></string>
+    <string name="_bx_timeline_menu_item_title_system_add_photo_html5"><![CDATA[Add Photo (HTML5)]]></string>
+    <string name="_bx_timeline_menu_item_title_add_photo"><![CDATA[Add Photo]]></string>
+    <string name="_bx_timeline_menu_item_title_system_add_video_simple"><![CDATA[Add Video (Simple)]]></string>
+    <string name="_bx_timeline_menu_item_title_system_add_video_html5"><![CDATA[Add Video (HTML5)]]></string>
+    <string name="_bx_timeline_menu_item_title_add_video"><![CDATA[Add Video]]></string>
+    <string name="_bx_timeline_menu_item_title_system_timeline"><![CDATA[Timeline]]></string>
+    <string name="_bx_timeline_menu_item_title_timeline"><![CDATA[Timeline]]></string>
+    <string name="_bx_timeline_menu_item_title_system_create_entry"><![CDATA[Update]]></string>
+    <string name="_bx_timeline_menu_item_title_create_entry"><![CDATA[Update]]></string>
+    <string name="_bx_timeline_menu_item_title_system_view_timeline_view"><![CDATA[Timeline]]></string>
+    <string name="_bx_timeline_menu_item_title_view_timeline_view"><![CDATA[Timeline]]></string>
+
+  <string name="_bx_timeline_grid_column_title_adm_active"><![CDATA[Active]]></string>
+  <string name="_bx_timeline_grid_column_title_adm_description"><![CDATA[Event]]></string>
+  <string name="_bx_timeline_grid_column_title_adm_added"><![CDATA[Added]]></string>
+  <string name="_bx_timeline_grid_column_title_adm_author"><![CDATA[Author]]></string>
+  <string name="_bx_timeline_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+  <string name="_bx_timeline_grid_txt_account_manager"><![CDATA[Redirect to manage account.]]></string>
+  
+    <string name="_bx_timeline_alert_module_timeline_common_post"><![CDATA[Timeline (post)]]></string>
+    <string name="_bx_timeline_alert_module_timeline_common_repost"><![CDATA[Timeline (repost)]]></string>
+    <string name="_bx_timeline_alert_action_added"><![CDATA[add]]></string>
+    <string name="_bx_timeline_alert_action_post_common"><![CDATA[add post]]></string>
+    <string name="_bx_timeline_alert_action_repost"><![CDATA[repost]]></string>
+    <string name="_bx_timeline_alert_action_post_common_personal"><![CDATA[New content]]></string>
+    <string name="_bx_timeline_alert_action_post_common_follow_member"><![CDATA[New content]]></string>
+    <string name="_bx_timeline_alert_action_post_common_follow_context"><![CDATA[New content]]></string>
+    <string name="_bx_timeline_alert_action_repost_follow_member"><![CDATA[New content repost]]></string>
+    <string name="_bx_timeline_alert_action_repost_follow_context"><![CDATA[New content repost]]></string>
+
+	<string name="_bx_timeline_txt_msg_no_results"><![CDATA[Empty]]></string>
+	<string name="_bx_timeline_txt_msg_performed_action"><![CDATA[The action was successfully performed.]]></string>
+	<string name="_bx_timeline_txt_msg_posted"><![CDATA[Posted successfully.]]></string>
+  <string name="_bx_timeline_grid_action_err_delete"><![CDATA[Cannot delete the selected timeline events(s).]]></string>
+	<string name="_bx_timeline_txt_err_cannot_perform_action"><![CDATA[Cannot perform action. Please report.]]></string>
+	<string name="_bx_timeline_txt_err_empty_post"><![CDATA[The post is empty.]]></string>
+
+        <string name="_bx_timeline_txt_to"><![CDATA[to]]></string>
+	<string name="_bx_timeline_txt_load_more"><![CDATA[Load More]]></string>
+	<string name="_bx_timeline_txt_or_jump_to"><![CDATA[... or jump to:]]></string>
+	<string name="_bx_timeline_txt_jump_to_n_year"><![CDATA[Jump to {0} year]]></string>
+	<string name="_bx_timeline_txt_jump_to_recent"><![CDATA[Jump to recent posts]]></string>
+        <string name="_bx_timeline_txt_status_deleted"><![CDATA[Deleted]]></string>
+        <string name="_bx_timeline_txt_hot"><![CDATA[Hot post]]></string>
+	<string name="_bx_timeline_txt_pinned"><![CDATA[Pinned post]]></string>
+        <string name="_bx_timeline_txt_sticked"><![CDATA[Pinned for all post]]></string>
+	<string name="_bx_timeline_txt_promoted"><![CDATA[Promoted]]></string>
+        <string name="_bx_timeline_txt_note_scheduled_awaiting"><![CDATA[Update publishing date is {0}]]></string>
+        <string name="_bx_timeline_txt_note_processing_awaiting"><![CDATA[Update will be published as soon as video is converted]]></string>
+        <string name="_bx_timeline_txt_note_processing_failed"><![CDATA[Update isn't published because video conversion failed, edit video to fix the issue.]]></string>
+	<string name="_bx_timeline_txt_rss_caption"><![CDATA[{0}'s timeline]]></string>
+	<string name="_bx_timeline_txt_added_sample"><![CDATA[added {0}]]></string>
+	<string name="_bx_timeline_txt_user_added_sample"><![CDATA[{0} added {1}]]></string>
+	<string name="_bx_timeline_txt_user_repost"><![CDATA[{0}'s repost]]></string>
+	<string name="_bx_timeline_txt_user_reposted_user_sample"><![CDATA[{0} reposted {1}'s {2}]]></string>
+	<string name="_bx_timeline_txt_sample"><![CDATA[post]]></string>
+	<string name="_bx_timeline_txt_sample_with_article"><![CDATA[a post]]></string>
+	<string name="_bx_timeline_txt_sample_ext"><![CDATA[timeline post]]></string>
+	<string name="_bx_timeline_txt_sample_comment_single"><![CDATA[comment to timeline post]]></string>
+    <string name="_bx_timeline_txt_sample_vote_single"><![CDATA[vote to timeline post]]></string>
+    <string name="_bx_timeline_txt_sample_score_up_single"><![CDATA[score up vote to timeline post]]></string>
+    <string name="_bx_timeline_txt_sample_score_down_single"><![CDATA[score down vote to timeline post]]></string>
+    <string name="_bx_timeline_txt_sample_with_link"><![CDATA[with link]]></string>
+    <string name="_bx_timeline_txt_sample_with_image"><![CDATA[with image]]></string>
+    <string name="_bx_timeline_txt_sample_with_video"><![CDATA[with video]]></string>
+    <string name="_bx_timeline_txt_sample_with_media"><![CDATA[with media]]></string>
+    <string name="_bx_timeline_txt_today"><![CDATA[Today]]></string>
+    <string name="_bx_timeline_txt_some_text_here"><![CDATA[Share your thoughts, location, photos or video]]></string>
+    <string name="_bx_timeline_txt_show"><![CDATA[Show]]></string>
+    <string name="_bx_timeline_txt_new_content"><![CDATA[New content]]></string>
+
+    <string name="_bx_timeline_txt_do_repost"><![CDATA[Repost]]></string>
+    <string name="_bx_timeline_txt_reposted"><![CDATA[Reposted {0}'s {1}.]]></string>
+    <string name="_bx_timeline_txt_reposted_by"><![CDATA[Reposted by]]></string>
+    <string name="_bx_timeline_txt_err_cannot_repost"><![CDATA[Cannot repost. Please report.]]></string>
+    <string name="_bx_timeline_txt_err_already_reposted"><![CDATA[You already reposted the item.]]></string>
+    <string name="_bx_timeline_txt_msg_success_repost"><![CDATA[The item was successfully reposted.]]></string>
+    <string name="_bx_timeline_txt_object_reposted"><![CDATA[<b class="bx-ntfs-content-profile">{owner_name}</b> reposted a {entry_sample} <b class="bx-ntfs-content-entry">{entry_caption}</b>]]></string>
+
+    <!-- EMAIL TEMPLATES -->
+    <string name="_bx_timeline_et_txt_name_send"><![CDATA[Send to Friend.]]></string>
+    <string name="_bx_timeline_et_txt_subject_send"><![CDATA[It may be interesting for you.]]></string>
+    <string name="_bx_timeline_et_txt_body_send"><![CDATA[
+<p>Hello.</p>
+<p>Take a look at <a href="{ViewLink}">this post</a>, it may be interesting for you.</p>]]></string>
+</resources>

+ 56 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/disable.sql

@@ -0,0 +1,56 @@
+-- PAGES & BLOCKS
+DELETE FROM `sys_objects_page` WHERE `module` = 'bx_timeline';
+DELETE FROM `sys_pages_blocks` WHERE `module` = 'bx_timeline' OR `object` IN('bx_timeline_view', 'bx_timeline_view_home', 'bx_timeline_item', 'bx_photos_item_brief');
+
+
+-- MENU
+DELETE FROM `sys_objects_menu` WHERE `module` = 'bx_timeline';
+DELETE FROM `sys_menu_sets` WHERE `module` = 'bx_timeline';
+DELETE FROM `sys_menu_items` WHERE `module` = 'bx_timeline' OR `set_name` IN('bx_timeline_menu_item_share', 'bx_timeline_menu_item_manage', 'bx_timeline_menu_item_actions', 'bx_timeline_menu_item_meta', 'bx_timeline_menu_post_attachments');
+
+
+-- SETTINGS
+SET @iTypeId = (SELECT `ID` FROM `sys_options_types` WHERE `name` = 'bx_timeline' LIMIT 1);
+SET @iCategId = (SELECT `ID` FROM `sys_options_categories` WHERE `type_id` = @iTypeId LIMIT 1);
+DELETE FROM `sys_options` WHERE `category_id` = @iCategId;
+DELETE FROM `sys_options_categories` WHERE `type_id` = @iTypeId;
+DELETE FROM `sys_options_types` WHERE `id` = @iTypeId;
+
+
+-- PRIVACY 
+DELETE FROM `sys_objects_privacy` WHERE `module` = 'bx_timeline';
+
+
+-- ACL
+DELETE `sys_acl_actions`, `sys_acl_matrix` FROM `sys_acl_actions`, `sys_acl_matrix` WHERE `sys_acl_matrix`.`IDAction` = `sys_acl_actions`.`ID` AND `sys_acl_actions`.`Module` = 'bx_timeline';
+DELETE FROM `sys_acl_actions` WHERE `Module` = 'bx_timeline';
+
+
+-- ALERTS
+SET @iHandlerId = (SELECT `id` FROM `sys_alerts_handlers` WHERE `name` = 'bx_timeline' LIMIT 1);
+DELETE FROM `sys_alerts` WHERE `handler_id` = @iHandlerId;
+DELETE FROM `sys_alerts_handlers` WHERE `id` = @iHandlerId LIMIT 1;
+
+
+-- SEARCH
+DELETE FROM `sys_objects_search` WHERE `ObjectName` IN ('bx_timeline', 'bx_timeline_cmts');
+
+-- GRIDS
+DELETE FROM `sys_objects_grid` WHERE `object` IN ('bx_timeline_administration');
+DELETE FROM `sys_grid_fields` WHERE `object` IN ('bx_timeline_administration');
+DELETE FROM `sys_grid_actions` WHERE `object` IN ('bx_timeline_administration');
+
+-- METATAGS
+DELETE FROM `sys_objects_metatags` WHERE `object` = 'bx_timeline';
+
+
+-- EMAIL TEMPLATES
+DELETE FROM `sys_email_templates` WHERE `Module` = 'bx_timeline';
+
+
+-- CRON
+DELETE FROM `sys_cron_jobs` WHERE `name` LIKE 'bx_timeline%';
+
+
+-- PRELOADER
+DELETE FROM `sys_preloader` WHERE `module` = 'bx_timeline';

+ 343 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,343 @@
+-- PAGES & BLOCKS
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_timeline_view', '_bx_timeline_page_title_sys_view', '_bx_timeline_page_title_view', 'bx_timeline', 5, 2147483647, 1, 'timeline-view', 'page.php?i=timeline-view', '', '', '', 0, 1, 0, 'BxTimelinePageView', 'modules/boonex/timeline/classes/BxTimelinePageView.php'),
+('bx_timeline_view_home', '_bx_timeline_page_title_sys_view_home', '_bx_timeline_page_title_view_home', 'bx_timeline', 5, 2147483647, 1, 'timeline-view-home', 'page.php?i=timeline-view-home', '', '', '', 0, 1, 0, '', ''),
+('bx_timeline_view_hot', '_bx_timeline_page_title_sys_view_hot', '_bx_timeline_page_title_view_hot', 'bx_timeline', 5, 2147483647, 1, 'timeline-view-hot', 'page.php?i=timeline-view-hot', '', '', '', 0, 1, 0, '', ''),
+
+('bx_timeline_item', '_bx_timeline_page_title_sys_item', '_bx_timeline_page_title_item', 'bx_timeline', 5, 2147483647, 1, 'item', 'page.php?i=item', '', '', '', 0, 1, 0, '', ''),
+('bx_timeline_item_brief', '_bx_timeline_page_title_sys_item_brief', '_bx_timeline_page_title_item_brief', 'bx_timeline', 2, 2147483647, 1, 'item-quick', 'page.php?i=item-quick', '', '', '', 0, 1, 0, '', '');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('bx_timeline_view', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_post_profile', '_bx_timeline_page_block_title_post_profile', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:14:"get_block_post";}', 0, 0, 1, 1),
+('bx_timeline_view', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_view_profile', '_bx_timeline_page_block_title_view_profile', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:14:"get_block_view";}', 0, 0, 1, 2),
+('bx_timeline_view', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_view_profile_outline', '_bx_timeline_page_block_title_view_profile_outline', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_view_outline";}', 0, 0, 0, 3),
+
+('bx_timeline_view_home', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_post_home', '_bx_timeline_page_block_title_post_home', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:19:"get_block_post_home";}', 0, 0, 1, 1),
+('bx_timeline_view_home', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_view_home', '_bx_timeline_page_block_title_view_home', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:19:"get_block_view_home";}', 0, 0, 0, 2),
+('bx_timeline_view_home', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_view_home_outline', '_bx_timeline_page_block_title_view_home_outline', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:27:"get_block_view_home_outline";}', 0, 0, 1, 3),
+
+('bx_timeline_view_hot', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_view_hot', '_bx_timeline_page_block_title_view_hot', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:18:"get_block_view_hot";}', 0, 1, 0, 1),
+('bx_timeline_view_hot', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_view_hot_outline', '_bx_timeline_page_block_title_view_hot_outline', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:26:"get_block_view_hot_outline";}', 0, 1, 1, 2),
+
+('bx_timeline_item', 1, 'bx_timeline', '', '_bx_timeline_page_block_title_item', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:14:"get_block_item";}', 0, 0, 1, 1),
+('bx_timeline_item', 1, 'bx_timeline', '', '_bx_timeline_page_block_title_item_comments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:23:"get_block_item_comments";}', 0, 0, 1, 2),
+
+('bx_timeline_item_brief', 1, 'bx_timeline', '', '_bx_timeline_page_block_title_item_content', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_item_content";}', 0, 0, 1, 1),
+('bx_timeline_item_brief', 2, 'bx_timeline', '', '_bx_timeline_page_block_title_item_info', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:19:"get_block_item_info";}', 0, 0, 1, 1),
+('bx_timeline_item_brief', 2, 'bx_timeline', '', '_bx_timeline_page_block_title_item_comments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:23:"get_block_item_comments";}', 0, 0, 1, 2);
+
+
+-- PAGES: add page block on dashboard
+SET @iPBCellDashboard = 2;
+SET @iPBOrderDashboard = 1; --(SELECT IFNULL(MAX(`order`), 0) FROM `sys_pages_blocks` WHERE `object` = 'sys_dashboard' AND `cell_id` = @iPBCellDashboard LIMIT 1);
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('sys_dashboard', @iPBCellDashboard, 'bx_timeline', '_bx_timeline_page_block_title_system_post_account', '_bx_timeline_page_block_title_post_account', 11, 2147483644, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_post_account";}', 0, 1, 1, @iPBOrderDashboard),
+('sys_dashboard', @iPBCellDashboard, 'bx_timeline', '_bx_timeline_page_block_title_system_view_account', '_bx_timeline_page_block_title_view_account', 0, 2147483644, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_view_account";}', 0, 1, 1, @iPBOrderDashboard + 1),
+('sys_dashboard', @iPBCellDashboard, 'bx_timeline', '_bx_timeline_page_block_title_system_view_account_outline', '_bx_timeline_page_block_title_view_account_outline', 0, 2147483644, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:30:"get_block_view_account_outline";}', 0, 1, 0, @iPBOrderDashboard + 1);
+
+-- PAGES: add page block on home
+SET @iPBCellHome = 1;
+SET @iPBOrderHome = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_pages_blocks` WHERE `object` = 'sys_home' AND `cell_id` = @iPBCellHome ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('sys_home', @iPBCellHome, 'bx_timeline', '_bx_timeline_page_block_title_system_post_home', '_bx_timeline_page_block_title_post_home', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:19:"get_block_post_home";}', 0, 1, 1, @iPBOrderHome + 1),
+('sys_home', @iPBCellHome, 'bx_timeline', '_bx_timeline_page_block_title_system_view_home', '_bx_timeline_page_block_title_view_home', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:19:"get_block_view_home";}', 0, 1, 0, @iPBOrderHome + 2),
+('sys_home', @iPBCellHome, 'bx_timeline', '_bx_timeline_page_block_title_system_view_home_outline', '_bx_timeline_page_block_title_view_home_outline', 0, 2147483647, 'service', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:27:"get_block_view_home_outline";}', 0, 1, 1, @iPBOrderHome + 3);
+
+-- PAGES: add page block to profiles modules (trigger* page objects are processed separately upon modules enable/disable)
+SET @iPBCellProfile = 2;
+SET @iPBCellGroup = 4;
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('trigger_page_profile_view_entry', @iPBCellProfile, 'bx_timeline', '_bx_timeline_page_block_title_system_post_profile', '_bx_timeline_page_block_title_post_profile', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_post_profile";s:6:"params";a:1:{i:0;s:6:"{type}";}}', 0, 0, 1, 0),
+('trigger_page_profile_view_entry', @iPBCellProfile, 'bx_timeline', '_bx_timeline_page_block_title_system_view_profile', '_bx_timeline_page_block_title_view_profile', 0, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_view_profile";s:6:"params";a:1:{i:0;s:6:"{type}";}}', 0, 0, 1, 0),
+('trigger_page_profile_view_entry', @iPBCellProfile, 'bx_timeline', '_bx_timeline_page_block_title_system_view_profile_outline', '_bx_timeline_page_block_title_view_profile_outline', 0, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:30:"get_block_view_profile_outline";s:6:"params";a:1:{i:0;s:6:"{type}";}}', 0, 0, 0, 0),
+
+('trigger_page_group_view_entry', @iPBCellGroup, 'bx_timeline', '_bx_timeline_page_block_title_system_post_profile', '_bx_timeline_page_block_title_post_profile', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_post_profile";s:6:"params";a:1:{i:0;s:6:"{type}";}}', 0, 0, 1, 0),
+('trigger_page_group_view_entry', @iPBCellGroup, 'bx_timeline', '_bx_timeline_page_block_title_system_view_profile', '_bx_timeline_page_block_title_view_profile', 0, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:22:"get_block_view_profile";s:6:"params";a:1:{i:0;s:6:"{type}";}}', 0, 0, 1, 0),
+('trigger_page_group_view_entry', @iPBCellGroup, 'bx_timeline', '_bx_timeline_page_block_title_system_view_profile_outline', '_bx_timeline_page_block_title_view_profile_outline', 0, 2147483647, 'service', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:30:"get_block_view_profile_outline";s:6:"params";a:1:{i:0;s:6:"{type}";}}', 0, 0, 0, 0);
+
+-- PAGE: module manage all
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_timeline_administration', '_bx_timeline_page_title_sys_manage_administration', '_bx_timeline_page_title_manage', 'bx_timeline', 5, 192, 1, 'timeline-administration', 'page.php?i=timeline-administration', '', '', '', 0, 1, 0, 'BxTimelinePageBrowse', 'modules/boonex/timeline/classes/BxTimelinePageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_timeline_administration', 1, 'bx_timeline', '_bx_timeline_page_block_title_system_manage_administration', '_bx_timeline_page_block_title_manage', 11, 192, 'service', 'a:3:{s:6:\"module\";s:11:\"bx_timeline\";s:6:\"method\";s:12:\"manage_tools\";s:6:\"params\";a:1:{i:0;s:14:\"administration\";}}', 0, 1, 0);
+
+
+-- MENU: Item Share (Repost, Send to Friend, etc)
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_timeline_menu_item_share', '_bx_timeline_menu_title_item_share', 'bx_timeline_menu_item_share', 'bx_timeline', 6, 0, 1, 'BxTimelineMenuItemShare', 'modules/boonex/timeline/classes/BxTimelineMenuItemShare.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_timeline_menu_item_share', 'bx_timeline', '_bx_timeline_menu_set_title_item_share', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
+('bx_timeline_menu_item_share', 'bx_timeline', 'item-repost', '_bx_timeline_menu_item_title_system_item_repost', '_bx_timeline_menu_item_title_item_repost', 'javascript:void(0)', 'javascript:{js_onclick_repost}', '_self', 'redo', '', 2147483647, 1, 0, 1),
+('bx_timeline_menu_item_share', 'bx_timeline', 'item-send', '_bx_timeline_menu_item_title_system_item_send', '_bx_timeline_menu_item_title_item_send', 'page.php?i=start-convo&et={et_send}', '', '_self', 'envelope', '', 2147483647, 1, 0, 2);
+
+-- MENU: Item Manage (Pin, Delete, etc)
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_timeline_menu_item_manage', '_bx_timeline_menu_title_item_manage', 'bx_timeline_menu_item_manage', 'bx_timeline', 20, 0, 1, 'BxTimelineMenuItemManage', 'modules/boonex/timeline/classes/BxTimelineMenuItemManage.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_timeline_menu_item_manage', 'bx_timeline', '_bx_timeline_menu_set_title_item_manage', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-pin', '_bx_timeline_menu_item_title_system_item_pin', '_bx_timeline_menu_item_title_item_pin', 'javascript:void(0)', 'javascript:{js_object_view}.pinPost(this, {content_id}, 1)', '_self', 'thumbtack', '', 2147483647, 1, 0, 0),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-unpin', '_bx_timeline_menu_item_title_system_item_unpin', '_bx_timeline_menu_item_title_item_unpin', 'javascript:void(0)', 'javascript:{js_object_view}.pinPost(this, {content_id}, 0)', '_self', 'thumbtack', '', 2147483647, 1, 0, 1),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-stick', '_bx_timeline_menu_item_title_system_item_stick', '_bx_timeline_menu_item_title_item_stick', 'javascript:void(0)', 'javascript:{js_object_view}.stickPost(this, {content_id}, 1)', '_self', 'thumbtack', '', 2147483647, 1, 0, 2),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-unstick', '_bx_timeline_menu_item_title_system_item_unstick', '_bx_timeline_menu_item_title_item_unstick', 'javascript:void(0)', 'javascript:{js_object_view}.stickPost(this, {content_id}, 0)', '_self', 'thumbtack', '', 2147483647, 1, 0, 3),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-promote', '_bx_timeline_menu_item_title_system_item_promote', '_bx_timeline_menu_item_title_item_promote', 'javascript:void(0)', 'javascript:{js_object_view}.promotePost(this, {content_id}, 1)', '_self', 'certificate ', '', 2147483647, 1, 0, 4),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-unpromote', '_bx_timeline_menu_item_title_system_item_unpromote', '_bx_timeline_menu_item_title_item_unpromote', 'javascript:void(0)', 'javascript:{js_object_view}.promotePost(this, {content_id}, 0)', '_self', 'certificate', '', 2147483647, 1, 0, 5),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-report', '_bx_timeline_menu_item_title_system_item_report', '', 'javascript:void(0)', '', '', '', '', 2147483647, 1, 0, 6),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-edit', '_bx_timeline_menu_item_title_system_item_edit', '_bx_timeline_menu_item_title_item_edit', 'javascript:void(0)', 'javascript:{js_object_view}.editPost(this, {content_id})', '_self', 'pencil-alt', '', 2147483647, 1, 0, 7),
+('bx_timeline_menu_item_manage', 'bx_timeline', 'item-delete', '_bx_timeline_menu_item_title_system_item_delete', '_bx_timeline_menu_item_title_item_delete', 'javascript:void(0)', 'javascript:{js_object_view}.deletePost(this, {content_id})', '_self', 'remove', '', 2147483647, 1, 0, 8);
+
+-- MENU: Item Actions (Comment, Vote, Share, Report, etc)
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_timeline_menu_item_actions', '_bx_timeline_menu_title_item_actions', 'bx_timeline_menu_item_actions', 'bx_timeline', 15, 0, 1, 'BxTimelineMenuItemActions', 'modules/boonex/timeline/classes/BxTimelineMenuItemActions.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_timeline_menu_item_actions', 'bx_timeline', '_bx_timeline_menu_set_title_item_actions', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-view', '_bx_timeline_menu_item_title_system_item_view', '', 'javascript:void(0)', '', '', '', '', '', 0, 2147483647, 0, 0, 1, 0),
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-comment', '_bx_timeline_menu_item_title_system_item_comment', '_bx_timeline_menu_item_title_item_comment', 'javascript:void(0)', 'javascript:{comment_onclick}', '_self', 'comment', 'a:3:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:27:"get_menu_item_addon_comment";s:6:"params";a:3:{i:0;s:16:"{comment_system}";i:1;s:16:"{comment_object}";i:2;a:3:{s:4:"name";s:6:"{name}";s:4:"view";s:6:"{view}";s:4:"type";s:6:"{type}";}}}', '', 0, 2147483647, 1, 0, 1, 10),
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-vote', '_bx_timeline_menu_item_title_system_item_vote', '', 'javascript:void(0)', '', '', '', '', '', 0, 2147483647, 0, 0, 1, 20),
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-reaction', '_bx_timeline_menu_item_title_system_item_reaction', '', 'javascript:void(0)', '', '', '', '', '', 0, 2147483647, 1, 0, 1, 30),
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-score', '_bx_timeline_menu_item_title_system_item_score', '', 'javascript:void(0)', '', '', '', '', '', 0, 2147483647, 0, 0, 1, 40),
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-share', '_bx_timeline_menu_item_title_system_item_share', '_bx_timeline_menu_item_title_item_share', 'javascript:void(0)', 'bx_menu_popup(''bx_timeline_menu_item_share'', this, {''id'':''bx_timeline_menu_item_share_{content_id}''}, {content_id:{content_id}, name:''{name}'', view:''{view}'', type:''{type}''});', '', 'share-alt', '', 'bx_timeline_menu_item_share', 1, 2147483647, 1, 0, 1, 50),
+('bx_timeline_menu_item_actions', 'bx_timeline', 'item-more', '_bx_timeline_menu_item_title_system_item_more', '_bx_timeline_menu_item_title_item_more', 'javascript:void(0)', 'bx_menu_popup(''bx_timeline_menu_item_manage'', this, {''id'':''bx_timeline_menu_item_manage_{content_id}''}, {content_id:{content_id}, name:''{name}'', view:''{view}'', type:''{type}''});', '', 'ellipsis-h', '', 'bx_timeline_menu_item_manage', 1, 2147483647, 1, 0, 1, 60);
+
+-- MENU: Item Meta Info
+INSERT INTO `sys_objects_menu` (`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_menu_item_meta', '_sys_menu_title_snippet_meta', 'bx_timeline_menu_item_meta', 'bx_timeline', 15, 0, 1, 'BxTimelineMenuSnippetMeta', 'modules/boonex/timeline/classes/BxTimelineMenuSnippetMeta.php');
+
+INSERT INTO `sys_menu_sets` (`set_name`, `module`, `title`, `deletable`) VALUES
+('bx_timeline_menu_item_meta', 'bx_timeline', '_sys_menu_set_title_snippet_meta', 0);
+
+-- comment meta info menu
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
+('bx_timeline_menu_item_meta', 'bx_timeline', 'date', '_sys_menu_item_title_system_sm_date', '_sys_menu_item_title_sm_date', '', '', '', '', '', '', 0, 2147483647, 1, 0, 1, 1),
+('bx_timeline_menu_item_meta', 'bx_timeline', 'membership', '_sys_menu_item_title_system_sm_membership', '_sys_menu_item_title_sm_membership', '', '', '', '', '', '', 0, 2147483647, 0, 0, 1, 2);
+
+-- MENU: Post form attachments (Link, Photo, Video)
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_timeline_menu_post_attachments', '_bx_timeline_menu_title_post_attachments', 'bx_timeline_menu_post_attachments', 'bx_timeline', 23, 0, 1, '', '');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_timeline_menu_post_attachments', 'bx_timeline', '_bx_timeline_menu_set_title_post_attachments', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
+('bx_timeline_menu_post_attachments', 'bx_timeline', 'add-emoji', '_bx_timeline_menu_item_title_system_add_emoji', '_bx_timeline_menu_item_title_add_emoji', 'javascript:void(0)', '', '_self', 'far smile', '', '', 2147483647, 1, 0, 1, 0),
+('bx_timeline_menu_post_attachments', 'bx_timeline', 'add-link', '_bx_timeline_menu_item_title_system_add_link', '_bx_timeline_menu_item_title_add_link', 'javascript:void(0)', 'javascript:{js_object}.showAttachLink(this);', '_self', 'link', '', '', 2147483647, 1, 0, 1, 1),
+('bx_timeline_menu_post_attachments', 'bx_timeline', 'add-photo-simple', '_bx_timeline_menu_item_title_system_add_photo_simple', '_bx_timeline_menu_item_title_add_photo', 'javascript:void(0)', 'javascript:{js_object_uploader_simple_photo}.showUploaderForm();', '_self', 'camera', '', '', 2147483647, 0, 0, 1, 2),
+('bx_timeline_menu_post_attachments', 'bx_timeline', 'add-photo-html5', '_bx_timeline_menu_item_title_system_add_photo_html5', '_bx_timeline_menu_item_title_add_photo', 'javascript:void(0)', 'javascript:{js_object_uploader_html5_photo}.showUploaderForm();', '_self', 'camera', '', '', 2147483647, 1, 0, 1, 3),
+('bx_timeline_menu_post_attachments', 'bx_timeline', 'add-video-simple', '_bx_timeline_menu_item_title_system_add_video_simple', '_bx_timeline_menu_item_title_add_video', 'javascript:void(0)', 'javascript:{js_object_uploader_simple_video}.showUploaderForm();', '_self', 'video', '', '', 2147483647, 0, 0, 1, 4),
+('bx_timeline_menu_post_attachments', 'bx_timeline', 'add-video-html5', '_bx_timeline_menu_item_title_system_add_video_html5', '_bx_timeline_menu_item_title_add_video', 'javascript:void(0)', 'javascript:{js_object_uploader_html5_video}.showUploaderForm();', '_self', 'video', '', '', 2147483647, 1, 0, 1, 5);
+
+-- MENU: add to "add content" menu
+SET @iAddMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_add_content_links' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_add_content_links', 'bx_timeline', 'create-item', '_bx_timeline_menu_item_title_system_create_entry', '_bx_timeline_menu_item_title_create_entry', 'page.php?i=timeline-view', '', '', 'far clock col-green1', '', 2147483647, 1, 1, IFNULL(@iAddMenuOrder, 0) + 1);
+
+-- MENU: add menu item to profiles modules (trigger* menu sets are processed separately upon modules enable/disable)
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('trigger_profile_view_submenu', 'bx_timeline', 'timeline-view', '_bx_timeline_menu_item_title_system_view_timeline_view', '_bx_timeline_menu_item_title_view_timeline_view', 'page.php?i=timeline-view&profile_id={profile_id}', '', '', 'far clock col-green1', '', 2147483647, 1, 0, 0),
+('trigger_group_view_submenu', 'bx_timeline', 'timeline-view', '_bx_timeline_menu_item_title_system_view_timeline_view', '_bx_timeline_menu_item_title_view_timeline_view', 'page.php?i=timeline-view&profile_id={profile_id}', '', '', 'far clock col-green1', '', 2147483647, 1, 0, 0);
+
+-- MENU: dashboard manage tools
+SET @iManageMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard_manage_tools' LIMIT 1);
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_account_dashboard_manage_tools', 'bx_timeline', 'timeline-administration', '_bx_timeline_menu_item_title_system_admt_timeline', '_bx_timeline_menu_item_title_admt_timeline', 'page.php?i=timeline-administration', '', '_self', 'clock', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:27:"get_menu_addon_manage_tools";}', '', 192, 1, 0, @iManageMenuOrder + 1);
+
+-- SETTINGS
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types`(`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_timeline', '_bx_timeline', 'bx_timeline@modules/boonex/timeline/|std-icon.svg', IF(ISNULL(@iTypeOrder), 1, @iTypeOrder + 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order`)
+VALUES (@iTypeId, 'bx_timeline', '_bx_timeline', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `check`, `check_params`, `check_error`, `extra`, `order`) VALUES
+-- View/Browse related settings
+('bx_timeline_enable_edit', 'on', @iCategId, '_bx_timeline_option_enable_edit', 'checkbox', '', '', '', '', 0),
+('bx_timeline_enable_delete', 'on', @iCategId, '_bx_timeline_option_enable_delete', 'checkbox', '', '', '', '', 1),
+('bx_timeline_enable_show_all', '', @iCategId, '_bx_timeline_option_enable_show_all', 'checkbox', '', '', '', '', 5),
+('bx_timeline_enable_count_all_views', '', @iCategId, '_bx_timeline_option_enable_count_all_views', 'checkbox', '', '', '', '', 6),
+('bx_timeline_events_per_page_profile', '12', @iCategId, '_bx_timeline_option_events_per_page_profile', 'digit', '', '', '', '', 10),
+('bx_timeline_events_per_page_account', '12', @iCategId, '_bx_timeline_option_events_per_page_account', 'digit', '', '', '', '', 11),
+('bx_timeline_events_per_page_home', '24', @iCategId, '_bx_timeline_option_events_per_page_home', 'digit', '', '', '', '', 12),
+('bx_timeline_events_per_page', '24', @iCategId, '_bx_timeline_option_events_per_page', 'digit', '', '', '', '', 13),
+('bx_timeline_rss_length', '5', @iCategId, '_bx_timeline_option_rss_length', 'digit', '', '', '', '', 20),
+('bx_timeline_events_hide', '', @iCategId, '_bx_timeline_option_events_hide', 'rlist', '', '', '', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:21:"get_actions_checklist";}', 30),
+('bx_timeline_videos_autoplay', 'off', @iCategId, '_bx_timeline_option_videos_autoplay', 'select', '', '', '', 'a:2:{s:6:"module";s:11:"bx_timeline";s:6:"method";s:27:"get_options_videos_autoplay";}', 50),
+('bx_timeline_preload_comments', '0', @iCategId, '_bx_timeline_option_preload_comments', 'digit', '', '', '', '', 51),
+('bx_timeline_enable_hot', '', @iCategId, '_bx_timeline_option_enable_hot', 'checkbox', '', '', '', '', 60),
+('bx_timeline_hot_interval', '48', @iCategId, '_bx_timeline_option_hot_interval', 'digit', '', '', '', '', 61),
+('bx_timeline_enable_cache_item', 'on', @iCategId, '_bx_timeline_option_enable_cache_item', 'checkbox', '', '', '', '', 70),
+('bx_timeline_cache_item_engine', 'File', @iCategId, '_bx_timeline_option_cache_item_engine', 'select', '', '', '', 'File,Memcache,APC,XCache', 71),
+('bx_timeline_cache_item_lifetime', '604800', @iCategId, '_bx_timeline_option_cache_item_lifetime', 'digit', '', '', '', '', 72),
+('bx_timeline_enable_cache_list', 'on', @iCategId, '_bx_timeline_option_enable_cache_list', 'checkbox', '', '', '', '', 73),
+
+-- Post related settings
+('bx_timeline_enable_editor_toolbar', '', @iCategId, '_bx_timeline_option_enable_editor_toolbar', 'checkbox', '', '', '', '', 100);
+
+
+-- PRIVACY 
+INSERT INTO `sys_objects_privacy` (`object`, `module`, `action`, `title`, `default_group`, `table`, `table_field_id`, `table_field_author`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_privacy_view', 'bx_timeline', 'view', '_bx_timeline_privacy_view', '3', 'bx_timeline_events', 'id', '', 'BxTimelinePrivacy', 'modules/boonex/timeline/classes/BxTimelinePrivacy.php');
+
+
+-- ACL
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'post', NULL, '_bx_timeline_acl_action_post', '', 1, 3);
+SET @iIdActionPost = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'edit', NULL, '_bx_timeline_acl_action_edit', '', 1, 3);
+SET @iIdActionEdit = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'delete', NULL, '_bx_timeline_acl_action_delete', '', 1, 3);
+SET @iIdActionDelete = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'vote', NULL, '_bx_timeline_acl_action_vote', '', 1, 0);
+SET @iIdActionVote = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'repost', NULL, '_bx_timeline_acl_action_repost', '', 1, 3);
+SET @iIdActionRepost = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'send', NULL, '_bx_timeline_acl_action_send', '', 1, 3);
+SET @iIdActionSend = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'pin', NULL, '_bx_timeline_acl_action_pin', '', 1, 3);
+SET @iIdActionPin = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'stick', NULL, '_bx_timeline_acl_action_stick', '', 1, 3);
+SET @iIdActionStick = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_timeline', 'promote', NULL, '_bx_timeline_acl_action_promote', '', 1, 3);
+SET @iIdActionPromote = LAST_INSERT_ID();
+
+SET @iUnauthenticated = 1;
+SET @iAccount = 2;
+SET @iStandard = 3;
+SET @iUnconfirmed = 4;
+SET @iPending = 5;
+SET @iSuspended = 6;
+SET @iModerator = 7;
+SET @iAdministrator = 8;
+SET @iPremium = 9;
+
+INSERT INTO `sys_acl_matrix` (`IDLevel`, `IDAction`) VALUES
+
+-- post
+(@iStandard, @iIdActionPost),
+(@iModerator, @iIdActionPost),
+(@iAdministrator, @iIdActionPost),
+(@iPremium, @iIdActionPost),
+
+-- edit any post
+(@iModerator, @iIdActionEdit),
+(@iAdministrator, @iIdActionEdit),
+
+-- delete any post
+(@iModerator, @iIdActionDelete),
+(@iAdministrator, @iIdActionDelete),
+
+-- vote
+(@iStandard, @iIdActionVote),
+(@iModerator, @iIdActionVote),
+(@iAdministrator, @iIdActionVote),
+(@iPremium, @iIdActionVote),
+
+-- repost
+(@iStandard, @iIdActionRepost),
+(@iModerator, @iIdActionRepost),
+(@iAdministrator, @iIdActionRepost),
+(@iPremium, @iIdActionRepost),
+
+-- send
+(@iStandard, @iIdActionSend),
+(@iModerator, @iIdActionSend),
+(@iAdministrator, @iIdActionSend),
+(@iPremium, @iIdActionSend),
+
+-- pin any post
+(@iModerator, @iIdActionPin),
+(@iAdministrator, @iIdActionPin),
+
+-- stick any post
+(@iModerator, @iIdActionStick),
+(@iAdministrator, @iIdActionStick),
+
+-- promote any post
+(@iModerator, @iIdActionPromote),
+(@iAdministrator, @iIdActionPromote);
+
+
+-- ALERTS
+INSERT INTO `sys_alerts_handlers`(`name`, `class`, `file`, `service_call`) VALUES 
+('bx_timeline', 'BxTimelineResponse', 'modules/boonex/timeline/classes/BxTimelineResponse.php', '');
+SET @iHandler := LAST_INSERT_ID();
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('system', 'clear_cache', @iHandler),
+('profile', 'delete', @iHandler),
+
+('bx_timeline_videos_mp4', 'transcoded', @iHandler);
+
+
+-- SEARCH
+SET @iSearchOrder = (SELECT IFNULL(MAX(`Order`), 0) FROM `sys_objects_search`);
+INSERT INTO `sys_objects_search` (`ObjectName`, `Title`, `Order`, `ClassName`, `ClassPath`) VALUES
+('bx_timeline', '_bx_timeline', @iSearchOrder + 1, 'BxTimelineSearchResult', 'modules/boonex/timeline/classes/BxTimelineSearchResult.php'),
+('bx_timeline_cmts', '_bx_timeline_cmts', @iSearchOrder + 2, 'BxTimelineCmtsSearchResult', 'modules/boonex/timeline/classes/BxTimelineCmtsSearchResult.php');
+
+
+-- GRIDS: moderation tools
+INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_administration', 'Sql', 'SELECT * FROM `bx_timeline_events` WHERE 1 AND `active`=''1'' ', 'bx_timeline_events', 'id', 'date', 'status', '', 20, NULL, 'start', '', 'title,description', '', 'like', 'reports', '', 192, 'BxTimelineGridAdministration', 'modules/boonex/timeline/classes/BxTimelineGridAdministration.php');
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
+('bx_timeline_administration', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_timeline_administration', 'switcher', '_bx_timeline_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_timeline_administration', 'reports', '_sys_txt_reports_title', '5%', 0, '', '', 3),
+('bx_timeline_administration', 'description', '_bx_timeline_grid_column_title_adm_description', '25%', 0, '25', '', 4),
+('bx_timeline_administration', 'date', '_bx_timeline_grid_column_title_adm_added', '20%', 1, '25', '', 5),
+('bx_timeline_administration', 'owner_id', '_bx_timeline_grid_column_title_adm_author', '20%', 0, '25', '', 6),
+('bx_timeline_administration', 'actions', '', '20%', 0, '', '', 7);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon_only`, `confirm`, `order`) VALUES
+('bx_timeline_administration', 'bulk', 'delete', '_bx_timeline_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_timeline_administration', 'single', 'delete', '_bx_timeline_grid_action_title_adm_delete', 'remove', 1, 1, 2);
+
+
+-- METATAGS
+INSERT INTO `sys_objects_metatags` (`object`, `table_keywords`, `table_locations`, `table_mentions`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline', 'bx_timeline_meta_keywords', 'bx_timeline_meta_locations', 'bx_timeline_meta_mentions', '', '');
+
+
+-- EMAIL TEMPLATES
+INSERT INTO `sys_email_templates` (`Module`, `NameSystem`, `Name`, `Subject`, `Body`) VALUES 
+('bx_timeline', '_bx_timeline_et_txt_name_send', 'bx_timeline_send', '_bx_timeline_et_txt_subject_send', '_bx_timeline_et_txt_body_send');
+
+
+-- CRON
+INSERT INTO `sys_cron_jobs` (`name`, `time`, `class`, `file`, `service_call`) VALUES
+('bx_timeline_hot', '0 * * * *', 'BxTimelineCronHot', 'modules/boonex/timeline/classes/BxTimelineCronHot.php', ''),
+('bx_timeline_publishing', '* * * * *', 'BxTimelineCronPublishing', 'modules/boonex/timeline/classes/BxTimelineCronPublishing.php', '');
+
+
+-- PRELOADER
+SET @iOrderPreloader = (SELECT IFNULL(MAX(`order`), 9999) FROM `sys_preloader` WHERE `type`='js_system' AND `order` > 9999 LIMIT 1);
+INSERT INTO `sys_preloader`(`module`, `type`, `content`, `active`, `order`) VALUES
+('bx_timeline', 'js_system', 'modernizr.min.js', 1, @iOrderPreloader + 1);

+ 497 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/install.sql

@@ -0,0 +1,497 @@
+SET @sName = 'bx_timeline';
+
+-- TABLES
+CREATE TABLE IF NOT EXISTS `bx_timeline_events` (
+  `id` int(11) NOT NULL auto_increment,
+  `owner_id` int(11) NOT NULL default '0',
+  `type` varchar(255) NOT NULL,
+  `action` varchar(255) NOT NULL,
+  `object_id` int(11) NOT NULL default '0',
+  `object_privacy_view` varchar(16) NOT NULL default '3',
+  `content` text NOT NULL,
+  `title` varchar(255) NOT NULL,
+  `description` text NOT NULL,
+  `views` int(11) unsigned NOT NULL default '0',
+  `rate` float NOT NULL default '0',
+  `votes` int(11) unsigned NOT NULL default '0',
+  `rrate` float NOT NULL default '0',
+  `rvotes` int(11) NOT NULL default '0',
+  `score` int(11) NOT NULL default '0',
+  `sc_up` int(11) NOT NULL default '0',
+  `sc_down` int(11) NOT NULL default '0',
+  `comments` int(11) unsigned NOT NULL default '0',
+  `reports` int(11) unsigned NOT NULL default '0',
+  `reposts` int(11) unsigned NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  `published` int(11) NOT NULL default '0',
+  `status` enum ('active', 'awaiting', 'failed', 'hidden', 'deleted') NOT NULL DEFAULT 'active',
+  `active` tinyint(4) NOT NULL default '1',
+  `pinned` int(11) NOT NULL default '0',
+  `sticked` int(11) NOT NULL default '0',
+  `promoted` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `owner_id` (`owner_id`),
+  KEY `object_id` (`object_id`),
+  FULLTEXT KEY `search_fields` (`title`, `description`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_handlers` (
+  `id` int(11) NOT NULL auto_increment,
+  `group` varchar(64) NOT NULL default '',
+  `type` enum('insert','update','delete') NOT NULL DEFAULT 'insert',
+  `alert_unit` varchar(64) NOT NULL default '',
+  `alert_action` varchar(64) NOT NULL default '',
+  `content` text NOT NULL,
+  `privacy` varchar(64) NOT NULL default '',
+  PRIMARY KEY  (`id`),
+  UNIQUE `handler` (`group`, `type`),
+  UNIQUE `alert` (`alert_unit`, `alert_action`)
+);
+
+INSERT INTO `bx_timeline_handlers`(`group`, `type`, `alert_unit`, `alert_action`, `content`) VALUES
+('common_post', 'insert', 'timeline_common_post', '', ''),
+('common_repost', 'insert', 'timeline_common_repost', '', ''),
+('profile', 'delete', 'profile', 'delete', '');
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_cache` (
+  `type` varchar(32) NOT NULL default '',
+  `context_id` int(11) NOT NULL default '0',
+  `profile_id` int(11) NOT NULL default '0',
+  `event_id` int(11) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY `item` (`type`, `context_id`, `profile_id`, `event_id`)
+);
+
+-- TABLES: STORAGES, TRANSCODERS, UPLOADERS
+CREATE TABLE IF NOT EXISTS `bx_timeline_photos` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_photos_processed` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_photos2events` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `event_id` int(11) NOT NULL DEFAULT '0',
+  `media_id` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `media` (`event_id`, `media_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_videos` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_videos_processed` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `remote_id` varchar(128) NOT NULL,
+  `path` varchar(255) NOT NULL,
+  `file_name` varchar(255) NOT NULL,
+  `mime_type` varchar(128) NOT NULL,
+  `ext` varchar(32) NOT NULL,
+  `size` int(11) NOT NULL,
+  `added` int(11) NOT NULL,
+  `modified` int(11) NOT NULL,
+  `private` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `remote_id` (`remote_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_videos2events` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `event_id` int(11) NOT NULL DEFAULT '0',
+  `media_id` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `media` (`event_id`, `media_id`)
+);
+
+-- TABLES: LINKS
+CREATE TABLE IF NOT EXISTS `bx_timeline_links` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `profile_id` int(10) unsigned NOT NULL,
+  `media_id` int(11) NOT NULL DEFAULT '0',
+  `url` varchar(255) NOT NULL,
+  `title` varchar(255) NOT NULL,
+  `text` text NOT NULL,
+  `added` int(11) NOT NULL,
+  PRIMARY KEY (`id`),
+  KEY `profile_id` (`profile_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_links2events` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `event_id` int(11) NOT NULL DEFAULT '0',
+  `link_id` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `link` (`link_id`, `event_id`)
+);
+
+-- TABLES: REPOSTS
+CREATE TABLE IF NOT EXISTS `bx_timeline_reposts_track` (
+  `event_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `reposted_id` int(11) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  UNIQUE KEY `event_id` (`event_id`),
+  KEY `repost` (`reposted_id`, `author_nip`)
+);
+
+-- TABLES: COMMENTS
+CREATE TABLE IF NOT EXISTS `bx_timeline_comments` (
+  `cmt_id` int(11) NOT NULL AUTO_INCREMENT,
+  `cmt_parent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_vparent_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_object_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_author_id` int(11) NOT NULL DEFAULT '0',
+  `cmt_level` int(11) NOT NULL DEFAULT '0',
+  `cmt_text` text NOT NULL,
+  `cmt_time` int(11) unsigned NOT NULL DEFAULT '0',
+  `cmt_replies` int(11) NOT NULL DEFAULT '0',
+  PRIMARY KEY (`cmt_id`),
+  KEY `cmt_object_id` (`cmt_object_id`,`cmt_parent_id`),
+  FULLTEXT KEY `search_fields` (`cmt_text`)
+);
+
+-- TABLE: views
+CREATE TABLE IF NOT EXISTS `bx_timeline_views_track` (
+  `object_id` int(11) NOT NULL default '0',
+  `viewer_id` int(11) NOT NULL default '0',
+  `viewer_nip` int(11) unsigned NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  KEY `id` (`object_id`,`viewer_id`,`viewer_nip`)
+);
+
+-- TABLES: VOTES
+CREATE TABLE IF NOT EXISTS `bx_timeline_votes` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_votes_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_reactions` (
+  `object_id` int(11) NOT NULL default '0',
+  `reaction` varchar(32) NOT NULL default '',
+  `count` int(11) NOT NULL default '0',
+  `sum` int(11) NOT NULL default '0',
+  UNIQUE KEY `reaction` (`object_id`, `reaction`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_reactions_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `reaction` varchar(32) NOT NULL default '',
+  `value` tinyint(4) NOT NULL default '0',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+-- TABLE: metas
+CREATE TABLE IF NOT EXISTS `bx_timeline_meta_keywords` (
+  `object_id` int(10) unsigned NOT NULL,
+  `keyword` varchar(255) NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `keyword` (`keyword`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_meta_locations` (
+  `object_id` int(10) unsigned NOT NULL,
+  `lat` double NOT NULL,
+  `lng` double NOT NULL,
+  `country` varchar(2) NOT NULL,
+  `state` varchar(255) NOT NULL,
+  `city` varchar(255) NOT NULL,
+  `zip` varchar(255) NOT NULL,
+  `street` varchar(255) NOT NULL,
+  `street_number` varchar(255) NOT NULL,
+  PRIMARY KEY (`object_id`),
+  KEY `country_state_city` (`country`,`state`(8),`city`(8))
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_meta_mentions` (
+  `object_id` int(10) unsigned NOT NULL,
+  `profile_id` int(10) unsigned NOT NULL,
+  KEY `object_id` (`object_id`),
+  KEY `profile_id` (`profile_id`)
+);
+
+-- TABLE: reports
+CREATE TABLE IF NOT EXISTS `bx_timeline_reports` (
+  `object_id` int(11) NOT NULL default '0',
+  `count` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_reports_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(32) NOT NULL default '',
+  `text` text NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `report` (`object_id`, `author_nip`)
+);
+
+-- TABLE: hot track
+CREATE TABLE IF NOT EXISTS `bx_timeline_hot_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `event_id` int(11) NOT NULL default '0',
+  `value` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  UNIQUE KEY `event_id` (`event_id`)
+);
+
+-- TABLE: scores
+CREATE TABLE IF NOT EXISTS `bx_timeline_scores` (
+  `object_id` int(11) NOT NULL default '0',
+  `count_up` int(11) NOT NULL default '0',
+  `count_down` int(11) NOT NULL default '0',
+  UNIQUE KEY `object_id` (`object_id`)
+);
+
+CREATE TABLE IF NOT EXISTS `bx_timeline_scores_track` (
+  `id` int(11) NOT NULL AUTO_INCREMENT,
+  `object_id` int(11) NOT NULL default '0',
+  `author_id` int(11) NOT NULL default '0',
+  `author_nip` int(11) unsigned NOT NULL default '0',
+  `type` varchar(8) NOT NULL default '',
+  `date` int(11) NOT NULL default '0',
+  PRIMARY KEY (`id`),
+  KEY `vote` (`object_id`, `author_nip`)
+);
+
+
+-- STORAGES, TRANSCODERS, UPLOADERS
+SET @sStorageEngine = (SELECT `value` FROM `sys_options` WHERE `name` = 'sys_storage_default');
+
+INSERT INTO `sys_objects_uploader` (`object`, `active`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_simple_photo', 1, 'BxTimelineUploaderSimpleAttach', 'modules/boonex/timeline/classes/BxTimelineUploaderSimpleAttach.php'),
+('bx_timeline_simple_video', 1, 'BxTimelineUploaderSimpleAttach', 'modules/boonex/timeline/classes/BxTimelineUploaderSimpleAttach.php'),
+('bx_timeline_html5_photo', 1, 'BxTimelineUploaderHTML5Attach', 'modules/boonex/timeline/classes/BxTimelineUploaderHTML5Attach.php'),
+('bx_timeline_html5_video', 1, 'BxTimelineUploaderHTML5Attach', 'modules/boonex/timeline/classes/BxTimelineUploaderHTML5Attach.php');
+
+INSERT INTO `sys_objects_storage` (`object`, `engine`, `params`, `token_life`, `cache_control`, `levels`, `table_files`, `ext_mode`, `ext_allow`, `ext_deny`, `quota_size`, `current_size`, `quota_number`, `current_number`, `max_file_size`, `ts`) VALUES
+('bx_timeline_photos', @sStorageEngine, '', 360, 2592000, 3, 'bx_timeline_photos', 'allow-deny', 'jpg,jpeg,jpe,gif,png', '', 0, 0, 0, 0, 0, 0),
+('bx_timeline_photos_processed', @sStorageEngine, '', 360, 2592000, 3, 'bx_timeline_photos_processed', 'allow-deny', 'jpg,jpeg,jpe,gif,png', '', 0, 0, 0, 0, 0, 0),
+
+('bx_timeline_videos', @sStorageEngine, '', 360, 2592000, 3, 'bx_timeline_videos', 'allow-deny', 'avi,flv,mpg,mpeg,wmv,mp4,m4v,mov,qt,divx,xvid,3gp,3g2,webm,mkv,ogv,ogg,rm,rmvb,asf,drc', '', 0, 0, 0, 0, 0, 0),
+('bx_timeline_videos_processed', @sStorageEngine, '', 360, 2592000, 3, 'bx_timeline_videos_processed', 'allow-deny', 'jpg,jpeg,jpe,gif,png,avi,flv,mpg,mpeg,wmv,mp4,m4v,mov,qt,divx,xvid,3gp,3g2,webm,mkv,ogv,ogg,rm,rmvb,asf,drc', '', 0, 0, 0, 0, 0, 0);
+
+INSERT INTO `sys_objects_transcoder` (`object`, `storage_object`, `source_type`, `source_params`, `private`, `atime_tracking`, `atime_pruning`, `ts`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_photos_preview', 'bx_timeline_photos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_photos";}', 'no', '1', '2592000', '0', '', ''),
+('bx_timeline_photos_view', 'bx_timeline_photos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_photos";}', 'no', '1', '2592000', '0', '', ''),
+('bx_timeline_photos_medium', 'bx_timeline_photos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_photos";}', 'no', '1', '2592000', '0', '', ''),
+('bx_timeline_photos_big', 'bx_timeline_photos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_photos";}', 'no', '1', '2592000', '0', '', ''),
+
+('bx_timeline_videos_poster', 'bx_timeline_videos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_videos";}', 'no', '0', '0', '0', 'BxDolTranscoderVideo', ''),
+('bx_timeline_videos_mp4', 'bx_timeline_videos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_videos";}', 'no', '0', '0', '0', 'BxDolTranscoderVideo', ''),
+('bx_timeline_videos_mp4_hd', 'bx_timeline_videos_processed', 'Storage', 'a:1:{s:6:"object";s:18:"bx_timeline_videos";}', 'no', '0', '0', '0', 'BxDolTranscoderVideo', '');
+
+INSERT INTO `sys_transcoder_filters` (`transcoder_object`, `filter`, `filter_params`, `order`) VALUES
+('bx_timeline_photos_preview', 'Resize', 'a:3:{s:1:"w";s:3:"100";s:1:"h";s:3:"100";s:13:"square_resize";s:1:"1";}', '0'),
+('bx_timeline_photos_view', 'Resize', 'a:1:{s:1:"w";s:3:"300";}', '0'),
+('bx_timeline_photos_medium', 'Resize', 'a:1:{s:1:"w";s:3:"600";}', '0'),
+('bx_timeline_photos_big', 'Resize', 'a:2:{s:1:"w";s:4:"1200";s:1:"h";s:4:"1200";}', '0'),
+
+('bx_timeline_videos_poster', 'Poster', 'a:2:{s:1:"h";s:3:"318";s:10:"force_type";s:3:"jpg";}', 0),
+('bx_timeline_videos_mp4', 'Mp4', 'a:2:{s:1:"h";s:3:"318";s:10:"force_type";s:3:"mp4";}', 0),
+('bx_timeline_videos_mp4_hd', 'Mp4', 'a:3:{s:1:"h";s:3:"720";s:13:"video_bitrate";s:4:"1536";s:10:"force_type";s:3:"mp4";}', 0);
+
+
+-- Forms -> Post
+INSERT INTO `sys_objects_form` (`object`, `module`, `title`, `action`, `form_attrs`, `submit_name`, `table`, `key`, `uri`, `uri_title`, `params`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_post', @sName, '_bx_timeline_form_post', '', '', 'tlb_do_submit', 'bx_timeline_events', 'id', '', '', '', 0, 1, 'BxTimelineFormPost', 'modules/boonex/timeline/classes/BxTimelineFormPost.php');
+
+INSERT INTO `sys_form_displays` (`display_name`, `module`, `object`, `title`, `view_mode`) VALUES
+('bx_timeline_post_add', @sName, 'bx_timeline_post', '_bx_timeline_form_post_display_add', 0),
+('bx_timeline_post_add_public', @sName, 'bx_timeline_post', '_bx_timeline_form_post_display_add_public', 0),
+('bx_timeline_post_add_profile', @sName, 'bx_timeline_post', '_bx_timeline_form_post_display_add_profile', 0),
+
+('bx_timeline_post_edit', @sName, 'bx_timeline_post', '_bx_timeline_form_post_display_edit', 0);
+
+INSERT INTO `sys_form_inputs` (`object`, `module`, `name`, `value`, `values`, `checked`, `type`, `caption_system`, `caption`, `info`, `required`, `collapsed`, `html`, `attrs`, `attrs_tr`, `attrs_wrapper`, `checker_func`, `checker_params`, `checker_error`, `db_pass`, `db_params`, `editable`, `deletable`) VALUES
+('bx_timeline_post', @sName, 'type', 'post', '', 0, 'hidden', '_bx_timeline_form_post_input_sys_type', '', '', 0, 0, 0, '', '', '', '', '', '', 'Xss', '', 0, 0),
+('bx_timeline_post', @sName, 'action', '', '', 0, 'hidden', '_bx_timeline_form_post_input_sys_action', '', '', 0, 0, 0, '', '', '', '', '', '', 'Xss', '', 0, 0),
+('bx_timeline_post', @sName, 'owner_id', '0', '', 0, 'hidden', '_bx_timeline_form_post_input_sys_owner_id', '', '', 0, 0, 0, '', '', '', '', '', '', 'Int', '', 1, 0),
+('bx_timeline_post', @sName, 'text', '', '', 0, 'textarea', '_bx_timeline_form_post_input_sys_text', '_bx_timeline_form_post_input_text', '', 0, 0, 3, 'a:1:{s:12:"autocomplete";s:3:"off";}', '', '', '', '', '', 'XssHtml', '', 1, 0),
+('bx_timeline_post', @sName, 'anonymous', '', '', 0, 'switcher', '_sys_form_input_sys_anonymous', '_sys_form_input_anonymous', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_timeline_post', @sName, 'date', '', '', 0, 'datetime', '_bx_timeline_form_post_input_sys_date', '_bx_timeline_form_post_input_date', '', 0, 0, 0, '', '', '', '', '', '', 'DateTimeUtc', '', 1, 0),
+('bx_timeline_post', @sName, 'published', '', '', 0, 'datetime', '_bx_timeline_form_post_input_sys_date_published', '_bx_timeline_form_post_input_date_published', '_bx_timeline_form_post_input_date_published_info', 0, 0, 0, '', '', '', '', '', '', 'DateTimeUtc', '', 1, 0),
+('bx_timeline_post', @sName, 'object_privacy_view', '', '', 0, 'custom', '_bx_timeline_form_post_input_sys_object_privacy_view', '_bx_timeline_form_post_input_object_privacy_view', '', 1, 0, 0, '', '', '', '', '', '', '', '', 0, 0),
+('bx_timeline_post', @sName, 'location', '', '', 0, 'location', '_sys_form_input_sys_location', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_timeline_post', @sName, 'link', '', '', 0, 'custom', '_bx_timeline_form_post_input_sys_link', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_timeline_post', @sName, 'photo', 'a:1:{i:0;s:23:"bx_timeline_html5_photo";}', 'a:2:{s:24:"bx_timeline_simple_photo";s:26:"_sys_uploader_simple_title";s:23:"bx_timeline_html5_photo";s:25:"_sys_uploader_html5_title";}', 0, 'files', '_bx_timeline_form_post_input_sys_photo', '_bx_timeline_form_post_input_photo', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_timeline_post', @sName, 'video', 'a:1:{i:0;s:23:"bx_timeline_html5_video";}', 'a:2:{s:24:"bx_timeline_simple_video";s:26:"_sys_uploader_simple_title";s:23:"bx_timeline_html5_video";s:25:"_sys_uploader_html5_title";}', 0, 'files', '_bx_timeline_form_post_input_sys_video', '_bx_timeline_form_post_input_video', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_timeline_post', @sName, 'attachments', '', '', 0, 'custom', '_bx_timeline_form_post_input_sys_attachments', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 1, 0),
+('bx_timeline_post', @sName, 'controls', '', 'tlb_do_submit,tlb_do_cancel', 0, 'input_set', '', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 0, 0),
+('bx_timeline_post', @sName, 'tlb_do_submit', '_bx_timeline_form_post_input_do_submit', '', 0, 'submit', '_bx_timeline_form_post_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 0, 0),
+('bx_timeline_post', @sName, 'tlb_do_cancel', '_bx_timeline_form_post_input_do_cancel', '', 0, 'button', '_bx_timeline_form_post_input_sys_do_cancel', '', '', 0, 0, 0, 'a:2:{s:7:"onclick";s:51:"{js_object_view}.editPostCancel(this, {content_id})";s:5:"class";s:22:"bx-def-margin-sec-left";}', '', '', '', '', '', '', '', 0, 0);
+
+INSERT INTO `sys_form_display_inputs` (`display_name`, `input_name`, `visible_for_levels`, `active`, `order`) VALUES
+('bx_timeline_post_add', 'type', 2147483647, 1, 0),
+('bx_timeline_post_add', 'action', 2147483647, 1, 1),
+('bx_timeline_post_add', 'text', 2147483647, 1, 2),
+('bx_timeline_post_add', 'attachments', 2147483647, 1, 3),
+('bx_timeline_post_add', 'owner_id', 2147483647, 1, 4),
+('bx_timeline_post_add', 'object_privacy_view', 2147483647, 1, 5),
+('bx_timeline_post_add', 'published', 192, 1, 6),
+('bx_timeline_post_add', 'location', 2147483647, 1, 7),
+('bx_timeline_post_add', 'link', 2147483647, 1, 8),
+('bx_timeline_post_add', 'photo', 2147483647, 1, 9),
+('bx_timeline_post_add', 'video', 2147483647, 1, 10),
+('bx_timeline_post_add', 'tlb_do_submit', 2147483647, 1, 11),
+
+('bx_timeline_post_add_public', 'type', 2147483647, 1, 0),
+('bx_timeline_post_add_public', 'action', 2147483647, 1, 1),
+('bx_timeline_post_add_public', 'owner_id', 2147483647, 1, 2),
+('bx_timeline_post_add_public', 'text', 2147483647, 1, 3),
+('bx_timeline_post_add_public', 'attachments', 2147483647, 1, 4),
+('bx_timeline_post_add_public', 'object_privacy_view', 2147483647, 1, 5),
+('bx_timeline_post_add_public', 'published', 192, 1, 6),
+('bx_timeline_post_add_public', 'location', 2147483647, 1, 7),
+('bx_timeline_post_add_public', 'link', 2147483647, 1, 8),
+('bx_timeline_post_add_public', 'photo', 2147483647, 1, 9),
+('bx_timeline_post_add_public', 'video', 2147483647, 1, 10),
+('bx_timeline_post_add_public', 'tlb_do_submit', 2147483647, 1, 11),
+
+('bx_timeline_post_add_profile', 'type', 2147483647, 1, 0),
+('bx_timeline_post_add_profile', 'action', 2147483647, 1, 1),
+('bx_timeline_post_add_profile', 'owner_id', 2147483647, 1, 2),
+('bx_timeline_post_add_profile', 'text', 2147483647, 1, 3),
+('bx_timeline_post_add_profile', 'attachments', 2147483647, 1, 4),
+('bx_timeline_post_add_profile', 'object_privacy_view', 2147483647, 1, 5),
+('bx_timeline_post_add_profile', 'published', 192, 1, 6),
+('bx_timeline_post_add_profile', 'location', 2147483647, 1, 7),
+('bx_timeline_post_add_profile', 'link', 2147483647, 1, 8),
+('bx_timeline_post_add_profile', 'photo', 2147483647, 1, 9),
+('bx_timeline_post_add_profile', 'video', 2147483647, 1, 10),
+('bx_timeline_post_add_profile', 'tlb_do_submit', 2147483647, 1, 11),
+
+('bx_timeline_post_edit', 'type', 2147483647, 1, 1),
+('bx_timeline_post_edit', 'action', 2147483647, 1, 2),
+('bx_timeline_post_edit', 'owner_id', 2147483647, 1, 3),
+('bx_timeline_post_edit', 'text', 2147483647, 1, 4),
+('bx_timeline_post_edit', 'published', 192, 1, 5),
+('bx_timeline_post_edit', 'location', 2147483647, 1, 6),
+('bx_timeline_post_edit', 'controls', 2147483647, 1, 7),
+('bx_timeline_post_edit', 'tlb_do_submit', 2147483647, 1, 8),
+('bx_timeline_post_edit', 'tlb_do_cancel', 2147483647, 1, 9);
+
+-- Forms -> Attach link
+INSERT INTO `sys_objects_form` (`object`, `module`, `title`, `action`, `form_attrs`, `submit_name`, `table`, `key`, `uri`, `uri_title`, `params`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES
+('bx_timeline_attach_link', @sName, '_bx_timeline_form_attach_link', '', '', 'do_submit', 'bx_timeline_links', 'id', '', '', '', 0, 1, '', '');
+
+INSERT INTO `sys_form_displays` (`display_name`, `module`, `object`, `title`, `view_mode`) VALUES
+('bx_timeline_attach_link_add', @sName, 'bx_timeline_attach_link', '_bx_timeline_form_attach_link_display_add', 0);
+
+INSERT INTO `sys_form_inputs` (`object`, `module`, `name`, `value`, `values`, `checked`, `type`, `caption_system`, `caption`, `info`, `required`, `collapsed`, `html`, `attrs`, `attrs_tr`, `attrs_wrapper`, `checker_func`, `checker_params`, `checker_error`, `db_pass`, `db_params`, `editable`, `deletable`) VALUES
+('bx_timeline_attach_link', @sName, 'url', '', '', 0, 'text', '_bx_timeline_form_attach_link_input_sys_url', '_bx_timeline_form_attach_link_input_url', '', 0, 0, 0, '', '', '', 'Preg', 'a:1:{s:4:"preg";s:0:"";}', '_bx_timeline_form_attach_link_input_url_err', '', '', 0, 0),
+('bx_timeline_attach_link', @sName, 'controls', '', 'do_submit,do_cancel', 0, 'input_set', '', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 0, 0),
+('bx_timeline_attach_link', @sName, 'do_submit', '_bx_timeline_form_attach_link_input_do_submit', '', 0, 'submit', '_bx_timeline_form_attach_link_input_sys_do_submit', '', '', 0, 0, 0, '', '', '', '', '', '', '', '', 0, 0),
+('bx_timeline_attach_link', @sName, 'do_cancel', '_bx_timeline_form_attach_link_input_do_cancel', '', 0, 'button', '_bx_timeline_form_attach_link_input_do_cancel', '', '', 0, 0, 0, 'a:2:{s:7:"onclick";s:45:"$(''.bx-popup-applied:visible'').dolPopupHide()";s:5:"class";s:22:"bx-def-margin-sec-left";}', '', '', '', '', '', '', '', 0, 0);
+
+INSERT INTO `sys_form_display_inputs` (`display_name`, `input_name`, `visible_for_levels`, `active`, `order`) VALUES
+('bx_timeline_attach_link_add', 'url', 2147483647, 1, 1),
+('bx_timeline_attach_link_add', 'controls', 2147483647, 1, 2),
+('bx_timeline_attach_link_add', 'do_submit', 2147483647, 1, 3),
+('bx_timeline_attach_link_add', 'do_cancel', 2147483647, 1, 4);
+
+
+-- COMMENTS
+INSERT INTO `sys_objects_cmts` (`Name`, `Module`, `Table`, `CharsPostMin`, `CharsPostMax`, `CharsDisplayMax`, `Html`, `PerView`, `PerViewReplies`, `BrowseType`, `IsBrowseSwitch`, `PostFormPosition`, `NumberOfLevels`, `IsDisplaySwitch`, `IsRatable`, `ViewingThreshold`, `IsOn`, `RootStylePrefix`, `BaseUrl`, `ObjectVote`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldTitle`, `TriggerFieldComments`, `ClassName`, `ClassFile`) VALUES
+('bx_timeline', 'bx_timeline', 'bx_timeline_comments', 1, 5000, 1000, 3, 5, 3, 'tail', 1, 'bottom', 1, 1, 1, -3, 1, 'cmt', 'page.php?i=item&id={object_id}', '', 'bx_timeline_events', 'id', 'object_id', 'title', 'comments', '', '');
+
+
+-- VIEWS
+INSERT INTO `sys_objects_view` (`name`, `table_track`, `period`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_timeline', 'bx_timeline_views_track', '86400', '1', 'bx_timeline_events', 'id', 'object_id', 'views', '', '');
+
+
+-- VOTES
+INSERT INTO `sys_objects_vote`(`Name`, `TableMain`, `TableTrack`, `PostTimeout`, `MinValue`, `MaxValue`, `IsUndo`, `IsOn`, `TriggerTable`, `TriggerFieldId`, `TriggerFieldAuthor`, `TriggerFieldRate`, `TriggerFieldRateCount`, `ClassName`, `ClassFile`) VALUES 
+('bx_timeline', 'bx_timeline_votes', 'bx_timeline_votes_track', '604800', '1', '1', '0', '1', 'bx_timeline_events', 'id', 'object_id', 'rate', 'votes', 'BxTimelineVoteLikes', 'modules/boonex/timeline/classes/BxTimelineVoteLikes.php'),
+('bx_timeline_reactions', 'bx_timeline_reactions', 'bx_timeline_reactions_track', '604800', '1', '1', '1', '1', 'bx_timeline_events', 'id', 'object_id', 'rrate', 'rvotes', 'BxTemplVoteReactions', '');
+
+
+-- SCORES
+INSERT INTO `sys_objects_score` (`name`, `module`, `table_main`, `table_track`, `post_timeout`, `is_on`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_score`, `trigger_field_cup`, `trigger_field_cdown`, `class_name`, `class_file`) VALUES 
+('bx_timeline', 'bx_timeline', 'bx_timeline_scores', 'bx_timeline_scores_track', '604800', '0', 'bx_timeline_events', 'id', 'object_id', 'score', 'sc_up', 'sc_down', '', '');
+
+
+-- REPORTS
+INSERT INTO `sys_objects_report` (`name`, `table_main`, `table_track`, `is_on`, `base_url`, `trigger_table`, `trigger_field_id`, `trigger_field_author`, `trigger_field_count`, `class_name`, `class_file`) VALUES 
+('bx_timeline', 'bx_timeline_reports', 'bx_timeline_reports_track', '1', 'page.php?i=item&id={object_id}', 'bx_timeline_events', 'id', 'owner_id', 'reports',  'BxTimelineReport', 'modules/boonex/timeline/classes/BxTimelineReport.php');
+
+
+-- CONTENT INFO
+INSERT INTO `sys_objects_content_info` (`name`, `title`, `alert_unit`, `alert_action_add`, `alert_action_update`, `alert_action_delete`, `class_name`, `class_file`) VALUES
+('bx_timeline', '_bx_timeline', 'bx_timeline', 'post_common', '', 'delete', '', ''),
+('bx_timeline_cmts', '_bx_timeline_cmts', 'bx_timeline', 'commentPost', 'commentUpdated', 'commentRemoved', 'BxDolContentInfoCmts', '');
+
+
+-- STUDIO PAGE & WIDGET
+INSERT INTO `sys_std_pages`(`index`, `name`, `header`, `caption`, `icon`) VALUES
+(3, 'bx_timeline', '_bx_timeline', '_bx_timeline', 'bx_timeline@modules/boonex/timeline/|std-icon.svg');
+SET @iPageId = LAST_INSERT_ID();
+
+SET @iParentPageId = (SELECT `id` FROM `sys_std_pages` WHERE `name` = 'home');
+SET @iParentPageOrder = (SELECT MAX(`order`) FROM `sys_std_pages_widgets` WHERE `page_id` = @iParentPageId);
+INSERT INTO `sys_std_widgets` (`page_id`, `module`, `url`, `click`, `icon`, `caption`, `cnt_notices`, `cnt_actions`) VALUES
+(@iPageId, 'bx_timeline', '{url_studio}module.php?name=bx_timeline', '', 'bx_timeline@modules/boonex/timeline/|std-icon.svg', '_bx_timeline', '', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_actions";s:6:"params";a:0:{}s:5:"class";s:18:"TemplStudioModules";}');
+INSERT INTO `sys_std_pages_widgets` (`page_id`, `widget_id`, `order`) VALUES
+(@iParentPageId, LAST_INSERT_ID(), IF(ISNULL(@iParentPageOrder), 1, @iParentPageOrder + 1));

+ 71 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/install/sql/uninstall.sql

@@ -0,0 +1,71 @@
+SET @sName = 'bx_timeline';
+
+DROP TABLE IF EXISTS `bx_timeline_events`, `bx_timeline_handlers`, `bx_timeline_cache`;
+
+DROP TABLE IF EXISTS `bx_timeline_photos`, `bx_timeline_photos_processed`, `bx_timeline_photos2events`;
+
+DROP TABLE IF EXISTS `bx_timeline_videos`, `bx_timeline_videos_processed`, `bx_timeline_videos2events`;
+
+DROP TABLE IF EXISTS `bx_timeline_links`, `bx_timeline_links2events`;
+
+DROP TABLE IF EXISTS `bx_timeline_reposts_track`;
+
+DROP TABLE IF EXISTS `bx_timeline_comments`;
+
+DROP TABLE IF EXISTS `bx_timeline_views_track`;
+
+DROP TABLE IF EXISTS `bx_timeline_votes`, `bx_timeline_votes_track`, `bx_timeline_reactions`, `bx_timeline_reactions_track`;
+
+DROP TABLE IF EXISTS `bx_timeline_meta_keywords`, `bx_timeline_meta_locations`, `bx_timeline_meta_mentions`;
+
+DROP TABLE IF EXISTS `bx_timeline_reports`, `bx_timeline_reports_track`;
+
+DROP TABLE IF EXISTS `bx_timeline_hot_track`;
+
+DROP TABLE IF EXISTS `bx_timeline_scores`, `bx_timeline_scores_track`;
+
+
+-- STORAGES, TRANSCODERS, UPLOADERS
+DELETE FROM `sys_objects_uploader` WHERE `object` LIKE 'bx_timeline%';
+DELETE FROM `sys_objects_storage` WHERE `object`  LIKE 'bx_timeline%';
+DELETE FROM `sys_objects_transcoder` WHERE `object`  LIKE 'bx_timeline%';
+DELETE FROM `sys_transcoder_filters` WHERE `transcoder_object` LIKE 'bx_timeline%';
+DELETE FROM `sys_transcoder_images_files` WHERE `transcoder_object` LIKE 'bx_timeline%';
+DELETE FROM `sys_transcoder_videos_files` WHERE `transcoder_object` LIKE 'bx_timeline%';
+
+
+-- Forms All
+DELETE FROM `sys_form_display_inputs` WHERE `display_name` IN  (SELECT `display_name` FROM `sys_form_displays` WHERE `module` = @sName);
+DELETE FROM `sys_form_inputs` WHERE `module` = @sName;
+DELETE FROM `sys_form_displays` WHERE `module` = @sName;
+DELETE FROM `sys_objects_form` WHERE `module` = @sName;
+
+
+-- COMMENTS
+DELETE FROM `sys_objects_cmts` WHERE `Name` = 'bx_timeline' LIMIT 1;
+
+
+-- VIEWS
+DELETE FROM `sys_objects_view` WHERE `name` = 'bx_timeline' LIMIT 1;
+
+
+-- VOTES
+DELETE FROM `sys_objects_vote` WHERE `Name` IN ('bx_timeline', 'bx_timeline_reactions');
+
+
+-- SCORES
+DELETE FROM `sys_objects_score` WHERE `name` = 'bx_timeline';
+
+
+-- REPORTS
+DELETE FROM `sys_objects_report` WHERE `Name` = 'bx_timeline' LIMIT 1;
+
+
+-- CONTENT INFO
+DELETE FROM `sys_objects_content_info` WHERE `name` IN ('bx_timeline', 'bx_timeline_cmts');
+
+
+-- STUDIO PAGE & WIDGET
+DELETE FROM `tp`, `tw`, `tpw`
+USING `sys_std_pages` AS `tp`, `sys_std_widgets` AS `tw`, `sys_std_pages_widgets` AS `tpw`
+WHERE `tp`.`id` = `tw`.`page_id` AND `tw`.`id` = `tpw`.`widget_id` AND `tp`.`name` = @sName;

+ 356 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/js/main.js

@@ -0,0 +1,356 @@
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+function BxTimelineMain() {
+    this.sIdPost = '#bx-timeline-post';
+    this.sIdPostForm = 'form#bx_timeline_post';
+
+    this.sId = '#bx-timeline';
+
+    this.sSP = 'bx-tl';
+    this.sClassView = this.sSP + '-view';
+    this.sClassMasonry = this.sSP + '-masonry';
+    this.sClassItems = this.sSP + '-items';
+    this.sClassItem = this.sSP + '-item';
+    this.sClassDividerToday = this.sSP + '-divider-today';
+    this.sClassItemContent = this.sSP + '-item-content';
+    this.sClassItemComments = this.sSP + '-item-comments-holder';
+    this.sClassItemImages = this.sSP + '-item-images';
+    this.sClassItemImage = this.sSP + '-item-image';
+    this.sClassItemVideos = this.sSP + '-item-videos';
+    this.sClassItemVideo = this.sSP + '-item-video';
+    this.sClassItemAttachments = this.sSP + '-item-attachments';
+    this.sClassItemAttachment = this.sSP + '-item-attachment';
+    this.sClassBlink = this.sSP + '-blink';
+
+    this.oView = null;
+    this.bViewTimeline = false;
+    this.bViewOutline = false;
+    this.bViewItem = false;
+}
+
+BxTimelineMain.prototype.initVideos = function(oParent) {
+    oParent.find('iframe').load(function() {
+        $(this).height(($(this).contents().find('video').height()) + 'px');
+    });
+};
+
+BxTimelineMain.prototype.isMasonry = function() {
+    return this.oView.find('.' + this.sClassItems).hasClass(this.sClassMasonry);
+};
+
+BxTimelineMain.prototype.isMasonryEmpty = function() {
+    return this.oView.find('.' + this.sClassItems + ' .' + this.sClassItem).length == 0;
+};
+
+BxTimelineMain.prototype.initMasonry = function(onComplete) {
+    var $this = this;
+    var oHolder = this.oView.find('.' + this.sClassItems);
+
+    var oItems = oHolder.find('.' + this.sClassItem);
+    if(oItems.length == 0) 
+        return;
+
+    oItems.resize(function(){
+            $this.reloadMasonry();
+    }).find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight(this.sSP + '-overflow', function(oElement) {
+            $this.onFindOverflow(oElement);
+    });
+
+    oHolder.addClass(this.sClassMasonry).masonry({
+      itemSelector: '.' + this.sClassItem,
+      columnWidth: '.' + this.sSP + '-grid-sizer'
+    }).masonry('once', 'layoutComplete', function() {
+        if(typeof onComplete === 'function')
+            onComplete(oItems);
+    });
+};
+
+BxTimelineMain.prototype.destroyMasonry = function() {
+    this.oView.find('.' + this.sClassItems).removeClass(this.sClassMasonry).masonry('destroy');
+};
+
+BxTimelineMain.prototype.appendMasonry = function(oItems, onComplete) {
+    var $this = this;
+    var oItems = $(oItems);
+    oItems.resize(function(){
+            $this.reloadMasonry();
+    }).find('iframe').load(function() {
+            $this.reloadMasonry();
+    }).find('img.' + this.sSP + '-item-image').load(function() {
+            $this.reloadMasonry();
+    });
+
+    var oHolder = this.oView.find('.' + this.sClassItems).masonry('layout').append(oItems);
+    if(!this.isMasonry())
+        this.initMasonry(onComplete);
+    else
+        oHolder.masonry('appended', oItems).masonry('layout').masonry('once', 'layoutComplete', function() {
+            if(typeof onComplete === 'function')
+                onComplete(oItems);
+        });
+};
+
+BxTimelineMain.prototype.prependMasonry = function(oItems, onComplete) {
+    var $this = this;
+    var oItems = $(oItems);
+    oItems.resize(function(){
+        $this.reloadMasonry();
+    }).find('iframe').load(function() {
+        $this.reloadMasonry();
+    }).find('img.' + this.sSP + '-item-image').load(function() {
+        $this.reloadMasonry();
+    });
+
+    var oHolder = this.oView.find('.' + this.sClassItems).masonry('layout').prepend(oItems);
+    if(!this.isMasonry())
+        this.initMasonry(onComplete);
+    else
+        oHolder.masonry('prepended', oItems).masonry('layout').masonry('once', 'layoutComplete', function() {
+            if(typeof onComplete === 'function')
+                onComplete(oItems);
+        });
+};
+
+BxTimelineMain.prototype.removeMasonry = function(oItems, onRemove) {
+    var $this = this;
+    var oItems = $(oItems);
+
+    var oHolder = this.oView.find('.' + this.sClassItems);
+    if(typeof onRemove === 'function')
+        oHolder.masonry('once', 'removeComplete', onRemove);
+
+    oHolder.masonry('remove', oItems).masonry('layout');
+};
+
+BxTimelineMain.prototype.reloadMasonry = function() {
+    this.oView.find('.' + this.sClassItems).masonry('reloadItems').masonry('layout');
+};
+
+BxTimelineMain.prototype.initFlickity = function() {
+    var $this = this;
+
+    //--- init Flickity for images (may be used in header section)
+    $('.' + this.sClassItem + ' .' + this.sClassItemImages + '.' + this.sSP + '-ii-gallery').each(function() {
+        if($(this).find('div.' + $this.sClassItemImage).length <= 1)
+            return;
+
+        $(this).flickity({
+            cellSelector: 'div.' + $this.sClassItemImage,
+            cellAlign: 'left',
+            imagesLoaded: true,
+            wrapAround: true,
+            pageDots: false
+        });
+    });
+
+    //--- init Flickity for videos (may be used in header section)
+    $('.' + this.sClassItem + ' .' + this.sClassItemVideos + '.' + this.sSP + '-iv-gallery').each(function() {
+        if($(this).find('div.' + $this.sClassItemVideo).length <= 1)
+            return;
+
+        var oCarousel = $(this);
+
+        oCarousel.flickity({
+            cellSelector: 'div.' + $this.sClassItemVideo,
+            cellAlign: 'left',
+            imagesLoaded: true,
+            wrapAround: true,
+            pageDots: false
+        });
+
+       oCarousel.find('div.' + $this.sClassItemVideo + ' video').each(function() {
+           this.addEventListener('loadedmetadata', function() {
+               oCarousel.flickity('resize');
+           }, true);
+       });
+    });
+
+    //--- init Flickity for attachments (images and video in attachments seation)
+    $('.' + this.sClassItem + ' .' + this.sClassItemAttachments + '.' + this.sSP + '-ia-gallery').each(function() {
+        if($(this).find('div.' + $this.sClassItemAttachment).length <= 1)
+            return;
+
+        var oCarousel = $(this);
+
+        oCarousel.flickity({
+            cellSelector: 'div.' + $this.sClassItemAttachment,
+            cellAlign: 'left',
+            imagesLoaded: true,
+            wrapAround: true,
+            pageDots: false
+        });
+
+       oCarousel.find('div.' + $this.sClassItemAttachment + ' video').each(function() {
+           this.addEventListener('loadedmetadata', function() {
+               oCarousel.flickity('resize');
+           }, true);
+       });
+    });
+};
+
+BxTimelineMain.prototype.onFindOverflow = function(oElement) {
+    $(oElement).after($(oElement).parents('.' + this.sClassView + ':first').find('.' + this.sSP + '-content-show-more:hidden:first').clone().show());
+};
+
+BxTimelineMain.prototype.loadingInButton = function(e, bShow) {
+    if($(e).length)
+        bx_loading_btn($(e), bShow);
+    else
+        bx_loading($('body'), bShow);	
+};
+
+BxTimelineMain.prototype.loadingInItem = function(e, bShow) {
+    var oParent = $('body');
+    if($(e).length)
+        oParent = !$(e).hasClass(this.sClassItem) ? $(e).parents('.' + this.sClassItem + ':first') : $(e);
+
+    bx_loading(oParent, bShow);
+};
+
+BxTimelineMain.prototype.loadingInBlock = function(e, bShow) {
+    var oParent = $(e).length ? $(e).parents('.bx-db-container:first') : $('body'); 
+    bx_loading(oParent, bShow);
+};
+
+BxTimelineMain.prototype.loadingInPopup = function(e, bShow) {
+    var oParent = $(e).length ? $(e).parents('.bx-popup-content:first') : $('body'); 
+    bx_loading(oParent, bShow);
+};
+
+BxTimelineMain.prototype.loadingIn = function(e, bShow) {
+    var oElement = $(e);
+    var bElement = oElement.length > 0;
+
+    if(bElement && oElement.hasClass('bx-btn'))
+        this.loadingInButton(e, bShow);
+    else if(bElement && (oElement.hasClass(this.sClassItem) || oElement.parents('.' + this.sClassItem + ':first').length > 0))
+        this.loadingInItem(e, bShow);
+    else if(bElement && oElement.parents('.bx-popup-content:first').length > 0)
+        this.loadingInPopup(e, bShow);
+    else if(bElement && oElement.parents('.bx-db-container:first').length > 0)
+        this.loadingInBlock(e, bShow);
+    else 
+        bx_loading($('body'), bShow);
+};
+
+BxTimelineMain.prototype._loading = function(e, bShow) {
+    var oParent = $(e).length ? $(e) : $('body'); 
+    bx_loading(oParent, bShow);
+};
+
+BxTimelineMain.prototype._getViewObject = function(oElement) {
+    oElement = $(oElement);
+
+    var oView = oElement;
+    if(oView.hasClass(this.sClassView))
+        return oView;
+
+    oView = oElement.parents('.' + this.sClassView + ':first');
+    if(oView.hasClass(this.sClassView))
+        return oView;
+
+    oView = oElement.parents('.bx-page-block-container:first').find('.' + this.sClassView + ':first');
+    if(oView.hasClass(this.sClassView))
+        return oView;
+
+    return null;
+};
+
+BxTimelineMain.prototype._getView = function(oElement) {
+    var oView = this._getViewObject(oElement);
+    if(!oView || oView.length == 0)
+        return '';
+
+    if(oView.hasClass(this.sClassView + '-item'))
+        return 'item';
+
+    if(oView.hasClass(this.sClassView + '-timeline'))
+        return 'timeline';
+
+    if(oView.hasClass(this.sClassView + '-outline'))
+        return 'outline';
+
+    if(oView.hasClass(this.sClassView + '-search'))
+        return 'search';
+
+    return '';
+};
+
+BxTimelineMain.prototype._getName = function(oData)
+{
+    var aAddons = [];
+    if(oData['name'])
+        aAddons.push(oData['name']);
+    else {
+        if(oData['view'])
+            aAddons.push(oData['view']);
+
+        if(oData['type'])
+            aAddons.push(oData['type']);
+    }
+
+    return aAddons.length > 0 ? aAddons.join('_') : '';
+};
+
+BxTimelineMain.prototype._getHtmlId = function(sKey, oData, bWhole, bHash)
+{
+    var sDiv = '_';
+    var sHtmlId = this.sId  + sDiv + sKey + sDiv + this._getName(oData) + (bWhole != undefined && !bWhole ? sDiv : '');
+    if(bHash != undefined && !bHash)
+        sHtmlId = sHtmlId.substr(1);
+
+    return sHtmlId.replace(new RegExp(sDiv,'g'), '-');
+};
+
+BxTimelineMain.prototype._getDefaultData = function() {
+    var oDate = new Date();
+    return jQuery.extend({}, this._oRequestParams, {_t:oDate.getTime()});
+};
+
+
+BxTimelineMain.prototype._getPost = function(oView, iId, aParams) {
+    var $this = this;
+    var oData = this._getDefaultData();
+    oData = jQuery.extend({}, oData, {js_object: this._sObjName, id: iId}, aParams != undefined ? aParams : {});
+
+    this.loadingInBlock(oView, true);
+
+    jQuery.post (
+        this._sActionsUrl + 'get_post/',
+        oData,
+        function(oData) {
+            $this.loadingInBlock(oView, false);
+
+            processJsonData(oData);
+        },
+        'json'
+    );
+};
+
+(function($) {
+    $.fn.checkOverflowHeight = function(sClass, onFind) {
+    	if(!sClass)
+    		sClass = 'bx-overflow';
+
+        return this.each(function() {
+            var oElement = $(this);
+            if(oElement.hasClass(sClass) || oElement.css('overflow') != 'hidden')
+            	return;
+
+            if(oElement.prop('scrollHeight') <= oElement.height())
+            	return;
+
+            oElement.addClass(sClass);
+            if(typeof onFind === 'function')
+            	onFind(oElement);
+        });
+    };
+})(jQuery);

+ 369 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/js/post.js

@@ -0,0 +1,369 @@
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+function BxTimelinePost(oOptions) {
+    this._sActionsUri = oOptions.sActionUri;
+    this._sActionsUrl = oOptions.sActionUrl;
+    this._sObjName = oOptions.sObjName == undefined ? 'oTimelinePost' : oOptions.sObjName;
+    this._iOwnerId = oOptions.iOwnerId == undefined ? 0 : parseInt(oOptions.iOwnerId);
+    this._sAnimationEffect = oOptions.sAnimationEffect == undefined ? 'slide' : oOptions.sAnimationEffect;
+    this._iAnimationSpeed = oOptions.iAnimationSpeed == undefined ? 'slow' : oOptions.iAnimationSpeed;
+    this._sVideosAutoplay = oOptions.sVideosAutoplay == undefined ? 'off' : oOptions.sVideosAutoplay;
+    this._aHtmlIds = oOptions.aHtmlIds == undefined ? {} : oOptions.aHtmlIds;
+    this._oRequestParams = oOptions.oRequestParams == undefined ? {} : oOptions.oRequestParams;
+
+    this._sPregTag = "(<([^>]+bx-tag[^>]+)>)";
+    this._sPregMention = "(<([^>]+bx-mention[^>]+)>)";
+    this._sPregUrl = "\\b((https?://)|(www\\.))(([0-9a-zA-Z_!~*'().&=+$%-]+:)?[0-9a-zA-Z_!~*'().&=+$%-]+\\@)?(([0-9]{1,3}\\.){3}[0-9]{1,3}|([0-9a-zA-Z_!~*'()-]+\\.)*([0-9a-zA-Z][0-9a-zA-Z-]{0,61})?[0-9a-zA-Z]\\.[a-zA-Z]{2,6})(:[0-9]{1,4})?((/[0-9a-zA-Z_!~*'().;?:\\@&=+$,%#-]+)*/?)";
+    this._oAttachedLinks = {};
+
+    var $this = this;
+    if (typeof window.glOnInitEditor === 'undefined')
+        window.glOnInitEditor = [];
+
+    window.glOnInitEditor.push(function (sEditorSelector) {
+        var sBaseUrl = sUrlRoot + 'plugins_public/emoji/js/';
+        if ('undefined' === typeof(EmojiPicker)) {
+            bx_get_scripts([
+                sBaseUrl + 'util.js', 
+                sBaseUrl + 'config.js',
+                sBaseUrl + 'emoji-picker.js', 
+                sBaseUrl + 'jquery.emojiarea.js'
+            ], function() {
+                $this.initEmoji(sEditorSelector)
+            });
+        }
+        else
+            $this.initEmoji(sEditorSelector);
+    });
+
+    $(document).ready(function () {
+        var oPost = $($this.sIdPost + ' form');
+        if(!oPost || oPost.length == 0)
+            oPost = $($this.sIdPostForm);
+
+    	oPost.each(function() {
+            var sId = $(this).attr('id');
+            $this.initFormPost(sId);
+    	});
+    });
+}
+
+BxTimelinePost.prototype = new BxTimelineMain();
+
+BxTimelinePost.prototype.initEmoji = function(sEditorSelector)
+{
+    var oLink = $(sEditorSelector).parents('form:first').find('a.add-emoji');
+
+    var oEmojiConf = {
+        emojiable_selector: bx_editor_get_htmleditable(sEditorSelector), 
+        menu_icon: oLink  /* emoji popup menu icon */
+    };
+    new EmojiPicker(oEmojiConf ).discover();  /* call init emoji function */
+};
+
+BxTimelinePost.prototype.initFormPost = function(sFormId)
+{
+    var $this = this;
+    var oForm = $('#' + sFormId);
+    var oTextarea = oForm.find('textarea');
+
+    autosize(oTextarea);
+
+    oForm.ajaxForm({
+        dataType: "json",
+        beforeSubmit: function (formData, jqForm, options) {
+            window[$this._sObjName].beforeFormPostSubmit(oForm);
+        },
+        success: function (oData) {
+            window[$this._sObjName].afterFormPostSubmit(oForm, oData);
+        }
+    });
+
+    if(typeof window.glOnSpaceEnterInEditor === 'undefined')
+        window.glOnSpaceEnterInEditor = [];
+
+    window.glOnSpaceEnterInEditor.push(function (sData, sSelector) {
+        if(!oTextarea.is(sSelector))
+            return;
+
+        var oExp, aMatch = null;
+
+        oExp = new RegExp($this._sPregTag , "ig");
+        sData = sData.replace(oExp, '');
+
+        oExp = new RegExp($this._sPregMention , "ig");
+        sData = sData.replace(oExp, '');
+
+        oExp = new RegExp($this._sPregUrl , "ig");
+        while(aMatch = oExp.exec(sData)) {
+            var sUrl = aMatch[0];
+            if(!sUrl.length || $this._oAttachedLinks[sUrl] != undefined)
+                continue;
+
+            //--- Mark that 'attach link' process was started.
+            $this._oAttachedLinks[sUrl] = 0;
+
+            $this.addAttachLink(oForm, sUrl);
+        }
+    });
+};
+
+BxTimelinePost.prototype.beforeFormPostSubmit = function(oForm)
+{
+    this.loadingInButton($(oForm).children().find(':submit'), true);
+};
+
+BxTimelinePost.prototype.afterFormPostSubmit = function (oForm, oData)
+{
+    var $this = this;
+    var fContinue = function() {
+        if(oData && oData.form != undefined && oData.form_id != undefined) {
+            $('#' + oData.form_id).replaceWith(oData.form);
+            $this.initFormPost(oData.form_id);
+
+            return;
+        }
+
+        if(oData && oData.id != undefined) {
+            var iId = parseInt(oData.id);
+            if(iId <= 0) 
+                return;
+
+            $('.' + $this.sClassView).each(function() {
+                var oView = $(this);
+                $this._getPost(oView, iId, jQuery.extend({}, $this._oRequestParams, {view: $this._getView(oView), afps_loading: 1}));
+            });
+        }
+
+        $this._getForm(oForm);
+    };
+
+    this.loadingInButton($(oForm).children().find(':submit'), false);
+
+    if(oData && oData.message != undefined)
+        bx_alert(oData.message, fContinue);
+    else
+        fContinue();
+};
+
+BxTimelinePost.prototype.initFormAttachLink = function(sFormId)
+{
+    var $this = this;
+    var oForm = $('#' + sFormId);
+
+    oForm.ajaxForm({
+        dataType: "json",
+        clearForm: true,
+        beforeSubmit: function (formData, jqForm, options) {
+            window[$this._sObjName].beforeFormAttachLinkSubmit(oForm);
+        },
+        success: function (oData) {
+            window[$this._sObjName].afterFormAttachLinkSubmit(oForm, oData);
+        }
+    });
+};
+
+BxTimelinePost.prototype.beforeFormAttachLinkSubmit = function(oForm)
+{
+    this.loadingInButton($(oForm).children().find(':submit'), true);
+};
+
+BxTimelinePost.prototype.afterFormAttachLinkSubmit = function (oForm, oData)
+{
+    var $this = this;
+    var fContinue = function() {
+        if(oData && oData.item != undefined) {
+            $('#' + $this._aHtmlIds['attach_link_popup']).dolPopupHide({});
+
+            if(!$.trim(oData.item).length)
+                return;
+
+            var oItem = $(oData.item).hide();
+            $('#' + $this._aHtmlIds['attach_link_form_field']).prepend(oItem).find('#' + oItem.attr('id')).bx_anim('show', $this._sAnimationEffect, $this._sAnimationSpeed);
+
+            return;
+        }
+
+        if(oData && oData.form != undefined && oData.form_id != undefined) {
+            $('#' + oData.form_id).replaceWith(oData.form);
+            $this.initFormAttachLink(oData.form_id);
+
+            return;
+        }
+    };
+
+    this.loadingInButton($(oForm).find(':submit'), false);
+
+    if(oData && oData.message != undefined)
+        bx_alert(oData.message, fContinue);
+    else
+        fContinue();
+};
+
+BxTimelinePost.prototype.deleteAttachLink = function(oLink, iId)
+{
+    var $this = this;
+    var oData = this._getDefaultData();
+    oData['id'] = iId;
+
+    var oAttachLink = $('#' + this._aHtmlIds['attach_link_item'] + iId);
+    bx_loading(oAttachLink, true);
+    
+    jQuery.post (
+        this._sActionsUrl + 'delete_attach_link/',
+        oData,
+        function(oData) {
+            var fContinue = function() {
+                if(oData && oData.code != undefined && oData.code == 0) {
+                    for(var sUrl in $this._oAttachedLinks)
+                        if(parseInt($this._oAttachedLinks[sUrl]) == parseInt(iId)) {
+                            delete $this._oAttachedLinks[sUrl];
+                            break;
+                        }
+
+                    oAttachLink.bx_anim('hide', $this._sAnimationEffect, $this._sAnimationSpeed, function() {
+                        $(this).remove;
+                    });
+                }
+            };
+
+            bx_loading(oAttachLink, false);
+
+            if(oData && oData.message != undefined)
+                bx_alert(oData.message, fContinue);
+            else
+                    fContinue();
+        },
+        'json'
+    );
+
+    return false;
+};
+
+BxTimelinePost.prototype.addAttachLink = function(oElement, sUrl)
+{
+    if(!sUrl)
+        return;
+
+    var $this = this;
+    var oData = this._getDefaultData();
+    oData['url'] = sUrl;
+
+    jQuery.post (
+        this._sActionsUrl + 'add_attach_link/',
+        oData,
+        function(oData) {
+            if(!oData.id || !oData.item || !$.trim(oData.item).length)
+                return;
+
+            //--- Mark that 'attach link' process was finished.
+            $this._oAttachedLinks[sUrl] = oData.id;
+
+            var oItem = $(oData.item).hide();
+            $('#' + $this._aHtmlIds['attach_link_form_field']).prepend(oItem).find('#' + oItem.attr('id')).bx_anim('show', $this._sAnimationEffect, $this._sAnimationSpeed);
+        },
+        'json'
+    );
+};
+
+BxTimelinePost.prototype.showAttachLink = function(oLink)
+{
+    var oData = this._getDefaultData();    
+
+    $(window).dolPopupAjax({
+        id: {value: this._aHtmlIds['attach_link_popup'], force: true},
+        url: bx_append_url_params(this._sActionsUri + 'get_attach_link_form/', oData),
+        closeOnOuterClick: false,
+        removeOnClose: true
+    });
+
+    return false;
+};
+
+BxTimelinePost.prototype._getForm = function(oElement)
+{
+    var $this = this;
+    var oData = this._getDefaultData();
+
+    jQuery.post (
+        this._sActionsUrl + 'get_post_form/',
+        oData,
+        function(oData) {
+            if(oData && oData.form != undefined && oData.form_id != undefined) {
+                $('#' + oData.form_id).replaceWith(oData.form);
+                $this.initFormPost(oData.form_id);
+            }
+        },
+        'json'
+    );
+};
+
+BxTimelinePost.prototype._onGetPost = function(oData)
+{
+    var $this = this;
+    var fContinue = function(oData) {
+        if(!$.trim(oData.item).length) 
+            return;
+
+        $this.oView = $($this._getHtmlId('main', oData));
+
+        var oLoadMore = $this.oView.find('.' + $this.sSP + '-load-more');
+        if(!oLoadMore.is(':visible'))
+            oLoadMore.show();
+
+        var oEmpty = $this.oView.find('.' + $this.sSP + '-empty');
+        if(oEmpty.is(':visible'))
+            oEmpty.hide();
+
+        var oContent = $(oData.item).bxProcessHtml();
+        switch(oData.view) {
+            case 'timeline':
+                var oItems = $this.oView.find('.' + $this.sClassItems);
+                var oDivider  = oItems.find('.' + $this.sClassDividerToday);
+                var bDivider = oDivider.length > 0;
+
+                if(bDivider && !oDivider.is(':visible'))
+                    oDivider.show();
+
+                oContent.hide();
+
+                var oItem = bDivider ? oDivider.after(oContent).next('.' + $this.sClassItem + ':hidden') : oContent.prependTo(oItems);
+                oItem.bx_anim('show', $this._sAnimationEffect, $this._iAnimationSpeed, function() {
+                    $(this).find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight($this.sSP + '-overflow', function(oElement) {
+                        $this.onFindOverflow(oElement);
+                    });
+
+                    $this.initFlickity();
+                });
+
+                if($this._sVideosAutoplay != 'off')
+                    $this.initVideos($this.oView);
+                break;
+
+            case 'outline':
+                $this.prependMasonry(oContent, function(oItems) {
+                    $(oItems).find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight($this.sSP + '-overflow', function(oElement) {
+                        $this.onFindOverflow(oElement);
+                    });
+
+                    $this.initFlickity();
+                });
+                break;
+        }
+    };
+
+    if(oData && oData.message != undefined && oData.message.length != 0)
+        bx_alert(oData.message, function() {
+                fContinue(oData);
+        });
+    else
+        fContinue(oData);
+};

+ 860 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/js/view.js

@@ -0,0 +1,860 @@
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Timeline Timeline
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+function BxTimelineView(oOptions) {
+    this._sActionsUri = oOptions.sActionUri;
+    this._sActionsUrl = oOptions.sActionUrl;
+    this._sObjName = oOptions.sObjName == undefined ? 'oTimelineView' : oOptions.sObjName;
+    this._iOwnerId = oOptions.iOwnerId == undefined ? 0 : oOptions.iOwnerId;
+    this._sReferrer = oOptions.sReferrer == undefined ? '' : oOptions.sReferrer;
+    this._sAnimationEffect = oOptions.sAnimationEffect == undefined ? 'slide' : oOptions.sAnimationEffect;
+    this._iAnimationSpeed = oOptions.iAnimationSpeed == undefined ? 'slow' : oOptions.iAnimationSpeed;
+    this._sVideosAutoplay = oOptions.sVideosAutoplay == undefined ? 'off' : oOptions.sVideosAutoplay;
+    this._aHtmlIds = oOptions.aHtmlIds == undefined ? {} : oOptions.aHtmlIds;
+    this._oRequestParams = oOptions.oRequestParams == undefined ? {} : oOptions.oRequestParams;
+
+    this._fOutsideOffset = 0.8;
+    this._oSaved = {};
+
+    this._oVapPlayers = {};
+    this._fVapOffsetStart = 0.8;
+    this._fVapOffsetStop = 0.2;
+
+    this._bLiveUpdatePaused = false;
+
+    var $this = this;
+    $(document).ready(function() {
+    	$this.init();
+    });
+}
+
+BxTimelineView.prototype = new BxTimelineMain();
+
+BxTimelineView.prototype.init = function()
+{
+    var $this = this;
+
+    this.oView = $(this._getHtmlId('main', this._oRequestParams));
+    if(this.oView.length > 0) {
+        if(this.oView.hasClass(this.sClassView + '-timeline'))
+            this.bViewTimeline = true;
+        else if(this.oView.hasClass(this.sClassView + '-outline'))
+            this.bViewOutline = true;
+        else if(this.oView.hasClass(this.sClassView + '-item'))
+            this.bViewItem = true;
+    }
+
+    if(this.bViewTimeline) {
+        var oItems = this.oView.find('.' + this.sClassItem);
+        oItems.find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight(this.sSP + '-overflow', function(oElement) {
+            $this.onFindOverflow(oElement);
+        });
+
+        //--- Hide timeline Events which are outside the viewport
+        this.hideEvents(oItems, this._fOutsideOffset);
+
+        //--- on scolling, show/animate timeline Events when enter the viewport
+        $(window).on('scroll', function() {
+            if(!window.requestAnimationFrame) 
+                setTimeout(function() {
+                    $this.showEvents(oItems, $this._fOutsideOffset);
+                }, 100);
+            else
+                window.requestAnimationFrame(function() {
+                    $this.showEvents(oItems, $this._fOutsideOffset);
+                });
+        });
+
+        //--- Init Video Autoplay
+        if(this._sVideosAutoplay != 'off') {
+            this.initVideosAutoplay(this.oView);
+
+            $(window).on('scroll', function() {
+                var oItems = $this.oView.find('.' + $this.sClassItem);
+
+                if(!window.requestAnimationFrame) 
+                    setTimeout(function() {
+                        $this.playVideos(oItems, $this._fVapOffsetStart, $this._fVapOffsetStop);
+                    }, 100);
+                else
+                    window.requestAnimationFrame(function() {
+                        $this.playVideos(oItems, $this._fVapOffsetStart, $this._fVapOffsetStop);
+                    });
+            });
+        }
+
+        //--- Blink (highlight) necessary items
+        this.blink(this.oView);
+    }
+
+    if(this.bViewOutline) {
+        this.initMasonry();
+
+        this.oView.find('.' + this.sClassItem).resize(function() {
+            $this.reloadMasonry();
+        });
+        this.oView.find('img.' + this.sClassItemImage).load(function() {
+            $this.reloadMasonry();
+        });
+
+        //--- Init Video Layout
+        if(this._sVideosAutoplay != 'off')
+            this.initVideos(this.oView);
+
+        //--- Blink (highlight) necessary items
+        this.blink(this.oView);
+    }
+
+    if(this.bViewItem) {
+        this.oView.find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight(this.sSP + '-overflow', function(oElement) {
+            $this.onFindOverflow(oElement);
+        });
+
+        //--- Init Video Layout
+        if(this._sVideosAutoplay != 'off')
+            this.initVideos(this.oView);
+    }
+
+    this.initFlickity();
+};
+
+BxTimelineView.prototype.initVideosAutoplay = function(oParent)
+{
+    var $this = this;
+
+    if(this._sVideosAutoplay == 'off')
+        return;
+
+    this.initVideos(oParent);
+
+    oParent.find('iframe').each(function() {
+        var sPlayer = $(this).attr('id');
+        if($this._oVapPlayers[sPlayer])
+            return;
+
+        var oPlayer = new playerjs.Player(this);
+        if($this._sVideosAutoplay == 'on_mute')
+            oPlayer.mute();
+
+        var fFixHeight = function () {
+            $('#' + sPlayer).height(($('#' + sPlayer).contents().find('video').height()) + 'px');
+        };
+        oPlayer.on('ready', fFixHeight);
+        oPlayer.on('play', fFixHeight);
+
+        $this._oVapPlayers[sPlayer] = oPlayer;
+    });
+};
+
+BxTimelineView.prototype.hideEvents = function(oEvents, fOffset)
+{
+    oEvents.each(function(iIndex, oElement) {
+        (iIndex >=3 && $(this).offset().top > $(window).scrollTop() + $(window).height() * fOffset ) && $(this).find('.bx-tl-item-type, .bx-tl-item-cnt').addClass('is-hidden');
+    });
+};
+
+BxTimelineView.prototype.showEvents = function(oEvents, fOffset)
+{
+    oEvents.each(function() {
+        ( $(this).offset().top <= $(window).scrollTop() + $(window).height() * fOffset && $(this).find('.bx-tl-item-type').hasClass('is-hidden') ) && $(this).find('.bx-tl-item-type, .bx-tl-item-cnt').removeClass('is-hidden').addClass('bounce-in');
+    });
+};
+
+BxTimelineView.prototype.playVideos = function(oEvents, fOffsetStart, fOffsetStop)
+{
+    var $this = this;
+
+    oEvents.each(function() {
+        $(this).find('iframe').each(function() {
+            var oFrame = $(this);
+            var oPlayer = $this._oVapPlayers[oFrame.attr('id')];
+            if(!oPlayer)
+                    return;
+
+            var iFrameTop = oFrame.offset().top;
+            var iFrameBottom = iFrameTop + oFrame.height();
+            var iWindowTop = $(window).scrollTop();
+            var iWindowHeight = $(window).height();
+            if(iFrameTop <= iWindowTop + iWindowHeight * fOffsetStart && iFrameBottom >= iWindowTop + iWindowHeight * fOffsetStop)
+                oPlayer.play();
+            else
+                oPlayer.pause();
+        });
+    });
+};
+
+BxTimelineView.prototype.changePage = function(oLink, iStart, iPerPage)
+{
+    var $this = this;
+
+    this.loadingInButton(oLink, true);
+
+    this._oRequestParams.start = iStart;
+    this._oRequestParams.per_page = iPerPage;
+    this._getPosts(oLink, function(oData) {
+    	$this.loadingInButton(oLink, false);
+
+    	var sItems = $.trim(oData.items);
+
+        if($this.bViewTimeline)
+            $this.oView.find('.' + $this.sClassItems).append($(sItems).hide()).find('.' + $this.sClassItem + ':hidden').bx_anim('show', $this._sAnimationEffect, $this._iAnimationSpeed, function() {
+                $(this).bxProcessHtml().find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight($this.sSP + '-overflow', function(oElement) {
+                    $this.onFindOverflow(oElement);
+                });
+
+                $this.initFlickity();
+
+                //--- Init Video Autoplay
+                $this.initVideosAutoplay($this.oView);
+            });
+
+        if($this.bViewOutline)
+            $this.appendMasonry($(sItems).bxProcessHtml(), function(oItems) {
+                oItems.find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight($this.sSP + '-overflow', function(oElement) {
+                    $this.onFindOverflow(oElement);
+                });
+
+                $this.initFlickity();
+
+                //--- Init Video Layout
+                if($this._sVideosAutoplay != 'off') 
+                    $this.initVideos($this.oView);
+            });
+
+    	if(oData && oData.load_more != undefined)
+            $this.oView.find('.' + $this.sSP + '-load-more-holder').html($.trim(oData.load_more));
+
+    	if(oData && oData.back != undefined)
+            $this.oView.find('.' + $this.sSP + '-back-holder').html($.trim(oData.back));
+
+    	if(oData && oData.empty != undefined)
+            $this.oView.find('.' + $this.sSP + '-empty-holder').html($.trim(oData.empty));
+    });
+};
+
+BxTimelineView.prototype.changeFilter = function(oLink)
+{
+    var sId = $(oLink).attr('id');
+    sId = sId.substr(sId.lastIndexOf('-') + 1, sId.length);
+
+    this.loadingInBlock(oLink, true);
+
+    this._oRequestParams.start = 0;
+    this._oRequestParams.filter = sId;
+    this._getPosts(oLink);
+};
+
+BxTimelineView.prototype.changeTimeline = function(oLink, iYear)
+{
+    this.loadingInBlock(oLink, true);
+
+    this._oRequestParams.start = 0;
+    this._oRequestParams.timeline = iYear;
+    this._getPosts(oLink);
+};
+
+BxTimelineView.prototype.showMore = function(oLink)
+{
+    var sClassOverflow = this.sSP + '-overflow';
+
+    $(oLink).parents('.' + this.sClassItem + ':first').find('.' + sClassOverflow).css('max-height', 'none').removeClass(sClassOverflow);
+    $(oLink).parents('.' + this.sSP + '-content-show-more:first').remove();
+
+    if(this.bViewOutline)
+        this.reloadMasonry();
+};
+
+BxTimelineView.prototype.showItem = function(oLink, iId, sMode, oParams)
+{
+    var oData = $.extend({}, this._getDefaultData(), {id: iId, mode: sMode}, (oParams != undefined ? oParams : {}));
+
+    $(".bx-popup-full-screen.bx-popup-applied:visible").dolPopupHide();
+
+    $(window).dolPopupAjax({
+        id: {
+            value: this._getHtmlId('item_popup', this._oRequestParams, false, false) + iId, 
+            force: true
+        },
+        url: bx_append_url_params(this._sActionsUrl + 'get_item_brief', oData),
+        closeOnOuterClick: false,
+        removeOnClose: true,
+        fullScreen: true
+    });
+
+    return false;
+};
+
+BxTimelineView.prototype.commentItem = function(oLink, sSystem, iId)
+{
+    var $this = this;
+    var oData = this._getDefaultData(oLink);
+    oData['system'] = sSystem;
+    oData['id'] = iId;
+
+    var oComments = $(oLink).parents('.' + this.sClassItem + ':first').find('.' + this.sClassItemComments);
+    if(oComments.children().length > 0) {
+    	oComments.bx_anim('toggle', this._sAnimationEffect, this._iAnimationSpeed);
+    	return;
+    }
+
+    if(oLink)
+    	this.loadingInItem(oLink, true);
+
+    jQuery.get (
+        this._sActionsUrl + 'get_comments',
+        oData,
+        function(oData) {
+            if(oLink)
+                $this.loadingInItem(oLink, false);
+
+            if(!oData.content)
+                return;
+
+            oComments.html($(oData.content).hide()).children(':hidden').bxProcessHtml().bx_anim('show', $this._sAnimationEffect, $this._iAnimationSpeed);
+        },
+        'json'
+    );
+};
+
+BxTimelineView.prototype.pinPost = function(oLink, iId, iWay)
+{
+    this._markPost(oLink, iId, iWay, 'pin');
+};
+
+BxTimelineView.prototype.onPinPost = function(oData)
+{
+    this._onMarkPost(oData, 'pin');
+};
+
+BxTimelineView.prototype.stickPost = function(oLink, iId, iWay)
+{
+    this._markPost(oLink, iId, iWay, 'stick');
+};
+
+BxTimelineView.prototype.onStickPost = function(oData)
+{
+    this._onMarkPost(oData, 'stick');
+};
+
+BxTimelineView.prototype.promotePost = function(oLink, iId, iWay)
+{
+    var $this = this;
+    var oData = this._getDefaultData();
+    oData['id'] = iId;
+
+    $(oLink).parents('.bx-popup-applied:first:visible').dolPopupHide({
+        onHide: function(oPopup) {
+            $(oPopup).remove();
+        }
+    });
+
+    var oLoadingContainer = $(this._getHtmlId('item', this._oRequestParams, false) + iId);
+
+    this.loadingInItem(oLoadingContainer, true);
+
+    $.post(
+        this._sActionsUrl + 'promote/',
+        oData,
+        function(oData) {
+            $this.loadingInItem(oLoadingContainer, false);
+
+            processJsonData(oData);
+        },
+        'json'
+    );
+};
+
+BxTimelineView.prototype.initFormEdit = function(sFormId)
+{
+    var $this = this;
+    var oForm = $('#' + sFormId);
+
+    autosize(oForm.find('textarea'));
+    oForm.ajaxForm({
+        dataType: "json",
+        beforeSubmit: function (formData, jqForm, options) {
+            window[$this._sObjName].beforeFormEditSubmit(oForm);
+        },
+        success: function (oData) {
+            window[$this._sObjName].afterFormEditSubmit(oForm, oData);
+        }
+    });
+};
+
+BxTimelineView.prototype.beforeFormEditSubmit = function(oForm)
+{
+    this.loadingInButton($(oForm).children().find(':submit'), true);
+};
+
+BxTimelineView.prototype.afterFormEditSubmit = function (oForm, oData)
+{
+    var $this = this;
+    var fContinue = function() {
+        if(oData && oData.id != undefined) {
+            var iId = parseInt(oData.id);
+            if(iId <= 0) 
+                return;
+
+            $this._getPost($this.oView, iId, $this._oRequestParams);
+            return;
+        }
+
+        if(oData && oData.form != undefined && oData.form_id != undefined) {
+            $('#' + oData.form_id).replaceWith(oData.form);
+            $this.initFormEdit(oData.form_id);
+
+            return;
+        }
+    };
+
+    this.loadingInButton($(oForm).children().find(':submit'), false);
+
+    if(oData && oData.message != undefined)
+        bx_alert(oData.message, fContinue);
+    else
+        fContinue();
+};
+
+BxTimelineView.prototype.editPost = function(oLink, iId)
+{
+    var $this = this;
+    var oData = this._getDefaultData(oLink);
+    oData['id'] = iId;
+
+    $(oLink).parents('.bx-popup-applied:first:visible').dolPopupHide();
+
+    var oItem = this.oView.find(this._getHtmlId('item', this._oRequestParams, false) + iId);
+
+    var oContent = oItem.find('.' + this.sClassItemContent);
+    if(oContent.find('form').length) {
+        $(oContent).bx_anim('hide', this._sAnimationEffect, this._iAnimationSpeed, function() {
+            $(this).html($this._oSaved[iId]).bx_anim('show', $this._sAnimationEffect, $this._iAnimationSpeed);
+        });
+        return;
+    }
+    else
+        this._oSaved[iId] = oContent.html();
+
+    this.loadingInItem(oItem, true);
+
+    jQuery.post (
+        this._sActionsUrl + 'get_edit_form/' + iId + '/',
+        oData,
+        function (oData) {
+            processJsonData(oData);
+        },
+        'json'
+    );
+};
+
+BxTimelineView.prototype.onEditPost = function(oData)
+{
+    var $this = this;
+
+    if(!oData || !oData.id)
+        return;
+
+    var oItem = $(this._getHtmlId('item', this._oRequestParams, false) + oData.id);
+
+    this.loadingInItem(oItem, false);
+
+    if(oData && oData.form != undefined && oData.form_id != undefined) {
+        oItem.find('.' + this.sClassItemContent).bx_anim('hide', this._sAnimationEffect, this._iAnimationSpeed, function() {
+            $(this).html(oData.form).bx_anim('show', $this._sAnimationEffect, $this._iAnimationSpeed, function() {
+                $this.initFormEdit(oData.form_id);
+            });
+        });
+    }
+};
+
+BxTimelineView.prototype.editPostCancel = function(oButton, iId)
+{
+    this.editPost(oButton, iId);
+};
+
+BxTimelineView.prototype.deletePost = function(oLink, iId)
+{
+    var $this = this;
+
+    $(oLink).parents('.bx-popup-applied:first:visible').dolPopupHide();
+
+    bx_confirm('', function() {
+        var oData = $this._getDefaultData();
+        oData['id'] = iId;
+
+        $this.loadingInItem($($this._getHtmlId('item', $this._oRequestParams, false) + iId), true);
+
+        $.post(
+            $this._sActionsUrl + 'delete/',
+            oData,
+            function(oData) {
+                processJsonData(oData);
+            },
+            'json'
+        );
+    });
+};
+
+BxTimelineView.prototype.onDeletePost = function(oData)
+{
+    var $this = this;
+    var oItem = $(this._getHtmlId('item', this._oRequestParams, false) + oData.id);
+
+    //--- Delete from 'Timeline' (if available)
+    if(this.bViewTimeline) {
+        oItem.bx_anim('hide', this._sAnimationEffect, this._iAnimationSpeed, function() {
+            $(this).remove();
+
+            if($this.oView.find('.' + $this.sClassItem).length == 0) {
+                $this.oView.find('.' + $this.sClassDividerToday).hide();
+                $this.oView.find('.' + $this.sSP + '-load-more').hide();
+                $this.oView.find('.' + $this.sSP + '-empty').show();
+            }
+        });
+
+        return;
+    }
+
+    //--- Delete from 'Outline' (if available)
+    if(this.bViewOutline) {
+        oItem.bx_anim('hide', this._sAnimationEffect, this._iAnimationSpeed, function() {
+            $(this).remove();
+
+            if($this.oView.find('.' + $this.sClassItem).length == 0) {
+                $this.destroyMasonry();
+
+                $this.oView.find('.' + $this.sSP + '-load-more').hide();
+                $this.oView.find('.' + $this.sSP + '-empty').show();
+            } 
+            else
+                $this.reloadMasonry();
+        });
+
+        return;
+    }
+
+    //--- Delete from 'View Item' page.
+    if(this._sReferrer.length != 0)
+        document.location = this._sReferrer;
+};
+
+BxTimelineView.prototype.onConnect = function(eElement, oData)
+{
+    $(eElement).remove();
+};
+
+/*----------------------------*/
+/*--- Live Updates methods ---*/
+/*----------------------------*/
+BxTimelineView.prototype.goTo = function(oLink, sGoToId, sBlinkIds, onLoad)
+{
+    var $this = this;
+
+    this.loadingInPopup(oLink, true);
+
+    this._oRequestParams.start = 0;
+    this._oRequestParams.blink = sBlinkIds;
+    this._getPosts(this.oView, function(oData) {
+        $this.loadingInPopup(oLink, false);
+
+        $(oLink).parents('.bx-popup-applied:first:visible').dolPopupHide();
+
+        oData.go_to = sGoToId;
+        processJsonData(oData);
+    });
+};
+
+BxTimelineView.prototype.goToBtn = function(oLink, sGoToId, sBlinkIds, onLoad)
+{
+    var $this = this;
+
+    this.loadingInButton(oLink, true);
+
+    this._oRequestParams.start = 0;
+    this._oRequestParams.blink = sBlinkIds;
+    this._getPosts(this.oView, function(oData) {
+        oData.go_to = sGoToId;
+        processJsonData(oData);
+
+        $this.loadingInButton(oLink, false);
+        $(oLink).parents('.' + $this.sSP + '-live-update-button:first').remove();
+
+        $this.resumeLiveUpdates();
+    });
+};
+
+/*
+ * Show only one live update notification for all new events.
+ * 
+ * Note. oData.count_old and oData.count_new are also available and can be checked or used in notification popup.  
+ */
+BxTimelineView.prototype.showLiveUpdate = function(oData)
+{
+    if(!oData.code)
+        return;
+
+    var oButton = $(oData.code);
+    var sId = oButton.attr('id');
+    $('#' + sId).remove();
+
+    oButton.prependTo(this.oView);
+};
+
+/*
+ * Show separate live update notification for each new Event.
+ * 
+ * Note. This way to display live update notifications isn't used for now. 
+ * See BxTimelineView::showLiveUpdate method instead.
+ * 
+ * Note. oData.count_old and oData.count_new are also available and can be checked or used in notification popup.  
+ */
+BxTimelineView.prototype.showLiveUpdates = function(oData)
+{
+    if(!oData.code)
+        return;
+
+    var $this = this;
+
+    var oItems = $(oData.code);
+    var sId = oItems.attr('id');
+    $('#' + sId).remove();
+
+    oItems.prependTo('body').dolPopup({
+        position: 'fixed',
+        left: '1rem',
+        top: 'auto',
+        bottom: '1rem',
+        fog: false,
+        onBeforeShow: function() {
+        },
+        onBeforeHide: function() {
+        },
+        onShow: function() {
+            setTimeout(function() {
+                $('.bx-popup-chain.bx-popup-applied:visible:first').dolPopupHide();
+            }, 5000);
+        },
+        onHide: function() {
+            $this.resumeLiveUpdates();
+        }
+    });
+};
+
+BxTimelineView.prototype.previousLiveUpdate = function(oLink)
+{
+    var fPrevious = function() {
+        var sClass = 'bx-popup-chain-item';
+        $(oLink).parents('.' + sClass + ':first').hide().prev('.' + sClass).show();
+    };
+
+    if(!this.pauseLiveUpdates(fPrevious));
+        fPrevious();
+};
+
+BxTimelineView.prototype.hideLiveUpdate = function(oLink)
+{
+    $(oLink).parents('.bx-popup-applied:visible:first').dolPopupHide();
+};
+
+BxTimelineView.prototype.resumeLiveUpdates = function(onLoad)
+{
+    if(!this._bLiveUpdatePaused)
+        return false;
+
+    var $this = this;
+    this.changeLiveUpdates('resume_live_update', function() {
+        $this._bLiveUpdatePaused = false;
+
+        if(typeof onLoad == 'function')
+            onLoad();
+    });
+
+    return true;
+};
+
+BxTimelineView.prototype.pauseLiveUpdates = function(onLoad)
+{
+    if(this._bLiveUpdatePaused)
+        return false;
+
+    var $this = this;
+    this.changeLiveUpdates('pause_live_update', function() {
+        $this._bLiveUpdatePaused = true;
+
+        if(typeof onLoad == 'function')
+            onLoad();
+    });
+
+    return true;
+};
+
+BxTimelineView.prototype.changeLiveUpdates = function(sAction, onLoad)
+{
+    var $this = this;
+    var oParams = this._getDefaultActions();
+    oParams['action'] = sAction;
+
+    jQuery.get(
+        this._sActionsUrl + sAction + '/',
+        oParams,
+        function() {
+            if(typeof onLoad == 'function')
+                onLoad();
+        }
+    );
+};
+
+BxTimelineView.prototype.blink = function(oParent)
+{
+	oParent.find('.' + this.sClassBlink + '-plate:visible').animate({
+		opacity: 0
+	}, 
+	5000, 
+	function() {
+		oParent.find('.' + this.sClassBlink).removeClass(this.sClassBlink);
+	});
+};
+
+
+/*------------------------------------*/
+/*--- Internal (protected) methods ---*/
+/*------------------------------------*/
+BxTimelineView.prototype._getPosts = function(oElement, onComplete)
+{
+    var $this = this;
+    var oData = this._getDefaultData(oElement);
+
+    jQuery.get(
+        this._sActionsUrl + 'get_posts/',
+        oData,
+        function(oData) {
+            if(typeof onComplete === 'function')
+                return onComplete(oData);
+
+            $this.loadingInBlock(oElement, false);
+
+            processJsonData(oData);
+        },
+        'json'
+    );
+};
+
+BxTimelineView.prototype._onGetPosts = function(oData)
+{
+    var $this = this;
+
+    var onComplete = function() {
+        if(oData && oData.go_to != undefined)
+            location.hash = oData.go_to;
+
+        if(oData && oData.load_more != undefined)
+            $this.oView.find('.' + $this.sSP + '-load-more-holder').html($.trim(oData.load_more));
+
+        if(oData && oData.back != undefined)
+            $this.oView.find('.' + $this.sSP + '-back-holder').html($.trim(oData.back));
+
+        if(oData && oData.empty != undefined)
+            $this.oView.find('.' + $this.sSP + '-empty-holder').html($.trim(oData.empty));
+    };
+
+    if(oData && oData.items != undefined) {
+        var sItems = $.trim(oData.items);
+
+        if(this.bViewTimeline) {
+            var oItems = this.oView.find('.' + this.sClassItems);
+            oItems.html(sItems).bxProcessHtml();
+
+            this.blink(oItems);
+            this.initFlickity();
+
+            onComplete();
+            return;
+        }
+
+        if(this.bViewOutline) {
+            oItems = this.oView.find('.' + this.sClassItems);
+            oItems.html(sItems).bxProcessHtml();
+
+            if(this.isMasonry())
+                this.destroyMasonry();
+
+            if(!this.isMasonryEmpty())
+                this.initMasonry();
+
+            this.blink(oItems);
+            this.initFlickity();
+
+            onComplete();
+            return;
+        }
+    }
+};
+
+BxTimelineView.prototype._onGetPost = function(oData)
+{
+    if(!$.trim(oData.item).length) 
+        return;
+
+    var $this = this;
+    var sItem = this._getHtmlId('item', this._oRequestParams, false) + oData.id;
+    this.oView.find(sItem).replaceWith($(oData.item).bxProcessHtml());
+    this.oView.find(sItem).find('.bx-tl-item-text .bx-tl-content').checkOverflowHeight(this.sSP + '-overflow', function(oElement) {
+        $this.onFindOverflow(oElement);
+    });
+};
+
+BxTimelineView.prototype._markPost = function(oLink, iId, iWay, sAction)
+{
+    var oData = this._getDefaultData();
+    oData['id'] = iId;
+
+    $(oLink).parents('.bx-popup-applied:first:visible').dolPopupHide({
+        onHide: function(oPopup) {
+            $(oPopup).remove();
+        }
+    });
+
+    this.loadingInItem($(this._getHtmlId('item', this._oRequestParams, false) + iId), true);
+
+    $.post(
+        this._sActionsUrl + sAction + '/',
+        oData,
+        function(oData) {
+        	processJsonData(oData);
+        },
+        'json'
+    );
+};
+
+BxTimelineView.prototype._onMarkPost = function(oData, sAction)
+{
+    var $this = this;
+    var sItem = this._getHtmlId('item', this._oRequestParams, false) + oData.id;
+
+    this._oRequestParams.start = 0;
+
+    //--- Mark on Timeline (if available)
+    if(this.bViewTimeline)
+        this._getPosts(this.oView, function(oData) {
+            $(sItem).bx_anim('hide', $this._sAnimationEffect, $this._iAnimationSpeed, function() {
+                $(this).remove();
+
+                processJsonData(oData);
+            });
+        });
+
+    //--- Mark on Outline (if available)
+    if(this.bViewOutline)
+        this._getPosts(this.oView, function(oData) {
+            $this.removeMasonry(sItem, function() {
+                processJsonData(oData);
+            });
+        });
+};

+ 254 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/css/view-media-desktop.css

@@ -0,0 +1,254 @@
+
+/*--- View Block Style ---*/
+.bx-media-desktop .bx-tl-grid-sizer {
+    width: 33.3%;
+}
+.bx-media-desktop .bx-layout-column-wide .bx-tl-grid-sizer,
+.bx-media-desktop .bx-layout-column-half .bx-tl-grid-sizer {
+   width: 50%;
+}
+.bx-media-desktop .bx-layout-column-thin .bx-tl-grid-sizer {
+   width: 100%;
+}
+
+.bx-media-desktop .bx-tl-grid-item-sizer {
+   width: 33.3%;
+}
+.bx-media-desktop .bx-layout-column-wide .bx-tl-grid-item-sizer,
+.bx-media-desktop .bx-layout-column-half .bx-tl-grid-item-sizer {
+    width: 50%;
+}
+.bx-media-desktop .bx-layout-column-thin .bx-tl-grid-item-sizer {
+    width: 100%;
+}
+
+/*--- Timeline Item Style ---*/
+.bx-media-desktop div.bx-tl-view-timeline div.bx-tl-item-cnt {
+    position: relative;
+
+    margin: 0px 0px 0px 56px;
+    margin: 0px 0px 0px 3.5rem;
+}
+.bx-media-desktop .bx-layout-column-fullwidth div.bx-tl-view-timeline div.bx-tl-items::before {
+    left: 50%;
+    margin-left: -2px;
+    margin-left: -0.125rem;
+} 
+.bx-media-desktop .bx-layout-column-fullwidth div.bx-tl-view-timeline div.bx-tl-item div.bx-tl-item-type {
+    left: 50%;
+    margin-left: -20px;
+    margin-left: -1.25rem;
+} 
+.bx-media-desktop .bx-layout-column-fullwidth div.bx-tl-view-timeline div.bx-tl-item div.bx-tl-item-cnt {
+    width: 45%;
+}
+.bx-media-desktop .bx-layout-column-fullwidth div.bx-tl-view-timeline div.bx-tl-item:nth-child(2n + 1) div.bx-tl-item-cnt {
+    margin: 0px 56px 0px 0p;
+    margin: 0px 3.5rem 0px 0px;
+}
+.bx-media-desktop .bx-layout-column-fullwidth div.bx-tl-view-timeline div.bx-tl-item:nth-child(2n) div.bx-tl-item-cnt {
+    float: right;
+
+    margin: 0px 0px 0px 56px;
+    margin: 0px 0px 0px 3.5rem;
+}
+
+/*--- Animation ---*/
+.bx-media-desktop.cssanimations div.bx-tl-view-timeline .bx-tl-item-type.is-hidden {
+    visibility: hidden;
+}
+.bx-media-desktop.cssanimations div.bx-tl-view-timeline .bx-tl-item-type.bounce-in {
+    visibility: visible;
+    -webkit-animation: cd-bounce-1 0.6s;
+    -moz-animation: cd-bounce-1 0.6s;
+    animation: cd-bounce-1 0.6s;
+}
+.bx-media-desktop.cssanimations div.bx-tl-view-timeline .bx-tl-item-cnt.is-hidden {
+    visibility: hidden;
+}
+.bx-media-desktop.cssanimations div.bx-tl-view-timeline .bx-tl-item-cnt.bounce-in {
+    visibility: visible;
+    -webkit-animation: cd-bounce-2 0.6s;
+    -moz-animation: cd-bounce-2 0.6s;
+    animation: cd-bounce-2 0.6s;
+}
+/* inverse bounce effect on even content blocks */
+.bx-media-desktop.cssanimations .bx-layout-column-fullwidth div.bx-tl-view-timeline .bx-tl-item:nth-child(even) .bx-tl-item-cnt.bounce-in {
+    -webkit-animation: cd-bounce-2-inverse 0.6s;
+    -moz-animation: cd-bounce-2-inverse 0.6s;
+    animation: cd-bounce-2-inverse 0.6s;
+}
+
+/*--- Animation ---*/
+@-webkit-keyframes cd-bounce-1 {
+  0% {
+    opacity: 0;
+    -webkit-transform: scale(0.5);
+  }
+
+  60% {
+    opacity: 1;
+    -webkit-transform: scale(1.2);
+  }
+
+  100% {
+    -webkit-transform: scale(1);
+  }
+}
+@-moz-keyframes cd-bounce-1 {
+  0% {
+    opacity: 0;
+    -moz-transform: scale(0.5);
+  }
+
+  60% {
+    opacity: 1;
+    -moz-transform: scale(1.2);
+  }
+
+  100% {
+    -moz-transform: scale(1);
+  }
+}
+@keyframes cd-bounce-1 {
+  0% {
+    opacity: 0;
+    -webkit-transform: scale(0.5);
+    -moz-transform: scale(0.5);
+    -ms-transform: scale(0.5);
+    -o-transform: scale(0.5);
+    transform: scale(0.5);
+  }
+
+  60% {
+    opacity: 1;
+    -webkit-transform: scale(1.2);
+    -moz-transform: scale(1.2);
+    -ms-transform: scale(1.2);
+    -o-transform: scale(1.2);
+    transform: scale(1.2);
+  }
+
+  100% {
+    -webkit-transform: scale(1);
+    -moz-transform: scale(1);
+    -ms-transform: scale(1);
+    -o-transform: scale(1);
+    transform: scale(1);
+  }
+}
+
+@-webkit-keyframes cd-bounce-2 {
+  0% {
+    opacity: 0;
+    -webkit-transform: translateX(-100px);
+  }
+
+  60% {
+    opacity: 1;
+    -webkit-transform: translateX(20px);
+  }
+
+  100% {
+    -webkit-transform: translateX(0);
+  }
+}
+@-moz-keyframes cd-bounce-2 {
+  0% {
+    opacity: 0;
+    -moz-transform: translateX(-100px);
+  }
+
+  60% {
+    opacity: 1;
+    -moz-transform: translateX(20px);
+  }
+
+  100% {
+    -moz-transform: translateX(0);
+  }
+}
+@keyframes cd-bounce-2 {
+  0% {
+    opacity: 0;
+    -webkit-transform: translateX(-100px);
+    -moz-transform: translateX(-100px);
+    -ms-transform: translateX(-100px);
+    -o-transform: translateX(-100px);
+    transform: translateX(-100px);
+  }
+
+  60% {
+    opacity: 1;
+    -webkit-transform: translateX(20px);
+    -moz-transform: translateX(20px);
+    -ms-transform: translateX(20px);
+    -o-transform: translateX(20px);
+    transform: translateX(20px);
+  }
+
+  100% {
+    -webkit-transform: translateX(0);
+    -moz-transform: translateX(0);
+    -ms-transform: translateX(0);
+    -o-transform: translateX(0);
+    transform: translateX(0);
+  }
+}
+@-webkit-keyframes cd-bounce-2-inverse {
+  0% {
+    opacity: 0;
+    -webkit-transform: translateX(100px);
+  }
+
+  60% {
+    opacity: 1;
+    -webkit-transform: translateX(-20px);
+  }
+
+  100% {
+    -webkit-transform: translateX(0);
+  }
+}
+@-moz-keyframes cd-bounce-2-inverse {
+  0% {
+    opacity: 0;
+    -moz-transform: translateX(100px);
+  }
+
+  60% {
+    opacity: 1;
+    -moz-transform: translateX(-20px);
+  }
+
+  100% {
+    -moz-transform: translateX(0);
+  }
+}
+@keyframes cd-bounce-2-inverse {
+  0% {
+    opacity: 0;
+    -webkit-transform: translateX(100px);
+    -moz-transform: translateX(100px);
+    -ms-transform: translateX(100px);
+    -o-transform: translateX(100px);
+    transform: translateX(100px);
+  }
+
+  60% {
+    opacity: 1;
+    -webkit-transform: translateX(-20px);
+    -moz-transform: translateX(-20px);
+    -ms-transform: translateX(-20px);
+    -o-transform: translateX(-20px);
+    transform: translateX(-20px);
+  }
+
+  100% {
+    -webkit-transform: translateX(0);
+    -moz-transform: translateX(0);
+    -ms-transform: translateX(0);
+    -o-transform: translateX(0);
+    transform: translateX(0);
+  }
+}

+ 556 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/css/view.css

@@ -0,0 +1,556 @@
+/*--- General section ---*/
+
+
+/*--- View Block Style ---*/
+div.bx-tl-view {
+	position: relative;
+}
+
+.bx-tl-grid-sizer {
+	width: 100%;
+}
+.bx-tl-grid-item-sizer {
+    width: 100%;
+}
+
+.bx-tl-view-sizer {
+	width: 100%;
+}
+.bx-tl-view-sizer div.bx-tl-item-ind {
+	padding: 0px;
+}
+div.bx-tl-items-wrapper {
+	position: relative;
+}
+
+/*--- Back Style ---*/
+
+
+/*--- Load More Style ---*/
+div.bx-tl-view-timeline div.bx-tl-load-more {
+	padding-top: 0px;
+}
+
+div.bx-tl-jump-to {
+	position: relative;
+	float: right;
+	line-height: 36px;
+	line-height: 2.25rem;
+}
+
+
+/*--- Divider Styles ---*/
+div.bx-tl-divider {
+    position: relative;
+}
+
+div.bx-tl-divider-cnt {
+    position: relative;
+    box-sizing: border-box;
+
+    width: 100%;
+
+    border: 2px solid rgba(0, 0, 0, 0.1);
+    border-radius: 20px;
+    -moz-border-radius: 20px;
+    -webkit-border-radius: 20px;
+    background-color: rgba(0, 0, 0, 0.1);
+    
+    text-align: center;
+    text-transform: uppercase;
+    font-weight: bold;
+    color: #ffffff;
+}
+
+/*--- Item Style ---*/
+div.bx-tl-item,
+div.bx-tl-item-cnt {
+    position: relative;
+}
+
+div.bx-tl-blink-plate {
+    position: absolute;
+    display: none;
+    top: -10px;
+    left: -10px;
+    width: 100%;
+    height: 100%;
+    padding: 10px;
+    background-color: rgb(255, 244, 213);
+    background-color: rgba(255, 234, 193, 0.5);
+}
+
+div.bx-tl-item.bx-tl-blink div.bx-tl-blink-plate {
+    display: block;
+}
+
+/*--- Item Owner Style ---*/
+div.bx-tl-item div.bx-tl-item-owner {
+    position: relative;
+	text-align: left;
+}
+div.bx-tl-item div.bx-tl-owner-avatar {
+    position: absolute;
+    top: 0px;
+    left: 0px;
+}
+div.bx-tl-item div.bx-tl-owner-info {
+    display: -webkit-flex;
+    display: flex;
+    -webkit-align-items: center;
+    align-items: center;
+}
+div.bx-tl-item div.bx-tl-item-owner.bx-tl-io-with-actions div.bx-tl-owner-info {
+    margin-right: 68px;
+    margin-right: 4.25rem;
+}
+div.bx-tl-item div.bx-tl-owner-name {
+    text-overflow: ellipsis;
+    overflow: hidden;
+}
+div.bx-tl-item div.bx-tl-owner-name > * {
+    vertical-align: middle;
+}
+div.bx-tl-item div.bx-tl-owner-name a.bx-tl-owner-name,
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-timeline-owner-name a.bx-tl-ton-item {
+    font-weight: 700;
+}
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-timeline-owner-name .bx-tl-ton-div:first-child {
+    display: none;
+}
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-date,
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-pinned .sys-icon,
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-sticked .sys-icon,
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-hot .sys-icon {
+    color: rgba(40, 60, 80, 0.5);
+}
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-pinned .sys-icon,
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-sticked .sys-icon,
+div.bx-tl-item div.bx-tl-owner-name .bx-tl-hot .sys-icon {
+    cursor: default;
+}
+div.bx-tl-item div.bx-tl-owner-actions {
+    position: absolute;
+    top: 0px;
+    right: 0px;
+	line-height: 48px;
+	line-height: 3rem;
+}
+div.bx-tl-item div.bx-tl-owner-actions .bx-btn {
+    display: inline-block;
+	float: none;
+	vertical-align: middle;
+}
+
+/*--- Item Meta Info Style ---*/
+.bx-tl-item-meta {
+    white-space: nowrap;
+    overflow: hidden;
+    text-overflow: ellipsis;
+    text-align: left;
+}
+.bx-tl-item-meta ul.bx-menu-custom.bx-menu-hor {
+    position: relative;
+    display: inline-block;
+}
+.bx-tl-item-meta ul.bx-menu-custom.bx-menu-hor > li > span {
+        margin-right: 0;
+}
+.bx-tl-item-meta ul.bx-menu-custom li:first-child .bx-tl-item-meta-div {
+    display: none;
+}
+.bx-tl-item-meta ul.bx-menu-custom li .bx-tl-item-meta-item,
+.bx-tl-item-meta ul.bx-menu-custom li .bx-tl-item-meta-div,
+.bx-tl-item-meta ul.bx-menu-custom li .bx-btn {
+    position: relative;
+    float: none;
+    display: inline-block;
+    vertical-align: middle;
+}
+
+/*--- Item Content Style ---*/
+div.bx-tl-item-content {
+	position: relative;
+    text-align: left;
+}
+div.bx-tl-item-content form {
+	padding-left: 1rem;
+	padding-right: 1rem;
+}
+div.bx-tl-item-content div.bx-tl-title {
+	text-overflow: ellipsis;
+    overflow: hidden;
+}
+div.bx-tl-item-content div.bx-tl-content iframe {
+	width: 100%;
+}
+div.bx-tl-item-text div.bx-tl-content {
+	position: relative;
+    max-height: 250px;
+
+	text-overflow: ellipsis;
+    overflow: hidden;
+}
+div.bx-tl-item-text div.bx-tl-content.bx-tl-overflow {
+    border-bottom: 1px solid rgba(0, 0, 0, 0.2);
+}
+div.bx-tl-item-text div.bx-tl-content-show-more {
+    position: relative;
+
+    text-transform: lowercase;
+    text-align: center;
+}
+div.bx-tl-item-text div.bx-tl-content p {
+	margin-top: 10px;
+	margin-top: 0.625rem;
+	margin-bottom: 10px;
+	margin-bottom: 0.625rem;
+}
+div.bx-tl-item-text div.bx-tl-content img {
+	max-width: 100%;
+	height: auto;
+}
+
+/*--- Item Images Style ---*/
+div.bx-tl-item div.bx-tl-item-images {
+    position: relative;
+    white-space: nowrap;
+    overflow: hidden;
+}
+div.bx-tl-item div.bx-tl-item-image {
+    display: inline-block;
+}
+
+div.bx-tl-item div.bx-tl-item-activity .bx-menu-custom {
+    position: realtive;
+    display: -webkit-flex;
+    display: flex;
+    -webkit-justify-content: space-between;
+    justify-content: space-between;
+}
+div.bx-tl-item div.bx-tl-item-activity .bx-menu-custom::before,
+div.bx-tl-item div.bx-tl-item-activity .bx-menu-custom::after {
+    display: none;
+}
+div.bx-tl-item div.bx-tl-item-activity .bx-menu-custom li > span {
+    margin-right: 0;
+}
+div.bx-tl-item div.bx-tl-item-activity .bx-menu-custom li > span img {
+    background-size: contain;
+    background-repeat: no-repeat;
+    background-position: center center;
+}
+
+/*--- Item Style: Timeline ---*/
+div.bx-tl-view-timeline div.bx-tl-items:before {
+    content: '';
+    position: absolute;
+    top: 0px;
+    left: 18px;
+    left: 1.125rem;
+    width: 4px;
+    height: 100%;
+
+    background: rgba(0, 0, 0, 0.1);
+}
+div.bx-tl-view-timeline div.bx-tl-items,
+div.bx-tl-view-search div.bx-tl-items,
+div.bx-tl-view-item div.bx-tl-items {
+	margin-left: 0px;
+	margin-right: 0px;
+}
+div.bx-tl-view-timeline div.bx-tl-item,
+div.bx-tl-view-search div.bx-tl-item,
+div.bx-tl-view-item div.bx-tl-item {
+    position: relative;
+}
+div.bx-tl-view-timeline div.bx-tl-item-type {
+	position: absolute;
+    top: 0px;
+    left: 0px;
+}
+div.bx-tl-view-timeline div.bx-tl-item-circle {
+	width: 40px;
+    width: 2.5rem;
+    height: 40px;
+    height: 2.5rem;
+
+	background-color: #ffffff;
+	background-clip: padding-box;
+	border-radius: 5rem;
+	box-shadow: inset 0 0 0 3px rgba(0, 0, 0, 0.1);
+
+    text-align: center;
+    color: #999999;
+	
+	overflow: hidden;
+}
+div.bx-tl-view-timeline div.bx-tl-item-circle .sys-icon {
+	display: block;
+
+	margin-left: auto;
+	margin-right: auto;
+
+	width: 40px;
+    width: 2.5rem;
+    height: 40px;
+    height: 2.5rem;
+
+	text-align: center;
+
+	line-height: 38px;
+	line-height: 2.375rem;
+    font-size: 20px;
+	font-size: 1.25rem;
+}
+
+
+/*--- Item Style: Outline ---*/
+div.bx-tl-view-outline div.bx-tl-item {
+	position: relative;
+}
+div.bx-tl-view-outline div.bx-tl-item div.bx-tl-item-owner.bx-tl-io-with-actions div.bx-tl-owner-info {
+    margin-right: 48px;
+    margin-right: 3.0rem;
+}
+div.bx-tl-view-outline div.bx-tl-item-ind {
+	position: relative;
+}
+
+/*+++ Item Text +++*/
+div.bx-tl-view-outline div.bx-tl-item-text div.bx-tl-title {
+	font-weight: bold;
+}
+div.bx-tl-view-outline div.bx-tl-content-show-more a {
+	font-weight: bold;
+}
+
+/*+++ Item Image +++*/
+div.bx-tl-view-search div.bx-tl-item-images {
+	margin-left: 0px;
+	margin-right: 0px;
+}
+div.bx-tl-view-search div.bx-tl-item-image {
+	margin-right: 2px;
+	margin-right: 0.125rem;
+}
+div.bx-tl-view-timeline div.bx-tl-item-image,
+div.bx-tl-view-outline div.bx-tl-item-image,
+div.bx-tl-view-item div.bx-tl-item-image {
+    width: 100%;
+    text-align: center;
+    overflow: hidden;
+}
+div.bx-tl-view-search div.bx-tl-item-image img {
+    height: 12.5rem;
+}
+div.bx-tl-view-timeline div.bx-tl-item-images.bx-tl-ii-gallery div.bx-tl-item-image img,
+div.bx-tl-view-item div.bx-tl-item-images.bx-tl-ii-gallery div.bx-tl-item-image img,
+div.bx-tl-view-timeline div.bx-tl-item-images.bx-tl-ii-single div.bx-tl-item-image img,
+div.bx-tl-view-item  div.bx-tl-item-images.bx-tl-ii-single div.bx-tl-item-image img {
+    position: relative;
+    display: block;
+    max-width: 100%;
+    margin-left: auto;
+    margin-right: auto;
+}
+div.bx-tl-view-outline div.bx-tl-item-image img {
+    max-width: 100%;
+    object-fit: cover;
+    object-position: center center;
+}
+
+/*+++ Item Video +++*/
+div.bx-tl-view-timeline div.bx-tl-item-video,
+div.bx-tl-view-outline div.bx-tl-item-video,
+div.bx-tl-view-item div.bx-tl-item-video {
+    width: 100%;
+}
+.bx-tl-video-iframe {
+    width: 100%;
+    border: none;
+}
+div.bx-tl-view div.bx-tl-item-videos.bx-tl-iv-gallery div.bx-tl-item-video video,
+div.bx-tl-view div.bx-tl-item-videos.bx-tl-iv-single div.bx-tl-item-video video {
+    display: block;
+    max-width: 100%;
+    margin-left: auto;
+    margin-right: auto;
+}
+
+/*+++ Item Attachment +++*/
+div.bx-tl-view-timeline div.bx-tl-item-attachment,
+div.bx-tl-view-outline div.bx-tl-item-attachment,
+div.bx-tl-view-item div.bx-tl-item-attachment {
+    position: relative;
+    display: -webkit-flex;
+    display: flex;
+    -webkit-justify-content: center;
+    justify-content: center;  
+
+    width: 100%;
+}
+div.bx-tl-view-timeline div.bx-tl-item-attachments.bx-tl-ia-gallery div.bx-tl-item-attachment img,
+div.bx-tl-view-item div.bx-tl-item-attachments.bx-tl-ia-gallery div.bx-tl-item-attachment img {
+    position: relative;
+    display: block;
+    max-width: 100%;
+    margin-left: auto;
+    margin-right: auto;
+}
+div.bx-tl-view-outline div.bx-tl-item-attachment img {
+    max-width: 100%;
+    object-fit: cover;
+    object-position: center center;
+}
+div.bx-tl-view-search div.bx-tl-item-attachment img {
+    height: 12.5rem;
+}
+
+div.bx-tl-view-timeline div.bx-tl-item-attachment video,
+div.bx-tl-view-outline div.bx-tl-item-attachment video,
+div.bx-tl-view-item div.bx-tl-item-attachment video {
+    display: block;
+    max-width: 100%;
+    margin-left: auto;
+    margin-right: auto;
+}
+
+/*+++ Slider Styles  +++*/
+div.bx-tl-item-images .flickity-slider,
+div.bx-tl-item-videos .flickity-slider,
+div.bx-tl-item-attachments .flickity-slider {
+    display: -webkit-flex;
+    display: flex;
+    -webkit-align-items: center;
+    align-items: center;
+}
+
+/*+++ Item Link +++*/
+div.bx-tl-view-outline div.bx-tl-item-link {
+	text-align: center;
+}
+div.bx-tl-view-outline div.bx-tl-il-thumbnail img {
+	width: 100%;
+	max-width: 100px;
+	height: 100%;
+	max-height: 100px;
+}
+div.bx-tl-view-outline div.bx-tl-il-embed iframe,
+div.bx-tl-view-timeline div.bx-tl-il-embed iframe {
+    width: 100%;
+}
+
+/*+++ Item Reposted +++*/
+div.bx-tl-view-outline div.bx-tl-reposted div.bx-tl-item-text {
+	padding-left: 5px;
+	padding-left: 0.3rem;
+
+	border-left: 1px solid #999999;
+	border-left: 0.07rem solid #999999;
+}
+div.bx-tl-view-outline div.bx-tl-reposted div.bx-tl-title {
+	font-size: 1.0rem;
+}
+div.bx-tl-view-outline div.bx-tl-reposted div.bx-tl-title a {
+	color: #999999;
+}
+div.bx-tl-view-outline div.bx-tl-reposted div.bx-tl-content {
+	font-size: 0.875rem;
+	color: #999999;
+}
+
+
+/*--- Item Brief Style ---*/
+div.bx-tl-bview-image {
+    text-align: center;
+}
+div.bx-tl-bview-image img {
+    max-width: 100%;
+}
+
+
+/*--- Empty Style ---*/
+div.bx-tl-empty div.bx-msg-box-container {
+    margin-top: 0px;
+    margin-bottom: 0px;
+}
+
+
+/*--- Comments Styles ---*/
+div.bx-tl-item-comments-holder .cmt.bx-def-box {
+    border-width: 0px;
+}
+div.bx-tl-item-comments-holder .bx-def-thumb-size {
+    width: 30px;
+    width: 2rem;
+    height: 30px;
+    height: 2rem;
+
+    line-height: 26px;
+    line-height: 1.75rem;
+
+    font-size: 19.5px;
+    font-size: 1.3rem;
+}
+div.bx-tl-item-comments-holder .bx-def-thumb-size-left-indent {
+    margin-left: 3.25rem;
+}
+div.bx-tl-item-comments-holder .bx-def-thumb-size-min-height {
+    min-height: 2rem;
+}
+div.bx-tl-item-comments-holder .cmts.cmts-margin {
+    font-size: 12px;
+    font-size: 0.75rem;
+}
+
+/*--- Live Update Alert Styles ---*/
+div.bx-tl-live-update-button {
+    position: relative;
+    text-align: center;
+}
+@supports(position:sticky) {
+    div.bx-tl-live-update-button {
+        position: sticky;
+        top: 1rem;
+        z-index: 1;
+    }
+}
+@supports(position:-webkit-sticky) {
+    div.bx-tl-live-update-button {
+        position: -webkit-sticky;
+        top: 1rem;
+        z-index: 1;
+    }
+}
+div.bx-tl-live-update-button .bx-btn {
+    display: inline-block;
+    float: none;
+}
+
+/*--- Live Update Notifications Styles ---*/
+.bx-tl-live-update-item {
+    position: relative;
+    display: block;
+}
+div.bx-tl-lui-cnt {
+    position: relative;
+}
+div.bx-tl-lui-avatar {
+    position: absolute;
+    top: 0px;
+    left: 0px;
+    text-align: center;
+}
+div.bx-tl-lui-info {
+    position: realtive;
+    display: -webkit-flex;
+    display: flex;
+    -webkit-align-items: center;
+    align-items: center;
+}
+div.bx-tl-luii-username {
+    white-space: nowrap;
+    text-overflow: ellipsis;
+    overflow: hidden;
+}

+ 36 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/images/icons/std-icon.svg

@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<svg width="64px" height="64px" viewBox="0 0 64 64" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
+    <!-- Generator: Sketch 55 (78076) - https://sketchapp.com -->
+    <title>Timeline</title>
+    <desc>Created with Sketch.</desc>
+    <defs>
+        <path d="M32,64 C46.0222222,64 53.8173667,64 58.9086889,58.9086889 C64,53.8173667 64,46.0222222 64,32 C64,17.9777778 64,10.1826333 58.9086889,5.09131111 C53.8173667,0 46.0222222,0 32,0 C17.9777778,0 10.1826333,0 5.09131111,5.09131111 C0,10.1826333 0,17.9777778 0,32 C0,46.0222222 0,53.8173667 5.09131111,58.9086889 C10.1826333,64 17.9777778,64 32,64 Z" id="path-1"></path>
+        <linearGradient x1="50%" y1="0%" x2="50%" y2="100%" id="linearGradient-3">
+            <stop stop-color="#FDFEFF" offset="0%"></stop>
+            <stop stop-color="#FBFCFD" stop-opacity="0.9" offset="100%"></stop>
+        </linearGradient>
+        <path d="M32,12 C20.9516129,12 12,20.9516129 12,32 C12,43.0483871 20.9516129,52 32,52 C43.0483871,52 52,43.0483871 52,32 C52,20.9516129 43.0483871,12 32,12 Z M36.6048387,40.233871 L29.4919355,35.0645161 C29.2419355,34.8790323 29.0967742,34.5887097 29.0967742,34.2822581 L29.0967742,20.7096774 C29.0967742,20.1774194 29.5322581,19.7419355 30.0645161,19.7419355 L33.9354839,19.7419355 C34.4677419,19.7419355 34.9032258,20.1774194 34.9032258,20.7096774 L34.9032258,31.8145161 L40.0241935,35.5403226 C40.4596774,35.8548387 40.5483871,36.4596774 40.233871,36.8951613 L37.9596774,40.0241935 C37.6451613,40.4516129 37.0403226,40.5483871 36.6048387,40.233871 Z" id="path-4"></path>
+        <filter x="-5.0%" y="-2.5%" width="110.0%" height="110.0%" filterUnits="objectBoundingBox" id="filter-5">
+            <feOffset dx="0" dy="1" in="SourceAlpha" result="shadowOffsetOuter1"></feOffset>
+            <feGaussianBlur stdDeviation="0.5" in="shadowOffsetOuter1" result="shadowBlurOuter1"></feGaussianBlur>
+            <feColorMatrix values="0 0 0 0 0   0 0 0 0 0   0 0 0 0 0  0 0 0 0.1 0" type="matrix" in="shadowBlurOuter1"></feColorMatrix>
+        </filter>
+    </defs>
+    <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
+        <g id="Artboard" transform="translate(-664.000000, -430.000000)">
+            <g id="Timeline" transform="translate(664.000000, 430.000000)">
+                <mask id="mask-2" fill="white">
+                    <use xlink:href="#path-1"></use>
+                </mask>
+                <use id="Path" fill="#00B356" xlink:href="#path-1"></use>
+                <g id="clock" mask="url(#mask-2)">
+                    <g transform="translate(12.000000, 12.000000)"></g>
+                </g>
+                <g id="Shape" fill-rule="nonzero" mask="url(#mask-2)">
+                    <use fill="black" fill-opacity="1" filter="url(#filter-5)" xlink:href="#path-4"></use>
+                    <use fill="url(#linearGradient-3)" xlink:href="#path-4"></use>
+                </g>
+            </g>
+        </g>
+    </g>
+</svg>

+ 67 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/item_outline.html

@@ -0,0 +1,67 @@
+<div id="__html_id__" class="__style_prefix__-item __class__">
+    <a name="timeline-event-__id__"></a>
+    <div class="__style_prefix__-item-ind bx-def-padding-sec">
+        <div class="__style_prefix__-item-cnt bx-def-box bx-def-padding-topbottom bx-def-round-corners __class_content__">
+            <div class="__style_prefix__-blink-plate"></div>
+            <bx_if:show_note>
+                <bx_repeat:notes>
+                    <div class="__style_prefix__-item-note bx-def-margin-leftright">
+                        <div class="__style_prefix__-in-text bx-def-font-grayed<bx_if:show_note_color> col-__item_note_color__</bx_if:show_note_color>">__item_note__</div>
+                    </div>
+                </bx_repeat:notes>
+                <div class="__style_prefix__-in-divider bx-def-hr bx-def-margin-sec-topbottom"></div>
+            </bx_if:show_note>
+            <div class="__style_prefix__-item-owner bx-def-margin-leftright __class_owner__"> 
+                <div class="__style_prefix__-owner-avatar bx-def-thumb-size">__item_owner_unit__</div>
+                    <div class="__style_prefix__-owner-info bx-def-thumb-size-min-height bx-def-thumb-size-left-indent">
+                        <!-- NOTE: Spaces after and between elements in 'owner-name' DIV are needed for better line folding -->
+                        <div class="__style_prefix__-owner-name bx-def-font-middle bx-def-font-grayed">
+                            <a href="__item_owner_url__" class="__style_prefix__-owner-name" title="__item_owner_title__">__item_owner_name__</a> <span> __item_owner_action__ </span> 
+                            <bx_if:show_timeline_owner>
+                                <span> <bx_text:_bx_timeline_txt_to /> </span> 
+                                <span class="__style_prefix__-timeline-owner-name">
+                                    <bx_repeat:owners><span class="__style_prefix__-ton-div">, </span><a href="__owner_url__" class="__style_prefix__-ton-item">__owner_username__</a></bx_repeat:owners>
+                                </span>
+                            </bx_if:show_timeline_owner>
+                            <bx_if:show_menu_item_meta>
+                                <br /><span class="__style_prefix__-item-meta bx-def-font-grayed">__meta__</span>
+                            </bx_if:show_menu_item_meta>
+                            <bx_if:show_pinned>
+                                <span class="__style_prefix__-pinned bx-def-margin-thd-left">
+                                    <i class="sys-icon thumbtack bx-def-margin-thd-left" title="<bx_text_attribute:_bx_timeline_txt_pinned />"></i>
+                                </span>
+                            </bx_if:show_pinned>
+                            <bx_if:show_sticked>
+                                <span class="__style_prefix__-sticked bx-def-margin-thd-left">
+                                    <i class="sys-icon thumbtack bx-def-margin-thd-left" title="<bx_text_attribute:_bx_timeline_txt_sticked />"></i>
+                                </span>
+                            </bx_if:show_sticked>
+                            <bx_if:show_hot>
+                                <span class="__style_prefix__-hot bx-def-margin-thd-left">
+                                    <i class="sys-icon fire bx-def-margin-thd-left" title="<bx_text_attribute:_bx_timeline_txt_hot />"></i>
+                                </span>
+                            </bx_if:show_hot>
+                        </div>
+                    </div>
+                    <bx_if:show_owner_actions>
+                    <div class="__style_prefix__-owner-actions bx-def-thumb-size-min-height">
+                        <bx_repeat:owner_actions>
+                            <a class="bx-btn bx-btn-small" href="__href__" onclick="__onclick__" title="__title__"><i class="sys-icon __icon__"></i></a>
+                        </bx_repeat:owner_actions>
+                    </div>
+                </bx_if:show_owner_actions>
+            </div>
+            <div class="__style_prefix__-item-content bx-def-margin-sec-top bx-clearfix">__content__</div>
+            <bx_if:show_location>
+                <div class="__style_prefix__-item-location bx-def-margin-leftright bx-def-margin-sec-top bx-def-font-grayed bx-clearfix">__location__</div>
+            </bx_if:show_location>
+            <bx_if:show_reactions>
+                <div class="__style_prefix__-item-reactions bx-def-margin-leftright bx-def-margin-sec-top">__reactions__</div>
+            </bx_if:show_reactions>
+            <bx_if:show_menu_item_actions>
+                <div class="__style_prefix__-item-activity bx-def-margin-leftright bx-def-margin-sec-top bx-clearfix">__menu_item_actions__</div>
+            </bx_if:show_menu_item_actions>
+            <div class="__style_prefix__-item-comments-holder bx-def-margin-leftright">__comments__</div>
+        </div>
+    </div>
+</div>

+ 70 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/item_timeline.html

@@ -0,0 +1,70 @@
+<div id="__html_id__" class="__style_prefix__-item __class__ bx-def-thumb-size-min-height bx-def-padding-bottom bx-clearfix">
+    <a name="timeline-event-__id__"></a>
+    <div class="__style_prefix__-item-type bx-def-media-phone-hide">
+        <div class="__style_prefix__-item-circle">
+            <i class="sys-icon __item_icon__"></i>
+        </div>
+    </div>
+    <div class="__style_prefix__-item-cnt bx-def-box bx-def-padding-topbottom bx-def-round-corners __class_content__">
+        <div class="__style_prefix__-blink-plate"></div>
+        <bx_if:show_note>
+            <bx_repeat:notes>
+                <div class="__style_prefix__-item-note">
+                    <div class="__style_prefix__-in-text bx-def-margin-leftright bx-def-font-grayed<bx_if:show_note_color> col-__item_note_color__</bx_if:show_note_color>">__item_note__</div>
+                </div>
+            </bx_repeat:notes>
+            <div class="__style_prefix__-in-divider bx-def-hr bx-def-margin-topbottom"></div>
+        </bx_if:show_note>
+        <div class="__style_prefix__-item-owner bx-def-margin-leftright __class_owner__"> 
+            <div class="__style_prefix__-owner-avatar bx-def-thumb-size">__item_owner_unit__</div>
+            <div class="__style_prefix__-owner-info bx-def-thumb-size-min-height bx-def-thumb-size-left-indent">
+                <!-- NOTE: Spaces after and between elements in 'owner-name' DIV are needed for better line folding -->
+                <div class="__style_prefix__-owner-name bx-def-font-middle bx-def-font-grayed">
+                    <a href="__item_owner_url__" class="__style_prefix__-owner-name" title="__item_owner_title__">__item_owner_name__</a> <span> __item_owner_action__ </span> 
+                    <bx_if:show_timeline_owner>
+                        <span> <bx_text:_bx_timeline_txt_to /> </span> 
+                        <span class="__style_prefix__-timeline-owner-name">
+                            <bx_repeat:owners><span class="__style_prefix__-ton-div">, </span><a href="__owner_url__" class="__style_prefix__-ton-item">__owner_username__</a></bx_repeat:owners>
+                        </span> 
+                    </bx_if:show_timeline_owner>
+                    <bx_if:show_menu_item_meta>
+                        <br /><span class="__style_prefix__-item-meta bx-def-font-grayed">__meta__</span>
+                    </bx_if:show_menu_item_meta>
+                    <bx_if:show_pinned>
+                        <span class="__style_prefix__-pinned bx-def-margin-thd-left">
+                            <i class="sys-icon thumbtack bx-def-margin-thd-left" title="<bx_text_attribute:_bx_timeline_txt_pinned />"></i>
+                        </span>
+                    </bx_if:show_pinned>
+                    <bx_if:show_sticked>
+                        <span class="__style_prefix__-sticked bx-def-margin-thd-left">
+                            <i class="sys-icon thumbtack bx-def-margin-thd-left" title="<bx_text_attribute:_bx_timeline_txt_sticked />"></i>
+                        </span>
+                    </bx_if:show_sticked>
+                    <bx_if:show_hot>
+                        <span class="__style_prefix__-hot bx-def-margin-thd-left">
+                            <i class="sys-icon fire bx-def-margin-thd-left" title="<bx_text_attribute:_bx_timeline_txt_hot />"></i>
+                        </span>
+                    </bx_if:show_hot>
+                </div>
+            </div>
+            <bx_if:show_owner_actions>
+                <div class="__style_prefix__-owner-actions bx-def-thumb-size-min-height">
+                    <bx_repeat:owner_actions>
+                        <a class="bx-btn bx-btn-small" href="__href__" onclick="__onclick__">__content__</a>
+                    </bx_repeat:owner_actions>
+                </div>
+            </bx_if:show_owner_actions>
+        </div>
+        <div class="__style_prefix__-item-content bx-def-margin-sec-top bx-clearfix">__content__</div>
+        <bx_if:show_location>
+            <div class="__style_prefix__-item-location bx-def-margin-leftright bx-def-margin-sec-top bx-def-font-grayed bx-clearfix">__location__</div>
+        </bx_if:show_location>
+        <bx_if:show_reactions>
+            <div class="__style_prefix__-item-reactions bx-def-margin-leftright bx-def-margin-sec-top">__reactions__</div>
+        </bx_if:show_reactions>
+        <bx_if:show_menu_item_actions>
+            <div class="__style_prefix__-item-activity bx-def-margin-leftright bx-def-margin-sec-top bx-clearfix">__menu_item_actions__</div>
+        </bx_if:show_menu_item_actions>
+        <div class="__style_prefix__-item-comments-holder bx-def-margin-leftright">__comments__</div>
+    </div>
+</div>

+ 9 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/link_embed_common.html

@@ -0,0 +1,9 @@
+<div class="__style_prefix__-il-embed __style_prefix__-il-embed-common bx-def-padding-sec bx-def-border bx-def-round-corners">
+    <bx_if:show_thumbnail>
+        <div class="__style_prefix__-il-thumbnail"><a href="__link__"__attrs__><img src="__thumbnail__" /></a></div>
+    </bx_if:show_thumbnail>
+    <div class="__style_prefix__-il-title"><a href="__link__"__attrs__>__content__</a></div>
+    <bx_if:show_text>
+        <div class="__style_prefix__-il-text bx-def-font-small bx-def-font-grayed">__text__</div>
+    </bx_if:show_text>
+</div>

+ 1 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/link_embed_provider.html

@@ -0,0 +1 @@
+<div class="__style_prefix__-il-embed __style_prefix__-il-embed-provider">__embed__</div>

+ 5 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/live_update_button.html

@@ -0,0 +1,5 @@
+<div id="__html_id__" class="__style_prefix__-live-update-button bx-def-padding-bottom">
+    <a class="bx-btn" href="javascript:void(0)" onclick="__onclick_show__" title="<bx_text_attribute:_bx_timeline_txt_show />">
+        <i class="sys-icon sync-alt bx-def-padding-right"></i><bx_text:_bx_timeline_txt_new_content />
+    </a>
+</div>

+ 10 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/live_update_notification.html

@@ -0,0 +1,10 @@
+<div class="__style_prefix__-live-update-item">
+    <a class="__style_prefix__-live-update-item bx-def-padding" href="javascript:void(0)" onclick="__onclick_show__" title="<bx_text_attribute:_bx_timeline_txt_show />">
+        <div class="__style_prefix__-lui-cnt">
+            <div class="__style_prefix__-lui-avatar bx-def-thumb-size">__author_unit__</div>
+            <div class="__style_prefix__-lui-info bx-def-thumb-size-min-height bx-def-thumb-size-left-indent">
+                <div class="__style_prefix__-luii-username"><b class="__style_prefix__-luii-username bx-def-font-color">__author_name__</b> <span class="bx-def-font-small bx-def-font-grayed">__text__</span></div>
+            </div>
+        </div>
+    </a>
+</div>

+ 39 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/type_post.html

@@ -0,0 +1,39 @@
+<bx_if:show_images>
+    <div class="__style_prefix__-item-images __style_prefix__-ii-main __style_prefix__-ii-__display__ bx-def-margin-topbottom">
+        <bx_repeat:items>
+            <div class="__style_prefix__-item-image">__item__</div>
+        </bx_repeat:items>
+    </div>
+</bx_if:show_images>
+<bx_if:show_videos>
+    <div class="__style_prefix__-item-videos __style_prefix__-iv-main __style_prefix__-iv-__display__ bx-def-margin-topbottom">
+        <bx_repeat:items>
+            <div class="__style_prefix__-item-video">__item__</div>
+        </bx_repeat:items>
+    </div>
+</bx_if:show_videos>
+<div class="__style_prefix__-item-text bx-def-margin-topbottom bx-def-margin-leftright">
+    <bx_if:show_title>
+        <div class="__style_prefix__-title bx-def-margin-sec-bottom bx-def-font-h1">__title__</div>
+    </bx_if:show_title>
+    <bx_if:show_content>
+        <div class="__style_prefix__-content">__item_content__</div>
+    </bx_if:show_content>
+</div>
+<bx_if:show_attachments>
+    <div class="__style_prefix__-item-attachments __style_prefix__-ia-gallery bx-def-margin-topbottom bx-def-margin-leftright">
+        <bx_repeat:items>
+            <div class="__style_prefix__-item-attachment">__item__</div>
+        </bx_repeat:items>
+    </div>
+</bx_if:show_attachments>
+<bx_if:show_links>
+    <div class="__style_prefix__-item-links bx-def-margin-topbottom bx-def-margin-leftright">
+        <bx_repeat:links>
+            <div class="__style_prefix__-item-link bx-def-margin-top-auto">__link__</div>
+        </bx_repeat:links>
+    </div>
+</bx_if:show_links>
+<bx_if:show_raw>
+    <div class="__style_prefix__-item-raw bx-def-margin-topbottom bx-def-margin-leftright">__item_content_raw__</div>
+</bx_if:show_raw>

+ 1 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/uploader_button_html5_attach.html

@@ -0,0 +1 @@
+<bx_include_base:../modules/base/text/template/uploader_button_html5_attach.html />

+ 1 - 0
modules/boonex/timeline/updates/9.0.14_10.0.0/source/template/uploader_button_simple_attach.html

@@ -0,0 +1 @@
+<bx_include_base:../modules/base/text/template/uploader_button_simple_attach.html />

+ 68 - 0
modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/config.php

@@ -0,0 +1,68 @@
+<?php 
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    TwitterConnect Twitter Connect
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_twitter',
+    'title' => 'Twitter connect',
+    'note' => 'Join the site using Twitter account.',
+    'version' => '10.0.0',
+    'vendor' => 'Boonex',
+    'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/twitter_connect/',
+    'home_uri' => 'twitter',
+
+    'db_prefix' => 'bx_twitter_',
+    'class_prefix' => 'BxTwitter',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Twitter Connect',
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    ),
+    'uninstall' => array (
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+);
+
+/** @} */

+ 37 - 0
modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+	<string name="_sys_module_twitter"><![CDATA[Twitter Connect]]></string>
+	<string name="_bx_twitter"><![CDATA[Twitter Connect]]></string>
+	<string name="_bx_twitter_settings"><![CDATA[Twitter Connect]]></string>
+	<string name="_bx_twitter_information_block"><![CDATA[
+        <p>This module can be used to login to this site using Twitter credentials.</p>
+        <p>To make it work, <a target="_blank" href="https://apps.twitter.com">create Twitter app</a> and specify all the details, particularly:
+            <ul>
+                <li>Callback URL: <strong>{0}</strong></li>
+            </ul>
+            When the app is created make sure to specify the following fields:
+            <ul>
+                <li>Settings &gt; Privacy Policy URL</li>
+                <li>Settings &gt; Terms of Service URL</li>
+                <li>Settings &gt; Enable "Allow this application to be used to Sign in with Twitter"</li>
+                <li>Permissions &gt; Access &gt; Read only</li>
+                <li>Permissions &gt; Additional Permissions &gt; Enable "Request email addresses from users"</li>
+            </ul>
+            Then enter generated API Key & Secret pair in this module settings.
+        </p>]]></string>
+		
+	<string name="_bx_twitter_profile_error_api_keys"><![CDATA[Please configure the module in admin panel (can't define API key, secret & URL)]]></string>
+	<string name="_bx_twitter_auth_title"><![CDATA[Login with Twitter]]></string>
+	<string name="_bx_twitter_error_no_oauth_token"><![CDATA[Auth token is missing]]></string>
+
+    <string name="_bx_twitter_adm_stg_cpt_type"><![CDATA[Twitter Connect]]></string>    
+    <string name="_bx_twitter_option_app_id"><![CDATA[API Key]]></string>
+    <string name="_bx_twitter_option_app_secret"><![CDATA[API Secret]]></string>
+
+	<string name="_bx_twitter_et_password_generated"><![CDATA[Twitter connect temporary password]]></string>
+	<string name="_bx_twitter_et_password_generated_subject"><![CDATA[Temporary password]]></string>
+	<string name="_bx_twitter_et_password_generated_body"><![CDATA[{email_header}
+<p>Temporary password - <b>{password}</b></p>
+<p>Change it after logging-in.</p>
+{email_footer}]]></string>
+</resources>

+ 49 - 0
modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,49 @@
+
+-- Email template
+
+INSERT INTO `sys_email_templates` (`Module`, `NameSystem`, `Name`, `Subject`, `Body`) VALUES
+('bx_twitter', '_bx_twitter_et_password_generated', 'bx_twitter_password_generated', '_bx_twitter_et_password_generated_subject', '_bx_twitter_et_password_generated_body');
+
+-- Auth objects
+
+INSERT INTO `sys_objects_auths` (`Name`, `Title`, `Link`, `Icon`, `Style`) VALUES
+('bx_twitter', '_bx_twitter_auth_title', 'modules/?r=twitter/start', 'fab twitter', 'a:1:{s:7:".bx-btn";a:1:{s:10:"background";s:18:"#5aa4eb !important";}}');
+
+-- Alerts
+
+INSERT INTO `sys_alerts_handlers` SET `name` = 'bx_twitter', `class` = 'BxTwitterAlerts', `file` = 'modules/boonex/twitter_connect/classes/BxTwitterAlerts.php';
+
+SET @iHandlerId := (SELECT `id` FROM `sys_alerts_handlers`  WHERE `name` = 'bx_twitter');
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('account', 'logout', @iHandlerId),
+('profile', 'delete', @iHandlerId),
+('profile', 'add', @iHandlerId);
+
+-- Options
+
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types` (`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_twitter', '_bx_twitter_adm_stg_cpt_type', 'bx_twitter@modules/boonex/twitter_connect/|std-icon.svg', IF(NOT ISNULL(@iTypeOrder), @iTypeOrder + 1, 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order` )  
+VALUES (@iTypeId, 'bx_twitter_general', '_sys_connect_adm_stg_cpt_category_general', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `check`, `check_error`, `order`, `extra`) VALUES
+('bx_twitter_api_key', '', @iCategId, '_bx_twitter_option_app_id', 'digit', '', '', 10, ''),
+('bx_twitter_secret', '', @iCategId, '_bx_twitter_option_app_secret', 'digit', '', '', 20, ''),
+('bx_twitter_redirect_page', 'dashboard', @iCategId, '_sys_connect_option_redirect', 'select', '', '', 40, 'join,settings,dashboard,index'),
+('bx_twitter_module', 'bx_persons', @iCategId, '_sys_connect_option_module', 'select', '', '', 50, 'a:2:{s:6:"module";s:10:"bx_twitter";s:6:"method";s:20:"get_profiles_modules";}'),
+('bx_twitter_privacy', '3', @iCategId, '_sys_connect_option_privacy', 'select', '', '', 54, 'a:2:{s:6:"module";s:10:"bx_twitter";s:6:"method";s:18:"get_privacy_groups";}'),
+('bx_twitter_confirm_email', 'on', @iCategId, '_sys_connect_option_confirm_email', 'checkbox', '', '', 70, ''),
+('bx_twitter_approve', '', @iCategId, '_sys_connect_option_approve', 'checkbox', '', '', 80, '');
+
+-- Pages
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_twitter_error', 'twitter-error', '_bx_twitter_error', '_bx_twitter_error', 'bx_twitter', 5, 2147483647, 0, '', '', '', '', 0, 1, 0, 'BxTwitterPage', 'modules/boonex/twitter_connect/classes/BxTwitterPage.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_twitter_error', 1, 'bx_twitter', '_bx_twitter_error', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:10:\"bx_twitter\";s:6:\"method\";s:10:\"last_error\";}', 0, 0, 1, 1);

+ 21 - 0
modules/boonex/twitter_connect/updates/9.0.5_10.0.0/source/install/sql/install.sql

@@ -0,0 +1,21 @@
+
+CREATE TABLE `bx_twitter_accounts` (
+  `local_profile` int(10) unsigned NOT NULL,
+  `remote_profile` varchar(16) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
+  PRIMARY KEY (`local_profile`),
+  KEY `remote_profile` (`remote_profile`)
+);
+
+-- Studio page and widget
+
+INSERT INTO `sys_std_pages`(`index`, `name`, `header`, `caption`, `icon`) VALUES
+(3, 'bx_twitter', '_bx_twitter', '_bx_twitter', 'bx_twitter@modules/boonex/twitter_connect/|std-icon.svg');
+SET @iPageId = LAST_INSERT_ID();
+
+SET @iParentPageId = (SELECT `id` FROM `sys_std_pages` WHERE `name` = 'home');
+SET @iParentPageOrder = (SELECT MAX(`order`) FROM `sys_std_pages_widgets` WHERE `page_id` = @iParentPageId);
+INSERT INTO `sys_std_widgets` (`page_id`, `module`, `url`, `click`, `icon`, `caption`, `cnt_notices`, `cnt_actions`) VALUES
+(@iPageId, 'bx_twitter', '{url_studio}module.php?name=bx_twitter', '', 'bx_twitter@modules/boonex/twitter_connect/|std-icon.svg', '_bx_twitter', '', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_actions";s:6:"params";a:0:{}s:5:"class";s:18:"TemplStudioModules";}');
+INSERT INTO `sys_std_pages_widgets` (`page_id`, `widget_id`, `order`) VALUES
+(@iParentPageId, LAST_INSERT_ID(), IF(ISNULL(@iParentPageOrder), 1, @iParentPageOrder + 1));
+

+ 68 - 0
modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/config.php

@@ -0,0 +1,68 @@
+<?php 
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    UnaConnect UNA Connect
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_unacon',
+    'title' => 'UNA connect',
+    'note' => 'Join the site using another UNA site account credentials.',
+    'version' => '10.0.0',
+    'vendor' => 'Boonex',
+    'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/una_connect/',
+    'home_uri' => 'unacon',
+
+    'db_prefix' => 'bx_unacon_',
+    'class_prefix' => 'BxUnaCon',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'UNA Connect',
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    ),
+    'uninstall' => array (
+        'execute_sql' => 1,
+        'update_languages' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+        'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+);
+
+/** @} */

+ 28 - 0
modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+	<string name="_sys_module_unacon"><![CDATA[UNA Connect]]></string>
+	<string name="_bx_unacon"><![CDATA[UNA Connect]]></string>
+	<string name="_bx_unacon_settings"><![CDATA[UNA Connect]]></string>
+	<string name="_bx_unacon_information_block"><![CDATA[
+This module can be used to login to this site using another UNA site (master site) credentials. <br />
+To make it work, go to the master site, install "OAuth2 Server" module and add new client site, specify the desired title and the following URL:<br />
+<strong>{0}</strong><br />
+Then enter generated on the master site the Key & Server pair in this module settings.]]></string>
+	<string name="_bx_unacon_profile_error_api_keys"><![CDATA[Please configure the module in admin panel (can't define API key, secret & URL)]]></string>
+	<string name="_bx_unacon_chart"><![CDATA[UNA Profiles]]></string>
+	<string name="_bx_unacon_auth_title"><![CDATA[Login with UNA]]></string>
+
+    <string name="_bx_unacon_adm_stg_cpt_type"><![CDATA[UNA Connect]]></string>
+    <string name="_bx_unacon_option_app_id"><![CDATA[UNA App ID]]></string>
+    <string name="_bx_unacon_option_app_secret"><![CDATA[UNA App Secret]]></string>
+    <string name="_bx_unacon_option_app_url"><![CDATA[Main UNA Site URL]]></string>
+    <string name="_bx_unacon_option_auto_friends"><![CDATA[Auto-friend members if they are already friends on other UNA site]]></string>
+    <string name="_bx_unacon_option_rewrite"><![CDATA[Use rewrite URLs on main UNA site]]></string>
+
+	<string name="_bx_unacon_et_password_generated"><![CDATA[UNA connect temporary password]]></string>
+	<string name="_bx_unacon_et_password_generated_subject"><![CDATA[Temporary password]]></string>
+	<string name="_bx_unacon_et_password_generated_body"><![CDATA[{email_header}
+<p>Temporary password - <b>{password}</b></p>
+<p>Change it after logging-in.</p>
+{email_footer}]]></string>
+</resources>

+ 52 - 0
modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,52 @@
+
+-- Email template
+
+INSERT INTO `sys_email_templates` (`Module`, `NameSystem`, `Name`, `Subject`, `Body`) VALUES
+('bx_unacon', '_bx_unacon_et_password_generated', 'bx_unacon_password_generated', '_bx_unacon_et_password_generated_subject', '_bx_unacon_et_password_generated_body');
+
+-- Auth objects
+
+INSERT INTO `sys_objects_auths` (`Name`, `Title`, `Link`, `Icon`, `Style`) VALUES
+('bx_unacon', '_bx_unacon_auth_title', 'modules/?r=unacon/start', 'sign-in-alt', 'a:1:{s:7:".bx-btn";a:1:{s:10:"background";s:18:"#40b060 !important";}}');
+
+-- Alerts
+
+INSERT INTO `sys_alerts_handlers` SET `name` = 'bx_unacon', `class` = 'BxUnaConAlerts', `file` = 'modules/boonex/una_connect/classes/BxUnaConAlerts.php';
+
+SET @iHandlerId := (SELECT `id` FROM `sys_alerts_handlers`  WHERE `name` = 'bx_unacon');
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('account', 'logout', @iHandlerId),
+('profile', 'delete', @iHandlerId),
+('profile', 'add', @iHandlerId);
+
+-- Options
+
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types` (`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_unacon', '_bx_unacon_adm_stg_cpt_type', 'bx_unacon@modules/boonex/una_connect/|std-icon.svg', IF(NOT ISNULL(@iTypeOrder), @iTypeOrder + 1, 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order` )  
+VALUES (@iTypeId, 'bx_unacon_general', '_sys_connect_adm_stg_cpt_category_general', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `check`, `check_error`, `order`, `extra`) VALUES
+('bx_unacon_api_key', '', @iCategId, '_bx_unacon_option_app_id', 'digit', '', '', 10, ''),
+('bx_unacon_secret', '', @iCategId, '_bx_unacon_option_app_secret', 'digit', '', '', 20, ''),
+('bx_unacon_url', '', @iCategId, '_bx_unacon_option_app_url', 'digit', '', '', 30, ''),
+('bx_unacon_redirect_page', 'dashboard', @iCategId, '_sys_connect_option_redirect', 'select', '', '', 40, 'join,settings,dashboard,index'),
+('bx_unacon_module', 'bx_persons', @iCategId, '_sys_connect_option_module', 'select', '', '', 50, 'a:2:{s:6:"module";s:9:"bx_unacon";s:6:"method";s:20:"get_profiles_modules";}'),
+('bx_unacon_privacy', '3', @iCategId, '_sys_connect_option_privacy', 'select', '', '', 54, 'a:2:{s:6:"module";s:9:"bx_unacon";s:6:"method";s:18:"get_privacy_groups";}'),
+('bx_unacon_auto_friends', 'on', @iCategId, '_bx_unacon_option_auto_friends', 'checkbox', '', '', 60, ''),
+('bx_unacon_confirm_email', 'on', @iCategId, '_sys_connect_option_confirm_email', 'checkbox', '', '', 70, ''),
+('bx_unacon_approve', '', @iCategId, '_sys_connect_option_approve', 'checkbox', '', '', 80, ''),
+('bx_unacon_url_rewrite', 'on', @iCategId, '_bx_unacon_option_rewrite', 'checkbox', '', '', 90, '');
+
+-- Pages
+
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_unacon_error', 'unacon-error', '_bx_unacon_error', '_bx_unacon_error', 'bx_unacon', 5, 2147483647, 0, '', '', '', '', 0, 1, 0, 'BxUnaConPage', 'modules/boonex/una_connect/classes/BxUnaConPage.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_unacon_error', 1, 'bx_unacon', '_bx_unacon_error', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_unacon\";s:6:\"method\";s:10:\"last_error\";}', 0, 0, 1, 1);

+ 21 - 0
modules/boonex/una_connect/updates/9.0.3_10.0.0/source/install/sql/install.sql

@@ -0,0 +1,21 @@
+
+CREATE TABLE `bx_unacon_accounts` (
+  `local_profile` int(10) unsigned NOT NULL,
+  `remote_profile` int(10) unsigned NOT NULL,
+  PRIMARY KEY (`local_profile`),
+  KEY `remote_profile` (`remote_profile`)
+);
+
+-- Studio page and widget
+
+INSERT INTO `sys_std_pages`(`index`, `name`, `header`, `caption`, `icon`) VALUES
+(3, 'bx_unacon', '_bx_unacon', '_bx_unacon', 'bx_unacon@modules/boonex/una_connect/|std-icon.svg');
+SET @iPageId = LAST_INSERT_ID();
+
+SET @iParentPageId = (SELECT `id` FROM `sys_std_pages` WHERE `name` = 'home');
+SET @iParentPageOrder = (SELECT MAX(`order`) FROM `sys_std_pages_widgets` WHERE `page_id` = @iParentPageId);
+INSERT INTO `sys_std_widgets` (`page_id`, `module`, `url`, `click`, `icon`, `caption`, `cnt_notices`, `cnt_actions`) VALUES
+(@iPageId, 'bx_unacon', '{url_studio}module.php?name=bx_unacon', '', 'bx_unacon@modules/boonex/una_connect/|std-icon.svg', '_bx_unacon', '', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_actions";s:6:"params";a:0:{}s:5:"class";s:18:"TemplStudioModules";}');
+INSERT INTO `sys_std_pages_widgets` (`page_id`, `widget_id`, `order`) VALUES
+(@iParentPageId, LAST_INSERT_ID(), IF(ISNULL(@iParentPageOrder), 1, @iParentPageOrder + 1));
+

Datei-Diff unterdrückt, da er zu groß ist
+ 17 - 0
modules/boonex/una_connect/updates/9.0.3_10.0.0/source/template/images/icons/std-icon.svg


+ 183 - 0
modules/boonex/videos/updates/9.0.4_10.0.0/source/classes/BxVideosConfig.php

@@ -0,0 +1,183 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Videos Videos
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+bx_import('BxDolInformer');
+
+class BxVideosConfig extends BxBaseModTextConfig
+{
+
+    function __construct($aModule)
+    {
+        parent::__construct($aModule);
+
+        $aMenuItems2Methods = array (
+            'edit-video' => 'checkAllowedEdit',
+            'delete-video' => 'checkAllowedDelete',
+        );
+
+        $this->CNF = array (
+
+            // module icon
+            'ICON' => 'film col-gray',
+
+            // database tables
+            'TABLE_ENTRIES' => $aModule['db_prefix'] . 'entries',
+            'TABLE_ENTRIES_FULLTEXT' => 'title_text',
+
+            // database fields
+            'FIELD_ID' => 'id',
+            'FIELD_AUTHOR' => 'author',
+            'FIELD_ADDED' => 'added',
+            'FIELD_CHANGED' => 'changed',
+            'FIELD_TITLE' => 'title',
+            'FIELD_TEXT' => 'text',
+            'FIELD_TEXT_ID' => 'video-text',
+            'FIELD_CATEGORY' => 'cat',
+            'FIELD_DURATION' => 'duration',
+            'FIELD_ALLOW_VIEW_TO' => 'allow_view_to',
+            'FIELD_PHOTO' => 'pictures',
+            'FIELD_THUMB' => 'thumb',
+            'FIELD_POSTER' => '', //'poster',
+            'FIELD_VIDEOS' => 'videos',
+            'FIELD_VIDEO' => 'video',
+            'FIELD_VIEWS' => 'views',
+            'FIELD_COMMENTS' => 'comments',
+            'FIELD_STATUS' => 'status',
+            'FIELD_STATUS_ADMIN' => 'status_admin',
+            'FIELD_LABELS' => 'labels',
+            'FIELD_LOCATION_PREFIX' => 'location',
+            'FIELDS_WITH_KEYWORDS' => 'auto', // can be 'auto', array of fields or comma separated string of field names, works only when OBJECT_METATAGS is specified
+            'FIELDS_DELAYED_PROCESSING' => 'videos', // can be array of fields or comma separated string of field names
+
+            // page URIs
+            'URI_VIEW_ENTRY' => 'view-video',
+            'URI_AUTHOR_ENTRIES' => 'videos-author',
+            'URI_ENTRIES_BY_CONTEXT' => 'videos-context',
+            'URI_ADD_ENTRY' => 'create-video',
+            'URI_EDIT_ENTRY' => 'edit-video',
+            'URI_MANAGE_COMMON' => 'videos-manage',
+
+            'URL_HOME' => 'page.php?i=videos-home',
+            'URL_POPULAR' => 'page.php?i=videos-popular',
+            'URL_UPDATED' => 'page.php?i=videos-updated',
+            'URL_MANAGE_COMMON' => 'page.php?i=videos-manage',
+            'URL_MANAGE_ADMINISTRATION' => 'page.php?i=videos-administration',
+
+            // some params
+            'PARAM_CHARS_SUMMARY' => 'bx_videos_summary_chars',
+            'PARAM_CHARS_SUMMARY_PLAIN' => 'bx_videos_plain_summary_chars',
+            'PARAM_NUM_RSS' => 'bx_videos_rss_num',
+            'PARAM_SEARCHABLE_FIELDS' => 'bx_videos_searchable_fields',
+
+            // objects
+            'OBJECT_STORAGE' => 'bx_videos_photos',
+            'OBJECT_STORAGE_VIDEOS' => 'bx_videos_videos',
+            'OBJECT_IMAGES_TRANSCODER_PREVIEW' => 'bx_videos_preview',
+            'OBJECT_IMAGES_TRANSCODER_GALLERY' => 'bx_videos_gallery',
+            'OBJECT_IMAGES_TRANSCODER_COVER' => 'bx_videos_cover',
+            'OBJECT_IMAGES_TRANSCODER_POSTER' => 'bx_videos_poster',
+            'OBJECT_VIDEOS_TRANSCODERS' => array(
+            	'poster' => 'bx_videos_video_poster_cover', 
+            	'poster_preview' => 'bx_videos_video_poster_preview',
+                'poster_gallery' => 'bx_videos_video_poster_gallery',  
+            	'mp4' => 'bx_videos_video_mp4', 
+            	'mp4_hd' => 'bx_videos_video_mp4_hd'
+            ),
+            'OBJECT_VIDEO_TRANSCODER_HEIGHT' => '480px',
+            'OBJECT_REPORTS' => 'bx_videos',
+            'OBJECT_VIEWS' => 'bx_videos',
+            'OBJECT_VOTES' => 'bx_videos',
+            'OBJECT_VOTES_STARS' => 'bx_videos_stars',
+            'OBJECT_REACTIONS' => 'bx_videos_reactions',
+            'OBJECT_SCORES' => 'bx_videos',
+            'OBJECT_FAVORITES' => 'bx_videos',
+            'OBJECT_FEATURED' => 'bx_videos',
+            'OBJECT_METATAGS' => 'bx_videos',
+            'OBJECT_COMMENTS' => 'bx_videos',
+            'OBJECT_CATEGORY' => 'bx_videos_cats',
+            'OBJECT_PRIVACY_VIEW' => 'bx_videos_allow_view_to',
+            'OBJECT_FORM_ENTRY' => 'bx_videos',
+            'OBJECT_FORM_ENTRY_DISPLAY_VIEW' => 'bx_videos_entry_view',
+            'OBJECT_FORM_ENTRY_DISPLAY_ADD' => 'bx_videos_entry_add',
+            'OBJECT_FORM_ENTRY_DISPLAY_EDIT' => 'bx_videos_entry_edit',
+            'OBJECT_FORM_ENTRY_DISPLAY_DELETE' => 'bx_videos_entry_delete',
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY' => 'bx_videos_view', // actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_VIEW_ENTRY_ALL' => 'bx_videos_view_actions', // all actions menu on view entry page
+            'OBJECT_MENU_ACTIONS_MY_ENTRIES' => 'bx_videos_my', // actions menu on my entries page
+            'OBJECT_MENU_SUBMENU' => 'bx_videos_submenu', // main module submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY' => 'bx_videos_view_submenu', // view entry submenu
+            'OBJECT_MENU_SUBMENU_VIEW_ENTRY_MAIN_SELECTION' => 'videos-home', // first item in view entry submenu from main module submenu
+            'OBJECT_MENU_SNIPPET_META' => 'bx_videos_snippet_meta', // menu for snippet meta info
+            'OBJECT_MENU_MANAGE_TOOLS' => 'bx_videos_menu_manage_tools', //manage menu in content administration tools
+            'OBJECT_GRID_ADMINISTRATION' => 'bx_videos_administration',
+            'OBJECT_GRID_COMMON' => 'bx_videos_common',
+            'OBJECT_UPLOADERS' => array('sys_simple', 'sys_html5'),
+
+            // menu items which visibility depends on custom visibility checking
+            'MENU_ITEM_TO_METHOD' => array (
+                'bx_videos_my' => array (
+                    'create-video' => 'checkAllowedAdd',
+                ),
+                'bx_videos_view' => $aMenuItems2Methods,
+            ),
+
+            // informer messages
+            'INFORMERS' => array (
+                'processing' => array (
+                    'name' => 'bx-videos-processing',
+                    'map' => array (
+                        'awaiting' => array('msg' => '_bx_videos_txt_processing_awaiting', 'type' => BX_INFORMER_ALERT),
+                        'failed' => array('msg' => '_bx_videos_txt_processing_failed', 'type' => BX_INFORMER_ERROR)
+                    ),
+                ),
+            ),
+
+            // some language keys
+            'T' => array (
+                'txt_sample_single' => '_bx_videos_txt_sample_single',
+                'txt_sample_single_with_article' => '_bx_videos_txt_sample_single_with_article',
+                'txt_sample_comment_single' => '_bx_videos_txt_sample_comment_single',
+                'txt_sample_vote_single' => '_bx_videos_txt_sample_vote_single',
+                'txt_sample_score_up_single' => '_bx_videos_txt_sample_score_up_single',
+                'txt_sample_score_down_single' => '_bx_videos_txt_sample_score_down_single',
+                'form_field_author' => '_bx_videos_form_entry_input_author',
+                'grid_action_err_delete' => '_bx_videos_grid_action_err_delete',
+                'grid_txt_account_manager' => '_bx_videos_grid_txt_account_manager',
+                'filter_item_active' => '_bx_videos_grid_filter_item_title_adm_active',
+                'filter_item_hidden' => '_bx_videos_grid_filter_item_title_adm_hidden',
+                'filter_item_select_one_filter1' => '_bx_videos_grid_filter_item_title_adm_select_one_filter1',
+                'menu_item_manage_my' => '_bx_videos_menu_item_title_manage_my',
+                'menu_item_manage_all' => '_bx_videos_menu_item_title_manage_all',
+                'txt_all_entries_by' => '_bx_videos_txt_all_entries_by',
+                'txt_all_entries_in' => '_bx_videos_txt_all_entries_in',
+                'txt_all_entries_by_author' => '_bx_videos_page_title_browse_by_author',
+                'txt_pict_use_as_thumb' => '_bx_videos_form_entry_input_picture_use_as_thumb',
+                'txt_all_entries_by_context' => '_bx_videos_page_title_browse_by_context',
+                'txt_pict_use_as_poster' => '_bx_videos_form_entry_input_picture_use_as_poster',
+            ),
+        );
+
+        $this->_aJsClasses = array(
+        	'manage_tools' => 'BxVideosManageTools'
+        );
+
+        $this->_aJsObjects = array(
+        	'manage_tools' => 'oBxVideosManageTools'
+        );
+
+        $this->_aGridObjects = array(
+        	'common' => $this->CNF['OBJECT_GRID_COMMON'],
+        	'administration' => $this->CNF['OBJECT_GRID_ADMINISTRATION']
+        );
+    }
+}
+
+/** @} */

+ 142 - 0
modules/boonex/videos/updates/9.0.4_10.0.0/source/classes/BxVideosModule.php

@@ -0,0 +1,142 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Videos Videos
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+/**
+ * Videos module
+ */
+class BxVideosModule extends BxBaseModTextModule
+{
+    function __construct(&$aModule)
+    {
+        parent::__construct($aModule);
+    }
+
+    /**
+     * @page service Service Calls
+     * @section bx_videos Videos
+     * @subsection bx_videos-page_blocks Page Blocks
+     * @subsubsection bx_videos-entity_video_block entity_video_block
+     * 
+     * @code bx_srv('bx_videos', 'entity_video_block', [...]); @endcode
+     * 
+     * Get page block with video player.
+     *
+     * @param $iContentId (optional) video ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @return HTML string with block content to display on the site or false if there is no enough input data. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxVideosModule::serviceEntityVideoBlock
+     */
+    /** 
+     * @ref bx_videos-entity_video_block "entity_video_block"
+     */
+    public function serviceEntityVideoBlock ($iContentId = 0)
+    {
+        $mixedContent = $this->_getContent($iContentId);
+        if($mixedContent === false)
+            return false;
+
+        list($iContentId, $aContentInfo) = $mixedContent;
+
+        return $this->_oTemplate->entryVideo($aContentInfo);
+    }
+
+	/**
+     * @page service Service Calls
+     * @section bx_videos Videos
+     * @subsection bx_videos-page_blocks Page Blocks
+     * @subsubsection bx_videos-entity_rating entity_rating
+     * 
+     * @code bx_srv('bx_videos', 'entity_rating', [...]); @endcode
+     * 
+     * Get page block with Stars based video's rating.
+     *
+     * @param $iContentId (optional) video ID. If empty value is provided, an attempt to get it from GET/POST arrays will be performed.
+     * @return HTML string with block content to display on the site or false if there is no enough input data. All necessary CSS and JS files are automatically added to the HEAD section of the site HTML.
+     * 
+     * @see BxVideosModule::serviceEntityRating
+     */
+    /** 
+     * @ref bx_videos-entity_rating "entity_rating"
+     */
+    public function serviceEntityRating($iContentId = 0)
+    {
+    	return $this->_serviceTemplateFunc ('entryRating', $iContentId);
+    }
+
+    protected function _getContentForTimelinePost($aEvent, $aContentInfo, $aBrowseParams = array())
+    {
+        $aResult = parent::_getContentForTimelinePost($aEvent, $aContentInfo, $aBrowseParams);
+
+        if(!empty($aResult['videos']) && is_array($aResult['videos']))
+            $aResult['images'] = array();
+
+        return $aResult;
+    }
+    protected function _getImagesForTimelinePost($aEvent, $aContentInfo, $sUrl, $aBrowseParams = array())
+    {
+        list($sImageThumb, $sImageGallery, $sImageCover) = $this->_oTemplate->getUnitImages($aContentInfo);
+        if(empty($sImageGallery) && !empty($sImageThumb))
+            $sImageGallery = $sImageThumb;
+
+        if(empty($sImageGallery))
+            return array();
+
+        return array(
+            array('url' => $sUrl, 'src' => $sImageGallery, 'src_orig' => $sImageCover),
+        );
+    }
+
+    protected function _getVideosForTimelinePost($aEvent, $aContentInfo, $sUrl, $aBrowseParams = array())
+    {
+        $CNF = &$this->_oConfig->CNF;
+
+        if(empty($CNF['OBJECT_STORAGE_VIDEOS']) || empty($CNF['OBJECT_VIDEOS_TRANSCODERS']))
+            return array();
+
+        $oStorage = BxDolStorage::getObjectInstance($CNF['OBJECT_STORAGE_VIDEOS']);
+
+        $iFile = (int)$aContentInfo[$CNF['FIELD_VIDEO']];
+        $aFile = $oStorage->getFile($iFile);
+        if(empty($aFile) || !is_array($aFile) || strncmp('video/', $aFile['mime_type'], 6) !== 0)
+            return array();
+
+        $oTcvPoster = BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['poster']);
+        $oTciPoster = BxDolTranscoder::getObjectInstance($CNF['OBJECT_IMAGES_TRANSCODER_POSTER']);
+        $oTcvMp4 = BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4']);
+        $oTcvMp4Hd = BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4_hd']);
+        if(!($oTcvPoster || $oTciPoster) || !$oTcvMp4 || !$oTcvMp4Hd)
+            return array();
+
+        $sPosterSrc = !empty($CNF['FIELD_POSTER']) ? $CNF['FIELD_POSTER'] : $CNF['FIELD_THUMB'];
+        if(!empty($sPosterSrc) && !empty($aContentInfo[$sPosterSrc]) && $oTciPoster)
+            $sPoster = $oTciPoster->getFileUrl($aContentInfo[$sPosterSrc]);
+        else 
+            $sPoster = $oTcvPoster->getFileUrl($iFile);
+
+        $sVideoUrl = $oStorage->getFileUrlById($iFile);
+        $aVideoSize = $oTcvMp4Hd->getVideoSize($sVideoUrl);
+
+        $sVideoUrlHd = '';
+        if(!empty($aVideoSize) && is_array($aVideoSize) && (int)$aVideoSize['h'] >= 720)
+            $sVideoUrlHd = $oTcvMp4Hd->getFileUrl($iFile);
+
+        return array(
+            $iFile => array(
+            	'id' => $iFile,
+            	'src_poster' => $sPoster, 
+            	'src_mp4' => $oTcvMp4->getFileUrl($iFile), 
+            	'src_mp4_hd' => $sVideoUrlHd
+            )
+        );
+    }
+}
+
+/** @} */

+ 203 - 0
modules/boonex/videos/updates/9.0.4_10.0.0/source/classes/BxVideosTemplate.php

@@ -0,0 +1,203 @@
+<?php defined('BX_DOL') or die('hack attempt');
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Videos Videos
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+/*
+ * Module representation.
+ */
+class BxVideosTemplate extends BxBaseModTextTemplate
+{
+    /**
+     * Constructor
+     */
+    public function __construct(&$oConfig, &$oDb)
+    {
+        $this->MODULE = 'bx_videos';
+        parent::__construct($oConfig, $oDb);
+    }
+
+    public function entryText ($aData, $sTemplateName = 'entry-text.html')
+    {
+        $aVars = $this->getTmplVarsText($aData);        
+        $mixedResult = $this->parseHtmlByName($sTemplateName, $aVars);
+
+        $sVideoPlayer = $this->entryVideo($aData);
+        if($sVideoPlayer === false)
+            return $mixedResult;
+
+        return $this->parseHtmlByContent($mixedResult, array(
+            'entry_video' => $sVideoPlayer, 
+        ));
+    }
+
+    public function entryVideo ($aContentInfo, $mixedContext = false)
+    {
+        $aTmplVars = array(
+            'video_title' => bx_process_output($aContentInfo['title']),
+            'video_title_attr' => bx_html_attribute($aContentInfo['title']),
+            'video_poster_url' => '',
+            'video' => ''
+        );
+
+        $mixedVideo = $this->getVideo($aContentInfo);
+        if($mixedVideo !== false)
+            $aTmplVars = array_merge($aTmplVars, array(
+                'video_poster_url' => $mixedVideo['poster_url'],
+                'video' => $mixedVideo['player']
+            ));
+
+        return $this->parseHtmlByName('entry-video.html', $aTmplVars);
+    }
+
+    public function entryRating($aData)
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+    	$sVotes = '';
+        $oVotes = BxDolVote::getObjectInstance($CNF['OBJECT_VOTES_STARS'], $aData['id']);
+        if($oVotes) {
+			$sVotes = $oVotes->getElementBlock(array('show_counter' => true, 'show_legend' => true));
+			if(!empty($sVotes))
+				$sVotes = $this->parseHtmlByName('entry-rating.html', array(
+		    		'content' => $sVotes,
+		    	));
+        }
+
+    	return $sVotes; 
+    }
+
+    public function getVideo($aContentInfo)
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $oStorage = BxDolStorage::getObjectInstance($CNF['OBJECT_STORAGE_VIDEOS']);
+
+        $aTranscodersVideo = false;
+        if($CNF['OBJECT_VIDEOS_TRANSCODERS'])
+            $aTranscodersVideo = array (
+                'poster' => BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['poster']),
+                'mp4' => BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4']),
+                'mp4_hd' => BxDolTranscoder::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4_hd']),
+            );
+
+        $iFile = (int)$aContentInfo[$CNF['FIELD_VIDEO']];
+        $aFile = $oStorage->getFile($iFile);
+        if(empty($aFile) || !is_array($aFile) || strncmp('video/', $aFile['mime_type'], 6) !== 0)
+            return false;
+
+        $this->_checkDuration($aContentInfo);
+
+        $sPosterSrc = !empty($CNF['FIELD_POSTER']) ? $CNF['FIELD_POSTER'] : $CNF['FIELD_THUMB'];
+        if(!empty($sPosterSrc) && !empty($aContentInfo[$sPosterSrc]))
+            $sPoster = BxDolTranscoder::getObjectInstance($CNF['OBJECT_IMAGES_TRANSCODER_POSTER'])->getFileUrl($aContentInfo[$sPosterSrc]);
+        else 
+            $sPoster = $aTranscodersVideo['poster']->getFileUrl($iFile);
+
+        $sVideoUrl = $oStorage->getFileUrlById($iFile);
+        $aVideoSize = $aTranscodersVideo['mp4_hd']->getVideoSize($sVideoUrl);
+
+        $sVideoUrlHd = '';
+        if(!empty($aVideoSize) && is_array($aVideoSize) && (int)$aVideoSize['h'] >= 720)
+            $sVideoUrlHd = $aTranscodersVideo['mp4_hd']->getFileUrl($iFile);
+
+        return array(
+            'poster_url' => $aTranscodersVideo['poster']->getFileUrl($iFile),
+            'player' => BxTemplFunctions::getInstance()->videoPlayer(
+                $sPoster, 
+                $aTranscodersVideo['mp4']->getFileUrl($iFile), 
+                $sVideoUrlHd, false, 'max-height:' . $CNF['OBJECT_VIDEO_TRANSCODER_HEIGHT']
+            )
+        );
+    }
+
+    public function getUnitImages ($aData)
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        list($sImageThumb, $sImageGallery) = $this->getUnitThumbAndGallery ($aData);
+
+        $sImageCover = $this->_getUnitImage($CNF['FIELD_THUMB'], $CNF['OBJECT_IMAGES_TRANSCODER_COVER'], $aData);
+        if(!empty($sImageCover))
+            return array($sImageThumb, $sImageGallery, $sImageCover);
+
+        $sImageCover = $this->_getUnitImage($CNF['FIELD_VIDEO'], $CNF['OBJECT_VIDEOS_TRANSCODERS']['poster'], $aData);
+        if(!empty($sImageCover))
+            return array($sImageThumb, $sImageGallery, $sImageCover);
+
+        return array($sImageThumb, $sImageGallery, '');
+    }
+
+    protected function getUnit($aData, $aParams = array())
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $this->_checkDuration($aData);
+
+        $aUnit = parent::getUnit($aData, $aParams);
+        $aUnit['bx_if:thumb']['content']['duration'] = _t_format_duration($aData[$CNF['FIELD_DURATION']]);
+
+        return $aUnit;
+    }
+
+    /**
+     * Use Gallery image for both because currently there is no Unit types with small thumbnails.
+     */
+    protected function getUnitThumbAndGallery ($aData)
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $sImage = $this->_getUnitImage($CNF['FIELD_THUMB'], $CNF['OBJECT_IMAGES_TRANSCODER_GALLERY'], $aData);
+        if(!empty($sImage))
+            return array($sImage, $sImage);
+
+        $sImage = $this->_getUnitImage($CNF['FIELD_VIDEO'], $CNF['OBJECT_VIDEOS_TRANSCODERS']['poster_gallery'], $aData);
+        if(!empty($sImage))
+            return array($sImage, $sImage);
+
+        return array('', '');
+    }
+    
+    protected function _getUnitImage ($sField, $sTranscoder, &$aData)
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $sImage = '';
+        if(empty($sField) || empty($aData[$sField])) 
+            return $sImage;
+
+        $oImagesTranscoder = BxDolTranscoderImage::getObjectInstance($sTranscoder);
+        if($oImagesTranscoder)
+            $sImage = $oImagesTranscoder->getFileUrl($aData[$sField]);
+
+        return $sImage;
+    }
+
+    protected function _checkDuration(&$aContentInfo) 
+    {
+        $CNF = &$this->getModule()->_oConfig->CNF;
+
+        $iVideo = (int)$aContentInfo[$CNF['FIELD_VIDEO']];
+        if(empty($iVideo) || !empty($aContentInfo[$CNF['FIELD_DURATION']]))
+            return;
+
+        $sFile = BxDolTranscoderImage::getObjectInstance($CNF['OBJECT_VIDEOS_TRANSCODERS']['mp4'])->getFileUrl($iVideo);
+        if(empty($sFile))
+            return;
+
+        $iDuration = BxDolTranscoderVideo::getDuration($sFile);
+        if(empty($iDuration))
+            return;
+
+        $this->_oDb->updateEntries(array($CNF['FIELD_DURATION'] => $iDuration), array($CNF['FIELD_ID'] => $aContentInfo[$CNF['FIELD_ID']]));
+    }
+
+}
+
+/** @} */

+ 142 - 0
modules/boonex/videos/updates/9.0.4_10.0.0/source/install/config.php

@@ -0,0 +1,142 @@
+<?php
+/**
+ * Copyright (c) UNA, Inc - https://una.io
+ * MIT License - https://opensource.org/licenses/MIT
+ *
+ * @defgroup    Videos Videos
+ * @ingroup     UnaModules
+ *
+ * @{
+ */
+
+$aConfig = array(
+
+    /**
+     * Main Section.
+     */
+    'type' => BX_DOL_MODULE_TYPE_MODULE,
+    'name' => 'bx_videos',
+    'title' => 'Videos',
+    'note' => 'Basic video posting module.',
+    'version' => '10.0.0',
+    'vendor' => 'BoonEx',
+	'help_url' => 'http://feed.una.io/?section={module_name}',
+
+    'compatible_with' => array(
+        '10.0.0-B1'
+    ),
+
+    /**
+     * 'home_dir' and 'home_uri' - should be unique. Don't use spaces in 'home_uri' and the other special chars.
+     */
+    'home_dir' => 'boonex/videos/',
+    'home_uri' => 'videos',
+
+    'db_prefix' => 'bx_videos_',
+    'class_prefix' => 'BxVideos',
+
+    /**
+     * Category for language keys.
+     */
+    'language_category' => 'Videos',
+
+    /**
+     * List of page triggers.
+     */
+    'page_triggers' => array (
+    	'trigger_page_profile_view_entry',
+    ),
+    
+    /**
+     * Menu triggers.
+     */
+    'menu_triggers' => array(
+    	'trigger_profile_view_submenu',
+        'trigger_group_view_submenu'
+    ),
+
+    /**
+     * Storage objects to automatically delete files from upon module uninstallation.
+     * Note. Don't add storage objects used in transcoder objects.
+     */
+    'storages' => array(
+    	'bx_videos_files'
+    ),
+
+    /**
+     * Transcoders.
+     */
+    'transcoders' => array(
+        'bx_videos_preview',
+        'bx_videos_gallery',
+        'bx_videos_cover',
+        'bx_videos_poster',
+        'bx_videos_video_poster_preview',
+        'bx_videos_video_poster_gallery',
+        'bx_videos_video_poster_cover',
+        'bx_videos_video_mp4',
+        'bx_videos_video_mp4_hd'
+    ),
+
+    /**
+     * Extended Search Forms.
+     */
+    'esearches' => array(
+        'bx_videos',
+    	'bx_videos_cmts'
+    ),
+
+    /**
+     * Installation/Uninstallation Section.
+     */
+    'install' => array(
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'uninstall' => array (
+    	'process_esearches' => 1,
+        'execute_sql' => 1,
+        'update_languages' => 1,
+        'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable' => array(
+        'execute_sql' => 1,
+        'update_relations' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'enable_success' => array(
+        'process_menu_triggers' => 1,
+        'process_page_triggers' => 1,
+    	'process_esearches' => 1,
+        'register_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable' => array (
+        'execute_sql' => 1,
+        'update_relations' => 1,
+        'unregister_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+    'disable_failed' => array (
+        'register_transcoders' => 1,
+        'clear_db_cache' => 1,
+    ),
+
+    /**
+     * Dependencies Section
+     */
+    'dependencies' => array(),
+
+    /**
+     * Relations Section
+     */
+    'relations' => array(
+    	'bx_timeline',
+    	'bx_notifications'
+    ),
+
+);
+
+/** @} */

+ 228 - 0
modules/boonex/videos/updates/9.0.4_10.0.0/source/install/langs/en.xml

@@ -0,0 +1,228 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources name="en" flag="gb" title="English">
+
+	<string name="_bx_videos"><![CDATA[Videos]]></string>
+	<string name="_bx_videos_cmts"><![CDATA[Videos' Comments]]></string>
+
+	<string name="_bx_videos_option_summary_chars"><![CDATA[Number of characters in auto-cropped video summary]]></string>
+	<string name="_bx_videos_option_plain_summary_chars"><![CDATA[Number of characters in plain video description when video hasn't thumb]]></string>
+	<string name="_bx_videos_option_per_page_browse"><![CDATA[Number of items per page]]></string>
+	<string name="_bx_videos_option_per_page_profile"><![CDATA[Number of items on profile/group page]]></string>
+	<string name="_bx_videos_option_rss_num"><![CDATA[Number of items in RSS feed]]></string>
+	<string name="_bx_videos_option_searchable_fields"><![CDATA[Searchable fields for keyword search]]></string>
+
+	<string name="_bx_videos_form_entry"><![CDATA[Videos]]></string>
+	<string name="_bx_videos_form_entry_display_add"><![CDATA[Add Video]]></string>
+	<string name="_bx_videos_form_entry_display_edit"><![CDATA[Edit Video]]></string>
+	<string name="_bx_videos_form_entry_display_delete"><![CDATA[Delete Video]]></string>
+	<string name="_bx_videos_form_entry_display_view"><![CDATA[View Video]]></string>
+	<string name="_bx_videos_form_entry_input_author"><![CDATA[Author]]></string>
+	<string name="_bx_videos_form_entry_input_sys_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_videos_form_entry_input_do_submit"><![CDATA[Submit]]></string>
+	<string name="_bx_videos_form_entry_input_sys_do_publish"><![CDATA[Publish]]></string>
+	<string name="_bx_videos_form_entry_input_do_publish"><![CDATA[Publish]]></string>
+	<string name="_bx_videos_form_entry_input_sys_title"><![CDATA[Title]]></string>
+	<string name="_bx_videos_form_entry_input_title"><![CDATA[Title]]></string>
+	<string name="_bx_videos_form_entry_input_title_err"><![CDATA[Title is essential. Please, fill in this field]]></string>
+	<string name="_bx_videos_form_entry_input_sys_cat"><![CDATA[Category]]></string>
+	<string name="_bx_videos_form_entry_input_cat"><![CDATA[Category]]></string>
+    <string name="_bx_videos_form_entry_input_cat_err"><![CDATA[Please select category]]></string>
+	<string name="_bx_videos_form_entry_input_sys_text"><![CDATA[Text]]></string>
+	<string name="_bx_videos_form_entry_input_text"><![CDATA[Text]]></string>
+	<string name="_bx_videos_form_entry_input_sys_duration"><![CDATA[Duration]]></string>
+    <string name="_bx_videos_form_entry_input_duration"><![CDATA[Duration]]></string>
+	<string name="_bx_videos_form_entry_input_sys_delete_confirm"><![CDATA[Delete confirmation]]></string>
+	<string name="_bx_videos_form_entry_input_delete_confirm"><![CDATA[I am sure I want to delete this video]]></string>
+	<string name="_bx_videos_form_entry_input_delete_confirm_info"><![CDATA[This action can not be undone]]></string>
+	<string name="_bx_videos_form_entry_input_delete_confirm_error"><![CDATA[Please check this checkbox if you really want to delete the video]]></string>
+	<string name="_bx_videos_form_entry_input_sys_pictures"><![CDATA[Pictures]]></string>
+	<string name="_bx_videos_form_entry_input_pictures"><![CDATA[Pictures]]></string>
+	<string name="_bx_videos_form_entry_input_sys_videos"><![CDATA[Video]]></string>
+    <string name="_bx_videos_form_entry_input_videos"><![CDATA[Video]]></string>
+    <string name="_bx_videos_form_entry_input_videos_error"><![CDATA[Video is essential. Please upload a video file.]]></string>
+    <string name="_bx_videos_form_entry_input_videos_upload"><![CDATA[Upload]]></string>
+    <string name="_bx_videos_form_entry_input_sys_allow_view_to"><![CDATA[Visibility]]></string>
+    <string name="_bx_videos_form_entry_input_allow_view_to"><![CDATA[Visibility]]></string>
+    <string name="_bx_videos_form_entry_input_picture_use_as_thumb"><![CDATA[Poster Image]]></string>
+    <string name="_bx_videos_form_entry_input_picture_use_as_poster"><![CDATA[Poster Image]]></string>
+    <string name="_bx_videos_form_entry_input_sys_date_added"><![CDATA[Created]]></string>
+    <string name="_bx_videos_form_entry_input_date_added"><![CDATA[Created]]></string>
+    <string name="_bx_videos_form_entry_input_sys_date_changed"><![CDATA[Updated]]></string>
+    <string name="_bx_videos_form_entry_input_date_changed"><![CDATA[Updated]]></string>
+
+	<string name="_bx_videos_acl_action_create_entry"><![CDATA[Create Video]]></string>
+	<string name="_bx_videos_acl_action_delete_entry"><![CDATA[Delete Video]]></string>
+	<string name="_bx_videos_acl_action_view_entry"><![CDATA[View Video]]></string>
+	<string name="_bx_videos_acl_action_set_thumb"><![CDATA[Set Video Thumbnail]]></string>
+	<string name="_bx_videos_acl_action_edit_any_entry"><![CDATA[Edit Any Video]]></string>
+
+	<string name="_bx_videos_page_title_sys_create_entry"><![CDATA[New Video]]></string>
+	<string name="_bx_videos_page_title_create_entry"><![CDATA[New Video]]></string>
+	<string name="_bx_videos_page_block_title_create_entry"><![CDATA[New Video]]></string>
+	<string name="_bx_videos_page_title_sys_edit_entry"><![CDATA[Edit]]></string>
+	<string name="_bx_videos_page_title_edit_entry"><![CDATA[Edit]]></string>
+	<string name="_bx_videos_page_block_title_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_videos_page_title_sys_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_videos_page_title_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_videos_page_block_title_delete_entry"><![CDATA[Delete]]></string>
+	<string name="_bx_videos_page_title_sys_view_entry"><![CDATA[View Video]]></string>
+	<string name="_bx_videos_page_title_view_entry"><![CDATA[{title}]]></string>
+	<string name="_bx_videos_page_block_title_entry_text"><![CDATA[Text]]></string>
+	<string name="_bx_videos_page_block_title_entry_video"><![CDATA[Video]]></string>
+	<string name="_bx_videos_page_title_browse"><![CDATA[Videos]]></string>
+	<string name="_bx_videos_page_title_search_results"><![CDATA[Videos matching "{0}"]]></string>
+	<string name="_bx_videos_page_title_browse_by_author"><![CDATA[Videos of {display_name}]]></string>
+  <string name="_bx_videos_page_title_browse_by_context"><![CDATA[Videos in {display_name}]]></string>
+	<string name="_bx_videos_page_title_browse_featured"><![CDATA[Featured Videos]]></string>
+    <string name="_bx_videos_page_title_browse_recent"><![CDATA[Latest Videos]]></string>
+    <string name="_bx_videos_page_title_browse_popular"><![CDATA[Popular Videos]]></string>
+    <string name="_bx_videos_page_title_browse_updated"><![CDATA[Updated Videos]]></string>
+    <string name="_bx_videos_page_title_sys_home"><![CDATA[Videos Home]]></string>
+    <string name="_bx_videos_page_title_home"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_page_block_title_featured_entries"><![CDATA[Featured Videos (Gallery View)]]></string>
+    <string name="_bx_videos_page_block_title_featured_entries_view_extended"><![CDATA[Featured Videos]]></string>
+    <string name="_bx_videos_page_block_title_featured_entries_view_full"><![CDATA[Featured Videos (Full View)]]></string>
+    <string name="_bx_videos_page_block_title_recent_entries"><![CDATA[Latest Videos (Gallery View)]]></string>
+    <string name="_bx_videos_page_block_title_recent_entries_view_extended"><![CDATA[Latest Videos]]></string>
+    <string name="_bx_videos_page_block_title_recent_entries_view_full"><![CDATA[Latest Videos (Full View)]]></string>
+    <string name="_bx_videos_page_block_title_entry_social_sharing"><![CDATA[Share]]></string>
+    <string name="_bx_videos_page_block_title_entry_author"><![CDATA[Author]]></string>
+    <string name="_bx_videos_page_block_title_entry_actions"><![CDATA[Actions]]></string>
+    <string name="_bx_videos_page_block_title_entry_comments"><![CDATA[Comments]]></string>
+    <string name="_bx_videos_page_block_title_entry_comments_link"><![CDATA[Comments to <a href="{entry_link}">{title}</a>]]></string>
+    <string name="_bx_videos_page_block_title_entry_location"><![CDATA[Location]]></string>
+    <string name="_bx_videos_page_block_title_entry_attachments"><![CDATA[Attachments]]></string>
+    <string name="_bx_videos_page_block_title_entry_all_actions"><![CDATA[All Actions]]></string>
+    <string name="_bx_videos_page_block_title_entry_rating"><![CDATA[Rating]]></string>
+    <string name="_bx_videos_page_title_sys_entries_popular"><![CDATA[Popular Videos]]></string>
+    <string name="_bx_videos_page_title_entries_popular"><![CDATA[Popular Videos]]></string>
+    <string name="_bx_videos_page_title_sys_entries_updated"><![CDATA[Updated Videos]]></string>
+    <string name="_bx_videos_page_title_entries_updated"><![CDATA[Updated Videos]]></string>
+    <string name="_bx_videos_page_title_sys_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_videos_page_title_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_videos_page_block_title_search_form"><![CDATA[Search Form]]></string>
+    <string name="_bx_videos_page_block_title_search_results"><![CDATA[Search Results]]></string>
+    <string name="_bx_videos_page_block_title_search_form_cmts"><![CDATA[Comments Search Form]]></string>
+    <string name="_bx_videos_page_block_title_search_results_cmts"><![CDATA[Comments Search Results]]></string>
+    <string name="_bx_videos_page_block_title_popular_entries"><![CDATA[Popular Videos]]></string>
+    <string name="_bx_videos_page_block_title_popular_entries_view_extended"><![CDATA[Popular Videos (Extended View)]]></string>
+    <string name="_bx_videos_page_block_title_popular_entries_view_full"><![CDATA[Popular Videos (Full View)]]></string>
+    <string name="_bx_videos_page_block_title_updated_entries"><![CDATA[Updated Videos]]></string>
+    <string name="_bx_videos_page_title_sys_view_entry_comments"><![CDATA[Video Comments]]></string>
+    <string name="_bx_videos_page_title_view_entry_comments"><![CDATA[Comments to {title}]]></string>
+    <string name="_bx_videos_page_title_sys_entries_of_author"><![CDATA[Videos of author]]></string>
+    <string name="_bx_videos_page_title_entries_of_author"><![CDATA[Videos by {display_name}]]></string>
+    <string name="_bx_videos_page_title_sys_entries_in_context"><![CDATA[Videos in context]]></string>
+    <string name="_bx_videos_page_title_entries_in_context"><![CDATA[Videos in {display_name}]]></string>
+    <string name="_bx_videos_page_block_title_favorites_of_author"><![CDATA[Favorites by <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_videos_page_block_title_sys_favorites_of_author"><![CDATA[Favorites of author]]></string>
+    <string name="_bx_videos_page_block_title_entries_of_author"><![CDATA[Videos by <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_videos_page_block_title_sys_entries_of_author"><![CDATA[Videos of author]]></string>
+    <string name="_bx_videos_page_block_title_entries_in_context"><![CDATA[Videos in <a href="{profile_link}">{display_name}</a>]]></string>
+    <string name="_bx_videos_page_block_title_sys_entries_in_context"><![CDATA[Videos in context]]></string>
+    <string name="_bx_videos_page_block_title_entries_actions"><![CDATA[Videos actions]]></string>
+    <string name="_bx_videos_page_block_title_browse_cmts"><![CDATA[Videos' Comments]]></string>
+	<string name="_bx_videos_page_title_sys_manage"><![CDATA[Manage Own]]></string>
+	<string name="_bx_videos_page_title_sys_manage_administration"><![CDATA[Manage All]]></string>
+	<string name="_bx_videos_page_title_manage"><![CDATA[Manage]]></string>
+	<string name="_bx_videos_page_block_title_system_manage"><![CDATA[Manage Own]]></string>
+	<string name="_bx_videos_page_block_title_system_manage_administration"><![CDATA[Manage All]]></string>
+	<string name="_bx_videos_page_block_title_manage"><![CDATA[Manage]]></string>    
+	<string name="_bx_videos_page_block_title_popular_keywords"><![CDATA[Popular Hashtags]]></string>
+	<string name="_bx_videos_page_block_title_cats"><![CDATA[Videos Categories]]></string>
+	<string name="_bx_videos_page_block_title_entry_info"><![CDATA[Info]]></string>
+	<string name="_bx_videos_page_block_title_my_entries"><![CDATA[My Videos]]></string>
+    <string name="_bx_videos_page_block_title_sys_recent_entries_view_showcase"><![CDATA[Latest Videos (Showcase View)]]></string>
+    <string name="_bx_videos_page_block_title_recent_entries_view_showcase"><![CDATA[Latest Videos]]></string>
+    <string name="_bx_videos_page_block_title_sys_popular_entries_view_showcase"><![CDATA[Popular Videos (Showcase View)]]></string>
+    <string name="_bx_videos_page_block_title_popular_entries_view_showcase"><![CDATA[Popular Videos]]></string>
+    <string name="_bx_videos_page_block_title_sys_featured_entries_view_showcase"><![CDATA[Featured Videos (Showcase View)]]></string>
+    <string name="_bx_videos_page_block_title_featured_entries_view_showcase"><![CDATA[Featured Videos]]></string>
+    <string name="_bx_videos_page_block_title_sys_entry_context"><![CDATA[Posted in]]></string>
+    <string name="_bx_videos_page_block_title_entry_context"><![CDATA[Posted in]]></string>
+
+    <string name="_bx_videos_menu_set_title_view_entry"><![CDATA[Video Actions]]></string>
+    <string name="_bx_videos_menu_title_view_entry"><![CDATA[Video Actions]]></string>
+    <string name="_bx_videos_menu_title_submenu"><![CDATA[Videos Submenu]]></string>
+    <string name="_bx_videos_menu_set_title_submenu"><![CDATA[Videos Submenu]]></string>
+    <string name="_bx_videos_menu_item_title_system_create_entry"><![CDATA[Video]]></string>
+    <string name="_bx_videos_menu_item_title_create_entry"><![CDATA[Video]]></string>
+    <string name="_bx_videos_menu_item_title_system_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_videos_menu_item_title_edit_entry"><![CDATA[Edit]]></string>
+    <string name="_bx_videos_menu_item_title_system_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_videos_menu_item_title_delete_entry"><![CDATA[Delete]]></string>
+    <string name="_bx_videos_menu_item_title_system_view_entry"><![CDATA[View Video]]></string>
+    <string name="_bx_videos_menu_item_title_system_entries_home"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_item_title_entries_home"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_item_title_system_entries_public"><![CDATA[Latest]]></string>
+    <string name="_bx_videos_menu_item_title_entries_public"><![CDATA[Latest]]></string>
+    <string name="_bx_videos_menu_item_title_system_entries_manage"><![CDATA[Manage]]></string>
+    <string name="_bx_videos_menu_item_title_entries_manage"><![CDATA[Manage]]></string>
+    <string name="_bx_videos_menu_item_title_system_entries_popular"><![CDATA[Popular]]></string>
+    <string name="_bx_videos_menu_item_title_entries_popular"><![CDATA[Popular]]></string>
+    <string name="_bx_videos_menu_item_title_system_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_videos_menu_item_title_entries_search"><![CDATA[Search]]></string>
+    <string name="_bx_videos_menu_title_view_entry_submenu"><![CDATA[View Video Submenu]]></string>
+    <string name="_bx_videos_menu_set_title_view_entry_submenu"><![CDATA[View Video Submenu]]></string>
+    <string name="_bx_videos_menu_item_title_view_entry_submenu_entry"><![CDATA[Video]]></string>
+    <string name="_bx_videos_menu_item_title_view_entry_submenu_comments"><![CDATA[Comments]]></string>
+    <string name="_bx_videos_menu_item_title_system_view_entry_comments"><![CDATA[Video Comments]]></string>
+    <string name="_bx_videos_menu_item_title_system_view_entries_author"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_item_title_view_entries_author"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_item_title_system_view_entries_in_context"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_item_title_view_entries_in_context"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_title_entries_my"><![CDATA[My Videos Action Menu]]></string>
+    <string name="_bx_videos_menu_set_title_entries_my"><![CDATA[My Videos Menu]]></string>
+	<string name="_bx_videos_menu_item_title_system_manage_my_videos"><![CDATA[My videos]]></string>
+    <string name="_bx_videos_menu_item_title_manage_my_videos"><![CDATA[Videos]]></string>
+    <string name="_bx_videos_menu_set_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+    <string name="_bx_videos_menu_title_manage_tools"><![CDATA[Manage Tools Submenu]]></string>
+    <string name="_bx_videos_menu_item_title_system_manage_account"><![CDATA[Manage account]]></string>
+    <string name="_bx_videos_menu_item_title_manage_account"><![CDATA[Manage account]]></string>
+	<string name="_bx_videos_menu_item_title_system_admt_videos"><![CDATA[Videos]]></string>
+	<string name="_bx_videos_menu_item_title_admt_videos"><![CDATA[Videos]]></string>
+	<string name="_bx_videos_menu_item_title_manage_my"><![CDATA[My Videos]]></string>
+	<string name="_bx_videos_menu_item_title_manage_all"><![CDATA[All Videos]]></string>
+
+	<string name="_bx_videos_grid_filter_item_title_adm_select_one_filter1"><![CDATA[All Statuses]]></string>
+	<string name="_bx_videos_grid_filter_item_title_adm_active"><![CDATA[Active]]></string>
+	<string name="_bx_videos_grid_filter_item_title_adm_hidden"><![CDATA[Hidden]]></string>
+	<string name="_bx_videos_grid_column_title_adm_active"><![CDATA[Active]]></string>
+    <string name="_bx_videos_grid_column_title_adm_title"><![CDATA[Title]]></string>
+    <string name="_bx_videos_grid_column_title_adm_added"><![CDATA[Added]]></string>
+    <string name="_bx_videos_grid_column_title_adm_author"><![CDATA[Author]]></string>
+    <string name="_bx_videos_grid_action_title_adm_edit"><![CDATA[Edit]]></string>
+    <string name="_bx_videos_grid_action_title_adm_delete"><![CDATA[Delete]]></string>
+    <string name="_bx_videos_grid_action_title_adm_more_actions"><![CDATA[More Actions]]></string>
+    <string name="_bx_videos_grid_action_err_delete"><![CDATA[Cannot delete the selected video(s).]]></string>
+    <string name="_bx_videos_grid_txt_account_manager"><![CDATA[Redirect to manage account.]]></string>
+
+    <string name="_bx_videos_chart_growth"><![CDATA[Videos: Growth]]></string>
+    <string name="_bx_videos_chart_growth_speed"><![CDATA[Videos: Growth Speed]]></string>
+
+    <string name="_bx_videos_search_extended"><![CDATA[Videos Search]]></string>
+    <string name="_bx_videos_search_extended_cmts"><![CDATA[Videos Comments Search]]></string>
+
+    <string name="_bx_videos_pre_lists_cats"><![CDATA[Video categories]]></string>
+    <string name="_bx_videos_cat_animals_and_pets"><![CDATA[Animals & Pets]]></string>
+    <string name="_bx_videos_cat_education"><![CDATA[Education]]></string>
+    <string name="_bx_videos_cat_entertainment"><![CDATA[Entertainment]]></string>
+    <string name="_bx_videos_cat_film_and_animation"><![CDATA[Film & Animation]]></string>
+    <string name="_bx_videos_cat_music"><![CDATA[Music]]></string>
+    <string name="_bx_videos_cat_news"><![CDATA[News]]></string>
+    <string name="_bx_videos_cat_people_and_blogs"><![CDATA[People & Blogs]]></string>
+    <string name="_bx_videos_cat_sports"><![CDATA[Sports]]></string>
+    <string name="_bx_videos_cat_travel"><![CDATA[Travel]]></string>
+
+    <string name="_bx_videos_txt_all_entries_by"><![CDATA[<a href="{0}">All Videos by {1} ({2})</a>]]></string>
+    <string name="_bx_videos_txt_all_entries_in"><![CDATA[<a href="{0}">All Videos in {1} ({2})</a>]]></string>
+    <string name="_bx_videos_txt_sample_single"><![CDATA[video]]></string>
+    <string name="_bx_videos_txt_sample_single_with_article"><![CDATA[a video]]></string>
+    <string name="_bx_videos_txt_sample_comment_single"><![CDATA[comment to video]]></string>
+    <string name="_bx_videos_txt_sample_vote_single"><![CDATA[vote to video]]></string>
+    <string name="_bx_videos_txt_sample_score_up_single"><![CDATA[score up vote to video]]></string>
+    <string name="_bx_videos_txt_sample_score_down_single"><![CDATA[score down vote to video]]></string>
+    <string name="_bx_videos_txt_n_views"><![CDATA[{0} views]]></string>
+    <string name="_bx_videos_txt_processing_awaiting"><![CDATA[Scheduled for publishing as soon as video conversion is complete.]]></string>
+    <string name="_bx_videos_txt_processing_failed"><![CDATA[Video isn't published because video conversion failed, edit video to fix the issue.]]></string>
+</resources>

+ 430 - 0
modules/boonex/videos/updates/9.0.4_10.0.0/source/install/sql/enable.sql

@@ -0,0 +1,430 @@
+
+-- SETTINGS
+SET @iTypeOrder = (SELECT MAX(`order`) FROM `sys_options_types` WHERE `group` = 'modules');
+INSERT INTO `sys_options_types`(`group`, `name`, `caption`, `icon`, `order`) VALUES 
+('modules', 'bx_videos', '_bx_videos', 'bx_videos@modules/boonex/videos/|std-icon.svg', IF(ISNULL(@iTypeOrder), 1, @iTypeOrder + 1));
+SET @iTypeId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options_categories` (`type_id`, `name`, `caption`, `order`)
+VALUES (@iTypeId, 'bx_videos', '_bx_videos', 1);
+SET @iCategId = LAST_INSERT_ID();
+
+INSERT INTO `sys_options` (`name`, `value`, `category_id`, `caption`, `type`, `check`, `check_error`, `extra`, `order`) VALUES
+('bx_videos_summary_chars', '700', @iCategId, '_bx_videos_option_summary_chars', 'digit', '', '', '', 1),
+('bx_videos_plain_summary_chars', '240', @iCategId, '_bx_videos_option_plain_summary_chars', 'digit', '', '', '', 2),
+('bx_videos_per_page_browse', '12', @iCategId, '_bx_videos_option_per_page_browse', 'digit', '', '', '', 10),
+('bx_videos_per_page_profile', '6', @iCategId, '_bx_videos_option_per_page_profile', 'digit', '', '', '', 12),
+('bx_videos_per_page_browse_showcase', '32', @iCategId, '_sys_option_per_page_browse_showcase', 'digit', '', '', '', 15),
+('bx_videos_rss_num', '10', @iCategId, '_bx_videos_option_rss_num', 'digit', '', '', '', 20),
+('bx_videos_searchable_fields', 'title,text', @iCategId, '_bx_videos_option_searchable_fields', 'list', '', '', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:21:"get_searchable_fields";}', 30);
+
+-- PAGE: create entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_create_entry', '_bx_videos_page_title_sys_create_entry', '_bx_videos_page_title_create_entry', 'bx_videos', 5, 2147483647, 1, 'create-video', 'page.php?i=create-video', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_videos_create_entry', 1, 'bx_videos', '_bx_videos_page_block_title_create_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"entity_create";}', 0, 1, 1);
+
+-- PAGE: edit entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_edit_entry', '_bx_videos_page_title_sys_edit_entry', '_bx_videos_page_title_edit_entry', 'bx_videos', 5, 2147483647, 1, 'edit-video', '', '', '', '', 0, 1, 0, 'BxVideosPageEntry', 'modules/boonex/videos/classes/BxVideosPageEntry.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_videos_edit_entry', 1, 'bx_videos', '_bx_videos_page_block_title_edit_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:11:"entity_edit";}', 0, 0, 0);
+
+-- PAGE: delete entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_delete_entry', '_bx_videos_page_title_sys_delete_entry', '_bx_videos_page_title_delete_entry', 'bx_videos', 5, 2147483647, 1, 'delete-video', '', '', '', '', 0, 1, 0, 'BxVideosPageEntry', 'modules/boonex/videos/classes/BxVideosPageEntry.php');
+
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('bx_videos_delete_entry', 1, 'bx_videos', '_bx_videos_page_block_title_delete_entry', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"entity_delete";}', 0, 0, 0);
+
+-- PAGE: view entry
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_view_entry', '_bx_videos_page_title_sys_view_entry', '_bx_videos_page_title_view_entry', 'bx_videos', 12, 2147483647, 1, 'view-video', '', '', '', '', 0, 1, 0, 'BxVideosPageEntry', 'modules/boonex/videos/classes/BxVideosPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES
+('bx_videos_view_entry', 2, 'bx_videos', '', '_bx_videos_page_block_title_entry_video', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:18:"entity_video_block";}', 0, 0, 0, 0),
+('bx_videos_view_entry', 2, 'bx_videos', '', '_bx_videos_page_block_title_entry_text', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:17:"entity_text_block";}', 0, 0, 1, 1),
+('bx_videos_view_entry', 2, 'bx_videos', '', '_bx_videos_page_block_title_entry_author', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"entity_author";}', 0, 0, 1, 3),
+('bx_videos_view_entry', 3, 'bx_videos', '_bx_videos_page_block_title_sys_entry_context', '_bx_videos_page_block_title_entry_context', 13, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_videos\";s:6:\"method\";s:14:\"entity_context\";}', 0, 0, 1, 1),
+('bx_videos_view_entry', 2, 'bx_videos', '', '_bx_videos_page_block_title_entry_rating', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"entity_rating";}', 0, 0, 0, 0),
+('bx_videos_view_entry', 3, 'bx_videos', '', '_bx_videos_page_block_title_entry_info', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:11:"entity_info";}', 0, 0, 1, 2),
+('bx_videos_view_entry', 3, 'bx_videos', '', '_bx_videos_page_block_title_entry_location', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"entity_location";}', 0, 0, 0, 0),
+('bx_videos_view_entry', 2, 'bx_videos', '', '_bx_videos_page_block_title_entry_all_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:18:"entity_all_actions";}', 0, 0, 1, 2),
+('bx_videos_view_entry', 4, 'bx_videos', '', '_bx_videos_page_block_title_entry_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:14:"entity_actions";}', 0, 0, 0, 0),
+('bx_videos_view_entry', 4, 'bx_videos', '', '_bx_videos_page_block_title_entry_social_sharing', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:21:"entity_social_sharing";}', 0, 0, 0, 0),
+('bx_videos_view_entry', 4, 'bx_videos', '', '_bx_videos_page_block_title_entry_attachments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:18:"entity_attachments";}', 0, 0, 0, 0),
+('bx_videos_view_entry', 2, 'bx_videos', '', '_bx_videos_page_block_title_entry_comments', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"entity_comments";}', 0, 0, 1, 4),
+('bx_videos_view_entry', 3, 'bx_videos', '', '_bx_videos_page_block_title_entry_location', 3, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:13:"locations_map";s:6:"params";a:2:{i:0;s:9:"bx_videos";i:1;s:4:"{id}";}s:5:"class";s:20:"TemplServiceMetatags";}', 0, 0, 1, 3),
+('bx_videos_view_entry', 3, 'bx_videos', '', '_bx_videos_page_block_title_featured_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 0, 1, 4);
+
+-- PAGE: view entry comments
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_view_entry_comments', '_bx_videos_page_title_sys_view_entry_comments', '_bx_videos_page_title_view_entry_comments', 'bx_videos', 5, 2147483647, 1, 'view-video-comments', '', '', '', '', 0, 1, 0, 'BxVideosPageEntry', 'modules/boonex/videos/classes/BxVideosPageEntry.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_videos_view_entry_comments', 1, 'bx_videos', '_bx_videos_page_block_title_entry_comments', '_bx_videos_page_block_title_entry_comments_link', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"entity_comments";}', 0, 0, 1);
+
+-- PAGE: popular entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_popular', '_bx_videos_page_title_sys_entries_popular', '_bx_videos_page_title_entries_popular', 'bx_videos', 5, 2147483647, 1, 'videos-popular', 'page.php?i=videos-popular', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_videos_popular', 1, 'bx_videos', '_bx_videos_page_block_title_popular_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:14:"browse_popular";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, 1);
+
+-- PAGE: recently updated entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_updated', '_bx_videos_page_title_sys_entries_updated', '_bx_videos_page_title_entries_updated', 'bx_videos', 5, 2147483647, 1, 'videos-updated', 'page.php?i=videos-updated', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_videos_updated', 1, 'bx_videos', '_bx_videos_page_block_title_updated_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:14:"browse_updated";s:6:"params";a:3:{s:9:"unit_view";s:7:"gallery";s:13:"empty_message";b:1;s:13:"ajax_paginate";b:0;}}', 0, 1, 1);
+
+-- PAGE: entries of author
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_author', 'videos-author', '_bx_videos_page_title_sys_entries_of_author', '_bx_videos_page_title_entries_of_author', 'bx_videos', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxVideosPageAuthor', 'modules/boonex/videos/classes/BxVideosPageAuthor.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_videos_author', 1, 'bx_videos', '', '_bx_videos_page_block_title_entries_actions', 13, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:18:"my_entries_actions";}', 0, 0, 1, 1),
+('bx_videos_author', 1, 'bx_videos', '_bx_videos_page_block_title_sys_favorites_of_author', '_bx_videos_page_block_title_favorites_of_author', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"browse_favorite";s:6:"params";a:1:{i:0;s:12:"{profile_id}";}}', 0, 1, 1, 2),
+('bx_videos_author', 1, 'bx_videos', '_bx_videos_page_block_title_sys_entries_of_author', '_bx_videos_page_block_title_entries_of_author', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"browse_author";}', 0, 0, 1, 3);
+
+-- PAGE: entries in context
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_context', 'videos-context', '_bx_videos_page_title_sys_entries_in_context', '_bx_videos_page_title_entries_in_context', 'bx_videos', 5, 2147483647, 1, '', '', '', '', 0, 1, 0, 'BxVideosPageAuthor', 'modules/boonex/videos/classes/BxVideosPageAuthor.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_videos_context', 1, 'bx_videos', '_bx_videos_page_block_title_sys_entries_in_context', '_bx_videos_page_block_title_entries_in_context', 11, 2147483647, 'service', 'a:2:{s:6:\"module\";s:9:\"bx_videos\";s:6:\"method\";s:14:\"browse_context\";}', 0, 0, 1, 1);
+
+
+-- PAGE: module home
+INSERT INTO `sys_objects_page`(`object`, `uri`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_home', 'videos-home', '_bx_videos_page_title_sys_home', '_bx_videos_page_title_home', 'bx_videos', 2, 2147483647, 1, 'page.php?i=videos-home', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_videos_home', 1, 'bx_videos', '', '_bx_videos_page_block_title_featured_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, 1, 0),
+('bx_videos_home', 1, 'bx_videos', '', '_bx_videos_page_block_title_recent_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, 1, 1),
+('bx_videos_home', 2, 'bx_videos', '', '_bx_videos_page_block_title_popular_keywords', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:14:"keywords_cloud";s:6:"params";a:2:{i:0;s:9:"bx_videos";i:1;s:9:"bx_videos";}s:5:"class";s:20:"TemplServiceMetatags";}', 0, 1, 1, 0),
+('bx_videos_home', 2, 'bx_videos', '', '_bx_videos_page_block_title_cats', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:15:"categories_list";s:6:"params";a:2:{i:0;s:14:"bx_videos_cats";i:1;a:1:{s:10:"show_empty";b:1;}}s:5:"class";s:20:"TemplServiceCategory";}', 0, 1, 1, 1);
+
+-- PAGE: search for entries
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_search', '_bx_videos_page_title_sys_entries_search', '_bx_videos_page_title_entries_search', 'bx_videos', 5, 2147483647, 1, 'videos-search', 'page.php?i=videos-search', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('bx_videos_search', 1, 'bx_videos', '_bx_videos_page_block_title_search_form', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:9:"bx_videos";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 1),
+('bx_videos_search', 1, 'bx_videos', '_bx_videos_page_block_title_search_results', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:9:"bx_videos";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 1, 2),
+('bx_videos_search', 1, 'bx_videos', '_bx_videos_page_block_title_search_form_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:8:"get_form";s:6:"params";a:1:{i:0;a:1:{s:6:"object";s:14:"bx_videos_cmts";}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 3),
+('bx_videos_search', 1, 'bx_videos', '_bx_videos_page_block_title_search_results_cmts', 11, 2147483647, 'service', 'a:4:{s:6:"module";s:6:"system";s:6:"method";s:11:"get_results";s:6:"params";a:1:{i:0;a:2:{s:6:"object";s:14:"bx_videos_cmts";s:10:"show_empty";b:1;}}s:5:"class";s:27:"TemplSearchExtendedServices";}', 0, 1, 0, 4);
+
+-- PAGE: module manage own
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_manage', '_bx_videos_page_title_sys_manage', '_bx_videos_page_title_manage', 'bx_videos', 5, 2147483647, 1, 'videos-manage', 'page.php?i=videos-manage', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_videos_manage', 1, 'bx_videos', '_bx_videos_page_block_title_system_manage', '_bx_videos_page_block_title_manage', 11, 2147483647, 'service', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:12:"manage_tools";}}', 0, 1, 0);
+
+-- PAGE: module manage all
+INSERT INTO `sys_objects_page`(`object`, `title_system`, `title`, `module`, `layout_id`, `visible_for_levels`, `visible_for_levels_editable`, `uri`, `url`, `meta_description`, `meta_keywords`, `meta_robots`, `cache_lifetime`, `cache_editable`, `deletable`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_administration', '_bx_videos_page_title_sys_manage_administration', '_bx_videos_page_title_manage', 'bx_videos', 5, 192, 1, 'videos-administration', 'page.php?i=videos-administration', '', '', '', 0, 1, 0, 'BxVideosPageBrowse', 'modules/boonex/videos/classes/BxVideosPageBrowse.php');
+
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('bx_videos_administration', 1, 'bx_videos', '_bx_videos_page_block_title_system_manage_administration', '_bx_videos_page_block_title_manage', 11, 192, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:12:"manage_tools";s:6:"params";a:1:{i:0;s:14:"administration";}}', 0, 1, 0);
+
+-- PAGE: add block to homepage
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = 'sys_home' AND `cell_id` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `active`, `order`) VALUES 
+('sys_home', 1, 'bx_videos', '_bx_videos_page_block_title_recent_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"browse_public";s:6:"params";a:2:{i:0;b:0;i:1;b:0;}}', 1, 0, 0, IFNULL(@iBlockOrder, 0) + 1);
+
+-- PAGES: add page block to profiles modules (trigger* page objects are processed separately upon modules enable/disable)
+SET @iPBCellProfile = 3;
+INSERT INTO `sys_pages_blocks` (`object`, `cell_id`, `module`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES
+('trigger_page_profile_view_entry', @iPBCellProfile, 'bx_videos', '_bx_videos_page_block_title_my_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"browse_author";s:6:"params";a:2:{i:0;s:12:"{profile_id}";i:1;a:2:{s:8:"per_page";s:26:"bx_videos_per_page_profile";s:13:"empty_message";b:0;}}}', 0, 0, 0);
+
+-- PAGE: service blocks
+SET @iBlockOrder = (SELECT `order` FROM `sys_pages_blocks` WHERE `object` = '' AND `cell_id` = 0 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_pages_blocks`(`object`, `cell_id`, `module`, `title_system`, `title`, `designbox_id`, `visible_for_levels`, `type`, `content`, `deletable`, `copyable`, `order`) VALUES 
+('', 0, 'bx_videos', '', '_bx_videos_page_block_title_recent_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:7:"gallery";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 1),
+('', 0, 'bx_videos', '', '_bx_videos_page_block_title_recent_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:13:"browse_public";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 2),
+('', 0, 'bx_videos', '', '_bx_videos_page_block_title_popular_entries_view_extended', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:14:"browse_popular";s:6:"params";a:1:{i:0;s:8:"extended";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 3),
+('', 0, 'bx_videos', '', '_bx_videos_page_block_title_popular_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:14:"browse_popular";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 4),
+('', 0, 'bx_videos', '', '_bx_videos_page_block_title_featured_entries', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:7:"gallery";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 5),
+('', 0, 'bx_videos', '', '_bx_videos_page_block_title_featured_entries_view_full', 11, 2147483647, 'service', 'a:3:{s:6:"module";s:9:"bx_videos";s:6:"method";s:15:"browse_featured";s:6:"params";a:1:{i:0;s:4:"full";}}', 0, 1, IFNULL(@iBlockOrder, 0) + 6),
+('', 0, 'bx_videos', '_bx_videos_page_block_title_sys_recent_entries_view_showcase', '_bx_videos_page_block_title_recent_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_videos\";s:6:\"method\";s:13:\"browse_public\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 7),
+('', 0, 'bx_videos', '_bx_videos_page_block_title_sys_popular_entries_view_showcase', '_bx_videos_page_block_title_popular_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_videos\";s:6:\"method\";s:14:\"browse_popular\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 8),
+('', 0, 'bx_videos', '_bx_videos_page_block_title_sys_featured_entries_view_showcase', '_bx_videos_page_block_title_featured_entries_view_showcase', 11, 2147483647, 'service', 'a:3:{s:6:\"module\";s:9:\"bx_videos\";s:6:\"method\";s:15:\"browse_featured\";s:6:\"params\";a:3:{s:9:\"unit_view\";s:8:\"showcase\";s:13:\"empty_message\";b:0;s:13:\"ajax_paginate\";b:0;}}', 0, 1, IFNULL(@iBlockOrder, 0) + 9);
+
+
+-- MENU: add to site menu
+SET @iSiteMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_site' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_site', 'bx_videos', 'videos-home', '_bx_videos_menu_item_title_system_entries_home', '_bx_videos_menu_item_title_entries_home', 'page.php?i=videos-home', '', '', 'film col-gray', 'bx_videos_submenu', 2147483647, 1, 1, IFNULL(@iSiteMenuOrder, 0) + 1);
+
+-- MENU: add to homepage menu
+SET @iHomepageMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_homepage' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_homepage', 'bx_videos', 'videos-home', '_bx_videos_menu_item_title_system_entries_home', '_bx_videos_menu_item_title_entries_home', 'page.php?i=videos-home', '', '', 'film col-gray', 'bx_videos_submenu', 2147483647, 1, 1, IFNULL(@iHomepageMenuOrder, 0) + 1);
+
+-- MENU: add to "add content" menu
+SET @iAddMenuOrder = (SELECT `order` FROM `sys_menu_items` WHERE `set_name` = 'sys_add_content_links' AND `active` = 1 ORDER BY `order` DESC LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_add_content_links', 'bx_videos', 'create-video', '_bx_videos_menu_item_title_system_create_entry', '_bx_videos_menu_item_title_create_entry', 'page.php?i=create-video', '', '', 'film col-gray', '', 2147483647, 1, 1, IFNULL(@iAddMenuOrder, 0) + 1);
+
+-- MENU: actions menu for view entry 
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_view', '_bx_videos_menu_title_view_entry', 'bx_videos_view', 'bx_videos', 9, 0, 1, 'BxVideosMenuView', 'modules/boonex/videos/classes/BxVideosMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_view', 'bx_videos', '_bx_videos_menu_set_title_view_entry', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_videos_view', 'bx_videos', 'edit-video', '_bx_videos_menu_item_title_system_edit_entry', '_bx_videos_menu_item_title_edit_entry', 'page.php?i=edit-video&id={content_id}', '', '', 'pencil-alt', '', 2147483647, 1, 0, 1),
+('bx_videos_view', 'bx_videos', 'delete-video', '_bx_videos_menu_item_title_system_delete_entry', '_bx_videos_menu_item_title_delete_entry', 'page.php?i=delete-video&id={content_id}', '', '', 'remove', '', 2147483647, 1, 0, 2);
+
+-- MENU: all actions menu for view entry 
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_view_actions', '_sys_menu_title_view_actions', 'bx_videos_view_actions', 'bx_videos', 15, 0, 1, 'BxVideosMenuViewActions', 'modules/boonex/videos/classes/BxVideosMenuViewActions.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_view_actions', 'bx_videos', '_sys_menu_set_title_view_actions', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `submenu_popup`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_videos_view_actions', 'bx_videos', 'edit-video', '_bx_videos_menu_item_title_system_edit_entry', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 10),
+('bx_videos_view_actions', 'bx_videos', 'delete-video', '_bx_videos_menu_item_title_system_delete_entry', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 20),
+('bx_videos_view_actions', 'bx_videos', 'comment', '_sys_menu_item_title_system_va_comment', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 200),
+('bx_videos_view_actions', 'bx_videos', 'view', '_sys_menu_item_title_system_va_view', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 210),
+('bx_videos_view_actions', 'bx_videos', 'vote', '_sys_menu_item_title_system_va_vote', '', '', '', '', '', '', '', 0, 2147483647, 0, 0, 220),
+('bx_videos_view_actions', 'bx_videos', 'reaction', '_sys_menu_item_title_system_va_reaction', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 225),
+('bx_videos_view_actions', 'bx_videos', 'score', '_sys_menu_item_title_system_va_score', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 230),
+('bx_videos_view_actions', 'bx_videos', 'favorite', '_sys_menu_item_title_system_va_favorite', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 240),
+('bx_videos_view_actions', 'bx_videos', 'feature', '_sys_menu_item_title_system_va_feature', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 250),
+('bx_videos_view_actions', 'bx_videos', 'repost', '_sys_menu_item_title_system_va_repost', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 260),
+('bx_videos_view_actions', 'bx_videos', 'report', '_sys_menu_item_title_system_va_report', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 270),
+('bx_videos_view_actions', 'bx_videos', 'social-sharing-facebook', '_sys_menu_item_title_system_social_sharing_facebook', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 300),
+('bx_videos_view_actions', 'bx_videos', 'social-sharing-twitter', '_sys_menu_item_title_system_social_sharing_twitter', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 320),
+('bx_videos_view_actions', 'bx_videos', 'social-sharing-pinterest', '_sys_menu_item_title_system_social_sharing_pinterest', '', '', '', '', '', '', '', 0, 2147483647, 1, 0, 330),
+('bx_videos_view_actions', 'bx_videos', 'more-auto', '_sys_menu_item_title_system_va_more_auto', '_sys_menu_item_title_va_more_auto', 'javascript:void(0)', '', '', 'ellipsis-v', '', '', 0, 2147483647, 1, 0, 9999);
+
+-- MENU: actions menu for my entries
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_my', '_bx_videos_menu_title_entries_my', 'bx_videos_my', 'bx_videos', 9, 0, 1, 'BxVideosMenu', 'modules/boonex/videos/classes/BxVideosMenu.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_my', 'bx_videos', '_bx_videos_menu_set_title_entries_my', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_videos_my', 'bx_videos', 'create-video', '_bx_videos_menu_item_title_system_create_entry', '_bx_videos_menu_item_title_create_entry', 'page.php?i=create-video', '', '', 'plus', '', 2147483647, 1, 0, 0);
+
+-- MENU: module sub-menu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_submenu', '_bx_videos_menu_title_submenu', 'bx_videos_submenu', 'bx_videos', 8, 0, 1, '', '');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_submenu', 'bx_videos', '_bx_videos_menu_set_title_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_videos_submenu', 'bx_videos', 'videos-home', '_bx_videos_menu_item_title_system_entries_public', '_bx_videos_menu_item_title_entries_public', 'page.php?i=videos-home', '', '', '', '', 2147483647, 1, 1, 1),
+('bx_videos_submenu', 'bx_videos', 'videos-popular', '_bx_videos_menu_item_title_system_entries_popular', '_bx_videos_menu_item_title_entries_popular', 'page.php?i=videos-popular', '', '', '', '', 2147483647, 1, 1, 2),
+('bx_videos_submenu', 'bx_videos', 'videos-search', '_bx_videos_menu_item_title_system_entries_search', '_bx_videos_menu_item_title_entries_search', 'page.php?i=videos-search', '', '', '', '', 2147483647, 1, 1, 3),
+('bx_videos_submenu', 'bx_videos', 'videos-manage', '_bx_videos_menu_item_title_system_entries_manage', '_bx_videos_menu_item_title_entries_manage', 'page.php?i=videos-manage', '', '', '', '', 2147483646, 1, 1, 4);
+
+-- MENU: sub-menu for view entry
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_view_submenu', '_bx_videos_menu_title_view_entry_submenu', 'bx_videos_view_submenu', 'bx_videos', 8, 0, 1, 'BxVideosMenuView', 'modules/boonex/videos/classes/BxVideosMenuView.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_view_submenu', 'bx_videos', '_bx_videos_menu_set_title_view_entry_submenu', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('bx_videos_view_submenu', 'bx_videos', 'view-video', '_bx_videos_menu_item_title_system_view_entry', '_bx_videos_menu_item_title_view_entry_submenu_entry', 'page.php?i=view-video&id={content_id}', '', '', '', '', 2147483647, 0, 0, 1),
+('bx_videos_view_submenu', 'bx_videos', 'view-video-comments', '_bx_videos_menu_item_title_system_view_entry_comments', '_bx_videos_menu_item_title_view_entry_submenu_comments', 'page.php?i=view-video-comments&id={content_id}', '', '', '', '', 2147483647, 0, 0, 2);
+
+-- MENU: custom menu for snippet meta info
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_snippet_meta', '_sys_menu_title_snippet_meta', 'bx_videos_snippet_meta', 'bx_videos', 15, 0, 1, 'BxVideosMenuSnippetMeta', 'modules/boonex/videos/classes/BxVideosMenuSnippetMeta.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_snippet_meta', 'bx_videos', '_sys_menu_set_title_snippet_meta', 0);
+
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `editable`, `order`) VALUES 
+('bx_videos_snippet_meta', 'bx_videos', 'date', '_sys_menu_item_title_system_sm_date', '_sys_menu_item_title_sm_date', '', '', '', '', '', 2147483647, 1, 0, 1, 1),
+('bx_videos_snippet_meta', 'bx_videos', 'rating', '_sys_menu_item_title_system_sm_rating', '_sys_menu_item_title_sm_rating', '', '', '', '', '', 2147483647, 1, 0, 1, 2),
+('bx_videos_snippet_meta', 'bx_videos', 'author', '_sys_menu_item_title_system_sm_author', '_sys_menu_item_title_sm_author', '', '', '', '', '', 2147483647, 1, 0, 1, 3),
+('bx_videos_snippet_meta', 'bx_videos', 'category', '_sys_menu_item_title_system_sm_category', '_sys_menu_item_title_sm_category', '', '', '', '', '', 2147483647, 0, 0, 1, 4),
+('bx_videos_snippet_meta', 'bx_videos', 'tags', '_sys_menu_item_title_system_sm_tags', '_sys_menu_item_title_sm_tags', '', '', '', '', '', 2147483647, 0, 0, 1, 5),
+('bx_videos_snippet_meta', 'bx_videos', 'views', '_sys_menu_item_title_system_sm_views', '_sys_menu_item_title_sm_views', '', '', '', '', '', 2147483647, 0, 0, 1, 6),
+('bx_videos_snippet_meta', 'bx_videos', 'comments', '_sys_menu_item_title_system_sm_comments', '_sys_menu_item_title_sm_comments', '', '', '', '', '', 2147483647, 0, 0, 1, 7);
+
+-- MENU: profile stats
+SET @iNotifMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name` = 'sys_profile_stats' AND `active` = 1 LIMIT 1);
+INSERT INTO `sys_menu_items` (`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES
+('sys_profile_stats', 'bx_videos', 'profile-stats-manage-videos', '_bx_videos_menu_item_title_system_manage_my_videos', '_bx_videos_menu_item_title_manage_my_videos', 'page.php?i=videos-manage', '', '_self', 'film col-gray', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:41:"get_menu_addon_manage_tools_profile_stats";}', '', 2147483646, 1, 0, @iNotifMenuOrder + 1);
+
+-- MENU: manage tools submenu
+INSERT INTO `sys_objects_menu`(`object`, `title`, `set_name`, `module`, `template_id`, `deletable`, `active`, `override_class_name`, `override_class_file`) VALUES 
+('bx_videos_menu_manage_tools', '_bx_videos_menu_title_manage_tools', 'bx_videos_menu_manage_tools', 'bx_videos', 6, 0, 1, 'BxVideosMenuManageTools', 'modules/boonex/videos/classes/BxVideosMenuManageTools.php');
+
+INSERT INTO `sys_menu_sets`(`set_name`, `module`, `title`, `deletable`) VALUES 
+('bx_videos_menu_manage_tools', 'bx_videos', '_bx_videos_menu_set_title_manage_tools', 0);
+
+--INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+--('bx_videos_menu_manage_tools', 'bx_videos', 'delete-with-content', '_bx_videos_menu_item_title_system_delete_with_content', '_bx_videos_menu_item_title_delete_with_content', 'javascript:void(0)', 'javascript:{js_object}.onClickDeleteWithContent({content_id});', '_self', 'far trash-alt', '', 128, 1, 0, 0);
+
+-- MENU: dashboard manage tools
+SET @iManageMenuOrder = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_menu_items` WHERE `set_name`='sys_account_dashboard_manage_tools' LIMIT 1);
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `addon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('sys_account_dashboard_manage_tools', 'bx_videos', 'videos-administration', '_bx_videos_menu_item_title_system_admt_videos', '_bx_videos_menu_item_title_admt_videos', 'page.php?i=videos-administration', '', '_self', 'film', 'a:2:{s:6:"module";s:9:"bx_videos";s:6:"method";s:27:"get_menu_addon_manage_tools";}', '', 192, 1, 0, @iManageMenuOrder + 1);
+
+-- MENU: add menu item to profiles modules (trigger* menu sets are processed separately upon modules enable/disable)
+INSERT INTO `sys_menu_items`(`set_name`, `module`, `name`, `title_system`, `title`, `link`, `onclick`, `target`, `icon`, `submenu_object`, `visible_for_levels`, `active`, `copyable`, `order`) VALUES 
+('trigger_profile_view_submenu', 'bx_videos', 'videos-author', '_bx_videos_menu_item_title_system_view_entries_author', '_bx_videos_menu_item_title_view_entries_author', 'page.php?i=videos-author&profile_id={profile_id}', '', '', 'film col-gray', '', 2147483647, 1, 0, 0),
+('trigger_group_view_submenu', 'bx_videos', 'videos-context', '_bx_videos_menu_item_title_system_view_entries_in_context', '_bx_videos_menu_item_title_view_entries_in_context', 'page.php?i=videos-context&profile_id={profile_id}', '', '', 'film col-gray', '', 2147483647, 1, 0, 0);
+
+-- PRIVACY 
+INSERT INTO `sys_objects_privacy` (`object`, `module`, `action`, `title`, `default_group`, `table`, `table_field_id`, `table_field_author`, `override_class_name`, `override_class_file`) VALUES
+('bx_videos_allow_view_to', 'bx_videos', 'view', '_bx_videos_form_entry_input_allow_view_to', '3', 'bx_videos_entries', 'id', 'author', '', '');
+
+
+-- ACL
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_videos', 'create entry', NULL, '_bx_videos_acl_action_create_entry', '', 1, 3);
+SET @iIdActionEntryCreate = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_videos', 'delete entry', NULL, '_bx_videos_acl_action_delete_entry', '', 1, 3);
+SET @iIdActionEntryDelete = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_videos', 'view entry', NULL, '_bx_videos_acl_action_view_entry', '', 1, 0);
+SET @iIdActionEntryView = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_videos', 'set thumb', NULL, '_bx_videos_acl_action_set_thumb', '', 1, 3);
+SET @iIdActionSetThumb = LAST_INSERT_ID();
+
+INSERT INTO `sys_acl_actions` (`Module`, `Name`, `AdditionalParamName`, `Title`, `Desc`, `Countable`, `DisabledForLevels`) VALUES
+('bx_videos', 'edit any entry', NULL, '_bx_videos_acl_action_edit_any_entry', '', 1, 3);
+SET @iIdActionEntryEditAny = LAST_INSERT_ID();
+
+SET @iUnauthenticated = 1;
+SET @iAccount = 2;
+SET @iStandard = 3;
+SET @iUnconfirmed = 4;
+SET @iPending = 5;
+SET @iSuspended = 6;
+SET @iModerator = 7;
+SET @iAdministrator = 8;
+SET @iPremium = 9;
+
+INSERT INTO `sys_acl_matrix` (`IDLevel`, `IDAction`) VALUES
+
+-- entry create
+(@iStandard, @iIdActionEntryCreate),
+(@iModerator, @iIdActionEntryCreate),
+(@iAdministrator, @iIdActionEntryCreate),
+(@iPremium, @iIdActionEntryCreate),
+
+-- entry delete
+(@iStandard, @iIdActionEntryDelete),
+(@iModerator, @iIdActionEntryDelete),
+(@iAdministrator, @iIdActionEntryDelete),
+(@iPremium, @iIdActionEntryDelete),
+
+-- entry view
+(@iUnauthenticated, @iIdActionEntryView),
+(@iAccount, @iIdActionEntryView),
+(@iStandard, @iIdActionEntryView),
+(@iUnconfirmed, @iIdActionEntryView),
+(@iPending, @iIdActionEntryView),
+(@iModerator, @iIdActionEntryView),
+(@iAdministrator, @iIdActionEntryView),
+(@iPremium, @iIdActionEntryView),
+
+-- set entry thumb
+(@iStandard, @iIdActionSetThumb),
+(@iModerator, @iIdActionSetThumb),
+(@iAdministrator, @iIdActionSetThumb),
+(@iPremium, @iIdActionSetThumb),
+
+-- edit any entry
+(@iModerator, @iIdActionEntryEditAny),
+(@iAdministrator, @iIdActionEntryEditAny);
+
+
+-- SEARCH
+SET @iSearchOrder = (SELECT IFNULL(MAX(`Order`), 0) FROM `sys_objects_search`);
+INSERT INTO `sys_objects_search` (`ObjectName`, `Title`, `Order`, `ClassName`, `ClassPath`) VALUES
+('bx_videos', '_bx_videos', @iSearchOrder + 1, 'BxVideosSearchResult', 'modules/boonex/videos/classes/BxVideosSearchResult.php'),
+('bx_videos_cmts', '_bx_videos_cmts', @iSearchOrder + 2, 'BxVideosCmtsSearchResult', 'modules/boonex/videos/classes/BxVideosCmtsSearchResult.php');
+
+
+-- METATAGS
+INSERT INTO `sys_objects_metatags` (`object`, `table_keywords`, `table_locations`, `table_mentions`, `override_class_name`, `override_class_file`) VALUES
+('bx_videos', 'bx_videos_meta_keywords', 'bx_videos_meta_locations', 'bx_videos_meta_mentions', '', '');
+
+
+-- CATEGORY
+INSERT INTO `sys_objects_category` (`object`, `search_object`, `form_object`, `list_name`, `table`, `field`, `join`, `where`, `override_class_name`, `override_class_file`) VALUES
+('bx_videos_cats', 'bx_videos', 'bx_videos', 'bx_videos_cats', 'bx_videos_entries', 'cat', 'INNER JOIN `sys_profiles` ON (`sys_profiles`.`id` = `bx_videos_entries`.`author`)', 'AND `sys_profiles`.`status` = ''active''', '', '');
+
+
+-- STATS
+SET @iMaxOrderStats = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_statistics`);
+INSERT INTO `sys_statistics` (`module`, `name`, `title`, `link`, `icon`, `query`, `order`) VALUES 
+('bx_videos', 'bx_videos', '_bx_videos', 'page.php?i=videos-home', 'film col-gray', 'SELECT COUNT(*) FROM `bx_videos_entries` WHERE 1 AND `status` = ''active'' AND `status_admin` = ''active''', @iMaxOrderStats + 1);
+
+
+-- CHARTS
+SET @iMaxOrderCharts = (SELECT IFNULL(MAX(`order`), 0) FROM `sys_objects_chart`);
+INSERT INTO `sys_objects_chart` (`object`, `title`, `table`, `field_date_ts`, `field_date_dt`, `field_status`, `query`, `active`, `order`, `class_name`, `class_file`) VALUES
+('bx_videos_growth', '_bx_videos_chart_growth', 'bx_videos_entries', 'added', '', 'status,status_admin', '', 1, @iMaxOrderCharts + 1, 'BxDolChartGrowth', ''),
+('bx_videos_growth_speed', '_bx_videos_chart_growth_speed', 'bx_videos_entries', 'added', '', 'status,status_admin', '', 1, @iMaxOrderCharts + 2, 'BxDolChartGrowthSpeed', '');
+
+
+-- GRIDS: moderation tools
+INSERT INTO `sys_objects_grid` (`object`, `source_type`, `source`, `table`, `field_id`, `field_order`, `field_active`, `paginate_url`, `paginate_per_page`, `paginate_simple`, `paginate_get_start`, `paginate_get_per_page`, `filter_fields`, `filter_fields_translatable`, `filter_mode`, `sorting_fields`, `sorting_fields_translatable`, `visible_for_levels`, `override_class_name`, `override_class_file`) VALUES
+('bx_videos_administration', 'Sql', 'SELECT * FROM `bx_videos_entries` WHERE 1 ', 'bx_videos_entries', 'id', 'added', 'status_admin', '', 20, NULL, 'start', '', 'title,text', '', 'like', 'reports', '', 192, 'BxVideosGridAdministration', 'modules/boonex/videos/classes/BxVideosGridAdministration.php'),
+('bx_videos_common', 'Sql', 'SELECT * FROM `bx_videos_entries` WHERE 1 ', 'bx_videos_entries', 'id', 'added', 'status', '', 20, NULL, 'start', '', 'title,text', '', 'like', '', '', 2147483647, 'BxVideosGridCommon', 'modules/boonex/videos/classes/BxVideosGridCommon.php');
+
+
+INSERT INTO `sys_grid_fields` (`object`, `name`, `title`, `width`, `translatable`, `chars_limit`, `params`, `order`) VALUES
+('bx_videos_administration', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_videos_administration', 'switcher', '_bx_videos_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_videos_administration', 'reports', '_sys_txt_reports_title', '5%', 0, '', '', 3),
+('bx_videos_administration', 'title', '_bx_videos_grid_column_title_adm_title', '25%', 0, '25', '', 4),
+('bx_videos_administration', 'added', '_bx_videos_grid_column_title_adm_added', '20%', 1, '25', '', 5),
+('bx_videos_administration', 'author', '_bx_videos_grid_column_title_adm_author', '20%', 0, '25', '', 6),
+('bx_videos_administration', 'actions', '', '20%', 0, '', '', 7),
+('bx_videos_common', 'checkbox', '_sys_select', '2%', 0, '', '', 1),
+('bx_videos_common', 'switcher', '_bx_videos_grid_column_title_adm_active', '8%', 0, '', '', 2),
+('bx_videos_common', 'title', '_bx_videos_grid_column_title_adm_title', '40%', 0, '35', '', 3),
+('bx_videos_common', 'added', '_bx_videos_grid_column_title_adm_added', '30%', 1, '25', '', 4),
+('bx_videos_common', 'actions', '', '20%', 0, '', '', 5);
+
+INSERT INTO `sys_grid_actions` (`object`, `type`, `name`, `title`, `icon`, `icon_only`, `confirm`, `order`) VALUES
+('bx_videos_administration', 'bulk', 'delete', '_bx_videos_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_videos_administration', 'single', 'edit', '_bx_videos_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_videos_administration', 'single', 'delete', '_bx_videos_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_videos_administration', 'single', 'settings', '_bx_videos_grid_action_title_adm_more_actions', 'cog', 1, 0, 3),
+('bx_videos_common', 'bulk', 'delete', '_bx_videos_grid_action_title_adm_delete', '', 0, 1, 1),
+('bx_videos_common', 'single', 'edit', '_bx_videos_grid_action_title_adm_edit', 'pencil-alt', 1, 0, 1),
+('bx_videos_common', 'single', 'delete', '_bx_videos_grid_action_title_adm_delete', 'remove', 1, 1, 2),
+('bx_videos_common', 'single', 'settings', '_bx_videos_grid_action_title_adm_more_actions', 'cog', 1, 0, 3);
+
+
+-- UPLOADERS
+INSERT INTO `sys_objects_uploader` (`object`, `active`, `override_class_name`, `override_class_file`) VALUES
+('bx_videos_simple', 1, 'BxVideosUploaderSimple', 'modules/boonex/videos/classes/BxVideosUploaderSimple.php'),
+('bx_videos_html5', 1, 'BxVideosUploaderHTML5', 'modules/boonex/videos/classes/BxVideosUploaderHTML5.php');
+
+
+-- ALERTS
+INSERT INTO `sys_alerts_handlers` (`name`, `class`, `file`, `service_call`) VALUES 
+('bx_videos', 'BxVideosAlertsResponse', 'modules/boonex/videos/classes/BxVideosAlertsResponse.php', '');
+SET @iHandler := LAST_INSERT_ID();
+
+INSERT INTO `sys_alerts` (`unit`, `action`, `handler_id`) VALUES
+('system', 'save_setting', @iHandler),
+('profile', 'delete', @iHandler),
+
+('bx_videos_video_mp4', 'transcoded', @iHandler);

Einige Dateien werden nicht angezeigt, da zu viele Dateien in diesem Diff geändert wurden.