Manually creating jos_assets records Print

  • 3

jimport('joomla.database.table');
$asset = JTable::getInstance('Asset');
$asset->name      = 'com_wbuserstores';
$asset->title     = 'com_wbuserstores';
$asset->parent_id = 1;
$asset->level     = 1;
$asset->rules     = '{"core.admin":{"7":1},"core.manage":{"6":1},"core.create":[],"core.delete":[],"core.edit":[],"core.edit.state":[]}';
$asset->setLocation(1, 'last-child');
$asset->store();


Was this answer helpful?

« Back