format of form data

Issues related to forms.
adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

format of form data

Post by adrian5750 » Tue Dec 05, 2017 1:56 pm

HI Folks

One of my clients has several 'response' forms on their site.

One form is at www.mast.ie/contact.php (created some years ago)
the other (recently created) is at www.mast.ie/application.php

When the first form is submitted, each field shows in the email data recieved as a new line.
When the second form is submitted, there are no line breaks between the fields in the email, so everything is shown as one long line.

I use Thunderbird for email, which does not show this effect - in (my) Thunderbird both emails are sensibly-formatted, with line-feeds.
My client uses whatever the latest Microsoft email program is - and they are reporting this problem.

Looking at the pages, both in WYSIWYG design view and the actual code after publishing, I can't see any obvious difference.
Client is asking "Why can't the data from the new form be displayed the same way as the data from the old form?"

Any ideas, please?
Thanks
Adrian

User avatar
BaconFries
 
 
Posts: 4112
Joined: Thu Aug 16, 2007 7:32 pm

Re: format of form data

Post by BaconFries » Tue Dec 05, 2017 2:14 pm

You can, the line breaks that allow the text to flow to the next line are always included but some email applications filter it out and the final output is plain text all in one line. To resolve you can set the message format at to 'rich text' or HTML, so you have more control over the formatting.

User avatar
Pablo
 
Posts: 16809
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: format of form data

Post by Pablo » Tue Dec 05, 2017 2:17 pm


adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Tue Dec 05, 2017 2:34 pm

HI Baconfries & Pablo

Thanks for the info - didn't realise that I have the option of producing 'pretty' formatted data...
I suppose I can do that for the 2nd form - the one that's misbehaving. It's a bit of effort to type in the formatting info...
but if it makes the client happy..... ,g>

Still don't know why the first form displays _with_ line-breaks in Microsoft-whatever-it-is - but the second form, which seems to have exactly the same set-up doesn't....?
Just a Microsoft 'funny' - do you think?

Thanks
Adrian

adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Tue Dec 05, 2017 9:40 pm

HI Folks

OK - some follow-up issues

#1
I've changed the form so that it returns rich-text - but it seems to be adding 'space' characters into the email - see the pasted data from the email below. e.g "Application" becomes "Applica tion", "Ballydehob" becomes "Ballyde hob" and so on.

=====starts
MAST Applica tion form

Name : Adrian Brentnall
Address : Gortnagrough, Ballyde hob
Mobile : 08612345678
Landline : 08612345678
Date of birth : 23/3 /1956
Trading Name : Inspired-glass
Email address : adrian@inspired-g lass.com
Web address : www.inspired-glass.com
Facebook : https://www. facebook.com/inspiredglass
====ends

This is the corresponding text from the Form Processor Message panel - email format is set to Rich Text.
===starts
MAST Application form

Name : $Name
Address : $Address
Mobile : $Mobile
Landline : $Landline
Date of birth : $Date-of-Birth
Trading Name : $Trading-Name
Email address : $Email
Web address : $Web-address
Facebook : $Facebook
===ends

#2 Also, the form has a number of questions where one or more checkboxes can be ticked.
In the fragment below these checkboxes are named Public-Liability, Public-Liability-Food-Only, Public-Liability-other-then-Food, Employers-Liability, and Goods-in-Transit - and are initially set to 'not checked', and, when ticked, have a value of 'yes'

In the Form Processor Message panel, I have, for example
===starts
Benefits required -
Public Liability :$Public-Liability
Public Liability Food Only :$Public-Liability-Food-Only
Public Liability other than Food :$Public-Liability-other-than-Food
Employers Liability :$Employers-Liability
Goods in Transit :$Goods-in-Transit
===ends

Which returns the following in the email when the 1st, 3rd and 5th boxes are ticked
===starts
P ublic Liability :yes
Public Liability Food Only :yes-Food-Only
Publ ic Liability other than Food :yes-other-than-Food
Employers Liability :$ Employers-Liability
Goods in Transit :yes
===ends

Which doesn't seem to make sense to me... - but perhaps I've got something wrong in the Form Processor Message Panel

The project is at http://www.mast.ie/Adrian-application-form-dec-2017.wbs and the page is called apptest.php

Would greatly appreciated some help - thanks in advance
Adrian

User avatar
Pablo
 
Posts: 16809
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: format of form data

Post by Pablo » Wed Dec 06, 2017 7:08 am

I don't think the script will insert random spaces. Maybe it's a glitch in the email application?
Did you view the source of the message in the email application?

adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Wed Dec 06, 2017 8:12 am

HI Pablo

Thanks for the reply.

OK - looking at 'view source' in Thunderbird - taking the first few lines of the message

===starts
This is a multi-part message in MIME format.

--b1_ef352795bb2a9f1dbf69433de511bb41
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: quoted-printable

MAST Application formName : AdrianAddress : Gurtnagrough, GortnagroughMobil=

e : +3532837593Landline : +3532837593Date of birth : 23/3/1956Trading Name =

: Inspired-glassEmail

<<snip>>
--b1_ef352795bb2a9f1dbf69433de511bb41
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: quoted-printable

<font style=3D"color:#000000;font-family:arial;font-size:16px">MAST Applica=

tion form<br><br>Name : Adrian<br>Address : Gurtnagrough, Gortnagrough<br>M=

obile : +3532837593<br>Landline : +3532837593<br>Date of birth : 23/3/1956<=

br>Trading Name : Inspired-glass<br>Email
===ends

It looks a lot clearer in a fixed-width font - but the second section has a character (represened in the 'view source' as an '=' character, at the end of every line (think it's every 75th character) - and these characters seem to be represented as spaces in the normal view of the email.

Before getting to Thunderbird, the email is checked by Mailwasher - and the same effect (extra character inserted at regular intervals) is visible there.

Don't know if that gives any clues as to what's going on?
At the moment, it seems I can either deliver the form data (to my client's Microsoft email program) as a single continous string of characters (by senting raw text) - or as a nicely-formatted email with additional spaces thrown in (using rich text and/or html formatting.


Thanks
Adrian

User avatar
Pablo
 
Posts: 16809
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: format of form data

Post by Pablo » Wed Dec 06, 2017 8:41 am

I think '=' is added by PHP Mailer to indicate the end of a line.
The email application should filter this and reconstruct the original message.
Did you also try to view the message in another email application?

adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Wed Dec 06, 2017 8:43 am

I don't have an alternative email application.
Shall I send the form and add your email - so you get a copy?
Adrian

User avatar
Pablo
 
Posts: 16809
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: format of form data

Post by Pablo » Wed Dec 06, 2017 8:48 am

Yes, you can try that.

adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Wed Dec 06, 2017 9:07 am

Thanks - form is now cc'd to support@pablosoftwaresolutions.com
Got to step out of the office for 2 hours - but back later
Thanks
Adrian

adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Wed Dec 06, 2017 11:17 am

Hi Pablo.
Back now - did you get the submission from the form - if so, what did you see in the formatting?
Thanks
Adrian

User avatar
Pablo
 
Posts: 16809
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: format of form data

Post by Pablo » Wed Dec 06, 2017 12:06 pm

No, I did not receive any messages from this form.

adrian5750
 
 
Posts: 92
Joined: Wed Apr 20, 2011 9:17 pm

Re: format of form data

Post by adrian5750 » Wed Dec 06, 2017 12:09 pm

Ah - sorry - my mistake...
I see your submission - it's from the original page - which sends (me) plain text - and which shows up on the client's email as one single line of text without <br>s.
I'd cloned it to a new page while I tried various tweaks.

Please try this page instead - which should send you a copy.
http://www.mast.ie/apptest1.php

Thanks & sorry for the confusion
Adrian

User avatar
Pablo
 
Posts: 16809
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: format of form data

Post by Pablo » Wed Dec 06, 2017 12:36 pm

I filled in the form, but still no email.

Note that for testing it may be easier to simply the form. Now it is a lot of work to fill in the entire form...

Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests