0

I connect to my Ubuntu server with command line.

I have installed Apache and, with cURL (PHP) I've tried to connect to IMDb and get data from that website.

But some of the data have German titles because of my server (which is in Germany), and I want to load all titles in English language!

I should change my default country but I don't know how to do that in Ubuntu.

I've searched and found these codes :

sudo dpkg-reconfigure tzdata

Any help, please?

Cristiana Nicolae
  • 4,460
  • 9
  • 30
  • 46
Hamed Ap
  • 1
  • 3

1 Answers1

0

First install the English language packs.

sudo apt-get install language-pack-en language-pack-en-base manpages

You then need to execute nano /etc/default/locale and replace the French lines with:

LANG=en_US.UTF-8
LANGUAGE=en_US:en

You can then remove the German langauge pack as thus:

sudo apt-get remove language-pack-de language-pack-de-base manpages-de

Reboot and you should have English as the default.

More info.

Tony Lancer
  • 1,003
  • 9
  • 23
  • You mean Germany ? – Hamed Ap Sep 25 '16 at 10:46
  • @HamedAp Yes, my silly mistake. Didn't double check the answer. Too excited to help. Fixed the answer. – Tony Lancer Sep 25 '16 at 11:08
  • i do 2 steps . 3rd step do not uninstall anything . because i dont have DE language in my system !!! – Hamed Ap Sep 25 '16 at 11:33
  • "DE" is Deutsch(relating to Germany, people, language, etc). IF you don't have DE then that means you never had it. – Tony Lancer Sep 25 '16 at 11:49
  • What does the command `locale` return? – Tony Lancer Sep 25 '16 at 11:51
  • `# locale LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_CTYPE="en_US.UTF-8" LC_NUMERIC="en_US.UTF-8" LC_TIME="en_US.UTF-8" LC_COLLATE="en_US.UTF-8" LC_MONETARY="en_US.UTF-8" LC_MESSAGES="en_US.UTF-8" LC_PAPER="en_US.UTF-8" LC_NAME="en_US.UTF-8" LC_ADDRESS="en_US.UTF-8" LC_TELEPHONE="en_US.UTF-8" LC_MEASUREMENT="en_US.UTF-8" LC_IDENTIFICATION="en_US.UTF-8" LC_ALL=` – Hamed Ap Sep 25 '16 at 12:26
  • Can you load the page that you loaded again? It should be in English(provided that you have logged out and logged in again. – Tony Lancer Sep 25 '16 at 12:28
  • again Germany ! no diffrent ! – Hamed Ap Sep 25 '16 at 12:59
  • Weird. Your locale file returns US, but you still get German data. What does `cat /etc/localtime` and `cat /etc/timezone` return? – Tony Lancer Sep 26 '16 at 15:27