Restricting access to URL's and Redirect to other URL
Moderators: Tyler, Scott, PWB v2 Moderator
Restricting access to URL's and Redirect to other URL
Can I restrict users from accessing particular URL's and redirect them to another URL instead?
Thanks,
Michael
Thanks,
Michael
-
- Contributor
- Posts: 31
- Joined: Fri Jan 28, 2011 9:23 am
Hi, I am in a bind and need a redirect. We set up are apached config to redirect on the website for a certain link but on the kiosk we want it to hit a different link. Long story short we are using different skins for our opac. Can you help me with this it looks like you had a possible fix for this. I need it to redirect a folder request or a specific link to another specific link.
Thanks in advance for looking into this
Phil
Thanks in advance for looking into this
Phil
This is a pretty old post from 2003.
In 2004 we added [Dialogs] AccessURLRedirect= in PWB v2.05 which redirects to the specified URL when a URL is denied.
This may fit your needs.
To have PWB redirect to a specific URL for a specific URL could be added, but this will require maintaining a separate list of paired URLs.
--Scott
In 2004 we added [Dialogs] AccessURLRedirect= in PWB v2.05 which redirects to the specified URL when a URL is denied.
This may fit your needs.
To have PWB redirect to a specific URL for a specific URL could be added, but this will require maintaining a separate list of paired URLs.
--Scott
-
- Contributor
- Posts: 31
- Joined: Fri Jan 28, 2011 9:23 am
How would I go by doing to paired list. For example I wanted to send someone from a our homepage http://www.ualibrary.org/index.php to our catalog http://vtls.ualibrary.org/cgi-bin/gw/ch ... arch=kiosk. Is this possible and if so then how?
-
- Contributor
- Posts: 31
- Joined: Fri Jan 28, 2011 9:23 am
No it I have a custom local web page for the home page for pwb. I then open the catalog in a iframe. And I need that I frame not to go to get redirected if it opens a epecific url. The actual url is http://vtls.ualibrary.org/cgi-bin/gw/ that I do not want it to go to. I would like it get redirected to http://vtls.ualibrary.org/cgi-bin/gw/ch ... =SEARCHSCR.
PWB v2.11.2 (02-01-2011) has the following functionality added.
[Files] CheckURLRedirectFile= Tab delimited list of paired URL -> redirect URL.
[Security] CheckURLRedirect=False Enable URL redirects (uses [Files]CheckURLRedirectFile=).
This allows for a paired list of URLs to redirect.
You will need to download this new version of PWB, copy it over your old version of PWB v2.11.x, and add the following to your current INI file.
In URLDirect.txt add the following.
Please note the URLs are on one line separated by a tab.
--Scott
[Files] CheckURLRedirectFile= Tab delimited list of paired URL -> redirect URL.
[Security] CheckURLRedirect=False Enable URL redirects (uses [Files]CheckURLRedirectFile=).
This allows for a paired list of URLs to redirect.
You will need to download this new version of PWB, copy it over your old version of PWB v2.11.x, and add the following to your current INI file.
Code: Select all
[Files]
CheckURLRedirectFile=C:\path to file\URLDirect.txt
[Security]
CheckURLRedirect=True
Code: Select all
http://vtls.ualibrary.org/cgi-bin/gw/ http://vtls.ualibrary.org/cgi-bin/gw/chameleon?skin=kiosk&search=SCAN&function=SEARCHSCR&SourceScreen=SEARCHSCR
--Scott
-
- Contributor
- Posts: 31
- Joined: Fri Jan 28, 2011 9:23 am
What PWB is doing is watching for the URL in the OnBeforeNavigate function and changing the URL if a match is found before navigating to the URL. It is not touching the HOSTS file.
Check you are using PWB v2.11.2 (02-01-2010) by viewing the Help About dialog. (Yes we need to update it to 2011 )
Did you enable it by adding the following to your INI file?
[Security]
CheckURLRedirect=True
Did you create a file with paired URLs separated by a single tab that is specified in the following?
[Files]
CheckURLRedirectFile=C:\path to file\URLDirect.txt
Please send a copy of your "CheckURLRedirectFile" file as an attachment to support@teamsoftwaresolutions.com and we can take a look at it.
--Scott
Check you are using PWB v2.11.2 (02-01-2010) by viewing the Help About dialog. (Yes we need to update it to 2011 )
Did you enable it by adding the following to your INI file?
[Security]
CheckURLRedirect=True
Did you create a file with paired URLs separated by a single tab that is specified in the following?
[Files]
CheckURLRedirectFile=C:\path to file\URLDirect.txt
Please send a copy of your "CheckURLRedirectFile" file as an attachment to support@teamsoftwaresolutions.com and we can take a look at it.
--Scott
-
- Contributor
- Posts: 31
- Joined: Fri Jan 28, 2011 9:23 am
That would be a problem, however the URL redirect filter uses Regular Expressions. So you can use the begins with ("^") and ends with ("$") characters to match the whole URL only.
Example:
This will match the URL is it both begins with itself and ends with itself.
We posted a new version that corrects a problem if you have cache filter files set to true, which you should to prevent many disk reads.
--Scott
Example:
Code: Select all
^http://vtls.ualibrary.org/cgi-bin/gw/$ http://vtls.ualibrary.org/cgi-bin/gw/chameleon?skin=kiosk&search=SCAN&function=SEARCHSCR&SourceScreen=SEARCHSCR
We posted a new version that corrects a problem if you have cache filter files set to true, which you should to prevent many disk reads.
--Scott
-
- Contributor
- Posts: 31
- Joined: Fri Jan 28, 2011 9:23 am