Project

General

Profile

Bug #11138

Widget gallery: images and icons are not loaded (404) when not deployed at the servlet container's root

Added by Roel Standaert about 2 months ago. Updated about 1 month ago.

Status:
Resolved
Priority:
Normal
Category:
-
Target version:
Start date:
12/07/2022
Due date:
% Done:

100%

Estimated time:

Description

If the context path is anything other than empty (e.g. the default /jwt-gallery if you add jwt-gallery.war to the webapps folder in Tomcat), then the (J)Wt logo and any other images result in a 404.

This is because the template text uses <img src="/pics/..."> and <img src="/icons/...">, while the files can actually be found at <img src="CONTEXTPATH/pics/...> and <img src="CONTEXTPATH/icons/...>.

Note that simply writing it as <img src="pics/..."> or <img src="icons/..."> does not work because of internal paths. The desired location should pass through WApplication#resolveRelativeUrl().

#1

Updated by Roel Standaert about 2 months ago

  • Status changed from InProgress to Review
  • Assignee changed from Roel Standaert to Korneel Dumon
#2

Updated by Roel Standaert about 1 month ago

  • Assignee changed from Korneel Dumon to Roel Standaert
#3

Updated by Roel Standaert about 1 month ago

  • Status changed from Review to Resolved
#4

Updated by Roel Standaert about 1 month ago

  • % Done changed from 0 to 100

Also available in: Atom PDF