Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#73 2009-09-25 17:10:08

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 999
Website

Re: mem_postmaster - Postmaster Revamp

mrdale wrote:

here’s a way

Thanks, Dale— that’s inspiring txp-fu. Do you know of anyone implementing this design pattern? A code sample would be great!

Offline

#74 2009-09-25 19:47:57

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: mem_postmaster - Postmaster Revamp

johnstephens wrote: Do you know of anyone implementing this design pattern?

Not a bit. Shouldn’t be too hard tho.

Offline

#75 2009-09-25 22:26:11

whocarez
Plugin Author
From: Germany/Ukraine
Registered: 2007-10-08
Posts: 305
Website GitHub Twitter

Re: mem_postmaster - Postmaster Revamp

mrdale wrote:

here’s a way

Ahhh, I didn’t look in the other thread … Thanks, a lot! Hope, that I can get it to work.

Offline

#76 2009-09-27 21:08:16

whocarez
Plugin Author
From: Germany/Ukraine
Registered: 2007-10-08
Posts: 305
Website GitHub Twitter

Re: mem_postmaster - Postmaster Revamp

Newsletter cronjob

I hope, that’s the right place for this information and it is interesting for someone. Perhaps there is already an easier solution …

I worked out a solution to automate the newsletter via crontab.
It is tested under Debian Etch with edbrowse 3.1.2, textpattern 4.2.0 and mem_postmaster 1.03/ 1.06 , in 1.06 seems to be a problem with javascript …

You have to create a “.ebrc” file in your user directory – for example root – and put the following in:


function+init{
b http://yoursite/textpattern
4
i=your_user
5
i=her_password
8
i*
b http://yoursite/textpattern/index.php?event=postmaster&step=initialize_mail&radio=1&list=your_list&artID=an_existing_article_id
b http://yoursite/textpattern/index.php?logout=1
q
}

Edbrowse logs in to your Textpatterninstallation and calls your Postmasterplugin to send out the newsletter. After that it logs out and closes itself.
Important is to put a right username and his/her password into this file. Be sure, that only this user can read this file “chmod 600”. Don’t forget to name the existing newsletter_list. For testing purposes use “radio=2”.

After that create a file in your /etc/cron.d – for example “newsletter” – with the following content:

@weekly username(maybe root) /usr/bin/nice -n 19 /usr/bin/edbrowse > /dev/null

That’s all. So every week cron sends via edbrowse automatically your newsletter out.
More about Edbrowse you can find here. A detailled documentation is here.

Last edited by whocarez (2009-10-04 23:50:11)

Offline

#77 2009-09-28 04:35:53

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: mem_postmaster - Postmaster Revamp

Is there a way to have the article title to be the same as the title of the newsletter?


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#78 2009-09-29 11:24:49

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,538
Website GitHub Twitter

Re: mem_postmaster - Postmaster Revamp

[SOLVED]
Hi

I have upgraded one of my website to 4.2.0 from 4.0.2, all goes well, I also decided to use the new mem_postmaster, then i installed the new plugin and desactivated the old bab_postmaster, the upgrade didnt work correctly , but after importing old subscribers to a new empty table, the data was ok.

Now the issu is the online subsciption is not working, i checked the form it seems ok, i take a form from this thread to test, and it also dont work, here is the form:

<txp:zem_contact to="mail@mymail.com" label="" >
<txp:zem_contact_text name="zemSubscriberFirstName" label="Your Name:" required="1" /><br />
<txp:zem_contact_text name="zemSubscriberLastName" label="Your Name:" required="1" /><br />
<txp:zem_contact_email name="zemSubscriberEmail" label="Your Email:" required="1" /><br />
<txp:zem_contact_secret name="zemSubscriberLists" value="default" />
<txp:zem_contact_text name="zemSubscriberCustom1" label="Your website:" required="0" /><br />
<txp:zem_contact_submit label="Subscribe" />
</txp:zem_contact>

Putting the site en testing mode dont give me any message, en debugging i get that:

Tag error:  <txp:zem_contact_secret name="zemSubscriberLists" value="default" /> ->  Notice: Undefined variable: label  on line 591

textpattern/lib/txplib_misc.php(594) : eval()'d code:591 zem_contact_secret()
textpattern/publish.php:1106 zem_contact_secret()
textpattern/publish.php:1028 processTags()
textpattern/lib/txplib_misc.php(594) : eval()'d code:58 parse()
textpattern/publish.php:1106 zem_contact()
textpattern/publish.php:1041 processTags()
textpattern/publish/taghandlers.php:2062 parse()
textpattern/publish.php:1106 body()
textpattern/publish.php:1028 processTags()
textpattern/lib/txplib_misc.php:1621 parse()

Tag error:  <txp:zem_contact to="mesrabeh@gmail.com" label="" > ->  Warning: extract() [function.extract]: First argument should be an array  on line 1270

textpattern/lib/txplib_misc.php(594) : eval()'d code:1270 extract()
textpattern/lib/txplib_misc.php:636 bab_pm_zemcontact_submit()
textpattern/lib/txplib_misc.php:636 call_user_func_array()
textpattern/lib/txplib_misc.php(594) : eval()'d code:87 callback_event()
textpattern/publish.php:1106 zem_contact()
textpattern/publish.php:1041 processTags()
textpattern/publish/taghandlers.php:2062 parse()
textpattern/publish.php:1106 body()
textpattern/publish.php:1028 processTags()
textpattern/lib/txplib_misc.php:1621 parse()

Tag error:  <txp:zem_contact to="mesrabeh@gmail.com" label="" > ->  Notice: Undefined variable: zemSubscriberEmail  on line 1275

textpattern/lib/txplib_misc.php(594) : eval()'d code:1275 bab_pm_zemcontact_submit()
textpattern/lib/txplib_misc.php:636 bab_pm_zemcontact_submit()
textpattern/lib/txplib_misc.php:636 call_user_func_array()
textpattern/lib/txplib_misc.php(594) : eval()'d code:87 callback_event()
textpattern/publish.php:1106 zem_contact()
textpattern/publish.php:1041 processTags()
textpattern/publish/taghandlers.php:2062 parse()
textpattern/publish.php:1106 body()
textpattern/publish.php:1028 processTags()
textpattern/lib/txplib_misc.php:1621 parse()

My diag is:
Textpattern version: 4.2.0 (r3275)
Last Update: 2009-09-28 15:31:40/2009-09-28 15:27:49
Document root: /var/www/vhosts/viesdevilles.net/httpdocs
$path_to_site: /var/www/vhosts/viesdevilles.net/httpdocs
Textpattern path: /var/www/vhosts/viesdevilles.net/httpdocs/textpattern
Permanent link mode: section_id_title
open_basedir: /var/www/vhosts/viesdevilles.net/httpdocs:/tmp
Temporary directory path: /var/www/vhosts/viesdevilles.net/httpdocs/tmp
Site URL: viesdevilles.net
PHP version: 5.0.4
GD Image Library: bundled (2.0.28 compatible); supported formats: GIF, JPG, PNG.
Server TZ: -
Server Local Time: 2009-09-29 13:23:32
DST enabled?: 0
Automatically adjust DST setting?: 
Time Zone:  (+3600)
MySQL: 4.1.20
Locale: en_GB.UTF-8
Server: Apache/2.0.54 (Fedora)
Apache version: Apache/2.0.54 (Fedora)
PHP Server API: apache2handler
RFC 2616 headers: 
Server OS: Linux 2.6.9-023stab048.6-smp
Active plugins: chh_if_data-0.10, zem_contact_lang-4.0.3.03m, zem_contact_reborn-4.0.3.17m, zem_article_image-0.1, hak_article_image-0.6.1, upm_img_popper-1.3.3, upm_insert_tab-0.2.2, ign_password_protect-0.5, rss_admin_show_adv_opts-0.3, mem_postmaster-1.0.6, mem_postmaster_library-1.0.3
Admin-side theme: classic 4.2.0

.htaccess file contents: 
------------------------
#DirectoryIndex index.php index.html

#Options +FollowSymLinks
#Options -Indexes

<IfModule mod_rewrite.c>
	RewriteEngine On
	#RewriteBase /relative/web/path/

	RewriteCond %{REQUEST_FILENAME} -f [OR]
	RewriteCond %{REQUEST_FILENAME} -d
	RewriteRule ^(.+) - [PT,L]

	RewriteCond %{REQUEST_URI} !=/favicon.ico
	RewriteRule ^(.*) index.php

	RewriteCond %{HTTP:Authorization}  !^$
	RewriteRule .* - [E=REMOTE_USER:%{HTTP:Authorization}]
</IfModule>

php_value register_globals 0

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

Also: adding sibscriber using admin tab work.

Has somone an idea what’s wrong?

Thanks in advance.

Additional information: I had desactivated upm_save_new also, now i have erased: ben postmater plugin and upm_save_new, i make another attempt and now the online form send the email, but the database is not populated (i checked also phpmyAdmin to be sure), and an error is displayed on testing mode:

Tag error:  <txp:zem_contact to="mesrabah@gmail.com" label="" > ->  Warning: extract() [function.extract]: First argument should be an array  on line 1270

SOLVED

The problem was zem_contact plugin, I haven’t noticed that it has been updated, I was using 4.0.3.17 and it is now on 4.0.3.20

Then Apologise.

Last edited by Dragondz (2009-09-30 13:03:43)

Offline

#79 2009-10-07 15:03:12

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,538
Website GitHub Twitter

Re: mem_postmaster - Postmaster Revamp

Hi all

I try to integrate a file link into the newsletter but the tag <txp:file_link id=“XX”>Download the file</txp:file_link> is not rendered, am i make mistake or should i put a direct link to the file?

Thanks

Offline

#80 2009-10-08 13:09:59

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,538
Website GitHub Twitter

Re: mem_postmaster - Postmaster Revamp

Hi

I confirm that mem_postmaster didn’t convert txp:file into link.

The only way to include the link to file is to insert a link code directly into newsletter text and not use txp:file_link.

Cheers

Offline

#81 2009-10-09 07:04:36

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: mem_postmaster - Postmaster Revamp

An issue and a question:)

  • Issue: “last name” field is not included in the search for ‘subscriber name’. Understandable but it would be appropriate to include ‘subscriber last name’ in the search.
  • Question: We use a noreply email address to send our news. the emails which arrive only show that address is there a way to show something like Site Name <noreplay_email@address.com>?

Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#82 2009-10-21 15:32:40

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: mem_postmaster - Postmaster Revamp

colak wrote:

Issue: “last name” field is not included in the search for ‘subscriber name’. Understandable but it would be appropriate to include ‘subscriber last name’ in the search. solved it searches just fine

-Question: We use a noreply email address to send our news. the emails which arrive only show that address is there a way to show something like Site Name <noreplay_email@address.com> – solved all i needed to do is write Name <email@noreply.com> in the admin email field in the lists


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#83 2009-10-21 17:15:19

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: mem_postmaster - Postmaster Revamp

OK we have major problem with the unsubscribe function

THis is what we currently have

<txp:zem_contact to="an_email@gmail.com" label="" thanks_form="news-unsubform">
<txp:zem_contact_email name="zemSubscriberEmail" label="Your Email:" />
<txp:zem_contact_checkbox name="zemUnSubscribe" label="Unsubscribe" required="no" />
<txp:zem_contact_submit label="usubuscribe" />
</txp:zem_contact>

but it does NOT delete the email from the databse. Any ideas?


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#84 2009-10-28 08:51:12

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,090
Website GitHub Mastodon Twitter

Re: mem_postmaster - Postmaster Revamp

knock knock


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

Board footer

Powered by FluxBB