Jump to content

Have moved host and cannot access site / login


Recommended Posts

Hi there

 

I have (also) moved host of my second shop (running on PS v. 1.5.4.1) and changed settings.inc.php to access the new datebase name, user and pw.

 

However now I cannot access the site and not the admin login.

 

I get:

 

quote

 

[PrestaShopException]

No access reference in table module_access for id_module 91.
at line 1743 in file classes/module/Module.php

1737.                 self::$cache_permissions[$employee->id_profile][$row['id_module']]['configure'] = $row['configure'];
1738.             }
1739.         }
1740.
1741.         if (!isset(self::$cache_permissions[$employee->id_profile][$id_module]))
1742.             throw new PrestaShopException('No access reference in table module_access for id_module '.$id_module.'.');
1743.
1744.         return (bool)self::$cache_permissions[$employee->id_profile][$id_module][$variable];
1745.     }
1746.
1747.     /**


ModuleCore::getPermissionStatic - [line 2220 - classes/controller/AdminController.php] - [2 Arguments]

Argument [0]
91
Argument [1]
configure

AdminControllerCore->getModulesList - [line 1518 - classes/controller/AdminController.php] - [1 Arguments]
AdminControllerCore->renderModulesList - [line 1441 - classes/controller/AdminController.php] - [0 Argument]
AdminControllerCore->initContent - [line 111 - controllers/admin/AdminLoginController.php] - [0 Argument]
AdminLoginControllerCore->initContent - [line 167 - classes/controller/Controller.php] - [0 Argument]
ControllerCore->run - [line 349 - classes/Dispatcher.php] - [0 Argument]
DispatcherCore->dispatch - [line 50 - adminfreek/index.php] - [0 Argument]

 

unquote

 

What went wrong?

 

With my old host all files were in public_html/shop

now they are in public_html/domainname/shop

 

Should this be amended somewhere in settings.inc.php as well (ie in '__PS_BASE_URI__') ?

 

Link to comment
Share on other sites

Dear Vekia

 

Sorry had to continue due to host deadline as my contract with old host end July30 and want to have it working befor then to avoid downtime.

Deleted my folder and installed PS 1.5.4.1. clean. Login was ok.

Deleted tables from database and imported all tables from backup, login did not work "unknow user/pw" to get new pw send and login worked but got red banner saying no permission. Could still enter my settings but when I logged out get error. When I try to login again the same error:

 

[PrestaShopException]

No access reference in table module_access for id_module 38.
at line 1743 in file classes/module/Module.php

1737. 				self::$cache_permissions[$employee->id_profile][$row['id_module']]['configure'] = $row['configure'];1738. 			}1739. 		}1740. 1741. 		if (!isset(self::$cache_permissions[$employee->id_profile][$id_module]))1742. 			throw new PrestaShopException('No access reference in table module_access for id_module '.$id_module.'.');1743. 1744. 		return (bool)self::$cache_permissions[$employee->id_profile][$id_module][$variable];1745. 	}1746. 1747. 	/**

 

 

The link you gave me in your reply talkes about classes/Hook.php

This error mentions classes/module/Module.php

 

When I open my hook.php there is now "if (isset($context->employee) && !$moduleInstance->getPermission('view', $context->employee))" on row 378. When I search in hook.php there is nu such text on any row.

 

How can I solve this ?  Thanks for your help.

 

I have to shops that I have to move to another host before July 1st so I hope it can work before then. The other shop is on an older version (cannot update theme template yet) and put another post on forum. Also login problem but I am not sure if it is the same.

 

 

PS

In hook.php is see (from row 392+)

 

            // Check permissions
            if ($check_exceptions)
            {
                $exceptions = $moduleInstance->getExceptions($array['id_hook']);
                $controller = Dispatcher::getInstance()->getController();
                                
                if (in_array($controller, $exceptions))
                    continue;
                
                //retro compat of controller names
                $matching_name = array(
                    'authentication' => 'auth',
                    'compare' => 'products-comparison',
                    );
                if (isset($matching_name[$controller]) && in_array($matching_name[$controller], $exceptions))
                    continue;
                if (Validate::isLoadedObject($context->employee) && !$moduleInstance->getPermission('view', $context->employee))
                    continue;
            }
 

Edited by Frevab (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...