Jump to content

Recommended Posts

Posted

Hi, in my installation appear this advice:

Note: your current server locale setting isn’t working as expected with the UTF-8 charset and may cause minor issues. Your current locale setting is “C”. Please add this to your /site/config.php file (adjust “en_US.UTF-8” as needed): setlocale(LC_ALL,'en_US.UTF-8');

Now, my config.php file is this:


 

?php namespace ProcessWire;

/**
 * ProcessWire Configuration File
 *
 * Site-specific configuration for ProcessWire
 * 
 * Please see the file /wire/config.php which contains all configuration options you may
 * specify here. Simply copy any of the configuration options from that file and paste
 * them into this file in order to modify them. 
 * 
 * SECURITY NOTICE
 * In non-dedicated environments, you should lock down the permissions of this file so
 * that it cannot be seen by other users on the system. For more information, please
 * see the config.php section at: https://processwire.com/docs/security/file-permissions/
 * 
 * This file is licensed under the MIT license
 * https://processwire.com/about/license/mit/
 *
 * ProcessWire 3.x, Copyright 2016 by Ryan Cramer
 * https://processwire.com
 *
 */

if(!defined("PROCESSWIRE")) die();

/*** SITE CONFIG *************************************************************************/

/** @var Config $config */

/**
 * Enable debug mode?
 *
 * Debug mode causes additional info to appear for use during dev and debugging.
 * This is almost always recommended for sites in development. However, you should
 * always have this disabled for live/production sites.
 *
 * @var bool
 *
 */
$config->debug = false;

/**
 * Prepend template file
 *
 * PHP file in /site/templates/ that will be loaded before each page's template file.
 * Example: _init.php
 *
 * @var string
 *
 */
$config->prependTemplateFile = '_init.php';

/**
 * Append template file
 *
 * PHP file in /site/templates/ that will be loaded after each page's template file.
 * Example: _main.php
 *
 * @var string
 *
 */
$config->appendTemplateFile = '_main.php';




/*** INSTALLER CONFIG ********************************************************************/

/**
 * Installer: Database Configuration
 * 
 */
$config->dbHost = 'localhost';
$config->dbName = 'permacul_dbpwire';
$config->dbUser = 'permacul_dbpwire';
$config->dbPass = '9g9p(SF0S!';
$config->dbPort = '3306';

/**
 * Installer: User Authentication Salt 
 * 
 * Must be retained if you migrate your site from one server to another
 * 
 */
$config->userAuthSalt = 'edb4de86bb988b98d80e9c223cc944d0'; 

/**
 * Installer: File Permission Configuration
 * 
 */
$config->chmodDir = '0755'; // permission for directories created by ProcessWire
$config->chmodFile = '0644'; // permission for files created by ProcessWire 

/**
 * Installer: Time zone setting
 * 
 */
$config->timezone = 'America/New_York';

/**
 * Installer: Admin theme
 * 
 */
$config->defaultAdminTheme = 'AdminThemeUikit';

/**
 * Installer: Unix timestamp of date/time installed
 * 
 * This is used to detect which when certain behaviors must be backwards compatible.
 * Please leave this value as-is.
 * 
 */
$config->installed = 1554197421;


/**
 * Installer: HTTP Hosts Whitelist
 * 
 */
$config->httpHosts = array('www.permaculturaorganica.info', 'www.www.permaculturaorganica.info');

So, where e what I must change?

Posted

Add this line on config.php for English (or change it for Italian).

/**
 * Server locale setting
 * 
 */
setlocale(LC_ALL,'en_US.UTF-8');

 

Posted

It is it_IT.UTF-8 like Ivan mentioned. Is the language and the country/region, for instance:

pt_PT and pt_BR. On for Portugal and the other for Brazil.

Posted

Of course, this it_IT locale needs to be installed on our server to work.

So, on a Linux server:

//List installed locales
$ locale

// Install yours if not on that list
$ locale-gen it_IT.UTF-8

 

  • Like 1
Posted

Ok, so in Linux Server I must add in config.php:

/**
 * Server locale setting
 * 
 */
setlocale(LC_ALL,'it_IT.UTF-8');


//List installed locales
$ locale

// Install yours if not on that list
$ locale-gen it_IT.UTF-8

but in Windows Server what change?

Posted
5 hours ago, franciccio-ITALIANO said:

//List installed locales $ locale // Install yours if not on that list $ locale-gen it_IT.UTF-8

These commands should be done in the Linux command line, sorry for the confusion.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...