I faced this issue in my client website after downloaded into local and tried numerous way to solve the issue, there was no plugin to cause this issue, i completely disabled all the plugin and replaced new components files, BUT i did’t get any chance to make it work,

Finally i opened the configuration.php file which is located in the root directly of joomla, and found there was $live_site property under the JConfig class, i just emptied the value of $live_site variable. after this changes it worked successfully.