URL in comments are generated incorrectly for domains with drupal installed at a subdir

dwarner - March 28, 2008 - 17:45
Project:Spam
Version:5.x-3.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

Including $base_url in the generated url in the emails doesn't work since Drupal's url() function will add in the subdirectory drupal is installed in, so you get the subdirectory twice, like so:

http://www.mozdev.org/drupal/drupal/comment/edit/40
$base_url ---^^--- url()

Where it should be:
http://www.mozdev.org/drupal/comment/edit/40

AttachmentSize
spam-5.x-1.1-2-url.patch3.84 KB

#1

dwarner - March 28, 2008 - 17:47

Non-monospace text screwed up my explanation of what was $base_url and what was url();

For this URL: http://www.mozdev.org/drupal/drupal/comment/edit/40
$base_url = http://www.mozdev.org/drupal
url('comment/edit/40') = /drupal/comment/edit/40

#2

Jeremy - April 24, 2008 - 13:19
Version:5.x-1.1-2» 5.x-3.x-dev
Status:active» needs review

I'll review this fix for the 3.x development branch.

#3

Jeremy - September 17, 2008 - 14:56
Status:needs review» fixed

Bug not applicable to 3.x version of the spam module, closing.

#4

Anonymous (not verified) - October 1, 2008 - 15:12
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.