[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/installation/src/Model/ -> LanguagesModel.php (summary)

(no description)

Copyright: (C) 2012 Open Source Matters, Inc.
License: GNU General Public License version 2 or later; see LICENSE.txt
File Size: 543 lines (15 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

LanguagesModel:: (16 methods):
  __construct()
  getItems()
  install()
  getLanguageManifest()
  getPackageUrl()
  downloadPackage()
  getInstalledlangsAdministrator()
  getInstalledlangsFrontend()
  getInstalledlangs()
  getLanguageList()
  compareLanguages()
  getPath()
  getClient()
  setDefault()
  getOptions()
  getForm()


Class: LanguagesModel  - X-Ref

Language Installer model for the Joomla Core Installer.

__construct()   X-Ref
Constructor: Deletes the default installation config file and recreates it with the good config file.


getItems()   X-Ref
Generate a list of language choices to install in the Joomla CMS.

return: array

install($lids)   X-Ref
Method that installs in Joomla! the selected languages in the Languages View of the installer.

param: array  $lids  List of the update_id value of the languages to install.
return: boolean  True if successful

getLanguageManifest($uid)   X-Ref
Gets the manifest file of a selected language from a the language list in an update server.

param: integer  $uid  The id of the language in the #__updates table.
return: string

getPackageUrl($remoteManifest)   X-Ref
Finds the URL of the package to download.

param: string  $remoteManifest  URL to the manifest XML file of the remote package.
return: string|boolean

downloadPackage($url)   X-Ref
Download a language package from a URL and unpack it in the tmp folder.

param: string  $url  URL of the package.
return: array|boolean  Package details or false on failure.

getInstalledlangsAdministrator()   X-Ref
Get Languages item data for the Administrator.

return: array

getInstalledlangsFrontend()   X-Ref
Get Languages item data for the Frontend.

return: array  List of installed languages in the frontend application.

getInstalledlangs($clientName = 'administrator')   X-Ref
Get Languages item data.

param: string  $clientName  Name of the cms client.
return: array

getLanguageList($clientId = 1)   X-Ref
Get installed languages data.

param: integer  $clientId  The client ID to retrieve data for.
return: object  The language data.

compareLanguages($lang1, $lang2)   X-Ref
Compare two languages in order to sort them.

param: object  $lang1  The first language.
param: object  $lang2  The second language.
return: integer

getPath()   X-Ref
Get the languages folder path.

return: string  The path to the languages folders.

getClient($client = 'administrator')   X-Ref
Get the client object of Administrator or Frontend.

param: string  $client  Name of the client object.
return: object

setDefault($language, $clientName = 'administrator')   X-Ref
Set the default language.

param: string  $language    The language to be set as default.
param: string  $clientName  The name of the CMS client.
return: boolean

getOptions()   X-Ref
Get the current setup options from the session.

return: array

getForm($view = null)   X-Ref
Get the model form.

param: string|null $view  The view being processed.
return: mixed  JForm object on success, false on failure.



Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer