|
Posted by John Murtari on 08/28/07 16:22
shror <shahirwm@gmail.com> writes:
>>
>> > I want to add to my website php.ini file to change the settings of my
>> > mail() function so that my function is working fine except that the
>> > sender email is not my user but nob...@hostingprovider.com so Someone
>> > told me that its easily edited using php.ini but he dont know how, so
>> > I thought that you could help me in this situation.
>>
>> > more details about my hosting:
>> > - Linux host
>> > - php 4.4.6
>> > - apache
>>
>
> I tried to add from in my code but its not working so i thought of
> using the php.ini
> I thought that if i added php.ini to my root directory (inside /
> public_html/) things will work fine???
>
> anyway thanks for your info I will try on changing my code once more
> to check it again
>
Okay, in the php.ini the setting is as follows:
sendmail_from = me@localhost.com
But this should just be a default if you don't specify. I
doubt the hosting provider will change it on their servers. In your
local .htaccess file you may be able to give the variable a new value
(but I'm not sure). You would not have local php.ini, the system
won't read it as long as the provider has one installed.
Like the other guy, your best bet is just to get the
From part of the mail function working. You shouldn't have any
trouble setting the from there (the fourth parameter allows
you to add additional headers):
mail($msgTo, $msgSubj, $msgTxt, "From: $msgFrom")
Best regards!
--
John
___________________________________________________________________
John Murtari Software Workshop Inc.
jmurtari@following domain 315.635-1968(x-211) "TheBook.Com" (TM)
http://thebook.com/
[Back to original message]
|