Where does $language originate from?

Post Reply
User avatar
cobber
Master Bludit
Posts: 78
Joined: Sun Feb 28, 2016 10:15 am
Location: Scotland
Has thanked: 21 times
Been thanked: 5 times

Have been looking at a couple of themes to get a handle on developing my own themes and noticed a variable named $language.

Does anyone know where this originates from?

I see it takes a parameter of text to be used as an output for the search bar but wanted to know more about any additional parameters or methods possibly associated with the variable.

eg: $langauge->p('search')
User avatar
Edi
Site Admin
Posts: 3121
Joined: Sun Aug 09, 2015 5:01 pm
Location: Zurich
Has thanked: 54 times
Been thanked: 77 times
Contact:

$language->p('search') is taken from the translation files in the directory /language of the plugin Search depending of the selected language of the installation.

If the word or its translation is used by the plugin itself it would be $L->get('Search').
Clickwork - Websites mit Bludit | Planet Bludit - Tipps und Snippets
Post Reply