Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
p01-contact : simply add contact forms in your pages
#1
Hi,

This plugin let you simply add contact forms in pages by writing tags.

Infos, releases, issues :

https://github.com/nliautaud/p01contact
Reply
#2
The p01-contact plugin is disable, message not sent.
Reply
#3
GetSimple hide me all this errors? There is a "show php errors" somewhere?

There is a corrected version.
Reply
#4
Yes, running, could you attach a captcha?
Reply
#5
Thanks for debugging.

Oh, yeah, a captcha. Added to the todo list.
Reply
#6
but the letters do not come
Reply
#7
It's working on the websites where i've implemented the plugin.
Can you tell me more? There is a confirmation message? Any other error?

Thanks.

PS : I have 502 Bad Gateway in your page.
Reply
#8
p01 Wrote:Thanks for debugging.

Oh, yeah, a captcha. Added to the todo list.

Plz add option to choose on or off.

Thank you
Reply
#9
How do i send mail to several mail adresses?
Reply
#10
letters do not come and Russian text after sending looks like this
Reply
#11
im getting this error:
Deprecated: Function eregi() is deprecated in /Applications/MAMP/htdocs/gs/plugins/p01-contact.php on line 102

And Subject in reading the mail looks like : öåäöåäöåäö

Im using Å Ä Ö åäö (Swedish).
Reply
#12
Version 0.3 online!

Major news : You can specify which fields to show, in what order and what fields are required (from the plugin source, for now), there is a CAPTCHA field, new error system...

All details on p01-contact page.

Feel free to report any bugs you encounter (and there will be!).

Oleg06 Wrote:Russian text after sending looks like this
maxpop Wrote:Im using Å Ä Ö åäö (Swedish).

I don't know how to resolve that... The mail charset are utf-8, the plugin source and the mail contents are encoded in utf-8, the mail subject is base64 encoded...
If someone know...

maxpop Wrote:How do i send mail to several mail adresses?

For now you can't. And i'm not sure adding that is a good idea, because of spam.

maxpop Wrote:im getting this error:
Deprecated: Function eregi() is deprecated in /Applications/MAMP/htdocs/gs/plugins/p01-contact.php on line 102

Thanks, it's corrected.
Reply
#13
Code:
Notice: Undefined index: contact in /home/cp057944/public_html/neowebtime.ru/0000/plugins/p01-contact.php on line 65
Reply
#14
Version 0.4 online!

Major news : Define recipients and options with tags parameters (add multiple recipients, display fields, hide fields, make fields required), put several forms by page...

All details here : http://nliautaud.fr/wiki/travaux/p01-contact

Feel free to report any bugs you encounter (and there will be!).

Branch 0.4 updates :
  • Bugs fixes in version 0.4.1 (i found the GS debug mode, it's help a lot :B)
  • Working encoding, bugs fixes in version 0.4.2
Reply
#15
p01 Wrote:Version 0.4 online!
Feel free to report any bugs you encounter (and there will be!).

Code:
Notice: Undefined index: targets in /gs/plugins/p01-contact.php on line 123

Warning: array_unique() [function.array-unique]: The argument should be an array in /gs/plugins/p01-contact.php on line 123

Notice: Undefined index: status in /gs/plugins/p01-contact.php on line 280

Could you provide couple examples of using this plugin with parameters ?
I've read dozen times your documentation, and still have no idea how to set recipient e-mail address.
Entering an invalid parameter in (% contact : parameter %) leads to additional errors with array.

edit: php ver 5.2.13
Did you develop contact plugin on php 5.3.x ?
Addons: blue business theme, Online Visitors, Notepad
Reply
#16
Hi,

I give some examples in p01-contact page.

Just replace the example addresses by your recipients addresses.

The errors reported was fixed in 0.4.1, look at precedent post.

The plugin should work with the minimum version of php requested by GetSimple.

Thanks.
Reply
#17
Hmm...I had to download v4.0 plugin just before you uploaded version with fixed bugs later posted by me Wink

Anyway I forgot to add , that captcha img isn't being shown (only alt text "CAPTCHA image")

Second thing, as I expected, message encoding is messed up, although I see it's encoded in utf-8. National chars are shown as bushes. Common problem in phpmailers :/
When message is too short, it reloads field content, with bushes instead of special chars.

I'll try to look inside plugin files later, and try to fix encoding. Supposing I am able to do it, because reloading badly encoded content is a different thing than just sending a message.

But I have no idea how to make captcha image working.
I see you utilize a GPL script, and there's a tag allowing to use prepared backg img.
Addons: blue business theme, Online Visitors, Notepad
Reply
#18
yojoe Wrote:Anyway I forgot to add , that captcha img isn't being shown (only alt text "CAPTCHA image")

Yeah, i saw that. This is obviously due to bad relative link with url-rewriting, i think. I'll fix tonight.

yojoe Wrote:Second thing, as I expected, message encoding is messed up, although I see it's encoded in utf-8. National chars are shown as bushes. Common problem in phpmailers :/
I have never been able to properly handle the encoding... This is at the top of my todo list.
http://get-simple.info/forum/post/7166/#p7166

I can correctly decode latin characters (accents, etc...) with utf8_decode(), but the others (chinese, russian...) become : ???.
Reply
#19
Some sort of encoding specification as mentioned in the ‘email encoding problem’ topic might solve this. You won’t have to encode/decode the email when you specify the characters as being UTF-8.

I haven’t looked into it much, but it might solve your problems.
“Don’t forget the important ˚ (not °) on the a,” says the Unicode lover.
Help us test a key change for the core! ¶ Problems with GetSimple? Be sure to enable debug mode!
Reply
#20
Hi p01;

i'm received your mail, but i'm is just limit time for my job.

Sorry Sad

I try to look quickly Smile
Reply
#21
Ok,

I'have 3 problem .

1 error php strict, the var $error, in function check_form_content, in p01-contact is not initialized.

replace in lg 169
Code:
function check_form_content($form_data)
{
    foreach($form_data['fields'] as $name => $value) {


by
Code:
function check_form_content($form_data)
{
    $error=array();
    foreach($form_data['fields'] as $name => $value) {

2 in my page, I have just form, and i look source:
Code:
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
    <meta name="description" content="(% contact : xxxx@oscim.xxx , nocaptcha, %)" />
the mail is visible

3 and encoding,

Your encode/decode several times. And it's bug..
And this page is encoding in utf-8. So not use utf8_encode

For me, in lg ~130
Code:
//         $forms_data[$form_id]['fields'] = stripslashes_r(htmlentities_r($_POST['contact']));
        $forms_data[$form_id]['fields'] = stripslashes_r(($_POST['contact']));

And

lg ~ 329
Code:
//     $fields  = utf8_encode_r($form_data['fields']);
    $fields  = $form_data['fields'];

lg 333
Code:
//     $subject = '=?UTF-8?B?' . base64_encode($fields['subject']) . '?=';
    $subject = '=?utf-8?q?' . $fields['subject'] . '?=';

It's ok Smile

I'm test in french .

PS , the sender did not have a copy ?
Reply
#22
p01: I've found the "bug" with encoding, and now I'm getting nicely encoded messages with special chars :]
Want to know solution ?
PLEASE INSERT COIN Tongue

hihii
Problem was caused by your tools functions.
I had no idea whatfor you are converting chars to entities, and encode utf-8 ... into utf8 using an array.

Solution
Get rid of function utf8_encode_r($array) and function htmlentities_r($array)
Or just don't call them at all in below variables
Code:
$forms_data[$form_id]['fields'] = stripslashes_r($_POST['contact']);
$fields  = $form_data['fields'];

K, problem with encoding solved.
But I've been hit with big dose of procrastination, and solving captcha img problem is up to you Wink

btw. 3 additional things for your "todo" list:

1.custom subject as a parameter - to let users know that e-mail came from their contact form

2. handler informing user that message has been successfully sent - I didn't get any "you were lucky to successfully send me an e-mail" info Wink

3. try to secure the form from history_back, put a timer or do anything to prevent resending message in a given period of time



edit: ohhh oscim found out earlier, so I didn't see his reply
But "base64_encode" is a must, and I wouldn't get rid of it, if this whole thing should work correctly

oscim: fix captcha img if you're such php geeko Tongue
Addons: blue business theme, Online Visitors, Notepad
Reply
#23
Quote:But "base64_encode" is a must, and I wouldn't get rid of it, if this whole thing should work correctly

Ok, use in function send_mail
Code:
$subject = '=?utf-8?b?' . base64_encode($fields['subject']) . '?=';

This usage not problem, and encoding is ok.


Quote:fix captcha img if you're such php geeko

The htaccess in pugin, block call captcha.

For fix, add htaccess in folder p01-contact/captcha

Code:
<Files securimage_show.php>
order allow,deny
allow from all
</Files>
Reply
#24
Thank you all for your participation.

The 0.4.2 is online : http://get-simple.info/forum/post/7177/#p7177

Zegnåt Wrote:Some sort of encoding specification as mentioned in the ‘email encoding problem’ topic might solve this.
I had contacted him, like you see Smile

oscim Wrote:1 error php strict, the var $error, in function check_form_content, in p01-contact is not initialized.
Thanks, fixed.

oscim Wrote:2 in my page, I have just form, and i look source:
Code:
<meta name="description" content="(% contact : xxxx@oscim.xxx , nocaptcha, %)" />
Damn, i had not thought to GetSimple source scan... For now I don't know enough about the operation to avoid this.
Todo.

oscim Wrote:For me, in lg ~130
Code:
//$forms_data[$form_id]['fields'] = stripslashes_r(htmlentities_r($_POST['contact']));
$forms_data[$form_id]['fields'] = stripslashes_r(($_POST['contact']));
yojoe Wrote:Get rid of function utf8_encode_r($array) and function htmlentities_r($array)
Or just don't call them at all in below variables
The htmlentities() function avoid XSS, script injections by converting risqued characters to html entities. It's a needed security operation.
But yes, there was indeed a problem here with the encoding of this function. And I tried to tinker with output, using utf8_encode (). But it was thus sufficient to force the charset as follows :
Code:
htmlentities($tmp, ENT_QUOTES, 'UTF-8');
So, it's working. Thank you both for trying.

Quote:I didn't get any "you were lucky to successfully send me an e-mail" info
It was a bug. Fixed.

oscim Wrote:PS , the sender did not have a copy ?
I did not implemented because it would be easy to spam.

oscim Wrote:The htaccess in pugin, block call captcha.
For fix, add htaccess in folder p01-contact/captcha
Code:
<Files securimage_show.php>
order allow,deny
allow from all
</Files>
Oh, I thought I had added the htaccess in the previous update. But anyway I had not limited access, donc merci pour ça Wink
Reply
#25
p01 Wrote:
oscim Wrote:PS , the sender did not have a copy ?
I did not implemented because it would be easy to spam.
The way this is usually implemented would be a checkbox at the bottom of the form, something like: “Send me a copy of this email.” I don’t think it’s really that much of a spam thing. Of course you could make it an optional setting if you ever get to implementing it.
“Don’t forget the important ˚ (not °) on the a,” says the Unicode lover.
Help us test a key change for the core! ¶ Problems with GetSimple? Be sure to enable debug mode!
Reply




Users browsing this thread: 7 Guest(s)