I noticed that the following code is used to get the uri_brief parameter that can be used in the node and comment notification messages:
'!uri_brief' => drupal_substr($base_url, drupal_strlen('http://')),
However, that won't work if $base_url is something like https://www.example.com
The attached (and untested) patch should allow sites using both http and https to have proper uri_brief replacements.
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | 323030_https_compat.patch | 1.37 KB | greggles |
| cn_brief_uri_0.patch | 1.75 KB | aclight |
Comments
Comment #1
gregglesThe way that core does this is
preg_replace('!^https?://!', '', $base_url)http://cvs.drupal.org/viewvc.py/drupal/drupal/modules/user/user.module?r...
What do you think? Do you have a site where you can test this?
Comment #2
gregglesPatch is for 5.x but seems to work for 6.x as well.
Comment #3
aclight commentedI guess core's way of doing this is less code, but functionally the same thing, so maybe it's best to do it that way. I don't actually have comment_notify running on a site yet, so don't have a simple way to test. I just happened to notice this while looking through the code.
Comment #4
gregglesCool - thanks for the review.
I accidentally committed this with another issue so I guess it's fixed.
Comment #5
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.