hi all,
i searched the forums for an solution of the following problem, but i couldn't find one:
i have s9y 1.1 installed (in the root directory) and url rewriting was automatically disabled (i guess my server doesn't support it). i am also using the staticpage-plugin.
what i would like to do is: redirecting from a directory to a static page, for example:
www.mypage.com/test
should be automatically redirected to
www.mypage.com/index.php?/test.html
what i already did is:
- creating the directory called "test"
- creating a index.html, which i put in this directory
then i tried the meta- and the javascript-redirection, but both redirects delivered the startpage of s9y instead of the page mentioned above.
i read in the forums that there is also the possiblity of redirecting with htaccess-files, but this seems to be a bit difficult and i am not sure if it would solve my problem.
does anybody know what could help?
redirect from directory to static page
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: redirect from directory to static page
Hi!
How does your .htaccess file currently look like?
If "index.html" should be opened when you call "/test" you must make sure that DirectoryIndex "index.html" is set in a .htaccess of the 'test' subdirectory.
HTH,
Garvin
How does your .htaccess file currently look like?
If "index.html" should be opened when you call "/test" you must make sure that DirectoryIndex "index.html" is set in a .htaccess of the 'test' subdirectory.
HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
hi garvin,
that is what my htaccess in the root directory looks like at the moment:
# BEGIN s9y
DirectoryIndex /index.php
<Files *.tpl.php>
deny from all
</Files>
<Files *.tpl>
deny from all
</Files>
<Files *.sql>
deny from all
</Files>
<Files *.inc.php>
deny from all
</Files>
<Files *.db>
deny from all
</Files>
# END s9y
what i did now is to create a separate htaccess-file, that looks like this:
# BEGIN s9y
DirectoryIndex /index.html
# END s9y
i put that file in the test-directory, but when i want to open that directory now, an error occurs "access denied"...
that is what my htaccess in the root directory looks like at the moment:
# BEGIN s9y
DirectoryIndex /index.php
<Files *.tpl.php>
deny from all
</Files>
<Files *.tpl>
deny from all
</Files>
<Files *.sql>
deny from all
</Files>
<Files *.inc.php>
deny from all
</Files>
<Files *.db>
deny from all
</Files>
# END s9y
what i did now is to create a separate htaccess-file, that looks like this:
# BEGIN s9y
DirectoryIndex /index.html
# END s9y
i put that file in the test-directory, but when i want to open that directory now, an error occurs "access denied"...
-
garvinhicking
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Hi!
Use
DirectoryIndex index.html
so, remove that leading "/" in the subfolder's .htaccess.
HTH,
Garvin
Use
DirectoryIndex index.html
so, remove that leading "/" in the subfolder's .htaccess.
HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/