Skip to content

Codeigniter hook for multi language support, focuses on support for SEO friendly URLs in each language.

Notifications You must be signed in to change notification settings

webhacking/CodeIgniter-Language-Switch

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

CodeIgniter Language Switch

Allows for the switching of languages within CodeIgniter, with a focus on support for SEO friendly URLs, eg.

SEO URLs default to using language codes if no translation is provided, eg.

Language codes can also be set as a default as a directory (above) or in query strings, eg.

Requirements

  1. CodeIgniter 2+

Installation and use

  1. Copy files to relevant places, if files already exist (eg. config/autoload.php) copy code into existing files
  2. Configure your languages in config/languages.php
  3. Create your URL translations for SEO links
  4. Put links to change languages in your views using "language_menu()"

Notes

  • You will need to use anchor() or site_url() for all internal links, you should be doing this anyway
  • Currently SEO links only support REQUEST_URI, you will need to change code if you want support for other URI protocols

About

Codeigniter hook for multi language support, focuses on support for SEO friendly URLs in each language.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • PHP 100.0%