Blesta
  • Package
  • Class
  • Tree
  • Deprecated

Packages

  • blesta
    • app
      • controllers
      • models
    • components
      • areyouahuman
      • auth
        • motp
        • oath
      • delivery
        • interfax
        • postal
          • methods
      • download
      • email
      • events
        • default
      • exchange
        • rates
          • google
            • finance
          • yahoo
            • finance
      • gateway
        • payments
      • gateways
      • invoice
        • delivery
        • templates
          • quickbooks
            • invoice
      • json
      • modules
      • net
        • amazon
          • s3
        • http
        • net
          • geo
            • ip
      • plugins
      • recaptcha
      • reports
        • aging
          • invoices
        • custom
          • report
        • invoice
          • creation
        • tax
          • liability
        • transactions
          • applied
          • received
      • security
      • session
        • cart
      • settingscollection
      • upgrades
        • tasks
      • upload
      • vcard
    • helpers
      • currency
        • format
      • data
        • structure
          • array
          • string
      • text
        • parser
      • widget
        • client
  • minPHP
    • components
      • input
      • record
    • helpers
      • color
      • data
        • structure
      • date
      • form
      • html
      • javascript
      • xml
    • lib
  • None
  • PHP

Classes

  • Accounts
  • ApiKeys
  • CalendarEvents
  • ClientGroups
  • Clients
  • Companies
  • Contacts
  • Countries
  • Coupons
  • CronTasks
  • Currencies
  • EmailGroups
  • Emails
  • Encryption
  • GatewayManager
  • Invoices
  • InvoiceTemplateManager
  • Languages
  • Logs
  • Marketplace
  • ModuleClientMeta
  • ModuleManager
  • Navigation
  • PackageGroups
  • PackageOptionGroups
  • PackageOptions
  • Packages
  • Payments
  • Permissions
  • PluginManager
  • Pricings
  • ReportManager
  • ServiceChanges
  • Services
  • Settings
  • Staff
  • StaffGroups
  • States
  • Taxes
  • Themes
  • Transactions
  • Users

Class Settings

System setting management

Model
Extended by AppModel
Extended by Settings
Package: blesta\app\models
Copyright: Copyright (c) 2010, Phillips Data, Inc.
License: The Blesta License Agreement
Link: Blesta
Located at app/models/settings.php

Methods summary

public mixed
# getSettings( )

Fetches all system settings

Fetches all system settings

Returns

mixed
An array of objects with key/value pairs of settings, false if no results found
public mixed
# getSetting( string $key )

Fetch a single setting by key name

Fetch a single setting by key name

Parameters

$key
string
$key The key name of the setting to fetch

Returns

mixed
An stdObject containg the key and value, false if no such key exists
public
# setSettings( array $settings, array $value_keys = null )

Sets a group of settings with key/value pairs

Sets a group of settings with key/value pairs

Parameters

$settings
array
$settings Settings to set as key/value pairs
$value_keys
array
$value_keys An array of key values to accept as valid fields

See

Settings::setSetting()
public
# setSetting( string $key, string $value, mixed $encrypted = null, integer $inherit = null )

Sets the setting with the given key, overwriting any existing value with that key

Sets the setting with the given key, overwriting any existing value with that key

Parameters

$key
string
$key The setting identifier
$value
string
$value The value to set for this setting
$encrypted
mixed
$encrypted True to encrypt $value, false to store unencrypted, null to encrypt if currently set to encrypt
$inherit
integer
$inherit Whether or not the setting should be inheritable
public
# unsetSetting( string $key )

Unsets a setting from the system settings. CAUTION: This method will physically remove the setting from the system, and could have dire consequences. You should never use this method, except when attempting to remove a setting created by Settings::setSettings() or Settings::setSetting() that did not previously exist for this installation.

Unsets a setting from the system settings. CAUTION: This method will physically remove the setting from the system, and could have dire consequences. You should never use this method, except when attempting to remove a setting created by Settings::setSettings() or Settings::setSetting() that did not previously exist for this installation.

Parameters

$key
string
$key The setting to unset
public string
# getVersion( )

Returns the source version of Blesta

Returns the source version of Blesta

Returns

string
The source version of Blesta

See

Settings::getDbVersion()
public string
# getDbVersion( )

Returns the database version of Blesta. A shortcut for Settings::getSetting("database_version"). Often this will not be exactly the same as the source version because database changes are not made in every sourve version update.

Returns the database version of Blesta. A shortcut for Settings::getSetting("database_version"). Often this will not be exactly the same as the source version because database changes are not made in every sourve version update.

Returns

string
The source version of Blesta

See

Settings::getVersion()
public boolean
# upgradable( )

Returns whether or not there are upgrade tasks to run

Returns whether or not there are upgrade tasks to run

Returns

boolean
True if there are upgrade tasks to run, false otherwise

Methods inherited from AppModel

_(), __construct(), boolToInt(), currencyToDecimal(), dateToUtc(), errors(), getPerPage(), ifSet(), loadCrypto(), setDefaultIfEmpty(), setPerPage(), setRulesIfSet(), strToBool(), systemDecrypt(), systemEncrypt(), systemHash(), truncateDecimal(), validateExists(), validateStateCountry()

Methods inherited from Model

affectedRows(), begin(), commit(), getConnection(), lastInsertId(), makeDSN(), prepare(), query(), rollBack(), setAttribute(), setFetchMode()

Magic methods summary

Properties summary

Properties inherited from AppModel

$replacement_keys

Blesta API documentation generated by ApiGen 2.8.0