+ Reply to Thread
Results 1 to 5 of 5

Thread: $TEMPLATEDIR = Troubleshooting: The saga continues

  1. #1
    Join Date
    Oct 2008
    Posts
    3

    Default $TEMPLATEDIR = Troubleshooting: The saga continues

    Wow, took me about 7 tries to get thru the forum registration door. I thought I was reading the image verification correctly but apparently not. Never had this problem before. I guess the eyes aint what they used to be.

    Anyway...I'm in the middle of switching my company site to a new server and as a result I am changing forms from the .pl form we currently use.

    My host (u2-web) has verified that I have the correct string in the $TEMPLATEDIR = path but the form is still not reading my plain text file. I'm getting results (thanks page and no errors) but not what I expect to see based on my plain.txt file.

    /hsphere/local/home/mysite/mysite.com/fmtemplates

    My php file is saved in the above path, my plain.txt file is in a directory named fmtemplates, and my html file is in a directory called Company.

    Any ideas or suggestions? Thanks in advance for you input.

  2. #2
    Join Date
    May 2008
    Posts
    1,274

    Default Re: $TEMPLATEDIR = Troubleshooting: The saga continues

    Hi,

    I'm assuming this is an email template that you're having trouble with? Are you using a template for your thank you page? If so, is that template working right?

    Have you set the template in your form?

    Can you post the relevant portions of your form code?

    ginger

  3. #3
    Join Date
    Oct 2008
    Posts
    3

    Default Re: $TEMPLATEDIR = Troubleshooting: The saga continues

    Hi Ginger,

    $TEMPLATEDIR = "/hsphere/local/home/my domain/mydomain.com/fmtemplates"

    My host offers this php script on their server and confirmed that the above string is correct and that I should contact the developer for assistance.

    In my html file I have the following:
    <input type="hidden" name="mail_options" value="PlainTemplate=results.txt" />

    results.txt is saved in a directory named fmtemplates. (I checked the directory attributes as suggested in another post and they are correct, 755)

    My thank you page displays properly:
    <input type="hidden" name="good_url" value="http://mydomain.com/thankyou.html" />

    I'm not getting any error messages. I am getting the form results in email, they just aren't formatted based on what I have in the results.txt file, and the whole point is to be able to paste certain info right into our quote templates.

    Thanks so much for your time. I hope you spot something that I am missing.

  4. #4
    Join Date
    May 2008
    Posts
    1,274

    Default Re: $TEMPLATEDIR = Troubleshooting: The saga continues

    When you say you aren't getting any error messages, have you set $DEF_ALERT, or do you just mean you aren't getting any error messages on the page after submission?

    Your good_url is not a "template" so it wouldn't be affected by the same things as good_template.

    When using templates, you need to set TemplateMissing, unless all of your fields are required. I also set "KeepLines" in the mail_options field.

    The only other thing I can think of is to change the following in the script: (Of course, make a backup first.) You can try these independently and see if it solves your problem, or you might need both changes.

    Change:
    Code:
    define("BODY_LF","\r\n");
    . . . to this:
    Code:
    define("BODY_LF","\n");
    . . . and this:
    Code:
    define("HEAD_CRLF","\r\n");
    . . . to this:
    Code:
    define("HEAD_CRLF","\n");
    ginger

  5. #5
    Join Date
    Oct 2008
    Posts
    3

    Default Re: $TEMPLATEDIR = Troubleshooting: The saga continues

    Thanks Ginger.

    I did set Def Alert. No errors messages in the webmaster email.

    The good url page works (I recognize it's not a template) and redirects me to my thanks page. This is important for my analytic reporting.

    I did set Template Missing at some point (I probably removed it before asking you to look again...to isolate results of my changes). I read other posts, I want the non-required fields in the results to be blank (not N/A or populated w/ anything else) I'll reset this.

    I'm not even sure if I want plain text or the html option. I need to experiment w/ both. I'll save a copy of the php file and try the changes you suggested to the code. If that doesn't work I'll purchase support. I just wanted to troubleshoot first and make sure I'm not missing somethig obvious.

    Again, thanks...I really appreciate your help. I'll let you know how I make out.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

     

Similar Threads

  1. Defining your TEMPLATEDIR path with Godaddy (Linux)
    By JacobF in forum HOWTO Guides and Tips
    Replies: 0
    Last Post: 02-May-2008, 03:19 AM
  2. No email delivery after $TEMPLATEDIR config
    By gofreeserve in forum Community Support
    Replies: 1
    Last Post: 08-Jan-2008, 08:02 AM
  3. Templatedir
    By cesar in forum FormMail Subscription Support
    Replies: 2
    Last Post: 14-Jun-2006, 11:32 PM
  4. error using $templatedir
    By smartie91 in forum Community Support
    Replies: 13
    Last Post: 11-Apr-2006, 04:49 PM

Bookmarks

Posting Permissions

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