Guest Posted February 1, 2020 Share Posted February 1, 2020 (edited) Rename PHP function does not work in my module. Any idea to rename a directory? Thank you private function postValidation() { $context = Context::getContext(); if (Tools::isSubmit('submit_create_folder')) { rename(_PS_ROOT_DIR_.'/'.Configuration::get('module_directory_home'),_PS_ROOT_DIR_.'/'.Tools::getValue('module_directory_home')); Configuration::updateValue('module_directory_home', Tools::getValue('module_directory_home')); } ...... ... .. Edited February 2, 2020 by Guest (see edit history) Link to comment Share on other sites More sharing options...
joseantgv Posted February 2, 2020 Share Posted February 2, 2020 Have you checked if it executes IF condition? Link to comment Share on other sites More sharing options...
Guest Posted February 2, 2020 Share Posted February 2, 2020 I've disabled debug mode and everything is working. Thank you for your response. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now