Thứ Hai, 29 tháng 7, 2024

J5 menu item login the first page You don't have permission to access - SOLVED

Detail:
danger
You don't have permission to access this. Please contact a website administrator if this is incorrect.

Menu item > login. The first page warning
Module login not warning
-
Solution:
Administrator>menu login > tab options > login redirect : specify exactly value example 'index.php?Itemid=101'

 


Chủ Nhật, 28 tháng 7, 2024

joomla 5 Class "JResponse" not found - SOLVED

Change
JResponse::getHeaders();
JResponse::getBody()
to
JFactory::getApplication()->getHeaders();
JFactory::getApplication()->getBody();

 



 

Manual mysql import Categories,Artiles, Menu joomla 3.10.12 to joomla 5.1.2 - SOLVED

PHPMyAdmin, manual mysql import Categories,Artiles, Menu joomla 3.10.12 to joomla 5.1.2

Backup each before do anything
1. J3 export table _categories, _content, _menu:

_categories export type extension = 'com_content' only
_content export all data
_menu export menutype='mainmenu' or require menu only, not export all
2. J5 Import _categories, _content, _menu : 

 _categories remove all extension = 'com_content', then import from j3
_content add column 'xreference' varchar 50 null, import all. Then remove column 'xreference'
_menu remove menutype='mainmenu', import from j3


ISSUES MUST COUNTER: #_ is prefix table


1. J5 BACK END + FRONT END article not view, not access: reason j5 require table __workflow_associations
Run this query:
INSERT INTO #_workflow_associations (item_id, stage_id, extension)
SELECT c.id as item_id, '1', 'com_content.article' FROM #_content AS c
WHERE NOT EXISTS (SELECT wa.item_id FROM #_workflow_associations AS wa WHERE wa.item_id = c.id);


2. J5 FRONT END article not view: reason j5 _content have `publish_down`. set null is allow view
UPDATE `#_content` SET `publish_down`=null;
-

3. J5 FRONT END 'Category not found':  this relate table _assests, but we use administrator>Articles>Categoryies -> Rebuild
This will update _asset, -> category blog view



4. J5 Front End main menu links wrong article,category blog link: reason J5 table _menu require 'component_id', must set component_id to article component
UPDATE `#_menu` SET `component_id`=MUST_GET_COMPONENT_ID WHERE menutype = 'mainmenu'

 





Thứ Hai, 22 tháng 7, 2024

Joomla5 JString not found


Detail: upgrade j3 to j5 JString not found
Solution: Change to
use Joomla\String\StringHelper;
JString->StringHelper




Joomla5 JArrayHelper not found


Detail: upgrade j3 to j5, error view JArrayHelper not found
Solution: add user ArrayHelper and replace
Replace
JArrayHelper
To
/*at top file PHP*/
use Joomla\Utilities\ArrayHelper;
ArrayHelper

 



Upgrade to joomla5 JRequest not found


Detail: upgrade j3 to joomla 5 error JRequest not found
Solution:
Replace
JRequest::getVar('item');
To
Joomla\CMS\Factory::getApplication()->getInput()->get('item');



 

Thứ Bảy, 13 tháng 7, 2024

JQuery 1.9 and above .size() is not function

Detail: jquery 1.9 above not allow element.size() funtion, instead use .length
Solution: replace .size() to .length
or : this is will return length not change code
$.fn.size = function() {
    return this.length;
}

 



 

Thứ Năm, 11 tháng 7, 2024

xampp - MySQL: Error Code: 1118 Row size too large - SOVLED


Detail: Local host Xampp 3.3.0, phpmyadmin import .sql file -> error
Error Code: 1118 Row size too large (> 8126). Changing some columns to TEXT or BLOB
Solution: goto https://localhost/phpmyadmin runt sql: SET GLOBAL innodb_strict_mode = 0;
Status: SOLVED