Skip to content

config staticfilepath

Violet edited this page Nov 2, 2010 · 2 revisions

StaticFilePath

The absolute file system path to the mt-static directory.

This value corresponds to the absolute URL path or fully-qualified domain name URL specified in StaticWebPath.

Tip: If not configured, it is assumed that the mt-static directory is located in the application directory. Thus the StaticFilePath directive is only required if the mt-static directory has been moved out of the Melody application directory.

Values

Filesystem path. Default is to assume that filepath is the value of CGIPath + "mt-static/"

Example

If the application directory is located at:

URL:        http://example.com/cgi-bin/mt/
Filepath:   /var/www/cgi-bin/mt/

...and static files cannot be served from the cgi-bin directory, then you have two choices:

  1. Alias http://example.com/mt-static/ to /var/www/cgi-bin/mt/mt-static/ via symlink, Apache alias, etc.

    Because the mt-static directory is still in the application directory there is no need to use the StaticFilePath config directive. The config.cgi file would look like this:

     CGIPath         http://example.com/cgi-bin/mt/
     StaticWebPath   http://example.com/mt-static/
    
  2. Move the mt-static directory to the web root directory:

     /var/www/html/mt-static/
    

    and then set the StaticFilePath config directive to this location:

     StaticFilePath /var/www/html/mt-static/
    

    The following three path settings would then be in the config.cgi file:

     CGIPath         http://example.com/cgi-bin/mt/
     StaticWebPath   http://example.com/mt-static/
     StaticFilePath  /var/www/html/mt-static/
    

Related

  • CGIPath

  • StaticWebPath

  • Categories: Appendix: Configuration Directives

  • Tags: config, file, mt-static, New in MT4, static files

Clone this wiki locally