Redirecting (or theme) by domain Redirecting (or theme) by domain
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Redirecting (or theme) by domain

Started by ff, January 08, 2009, 09:32:24 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ff

Maybe I'm thinking about something impossible.

My simplyfied tree:

root
|--- www.ff.fm
||--- www.ff.fm/fotoalbum (symlink to root/fotoalbum)
|
|--- www.ff.fm/hummeltje
||--- www.ff.fm/hummeltje/fotoalbum (symlink to root/fotoalbum)
|
|--- www.xarno.nl
||--- www.xarno.nl/fotoalbum (symlink to root/fotoalbum)
|
|--- fotoalbum (CPG)

www.ff.fm/hummeltje/fotoalbum has to be redirected to www.ff.fm/hummeltje/fotoalbum/index-25.html
www.xarno.nl/fotoalbum has to be redirected to www.xarno.nl/fotoalbum/index-26.html

There are links to these old galleries and I can't edit them all :)

What are my possibilities?
I was fiddling with httpd.conf and .htaccess but didn't get what I wanted.
I'm using the SEF-plugin and thought it could be something like that or would it be possible by creating PHP-rules in the main index?

Greetings Jeroen.

Stramm

That's not an issue this board covers... there are other sites for htaccess realted questíons.

I'd say you'd just need to define another index, eg. for www.xarno.nl/fotoalbum has to be redirected to www.xarno.nl/fotoalbum/index-26.html; place the htaccess in the fotoalbum dir

DirectoryIndex index-26.html index.php index.shtml index.html

or alternatively read more about RewriteCond, RewriteRule, redirectMatch

example:
(the following two solutions may not work as it should lead to an infinite loop (target in the same dir as the condition))
redirectMatch 301 ^/fotoalbum/(.*) http://www.xarno.nl/fotoalbum/index-26.html
but sends a 301 to the browser

Same problem
RewriteEngine on
RewriteCond %{REQUEST_URI} !^/fotoalbum/ [NC]
RewriteRule (.*) http://www.xarno.nl/fotoalbum/index-26.html [L]

ff

Thanks Stramm,

I was hoping there was a MOD like theme by category or a plugin ;)

Back to the manpages it is.

Stramm

If I'm not totally wrong there was at least a discussion about the matter theme by album and/ or category. However I haven't followed it and therefore I even do not remember when that was and if there were code examples or even working code. And it's likely that it was for 1.3x.

ff

Quote from: Stramm on January 09, 2009, 12:52:14 PM
If I'm not totally wrong there was at least a discussion about the matter theme by album and/ or category. However I haven't followed it and therefore I even do not remember when that was and if there were code examples or even working code. And it's likely that it was for 1.3x.

There are 2 MODs for this :)

But I wanted more  ;D