Forum

Elgg UrlToolkit config

Stuart Naylor
9 January 2016, 05:49
Just wondered if anyone has Elgg running under Hiawatha or has a UrlToolkit config of.
<IfModule mod_rewrite.c>

RewriteEngine on

# If Elgg is in a subdirectory on your site, you might need to add a RewriteBase line
# containing the path from your site root to elgg's root. e.g. If your site is
# http://example.com/ and Elgg is in http://example.com/sites/elgg/, you might need
#
#RewriteBase /sites/elgg/
#
# here, only without the # in front.
#
# If you're not running Elgg in a subdirectory on your site, but still getting lots
# of 404 errors beyond the front page, you could instead try:
#
#RewriteBase /


# If your users receive the message "Sorry, logging in from a different domain is not permitted"
# you must make sure your login form is served from the same hostname as your site pages.
# See http://learn.elgg.org/en/stable/appendix/faqs/general.html#login-token-mismatch for more info.
#
# If you must add RewriteRules to change hostname, add them directly below (above all the others)

# hide all dot files/dirs (.git)
RewriteRule (^\.|/\.) - [F]

# Everything else that isn't a file gets routed through Elgg
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?__elgg_uri=$1 [QSA,L]

</IfModule>
Hugo Leisink
9 January 2016, 08:38
UrlToolkit {
ToolkitID = elgg
RequestURI exists Return
Match ^/([^?]*)(\?(.*))? Rewrite /index.php?__elgg_uri=$1&$3
}
Stuart Naylor
11 January 2016, 12:42
Many thanks Hugo will give it a try.
This topic has been closed.