How to show hard returns the same in email - Page 2
Page 2 of 2 FirstFirst 12
Results 16 to 20 of 20

Thread: How to show hard returns the same in email

  1. #16
    Junior Member
    Join Date
    Mar 2012
    Posts
    17
    var_dump (Item #1 - Orange 25.25 Item #2 - Red 47.12 Item #3 - Blue 63.78 ) is the output for var_dump ($questionField)

  2. #17
    Pna lbh ernq guvf¿
    Join Date
    Jul 2004
    Location
    Kansas City area
    Posts
    19,349
    No, it is not. The manual page for var_dump() shows the type of output that function generates.

    Are you calling the function var_dump(), or are you simply putting the string "var_dump($questionField)" inside of $body?

  3. #18
    Junior Member
    Join Date
    Mar 2012
    Posts
    17
    I have been to the var_dump link and learned nothing about "where" to put it. I am putting it in the body. Again, where is it supposed to go? I put it outside the body and got the Web Browser result:

    string(67) "Item #1 - Orange 25.25 Item #2 - Red 47.12 Item #3 - Blue 63.78 "
    Last edited by bkirkpatrick; 03-31-2012 at 11:38 PM.

  4. #19
    Senior Member traq's Avatar
    Join Date
    Jun 2011
    Location
    so.Cal
    Posts
    949
    Quote Originally Posted by bkirkpatrick View Post
    string(67) "Item #1 - Orange 25.25 Item #2 - Red 47.12 Item #3 - Blue 63.78 "
    That is what we were looking for.

    If you view source on the page, does that display in a single line, or are there line breaks?

    (i.e., do you see this:

    string(67) "Item #1 - Orange 25.25
    Item #2 - Red 47.12
    Item #3 - Blue 63.78 "


    or this:

    string(67) "Item #1 - Orange 25.25 Item #2 - Red 47.12 Item #3 - Blue 63.78 "

    ?)


    Alternatively, run this
    PHP Code:
    print strpos$questionField,"\n" ); 
    and show us the output.

    -----------------------------------
    [edit]

    actually, the string length (67) would seem to indicate that there are newlines... what OS are you using?
    Last edited by traq; 04-01-2012 at 12:07 AM.

  5. #20
    Junior Member
    Join Date
    Mar 2012
    Posts
    17
    It prints the second example (ie. on one line).

    I tried the print code but get the following error:

    Parse error: syntax error, unexpected T_PRINT....

    I am Using Windows XP but the form is run off of Godaddy which is running a linux

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •