← Back to team overview

mahara-contributors team mailing list archive

[Bug 1599404] [NEW] The function "get_mahara_install_subdirectory" doesn't correctly handle a URL with a missing trailing slash

 

Public bug reported:

One of the causes of Bug 1592236 was that
get_mahara_install_subdirectory() doesn't correctly handle a wwwroot
with a missing trailing slash. If you set your wwwroot to e.g.
"http://www.example.com";, it will return "www.example.com".

This rarely affects anything because fairly early in init.php we rectify
$CFG->wwwroot to add the missing trailing slash if it's missing. But if
we need to call it before that point it can cause subtle problems, so we
may as well fix it.

** Affects: mahara
     Importance: Undecided
         Status: New

** Description changed:

  One of the causes of Bug 1592236 was that
  get_mahara_install_subdirectory() doesn't correctly handle a wwwroot
  with a missing trailing slash. If you set your wwwroot to e.g.
  "http://www.example.com";, it will return "www.example.com".
  
  This rarely affects anything because fairly early in init.php we rectify
  $CFG->wwwroot to add the missing trailing slash if it's missing. But if
- we need to call it before that point it can cause problems, so we may as
- well fix it.
+ we need to call it before that point it can cause subtle problems, so we
+ may as well fix it.

-- 
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Matching subscriptions: Subscription for all Mahara Contributors -- please ask on #mahara-dev or mahara.org forum before editing or unsubscribing it!
https://bugs.launchpad.net/bugs/1599404

Title:
  The function "get_mahara_install_subdirectory" doesn't correctly
  handle a URL with a missing trailing slash

Status in Mahara:
  New

Bug description:
  One of the causes of Bug 1592236 was that
  get_mahara_install_subdirectory() doesn't correctly handle a wwwroot
  with a missing trailing slash. If you set your wwwroot to e.g.
  "http://www.example.com";, it will return "www.example.com".

  This rarely affects anything because fairly early in init.php we
  rectify $CFG->wwwroot to add the missing trailing slash if it's
  missing. But if we need to call it before that point it can cause
  subtle problems, so we may as well fix it.

To manage notifications about this bug go to:
https://bugs.launchpad.net/mahara/+bug/1599404/+subscriptions


Follow ups