Article
A Forum reader recently asked:
"I need help on how to redirect our iChain users, based on their groups, to webpage.html. If the users belong to group1, they go to group1.html, group2 goes to
group2.html, group3 to group3.html, etc. It's all in the same domain but different folders."
And here is the response from Andrey Karyagin ...
Solution
This is possible, if each user is a member of one and only one group. In other words, it is possible if groupMembership attribute contains only one value.
Some time ago, one of my engineers implemented the following configuration to redirect user to desired page, depending on the siteLocation attribute. This configuration consists of index.html, which should be created in the Apache root directory, and iChain Form Fill Policy which should be configured via ConsoleOne. As you can see below, when the sitelocation attribute is empty, the user will be redirected to www.somecompany.ru/nps. But when sitelocation is not empty, the user will be redirected to some other page, such as www.somecompany.ru/merchant
In this case, the sitelocation attribute is filled with merchant. Just replace sitelocation with groupMembership, and you should get the desired result. This configuration works fine with IE6 SP1, FireFox 2.0.0.12, and Netscape 7,8, and 9.
Here's an index.html sample:
<html>
<head>
<meta http-equiv="cache-control" content="no-cache">
<script language="javascript">
function go()
{
var url = document.UrlForm.url.value;
if ( url.length == 0 ) url = "/nps";
self.location.replace ( url );
}
</script>
</head>
<body onLoad="go();">
<form name="UrlForm" method="post" action="dummy">
<input type=hidden name="url">
</form>
</body>
</html>
And here is a Form Fill Policy sample:
<urlPolicy>
<name>HomeUrlFill</name>
<url>www.somecompany.ru/</url>
<formCriteria>
<form name="UrlForm" method="post" action="dummy">
</formCriteria>
<actions>
<fill>
<input name="url" value="~sitelocation">
</fill>
</actions>
</urlPolicy>
Disclaimer: As with everything else at Cool Solutions, this content is definitely not supported by Novell (so don't even think of calling Support if you try something and it blows up).
It was contributed by a community member and is published "as is." It seems to have worked for at least one person, and might work for you. But please be sure to test, test, test before you do anything drastic with it.
Related Articles
User Comments
- Be the first to comment! To leave a comment you need to Login or Register
- 3726 reads


0