Extension talk:EmailPage/Archive

fatal error getID
I installed the extension but when I use it I get
 * Fatal error: Call to a member function getID on a non-object in /home/kickmysi/public_html/techwiki/includes/SkinTemplate.php on line 408


 * To be able to give any advice I need more info such as your EmailArticle configuration settings and MediaWiki version. --Nad 21:21, 27 June 2007 (UTC)


 * I have installed it successfully on MW 1.10.0 without problems. My file structure was:


 * --Zven 21:25, 1 July 2007 (UTC)

Media Wiki Version MediaWiki: 1.10.0 include ("$IP/extensions/EmailArticle/EmailArticle.php"); $wgEmailArticleGroup = "**"; $wgEmailArticleContactsCat = ""; $wgEmailArticleCss = "EmailArticle.css"; $wgEmailArticleAllowRemoteAddr = ""; $wgEmailArticleAllowAllUsers = "false"; $wgEmailArticleToolboxLink = "Send to email"; $wgEmailArticleActionLink = "email"; $wgPhpMailerClass = "";

blank page, no email
I installed extension as well according to all of the instructions outlined and the extension will not send email. It goes to a blank page when I hit submit. Any suggestions email me at drclinks@gmail.com. -Mike


 * Is the normal mediawiki mail functionality is working such as password confirmation or watchlist changes? --Nad 00:29, 6 July 2007 (UTC)


 * peblusto says: this would be a perfect extension ... if i could get it working!  but we also get a blank page when clicking send, and there's no outgoing email, yet other email works from the wiki, including "e-mail user". i also note that this extension only permits building a page send form for users who have confirmed their email address (doh!) otherwise it displays "...permission denied" at the bottom of the form. here's my localsettings.php lines:


 * any clues? has anyone else seen this "blank page, no email send" problem, and resolved it? thanx peblusto 20:25, 19 September 2007 (UTC)


 * There seems to be a bug preventing the pseudo-groups ("*" and "user") from working. I'll try and fix that soon, but in the mean time, you can set the group to "" to allow anyone, or a real group. --Nad 22:13, 19 September 2007 (UTC)


 * peblusto says: thanks, but i'm still getting a blank page and no email, even with "$wgEmailArticleGroup = "";" instead of "*".


 * also, not having had success yet, i'm not absolutely sure how to use the form (see, for example, Special:EmailArticle/Main_Page), under "select recipients" do i have to select a "...group" or can i just type in email addresses under "additional..."?
 * Let me look at my apache server error.log:


 * what are you doing here in emailarticle.php?:


 * should i have a file "phpmailer.php" in any particular directory?
 * also, i'd love some examples of the effect of the variables, for instance, what does


 * mean? thanx peblusto 13:19, 20 September 2007 (UTC)
 * ps - i can mess it up and get a screen full of this as the send results instead of a blank screen - i guess i'll re-download the extension and try again!

and on and on ...

--

ea_autherror
I installed according to instructions, including the phpmailer class. I get an  when trying to send an email with empty string as $wgEmailArticleGroup. Also, how can I add aditional groups to the system to send email only to those people? Manually added groups work for the permissions but not as recipient. Also, the Article title is empty in the form and email ("" article sent from Elixir Wiki) - Oliver


 * I found some minor bugs which should fix those problems, try the new 1.0.3 version --Nad 07:54, 10 July 2007 (UTC)

User and * Groups
Hi - this extension doesn't work for me unless I set $wgEmailArticleGroup to ' ' ; - when I try 'user' or even '*' it says permission denied, though I am logged in as a bureaucrat and sysop. Gary Kirk 14:37, 24 August 2007 (UTC)


 * The "user" and "*" groups are virtual groups and aren't allowed as special-page permissions. The "user" group is allowed to be used for selecting recipients though and will send the article to all registered users. --Nad 11:58, 27 August 2007 (UTC)

MySQL errors in 1.11
Having upgraded to MW 1.11 I tried this extension (which worked fine in 1.10).

I went to: http://mywiki.local/index.php?title=Special:EmailArticle&ea_title=Main%20Page (and other articles as well) and each time was greated with these two error messages:

Warning: mysql_fetch_row: supplied argument is not a valid MySQL result resource in /var/www/mywiki/extensions/EmailArticle/EmailArticle.php on line 120 Warning: mysql_fetch_row: supplied argument is not a valid MySQL result resource in /var/www/mywiki/extensions/EmailArticle/EmailArticle.php on line 159

I echo'd out the select statements that were being sent and saw that it was as follows:

SELECT cl_from FROM `categorylinks` WHERE cl_to = 'Contacts' ORDER BY cl_sortkey SELECT page_id FROM `page` WHERE page_title REGEXP('\.css$') ORDER BY page_title

My PHP version hasn't changed (5.2.0-8), neither has MySQL (5.0.41).

Email sending still works, however.


 * I'm about to do the upgrade to 1.11 on mine too so I'll be able to look in to that soon. --Nad 21:49, 12 September 2007 (UTC)


 * Working fine in MW1.11 now ;-) --Nad 12:14, 14 September 2007 (UTC)

Suggestions
Can this extension be given the option of stripping out the [edit] links that appear in the emails? Unfortunately this makes the extension a little useless for our environment.


 * You can add to the text message part of the form, or you could remove them from the CSS you use --Nad 21:47, 12 September 2007 (UTC)

Error sending (page name): Language string failed to load: instantiate
peblusto says: huh? i'm having fun crashing this and should be a master at it by the time i get it working. i just downloaded the entire big phpmailer suite from http://phpmailer.sourceforge.net/ and replaced the version from http://www.organicdesign.co.nz/Class.phpmailer.php in my C:\www\apache2\htdocs\mediawiki\extensions\EmailArticle\*.* directory (by the way, where should it go and how would i know?).

my apache error.log now says:

so i open EmailArticle.php in free http://www.htmlkit.com/ and read down to the numbered line 256 which says:

i've tried adding these lines into my php.ini:

but now i see there are two php.ini files, one in C:\www\apache2\ and one in C:\www\php5\ ... which one matters? how should i coordinate them to best support mediawiki and this extension, if it matters? I added the "include_path..." and "$mail..." lines the end of both php.ini files, reloaded to send a new page and still get "Language string failed to load: instantiate". here are the two lines in apache error.log when trying to send a page:

maybe i need remedial details on exactly what resources need to be where in the system. thanx peblusto 17:43, 20 September 2007 (UTC)
 * Sorry, the instructions regarding the phpmailer file were incorrect and have been updated, I've added the specific info about this in the following section as well --Nad 04:18, 21 September 2007 (UTC)

PHP Mailer class
The only file this extension needs from phpmailer is the one named class.phpmailer.php, by default this extension expects it to be found in a directory called phpmailer which should be located in the same directory as the EmailArticle.php script is located. If you want to put it in some other location, then specify its full path name in the $wgPhpMailerClass variable in your localsettings after the EmailArticle include statement. There's no need to adjust anything to do with PHP or Apache. --Nad 04:18, 21 September 2007 (UTC)