Uploaded image for project: 'JSPWiki'
  1. JSPWiki
  2. JSPWIKI-590

way of integrating JavaScript libraries in default template

Bulk Copy AttachmentsBulk Move AttachmentsVotersWatch issueWatchersConvert to sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.8.3
    • 2.8.3
    • Templates and UI
    • None

    Description

      I've just configured JSPWiki to run on a Tomcat 6 behind an Apache 2.2 web server, connected via mod_proxy_ajp.
      The client URL is https://wiki.somewhere.com/ and the real URL on Tomcat is ajp://my.intra.com:8009/my-context-path/

      Everything is running fine, there's just one little problem left:
      On the Edit page, two JavaScript libraries can't be loaded because the browser is searching for them under /my-context-path/scripts/xyz.js instead of /scripts/xyz.js:

      <script type='text/javascript' src='/my-context-path/scripts/jspwiki-edit.js'></script>
      <script type='text/javascript' src='/my-context-path/scripts/posteditor.js'></script>

      This is because of the following lines in templates/default/editors/plain.jsp:

      TemplateManager.addResourceRequest( context, "script", contextPath + "/scripts/jspwiki-edit.js" );
      TemplateManager.addResourceRequest( context, "script", contextPath + "/scripts/posteditor.js" );

      Now I'm not sure whether this is a bug in JSPWiki or I have to configure anything more in Tomcat.
      WDYT?

      Attachments

        1. JSPWIKI-590.patch
          1.0 kB
          Florian Holeczek

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            Unassigned Unassigned
            florianh Florian Holeczek
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment