[
https://issues.apache.org/jira/browse/JSPWIKI-662?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12912616#action_12912616
]
Dirk Frederickx commented on JSPWIKI-662:
-----------------------------------------
Harry,
The proposed, simplified, calculation of the BasePath assumes you always take
the part of the href, after the third "/"
I wonder if the url-scheme's supported by JSPWiki are not allowing more
flexibility.
The algorithm we are currently using is based on the BaseUrl, set by the
jspwiki engine.
= = = =
@Christian,
I tested the current javascript on FF 3.6.4, which is working properly.
The BaseUrl normally contains also the port number, in which case the
javascript is working perfectly.
Plse check the value of the <meta name="wikiBaseUrl" content=' ... ' /> which
should containt the portnumber.
dirk
> JavaScript disabled in Firefox when BaseURL contains port number
> ----------------------------------------------------------------
>
> Key: JSPWIKI-662
> URL: https://issues.apache.org/jira/browse/JSPWIKI-662
> Project: JSPWiki
> Issue Type: Bug
> Components: Core & storage
> Affects Versions: 2.8.3
> Environment: Windows XP, Tomcat 6, Firefox 3.6
> Reporter: Christian Lerch
> Priority: Minor
>
> I think I've found a little bug in JSPWiki v2.8.3 which, interestingly
> enough, prevents Firefox 3.6 from running any JavaScript at all (it falls
> back into the <noscript> trap), when you use a BaseURL with a port number.
> IE8 on the other hand can't see any problems.
> The bug is in file jspwiki-commons.js near line 235 inside the anonymous
> onPageLoad function:
> ...
> /** 100 Wiki functions **/
> var Wiki = {
> onPageLoad: function(){
> ...
> Somewhere in there you try to figure out the BasePath from the BaseUrl by
> doing this:
> ...
> var h = location.hostname;
> this.BasePath = this.BaseUrl.slice(this.BaseUrl.indexOf(h)+h.length,-1);
> ...
> Which clearly will fail when you happen to have a BaseUrl with a port number.
> I've replaced these 2 lines by
> ...
> var href = location.href;
> this.BasePath = "/" + href.split("/")[3];
> ...
> which seems to work fine in all of my configurations.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.