Opened 14 years ago

Closed 13 years ago

#1501 closed defect (fixed)

taskframe.php fails to load absolute initial task urls

Reported by: jng Owned by: jng
Priority: high Milestone: 2.2
Component: AJAX Viewer Version: 2.1.0
Severity: blocker Keywords:
Cc: External ID:

Description (last modified by jng)

Create a weblayout with 'http://www.google.com' as the initial task url

This will fail to load initially.

The affected lines are at line 60

$url = sprintf("%s?SESSION=%s&WEBLAYOUT=%s&DWF=%s&LOCALE=%s", $comp["path"], $sessionId, urlencode($webLayoutId), $dwf, $locale);

and line 62

$url = sprintf("%s?SESSION=%s&WEBLAYOUT=%s&DWF=%s&LOCALE=%s&%s", $comp["path"], $sessionId, urlencode($webLayoutId), $dwf, $locale, $comp["query"]);

The problem is parse_url() returning various items depending on whether the input parameter is an absolute or relative url.

For absolute urls, the "path" component of the parse_url result is "/"

The solution is to replace $comppath with an intermediate variable which is set to:

  • Initial task pane url if it is absolute
  • $comppath if it relative

Change History (5)

comment:1 by jng, 14 years ago

Description: modified (diff)

comment:2 by jng, 14 years ago

Owner: set to jng

comment:3 by jng, 13 years ago

Resolution: fixed
Status: newclosed

Fixed in 2.2 (r5345) Fixed in trunk (r5346)

comment:4 by jng, 13 years ago

Resolution: fixed
Status: closedreopened

Re-opening because parse_url() is an annoying API!

comment:5 by jng, 13 years ago

Resolution: fixed
Status: reopenedclosed

Fixed properly in r5349 (2.2) and r5350 (trunk)

Note: See TracTickets for help on using tickets.