webmcp

diff doc/apache.sample.conf @ 0:9fdfb27f8e67

Version 1.0.0
author jbe/bsw
date Sun Oct 25 12:00:00 2009 +0100 (2009-10-25)
parents
children 075ab292653d
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/doc/apache.sample.conf	Sun Oct 25 12:00:00 2009 +0100
     1.3 @@ -0,0 +1,37 @@
     1.4 +# Apache modules cgi_module, env, rewrite and alias must be loaded before
     1.5 +# Take a look in your main apache configuration!
     1.6 +
     1.7 +RewriteEngine on
     1.8 +# do not rewrite static URLs
     1.9 +RewriteRule ^/webmcp-demo/static/(.*)$ /webmcp-demo/static/$1
    1.10 +# base URL
    1.11 +RewriteRule ^/webmcp-demo/(\?(.*))?$ /webmcp-demo/webmcp-wrapper.lua?_webmcp_urldepth=0&_webmcp_module=index&_webmcp_view=index&$2
    1.12 +# module base URLs
    1.13 +RewriteRule ^/webmcp-demo/([^/\?]+)/(\?(.*))?$ /webmcp-demo/webmcp-wrapper.lua?_webmcp_urldepth=1&_webmcp_module=$1&_webmcp_view=index&$3
    1.14 +# actions
    1.15 +RewriteRule ^/webmcp-demo/([^/\?]+)/([^/\.\?]+)(\?(.*))?$ /webmcp-demo/webmcp-wrapper.lua?_webmcp_urldepth=1&_webmcp_module=$1&_webmcp_action=$2&$4
    1.16 +# views without numeric id or string ident
    1.17 +RewriteRule ^/webmcp-demo/([^/\?]+)/([^/\.\?]+)\.([^/\?]+)(\?(.*))?$ "/webmcp-demo/webmcp-wrapper.lua?_webmcp_urldepth=1&_webmcp_module=$1&_webmcp_view=$2&_webmcp_suffix=$3&$5
    1.18 +# views with numeric id or string ident
    1.19 +RewriteRule ^/webmcp-demo/([^/\?]+)/([^/\?]+)/([^/\.\?]+)\.([^/\?]+)(\?(.*))?$ /webmcp-demo/webmcp-wrapper.lua?_webmcp_urldepth=2&_webmcp_module=$1&_webmcp_view=$2&_webmcp_id=$3&_webmcp_suffix=$4&$6
    1.20 +
    1.21 +# Directly serve static files
    1.22 +Alias /webmcp-demo/static /__INSERT_LOCAL_FILE_PATH_TO_DEMO_APPLICATION_HERE__/static
    1.23 +
    1.24 +# Connect extarnal path to the webmcp cgi interface
    1.25 +ScriptAlias /webmcp-demo/ /__INSERT_LOCAL_FILE_PATH_TO_WEBMCP_FRAMEWORK_HERE__/cgi-bin/
    1.26 +
    1.27 +# Allow CGI execution for the webmcp CGI interface
    1.28 +<Directory "/__INSERT_LOCAL_FILE_PATH_TO_WEBMCP_FRAMEWORK_HERE__/cgi-bin">
    1.29 +    AllowOverride None
    1.30 +    Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
    1.31 +    Order allow,deny
    1.32 +    Allow from all
    1.33 +</Directory>
    1.34 +
    1.35 +# Configure environment for demo application    
    1.36 +<Location /webmcp-demo>
    1.37 +    SetEnv WEBMCP_APP_BASEPATH '/__INSERT_LOCAL_FILE_PATH_TO_DEMO_APPLICATION_HERE__'
    1.38 +    SetEnv WEBMCP_CONFIG_NAME 'demo'
    1.39 +</Location>
    1.40 +

Impressum / About Us