For more information... RTFM!
NAVIGATION
ACCOUNT LOGIN

You are not logged in

Powered by Interchange version 5.7.0

AliasTable

Specify a table that contains page redirect instructions.

Synopsis

AliasTable  table_name

The parameter is expected to be the name of a table in the website's database.  There is no default value, which means that this facility is disabled by default.

Scope

This directive is only available for use in the local (catalog.cfg) configuration file.  It will not affect any other website in any way.  This directive will not work in the global (interchange.cfg) configuration file. 

Description

This directive specifies the name of a table that contains page redirect instructions.  The table is expected to consist of the following columns:

Name Description
code The requested page.
real_page The page that will be displayed.
base_page The name of an alternate flypage to display when real_page is a sku.
base_control CGI variables to populate in option hash format.

If this directive is enabled, then all page requests will be looked up in the named table's "code" column.  The name of the "code" column is not fixed but can be any name as long as it is set as the primary key.  If a row is found then the page named in the "real_page" column will be used instead of the specified page name.

If the optional "base_page" has a value then the "real_page" will be assumed to be a SKU and the specified "base_page" will be used as a flypage to display the specified product.

If the optional "base_control" column has a value then it should contain a comma-separated list of CGI variable names and values, with each variable name and value pair in a "name=value" format.  This list of variables and values will be passed to the target page as CGI variables.  The specified CGI variable values will be overridden if any CGI variables with the same name are encoded into the original request URI.

Example

The following example makes use of an AliasTable table that has the following values:

code real_page base_page base_control
request1 index  
request2 realpage2  
request3 00-0010 realpage3  
request4 realpage4 foo=bar, kevin=walsh

Using the above data, the following request mapping will occur:

  • A request for "request1.html" would be treated as a request for the "index.html" page.
  • A request for "request2.html" would be treated as a request for the "realpage2.html" page.
  • A request for "request3.html" would cause the page "realpage3.html" to be displayed as a flypage with the sku "00-0010".
  • A request for "request4.html" would be treated as a request for the "realpage4.html" page and also pass the CGI variables "foo=bar" and "kevin=walsh" to the page.
  • A request for "kevin.html" would not be mapped, and would proceed as usual.
Category:  Local config directives
Last modified by: Peter Ajamian
Modification date: Monday 13 October 2008 at 9:36 PM (EDT)
Home  |  Legal nonsense  |  Privacy policy  |  Contact us