Jump to content

La Date De Livraison En Anglais !


Recommended Posts

Ouep, le module EnvoiMoinsCher est bugué à ce niveau^^

 

Remplacez le code de la fonction dateToString($date) (qui est quand même magnifique d'incompétence !) ligne 3438 de envoimoinscher.php

    public function dateToString($date)
    {	
		$date_data = explode('/', strftime('%w/%d/%m/%Y', strtotime($date)));

		return $this->l('day' . $date_data[0]) . ' ' . $date_data[1] . ' ' .
		$this->l('month' . $date_data[2]) . ' ' . $date_data[3];
}
		  

Par:

    public function dateToString($date)
    {	
		$locale = array(
			strtolower(Configuration::get('PS_LOCALE_LANGUAGE')).'_'.strtoupper(Configuration::get('PS_LOCALE_COUNTRY').'.UTF-8'),
			strtolower(Configuration::get('PS_LOCALE_LANGUAGE')).'_'.strtoupper(Configuration::get('PS_LOCALE_COUNTRY')));

		setlocale(LC_ALL, $locale);
		return strftime('%A %d %B %Y', strtotime($date));
		  
    }

Si le code d'origine pouvait marcher (ce qui est impossible)  il afficherait:

Livraison le : jour4 14 mois01 2016

  • Like 1
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...