+ Reply to Thread
Results 1 to 10 of 10

Thread: Trouble with INI file.

Hybrid View

  1. #1
    Join Date
    Jan 2012
    Posts
    3

    Default Trouble with INI file.

    Hi,

    I have followed the How To Guides read all the documentation but to no avail I can't seem to get an .ini file to work. I constantly get an error message stating "The following error occurred in FormMail: bad_ini" It then states "Error=The FormMail INI file"http://mysite.org/folder/file.ini" has a syntax error"

    I've been at this for three days and no matter what I do I can't get this to work.

    The file.ini looks like this
    [email_addresses]
    chelp="cubhelp@mysite.org"

    I have no clue what is wrong. Can someone help?

  2. #2
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: Trouble with INI file.

    first, don't use a URL for ur INI file path

    use a filesystem path - use the "testalert" test to help find the right path

    second, check that the file is readable by "everyone" - rw-r--r--

  3. #3
    Join Date
    Jan 2012
    Posts
    3

    Default Re: Trouble with INI file.

    Crabtree,

    You were spot on, the INI file works now.

    I do have one issue that isn't working though. I'm using an alias in the command

    <input type="hidden" name="email" value="alias" />

    trying to display a 'From' email address to the recipients. But when I use the 'alias' the from email address in my email is displayed as "alias@webhostingcompany.com" but if I use any email address in the form of "me@anydomain.com" the 'From' field in the recipients emails displays as "me@anydomain.com". So in other words a "Alias" will not work when used in <input type="hidden" name="email" value="alias" />

    The INI file is

    [email_addresses]
    alias="me@anydomain.com"

    Can anyone explain what is happening or am I trying to do something that isn't possible?

    Thanks in advance!!!!

    DLR

  4. #4
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: Trouble with INI file.

    so, the "email" field is supposed to be input from the form - it's the address of the person filling in the form

    the "recipients" is u - the owner of the form

    it makes no sense to set the "email" field to anything other than an input on the form.

    sometimes email servers refuse to send email from outside ur domain - in this case u can tell formmail to set the from address using a "mail_options" feature called "FromAddr". Do that if u need to, but don't try to set the "email" field.

  5. #5
    Join Date
    Jan 2012
    Posts
    3

    Default Re: Trouble with INI file.

    Crabtree,

    I did as you said and again you're the man, works like a champ!!! Before you helped me get the INI file to work I tried to use "FromAddr" and it only worked for the error reporting emails to me via DEF_ALERT and not for recipients of a successful form. But all is well now and I hope it stays that way!!

    Thanks again Crabtree!!

    DLR

  6. #6
    Join Date
    Mar 2012
    Posts
    21

    Default Re: Trouble with INI file.

    How do I find instructions as to "How to make and ini file"
    I have the formmail working on my site but I would like to be able to totally hid my email address.
    Can anyone point me in the right direction
    Maggie

    PS I am totally new to php so please be gentle.

+ 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. Using the ini file
    By additude in forum Community Support
    Replies: 4
    Last Post: 18-Jan-2009, 11:41 AM
  2. Trouble with file attachments
    By dlpreston18 in forum Community Support
    Replies: 0
    Last Post: 18-May-2007, 12:25 AM
  3. Trouble with file attachments
    By dlpreston18 in forum Community Support
    Replies: 0
    Last Post: 18-May-2007, 12:18 AM
  4. Trouble with the formmail ini function
    By Carina in forum Community Support
    Replies: 3
    Last Post: 17-Sep-2006, 03:48 PM
  5. formmail trouble html or php file not sure
    By putertfix in forum FormMail Subscription Support
    Replies: 5
    Last Post: 25-Oct-2004, 09:11 AM

Tags for this Thread

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