Opened 15 years ago

Closed 15 years ago

#1199 closed Bug (fixed)

web interface index.html fails to load css/javascript

Reported by: journey4712 Owned by: Gimp
Priority: Normal Milestone: 1.33
Component: Web Client Version: 1.32
Severity: Normal Keywords:
Cc:

Description

Device: Popcorn A-100 Firmware: 00-17-080730-15-POP-402

Cross compiled transmission 1.32 for mipsel-linux-uclibc. After install when loading http://remotedevice:9091/transmission/web/ from my PC the page fails to load all javascript/css

Firebug in firefox reports that they all returned 404 errors

As a hack, i was able to change all css/js links from ./ to /transmission/web/ in index.html and transmission webui now works properly.

Change History (7)

comment:1 Changed 15 years ago by journey4712

To follow up on this, the behavior can be reproduced with:

http://remotedevice:9091/transmission/web

The proper behavior is shown with

http://remotedevice:9091/transmission/web/

By default if you go to http://remotedevice:9091/ you get redirected to the first instance(broken) as oposed to the second(works)

journey

comment:3 Changed 15 years ago by journey4712

Retried with todays svn, the http://remotedevice:9091/ now redirects with the trailing slash, so in general this works. Manualy going to the page without a trailing slash still doesn't work. On IRC was mentioned that safari and FF 3.0.1 on mac add a trailing slash if you dont provide it. Tested FF 2.0.0.14 and FF 3.0.1 on windows XP SP2, FF 3.0.1 and Konquror 4.0.3 on linux(ubuntu hardy) all failed to add a trailing slash.

comment:4 Changed 15 years ago by journey4712

Adding the tag <base href="http://remotedevice:9091/transmission/web/" /> to the head of index.html is another method of resolving this problem. Unfortunatly this cannot be relative, it must be full including the hostname and port. A possible solution is the use a bit of client javascript to write the proper base tag.

comment:5 Changed 15 years ago by journey4712

The following javascript in index.html, inside <head> produces proper behavior. Not sure how quality it is of a fix though.

<script type="text/javascript">document.write('<base href="http://' + document.location.host + '/transmission/web/" />');</script>

comment:6 Changed 15 years ago by jinzo

FF 2.0.0.16 and Opera 9.51 on gentoo both add a trailing slash when I try it. ( Transmission latest SVN )

comment:7 Changed 15 years ago by charles

  • Milestone changed from None Set to 1.33
  • Resolution set to fixed
  • Status changed from new to closed

The slash/noslash bug was fixed in r6533.

Note: See TracTickets for help on using tickets.