Jump to content

[SOLVED] Error Log, PHP Fatal error - Translation not found


ljubica

Recommended Posts

Hello,

 

I cant access my "Log in" page "HTTP ERROR 500".

 

In public_html I found this error_log:

PHP Fatal error: Cannot redeclare class Symfony\Component\DependencyInjection\ContainerAwareInterface in /home/name/public_html/app/cache/prod/classes.php on line 7247

}
}
namespace Symfony\Component\DependencyInjection
{
interface ContainerAwareInterface
{
public function setContainer(ContainerInterface $container = null);
}
}

Web site is still acive, just I cant access "admin log in".

 

Hope someone can help me.

Thank you very much

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

Before Fatal Error, I had:

PHP Warning:  Invalid argument supplied for foreach() in /home/namel/public_html/src/PrestaShopBundle/Twig/TranslationsExtension.php on line 115
PHP Warning:  reset() expects parameter 1 to be array, null given in /home/name/public_html/src/PrestaShopBundle/Twig/TranslationsExtension.php on line 143
    {
        $output = '';
        $hasMessages = $this->hasMessages($subtree);

        if ($hasMessages) {
            list($camelizedDomain, $messages) = each($subtree['__messages']);

            foreach ($messages as $translationKey => $translation) {
                $viewProperties['camelized_domain'] = $camelizedDomain;
                $viewProperties['translation_key'] = $translationKey;
                $viewProperties['translation'] = $translation;

                $output .= $this->renderEditTranslationForm($viewProperties);
            }
        } else {
            foreach ($subtree as $tree) {
                $output .= $this->concatenateEditTranslationForm($tree, $viewProperties);
            }
        }

        if ($hasMessages && count($subtree) > 1) {
            unset($subtree['__messages']);
            $output .= $this->concatenateEditTranslationForm($subtree, $viewProperties);
        }

        return $output;
    }
    {
        $this->theme = $themeName;

        $output = '';
        end($translationsTree);
        list($lastTranslationDomain) = each($translationsTree);
        reset($translationTree);

        foreach ($translationsTree as $topLevelDomain => $tree) {
            $output .= $this->concatenateSubtreeHeader($topLevelDomain, $tree);

            if ($lastTranslationDomain !== $topLevelDomain) {
                $output .= '<hr />';
            }
        }

        return $output;
    }
Link to comment
Share on other sites

I can Log In in debug mode only.

 

Silenced Errors:

filemtime(): stat failed for /home/name/public_html/admin/themes/new-theme/css/admin-theme.cssContext: { "name": "E_WARNING", "type":2,"file": "/home/name/public_html/classes/controller/AdminController.php", "line":427,"level":28928,"scream":true}

 

And translation messages:

"These messages are not available for the given locale and cannot be found in the fallback locales. Add them to the translation catalogue to avoid Symfony outputting untranslated contents"

 

Log messages:

 

WARNING00:08:01 translation Translation not found.Context: { "id": "Upload a module", "domain": "Admin.Modules.Feature", "locale": "sr-CS" }

and too many WARNING translations...

 

I translated usiing International/Translations/Themes translations

 

 

Any suggestion?

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

  • 4 weeks later...

Hi!!

 

I have the same problem!!

 

Do you know how to solve the problem?

 

 

Thank you

 

Hi,

 

I really do not know. I'm sorry... I was at the beginning, so I re-installed.
 
Now, I have problem about translations again...
Each time I use manual translation error_log appears in public_html. But I can log in as admin.

 

Hope someone will help you.

Link to comment
Share on other sites

It's strange. I've tried to reproduce the problem in a local installation with the sames modules and content and works well, and I can modify translations in backend without problem.

 

And in the production website I have the same problem and mesage error than you.

 

I have a backup of my website before appers this error., so i can re-install

 

I understand that re-installing has solved the problem, right? But if you enter the backend of translations error appears again, right?

Link to comment
Share on other sites

  • 6 months later...
  • 6 years later...

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...