DJ-Fix for K2
Introduction
K2 modules may conflict with 3rd party components (some of ours as well) which contain item.php file in models folder.
This is related with function addIncludePath of JModel and that K2 system plugin doesn't use prefix as a second parameter of this function.
In result the path to K2 models is added only to global prefix where all other paths are also added usually after K2 path.
Consequently getting the instance of the model include the item.php only from last added path which is not K2 and generates the warning message that K2ModelItem class was not found in file.
Eventually ver. 2.7 of K2 fixed the issue, so it's useful ONLY for versions BELOW 2.7
Our K2 fix plugin adds the models path with K2Model prefix what fix major problems with proper working of K2 modules with other extensions. It fixes following problems in certain modules:
-K2 Content - module doesn't show up and warning message is displayed: Model class K2ModelItem not found in file
-K2 Users - nothing except php error message: Fatal error: Call to a member function getUserProfile() on a non-object in componentscom_k2helpersutilities.php on line 65
-K2 User - white page after log in
-K2 Comments - it seems to work, but warning message is displayed: Model class K2ModelItem not found in file
Moduły K2 mogą powodować konflikt z komponentami które zawierają plik item.php w folderze modeli.
Jest to związane z funkcją addIncludePath z JModel i wtyczki systemu K2 która nie używa prefiksu jako drugiego parametru tej funkcji.
W rezultacie scieżka do modeli K2 dodaje się tylko do globalnego prefiksu, gdzie wszystkie inne ścieżki są również dodawane zwykle po ścieżce K2.
Nasza wtyczka K2 dodaje scieżkę modeli z prefixem K2Model co naprawia poważne problemy z prawidłowym działaniem modułów z innymi dodatkami.
K2 fix
Unser K2 fix Plugin fügt einen Pfad mit dem K2Model Präfix , das den ordnungsgemäßen Betrieb der K2 -Module mit anderen Erweiterungen herstellt und Probleme behebt.
Es behebt folgende Probleme in bestimmten Modulen :
-K2 Inhalt - Modul wird nicht angezeigt und folgende Warnmeldung ist zu sehen: Modellklasse K2ModelItem nicht in der Datei gefunden
-K2 Benutzer - nichts außer der PHP- Fehlermeldung : Fatal error: Call to a member function getUserProfile() on a non-object in componentscom_k2helpersutilities.php on line 65
-K2 Benutzer - weiße Seite nach der Anmeldung
-K2 Kommentare - scheint zu funktionieren , aber eine Warnmeldung wird angezeigt: Klasse K2ModelItem nicht in der Datei gefunden
DJ-Fix for K2
- Version:
- 1.4
- Developer:
- DJ-Extensions
- Last updated:
-
Jun 29 2020
2 years ago - Date added:
- Nov 19 2014
- License:
- GPLv2 or later
- Type:
- Free download
- Includes:
- p
- Compatibility:
- J3
Share