This is the documentation for LemonStand V1, which has been discontinued. You can learn more and upgrade your store here.

LemonStand Version 1 Has Been Discontinued

This documentation is for LemonStand Version 1. LemonStand is now offered as a cloud-based eCommerce platform.
You can try the new LemonStand and learn about upgrading here.

LemonStand Configuration Options

This page contains a list of parameters which you can use for configuring your LemonStand copy. All parameters listed here can be declared in the config/config.php file. Example:

$CONFIG['BACKEND_URL'] = '/backdoor';

Security

  • BACKEND_URL - specifies an URL of the Administration Area. Read more.
  • CONFIG_URL - specifies an URL of the Configuration Tool. Read more.
  • EDITABLE_FILES - specifies a list of text-based files which you can edit in the Resource Manager on the CMS/Resources page. By default you can edit JavaScript and CSS files.
  • SECURE_CONFIG_PATH - specifies a path to the secure config file (config.dat). Please use an absolute path in this parameter. If the config.dat file is in the /config directory, you can omit (comment out) this parameter. Default path is the config directory in your LemonStand installation root.
  • FILE_PERMISSIONS - specifies a permission mask to apply to when LemonStand overrides files. The mask should start with the 0 (zero) symbol: 0777. Default is 0777.
  • FOLDER_PERMISSIONS - specifies a permission mask to apply to when LemonStand overrides directories. The mask should start with the 0 (zero) symbol: 0777. Default is 0777.
  • CRON_ALLOWED_IPS - specifies a list of IP addresses allowed for executing scheduled tasks (like updating the catalog price rules).
  • FRONTEND_AUTH_COOKIE_LIFETIME - defines the lifetime for the front-end customer session cookies. The parameter value should be an integer number, specifying the number of days. Set the 0 value to remove cookies automatically when a visitor closes the browser.
  • AUTH_COOKIE_LIFETIME - defines the lifetime for the Administration Area user session cookies. The parameter value should be an integer number, specifying the number of days. Set the 0 value to remove cookies automatically when a user closes the browser.
  • USER_DISABLE_IP_CHECK - allows to disable the IP check for user authentication (based on cookies). This may be useful if you are randomly being logged out. This parameter is obsolete and not used since Core version 1.5.4.
  • SESSION_PARAM_NAME - name of the GET parameter used for passing the session identifier during the HTTP=>HTTPS redirections. The default value is ls_session_id.
  • ALLOWED_RESOURCE_EXTENSIONS - allows you to customize the allowed file extensions for resources. All files which do not have an extension in the list will be ignored. When requesting minified resources, this value is checked to verify it is allowed. The default is only CSS and JavaScript files (css and js, respectively). For example:
    $CONFIG['ALLOWED_RESOURCE_EXTENSIONS'] = array('js', 'css');
  • ALLOWED_RESOURCE_PATHS - allows you to customize the allowed base directories for resources. All files below this folder will be allowed (files of sub-directories). When requesting minified resources, this value is checked to verify the resource is not outside of the allowed directories. It is to prevent local file inclusion (LFI). The default is only the LemonStand installation directory. For example: 
    $CONFIG['ALLOWED_RESOURCE_PATHS'] = array(PATH_APP);
  • TICKET_PARAM_NAME  - name of the GET parameter used for passing the security ticket value during the HTTP=>HTTPS redirections. The default value is ls_frontend_ticket.
  • SEARCH_MAX_RECORDS - allows to limit the maximum number of products displayed by the search page. Default value is NULL (unlimited).
  • SECURE_COOKIES - determines if secure cookies should be used in the HTTPS mode. The default value is TRUE (enabled). The secure cookies feature can have undesirable effects in some cases. Secure cookies are not accessible in the HTTP mode. LemonStand handles HTTP/HTTPS redirection automatically, but this works only when visitors use links for navigating between pages. If they use the back/forward browser buttons the session information could be lost. This could be solved with disabling the secure cookies or with requiring the HTTPS mode for all website pages.
  • SECURITY_AUTO_REDIRECT - cleans up the page URL after the redirect between HTTP and HTTPS protocols by removing the GET parameters (ls_session_id and ls_frontend_ticket). Default value is TRUE (redirect).
  • FORCE_ADMIN_SSL - forces the HTTPS protocol in the Administration Area. The default value is FALSE (do not force).

Database

  • MYSQL_PERSISTENT - allows to disable MySQL Persistent mode. We noticed that persistent connection sometimes fails on some servers. Default is TRUE.
  • OPTIMIZE_FRONTEND_QUERIES - enables the front-end queries optimization. Default value is FALSE. Read the Performance tuning article for details.
  • ALLOW_DB_DESCRIBE_CACHE - enables the database structure caching. The caching reduces the number of DESCRIBE SQL requests and increases the overall system performance. Default value is FALSE. Read the Performance tuning article for details.
  • USE_PROXY_MODELS - enables the proxy models feature explained in the Perfrmance tuning article. Default value is FALSE.
  • driver - specifies MySQL driver. The default value is Db_MySQL. Use the Db_MySQLi value if PHP MySQL functions are deprecated on your server.

Updates

  • FREEZE_UPDATES - allows to freeze LemonStand updates. Read more. Default is FALSE.
  • AUTO_CHECK_UPDATES - allows to disable the automatic update checking. Default value is TRUE.

Image processing

  • IMAGEMAGICK_ENABLED - determines whether ImageMagick is enabled or not. Default is FALSE.
  • IMAGEMAGICK_PATH - if ImageMagick is enabled, the parameter should contain a path to a directory containing the convert script. Often the convert script is accessible from anywhere and you can leave the parameter empty.
  • IMAGE_JPEG_QUALITY - integer value (0-100), determining the quality of generated JPEG images. Default is 70.
  • IMAGE_JPEG_COLORSPACE - sets colorspace for processing JPEG images with ImageMagick. Default value is RGB. You can find a list of available color spaces in ImageMagick documentation.

Networking and HTTP request handling

  • REMOVE_GPC_SLASHES - forces LemonStand to remove slash characters from POST, GET and COOKIE input arrays. Usually LemonStand can automatically detect whether the PHP Magic Quotes feature is enabled, but on some servers the automatic detection fails and this flag is required. If you find that LemonStand adds slashes before quotes in your pages, templates or partials source code, set with parameter to TRUE. Default value is FALSE.
  • STANDARD_HTTP_PORTS - disables the automatic port guessing feature. Enabling this option could be helpful if the web server is behind a proxy server. When this feature is enabled, the system never uses port specifiers in URLs, assuming the default HTTP port is 80 and the default HTTPS port is 443. Default value is FALSE.
  • REMOTE_IP_HEADERS - defines the sequence of HTTP headers to read the client IP address from. Array value. Default value is 
    array( 'REMOTE_ADDR', 'HTTP_CLIENT_ip', 'HTTP_X_FORWARDED_FOR' )
  • DISABLE_HTTP_SUBREQUESTS - allows to disable the HTTP subrequests in some operations (like applying the catalog price rules). The default value is FALSE. 
  • ENABLE_REMOTE_RESOURCES - allows to disable the remote resources in the js_combine() and css_combine() calls.The default value is TRUE. The parameter should be declared before the following lines in the config.php file:
    if ( !defined('PATH_APP') )
      return;
  • REQUEST_PARAM_NAME - allows to rename the default LemonStand query parameter. The default parameter name is q. It can interfere with Google Search (if you implement Google site search in your store). To rename the query parameter, declare the REQUEST_PARAM_NAME option in the config.php file and assign a new query parameter value, for example:
    $CONFIG['REQUEST_PARAM_NAME'] = 'lsq';
    After that replace all occurrences of the q= string in the .htaccess file with lsq=

eCommerce settings

  • CATALOG_RULES_PROCESS_BATCH_SIZE - number of products to process in each HTTP subrequest during the Apply Catalog Price Rules operation. The default value is 50. Greater numbers mean more memory required for each request.
  • NESTED_CATEGORY_URLS - determines whether the nested category URLs support is enabled. Defaults to false. When the feature is enabled, you can use category URLs like "men/jumpers". Please note that this feature requires a minor update of the category pagination code, described in this article. This parameter is obsolete since Shop module version 1.17.0.  You can enable category nesting on System/Settings/eCommerce Settings page.
  • DISABLE_GROUPED_PRODUCTS - disables the Grouped Products feature. The default parameter value is TRUE (grouped products are disabled) in new LemonStand instsallations  since July 10, 2012 in favor of the Option Matrix feature. The parameter hides grouped products user interface elements in the Administration Area.
  • CACHE_SHIPPING_METHODS - The parameter enables the shipping options caching in cases when the cart contents and shipping address have not been changed. It increases the store performance by removing unnecessary HTTP requests to shipping providers from the checkout processing. The default parameter value is TRUE in LemonStand copies installed after April 04 2013. The value is FALSE in installations created before this date.
  • DISABLE_ATTR_CONDITIONS - allows to disable the product attribute (ATTR) discount conditions. Default value is FALSE (enabled). 
  • LOWERCASE_ORDER_ITEM_OPTIONS - determines whether option values should be displayed in the lower case in the order item list. The default value is TRUE (lower case).
  • OM_SALE_PRICE_FALLBACK - determines if the Option Matrix record should use the product sale price if the record doesn't have it's own price. The default value is FALSE (do not fallback).

Error handling

  • ERROR_IGNORE - allows to specify a list of exception classes which should be ignored in the error log. The value should be an array of strings (exception class names).
  • HIDE_ERROR_DETAILS - allows to disable the default detailed error page. Default value is FALSE. Read more.
  • LOG_TO_DB - determines whether error messages should be saved to the database. Default value is FALSE.
  • ENABLE_ERROR_STRING - determines whether encrypted error details string should be added to the text error log. Default value is TRUE. You can decode error strings on the System/Settings/View error log/Decoder page.
  • DISPLAY_ERROR_LOG_ID - determines whether error log record identifier should be visible on the default error page. Default value is FALSE.
  • DISPLAY_ERROR_LOG_STRING - determines whether encrypted error details string should be visible on the default error page. Default value is FALSE.
  • ENABLE_DB_ERROR_DETAILS - determines whether encrypted error details string should be saved to the database. Default value is TRUE. When this feature is enabled you can see the error details on System/Settings/View error log/Error Preview page.
  • ERROR_LOG_TTL - determines how many days the error details should remain in the database. The value should be an integer greater than 0, set it to FALSE to never delete error log records from the database. Default value is 14.

Other settings

  • TIMEZONE - specifies the time zone to use for displaying date/time values. You can find a list of supported time zones on this page: http://php.net/manual/en/timezones.php
  • URL_SEPARATOR - allows to set a default URL separator symbol. Read more. Default is - (dash).
  • CACHING - allows to configure the built-in caching system. Please read the Caching Pages and Partials and Caching API articles for details.
  • DISABLE_USAGE_STATISTICS - disables the anonymous usage statistics feature. This feature anonymously sends usage statistics to help us improve LemonStand. Statistics are never tied to your account and are completely anonymous. Default value is FALSE. 
  • ENABLE_DEVELOPER_TOOLS - enables some development features. At the moment it includes only the core:onBeforeDatabaseQuery and core:onAfterDatabaseQuery events. Default value is FALSE.
  • DISABLE_MODULES - allows to disable LemonStand modules. The parameter should be declared before the following lines in the config.php file:
    if ( !defined('PATH_APP') )
      return;
    The parameter value should be an array of module identifiers, in lower case. If a module identifier is listed in the DISABLE_MODULE parameter, LemonStand completely ignores the module. This includes any event handlers declared in the module, module classes and any Administration Area extensions. Please note, that disabling a module can break existing front-end pages if they refer to classes defined in the disabled module. Example:  
    $CONFIG['DISABLE_MODULES'] = array('mymodule');
  • TEMPLATE_PATH - allows to specify a path to templates directory for file-based templates feature.
  • TINYMCE_ENTITY_ENCODING - this option controls how entities/characters get processed by TinyMCE. Default value is "named". See TinyMCE documentation for details.
  • RESOURCE_SYMLINKS - if CSS files are stored in a symlink-ed directory, provide an array of link paths to target paths, where the link paths are within the document root. Because paths need to be normalized for this to work, use "//" to substitute the doc root in the link paths (the array keys). Example:
    $CONFIG['RESOURCE_SYMLINKS'] = array(
      '//themes'=>'/home/web/sites/mystore/repos/themes'
    );
  • DISABLE_CSV_CURRENCY_FORMATTING - disables currency formatting in the exported CSV files (reports and lists).
  • GRID_MAX_ROW_NUMBER - sets the maximum number of rows the grid editor on the Edit Table Rate Shipping Option and Edit Tax pages can handle. If the number of rows in the grid exceeds the specified value, the system hides the grid editor, but you still can manage the grid contents with the CSV operations and external applications (Excel, Open Office, etc). The default value is 300.

Next: Moving LemonStand installation to another server
Previous: Using the Maintenance Mode
Return to Installation, Configuration and Maintenance