alert(this.location.pathname.match(/(?!.*[\/\\])[^\.\?\#]*/));//取得index
alert(this.location.pathname.match(/(?!.*[\/\\])[^\?\#]*/));//取得index.asp
<script type="text/javascript" id="wumiiRelatedItems"> </script>
alert(this.location.pathname.match(/(?!.*[\/\\])[^\.\?\#]*/));//取得index
alert(this.location.pathname.match(/(?!.*[\/\\])[^\?\#]*/));//取得index.asp