diff --git a/.gitattributes b/.gitattributes index 36484a9..19ab0d2 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,31 +1,15 @@ * text=auto !eol -changed_full/420-448/out/basic/de/d3_usersonline_lang.php -text -changed_full/420-448/out/basic/tpl/_left.tpl -text -changed_full/420-448/out/basic/tpl/inc/d3usersonline.tpl -text -changed_full/450/out/azure/de/d3_usersonline_lang.php -text -changed_full/450/out/azure/tpl/inc/d3usersonline.tpl -text -changed_full/450/out/azure/tpl/layout/sidebar.tpl -text -changed_full/450/out/basic/de/d3_usersonline_lang.php -text -changed_full/450/out/basic/tpl/_left.tpl -text -changed_full/450/out/basic/tpl/inc/d3usersonline.tpl -text -changed_full/451-453/out/azure/de/d3_usersonline_lang.php -text -changed_full/451-453/out/azure/tpl/inc/d3usersonline.tpl -text -changed_full/451-453/out/azure/tpl/layout/sidebar.tpl -text -changed_full/451-453/out/basic/de/d3_usersonline_lang.php -text -changed_full/451-453/out/basic/tpl/_left.tpl -text -changed_full/451-453/out/basic/tpl/inc/d3usersonline.tpl -text -changed_full/461/out/admin/de/d3_usersonline_lang.php -text -changed_full/461/out/azure/tpl/inc/d3usersonline.tpl -text -changed_full/461/out/azure/tpl/layout/sidebar.tpl -text -changed_full/461/out/basic/tpl/_left.tpl -text -changed_full/461/out/basic/tpl/inc/d3usersonline.tpl -text -changed_full/461/out/de/d3_usersonline_lang.php -text +changed_full/EE500-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl -text +changed_full/PE470-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl -text copy_this/modules/d3/d3usersonline/metadata.php -text copy_this/modules/d3/d3usersonline/models/d3usersonline.php -text +copy_this/modules/d3/d3usersonline/models/d3usersonline_update.php -text copy_this/modules/d3/d3usersonline/modules/components/d3_oxcmp_utils_usersonline.php -text copy_this/modules/d3/d3usersonline/picture.png -text +copy_this/modules/d3/d3usersonline/translations/de/d3usersonline_lang.php -text +copy_this/modules/d3/d3usersonline/translations/en/d3usersonline_lang.php -text setup+doku/Installation.pdf -text -setup+doku/install.sql -text +setup+doku/d3precheck.php -text source/Re[!!-~]D3[!!-~]Users[!!-~]Online[!!-~]kit[!!-~]Oxid[!!-~]CE[!!-~]4.7.eml -text source/UsersOnline[!!-~]v1.2.1[!!-~]CE4_Kundenversion_4.7.0.zip -text source/UsersOnline-Installation.docx -text diff --git a/changed_full/420-448/out/basic/de/d3_usersonline_lang.php b/changed_full/420-448/out/basic/de/d3_usersonline_lang.php deleted file mode 100644 index 34d61c2..0000000 --- a/changed_full/420-448/out/basic/de/d3_usersonline_lang.php +++ /dev/null @@ -1,34 +0,0 @@ - 'ISO-8859-15', -'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', -'D3_USERSONLINE_USER' => 'Benutzer', -'D3_USERSONLINE_USERS' => 'Benutzer', -'D3_USERSONLINE_ALL' => 'gesamt', - -); - -/* -[{ oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE' }] -*/ \ No newline at end of file diff --git a/changed_full/420-448/out/basic/tpl/_left.tpl b/changed_full/420-448/out/basic/tpl/_left.tpl deleted file mode 100644 index bd6d191..0000000 --- a/changed_full/420-448/out/basic/tpl/_left.tpl +++ /dev/null @@ -1,79 +0,0 @@ -[{if $oView->showSearch() }] - [{ oxmultilang ident="INC_LEFTITEM_PRODUCTSEARCH" }] - -[{/if}] -[{if $oxcmp_categories }] - [{if $oView->showTopCatNavigation()}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() class="tree"}] - [{else}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories act=$oxcmp_categories->getClickCat() class="tree"}] - [{/if}] -[{/if}] - -[{if $oView->loadVendorTree() && $oView->getVendorlist()}] - [{include file="inc/vendor_tree.tpl" tree=$oView->getVendorlist() class="tree"}] -[{/if}] - -[{if $oView->loadManufacturerTree() && $oView->getManufacturerlist()}] - [{include file="inc/manufacturer_tree.tpl" tree=$oView->getManufacturerlist() class="tree"}] -[{/if}] - -[{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] -[{*** D3 Modul "UsersOnline" END ***}] - -[{if $oView->showLeftBasket()}] - [{oxid_include_dynamic file="dyn/mini_basket.tpl" type="basket" testid="LeftBasket"}] -[{/if}] - -[{include file="inc/infobox.tpl"}] - -[{if $oxcmp_news && count($oxcmp_news) > 0}] - [{include file="inc/cmp_news.tpl"}] -[{/if}] - -[{ oxmultilang ident="INC_LEFTITEM_PARTNERANDSEAL" }] -
- - -
- - diff --git a/changed_full/420-448/out/basic/tpl/inc/d3usersonline.tpl b/changed_full/420-448/out/basic/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 58b70df..0000000 --- a/changed_full/420-448/out/basic/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,43 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] - [{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}] -
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/450/out/azure/de/d3_usersonline_lang.php b/changed_full/450/out/azure/de/d3_usersonline_lang.php deleted file mode 100644 index 34d61c2..0000000 --- a/changed_full/450/out/azure/de/d3_usersonline_lang.php +++ /dev/null @@ -1,34 +0,0 @@ - 'ISO-8859-15', -'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', -'D3_USERSONLINE_USER' => 'Benutzer', -'D3_USERSONLINE_USERS' => 'Benutzer', -'D3_USERSONLINE_ALL' => 'gesamt', - -); - -/* -[{ oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE' }] -*/ \ No newline at end of file diff --git a/changed_full/450/out/azure/tpl/inc/d3usersonline.tpl b/changed_full/450/out/azure/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 215e0b8..0000000 --- a/changed_full/450/out/azure/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,45 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] -
-

[{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}]

-
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/450/out/azure/tpl/layout/sidebar.tpl b/changed_full/450/out/azure/tpl/layout/sidebar.tpl deleted file mode 100644 index f820a02..0000000 --- a/changed_full/450/out/azure/tpl/layout/sidebar.tpl +++ /dev/null @@ -1,70 +0,0 @@ -[{if $oView->isDemoShop()}] - [{ include file="widget/sidebar/adminbanner.tpl" }] -[{/if}] - -[{if $oxcmp_categories }] -[{capture append="oxidBlock_sidebar" }] - [{include file="widget/sidebar/categoriestree.tpl" categories=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() deepLevel=0}] -[{/capture}] -[{/if}] - -[{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] -[{*** D3 Modul "UsersOnline" END ***}] - -[{if $oView->getClassName() eq "start" && $oView->getTop5ArticleList()}] -[{capture append="oxidBlock_sidebar" }] - [{include file="widget/product/boxproducts.tpl" _boxId="topBox" _oBoxProducts=$oView->getTop5ArticleList() _sHeaderIdent="BOX_TOPOFTHESHOP_HEADER"}] -[{/capture}] -[{/if}] - -[{if $oViewConf->getShowListmania() }] -[{capture append="oxidBlock_sidebar"}] - [{include file="widget/sidebar/recommendation.tpl"}] -[{/capture}] -[{/if}] - -[{if $oView->getClassName() ne "details" && $oView->getClassName() ne "tags"}] - [{if $oView->getTagCloudManager() }] - [{capture append="oxidBlock_sidebar"}] - [{include file="widget/sidebar/tags.tpl" oTagsManager=$oView->getTagCloudManager()}] - [{/capture}] - [{/if}] -[{/if}] - -[{if $oxcmp_news|count }] -[{capture append="oxidBlock_sidebar"}] - [{include file="widget/sidebar/news.tpl" oNews=$oxcmp_news}] -[{/capture}] -[{/if}] - -[{if $oView->isActive('FbFacepile') && $oView->isConnectedWithFb()}] -[{capture append="oxidBlock_sidebar"}] - [{include file="widget/facebook/facepile.tpl"}] -[{/capture}] -[{/if}] - -[{if $oView->getClassName() eq "start"}] - [{capture append="oxidBlock_sidebar"}] - [{include file="widget/sidebar/partners.tpl" }] - [{/capture}] -[{/if}] - -[{if $oView->getClassName() eq "start"}] - [{if $oViewConf->showTs("WIDGET")}] - [{capture append="oxidBlock_sidebar"}] - [{include file="widget/trustedshops/ratings.tpl" }] - [{/capture}] - [{/if}] -[{/if}] - -[{if $oView->getClassName() eq "start"}] - [{capture append="oxidBlock_sidebar"}] - [{include file="widget/shoplupe/ratings.tpl" }] - [{/capture}] -[{/if}] - -[{foreach from=$oxidBlock_sidebar item="_block"}] - [{$_block}] -[{/foreach}] - diff --git a/changed_full/450/out/basic/de/d3_usersonline_lang.php b/changed_full/450/out/basic/de/d3_usersonline_lang.php deleted file mode 100644 index 34d61c2..0000000 --- a/changed_full/450/out/basic/de/d3_usersonline_lang.php +++ /dev/null @@ -1,34 +0,0 @@ - 'ISO-8859-15', -'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', -'D3_USERSONLINE_USER' => 'Benutzer', -'D3_USERSONLINE_USERS' => 'Benutzer', -'D3_USERSONLINE_ALL' => 'gesamt', - -); - -/* -[{ oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE' }] -*/ \ No newline at end of file diff --git a/changed_full/450/out/basic/tpl/_left.tpl b/changed_full/450/out/basic/tpl/_left.tpl deleted file mode 100644 index 9b17045..0000000 --- a/changed_full/450/out/basic/tpl/_left.tpl +++ /dev/null @@ -1,79 +0,0 @@ -[{if $oView->showSearch() }] - [{ oxmultilang ident="INC_LEFTITEM_PRODUCTSEARCH" }] - -[{/if}] -[{if $oxcmp_categories }] - [{if $oView->showTopCatNavigation()}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() class="tree"}] - [{else}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories act=$oxcmp_categories->getClickCat() class="tree"}] - [{/if}] -[{/if}] - -[{if $oView->loadVendorTree() && $oView->getVendorlist()}] - [{include file="inc/vendor_tree.tpl" tree=$oView->getVendorlist() class="tree"}] -[{/if}] - -[{if $oView->loadManufacturerTree() && $oView->getManufacturerlist()}] - [{include file="inc/manufacturer_tree.tpl" tree=$oView->getManufacturerlist() class="tree"}] -[{/if}] - -[{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] -[{*** D3 Modul "UsersOnline" END ***}] - -[{if $oView->showLeftBasket()}] - [{oxid_include_dynamic file="dyn/mini_basket.tpl" type="basket" testid="LeftBasket"}] -[{/if}] - -[{include file="inc/infobox.tpl"}] - -[{if $oxcmp_news && count($oxcmp_news) > 0}] - [{include file="inc/cmp_news.tpl"}] -[{/if}] - -[{ oxmultilang ident="INC_LEFTITEM_PARTNERANDSEAL" }] -
- - -
- - diff --git a/changed_full/450/out/basic/tpl/inc/d3usersonline.tpl b/changed_full/450/out/basic/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 58b70df..0000000 --- a/changed_full/450/out/basic/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,43 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] - [{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}] -
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/451-453/out/azure/de/d3_usersonline_lang.php b/changed_full/451-453/out/azure/de/d3_usersonline_lang.php deleted file mode 100644 index 34d61c2..0000000 --- a/changed_full/451-453/out/azure/de/d3_usersonline_lang.php +++ /dev/null @@ -1,34 +0,0 @@ - 'ISO-8859-15', -'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', -'D3_USERSONLINE_USER' => 'Benutzer', -'D3_USERSONLINE_USERS' => 'Benutzer', -'D3_USERSONLINE_ALL' => 'gesamt', - -); - -/* -[{ oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE' }] -*/ \ No newline at end of file diff --git a/changed_full/451-453/out/azure/tpl/inc/d3usersonline.tpl b/changed_full/451-453/out/azure/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 215e0b8..0000000 --- a/changed_full/451-453/out/azure/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,45 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] -
-

[{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}]

-
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/451-453/out/azure/tpl/layout/sidebar.tpl b/changed_full/451-453/out/azure/tpl/layout/sidebar.tpl deleted file mode 100644 index 69eab76..0000000 --- a/changed_full/451-453/out/azure/tpl/layout/sidebar.tpl +++ /dev/null @@ -1,74 +0,0 @@ -[{foreach from=$oxidBlock_sidebar item="_block"}] - [{$_block}] -[{/foreach}] - -[{block name="sidebar"}] - [{block name="sidebar_adminbanner"}] - [{if $oView->isDemoShop()}] - [{ include file="widget/sidebar/adminbanner.tpl" }] - [{/if}] - [{/block}] - - [{block name="sidebar_categoriestree"}] - [{if $oxcmp_categories }] - [{include file="widget/sidebar/categoriestree.tpl" categories=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() deepLevel=0}] - [{/if}] - [{/block}] - -[{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] -{{*** D3 Modul "UsersOnline" END ***}] - - [{block name="sidebar_trustedshopsratings"}] - [{if $oView->getClassName() eq "start"}] - [{if $oViewConf->showTs("WIDGET")}] - [{include file="widget/trustedshops/ratings.tpl" }] - [{/if}] - [{/if}] - [{/block}] - - [{block name="sidebar_partners"}] - [{if $oView->getClassName() eq "start"}] - [{include file="widget/sidebar/partners.tpl" }] - [{/if}] - [{/block}] - - [{block name="sidebar_boxproducts"}] - [{if $oView->getClassName() eq "start" && $oView->getTop5ArticleList()}] - [{include file="widget/product/boxproducts.tpl" _boxId="topBox" _oBoxProducts=$oView->getTop5ArticleList() _sHeaderIdent="BOX_TOPOFTHESHOP_HEADER"}] - [{/if}] - [{/block}] - - [{block name="sidebar_recommendation"}] - [{if $oViewConf->getShowListmania() }] - [{include file="widget/sidebar/recommendation.tpl"}] - [{/if}] - [{/block}] - - [{block name="sidebar_tags"}] - [{if $oView->showTags() && $oView->getClassName() ne "details" && $oView->getClassName() ne "alist" && $oView->getClassName() ne "tags"}] - [{if $oView->getTagCloudManager() }] - [{include file="widget/sidebar/tags.tpl" oTagsManager=$oView->getTagCloudManager()}] - [{/if}] - [{/if}] - [{/block}] - - [{block name="sidebar_news"}] - [{if $oxcmp_news|count }] - [{include file="widget/sidebar/news.tpl" oNews=$oxcmp_news}] - [{/if}] - [{/block}] - - [{block name="sidebar_facebookfacepile"}] - [{if $oView->isActive('FbFacepile') && $oView->isConnectedWithFb()}] - [{include file="widget/facebook/facepile.tpl"}] - [{/if}] - [{/block}] - - [{block name="sidebar_shopluperatings"}] - [{if $oView->getClassName() eq "start"}] - [{include file="widget/shoplupe/ratings.tpl" }] - [{/if}] - [{/block}] -[{/block}] - diff --git a/changed_full/451-453/out/basic/de/d3_usersonline_lang.php b/changed_full/451-453/out/basic/de/d3_usersonline_lang.php deleted file mode 100644 index 34d61c2..0000000 --- a/changed_full/451-453/out/basic/de/d3_usersonline_lang.php +++ /dev/null @@ -1,34 +0,0 @@ - 'ISO-8859-15', -'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', -'D3_USERSONLINE_USER' => 'Benutzer', -'D3_USERSONLINE_USERS' => 'Benutzer', -'D3_USERSONLINE_ALL' => 'gesamt', - -); - -/* -[{ oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE' }] -*/ \ No newline at end of file diff --git a/changed_full/451-453/out/basic/tpl/_left.tpl b/changed_full/451-453/out/basic/tpl/_left.tpl deleted file mode 100644 index 9b17045..0000000 --- a/changed_full/451-453/out/basic/tpl/_left.tpl +++ /dev/null @@ -1,79 +0,0 @@ -[{if $oView->showSearch() }] - [{ oxmultilang ident="INC_LEFTITEM_PRODUCTSEARCH" }] - -[{/if}] -[{if $oxcmp_categories }] - [{if $oView->showTopCatNavigation()}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() class="tree"}] - [{else}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories act=$oxcmp_categories->getClickCat() class="tree"}] - [{/if}] -[{/if}] - -[{if $oView->loadVendorTree() && $oView->getVendorlist()}] - [{include file="inc/vendor_tree.tpl" tree=$oView->getVendorlist() class="tree"}] -[{/if}] - -[{if $oView->loadManufacturerTree() && $oView->getManufacturerlist()}] - [{include file="inc/manufacturer_tree.tpl" tree=$oView->getManufacturerlist() class="tree"}] -[{/if}] - -[{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] -[{*** D3 Modul "UsersOnline" END ***}] - -[{if $oView->showLeftBasket()}] - [{oxid_include_dynamic file="dyn/mini_basket.tpl" type="basket" testid="LeftBasket"}] -[{/if}] - -[{include file="inc/infobox.tpl"}] - -[{if $oxcmp_news && count($oxcmp_news) > 0}] - [{include file="inc/cmp_news.tpl"}] -[{/if}] - -[{ oxmultilang ident="INC_LEFTITEM_PARTNERANDSEAL" }] -
- - -
- - diff --git a/changed_full/451-453/out/basic/tpl/inc/d3usersonline.tpl b/changed_full/451-453/out/basic/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 58b70df..0000000 --- a/changed_full/451-453/out/basic/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,43 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] - [{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}] -
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/461/out/admin/de/d3_usersonline_lang.php b/changed_full/461/out/admin/de/d3_usersonline_lang.php deleted file mode 100644 index 38e1ddb..0000000 --- a/changed_full/461/out/admin/de/d3_usersonline_lang.php +++ /dev/null @@ -1,31 +0,0 @@ - 'ISO-8859-15', - 'D3_USERONLINE_METADATA_TITLE' => 'D³ User Online', - 'D3_USERONLINE_METADATA_DESC' => 'Lassen Sie sich anonym im Shop anzeigen, wie viele Benutzer zur Zeit Ihren Shop besuchen und welche Seiten angezeigt werden. Das Modul speichert nicht die IP-Adresse oder sonstige Daten des Nutzers. Damit genügen Sie auch dem deutschen Recht.', - -); - -/* -[{ oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE' }] -*/ \ No newline at end of file diff --git a/changed_full/461/out/azure/tpl/inc/d3usersonline.tpl b/changed_full/461/out/azure/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 215e0b8..0000000 --- a/changed_full/461/out/azure/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,45 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] -
-

[{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}]

-
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/461/out/azure/tpl/layout/sidebar.tpl b/changed_full/461/out/azure/tpl/layout/sidebar.tpl deleted file mode 100644 index d0e2df3..0000000 --- a/changed_full/461/out/azure/tpl/layout/sidebar.tpl +++ /dev/null @@ -1,74 +0,0 @@ -[{foreach from=$oxidBlock_sidebar item="_block"}] - [{$_block}] -[{/foreach}] - -[{block name="sidebar"}] - [{block name="sidebar_adminbanner"}] - [{if $oView->isDemoShop()}] - [{ include file="widget/sidebar/adminbanner.tpl" }] - [{/if}] - [{/block}] - - [{block name="sidebar_categoriestree"}] - [{if $oxcmp_categories }] - [{include file="widget/sidebar/categoriestree.tpl" categories=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() deepLevel=0}] - [{/if}] - [{/block}] - - [{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] - [{*** D3 Modul "UsersOnline" END ***}] - - [{block name="sidebar_trustedshopsratings"}] - [{if $oView->getClassName() eq "start"}] - [{if $oViewConf->showTs("WIDGET")}] - [{include file="widget/trustedshops/ratings.tpl" }] - [{/if}] - [{/if}] - [{/block}] - - [{block name="sidebar_partners"}] - [{if $oView->getClassName() eq "start"}] - [{include file="widget/sidebar/partners.tpl" }] - [{/if}] - [{/block}] - - [{block name="sidebar_boxproducts"}] - [{if $oView->getClassName() eq "start" && $oView->getTop5ArticleList()}] - [{include file="widget/product/boxproducts.tpl" _boxId="topBox" _oBoxProducts=$oView->getTop5ArticleList() _sHeaderIdent="BOX_TOPOFTHESHOP_HEADER"}] - [{/if}] - [{/block}] - - [{block name="sidebar_recommendation"}] - [{if $oViewConf->getShowListmania() }] - [{include file="widget/sidebar/recommendation.tpl"}] - [{/if}] - [{/block}] - - [{block name="sidebar_tags"}] - [{if $oView->showTags() && $oView->getClassName() ne "details" && $oView->getClassName() ne "alist" && $oView->getClassName() ne "tags"}] - [{if $oView->getTagCloudManager() }] - [{include file="widget/sidebar/tags.tpl" oTagsManager=$oView->getTagCloudManager()}] - [{/if}] - [{/if}] - [{/block}] - - [{block name="sidebar_news"}] - [{if $oxcmp_news|count }] - [{include file="widget/sidebar/news.tpl" oNews=$oxcmp_news}] - [{/if}] - [{/block}] - - [{block name="sidebar_facebookfacepile"}] - [{if $oView->isActive('FbFacepile') && $oView->isConnectedWithFb()}] - [{include file="widget/facebook/facepile.tpl"}] - [{/if}] - [{/block}] - - [{block name="sidebar_shopluperatings"}] - [{if $oView->getClassName() eq "start"}] - [{include file="widget/shoplupe/ratings.tpl" }] - [{/if}] - [{/block}] -[{/block}] - diff --git a/changed_full/461/out/basic/tpl/_left.tpl b/changed_full/461/out/basic/tpl/_left.tpl deleted file mode 100644 index 9b17045..0000000 --- a/changed_full/461/out/basic/tpl/_left.tpl +++ /dev/null @@ -1,79 +0,0 @@ -[{if $oView->showSearch() }] - [{ oxmultilang ident="INC_LEFTITEM_PRODUCTSEARCH" }] - -[{/if}] -[{if $oxcmp_categories }] - [{if $oView->showTopCatNavigation()}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories->getClickRoot() act=$oxcmp_categories->getClickCat() class="tree"}] - [{else}] - [{include file="inc/category_tree.tpl" tree=$oxcmp_categories act=$oxcmp_categories->getClickCat() class="tree"}] - [{/if}] -[{/if}] - -[{if $oView->loadVendorTree() && $oView->getVendorlist()}] - [{include file="inc/vendor_tree.tpl" tree=$oView->getVendorlist() class="tree"}] -[{/if}] - -[{if $oView->loadManufacturerTree() && $oView->getManufacturerlist()}] - [{include file="inc/manufacturer_tree.tpl" tree=$oView->getManufacturerlist() class="tree"}] -[{/if}] - -[{*** D3 Modul "UsersOnline" START ***}] - [{include file="inc/d3usersonline.tpl"}] -[{*** D3 Modul "UsersOnline" END ***}] - -[{if $oView->showLeftBasket()}] - [{oxid_include_dynamic file="dyn/mini_basket.tpl" type="basket" testid="LeftBasket"}] -[{/if}] - -[{include file="inc/infobox.tpl"}] - -[{if $oxcmp_news && count($oxcmp_news) > 0}] - [{include file="inc/cmp_news.tpl"}] -[{/if}] - -[{ oxmultilang ident="INC_LEFTITEM_PARTNERANDSEAL" }] -
- - -
- - diff --git a/changed_full/461/out/basic/tpl/inc/d3usersonline.tpl b/changed_full/461/out/basic/tpl/inc/d3usersonline.tpl deleted file mode 100644 index 58b70df..0000000 --- a/changed_full/461/out/basic/tpl/inc/d3usersonline.tpl +++ /dev/null @@ -1,43 +0,0 @@ -[{if $oxcmp_user && $oxcmp_user->oxuser__oxrights->value == 'malladmin'}] - [{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}] -
- - - - - - - [{foreach from=$aUsersOnline.classes item="aClassUser"}] - - - - - - [{/foreach}] -
- [{oxmultilang ident="D3_USERSONLINE_ALL"}] - - [{$aUsersOnline.all }] - - [{if $aUsersOnline.all == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
- [{if $aClassUser->classname}] - [{$aClassUser->classname|ucfirst}]: - [{else}] - undefined: - [{/if}] - - [{$aClassUser->counter}] - - [{if $aClassUser->counter == 1}] - [{oxmultilang ident="D3_USERSONLINE_USER"}] - [{else}] - [{oxmultilang ident="D3_USERSONLINE_USERS"}] - [{/if}] -
-
-[{/if}] \ No newline at end of file diff --git a/changed_full/EE500-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl b/changed_full/EE500-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl new file mode 100644 index 0000000..8717382 --- /dev/null +++ b/changed_full/EE500-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl @@ -0,0 +1,49 @@ +[{d3modcfgcheck modid="d3usersonline"}] + [{if $oxcmp_user && $oxcmp_user->getFieldData('oxrights') == 'malladmin'}] +
+

[{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}]

+
+ + + + + + + [{foreach from=$aUsersOnline.classes item="aClassUser"}] + + + + + + [{/foreach}] +
+ [{oxmultilang ident="D3_USERSONLINE_ALL"}] + + [{$aUsersOnline.all}]  + + [{if $aUsersOnline.all == 1}] + [{oxmultilang ident="D3_USERSONLINE_USER"}] + [{else}] + [{oxmultilang ident="D3_USERSONLINE_USERS"}] + [{/if}] +
+ [{if $aClassUser->classname}] + [{$aClassUser->classname|ucfirst}]: + [{else}] + undefined: + [{/if}] + + [{$aClassUser->counter}]  + + [{if $aClassUser->counter == 1}] + [{oxmultilang ident="D3_USERSONLINE_USER"}] + [{else}] + [{oxmultilang ident="D3_USERSONLINE_USERS"}] + [{/if}] +
+
+
+ [{/if}] +[{/d3modcfgcheck}] + +[{$smarty.block.parent}] \ No newline at end of file diff --git a/changed_full/PE470-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl b/changed_full/PE470-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl new file mode 100644 index 0000000..8717382 --- /dev/null +++ b/changed_full/PE470-/modules/d3/d3usersonline/views/blocks/layout/d3usersonline_sidebar.tpl @@ -0,0 +1,49 @@ +[{d3modcfgcheck modid="d3usersonline"}] + [{if $oxcmp_user && $oxcmp_user->getFieldData('oxrights') == 'malladmin'}] +
+

[{oxmultilang ident="D3_USERSONLINE_USERSONLINE"}]

+
+ + + + + + + [{foreach from=$aUsersOnline.classes item="aClassUser"}] + + + + + + [{/foreach}] +
+ [{oxmultilang ident="D3_USERSONLINE_ALL"}] + + [{$aUsersOnline.all}]  + + [{if $aUsersOnline.all == 1}] + [{oxmultilang ident="D3_USERSONLINE_USER"}] + [{else}] + [{oxmultilang ident="D3_USERSONLINE_USERS"}] + [{/if}] +
+ [{if $aClassUser->classname}] + [{$aClassUser->classname|ucfirst}]: + [{else}] + undefined: + [{/if}] + + [{$aClassUser->counter}]  + + [{if $aClassUser->counter == 1}] + [{oxmultilang ident="D3_USERSONLINE_USER"}] + [{else}] + [{oxmultilang ident="D3_USERSONLINE_USERS"}] + [{/if}] +
+
+
+ [{/if}] +[{/d3modcfgcheck}] + +[{$smarty.block.parent}] \ No newline at end of file diff --git a/copy_this/modules/d3/d3usersonline/metadata.php b/copy_this/modules/d3/d3usersonline/metadata.php index 14d4ee0..4139db5 100644 --- a/copy_this/modules/d3/d3usersonline/metadata.php +++ b/copy_this/modules/d3/d3usersonline/metadata.php @@ -1,18 +1,58 @@ . + * + * @author D3 Data Development - Daniel Seifert + * @link http://www.oxidmodule.com + */ + +/** + * Metadata version + */ +$sMetadataVersion = '1.1'; + /** * Module information */ -$sMetadataVersion = '1.0'; $aModule = array( - 'id' => 'd3useronline', - 'title' => oxLang::getInstance()->translateString('D3_USERONLINE_METADATA_TITLE'), - 'description' => oxLang::getInstance()->translateString('D3_USERONLINE_METADATA_DESC'), - 'thumbnail' => 'picture.png', - 'version' => '1.2.1', - 'author' => oxLang::getInstance()->translateString('D3_MOD_LIB_METADATA_AUTHOR'), - 'email' => 'support@shopmodule.com', - 'url' => 'http://www.oxidmodule.com/', + 'id' => 'd3usersonline', + 'title' => + (class_exists('d3utils') ? d3utils::getInstance()->getD3Logo() : 'D³') . ' Users Online', + 'description' => array( + 'de' => 'Lassen Sie sich anonym im Shop anzeigen, wie viele Benutzer zur Zeit Ihren Shop besuchen und welche Seiten angezeigt werden. Das Modul speichert nicht die IP-Adresse oder sonstige Daten des Nutzers. Damit genügen Sie auch dem deutschen Recht.', + 'en' => '', + ), + 'thumbnail' => 'picture.png', + 'version' => '2.0.0.0', + 'author' => 'D³ Data Development (Inh.: Thomas Dartsch)', + 'email' => 'support@shopmodule.com', + 'url' => 'http://www.oxidmodule.com/', 'extend' => array( - 'oxcmp_utils' => 'd3usersonline/views/d3_oxcmp_utils_usersonline' + 'oxcmp_utils' => 'd3/d3usersonline/modules/components/d3_oxcmp_utils_usersonline', + ), + 'files' => array( + 'd3usersonline' => 'd3/d3usersonline/models/d3usersonline.php', + 'd3usersonline_update' => 'd3/d3usersonline/models/d3usersonline_update.php', + ), + 'templates' => array( + //'d3_cfg_extsearch_main.tpl' => 'd3/d3_extsearch/views/admin/tpl/d3_cfg_extsearch_main.tpl', + ), + 'events' => array( + 'onActivate' => 'd3install::checkUpdateStart', + ), + 'blocks' => array( + array('template' => 'layout/sidebar.tpl', 'block' => 'sidebar_categoriestree', + 'file' => 'views/blocks/layout/d3usersonline_sidebar.tpl'), ) ); \ No newline at end of file diff --git a/copy_this/modules/d3/d3usersonline/models/d3usersonline.php b/copy_this/modules/d3/d3usersonline/models/d3usersonline.php index a6f9365..1ff2838 100644 --- a/copy_this/modules/d3/d3usersonline/models/d3usersonline.php +++ b/copy_this/modules/d3/d3usersonline/models/d3usersonline.php @@ -13,77 +13,188 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * @author Aggrosoft, D³ Data Development + * @author D3 Data Development - Daniel Seifert + * @link http://www.oxidmodule.com */ -class d3usersonline extends oxI18n +class d3usersonline extends oxbase { - /** - * Object core table name - * - * @var string - */ protected $_sCoreTbl = 'd3usersonline'; - - /** - * Current class name - * - * @var string - */ protected $_sClassName = 'd3usersonline'; - public function __construct($aParams = null) + protected $_remoteAddr = null; + protected $_httpClientIp = null; + protected $_httpXForwardedFor = null; + protected $_httpXForwarded = null; + protected $_httpForwardedFor = null; + protected $_httpForwarded = null; + protected $_httpVia = null; + protected $_httpXComingFrom = null; + protected $_httpComingFrom = null; + + /** + * constructor + */ + public function __construct() { parent::__construct(); $this->init( 'd3usersonline' ); } + /** + * @param $iExpTime + */ public function clearOldItems($iExpTime) { + startProfile(__METHOD__); + $exptime = time() - $iExpTime; oxDb::getDb()->Execute("delete from ".$this->getViewName()." where timevisit < $exptime"); + + stopProfile(__METHOD__); } - public function getActUserItem($sUserIPHash) - { - $sSelect = "select count(*) from ".$this->getViewName()." where visitor= ".oxDb::getDb()->quote($sUserIPHash); - return oxDb::getDb()->getOne( $sSelect ); - } - + /** + * @return array + */ public function getUserCount() { - $sSelect = "select count(*) counter, oxclass from ".$this->getViewName()." GROUP BY oxclass ORDER BY counter desc"; + startProfile(__METHOD__); - $rs = oxDb::getDb(2)->Execute($sSelect); + $sSelect = "select count(oxid) AS counter, oxclass from ".$this->getViewName()." GROUP BY oxclass ORDER BY counter desc"; + $aRecords = oxDb::getDb(oxDb::FETCH_MODE_ASSOC)->getArray($sSelect); $iAllCounter = 0; $aUserClasses = array(); - if ($rs != false && $rs->RecordCount() > 0) + if ($aRecords && is_array($aRecords) && count($aRecords)) { - while (!$rs->EOF) + foreach ($aRecords as $aRecord) { + $aRecord = array_change_key_case($aRecord, CASE_UPPER); + $oTmp = new stdClass; - $oTmp->classname = $rs->fields['oxclass']; - $oTmp->counter = $rs->fields['counter']; - $iAllCounter += $rs->fields['counter']; + $oTmp->classname = $aRecord['OXCLASS']; + $oTmp->counter = $aRecord['COUNTER']; + $iAllCounter += $aRecord['COUNTER']; $aUserClasses['classes'][] = $oTmp; - $rs->moveNext(); } } $aUserClasses['all'] = $iAllCounter; + stopProfile(__METHOD__); + return $aUserClasses; } - public function setActTimeVisit($sUserIpHash) + public function setActTimeVisit() { - oxDb::getDb()->Execute("update ".$this->getViewName()." set timevisit= ".oxDb::getDb()->quote(time()).", oxclass = ".oxDb::getDb()->quote($this->getConfig()->getActiveView()->getClassName())." where visitor= ".oxDb::getDb()->quote($sUserIpHash)); + startProfile(__METHOD__); + + $this->setId($this->_getIPHash()); + + $aValues = array( + 'timevisit' => time(), + 'oxclass' => oxRegistry::getConfig()->getActiveView()->getClassName() + ); + + $this->assign($aValues); + $this->save(); + + stopProfile(__METHOD__); } - public function insertActUser($sUserIpHash) + /** + * @return string + */ + protected function _getIPHash() { - oxDb::getDb()->Execute("insert into ".$this->getViewName()." (visitor,timevisit,oxclass) values (".oxDb::getDb()->quote($sUserIpHash).", ".oxDb::getDb()->quote(time()).", ".oxDb::getDb()->quote($this->getConfig()->getActiveView()->getClassName()).")"); + return md5($this->_getTrueIP()); } + /** + * @return null|string + */ + protected function _getTrueIP() + { + $sDirectIp = ''; + + $this->_getIpData('_remoteAddr', 'REMOTE_ADDR'); + $this->_getIpData('_httpClientIp', 'HTTP_CLIENT_IP'); + $this->_getIpData('_httpXForwardedFor', 'HTTP_X_FORWARDED_FOR'); + $this->_getIpData('_httpXForwarded', 'HTTP_X_FORWARDED'); + $this->_getIpData('_httpForwardedFor', 'HTTP_FORWARDED_FOR'); + $this->_getIpData('_httpForwarded', 'HTTP_FORWARDED'); + $this->_getIpData('_httpVia', 'HTTP_VIA'); + $this->_getIpData('_httpXComingFrom', 'HTTP_X_COMING_FROM'); + $this->_getIpData('_httpComingFrom', 'HTTP_COMING_FROM'); + + // Gets the default ip sent by the user + if (!empty($this->_remoteAddr)) + $sDirectIp = $this->_remoteAddr; + + // Gets the proxy ip sent by the user + if (!empty($this->_httpXForwardedFor)) + $sProxyIp = $this->_httpXForwardedFor; + else if (!empty($this->_httpXForwarded)) + $sProxyIp = $this->_httpXForwarded; + else if (!empty($this->_httpForwardedFor)) + $sProxyIp = $this->_httpForwardedFor; + else if (!empty($this->_httpForwarded)) + $sProxyIp = $this->_httpForwarded; + else if (!empty($this->_httpVia)) + $sProxyIp = $this->_httpVia; + else if (!empty($this->_httpXComingFrom)) + $sProxyIp = $this->_httpXComingFrom; + else if (!empty($this->_httpComingFrom)) + $sProxyIp = $this->_httpComingFrom; + + // Returns the true IP if it has been found, else ... + if (empty($sProxyIp)) + { + // True IP without proxy + return $sDirectIp; + } + else + { + $blIsIp = preg_match('@^([0-9]{1,3}.){3,3}[0-9]{1,3}@', $sProxyIp, $aMatches); + + if ($blIsIp && (count($aMatches) > 0)) + { + // True IP behind a proxy + return $aMatches[0]; + } + else + { + if (empty($this->_httpClientIp)) + { + // Can't define IP: there is a proxy but we don't have + // information about the true IP + return "(unbekannt) " . $sProxyIp; + } + else + { + // better than nothing + return $this->_httpClientIp; + } + } + } + } + + /** + * @param $sTargetVarName + * @param $sDataName + */ + protected function _getIpData($sTargetVarName, $sDataName) + { + if (empty($this->{$sTargetVarName})) + { + if (!empty($_SERVER) && isset($_SERVER[$sDataName])) + $this->{$sTargetVarName} = $_SERVER[$sDataName]; + else if (!empty($_ENV) && isset($_ENV[$sDataName])) + $this->{$sTargetVarName} = $_ENV[$sDataName]; + else if (@getenv($sDataName)) + $this->{$sTargetVarName} = getenv($sDataName); + } + } } diff --git a/copy_this/modules/d3/d3usersonline/models/d3usersonline_update.php b/copy_this/modules/d3/d3usersonline/models/d3usersonline_update.php new file mode 100644 index 0000000..d029cd8 --- /dev/null +++ b/copy_this/modules/d3/d3usersonline/models/d3usersonline_update.php @@ -0,0 +1,253 @@ +. + * + * @author D3 Data Development - Daniel Seifert + * @link http://www.oxidmodule.com + */ + +class d3usersonline_update extends d3install_updatebase +{ + public $sModKey = 'd3usersonline'; + public $sModName = 'Users Online'; + public $sModVersion = '2.0.0.0'; + public $sModRevision = '24'; + public $sBaseConf = 'qnqSkx5WGk0V0xyY0wwVWNKTE5qSy9oY3RZeXdOSHhtd1c5aW9PWEltei9aWXg2RTBoOUErUi9UcVZFb +W1RVUpWM1ZwTTBLU2plR3RxNzVXSVREQUFqd0V4cTQ5ZHVYQTYvVEFYKzdXMkE3aTM0SFgvbEZsZzlwU +VJKeTltWmVISFQ5YmY1Y0Q5aDRFRGZ4b2FoenlOb1p5Y0c2aFdnRXVmQVdTK2VubzBhc2hvUkVQbVBhV +jFJeWdqRUZOSEFnekZVZmF2eCtIcThzeDBqNU1JdWkrZG9MQlhFdUNyd3NhUzlkL05YVDAvaEhjS04vZ +2xRL0w2U2ZlOEFjTXB3aGp1UmRFS2dmVGNocXhCT2dQY0MzZkVvckVOU1BoMG5Ma053UTNhYlNtMklQZ +DQ9'; + public $sRequirements = ''; + public $sBaseValue = ''; + + protected $_aUpdateMethods = array( + array('check' => 'checkUsersOnlineTableExist', + 'do' => 'updateUsersOnlineTableExist'), + array('check' => 'checkModCfgItemExist', + 'do' => 'updateModCfgItemExist'), + array('check' => 'checkFields', + 'do' => 'fixFields'), + array('check' => 'checkIndizes', + 'do' => 'fixIndizes'), + array('check' => 'checkModCfgSameRevision', + 'do' => 'updateModCfgSameRevision'), + ); + + public $aFields = array( + 'OXID' => array( + 'sTableName' => 'd3usersonline', + 'sFieldName' => 'OXID', + 'sType' => 'char(32)', + 'blNull' => FALSE, + 'sDefault' => FALSE, + 'sComment' => '', + 'sExtra' => '', + 'blMultilang' => FALSE, + ), + 'TIMEVISIT' => array( + 'sTableName' => 'd3usersonline', + 'sFieldName' => 'TIMEVISIT', + 'sType' => 'INT(11)', + 'blNull' => FALSE, + 'sDefault' => '0', + 'sComment' => '', + 'sExtra' => '', + 'blMultilang' => FALSE, + ), + 'OXCLASS' => array( + 'sTableName' => 'd3usersonline', + 'sFieldName' => 'OXCLASS', + 'sType' => 'VARCHAR(32)', + 'blNull' => FALSE, + 'sDefault' => FALSE, + 'sComment' => '', + 'sExtra' => '', + 'blMultilang' => FALSE, + ), + ); + + public $aIndizes = array( + 'OXID' => array( + 'sTableName' => 'd3usersonline', + 'sType' => 'PRIMARY', + 'aFields' => array( + 'OXID' => 'OXID', + ), + ), + 'OXCLASS' => array( + 'sTableName' => 'd3usersonline', + 'sType' => 'PRIMARY', + 'sName' => 'OXCLASS', + 'aFields' => array( + 'OXCLASS' => 'OXCLASS', + ), + ), + ); + + protected $_aRefreshMetaModuleIds = array('d3usersonline'); + + /** + * @return bool TRUE, if table is missing + */ + public function checkUsersOnlineTableExist() + { + return $this->_checkTableNotExist('d3usersonline'); + } + + /** + * @return bool + */ + public function updateUsersOnlineTableExist() + { + $blRet = TRUE; + + if ($this->checkUsersOnlineTableExist()) + { + $aRet = $this->_addTable('d3usersonline', $this->aFields, $this->aIndizes, 'users online', 'MyISAM'); + $blRet = $aRet['blRet']; + $this->_setActionLog('SQL', $aRet['sql'], __METHOD__); + } + + return $blRet; + } + + /** + * @return bool + */ + public function checkModCfgItemExist() + { + $blRet = FALSE; + foreach ($this->_getShopList() as $oShop) + { + /** @var $oShop oxshop */ + $aWhere = array( + 'oxmodid' => $this->sModKey, + 'oxnewrevision' => $this->sModRevision, + 'oxshopid' => $oShop->getId(), + ); + + $blRet = $this->_checkTableItemNotExist('d3_cfg_mod', $aWhere); + + if ($blRet) + { + return $blRet; + } + } + + return $blRet; + } + + /** + * @return bool + */ + public function updateModCfgItemExist() + { + $blRet = FALSE; + + if ($this->checkModCfgItemExist()) + { + foreach ($this->_getShopList() as $oShop) + { + /** @var $oShop oxshop */ + $aWhere = array( + 'oxmodid' => $this->sModKey, + 'oxshopid' => $oShop->getId(), + 'oxnewrevision' => $this->sModRevision, + ); + + if ($this->_checkTableItemNotExist('d3_cfg_mod', $aWhere)) + { + // update don't use this property + unset($aWhere['oxnewrevision']); + + $aInsertFields = array( + 'OXID' => array ( + 'content' => "md5('" . $this->sModKey . " " . $oShop->getId() . " de')", + 'force_update' => TRUE, + 'use_quote' => FALSE, + ), + 'OXSHOPID' => array ( + 'content' => $oShop->getId(), + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXMODID' => array ( + 'content' => $this->sModKey, + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXNAME' => array ( + 'content' => $this->sModName, + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXACTIVE' => array ( + 'content' => "0", + 'force_update' => FALSE, + 'use_quote' => FALSE, + ), + 'OXBASECONFIG' => array ( + 'content' => $this->sBaseConf, + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXSERIAL' => array ( + 'content' => "", + 'force_update' => FALSE, + 'use_quote' => TRUE, + ), + 'OXINSTALLDATE' => array ( + 'content' => "NOW()", + 'force_update' => TRUE, + 'use_quote' => FALSE, + ), + 'OXVERSION' => array ( + 'content' => $this->sModVersion, + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXSHOPVERSION' => array ( + 'content' => oxRegistry::getConfig()->getEdition(), + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXREQUIREMENTS' => array ( + 'content' => $this->sRequirements, + 'force_update' => TRUE, + 'use_quote' => TRUE, + ), + 'OXVALUE' => array( + 'content' => $this->sBaseValue, + 'force_update' => FALSE, + 'use_quote' => TRUE, + ), + 'OXNEWREVISION' => array( + 'content' => $this->sModRevision, + 'force_update' => TRUE, + 'use_quote' => TRUE, + ) + ); + $aRet = $this->_updateTableItem('d3_cfg_mod', $aInsertFields, $aWhere); + $blRet = $aRet['blRet']; + + $this->_setActionLog('SQL', $aRet['sql'], __METHOD__); + $this->_setUpdateBreak(FALSE); + } + } + } + return $blRet; + } +} \ No newline at end of file diff --git a/copy_this/modules/d3/d3usersonline/modules/components/d3_oxcmp_utils_usersonline.php b/copy_this/modules/d3/d3usersonline/modules/components/d3_oxcmp_utils_usersonline.php index ae7e8f3..fed4ad1 100644 --- a/copy_this/modules/d3/d3usersonline/modules/components/d3_oxcmp_utils_usersonline.php +++ b/copy_this/modules/d3/d3usersonline/modules/components/d3_oxcmp_utils_usersonline.php @@ -13,128 +13,39 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . * - * @author Aggrosoft, D³ Data Development + * @author D3 Data Development - Daniel Seifert + * @link http://www.oxidmodule.com */ class d3_oxcmp_utils_usersonline extends d3_oxcmp_utils_usersonline_parent { + protected $_blIsComponent = true; protected $_iExpTime = 600; // (in seconds) - protected $_sUserIpHash = null; - protected $_remoteAddr = null; - protected $_httpClientIp = null; - protected $_httpXForwardedFor = null; - protected $_httpXForwarded = null; - protected $_httpForwardedFor = null; - protected $_httpForwarded = null; - protected $_httpVia = null; - protected $_httpXComingFrom = null; - protected $_httpComingFrom = null; - protected $_proxyIp = null; - protected $_directIp = null; - - public function init() - { - $this->blIsComponent = true; - parent::init(); - } + protected $_sD3UsersOnlineModId = 'd3usersonline'; + /** + * @return string + */ public function render() { - $ret = parent::render(); + $sRet = parent::render(); - //WE ARE NOT ALLOWED TO STORE THE REAL IP - $this->_sUserIpHash = md5($this->_getTrueIP()); - $this->utime = time(); - - $oUserOnline = oxNew('d3usersonline'); - $oUserOnline->clearOldItems($this->_iExpTime); - $iUserExist = $oUserOnline->getActUserItem($this->_sUserIpHash); - - if ($iUserExist > 0) { - $oUserOnline->setActTimeVisit($this->_sUserIpHash); - } else { - $oUserOnline->insertActUser($this->_sUserIpHash); - } - - $this->getParent()->addTplParam('aUsersOnline', $oUserOnline->getUserCount()); - - return $ret; - } - - private function _getIpData($sTargetVarName, $sDataName) - { - if (empty($this->{$sTargetVarName})) + if (d3_cfg_mod::get($this->_sD3UsersOnlineModId)->isActive()) { - if (!empty($_SERVER) && isset($_SERVER[$sDataName])) - $this->{$sTargetVarName} = $_SERVER[$sDataName]; - else if (!empty($_ENV) && isset($_ENV[$sDataName])) - $this->{$sTargetVarName} = $_ENV[$sDataName]; - else if (@getenv($sDataName)) - $this->{$sTargetVarName} = getenv($sDataName); - } - } + /** @var d3usersonline $oUserOnline */ + $oUserOnline = oxNew('d3usersonline'); + $oUserOnline->clearOldItems($this->_iExpTime); + $oUserOnline->setActTimeVisit(); - private function _getTrueIP() - { - $this->_getIpData('_remoteAddr', 'REMOTE_ADDR'); - $this->_getIpData('_httpClientIp', 'HTTP_CLIENT_IP'); - $this->_getIpData('_httpXForwardedFor', 'HTTP_X_FORWARDED_FOR'); - $this->_getIpData('_httpXForwarded', 'HTTP_X_FORWARDED'); - $this->_getIpData('_httpForwardedFor', 'HTTP_FORWARDED_FOR'); - $this->_getIpData('_httpForwarded', 'HTTP_FORWARDED'); - $this->_getIpData('_httpVia', 'HTTP_VIA'); - $this->_getIpData('_httpXComingFrom', 'HTTP_X_COMING_FROM'); - $this->_getIpData('_httpComingFrom', 'HTTP_COMING_FROM'); - - // Gets the default ip sent by the user - if (!empty($this->_remoteAddr)) - $this->_directIp = $this->_remoteAddr; - - // Gets the proxy ip sent by the user - if (!empty($this->_httpXForwardedFor)) - $this->_proxyIp = $this->_httpXForwardedFor; - else if (!empty($this->_httpXForwarded)) - $this->_proxyIp = $this->_httpXForwarded; - else if (!empty($this->_httpForwardedFor)) - $this->_proxyIp = $this->_httpForwardedFor; - else if (!empty($this->_httpForwarded)) - $this->_proxyIp = $this->_httpForwarded; - else if (!empty($this->_httpVia)) - $this->_proxyIp = $this->_httpVia; - else if (!empty($this->_httpXComingFrom)) - $this->_proxyIp = $this->_httpXComingFrom; - else if (!empty($this->_httpComingFrom)) - $this->_proxyIp = $this->_httpComingFrom; - - // Returns the true IP if it has been found, else ... - if (empty($this->_proxyIp)) - { - // True IP without proxy - return $this->_directIp; - } - else - { - $isIp = ereg('^([0-9]{1,3}.){3,3}[0-9]{1,3}', $this->_proxyIp, $regs); - - if ($isIp && (count($regs) > 0)) + $oUser = $this->getUser(); + if ($oUser && strtolower($oUser->getFieldData('oxrights')) == 'malladmin') { - // True IP behind a proxy - return $regs[0]; - } - else - { - if (empty($this->_httpClientIp)) - { - // Can't define IP: there is a proxy but we don't have - // information about the true IP - return "(unbekannt) " . $this->_proxyIp; - } - else - { - // better than nothing - return $this->_httpClientIp; - } + /** @var oxview $oActView */ + $oActView = $this->getParent(); + $oActView->addTplParam('aUsersOnline', $oUserOnline->getUserCount()); } } + + return $sRet; } } \ No newline at end of file diff --git a/copy_this/modules/d3/d3usersonline/translations/de/d3usersonline_lang.php b/copy_this/modules/d3/d3usersonline/translations/de/d3usersonline_lang.php new file mode 100644 index 0000000..9ff3fa3 --- /dev/null +++ b/copy_this/modules/d3/d3usersonline/translations/de/d3usersonline_lang.php @@ -0,0 +1,36 @@ +. + * + * @author D3 Data Development - Daniel Seifert + * @link http://www.oxidmodule.com + */ + +$sLangName = 'Deutsch'; +$iLangNr = 0; +// ------------------------------- +// RESOURCE IDENTITFIER = STRING +// ------------------------------- +$aLang = array( + 'charset' => 'ISO-8859-15', + + 'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', + 'D3_USERSONLINE_USER' => 'Benutzer', + 'D3_USERSONLINE_USERS' => 'Benutzer', + 'D3_USERSONLINE_ALL' => 'gesamt', +); + +/* +[{oxmultilang ident='ACTIONS_MAIN_YOUWANTTODELETE'}] +*/ \ No newline at end of file diff --git a/changed_full/461/out/de/d3_usersonline_lang.php b/copy_this/modules/d3/d3usersonline/translations/en/d3usersonline_lang.php similarity index 75% rename from changed_full/461/out/de/d3_usersonline_lang.php rename to copy_this/modules/d3/d3usersonline/translations/en/d3usersonline_lang.php index 74c4592..df1848d 100644 --- a/changed_full/461/out/de/d3_usersonline_lang.php +++ b/copy_this/modules/d3/d3usersonline/translations/en/d3usersonline_lang.php @@ -21,10 +21,10 @@ $iLangNr = 0; // ------------------------------- $aLang = array( 'charset' => 'ISO-8859-15', - 'D3_USERSONLINE_USERSONLINE' => 'Benutzer online', - 'D3_USERSONLINE_USER' => 'Benutzer', - 'D3_USERSONLINE_USERS' => 'Benutzer', - 'D3_USERSONLINE_ALL' => 'gesamt', + 'D3_USERSONLINE_USERSONLINE' => 'Users online', + 'D3_USERSONLINE_USER' => 'user', + 'D3_USERSONLINE_USERS' => 'users', + 'D3_USERSONLINE_ALL' => 'all', ); diff --git a/setup+doku/Installation.pdf b/setup+doku/Installation.pdf index dd17df2..331bff1 100644 Binary files a/setup+doku/Installation.pdf and b/setup+doku/Installation.pdf differ diff --git a/setup+doku/d3precheck.php b/setup+doku/d3precheck.php new file mode 100644 index 0000000..a86252d --- /dev/null +++ b/setup+doku/d3precheck.php @@ -0,0 +1,804 @@ + + * @link http://www.oxidmodule.com + * @version 2.0 + */ + +/** + * Alle Anforderungen sind über $this->_aCheck konfigurierbar. Manche Anforderungen haben dazu noch weitergehende + * Informationen. Die Struktur dieser Requirementbeschreibungen: + * + * array( + * 'blExec' => 1, // obligatorisch: 0 = keine Prüfung, 1 = Püfung wird ausgeführt + * 'aParams' => array(...), // optional, Inhalt ist von jeweiliger Prüfung abhängig + * ) + * + * "Desc1": Diese Struktur kann allein eine Bedingung beschreiben. Wenn mehrere dieser Bedingungen + * nötig sind (z.B. bei unterschiedlichen Bibliotheksanforderungen), kann diese Struktur als + * Arrayelemente auch mehrfach genannt werden (kaskadierbar). Grundsätzlich sind alle Requirements + * kaskadierbar, jedoch ergibt dies nicht bei allen Sinn. :) Eine Kaskadierung sieht so aus: + * + * array( + * array( + * 'blExec' => 1, + * ... + * ), + * array( + * 'blExec' => 1, + * ... + * ) + * ) + * + * Unbedingt zu vermeiden sind Änderungen in der Scriptlogik, da diese bei Updates nur schwer zu übernehmen sind. + */ + +class requcheck +{ + protected $_db = false; + + public $dbHost; + + public $dbUser; + + public $dbPwd; + + public $dbName; + + protected $_sModName = 'D³ Users Online'; + + protected $_sModVersion = '2.0.0.X'; + + protected $_aCheck = array( + // kleinste erlaubte PHP-Version + 'hasMinPhpVersion' => array( + 'blExec' => 0, + 'aParams' => array( + '5.2.0' + ) + ), + // größte erlaubte PHP-Version + 'hasMaxPhpVersion' => array( + 'blExec' => 1, + 'aParams' => array( + '5.4.99' + ) + ), + // PHP-Version zwischen 5.2 und 5.4 + 'hasPhp52to54' => array('blExec' => 1), + // PHP-Version ist 5.2 + 'hasPhp52' => array('blExec' => 0), + // PHP-Version ist 5.3 + 'hasPhp53' => array('blExec' => 0), + // PHP-Version ist 5.4 + 'hasPhp54' => array('blExec' => 0), + // benötigt Zend Optimizer (PHP 5.2) bzw. Zend Guard Loader (> PHP 5.2) + 'hasZendLoaderOptimizer' => array('blExec' => 0), + // benötigt IonCubeLoader + 'hasIonCubeLoader' => array('blExec' => 0), + // benötigt PHP-Extension (kaskadierbar (siehe "Desc1")) + 'hasExtension' => array( + array( + 'blExec' => 0, + 'aParams' => array( + 'curl' + ), + ), + array( + 'blExec' => 0, + 'aParams' => array( + 'soap' + ), + ), + ), + // minimal benötigte Shopversion (editionsgetrennt) + 'hasMinShopVersion' => array( + 'blExec' => 1, + 'aParams' => array( + 'PE' => '4.7.0', + 'CE' => '4.7.0', + 'EE' => '5.0.0' + ), + ), + // maximal verwendbare Shopversion (editionsgetrennt) + 'hasMaxShopVersion' => array( + 'blExec' => 0, + 'aParams' => array( + 'PE' => '4.7.0', + 'CE' => '4.7.0', + 'EE' => '5.0.0' + ), + ), + // verfügbar für diese Shopeditionen + 'isShopEdition' => array( + 'blExec' => 1, + 'aParams' => array( + array( + 'PE', + 'EE', + 'CE', + ), + ), + ), + // benötigt mindestens diese Erweiterungen / Version lt. d3_cfg_mod (kaskadierbar (siehe "Desc1")) + 'hasMinModCfgVersion' => array( + array( + 'blExec' => 1, + 'aParams' => array( + 'd3modcfg_lib', + 'Modul-Connector', + '3.9.0.0', + ), + ), + array( + 'blExec' => 0, + 'aParams' => array( + 'd3log_lib', + 'Logging', + '1.2.1.3', + ), + ), + ), + // verwendbar bis zu diesen Erweiterungen / Version lt. d3_cfg_mod (kaskadierbar (siehe "Desc1")) + 'hasMaxModCfgVersion' => array( + array( + 'blExec' => 0, + 'aParams' => array( + 'd3modcfg_lib', + 'Modul-Connector', + '3.9.0.5' + ), + ), + ), + // benötigt Modul-Connector + 'hasModCfg' => array('blExec' => 1), + ); + + protected $_blGlobalResult = true; + + public function startCheck() + { + $this->getHTMLHeader(); + + $this->_runThroughChecks($this->_aCheck); + + $this->getHTMLFooter(); + } + + /** + * traversable requirement check + * + * @param $aCheckList + * @param string $sForceCheckType + */ + protected function _runThroughChecks($aCheckList, $sForceCheckType = '') + { + foreach ($aCheckList as $sCheckType => $aConf) { + if (array_key_exists('blExec', $aConf)) { + if ($aConf['blExec']) { + if (strlen($sForceCheckType)) { + $sCheckType = $sForceCheckType; + } + $this->displayCheck($sCheckType, $aConf); + } + } else { + $this->_runThroughChecks($aConf, $sCheckType); + } + } + } + + /** + * @param $sCheckType + * @param $aConfiguration + */ + public function displayCheck($sCheckType, $aConfiguration) + { + $sGenCheckType = preg_replace("@(\_[0-9]$)@", "", $sCheckType); + + if (method_exists($this, $sGenCheckType) && call_user_func(array($this, $sGenCheckType), $aConfiguration)) { + echo "
" . $this->translate($sCheckType, $aConfiguration) . "
"; + } elseif (method_exists($this, $sGenCheckType)) { + echo "
" . $this->translate($sCheckType, $aConfiguration) . "
"; + } else { + echo "
" . $this->translate($sCheckType, $aConfiguration) . " (" . $this->translate( + 'RequNotCheckable' + ) . ")
"; + } + } + + /** + * @return bool + */ + public function hasMinPhpVersion() + { + $aArgs = func_get_args(); + + if (version_compare(phpversion(), $aArgs[0]['aParams'][0], '>=')) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasPhp52to54() + { + if ((version_compare(phpversion(), '5.2.0', '>=')) && (version_compare(phpversion(), '5.4.900', '<'))) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasPhp52() + { + if ((version_compare(phpversion(), '5.2.0', '>=')) && (version_compare(phpversion(), '5.2.900', '<'))) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasPhp53() + { + if ((version_compare(phpversion(), '5.3.0', '>=')) && (version_compare(phpversion(), '5.3.999', '<'))) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasPhp54() + { + if ((version_compare(phpversion(), '5.4.0', '>=')) && (version_compare(phpversion(), '5.4.999', '<'))) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasMaxPhpVersion() + { + $aArgs = func_get_args(); + + if (version_compare(phpversion(), $aArgs[0]['aParams'][0], '<=')) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasExtension() + { + $aArgs = func_get_args(); + + if (extension_loaded($aArgs[0]['aParams'][0])) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasMinShopVersion() + { + if ($this->_getDb()) { + $aArgs = func_get_args(); + $sField = 'oxversion'; + $sSelect = "SELECT " . $sField . " FROM oxshops WHERE 1 ORDER BY oxversion ASC LIMIT 1"; + $rResult = mysql_query($sSelect, $this->_getDb()); + $oResult = mysql_fetch_object($rResult); + + $oEditionResult = $this->_getShopEdition(); + $sEdition = strtoupper($oEditionResult->oxedition); + + $aArgs[0]['aParams'] = $aArgs[0]['aParams'][$sEdition]; + + if (version_compare($oResult->oxversion, $aArgs[0]['aParams'], '>=')) { + return true; + } + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function isShopEdition() + { + if ($this->_getDb()) { + $aArgs = func_get_args(); + $oResult = $this->_getShopEdition(); + + if (in_array(strtoupper($oResult->oxedition), $aArgs[0]['aParams'][0])) { + $aArgs[0]['aParams'][0] = strtoupper($oResult->oxedition); + + return true; + } + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool|object|stdClass + */ + protected function _getShopEdition() + { + if ($this->_getDb()) { + $sField = 'oxedition'; + $sSelect = "SELECT " . $sField . " FROM oxshops WHERE 1 LIMIT 1"; + $rResult = mysql_query($sSelect, $this->_getDb()); + $oResult = mysql_fetch_object($rResult); + + return $oResult; + } + + return false; + } + + /** + * @return bool + */ + public function hasMaxShopVersion() + { + if ($this->_getDb()) { + $aArgs = func_get_args(); + $sField = 'oxversion'; + $sSelect = "SELECT " . $sField . " FROM oxshops WHERE 1 ORDER BY oxversion DESC LIMIT 1"; + $rResult = mysql_query($sSelect, $this->_getDb()); + $oResult = mysql_fetch_object($rResult); + + $oEditionResult = $this->_getShopEdition(); + $sEdition = strtoupper($oEditionResult->oxedition); + + $aArgs[0]['aParams'] = $aArgs[0]['aParams'][$sEdition]; + + if (version_compare($oResult->oxversion, $aArgs[0]['aParams'], '<=')) { + return true; + } + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasModCfg() + { + if ($this->_getDb()) { + $oResult = new stdClass(); + $sModId = 'd3modcfg_lib'; + $sSelect = "SELECT 1 as result FROM d3_cfg_mod WHERE oxmodid = '" . $sModId . "' LIMIT 1"; + $rResult = mysql_query($sSelect, $this->_getDb()); + if (is_resource($rResult)) { + $oResult = mysql_fetch_object($rResult); + } + + if ($oResult->result) { + return true; + } + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasMinModCfgVersion() + { + if ($this->_getDb()) { + $aArgs = func_get_args(); + $sSelect = "SELECT oxversion FROM d3_cfg_mod WHERE oxmodid = '" . $aArgs[0]['aParams'][0] . "' ORDER BY oxversion ASC LIMIT 1"; + + $rResult = mysql_query($sSelect, $this->_getDb()); + $oResult = mysql_fetch_object($rResult); + + if (is_object($oResult) && version_compare($oResult->oxversion, $aArgs[0]['aParams'][1], '>=')) { + return true; + } + } + + return false; + } + + /** + * @return bool + */ + public function hasMaxModCfgVersion() + { + if ($this->_getDb()) { + $aArgs = func_get_args(); + $sSelect = "SELECT oxversion FROM d3_cfg_mod WHERE oxmodid = '" . $aArgs[0]['aParams'][0] . "' ORDER BY oxversion ASC LIMIT 1"; + $rResult = mysql_query($sSelect, $this->_getDb()); + $oResult = mysql_fetch_object($rResult); + + if (is_object($oResult) && version_compare($oResult->oxversion, $aArgs[0]['aParams'][1], '<=')) { + return true; + } + } + + return false; + } + + /** + * @return bool + */ + public function hasZendLoaderOptimizer() + { + if (version_compare(phpversion(), '5.2.0', '>=') && version_compare( + phpversion(), + '5.2.900', + '<' + ) && function_exists('zend_optimizer_version') + ) { + return true; + } elseif (version_compare(phpversion(), '5.3.0', '>=') && version_compare( + phpversion(), + '5.4.900', + '<' + ) && function_exists('zend_loader_version') + ) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @return bool + */ + public function hasIonCubeLoader() + { + if (function_exists('ioncube_loader_version')) { + return true; + } + + $this->_blGlobalResult = false; + + return false; + } + + /** + * @param $sIdent + * @param array $aConfiguration + * + * @return mixed|string + */ + public function translate($sIdent, $aConfiguration = array()) + { + $sGenIdent = preg_replace("@(\_[0-9]$)@", "", $sIdent); + $aTransl = array( + 'de' => array( + 'RequCheck' => 'Mindestanforderungsprüfung', + 'ExecNotice' => 'Führen Sie diese Prüfung immer aus dem Stammverzeichnis Ihres Shops aus. Nur dann können die Prüfungen erfolgreich durchgeführt werden.', + 'RequSucc' => 'Bedingung erfüllt', + 'RequNotSucc' => 'Bedingung nicht erfüllt', + 'RequNotCheckable' => 'Bedingung nicht prüfbar', + 'hasMinPhpVersion' => 'mindestens PHP Version %s', + 'hasMaxPhpVersion' => 'maximal PHP Version %s', + 'hasPhp52to54' => 'Server verwendet PHP 5.2, 5.3 oder 5.4', + 'hasPhp52' => 'Server verwendet PHP 5.2', + 'hasPhp53' => 'Server verwendet PHP 5.3', + 'hasPhp54' => 'Server verwendet PHP 5.4', + 'hasSoap' => 'SOAP-Erweiterung verfügbar', + 'hasCurl' => 'Curl-Erweiterung verfügbar', + 'hasExtension' => '%s-Erweiterung verfügbar', + 'hasMinShopVersion' => 'mindestens Shop Version %s', + 'hasMaxShopVersion' => 'maximal Shop Version %s', + 'hasMinModCfgVersion' => 'ModCfg-Eintrag "%s" (%s) mit mindestens Version %s', + 'hasMaxModCfgVersion' => 'ModCfg-Eintrag "%s" (%s) mit maximal Version %s', + 'hasModCfg' => 'Modul-Connector installiert', + 'isShopEdition' => 'ist Shopedition %s', + 'hasZendLoaderOptimizer' => 'Zend Optimizer (PHP 5.2) oder Zend Guard Loader (PHP 5.3, 5.4) installiert **', + 'hasIonCubeLoader' => 'ionCube loader installiert', + 'globalSuccess' => 'Die Prüfung war erfolgreich. Sie können das Modul installieren.*

', + 'globalNotSuccess' => 'Die Prüfung war nicht erfolgreich. Bitte kontrollieren Sie die rot markierten Bedingungen.

', + 'deleteFile1' => 'Löschen Sie diese Datei nach der Verwendung bitte unbedingt wieder von Ihrem Server! Klicken Sie hier, um diese Datei zu löschen.', + 'showPhpInfo' => 'PHPinfo anzeigen', + 'dependentoffurther' => '* abhängig von ungeprüften Voraussetzungen', + 'oneandonedescription' => '** geprüft wurde das Ausführungsverzeichnis, providerabhängig müssen Unterverzeichnisse separat geprüft werden (z.B. bei 1&1)', + 'or' => ' oder ', + ), + 'en' => array( + 'RequCheck' => 'Requirement check', + 'ExecNotice' => 'Execute this check script in the root directory of your shop. In this case only checks can executed succesfully.', + 'RequSucc' => 'condition is fulfilled', + 'RequNotSucc' => 'condition isn\'t fulfilled', + 'RequNotCheckable' => 'condition isn\'t checkable', + 'hasMinPhpVersion' => 'at least PHP version %s', + 'hasMaxPhpVersion' => 'not more than PHP version %s', + 'hasPhp52to54' => 'server use PHP 5.2, 5.3 or 5.4', + 'hasPhp52' => 'server use PHP 5.2', + 'hasPhp53' => 'server use PHP 5.3', + 'hasPhp54' => 'server use PHP 5.4', + 'hasSoap' => 'SOAP extension available', + 'hasCurl' => 'curl extension available', + 'hasExtension' => '%s extension is available', + 'hasMinShopVersion' => 'at least shop version %s', + 'hasMaxShopVersion' => 'not more than shop version %s', + 'hasMinModCfgVersion' => 'ModCfg item "%s" (%s) has at least version %s', + 'hasMaxModCfgVersion' => 'ModCfg item "%s" (%s) has not more than version %s', + 'hasModCfg' => 'Module Connector installed', + 'isShopEdition' => 'shop edition is %s', + 'hasZendLoaderOptimizer' => 'Zend Optimizer (PHP 5.2) or Zend Guard Loader (PHP 5.3, 5.4) installed **', + 'hasIonCubeLoader' => 'ionCube loader installed', + 'globalSuccess' => 'The test was successful. Your server is ready for installing the module.*

', + 'globalNotSuccess' => 'The test wasn\'t successfull. Please check the red marked conditions.

', + 'deleteFile1' => 'Please delete this file after use on your server! Click here, to delete this file.', + 'showPhpInfo' => 'show PHPinfo', + 'dependentoffurther' => '* dependent of further unchecked conditions', + 'oneandonedescription' => '** this check use execution directory only, provider dependend subdirectories have to check separately (e.g. at 1&1)', + 'or' => ' or ', + ), + ); + + if (isset($aConfiguration['aParams']) && is_array($aConfiguration['aParams'])) { + array_walk($aConfiguration['aParams'], array($this, 'aTos'), $sIdent); + } + + if (($sTranslation = $aTransl[$this->_getLang()][$sGenIdent])) { + if (isset($aConfiguration['aParams'])) { + return vsprintf($sTranslation, $aConfiguration['aParams']); + } else { + return $sTranslation; + } + } else { + return $sGenIdent; + } + } + + /** + * @param $mParam + */ + protected function aTos(&$mParam) + { + if (is_array($mParam)) { + $mParam = implode($this->translate('or'), $mParam); + } + } + + /** + * @return string + */ + protected function _getLang() + { + if (isset($_REQUEST['lang'])) { + return strtolower($_REQUEST['lang']); + } + + return 'de'; + } + + /** + * @return bool|resource + */ + protected function _getDb() + { + if (!$this->_db) { + if (file_exists('config.inc.php')) { + require_once('config.inc.php'); + $this->_db = mysql_connect($this->dbHost, $this->dbUser, $this->dbPwd); + mysql_select_db($this->dbName, $this->_db); + } + } + + return $this->_db; + } + + /** + * @param $version + * @param int $iUnsetPart + * + * @return string + */ + public function versionToInt($version, $iUnsetPart = 0) + { + $match = explode('.', $version); + + return sprintf( + '%d%03d%03d%03d', + intval($match[0] !== null ? $match[0] : $iUnsetPart), + intval( + $match[1] !== null ? $match[1] : $iUnsetPart + ), + intval($match[2] !== null ? $match[2] : $iUnsetPart), + intval( + $match[3] !== null ? $match[3] : $iUnsetPart + ) + ); + } + + public function getHTMLHeader() + { + $sScriptName = $_SERVER['SCRIPT_NAME']; + $sTranslRequCheck = $this->translate('RequCheck'); + $sModName = $this->_sModName; + $sModVersion = $this->_sModVersion; + + echo <<< EOT + + + + + $sTranslRequCheck "$sModName" $sModVersion + + + + + + +EOT; + echo "

" . $this->translate('RequCheck') . ' "' . $this->_sModName . ' ' . $sModVersion . '"

'; + echo '

' . $this->translate('ExecNotice') . '

'; + + return; + } + + public function getHTMLFooter() + { + $sScriptName = $_SERVER['SCRIPT_NAME']; + $sTranslShopPhpInfo = $this->translate('showPhpInfo'); + $sTranslDependent = $this->translate('dependentoffurther'); + $sOneAndOneNote = $this->translate('oneandonedescription'); + + if ($this->_blGlobalResult) { + echo '

' . $this->translate('globalSuccess') . '' . $this->translate( + 'deleteFile1' + ) . $sScriptName . $this->translate('deleteFile2') . '

'; + } else { + echo '

' . $this->translate('globalNotSuccess') . '' . $this->translate( + 'deleteFile1' + ) . $sScriptName . $this->translate('deleteFile2') . '

'; + } + + echo <<< EOT + $sTranslDependent
+ $sOneAndOneNote

+

+ + $sTranslShopPhpInfo + +

+ + + +EOT; + + return; + } + + public function deleteme() + { + unlink($_SERVER['SCRIPT_FILENAME']); + + if (is_file($_SERVER['SCRIPT_FILENAME'])) { + exit('Datei konnte nicht gelöscht werden. Bitte löschen Sie diese manuell.'); + } else { + exit('Auf Wiedersehen.'); + } + } + + public function showinfo() + { + phpinfo(); + } + + public function getPngButton() + { + $sImg = "iVBORw0KGgoAAAANSUhEUgAABDgAAAAWCAYAAAAl+SzaAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAABMpJREFUeNrs3Y1O4zgUhuFY4hbb2ZthRjtczOz0Ght7cZwfQ5u2E4K0a55XiNDUXyWcT+ZwfGyHw+HQvZI6AACAT+J0OgW9AAAAtnA8Hh/JWYSnbkxuvAYeeg0AAAAAAPynuJevOB6P+ZKe6sYvLy96DgAA7M7z87NOAAAAm7iVq8gxRs5p5CTH03Tz758/uzAUc7x+Hy4pf71ex9fDj2leyxLG1vnNELpmdJPqo21a7afy+/MIj/AIj7zVhS/seWPD4zoAAIAtxJhW44+cy/jx/ftw/2kRxDEQSd0Uraah/RKVlLfK+/kDS0T7eieGZnTdA33QfeF+CpFHeIRHeORSF1Lw3I0Nd3UAAACbEhwprscfadnma05wpL7v8v0Sh4QiLimREqWEt7mSmK9xnLlrSBe6fdq02k9D1oxHeIRHeORCFz13Y8NtHQAAwNYER+zX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//P7n9/J/yOFwGO6fTie9BgAAPgvrVAAAwFZuzpgcj8fh+jQGHGm6AQAAsDcmUgAAwFYezFeEfwUYAAoCUXB0RZrTAAAAAElFTkSuQmCC"; + header("Content-type: image/png"); + echo base64_decode($sImg); + exit; + } + + public function getPngLogo() + { + $sImg = "iVBORw0KGgoAAAANSUhEUgAAADMAAAA0CAYAAAAnpACSAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAEIxJREFUeNq8Wgl4VNXZfu+dLZkkk5BA9kACYQlB2aIga6myuIEtFX+kLW1BJVT/akVrRds+rVqRX2lLRSsal5/nUaCgtmhi8BeaUhAl7EYTIWyGQPZlMsnM3Lnn/865dzJ3biaLVnsfDpk59yzf++3fOSMxxvANPlZqUdQs1FRqXmq+Ac7NpbaI2jxqQ6nZqDVR+z9qr1H71DxB+nfBPHYYSHUCK8fATl+HUZtK7Wpqo1SGeZ0BQCEYFolQETSrhDJ6d4rax9Q+pFa18SQ8HX6aHAcszUUS9T3U0IU1710ASqiddwNuBciMARbSDjcQtDQnnnj7HNYuGvY1gqHnW9RWBBi+f7kT+LwVKG8AjlDj38+0AR1EiJ1kk0XEZFAbO4gQJwOj44F0+m6TsYvWKKKWQOQUvVwFPHCAxNBlZDs1psk30wXsv4XWi8VvqefXXwcYWg6FRPy8racBzsXjjQxtXim4sra5bKCG6X3QCLOR4lxBwGakS1g+ChhORN5FcttWpSumpCunZADEH5L2iATa71bAaUUW9XzxVcEs4yCq2zD9qaMML1QQXQGdaMmwYW8PM41RQxwvmgu0+yU8Qap7uUMbN59UykUKXF4P0J5hgD4gi5qTjuW6DQkDHehDfMNvLnbgvp/vV7GdpKEGdA5aTMRiAIAQDj6HJHR7rgyHBc+T/a16jaQzNFbYB0FDXa0HC0a+QSrrD82J1qj3G73NQJ6buTT+eppdf+cehuauCCCCLDeDkcwAWM8xjA+T8JcKxp3FKu4oFGLUOZJEpyJNIqKfpP4F/kBI9bLIWUxIErPLvozN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GorvN2loNPbdNxx5KY4n/3nac3dfxA7kxugZCoJLX1qWgUdvTtESTkWNcIJi0vkw2zGU0oz19GbmrEXRwPxgWiL23puDnCT7w6WfuX/Z7y3Ql/i5Cc+vCmta/Mt+vOUCdp9s1wKaBaHAJvXyK4w+k0jDxIBWoU7KceLF72diYmb0Xu61XtjftC070U6GLyMlzhqGe3Sy/d/6VdMqX4A9V/xJO/60pwF7PneD+fXfYMkSvvTDdBA0dSKp1E9IGsunJCIuSv7liwean+QXWLQfvikw4oiZ2l2kCetP13vx+qEWvHygUTvQ0AnrBiYhdDFrVCk9/0uItWJpQYIAcUV6NI/qfxTS+FdTJT+rs1m+eTDBx6ar353tXnXpR2c94O3QeQ9qWv3ooBjVTIkmJ8ZG4FxUzbqiLUgmABMyojBleAymZDsxJNZayu9wqO3+bfHl1iQq5PgtwX8ajPFJ039IN4faWP36Llb/WaOs5yc+PcNt1a/6+I94PuBnCF8HAf8vwADS7GaT0D4fMwAAAABJRU5ErkJggg=="; + header("Content-type: image/png"); + echo base64_decode($sImg); + exit; + } + + public function getGifBg() + { + $sImg = "R0lGODlhCgAyANUAANHo+pfK85rM8/X6/vb6/v///5jL85bJ8+Hv/KbS9dzt+87m+qTR9fH4/er1/b7e+MTh+P3+/63V9u/3/dfq+rnc97fa96DP9Nns+53N9LLY9tTp+sHg+Mzl+cfi+OPx/Pv9/7DX9p/O9Oz2/bTZ9uXy/KLQ9Pj7/ujz/bzd9/7+//r8//P5/snj+ZvM897u+6nT9avU9qvU9QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAAAAAAALAAAAAAKADIAAAbFwINwSAwYj0iDcskUOJ9Ql3RKzVivWJF2y714v2CTeExmmM/ohHrNhrnf8Jh8PpdJ7vh8aM/va/6AgSSDhIUWh4iJFYuMjSmPkJEPk5SVHJeYmRCbnJ0en6ChLaOkpR2nqKkLq6ytAK+wsRuztLUUt7i5GLu8vQq/wMEvw8TFCMfIyR/LzM0lz9DRKNPU1Q7X2Nkj29zdE9/g4Q3j5OUs5+jpA+vs7QTv8PEn8/T1K/f4+SD7/P0R/wADqhhIsGCBgwgTBgEAOw=="; + header("Content-type: image/Gif"); + echo base64_decode($sImg); + exit; + } + + public function getGifDe() + { + $sImg = "R0lGODlhEgANAIQZAAAAABAFBhEGBhIGBhQHBxUHCCYNDZQqH5QrI9c4M+M4M9w9M+g/MuNDM/BFM99tI+t3H+CyDerIB+zIBuzKBurLCPfcAPfgAPjlAP///////////////////////////ywAAAAAEgANAAAFVaARCGRpmoExAGzrvsBAwHRLFHVdIEfv/8ADouEoGo9IR2PBaDqfUMYioahar1hF4gHper9gyKOCKZvPaExFcmm73/CLZGKp2+94yyRCmfj/gIAUESEAOw=="; + header("Content-type: image/Gif"); + echo base64_decode($sImg); + exit; + } + + public function getGifEn() + { + $sImg = "R0lGODlhEgANAOfRANzd6P9LQP7//93e6ba32v8HB/J4ef//+/85Of8fFVddwP8aFq+13P8aFPr////f3f8XE/n//62s3fQuLAIDj6ys3uHZ5P8uLOjp793f6dbX6uvBxsyasurCx/9fXcadtS88r+Da5EZHr+Hi7A0NlUVGqcjR9MKaunh5x/8REQAAkv9IP/9BPnh6wi4/td3c5uLl7P8PD7vO9aGSw7bM9uDh6UpLsf8hFv/f3PPx9/Dx9DFCuMDE4cHF4/sAANPU3ufp8JSDvuVocf8ODvz8+/xRTPQgG+PM0ZSWzs/R476+4ujp8v8/PurO0uPZ3//u5fQCAOPj6nFxxf8UE8rM4P/w5YGM18PH4/79/ExUuP3//4CAxqmo3KaZxv7+/RcstO3v89XW6fS8waOj2snM7Nra7Ccon+no9v03OFJZvuK2xBEipP89Ov8dE+be4u3u8/w3OOVocv8sKv8EBOjo9+/u+Kap15SFvgwRlba327uXteHh7tvc5yo3q9XX5SQ4uU5MrtjW5qaVxvDS2f8DA+Tj6vr6/j1FtVlgvL+euvHw9v+rqe7u+XKJ1ebn7p2x7CUmnvb2+dPW8P8cEc/P4efn8/38/5Ws66mYx/ccGNfY5vh0d927zSUlov96ev88OgAAjmmA09rb5v+xsPF5eMnR8i0upuuAgvEyLx0rq97f6cunwEBIuO/Aw/9/fuTm6vn5+vTEyM7P5rq63BESlf+Fgv8fF8SWsOfp7+2rrvX1+La23RgmqLe43PPV2vdydhcnqIWQ2BEgoube4wASn82atOHj6uTT2f97etKjuf9dWsSduZyb08fJ4fn5+/z8/f+ZAP///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////ywAAAAAEgANAAAI/gB/YHCkig+AAVGGuSmUAYCoEbpgGXsFY8kWM7T6JEI14QMIEpBaVNIBRBOSOtEqmAK27EabYqk6jYl2hpksKnjSmIgmqdEqWw2ShSITrZQCFXb8IDpkRdGBCLGmpBDj4ECOYKyyXHFyyoCQX8hceShQQFktT5viGCDV5AgUaHDjypXrI9exIgHYwEHA5MIcQnJYIEDzKcCKVi+63BE0CMeTUTGGLKrywBemIDMCJVnz5ZIWATI4LYCghoaAaI/+EGNAqQQXQ4xQuDiRYBKHHVLoWJIAaFaNZkSU2KAgTI+RTLd4gRKxC0uZPQPAvAnTiwCPEB02WOiRh4CGZ15wAgUEADs="; + header("Content-type: image/Gif"); + echo base64_decode($sImg); + exit; + } +} + +$oRequCheck = new requcheck; +if (isset($_REQUEST['fnc']) && $_REQUEST['fnc']) { + $oRequCheck->{$_REQUEST['fnc']}(); +} else { + $oRequCheck->startCheck(); +} \ No newline at end of file diff --git a/setup+doku/install.sql b/setup+doku/install.sql deleted file mode 100644 index be89199..0000000 --- a/setup+doku/install.sql +++ /dev/null @@ -1,7 +0,0 @@ -CREATE TABLE d3usersonline ( - `id` int(11) NOT NULL auto_increment, - `visitor` varchar(100) default NULL, - `timevisit` int(11) NOT NULL default '0', - `oxclass` varchar(32) collate latin1_general_ci NOT NULL, - PRIMARY KEY (id) -) ENGINE=MyISAM; \ No newline at end of file diff --git a/source/UsersOnline-Installation.docx b/source/UsersOnline-Installation.docx index 1c2101c..ce12fc8 100644 Binary files a/source/UsersOnline-Installation.docx and b/source/UsersOnline-Installation.docx differ