Any ideas for developing a website with several languages ​​- SEO, php, mysql

I just finished the customers website and now they want to have different languages.

Currently, the contents of sites are stored in tables in MySQL db:

  • pages: seotitle, seodesc, smallHtml, fullHtml

  • Products: ID, seotitle, seodesc, smallHtml, fullHtml

I thought a good way to do this would be to have an extra table:

  • languages: identifier, language, language

Then change the page and product table to:

  • pages: slug , seotitle, seodesc, smallHtml, fullHtml, languageCode
  • : identifier, slug , seotitle, seodesc, smallHtml, fullHtml, languageCode

So, I would use a query like

SELECT * FROM pages WHERE slug = '$slug' AND language='$language'

$language cookie ?

, , SEO. URL- /pages.php?slug=page-slug. mod_rewrite /pages/page-slug.

, /pages.php?slug=page-slug&code=languagecode /pages/page-slug/languagecode. .

- ?

- , , , , .

.

/////

http://en.kioskea.net/faq/596-change-the-language-of-your-website , URL-, Google

+3
2

, , , , , .

- ( ) , , ISO , . English = ru .. URL- en.websitename.com. , - , URL-, , , www.websitename.com, fr.websitename.com. , , , URL- . URL- SEO, .

, , ( , ). - (. ). , , ( ) , , , , /.

SEO: . .

+3

Google , URL-, , :

Google , URL- .

: HTTP Content-Language, lang , .

-, - (. PHP); (. HTTP).

URI - . , URI ( ).

URI , . .

+5

All Articles