Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#691 2009-11-23 10:36:13

MrLongbaugh
Member
From: Hamburg - Germany
Registered: 2004-10-11
Posts: 116

Re: zem_contact_reborn 4.0.3.20

Hi,
I use this plugin for years now and never had a problem.

For a new project I have to set the return-path.

How can I do that?

Offline

#692 2009-11-23 11:26:28

merz1
Member
From: Hamburg
Registered: 2006-05-04
Posts: 994
Website

Re: zem_contact_reborn 4.0.3.20

@MrLongbaugh In my inbox your comment was aimed at ‘tru_tags: A tagging plugin based off ran_tags’. Which one is right?


Get all online mentions of Textpattern via OPML subscription: TXP Info Sources: Textpattern RSS feeds as dynamic OPML

Offline

#693 2009-11-23 12:02:22

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

MrLongbaugh wrote:

Hi,
I use this plugin for years now and never had a problem.

For a new project I have to set the return-path.

How can I do that?

You shouldn’t, because according to RFC 5321 the return-path is added by the final delivering SMTP server, not by the sending SMTP server.
Consider using the ‘reply-to’ header instead?

Offline

#694 2009-11-23 12:39:45

MrLongbaugh
Member
From: Hamburg - Germany
Registered: 2004-10-11
Posts: 116

Re: zem_contact_reborn 4.0.3.20

merz1
My mistake. That was the wrong thread. So I deleted there. Sorry.

ruud
The Return-Path and the envelope-from is set to: anonymous@oberon.kreativmedia.xx
Some mailprovider don’t accept the mails.
Now I habe to find a way to change the anonymous@oberon.kreativmedia.xx entry.

Last edited by MrLongbaugh (2009-11-23 12:40:41)

Offline

#695 2009-11-23 12:53:26

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

Edit the plugin, search for the two lines that look like mail($to, $subject, $msg, $headers) (second one is slightly different) and add an extra parameter like this:

mail($to, $subject, $msg, $headers, '-fsender@example.com')

Last edited by ruud (2009-11-23 12:53:41)

Offline

#696 2009-11-23 12:59:06

MrLongbaugh
Member
From: Hamburg - Germany
Registered: 2004-10-11
Posts: 116

Re: zem_contact_reborn 4.0.3.20

Hi Ruud,

thanks for your suggestion. I did that already.
It seems the 5th parameter is not permitted.

Offline

#697 2009-11-23 13:25:36

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

If you’re on a windows server, try adding ini_set(‘sendmail_from’, ‘sender@example.com’); at the beginning of the plugin code or just above the mail() line. If that doesn’t work either, contact your webhost for advice.

Offline

#698 2009-11-23 13:45:01

MrLongbaugh
Member
From: Hamburg - Germany
Registered: 2004-10-11
Posts: 116

Re: zem_contact_reborn 4.0.3.20

The hoster changed the permissions. So its possible to use the 5th parameter now.
Thanks for your suggestions ruud.

Offline

#699 2009-12-05 21:14:41

Ldx
Member
Registered: 2009-10-24
Posts: 15

Re: zem_contact_reborn 4.0.3.20

Hi all.
First: Thanks to Ruud for this great plugin.

Then the question: I’d like that when user succesfully clicks “Submit”, he/she can get a copy of the email content on the screen, so he/she can print or save it as a “receipt”. I imagine that the “thank you” landing page should have a way to access the individual values of fields submitted by the user, or to the whole email body.

I don’t want to send a copy of the email to the address submitted by user because this could be used for free spamming (or even the email address can be mistyped so the user never gets the “receipt”).

I searched the forum but I was unsuccesful. Could you please give me some suggestion?

Kind regards
Aldo

Offline

#700 2009-12-05 23:01:55

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

Ldx, if you’re a bit familiar with PHP, this should get you started (put it in the thanks_form):

<txp:php>
  global $zem_contact_labels, $zem_contact_values;
  foreach ($zem_contact_labels as $name => $label)
  {
    if (!trim($zem_contact_values[$name])) continue;
    echo htmlspecialchars($label).': '.htmlspecialchars($zem_contact_values[$name]).'<br />';
  }
</txp:php>

Offline

#701 2009-12-07 08:13:36

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: zem_contact_reborn 4.0.3.20

Any way to specify an alternative article form to be used with the <txp:zem_contact_send_article /> tag?

What I’m trying to do is include a few custom fields (containing sensitive information) with the emailed article, which are not shown on the public website. Maybe this is possible using CSS (display: hidden), to hide the fields on the website but show them in the emailed article (the emailed article won’t contain styles right?), but I also worry about including the fields in the public HTML, even if they are hidden, as this can easily be circumvented by turning off styles. Any ideas or solutions are much appreciated!

Last edited by aswihart (2009-12-07 08:14:19)

Offline

#702 2009-12-07 17:50:16

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

aswihart, have a look at the <txp:zem_contact_secret /> tag.

Offline

#703 2009-12-08 02:43:39

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: zem_contact_reborn 4.0.3.20

Cool ruud, I am new to the plugin, it seems that was an obvious solution. But still, I’m wondering if there is a way to customize the article form that is sent by email. For instance can you send the whole article and not just the excerpt (if excerpt is present)?

And, the ideal functionality for me would be using rvm_privileged to hide the “Send Article” link from non-logged-in visitors, but if you are logged in, you can simply click the link one time and have the article sent. Currently I have it working, but I don’t like the fact that you can enter any e-mail address for the article to be sent to. My website contains protected information that should not be sent to any email address other than those associated with Textpattern users.

Is there a way to bypass the two-step “Send Article” -> “Submit” process, and automatically use the logged in users email address (a la <txp:rvm_privileged_user type="email">) as the recipient? I tried doing it this way using the copysender attribute, but got the error Required field, “Recipient”, is missing.:

<txp:rvm_if_privileged>
<txp:zem_contact to='<txp:rvm_privileged_user type="email">' copysender="1" send_article="1">
  <txp:zem_contact_submit label="Send Article" />
</txp:zem_contact>
<txp:zem_contact_send_article />
</txp:rvm_if_privileged>

Any ideas?

Offline

#704 2009-12-08 05:15:31

aswihart
Member
From: Pittsburgh, PA
Registered: 2006-07-22
Posts: 345
Website

Re: zem_contact_reborn 4.0.3.20

Thinking of a way to make it a little more user-friendly for the people using my site, is there way to auto-populate the recipient email text field with <txp:rvm_privileged_user type="email">?

Offline

#705 2009-12-08 10:37:05

ruud
Developer Emeritus
From: a galaxy far far away
Registered: 2006-06-04
Posts: 5,068
Website

Re: zem_contact_reborn 4.0.3.20

aswihart wrote:

I’m wondering if there is a way to customize the article form that is sent by email. For instance can you send the whole article and not just the excerpt (if excerpt is present)?

Edit the plugin, replace this part:

(trim(strip_tags($thisarticle['excerpt'])) ? $thisarticle['excerpt'] : $thisarticle['body']))));

with:

($thisarticle['body']))));

Currently I have it working, but I don’t like the fact that you can enter any e-mail address for the article to be sent to. My website contains protected information that should not be sent to any email address other than those associated with Textpattern users.

You can’t prevent people from forwarding the articles once the article is received on a registered email address.

Is there a way to bypass the two-step “Send Article” -> “Submit” process, and automatically use the logged in users email address (a la <txp:rvm_privileged_user type="email">) as the recipient? I tried doing it this way using the copysender attribute, but got the error Required field, “Recipient”, is missing.:

Try this (not tested):

<txp:rvm_if_privileged>
<txp:zem_contact from="webmaster@example.com" send_article="1">
  <txp:zem_contact_email label="Recipient Email" default='<txp:rvm_privileged_user type="email">' send_article="1" />
  <txp:zem_contact_submit label="Send Article" />
</txp:zem_contact>
<txp:zem_contact_send_article />
</txp:rvm_if_privileged>

Offline

Board footer

Powered by FluxBB