[Typo3] direct mail fetch and compile URL missing top level domain

Eric Blom ericb at piap.com
Sat Nov 5 19:42:29 CET 2005


After looking into this problem some more it seems to me that line  
257 of class.mod_web_dmail.php has some problems with math. This is  
the line of code:
$this->urlbase = substr(t3lib_div::getIndpEnv("TYPO3_REQUEST_DIR"),0,  
(strlen(TYPO3_MOD_PATH)+strlen(TYPO3_mainDir))).'index.php';

In my case the various parts of the line break down into the  
following strings
substr(t3lib_div::getIndpEnv("TYPO3_REQUEST_DIR")
     http://www.psocdeveloper.com/typo3conf/ext/plugin_mgm/modules/

strlen(TYPO3_MOD_PATH)
     ../typo3conf/ext/plugin_mgm/modules/

strlen(TYPO3_mainDir)
     typo3/

It seems to me that strlen(TYPO3_mainDir) is not needed at all and  
that the "../" on strlen(TYPO3_MOD_PATH) is not needed. Now what  
confuses me is how this could work for anyone? Therefore, I figure  
there must be something about my configuration, but, I'm stumped for  
now.

Does anyone on the list have a suggestion for me?

Cheers,
Eric




On Nov 5, 2005, at 9:25 AM, Eric Blom wrote:

> I'm still working on this problem and am wondering if anyone can make
> some debug suggestions. I've never written anything in php so I'm
> wondering what some basic debug techniques. For example, how can you
> "debug by printf" in Typo3?
>
> I'm trying to see what is going on with the following lines of
> class.mod_web_dmail.php to see if this is the source of the shortened
> URL I'm seeing.
>
> switch((string)$row["type"])    {
>                                          case 1:
>                                                  $this->url_html =
> $row["HTMLParams"];
>                                                  $this->url_plain =
> $row["plainParams"];
>                                          break;
>                                          default:
>                                                  $this->url_html =
> $this->urlbase."?id=".$row["page"].$row["HTMLParams"];
>                                                  $this->url_plain =
> $this->urlbase."?id=".$row["page"].$row["plainParams"];
>                                          break;
>                                  }
>
> Thank you,
> Eric
>
>
>
> On Oct 31, 2005, at 9:50 PM, Eric Blom wrote:
>
>
>> I've been trying to get the Web-Plugins Direct Mail plugin working
>> for a while now without success all because of the Fetch and Compile
>> URL -- as far as I can tell.
>>
>> When I try to "Fetch and compile maildata (read url)" the back end
>> page that comes up with the "Read URL" button has the URLs wrong. In
>> my case I was expecting
>>      http://www.psocdeveloper.com/index.php?id=71
>> but I get
>>      http://www.psocdevelindex.php?id=71
>>
>> "oper.com/" is missing!
>>
>> I've been bumbling around trying to find a solution to this problem,
>> but, have yet to find one.
>>
>> Searching the mailing list I haven't seen this problem so I figure it
>> must be something specific to my configuration, but, I don't know
>> where to look. I would appreciate any debugging suggestions the list
>> is willing to give me.
>>
>> The interesting thing to me is that I have another site where the
>> HTTP_HOST variable is returning the IP address of the machine
>> (192.168.2.4) and I can't get direct mail to use any value other than
>> that IP address. In the case I'm asking about here I've checked the
>> HTTP_HOST variable and it is set to www.psocdeveloper.com I can't get
>> direct mail to use the entire value!
>>
>> Thank you,
>> Eric




More information about the TYPO3-english mailing list