[mimp] Duplicate paths in Login and Delete URLs

Alex Kuretz akuretz at 3dstickfight.com
Fri Sep 1 12:53:33 PDT 2006


I think I found something, may be just an issue with the way my server (Dreamhost) works. I found that the Delete url gets constructed differently than the rest of the links in the Menu section; it's created by Util::addParameter which uses Horde::selfUrl.

In Horde::selfUrl, the first check is if the script is running as CGI (I had to recompile php to use Imp on Dreamhost, so it's executing as CGI). The problem occurs when the url is constructed with the script parameters:
        if ($script_params) {
            if (!empty($_SERVER['PATH_INFO'])) {
                if($_SERVER['PATH_INFO'] == $_SERVER['PHP_SELF'])
                {
//              print "<br><br>Blah!<br><br>\n";
                } else {
                $url .= $_SERVER['PATH_INFO'];
                }
            }
            if (!empty($_SERVER['QUERY_STRING'])) {
                $url .= '?' . $_SERVER['QUERY_STRING'];
            }
        }

I added the if check for PATH_INFO == PHP_SELF. Basically, the /horde/mimp/message.php (PATH_INFO) was getting appended to $url which already was set to /horde/mimp/message.php (PHP_SELF). My silly fix seems to work for the few cases I tried, and Imp seems to still function ok. Again, not fully tested.

I'm guessing this is an issue due to the way my server is working, or else I'm fixing something that's not really a bug, but is shown due to a problem elsewhere.

Any input would be appreciated!
Thanks,
Alex

On Fri, 1 Sep 2006 8:45:31 -0700, Alex Kuretz <akuretz at 3dstickfight.com> wrote:
> Well, I'm also seeing this in IMP now, after being prompted to perform
> maintenance:
> http://www.server.com/horde/imp/redirect.php/horde/imp/redirect.php?nocache=6de35ay90a68&maintenance_done=1&domaintenance=1
> 
> Any ideas? I'll try manually defining the webroot setting again, see if
> that makes a difference.
> 
> Thanks,
> Alex
> 
> On Thu, 24 Aug 2006 13:08:53 +0200, Jan Schneider <jan at horde.org> wrote:
>> Zitat von Alex Kuretz <akuretz at 3dstickfight.com>:
>>
>>> Hello,
>>>
>>> I'm new to Horde/Imp/Mimp, but have them all mostly working quite
>>> well on my server. Thanks to all the developers that put their time
>>> into this product, I'm enjoying it so far.
>>>
>>> The issue I'm seeing, is that duplicate paths appear when I log into
>>> Mimp and when I delete a message,  resulting in 404 errors. The URL
>>> looks like this:
>>>
>>
> http://www.server.com/horde/index.php?url=http%3A%2F%2Fwww.server.com%2Fhorde%2Fmimp%2Findex.php%2Fhorde%2Fmimp%2Findex.php%3Fnocache%3D5310v7zf1jsw
>>>
>>> Notice the
>>> "?url=http://www.server.com/horde/mimp/index.php/horde/mimp/index.php"
>>> redundant path? I only see this when initially logging in, and when
>>> deleting (or undeleting) messages. I am able to view, reply, and
>>> compose messages successfully. I see this behavior both in IE and on
>>> my Motorola e816 phone running the Novarra browser.
>>
>> Make sure that the webroot setting in config/registry.php is correct.
>> Try setting it to a fixed value.
>>
>> Jan.
>>
>> --
>> Do you need professional PHP or Horde consulting?
>> http://horde.org/consulting/
>>
>> --
>> mimp mailing list - Join the hunt: http://horde.org/bounties/#mimp
>> Frequently Asked Questions: http://horde.org/faq/
>> To unsubscribe, mail: mimp-unsubscribe at lists.horde.org



More information about the mimp mailing list