Portal Engine Questions on portal engine and web parts.
Version 5.x > Portal Engine > redirecting a directory (including its children) View modes: 
User avatar
Member
Member
cperras-uwb - 7/15/2010 1:19:08 PM
   
redirecting a directory (including its children)
Hi - I'm trying to find a simple way to redirect a page, including all its children. For example, say I have /mydir/foo, /mydir/bar. Now I want to move /mydir to /newdir, then set up a permanent redirect so /mydir will redirect to /newdir. Then if a user requests /mydir/bar, he'll go to /newdir/bar.

Any suggestions are appreciated!


User avatar
Kentico Support
Kentico Support
kentico_jurajo - 7/20/2010 12:31:49 PM
   
RE:redirecting a directory (including its children)
Hi,

One option is to check the requested URL in ApplicationBeginRequest event in global.asax.cs file and according to appropriate decision statement do the redirection.

Second option is to create a custom web part and place on the page template(s) used on the pages. The job of this web part will be redirection to the page and location you want to.

Third option is to manually set the URL redirection for each document on its Properties tab -> Menu section -> URL redirection field (or you can do it in the DB as well).

Best regards,
Juraj Ondrus