[plugin: Mail2List] Send mail to your list via email client

3rd party code for phpList

Postby SaWey » 8:51am, Tue 01 May, 2007

Please try this one:

Code: Select all
-- Database: `phplist`
--

-- --------------------------------------------------------

--
-- Tabel structuur voor tabel `phplist_mail2list_allowsend`
--

CREATE TABLE phplist_mail2list_allowsend (
  id int(11) NOT NULL auto_increment,
  email varchar(255) NOT NULL,
  name varchar(255) NOT NULL,
  sent int(50) NOT NULL default '0',
  PRIMARY KEY  (id)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=3 ;


--
-- Tabel structuur voor tabel phplist_mail2list_list
--

CREATE TABLE phplist_mail2list_list (
  listid int(10) NOT NULL,
  toemail varchar(255) NOT NULL,
  template int(10) NOT NULL,
  footer text NOT NULL,
  PRIMARY KEY  (listid)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;


--
-- Tabel structuur voor tabel phplist_mail2list_popaccounts
--

CREATE TABLE phplist_mail2list_popaccounts (
  listid int(10) NOT NULL,
  host varchar(255) NOT NULL,
  port varchar(255) NOT NULL,
  login varchar(50) NOT NULL,
  pass varchar(50) NOT NULL,
  mail_status varchar(10) NOT NULL default '0/0',
  queue varchar(3) NOT NULL default 'yes',
  del_message varchar(3) NOT NULL default 'yes',
  PRIMARY KEY  (listid)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;



In this version the quotes are gone.
I use MySQL v5.x, maybe that is the problem.
SaWey
PL Master
 
Posts: 192
Joined: 8:28pm, Wed 08 Mar, 2006
Location: Belgium

Postby blair.sawler » 10:42am, Tue 01 May, 2007

I appreciate your help by the way! Another error:

Error
SQL query:

-- Database: `phplist`
--
-- --------------------------------------------------------
--
-- Tabel structuur voor tabel `phplist_mail2list_allowsend`
--
CREATE TABLE phplist_mail2list_allowsend(

id int( 11 ) NOT NULL AUTO_INCREMENT ,
email varchar( 255 ) NOT NULL ,
name varchar( 255 ) NOT NULL ,
sent int( 50 ) NOT NULL default '0',
PRIMARY KEY ( id )
) ENGINE = InnoDB DEFAULT CHARSET = latin1 AUTO_INCREMENT =3;



MySQL said:

#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=3' at line
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Postby SaWey » 11:03am, Tue 01 May, 2007

Does your mysql server support innodb? you can check this by going to your phpMyAdmin and click on 'Storage Engines'.

If so, try to remove the 'DEFAULT CHARSET = latin1 ' pieces in the query, default it should be latin1 so you can drop this.
SaWey
PL Master
 
Posts: 192
Joined: 8:28pm, Wed 08 Mar, 2006
Location: Belgium

Postby blair.sawler » 11:10am, Tue 01 May, 2007

Just looked, and no InnoDB is disabled on the server. So what are my options now, manually create the table?
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Postby SaWey » 11:53am, Tue 01 May, 2007

I've got another query you can try, this one should work no matter what.

If it still doesn't work, then I don't know the answer and you will have to create the tables manualy.

here's the code:
Code: Select all
--
-- Database: 'phplist'
--

-- --------------------------------------------------------

--
-- Tabel structuur voor tabel 'phplist_mail2list_allowsend'
--

CREATE TABLE phplist_mail2list_allowsend (
  id int(11) NOT NULL auto_increment,
  email varchar(255) NOT NULL,
  name varchar(255) NOT NULL,
  sent int(50) NOT NULL default '0',
  PRIMARY KEY  (id)
);

-- --------------------------------------------------------

--
-- Tabel structuur voor tabel 'phplist_mail2list_list'
--

CREATE TABLE phplist_mail2list_list (
  listid int(10) NOT NULL,
  toemail varchar(255) NOT NULL,
  template int(10) NOT NULL,
  footer text NOT NULL,
  PRIMARY KEY  (listid)
);

-- --------------------------------------------------------

--
-- Tabel structuur voor tabel 'phplist_mail2list_popaccounts'
--

CREATE TABLE phplist_mail2list_popaccounts (
  listid int(10) NOT NULL,
  host varchar(255) NOT NULL,
  port varchar(255) NOT NULL,
  login varchar(50) NOT NULL,
  pass varchar(50) NOT NULL,
  mail_status varchar(10) NOT NULL default '0/0',
  queue varchar(3) NOT NULL default 'yes',
  del_message varchar(3) NOT NULL default 'yes',
  PRIMARY KEY  (listid)
);
Last edited by SaWey on 12:13pm, Tue 01 May, 2007, edited 1 time in total.
SaWey
PL Master
 
Posts: 192
Joined: 8:28pm, Wed 08 Mar, 2006
Location: Belgium

Postby blair.sawler » 12:06pm, Tue 01 May, 2007

Another error, is it the quotes?

Error
SQL query:

--
-- Database: 'phplist'
--
-- --------------------------------------------------------
--
-- Tabel structuur voor tabel 'phplist_mail2list_allowsend'
--
CREATE TABLE phplist_mail2list_allowsend(

id int( 11 ) NOT NULL AUTO_INCREMENT ,
email varchar( 255 ) NOT NULL ,
"name"varchar( 255 ) NOT NULL ,
sent int( 50 ) NOT NULL default '0',
PRIMARY KEY ( id )
);



MySQL said:

#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '"name" varchar(255) NOT NULL,
sent int(50) NOT NULL default
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Postby SaWey » 12:13pm, Tue 01 May, 2007

Ah, yes, sorry, just remove the quotes (changed it in my previous post)
SaWey
PL Master
 
Posts: 192
Joined: 8:28pm, Wed 08 Mar, 2006
Location: Belgium

Postby blair.sawler » 1:05pm, Tue 01 May, 2007

That was it, thanks very much!!! Now I will give it a try
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Postby blair.sawler » 1:19pm, Tue 01 May, 2007

Works great thanks this is what I always thought PHPList was missing.

Now I just need to get it to look for messages automatically!

-Blair
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Footer Question

Postby blair.sawler » 1:43pm, Tue 01 May, 2007

Where does Mail2List get the footer information for the mail? It does not match up with what I have configured.

Thanks

-Blair
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Postby SaWey » 2:34pm, Tue 01 May, 2007

Ah, yes, that's true, I forgot to check on that.

In get_email.class.php at about line 502 you will find
Code: Select all
$GLOBALS[default_config][messagefooter][0]


Just replace it with:
Code: Select all
getConfig("messagefooter")
SaWey
PL Master
 
Posts: 192
Joined: 8:28pm, Wed 08 Mar, 2006
Location: Belgium

Postby blair.sawler » 2:51pm, Tue 01 May, 2007

Perfect. Thanks so much again! Now one more question.... (but I am not promising anything :) )

I have created a cron job to process the queue for PHP list, but how do you process the queue for the messages from mail2list.

AM I right in assuming that if I Select "No" for "Queue messages sent to this address" that it will then automatically go to the queue for PHP list? Then my cron job will take over from there an make sure they are delivered?

Thanks again.

-Blair
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Postby SaWey » 3:06pm, Tue 01 May, 2007

blair.sawler wrote:AM I right in assuming that if I Select "No" for "Queue messages sent to this address" that it will then automatically go to the queue for PHP list? Then my cron job will take over from there an make sure they are delivered?


No, this isn't what it does, it will put the processed messages in draft mode, so they won't be sent out.

Currently there is no option to do this with cronjob because the page has to reload in the browser when multiple messages are in the mailbox.

I'm working on a version that will make it possible to use cron-jobs, but it won't be soon as I'm very bussy at the moment.
SaWey
PL Master
 
Posts: 192
Joined: 8:28pm, Wed 08 Mar, 2006
Location: Belgium

Postby blair.sawler » 3:10pm, Tue 01 May, 2007

Oh okay. Good thing I did not do that then eh? Thanks for the clarification.

That is the only thing that is missing on this fantastic plug in.

I will be patiently waiting. I guess for now, what I will do is just have any E-mails sent to the lists to be forwarded to me and then I'll log in and send them.

Thanks again you have been most helpful!

-Blair

P.S. Is the cron job enhancement ready yet. Ha ha :D
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

Not Sending Mail?

Postby blair.sawler » 9:28am, Wed 02 May, 2007

Another issue--everything was working great, but then last night I decided to tweak the footer a bit, saved the new footer, sent an E-mail to my list, and it processed the queue, I received the E-mail from the system saying that the E-mail was processed.

I never received the E-mails.

The only other thing I did was remove a friend from the list so he would not get the test E-mails.

Any thoughts to what teh issue could be? Thanks!
blair.sawler
PL Nut
 
Posts: 21
Joined: 3:05pm, Sun 26 Nov, 2006

PreviousNext

Return to Contributions: Plug-ins, Add-ons, Mods

Who is online

Users browsing this forum: No registered users and 1 guest