1 March 2005
Getting MT-Mail-Entry 2.0 working in MT 3.1x
Several MT enthusiasts are reporting that Stepan Riha’s MT-Mail-Entry 2.0 throws an error as of MT 3.1 on up;
Can't call method "param" on an undefined value at mt-mail-entry.cgi line 54
Here’s a quick fix.
Short and sweet, this one is (and Yoda I am not by a longshot - ahem). Replace the line that reads:
my $q = $app->{query};
with:
my $q = CGI->new;
It should now work! Since I saw reports of this working pre-3.1, I’m guessing that the 2.6x version of MT provided access to the CGI query via MT::App. If so, that’s either no longer true or perhaps said access has moved elsewhere within MT::App. I didn’t catch any notable clues while debugging the CGI, but no matter - this ought to do the trick. Enjoy …
Or rather, I will enjoy … once I nail down a reasonable game plan to keep it from being flagrantly abused. (If anyone has suggestions, by all means … and yes, I’ve already changed the name of the CGI. Heh-heh.)
Posted by joe at 01:11 AM
Trackback Pings
TrackBack URL for this entry:
http://www.joesapt.net/mt/mt-tb.fcgi/9
Comments
rowan
of Uncommon Thought Journal
writes:
# 1 March 2005, 08:51 AM -05:00
Joe writes:
This just in: While traipsing around lib/MT/App.pm I came across the setup for the CGI query within the App object. It’s there safe ‘n sound. It didn’t go anywhere. In fact, it’s used all over the Comments module, among other places.
Soooo … I’m still not sure why the query winds up being undefined. It looks like it’s being used correctly, but I suppose I’m missing something more subtle here. (This would be a good time for me to take a crash course on writing MT Plugins/CGIs … I was looking for an ideal oppy, and I suppose this must be it!)
Ahh well, all good intentions. Stay tuned …
# 1 March 2005, 06:04 PM -05:00
Joe writes:
[Browsed plugin tutorial, skimmed through APIs.] Well, that was quick. :-)
It turns out that, while a lot of plugins/extensions use App.pm, even MT’s own mt-send-entry.cgi uses (drum roll) … CGI.pm, and by that I mean only CGI.pm - no using the App module at all.
Here’s where it gets interesting. It turns out that App.pm takes some additional things into account, namely whether you use Apache and mod_perl, plus your CGIMaxUpload setting. Using mod_perl in particular means MT would not use CGI.pm to fetch the query. The plot thickens.
# 1 March 2005, 06:42 PM -05:00
Paul
of Speth.tv
writes:
Is there any feedback on this issue? Thanks for the help so far.Failed to send email: Error sending mail: RCPT TO: error (553 sorry, that domain isn’t allowed to be relayed thru this MTA (#5.7.1))
# 15 March 2005, 12:52 PM -05:00
leo prieto
of Leo Prieto is News - Cooking the Internet soup since 1996
writes:
# 31 March 2005, 05:06 PM -05:00
Martin Fuchs
of HASH(0x9b33b70)
writes:
# 13 July 2005, 06:14 PM -05:00
# 8 April 2006, 08:04 AM -05:00
Joe writes:
# 8 April 2006, 08:09 AM -05:00
Amirreza
of دانلود نرم افزارهای جدید
writes:
# 10 April 2006, 12:58 PM -05:00
Joe writes:
# 10 April 2006, 09:10 PM -05:00
# 12 April 2006, 01:32 PM -05:00
Comments are closed for this entry.