Edit...
Someone suggested I do it differently... If I were to use .htaccess, would this work?
Options +FollowSymlinks
RewriteEngine on
RewriteRule ^chapter http://mysite.com/chapter/1
I'm just using basic javascript here, but I wanted to find out if there's a way to add it to my jquery file so that the redirection will happen if the path matches something specific?
Right now, I'm using:
<script type="text/javascript">window.location.replace("/chapter/1");</script>
I'd like that to only occur if the user goes to http://mysite.com/chapter.
I'm not altogether clear on how to get the path using jquery and do a pattern match?