Joomla CMS  4.2.2
Documentation des API du CMS Joomla en version 4.2.2
Référence de la classe Text

Fonctions membres publiques statiques

static _ ($string, $jsSafe=false, $interpretBackSlashes=true, $script=false)
 
static alt ($string, $alt, $jsSafe=false, $interpretBackSlashes=true, $script=false)
 
static plural ($string, $n)
 
static sprintf ($string)
 
static printf ($string)
 
static script ($string=null, $jsSafe=false, $interpretBackSlashes=true)
 
static getScriptStrings ()
 

Attributs protégés statiques

static $strings = array()
 

Fonctions membres privées statiques

static passSprintf (&$string, $jsSafe=false, $interpretBackSlashes=true, $script=false)
 

Description détaillée

Text handling class.

Depuis
1.7.0

Documentation des fonctions membres

◆ _()

static _ (   $string,
  $jsSafe = false,
  $interpretBackSlashes = true,
  $script = false 
)
static

Translates a string into the current language.

Examples: ‘<script>alert(Joomla.Text._(’<?php echo Text::_("JDEFAULT", array("script"=>true)); ?>'));</script>‘ will generate an alert message containing 'Default’ <?php echo Text::_("JDEFAULT"); ?> will generate a 'Default' string

Paramètres
string$stringThe string to translate.
mixed$jsSafeBoolean: Make the result javascript safe.
boolean$interpretBackSlashesTo interpret backslashes (\=\,
=carriage return, =tabulation)
boolean$scriptTo indicate that the string will be push in the javascript language store
Renvoie
string The translated string or the key if $script is true
Depuis
1.7.0
Exemples:
C:/laragon/www/_install/Joomla_422-Stable-Full_Package_French_v1/libraries/src/HTML/HTMLHelper.php.

Références Language\$lang, $script, $strings, et Factory\getLanguage().

Référencé par JsonResponse\__construct(), Response\__construct(), TransitionButton\__construct(), WorkflowController\__construct(), WorkflowsController\__construct(), StageController\__construct(), TransitionController\__construct(), DisplayController\__construct(), TaskOption\__construct(), TransitionsController\__construct(), StagesController\__construct(), ActionButton\__construct(), Authentication\__construct(), InstallerExtension\__construct(), Pagination\_buildDataObject(), FileStorage\_deleteFolder(), ExtensionAdapter\_endElement(), HelpButton\_getCommand(), InstallModel\_getPackageFromFolder(), InstallModel\_getPackageFromUpload(), InstallModel\_getPackageFromUrl(), Pagination\_list_footer(), Editor\_loadEditor(), HtmlView\_prepareDocument(), ContactController\_sendEmail(), Installer\abort(), JGrid\action(), Access\actions(), LinksController\activate(), RegistrationModel\activate(), UsersController\activate(), LinkModel\activate(), UserModel\activate(), UserHelper\activateUser(), ModuleController\add(), FormController\add(), InstallerScript\addDashboardMenu(), Users\addNote(), Shortcut\addShortcuts(), HtmlView\addToolbar(), FormView\addToolbar(), ListView\addToolbar(), InstallController\ajax_upload(), LevelController\allowEdit(), UpdateModel\applyUpdateSite(), ActionsDropdown\archive(), MethodController\assertCanDelete(), MethodController\assertCanEdit(), MethodsController\assertLoggedInUser(), MethodController\assertLoggedInUser(), TasksModel\attachTaskOptions(), SiteApplication\authorise(), IndexerController\batch(), LinksController\batch(), FormController\batch(), AdminModel\batch(), UserModel\batch(), AdminModel\batchAccess(), ItemModel\batchCopy(), ModuleModel\batchCopy(), CategoryModel\batchCopy(), FieldModel\batchCopy(), AdminModel\batchLanguage(), ArticleModel\batchMove(), ModuleModel\batchMove(), ItemModel\batchMove(), AdminModel\batchMove(), CategoryModel\batchMove(), FieldModel\batchMove(), Modules\batchOptions(), UserModel\batchReset(), AdminModel\batchTag(), ContactModel\batchUser(), UserModel\batchUser(), Joomla\CMS\MVC\Model\batchWorkflowStage(), StyleTable\bind(), Menu\bind(), BannerTable\bind(), User\bind(), UserModel\block(), PhpSetting\boolean(), Select\booleanlist(), LanguageHelper\branchLanguageTitle(), Number\bytes(), Behavior\calendartranslation(), CallbackController\callback(), LevelModel\canDelete(), StageModel\canDelete(), TemplateHelper\canUpload(), MediaHelper\canUpload(), UpdateController\captive(), Category\categories(), UsersController\changeBlock(), Language\check(), UpdateSite\check(), Usergroup\check(), LinkTable\check(), MenuType\check(), MessageTable\check(), MapTable\check(), Update\check(), MenuTable\check(), ViewLevel\check(), NewsfeedTable\check(), CoreContent\check(), Extension\check(), ClientTable\check(), StyleTable\check(), BannerTable\check(), Asset\check(), GroupTable\check(), Menu\check(), StageTable\check(), WorkflowTable\check(), Module\check(), FieldTable\check(), ContactTable\check(), Category\check(), Content\check(), User\check(), CssMenu\check(), AdminModel\checkCategoryId(), ApiController\checkContent(), MediaController\checkContent(), LocalAdapter\checkContent(), SetConfigurationCommand\checkDb(), DatabaseHelper\checkDbServerParameters(), FieldModel\checkDefaultValue(), TemplateAdapter\checkExistingExtension(), ModuleAdapter\checkExistingExtension(), PluginAdapter\checkExistingExtension(), InstallerAdapter\checkExistingExtension(), LibraryAdapter\checkExtensionInFilesystem(), PackageAdapter\checkExtensionInFilesystem(), InstallerAdapter\checkExtensionInFilesystem(), FormModel\checkin(), AssociationsController\checkin(), GroupsController\checkin(), FormModel\checkout(), DatabaseHelper\checkRemoteDbHost(), Session\checkToken(), BaseController\checkToken(), CMSApplication\checkUserRequireReset(), JSONController\checkValidToken(), TemplateModel\child(), Stream\chmod(), AssociationsModel\clean(), BannerModel\click(), Banner\clients(), Languages\clients(), Email\cloak(), Stream\close(), CategoryView\commonCategoryDisplay(), TemplateModel\copy(), TemplateAdapter\copyBaseFiles(), PluginAdapter\copyBaseFiles(), ModuleAdapter\copyBaseFiles(), PackageAdapter\copyBaseFiles(), ComponentAdapter\copyBaseFiles(), TemplateModel\copyFile(), Installer\copyFiles(), TemplateModel\copyStyles(), Icon\create(), Folder\create(), ConfigurationModel\createConfiguration(), DatabaseModel\createDatabase(), ComponentAdapter\createExtensionRoot(), InstallerAdapter\createExtensionRoot(), TemplateController\createFile(), TemplateModel\createFile(), TemplateModel\createFolder(), TemplateModel\createOverride(), DatabaseModel\createTables(), Help\createUrl(), HTMLHelper\date(), Date\dayToString(), InstallationApplication\debugLanguage(), OverridesController\delete(), GroupsController\delete(), StageTable\delete(), WorkflowTable\delete(), DisplayController\delete(), MessageModel\delete(), MapsModel\delete(), LevelController\delete(), IndexModel\delete(), StyleModel\delete(), UpdatesitesModel\delete(), AdminController\delete(), HistoryModel\delete(), UpdatesitesController\delete(), StyleTable\delete(), TracksModel\delete(), MenuType\delete(), OverridesModel\delete(), MfaTable\delete(), MethodController\delete(), GroupModel\delete(), Folder\delete(), UserModel\delete(), ModuleModel\delete(), TemplateController\delete(), AdminModel\delete(), MethodsModel\deleteAll(), TemplateModel\deleteFile(), ApiController\deleteFiles(), TemplateModel\deleteFolder(), InstallerHelper\detectType(), DiscoverModel\discover_install(), InstallerAdapter\discover_install(), Installer\discover_install(), LanguageAdapter\discover_install(), Dispatcher\dispatch(), LegacyComponentDispatcher\dispatch(), AdministratorApplication\dispatch(), InstallationApplication\dispatch(), CategoryFeedView\display(), FeedView\display(), TextView\display(), JsonView\display(), DisplayController\display(), XmlView\display(), CategoriesView\display(), HtmlView\display(), MethodsController\display(), Editor\display(), JsonapiView\displayList(), PlgUserProfile\dob(), InstallerAdapter\doDatabaseTransactions(), LanguagesModel\downloadPackage(), StylesController\duplicate(), ModulesController\duplicate(), ActionsDropdown\duplicate(), StyleModel\duplicate(), ModuleModel\duplicate(), LinksController\duplicateUrls(), LinkModel\duplicateUrls(), ProfileController\edit(), OverrideController\edit(), AssociationController\edit(), TemplateController\edit(), Icon\edit(), Dropdown\edit(), FormController\edit(), Users\editor(), Stream\eof(), ApiController\execute(), Joomla\CMS\MVC\Model\executeTransition(), WorkflowStage\existing(), Query\explained(), MenuController\exportXml(), TemplateModel\extractArchive(), ActionsDropdown\feature(), ContactModel\featured(), ArticleModel\featured(), AjaxController\fetchAssociations(), DatabaseModel\fetchSchemaCache(), Stream\filesize(), Users\filterNotes(), FileAdapter\finaliseInstall(), ModuleAdapter\finaliseInstall(), ComponentAdapter\finaliseUninstall(), UpdateModel\finaliseUpgrade(), Installer\findManifest(), CredentialRepository\formatDate(), MethodsModel\formatRelative(), ListHelper\genericordering(), Stream\get_meta_data(), UsersHelper\getActiveOptions(), ModulesModel\getActivePositions(), ProviderManager\getAdapter(), TemplateModel\getArchive(), AssociationsHelper\getAssociationHtmlList(), TracksModel\getBaseName(), CapabilitiesModel\getCapabilities(), TracksModel\getCategoryName(), TracksModel\getClientName(), TemplatesHelper\getClientOptions(), ModulesHelper\getClientOptions(), InstallerHelper\getClientOptions(), BannersHelper\getClientOptions(), DebugHelper\getComponents(), ConfigHelper\getComponentsWithConfig(), TracksModel\getContent(), ContactComponent\getContexts(), ContentComponent\getContexts(), Joomlaupdate\getCoreUpdateNotification(), ActionlogsHelper\getCsvData(), CacheModel\getData(), PlgSystemTasknotification\getDataFromTask(), MessagesModel\getExtensionName(), SysinfoModel\getExtensions(), InstallerHelper\getExtensionTypes(), FeedHelper\getFeed(), TemplateModel\getFiles(), ActionlogsModel\getFilterForm(), FinderIndexCommand\getFilters(), TemplateModel\getFont(), OverrideModel\getForm(), TemplateModel\getForm(), ContenthistoryHelper\getFormValues(), MenuField\getGroups(), GroupedlistField\getGroups(), WorkflowstageField\getGroups(), TemplatestyleField\getGroups(), ChromestyleField\getGroups(), BreadcrumbsHelper\getHome(), ActionlogsHelper\getHumanReadableLogMessage(), TemplateModel\getImage(), ImpmadeField\getInput(), ClicksField\getInput(), PlugininfoField\getInput(), AssociationField\getInput(), FieldLayoutField\getInput(), FiltersField\getInput(), MenutypeField\getInput(), ModulelayoutField\getInput(), ComponentlayoutField\getInput(), MenuOrderingField\getInput(), ModulepositionField\getInput(), NewsfeedModel\getItem(), ArticleModel\getItem(), MessageModel\getItem(), ContactModel\getItem(), AdminModel\getItem(), WarningsModel\getItems(), SelectModel\getItems(), HistoryModel\getItems(), ItemsModel\getItems(), RequestController\getJson(), Authentication\getKnownAuthenticators(), TosField\getLabel(), SpacerField\getLabel(), NoteField\getLabel(), LoginHelper\getLanguageList(), LanguagesModel\getLanguages(), ContenthistoryField\getLayoutData(), TermsField\getLayoutData(), PrivacyField\getLayoutData(), UserField\getLayoutData(), FormField\getLayoutData(), Pagination\getLimitBox(), StatsHelper\getList(), TagsSimilarHelper\getList(), ArticlesArchiveHelper\getList(), TemplateModel\getMediaFiles(), ItemsModel\getMenu(), DatabaseController\getMenuBadgeData(), DisplayController\getMenuBadgeData(), DiscoverController\getMenuBadgeData(), UpdateController\getMenuBadgeData(), MenusHelper\getMenuItems(), ModulesHelper\getModules(), UpdateModel\getNonCoreExtensions(), UpdateModel\getNonCorePlugins(), AliastagField\getOptions(), ComponentsField\getOptions(), SearchfilterField\getOptions(), SessionhandlerField\getOptions(), WorkflowComponentSectionsField\getOptions(), ExtensionField\getOptions(), MenuParentField\getOptions(), CachehandlerField\getOptions(), ComponentsCategoryField\getOptions(), LogtypeField\getOptions(), MenuOrderingField\getOptions(), MenuPresetField\getOptions(), ConfigComponentsField\getOptions(), ContenttypesField\getOptions(), ComponentsFieldsField\getOptions(), ComponentsFieldgroupField\getOptions(), ComponentsWorkflowField\getOptions(), CategoryField\getOptions(), DatabaseconnectionField\getOptions(), LanguageclientField\getOptions(), LimitboxField\getOptions(), ContenttypeField\getOptions(), TemplatesListField\getOptions(), SubfieldsField\getOptions(), ListField\getOptions(), WorkflowconditionField\getOptions(), TransitionField\getOptions(), PredefinedlistField\getOptions(), PluginsField\getOptions(), CategoryeditField\getOptions(), CronField\getOptions(), SqlField\getOptions(), MethodModel\getPageTitle(), CaptiveModel\getPageTitle(), LocalAdapter\getPathInformation(), SysinfoModel\getPHPInfo(), ChecksModel\getPhpOptions(), UpdateModel\getPhpOptions(), ChecksModel\getPhpSettings(), UpdateModel\getPhpSettings(), Authentication\getPKCredentialRequestOptions(), ModulesHelper\getPositions(), ModulesModel\getPositions(), TemplateModel\getPreview(), ProviderManager\getProvider(), DisplayController\getQuickiconContent(), UsersHelper\getRangeOptions(), Pagination\getResultsCounter(), Stream\gets(), LocalAdapter\getSafeName(), TemplateModel\getSource(), MessagesHelper\getStateOptions(), ModulesHelper\getStateOptions(), UsersHelper\getStateOptions(), InstallerHelper\getStateOptions(), StatsAdminHelper\getStats(), AssociationsHelper\getSupportedExtension(), AdministratorApplication\getTemplate(), TemplateModel\getTemplate(), PopularHelper\getTitle(), LatestHelper\getTitle(), FormField\getTitle(), HelpModel\getToc(), ArticlesModel\getTransitions(), ModulesHelper\getTranslatedModulePosition(), UsersLatestHelper\getUsers(), ContentComponent\getWorkflowContexts(), ListHelper\images(), FinderIndexCommand\index(), FormView\initializeView(), InstallModel\install(), LanguagesModel\install(), UpdateModel\install(), Installer\install(), InstallerAdapter\install(), MenusHelper\installPreset(), HistoryController\keep(), HistoryModel\keep(), Access\level(), Menu\linkOptions(), CaptiveModel\loadCaptiveRenderOptions(), Form\loadField(), CMSApplication\login(), Joomla\Component\Scheduler\Administrator\Traits\logTask(), Finder\mapslist(), Menu\menuItems(), Directory\message(), ToolbarHelper\modal(), Date\monthToString(), File\move(), Folder\move(), LocalAdapter\move(), Users\notesModal(), PlgSampledataMultilang\onAjaxSampledataApplyStep1(), PlgSampledataMultilang\onAjaxSampledataApplyStep2(), PlgSampledataMultilang\onAjaxSampledataApplyStep3(), PlgSampledataMultilang\onAjaxSampledataApplyStep4(), PlgSampledataMultilang\onAjaxSampledataApplyStep5(), PlgSampledataMultilang\onAjaxSampledataApplyStep6(), PlgSampledataMultilang\onAjaxSampledataApplyStep7(), PlgSampledataMultilang\onAjaxSampledataApplyStep8(), PlgSystemStats\onAjaxSendAlways(), PlgSystemStats\onAjaxSendNever(), PlgSystemStats\onAjaxSendStats(), PlgWorkflowPublishing\onContentBeforeChangeState(), PlgContentConfirmConsent\onContentPrepareForm(), FieldsListPlugin\onCustomFieldsPrepareDom(), PlgButtonModule\onDisplay(), PlgButtonFields\onDisplay(), Joomla\Plugin\Editors\TinyMCE\PluginTraits\onDisplay(), PlgQuickiconPrivacyCheck\onGetIcons(), PlgInstallerUrlInstaller\onInstallerAddInstallationTab(), PlgInstallerWebinstaller\onInstallerAddInstallationTab(), ContentHelper\onPrepareForm(), PlgPrivacyUser\onPrivacyCanRemoveData(), PlgSampledataMultilang\onSampledataGetOverview(), PlgUserContactCreator\onUserAfterSave(), PlgUserProfile\onUserBeforeSave(), Webauthn\onUserMultifactorGetMethod(), Totp\onUserMultifactorGetMethod(), Yubikey\onUserMultifactorGetMethod(), Fixed\onUserMultifactorGetMethod(), Email\onUserMultifactorGetMethod(), Stream\open(), IndexController\optimise(), IndexerController\optimize(), ListHelper\ordering(), Menu\ordering(), ModuleController\orderPosition(), TemplateController\overrides(), Router\parse(), Installer\parseFiles(), Installer\parseLanguages(), Installer\parseMedia(), TemplateAdapter\parseQueries(), InstallerAdapter\parseQueries(), Installer\parseSchemaUpdates(), Installer\parseSQLFiles(), Installer\parseXMLInstallFile(), DatabaseModel\populateDatabase(), MethodModel\populateMfaMethods(), Modules\positions(), ListHelper\positions(), ApiController\postFiles(), RequestController\postSaveHook(), CategoriesView\prepareDocument(), CategoryView\prepareDocument(), HtmlView\prepareDocument(), ContentmapField\prepareLevel(), ConfirmButton\prepareOptions(), ToolbarButton\prepareOptions(), HtmlView\prepareToolbar(), PublishedButton\preprocess(), FeaturedButton\preprocess(), Menu\preprocess(), CssMenu\preprocess(), ModulesModel\preprocessForm(), TemplatesModel\preprocessForm(), GroupModel\preprocessForm(), PluginModel\preprocessForm(), StyleModel\preprocessForm(), CategoryModel\preprocessForm(), ModuleModel\preprocessForm(), FieldModel\preprocessForm(), ItemModel\preprocessForm(), Query\processDates(), RemindModel\processRemindRequest(), ResetModel\processResetComplete(), ResetModel\processResetConfirm(), ResetModel\processResetRequest(), Query\processString(), ActionsDropdown\publish(), GroupsController\publish(), UpdatesitesModel\publish(), TemplateController\publish(), ManageModel\publish(), Dropdown\publish(), ItemsController\publish(), AdminController\publish(), MessageModel\publish(), InstalledModel\publish(), MapsModel\publish(), StageModel\publish(), WorkflowModel\publish(), IndexModel\publish(), AdminModel\publish(), Table\publish(), ItemModel\publish(), Languages\published(), DisplayController\purge(), ActionlogsController\purge(), LinksController\purge(), OverridesModel\purge(), DiscoverModel\purge(), UpdateModel\purge(), FinderIndexCommand\purge(), AssociationsModel\purge(), ApiController\putFiles(), FinderIndexCommand\putFilters(), Select\radiolist(), Stream\read(), UpdatesitesModel\rebuild(), FeedView\reconcileNames(), AdminModel\redirectToAssociations(), ModuleAdapter\refreshManifestCache(), LibraryAdapter\refreshManifestCache(), FileAdapter\refreshManifestCache(), PluginAdapter\refreshManifestCache(), TemplateAdapter\refreshManifestCache(), PackageAdapter\refreshManifestCache(), LanguageAdapter\refreshManifestCache(), Installer\refreshManifestCache(), ComponentAdapter\refreshManifestCache(), RegistrationModel\register(), Date\relative(), ManageModel\remove(), LanguageAdapter\removeExtensionFiles(), TemplateAdapter\removeExtensionFiles(), PackageAdapter\removeExtensionFiles(), ApplicationModel\removeroot(), TemplateModel\renameFile(), HtmlRenderer\render(), PublishedButton\render(), FeaturedButton\render(), FeedDocument\render(), GroupsController\reorder(), LevelsModel\reorder(), AdminController\reorder(), AdminModel\reorder(), MessageController\reply(), SearchesController\reset(), Joomla\Component\Media\Administrator\Provider\resolveAdapterAndPath(), AdminController\runTransition(), ConfigController\save(), StyleController\save(), TemplatesController\save(), OverrideController\save(), MediumModel\save(), OverrideModel\save(), GroupModel\save(), ComponentModel\save(), LanguageModel\save(), UserModel\save(), ApplicationModel\save(), MessageModel\save(), RequestModel\save(), StyleModel\save(), CategoryModel\save(), FormController\save(), TemplateModel\save(), AdminModel\save(), ItemModel\save(), SetConfigurationCommand\saveConfiguration(), GroupsController\saveorder(), LevelsModel\saveorder(), AdminController\saveorder(), AdminModel\saveorder(), Stream\seek(), Filter\select(), MailModel\send(), Mail\Send(), Email\sendCode(), JSONController\sendJsonResponse(), ActionlogModel\sendNotificationEmails(), ApplicationModel\sendTestMail(), System\server(), PhpSetting\set(), InstalledController\setDefault(), WorkflowsController\setDefault(), ItemsController\setDefault(), StagesController\setDefault(), WorkflowModel\setDefault(), StageModel\setDefault(), StyleModel\setHome(), ItemModel\setHome(), ConfigurationModel\setup(), TextField\setup(), CalendarField\setup(), LibraryAdapter\setupInstallPaths(), PluginAdapter\setupInstallPaths(), TemplateAdapter\setupInstallPaths(), PackageAdapter\setupInstallPaths(), ModuleAdapter\setupInstallPaths(), ComponentAdapter\setupInstallPaths(), LanguageAdapter\setupUninstall(), FileAdapter\setupUninstall(), LibraryAdapter\setupUninstall(), PluginAdapter\setupUninstall(), TemplateAdapter\setupUninstall(), PackageAdapter\setupUninstall(), ComponentAdapter\setupUninstall(), Filter\slider(), IndexerController\start(), Finder\statelist(), Privacy\statusLabel(), Language\store(), ContactTable\store(), ContentType\store(), MenuType\store(), FilterTable\store(), NewsfeedTable\store(), TagTable\store(), Menu\store(), Category\store(), Content\store(), FileAdapter\storeExtension(), LibraryAdapter\storeExtension(), PluginAdapter\storeExtension(), PackageAdapter\storeExtension(), TemplateAdapter\storeExtension(), PhpSetting\string(), ContactController\submit(), InstalledModel\switchAdminLanguage(), Stream\tell(), TimeRule\test(), PasswordRule\test(), EmailRule\test(), Templates\thumb(), Templates\thumbModal(), ToolbarHelper\title(), HTMLHelper\tooltipText(), PlgUserProfile\tos(), InstallerModel\translate(), PluginsModel\translate(), UpdateModel\translate(), ModulesModel\translate(), UpdateModel\translateExtensionName(), CaptiveModel\translateMethodName(), ActionsDropdown\trash(), PackageAdapter\triggerManifestScript(), InstallerAdapter\triggerManifestScript(), Finder\typeslist(), ActionsDropdown\unarchive(), ActionsDropdown\unfeature(), InstallerAdapter\uninstall(), TaskTable\unlock(), ActionsDropdown\unpublish(), StyleModel\unsetHome(), LanguageAdapter\update(), Installer\update(), File\upload(), UpdateModel\upload(), Stream\upload(), TemplateController\uploadFile(), TemplateModel\uploadFile(), Access\usergroup(), ListHelper\users(), LevelModel\validate(), TemplateModel\validate(), RequestModel\validate(), Form\validate(), FormField\validate(), Authentication\validateAssertionResponse(), DatabaseHelper\validateConnectionParameters(), ApplicationModel\validateDbConnection(), DisplayController\validateEntry(), Users\value(), Credentials\verifyAttestation(), Menus\visibility(), ArticleController\vote(), Directory\writable(), Stream\write(), et ApplicationModel\writeConfigFile().

◆ alt()

static alt (   $string,
  $alt,
  $jsSafe = false,
  $interpretBackSlashes = true,
  $script = false 
)
static

Translates a string into the current language.

Examples: ‘<?php echo Text::alt('JALL’, 'language'); ?>‘ will generate a 'All’ string in English but a "Toutes" string in French ‘<?php echo Text::alt('JALL’, 'module'); ?>‘ will generate a 'All’ string in English but a "Tous" string in French

Paramètres
string$stringThe string to translate.
string$altThe alternate option for global string
mixed$jsSafeBoolean: Make the result javascript safe.
boolean$interpretBackSlashesTo interpret backslashes (\=\,
=carriage return, =tabulation)
boolean$scriptTo indicate that the string will be pushed in the javascript language store
Renvoie
string The translated string or the key if $script is true
Depuis
1.7.0

Références $alt, $script, Factory\getLanguage(), et Language\hasKey().

Référencé par AdminLanguage\existing(), ContentLanguage\existing(), GroupedlistField\getGroups(), FormField\getLayoutData(), ListField\getOptions(), WorkflowconditionField\getOptions(), FolderlistField\getOptions(), FilelistField\getOptions(), et TextField\getOptions().

◆ getScriptStrings()

static getScriptStrings ( )
static

Get the strings that have been loaded to the JavaScript language store.

Renvoie
array
Depuis
3.7.0

Références $strings.

Référencé par HtmlDocument\getHeadData().

◆ passSprintf()

static passSprintf ( $string,
  $jsSafe = false,
  $interpretBackSlashes = true,
  $script = false 
)
staticprivate

Checks the string if it should be interpreted as sprintf and runs sprintf over it.

Paramètres
string&$stringThe string to translate.
mixed$jsSafeBoolean: Make the result javascript safe.
boolean$interpretBackSlashesTo interpret backslashes (\=\,
=carriage return, =tabulation)
boolean$scriptTo indicate that the string will be push in the javascript language store
Renvoie
boolean Whether the string be interpreted as sprintf
Depuis
3.4.4

Références $i, Language\$lang, $script, $strings, et Factory\getLanguage().

◆ plural()

static plural (   $string,
  $n 
)
static

Like Text::sprintf but tries to pluralise the string.

Note that this method can take a mixed number of arguments as for the sprintf function.

The last argument can take an array of options:

array('jsSafe'=>boolean, 'interpretBackSlashes'=>boolean, 'script'=>boolean)

where:

jsSafe is a boolean to generate a javascript safe strings. interpretBackSlashes is a boolean to interpret backslashes \->\,
->new line, ->tabulation. script is a boolean to indicate that the string will be push in the javascript language store.

Examples: ‘<script>alert(Joomla.Text._(’<?php echo Text::plural("COM_PLUGINS_N_ITEMS_UNPUBLISHED", 1, array("script"=>true)); ?>'));</script>‘ will generate an alert message containing '1 plugin successfully disabled’ ‘<?php echo Text::plural('COM_PLUGINS_N_ITEMS_UNPUBLISHED’, 1); ?>‘ will generate a '1 plugin successfully disabled’ string

Paramètres
string$stringThe format string.
integer$nThe number of items
Renvoie
string The translated strings or the key if 'script' is true in the array of options
Depuis
1.7.0

Références $count, $key, Language\$lang, $n, $strings, $suffix, et Factory\getLanguage().

Référencé par LinksController\activate(), UsersController\activate(), LinksController\batch(), UsersController\changeBlock(), AdminController\checkin(), OverridesController\delete(), LevelController\delete(), UpdatesitesModel\delete(), AdminController\delete(), HtmlView\display(), ModulesController\duplicate(), LinksController\duplicateUrls(), PluginsController\getQuickiconContent(), CategoriesController\getQuickiconContent(), ItemsController\getQuickiconContent(), TagsController\getQuickiconContent(), ModulesController\getQuickiconContent(), DisplayController\getQuickiconContent(), ArticlesController\getQuickiconContent(), UsersController\getQuickiconContent(), LatestActionsHelper\getTitle(), LoggedHelper\getTitle(), PopularHelper\getTitle(), LatestHelper\getTitle(), HistoryController\keep(), Users\notes(), Users\notesModal(), ResetModel\processResetRequest(), TemplateController\publish(), ItemsController\publish(), AdminController\publish(), Date\relative(), LanguageAdapter\resetUserLanguage(), StyleModel\save(), MailModel\send(), ItemsController\setDefault(), et PasswordRule\test().

◆ printf()

static printf (   $string)
static

Passes a string thru an printf.

Note that this method can take a mixed number of arguments as for the sprintf function.

Paramètres
string$stringThe format string.
Renvoie
mixed
Depuis
1.7.0

Références $count, Language\$lang, et Factory\getLanguage().

◆ script()

static script (   $string = null,
  $jsSafe = false,
  $interpretBackSlashes = true 
)
static

◆ sprintf()

static sprintf (   $string)
static

Passes a string thru a sprintf.

Note that this method can take a mixed number of arguments as for the sprintf function.

The last argument can take an array of options:

array('jsSafe'=>boolean, 'interpretBackSlashes'=>boolean, 'script'=>boolean)

where:

jsSafe is a boolean to generate a javascript safe strings. interpretBackSlashes is a boolean to interpret backslashes \->\,
->new line, ->tabulation. script is a boolean to indicate that the string will be push in the javascript language store.

Paramètres
string$stringThe format string.
Renvoie
string The translated strings or the key if 'script' is true in the array of options.
Depuis
1.7.0

Références $count, Language\$lang, $strings, et Factory\getLanguage().

Référencé par AdminController\__construct(), BaseDatabaseModel\__construct(), FormController\__construct(), ApiController\__construct(), FileStorage\_deleteFolder(), ExtensionAdapter\_endElement(), FileStorage\_filesInFolder(), FileStorage\_folders(), Captcha\_load(), FtpClient\_mode(), FtpClient\_passive(), HtmlView\_prepareDocument(), FtpClient\_putCmd(), FtpClient\_verifyResponse(), RegistrationModel\activate(), LinkModel\activate(), MediaController\add(), InstallerScript\addDashboardMenu(), HtmlView\addToolbar(), File\append(), FtpClient\append(), Patcher\applyHunk(), AdministratorService\association(), Menus\association(), Authentication\authenticate(), DatabaseModel\backupDatabase(), LinksController\batch(), FormController\batch(), ItemModel\batchCopy(), AdminModel\batchCopy(), CategoryModel\batchCopy(), ArticleModel\batchMove(), ItemModel\batchMove(), AdminModel\batchMove(), CategoryModel\batchMove(), Joomla\CMS\MVC\Model\batchWorkflowStage(), BannerTable\bind(), FormController\cancel(), LevelModel\canDelete(), MediaHelper\canUpload(), FtpClient\chdir(), MenuType\check(), ViewLevel\check(), User\check(), CssMenu\check(), Dispatcher\checkAccess(), SetConfigurationCommand\checkDb(), DatabaseHelper\checkDbServerParameters(), TemplateAdapter\checkExistingExtension(), ModuleAdapter\checkExistingExtension(), PluginAdapter\checkExistingExtension(), InstallerAdapter\checkExistingExtension(), PackageAdapter\checkExtensionInFilesystem(), ComponentAdapter\checkExtensionInFilesystem(), InstallerAdapter\checkExtensionInFilesystem(), AdminController\checkin(), DatabaseHelper\checkRemoteDbHost(), ConfigurationModel\checkTestingSampledata(), FtpClient\chmod(), DatabaseModel\compareUpdateVersion(), FtpClient\connect(), File\copy(), FileAdapter\copyBaseFiles(), LibraryAdapter\copyBaseFiles(), TemplateAdapter\copyBaseFiles(), PluginAdapter\copyBaseFiles(), ModuleAdapter\copyBaseFiles(), PackageAdapter\copyBaseFiles(), ComponentAdapter\copyBaseFiles(), TemplateModel\copyFile(), Installer\copyFiles(), TemplateModel\copyStyles(), FtpClient\create(), LanguageAdapter\createContentLanguage(), DatabaseModel\createDatabase(), ComponentAdapter\createExtensionRoot(), InstallerAdapter\createExtensionRoot(), TemplateModel\createFile(), MenuFactory\createMenu(), DatabaseModel\createTables(), LegacyFactory\createView(), StageTable\delete(), WorkflowTable\delete(), DisplayController\delete(), UpdatesitesModel\delete(), MenuType\delete(), File\delete(), MediumModel\delete(), Folder\delete(), FtpClient\delete(), Installer\discover_install(), DisplayController\display(), HtmlView\display(), ManageController\displayList(), UsersController\displayList(), ExtensionRemoveCommand\doExecute(), FinderIndexCommand\doExecute(), InstallerHelper\downloadPackage(), UpdateModel\downloadPackage(), Icon\edit(), MediaController\edit(), FormController\edit(), PlgWorkflowPublishing\enhanceItemForm(), ApiController\execute(), BaseController\execute(), Query\explained(), AjaxController\fetchAssociations(), DatabaseModel\fetchSchemaCache(), Folder\files(), FileAdapter\finaliseInstall(), ModuleAdapter\finaliseInstall(), UpdateModel\finaliseUpgrade(), CollectionAdapter\findUpdate(), ExtensionAdapter\findUpdate(), Folder\folders(), FtpClient\get(), ContentHelper\getActions(), AssociationsHelper\getAssociationHtmlList(), CapabilitiesModel\getCapabilities(), ComponentDispatcher\getController(), DatabaseModel\getErrorsMessage(), SysinfoModel\getExtensions(), FinderIndexCommand\getFilters(), OverrideModel\getForm(), PlugininfoField\getInput(), FieldLayoutField\getInput(), ModulelayoutField\getInput(), ComponentlayoutField\getInput(), NumberField\getInput(), TextField\getInput(), Parser\getInstance(), Pathway\getInstance(), Router\getInstance(), AbstractMenu\getInstance(), BaseController\getInstance(), CMSApplication\getInstance(), MediumModel\getItem(), MediaModel\getItems(), WarningsModel\getItems(), LanguagesModel\getLanguages(), TinymcebuilderField\getLayoutData(), DebugHelper\getLevelsOptions(), ArticlesArchiveHelper\getList(), MultilangstatusHelper\getModule(), BaseModel\getName(), AbstractView\getName(), BaseController\getName(), WorkflowComponentSectionsField\getOptions(), LanguageclientField\getOptions(), ListField\getOptions(), PluginsField\getOptions(), DatabaseModel\getOtherInformationMessage(), Pagination\getPagesCounter(), CMSApplication\getPathway(), ChecksModel\getPhpOptions(), UpdateModel\getPhpOptions(), ChecksModel\getPhpSettings(), UpdateModel\getPhpSettings(), DisplayController\getQuickiconContent(), Pagination\getResultsCounter(), BaseDatabaseModel\getTable(), AdministratorApplication\getTemplate(), UpdateAdapter\getUpdateSiteResponse(), RegistrationModel\getUserIdFromToken(), BaseController\getView(), FinderIndexCommand\index(), DatabaseModel\initialise(), InstallModel\install(), LanguagesModel\install(), LanguageAdapter\install(), UpdateModel\install(), Route\link(), FtpClient\listDetails(), FtpClient\listNames(), User\load(), Changelog\loadFromXml(), Update\loadFromXml(), Manifest\loadManifestFromXml(), HtmlView\loadTemplate(), FtpClient\login(), FtpClient\mkdir(), File\move(), Folder\move(), InstallerScript\moveCliFiles(), PlgSampledataMultilang\onAjaxSampledataApplyStep1(), PlgSampledataMultilang\onAjaxSampledataApplyStep2(), PlgSampledataMultilang\onAjaxSampledataApplyStep3(), PlgSampledataMultilang\onAjaxSampledataApplyStep4(), PlgSampledataMultilang\onAjaxSampledataApplyStep5(), PlgSampledataMultilang\onAjaxSampledataApplyStep6(), PlgSampledataMultilang\onAjaxSampledataApplyStep7(), PlgSystemLanguagecode\onContentPrepareForm(), FieldsPlugin\onCustomFieldsGetTypes(), ContentHelper\onPrepareForm(), ModuleController\orderPosition(), Installer\parseFiles(), Installer\parseLanguages(), Installer\parseMedia(), TemplateAdapter\parseQueries(), Installer\parseQueries(), Installer\parseSchemaUpdates(), Installer\parseSQLFiles(), FileAdapter\populateFilesAndFolderList(), InstallerScript\preflight(), PluginModel\preprocessForm(), RemindModel\processRemindRequest(), ResetModel\processResetComplete(), ResetModel\processResetConfirm(), ResetModel\processResetRequest(), PlgSampledataMultilang\publishContentLanguages(), FinderIndexCommand\putFilters(), FtpClient\pwd(), FtpClient\read(), UpdatesitesModel\rebuild(), Installer\refreshManifestCache(), RegistrationModel\register(), FtpClient\reinit(), ManageModel\remove(), PackageAdapter\removeExtensionFiles(), InstallerScript\removeFiles(), FtpClient\rename(), ActionsDropdown\render(), RssRenderer\render(), PublishedButton\render(), AtomRenderer\render(), FeaturedButton\render(), AdministratorApplication\render(), Toolbar\renderButton(), AdminController\reorder(), FtpClient\restart(), AdminController\runTransition(), ConfigController\save(), StyleController\save(), TemplatesController\save(), OverrideController\save(), MediumModel\save(), ApplicationModel\save(), FormController\save(), TemplateModel\save(), AdminController\saveorder(), Filter\select(), ApplicationModel\sendTestMail(), HtmlView\setDocumentTitle(), ItemModel\setHome(), Mail\setSender(), ConfigurationModel\setup(), PluginAdapter\setupInstallPaths(), TemplateAdapter\setupInstallPaths(), PackageAdapter\setupInstallPaths(), ModuleAdapter\setupInstallPaths(), ModuleAdapter\setupUninstall(), FtpClient\size(), Filter\slider(), Finder\statelist(), MenuType\store(), Menu\store(), FtpClient\store(), FileAdapter\storeExtension(), LibraryAdapter\storeExtension(), PluginAdapter\storeExtension(), PackageAdapter\storeExtension(), TemplateAdapter\storeExtension(), ArticleModel\storeVote(), InstalledController\switchAdminLanguage(), FtpClient\syst(), UrlRule\test(), EmailRule\test(), Templates\thumbModal(), PackageAdapter\triggerManifestScript(), InstallerAdapter\triggerManifestScript(), Finder\typeslist(), InstallerAdapter\uninstall(), LanguageAdapter\update(), File\upload(), TemplateController\uploadFile(), Form\validate(), FormField\validate(), DatabaseHelper\validateConnectionParameters(), ApplicationModel\validateDbConnection(), SetupModel\validateDbConnection(), DisplayController\validateEntry(), File\write(), et FtpClient\write().

Documentation des champs

◆ $strings

$strings = array()
staticprotected

La documentation de cette classe a été générée à partir du fichier suivant :