f



sending PHP mail from my laptop?

I can set the host and port, but I don't see that there is anywhere to specify
the username and password for an email account on a remote server.

Is that do-able?
0
RJ_32 (18)
9/2/2008 3:18:30 AM
comp.lang.php 32646 articles. 0 followers. Post Follow

2 Replies
701 Views

Similar Articles

[PageSpeed] 8

RJ_32 wrote:
> I can set the host and port, but I don't see that there is anywhere to specify
> the username and password for an email account on a remote server.
> 
> Is that do-able?
> 

Not with the mail command.

However, the PHPMailer class as Micha suggests can handle such things 
(and more) for you.

-- 
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

0
jstucklex (14659)
9/2/2008 3:21:08 AM
Jerry Stuckle wrote:
> RJ_32 wrote:
>> I can set the host and port, but I don't see that there is anywhere to
>> specify
>> the username and password for an email account on a remote server.
>>
>> Is that do-able?
>>
> 
> Not with the mail command.
> 
> However, the PHPMailer class as Micha suggests can handle such things
> (and more) for you.
> 

yes, thanks, easy to use.

However, to enable SSL, I had to add to my php.ini:
extension=php_openssl.dll

and also to place a copy of that dll into the .../ext directory. It's
apparently already finding libeay32.dll because my system path still points to
the old PHP installation
0
RJ_32 (18)
9/2/2008 5:08:35 AM
Reply:

Similar Artilces:

php mail() not sending to mail Clients (ie, Outlook, Apple Mail, thunderbird, etc..)
I have a send mail script on my site that. The emails are recieved by gmail, and yahoo, but not to mail clients like Outlook, Mail, etc...) Is this a problem with the script, or is it something I must change in php ini file? Thanks in advance for any help. here is the code. (im using it in conjunction with javascript for some AJAX stuff) if(!isset($_GET['action'])) { die("You must not access this page directly!"); //Just to stop people from visiting contact.php normally } /* Now lets trim up the input before sending it */ $name = trim($_GET['name']); //The sen...

about send mail with php
Hello, I developed a PHP to send confirmation mail to my users. The users complainthat the mail goes to the SPAM section each time. What is the reason for this? I tested it several times, and I always get the same result. The mail always gets spammed. This is very bad because if a user doesn't get the confirmation, they won't even think that it's in their spam mail. The mail would therefore get stuck in their spam mail and I'll lose my clients. Looking forward to your reply. Thanks! On Fri, 26 Sep 2008 18:36:55 +0200, Marise wrote: > Hello, > > I developed a PHP to send confirmation mail to my users. > The users complainthat the mail goes to the SPAM section each time. > What is the reason for this? I tested it several times, and I always get > the same result. The mail always gets spammed. This is very bad because > if a user doesn't get the confirmation, they won't even think that it's in > their > spam mail. The mail would therefore get stuck in their spam mail and I'll > lose my clients. > > Looking forward to your reply. > > Thanks! > Host your website in a better neighborhood, maybe? -- Windows is a pane in the ass.... Marise wrote: > Hello, > > I developed a PHP to send confirmation mail to my users. > The users complainthat the mail goes to the SPAM section each time. > What is the reason for this? I tested it several times, and I always get > the same resul...

PHP Training Institute In Delhi, Live Projects on PHP. Short Term PHP Courses, PHP Scripts, PHP Training with Live Projects.
Vserve Global offers short term PHP: Hypertext Preprocessor Training Course, which is a widely used, general-purpose scripting language that was originally designed for web development, to produce dynamic web pages. It can be embedded into HTML and generally runs on a web server, which needs to be configured to process PHP code and create web page content from it. It can be deployed on most web servers and on almost every operating system and platform free of charge.PHP is installed on over 20 million websites and 1 million web servers. TOPICS:- >> Core PHP Language >> HTML, Cascad...

php send mail problem
Current, I have a function to send UTF-8 encoded HTML Format email to user. But my found that the produced email sometime accidently being injected with the ! sign....... e.g. <td> sometime become <!td> here is the code for that function $sql = "select * from user where userid='$userid'"; $res = send_sql($sql); //Get Reserve staff info $row = mysql_fetch_array($res); $fusername = $row["UserName"]; $femail = $row["Email"]; $message= ERNST."<html><body>"; $message.= "Hi ".htmlspecialchars($fusername).",&l...

PHP within PHP...
I took over the support of a website that is set up something like this inside one of the pages: include_once("header.php"); <?php //to get the content of the page they do this: $content = mysql_query("select content etc...); echo $content; ?> include_once("footer.php"); I am having problems evaluating any php that is used in the mysql content. Is there a way to get the mysql withing the mysql to run? Thank you for your time, Mandragon On Sep 17, 12:56 pm, Mandrago...@gmail.com wrote: > I took over the support of a website that is set up something like > this inside one of the pages: > > include_once("header.php"); > > <?php > //to get the content of the page they do this: > $content = mysql_query("select content etc...); > > echo $content; > ?> > > include_once("footer.php"); > > I am having problems evaluating any php that is used in the mysql > content. Is there a way to get the mysql withing the mysql to run? > > Thank you for your time, > > Mandragon Sorry, The question should read: "Is there a way to get the php withing the echo $htmlcontent to run?" Of course you are, $content is a resource. The MySQL Query resource. try this: $content = mysql_query('bla bla bla'); while ($row = mysql_fetch_assoc($content)) { $result[] = $row; } $content = $result; Now you can use $content ;). In answer to your edit... eval($co...

php to php obj
Hi All, Is there any tool to convert the .php files into its object files in deploying the files to other's server like java classes are deployed? Thanks in advance --AR John7481 <arjohn7481@hotmail.com> wrote or quoted: > Is there any tool to convert the .php files into its object files in > deploying the files to other's server like java classes are deployed? To what end? Do you want a PHP obfuscator? They tend not to be needed - since the code remains on the server. Do you want a PHP squeezer? Again - since PHP remains on the server that is of reduced importance. PHP obfuscators and squeezers are out there - but what exactly are you looking for? -- __________ |im |yler http://timtyler.org/ tim@tt1lock.org Remove lock to reply. With total disregard for any kind of safety measures Tim Tyler <tim@tt1lock.org> leapt forth and uttered: > John7481 <arjohn7481@hotmail.com> wrote or quoted: > >> Is there any tool to convert the .php files into its object >> files in deploying the files to other's server like java >> classes are deployed? > > To what end? > > Do you want a PHP obfuscator? They tend not to be needed - > since the code remains on the server. > > Do you want a PHP squeezer? Again - since PHP remains on the > server that is of reduced importance. > > PHP obfuscators and squeezers are out there - but what exactly > are you looking for? I think he'...

Problem with Mail()
In my PHP 5.0 at home, I'm using the following code to successfully write to a database and also send out an email. For some reason, when I take this code to work, it still writes to the database but doesn't send mail so we're (me and the I.T. guy) trying to find out whether it's the difference between PHP 4 or something else with email security. Does anyone here have experience with mail() in PHP 4 to know whether PHP 4 had issues with mail() that were fixed with PHP 5 ???? We've been chasing this from the mail server side at work when perhaps its some nuance between versions of PHP. Appreciate any help... Chris /* > $to = stripslashes($to); */ $to = stripslashes($to)."\r\n"; $subject = stripslashes($subject); $text = stripslashes($text); /* > mail('$to',$subject, $text); */ mail($to, $subject, $text, "From: admin@localhosthome.com"); cover wrote: > $to = stripslashes($to)."\r\n"; > Might or might not be the cause, but you should remove the trailing CRLF here. JW On Mon, 27 Feb 2006 22:33:57 +0100, "Janwillem Borleffs" <jw@jwscripts.com> wrote: >cover wrote: >> $to = stripslashes($to)."\r\n"; >> > >Might or might not be the cause, but you should remove the trailing CRLF >here. Thanks for the reply. I tried it after reading your post and no change... Thanks again, cover wrote: > In my PHP 5.0 at home, I'm using the following co...

php outside php (?)
Sounds weird, i know. What i want/wonder is the following: PHP can do the next: <?php if($foo == 'bar') { ?> Ow yeah, foo is bar! <?php }; ?> But how can i do the following: <?php $foo= ?> this is what foo looks like. <?php }; ?> This way i could edit the content of $foo in DW's design-view. I hope it's clear enough for you all to understand... Greetings frizzle. frizzle wrote: > But how can i do the following: > > <?php > > $foo= > > ?> > this is what foo looks like. > <?php > > }; > > ?> > > This way i could edit the content of $foo in DW's design-view. > I hope it's clear enough for you all to understand... <?php ob_start(); ?> this is what foo looks like. <?php $foo=ob_get_clean(); ?> -- Justin Koivisto - justin@koivi.com http://koivi.com Wow, little late on the reply, but i still wanted to thank you for your help. This is exactly what i meant, and it works great! :D Thanks again. ...

how to use the PHP path to send something explicitly to the PHP parser?
Hi. I'm messing around with some stuff in an .htaccess file. Among other things, I'd like to send my html files to the PHP parser. I'd also like to rewrite the urls using Apache mod_rewrite, so that the query string disappears, but the variables are still recorded. For all these tasks, I need to know the PHP path. When I run phpinfo, I see this listed as the Path: PATH /bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/usr/local/sbin I'm not sure how to use that infomation. Do I use all of it? Some of it? lkrubner@geocities.com wrote: > Hi. I'm messing around with some ...

Problem sending e-mail from PHP
I'm running FreeBSD 4.8 with Postfix and PHP. Postfix is working fine. I'm using a couple of PHP applications which fail to send mail. I can't find anything in the maillog. When using SMTP from PHP mail is being sent. I want the native PHP mail function to work properly. In my php.ini the sendmail_path points to the correct location for the postfix sendmail wrapper. The sendmail wrapper also works fine when used from a command line. Here are the relevant parameters for mail in php.ini [mail function] ; For Win32 only. #SMTP = localhost ; For Win32 only. #sendmail_from = me@localhost.com ; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). sendmail_path =/usr/sbin/sendmail -t -i Any hints on what the problem might be and how to solve it ? - Ron In article <bfv7t4$mam$1@news.hccnet.nl>, "Ron Bakker" <Ron.Bakker@hccnet.nl> wrote: > I'm using a couple of PHP applications which fail to send mail. > I can't find anything in the maillog. > [snip] > The sendmail wrapper also works fine when used from a command line. > [snip] > Any hints on what the problem might be and how to solve it ? chmod 4755 /usr/libexec/sendmail/sendmail Any luck? hth -- Bulworth : funha@fung.arg | My email address is ROT13 encoded, decode to mail --------------------------|-------------------------------------------------- <http://www.phplab...

Anyone here follows the mailing list php-general@lists.php.net?
I tried posting to it (I am subscribed and have posted to it successfully before, but this time I got this error message: >> This message was created automatically by mail delivery software. >> >> A message that you sent could not be delivered to one or more of its >> recipients. This is a permanent error. The following address(es) >> failed: >> >> php-general@lists.php.net >> SMTP error from remote mail server after end of data: >> host pair1.php.net [76.75.200.58]: 550 we're manly enough already WTH...

Why can't I send a mail with PHP
I can't send a mail with the following mail header: $headers = "MIME-Version: 1.0\n"; $headers .= "Content-type: text/html; charset=iso-8859-1\n"; $headers .= "From: \"User\" &lt;user@inter.net&gt;\n"; Therefore $headers is set to (echo $header;) MIME-Version: 1.0 Content-type: text/html; charset=iso-8859-1 From: "User" <user@inter.net> The mail has not been delivered and my PHP server says: [24-Nov-2005 00:37:19] PHP Warning: mail() [<a href='function.mail'>function.mail</a>]: SMTP server re...

Best PHP Training | PHP Development Training | PHP Training Institute
Tops Technologies provides php and mysql certification courses in ahmedabad, baroda, surat, Rajkot, Udaipur, Gujarat, india.PHP Training with MySQL is an introductory course in the PHP and MySQL technology. Mysql and php training course, php for beginners, sql training courses, PHP Training courses, php courses, mysql training courses, php mysql course. For More Details :- http://www.tops-int.com ...

Problem sending mail with sendmail and php
When i send mail using mail() in php i receive from my external smtp server a message such that: Sep 3 17:30:15 xxxxxxx postfix/smtpd[898]: NOQUEUE: reject: RCPT from unknown[yyyyyyyy]: 450 <apache@zzzzzzzzzz.uuu.hhh.it>: Sender address rejected: Domain not found; from=<apache@zzzzzzzzzz.uuu.hhh.it> to=<marco.pppppppppppppp@xxxxxxx.it> proto=ESMTP helo=<apache@zzzzzzzzzz.uuu.hhh.it> Where zzzzzzzzzz is name of the Linux machine uuu.hhh.it is the domain I need that sender is someone@uuu.hhh.it and not apache@zzzzzzzzzz.uuu.hhh.it Do you know where must i ...

sending mail from php and correct MS Outlook receive
Hello, In my MS Outlook I use global address book to handling contacts. When I send email from Outlook to myself and double click on sender I get information about me from my global address book. When I use php mail() function to sending messages and then double click on sender I get specificity message email window only. How do I have to prepare header at mail() function (for example: FROM: ???) that after send and double click on sender in Outlook I get information about sender from Outlook global address book ? Is it possible ? mail($to,$subj,$msg,"FROM: Some Name <user@domain...

How to send mail using php script on Windows XP?
I use xampp combo. How to write the code? I found that PEAR is already on my computer. I also found a sendmail folder in the xampp folder. -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Phper wrote: > I use xampp combo. How to write the code? I found that PEAR is already > on my computer. I also found a sendmail folder in the xampp folder. hello, well I would suggest you write some more text with some more information. With more information we can help you a lot more. Anyway here is some script: http://lmgtfy.com/?q=phpmailer regards, johannes ke�ler -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.11 (GNU/Linux) iEYEARECAAYFAkp/260ACgkQE++2Zdc7EtfMiACeP6GuQ6njcnJvpBh8XBVah2gR dpgAn3ENLwEQJpNev+18wXDPkMbrl3fd =TP0O -----END PGP SIGNATURE----- Phper wrote: > I use xampp combo. How to write the code? I found that PEAR is already > on my computer. I also found a sendmail folder in the xampp folder. The same way you do on any system - with the mail() function (or, as a package such as phpmailer which calls mail() eventually). You do need an MTA installed on your system; you can use the one which comes with Windows (depending on your version) or one of the free or non-free ones available. -- ================== Remove the "x" from my email address Jerry Stuckle JDS Computer Training Corp. jstucklex@attglobal.net ================== Jerry Stuckle wrote: > Phper wrote: >> I use xampp combo. How to write the code? I found that PEAR is al...

how to send mail in php and check whether ir rebound or not
hi i am building aan application which will send mail to user when he registers on my site and i am checking whther the email id is working properly or not by sending his email and then cheking whether the email was rebound or not. i know something about how to send email in php using mail function but not everything about sending email. i don't know anything about how can i check whether the email rebound or not. also tell me about sending email using php what considerations should be kept in mind when sending email. pls help me thxs for your help in advance. I noticed that Message...

sending mail from winxp os ,apache ws, php
I have windows xp pc and i have installed apache as a web server and php also working fine, but when i am sending mail, its giving me following error when upload same to linux live server its working, please help me what do i have to do for this Warning: mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in C:\Safras\WebHosting\netoffice.cybersoft.lk\functions.php on line 377 Warning: mail(): Failed to connect to mailserver at "localhost" port 25, verify your "SM...

Trouble with sending e-mail from simple php script
I have a simple form which is handled in a *.htm file by <FORM METHOD="POST" ACTION="send_msg.php"> <PRE> Your name <INPUT TYPE="text" NAME="name" MAXLENGTH=35 SIZE=50> Company <INPUT TYPE="text" NAME="orgn" MAXLENGTH=60 SIZE=50> City and country <INPUT TYPE="text" NAME="locn" MAXLENGTH=60 SIZE=50> Your e-mail address <INPUT TYPE="text" NAME="emad" MAXLENGTH=60 SIZE=50> Your message <TEXTAREA NAME="question" WRAP=VIRTUAL ROWS=5 COLS=45></TEXTAREA> <INPUT TYPE="submit" VALUE="Send message"> </PRE> </FORM> Then the send_msg.php should send the e-mail by the following code (but does not send e-mail). What am I doing wrong? <?php $date = date("F jS Y, h:iA"); if ($name == "" && $question == "") {exit;} $host=@gethostbyaddr($REMOTE_ADDR); $headers = "From: postmaster@domainname1.org \r\n"; $headers .= "X-Mailer: PHP \r\n"; if(mail("myusernamehere@gmail.com", "Comments from someone.", "$host on the contacts page at $date \n --- \n $name from $orgn, $locn ($emad) wrote:\n\n $question", $headers)) { $msg = "Thank you"; } else { $msg = "Message not sent"; } echo $msg; ?> <html> <head> <title...

Does PHP need the .php extension ?
Hi guys, When I use PHP I give my file the .php extension. I always wondered if it could be an .htm page with a <script> block that the PHP resides in, the same way you would do JavaScript. If you can do it that way are there any benifits to that method ? Take care, Cyrus "Cyrus D." <satan@invalid.org> writes: > Hi guys, > > When I use PHP I give my file the .php extension. I always wondered if it > could be an .htm page with a <script> block that the PHP resides in, the > same way you would do JavaScript. If you can do it that way are the...

PHP does not parse .PHP files
I have this problem with PHP that someone might be able to help. With CLI, I am able to execute my .php files. For example, if I type "php phpinfo.php" , this works fine on my system. If I put the phpinfo.php file is in /var/www/html and I try to access it through the browser, I get the content of the file and not the execution of the file. Instead of display the info of PHP, I got the text of the file as: <?php phpinfo(); ?> Why? Thanks Phong Ho wrote: >I have this problem with PHP that someone might be able to help. > >With CLI, I am able to execute my ....

php://memory and php://temp
http://php.net/manual/en/wrappers.php.php per the documentation: php://memory and php://temp are both listed under "Allows Appending" what am I missing / what's the point? They only seem to work with read/write modes such as fopen('php://memory','rw'); closing the handle, or trying to open another handle without closing the first essentially erase the contents... so what's the point of fopen('php://memory','a') ? you'll a) be appending nothing, b) no way to read what you just wrote? sure would be nice if you could $fh = fopen('php://memory', 'w'); fwrite($fh, 'test string'); fclose($fh); $fh = fopen('php://memory', 'r'); $result = fgets($fh,2048); fclose($fh); echo $result; On 10/12/2010 9:44 PM, BKDotCom wrote: > http://php.net/manual/en/wrappers.php.php > per the documentation: php://memory and php://temp are both listed > under "Allows Appending" > > what am I missing / what's the point? > > They only seem to work with read/write modes such as > fopen('php://memory','rw'); > > closing the handle, or trying to open another handle without closing > the first essentially erase the contents... so what's the point of > fopen('php://memory','a') ? > you'll > a) be appending nothing, > b) no way to read what you just wrote? > > sure would be nice if you could > > $fh = ...

PHP with Indian PHP Developers
Dear all, If you want to make a PHP web application, or need to <a href="http:// www.virtueinfo.com/php-developers/hire-php-programmers-developers-india.htm">Hire PHP Developer</a>contact a leading <a href="http://www.virtueinfo.com/ php-developers/php-web-development.htm"> PHP Web Development Compnay</ a> <a href="http://www.virtueinfo.com/php-developers/php-web-programming- php-developers-india.htm">Offshore PHP web development India</a> On Thu, 25 Feb 2010 01:37:02 -0800 (PST), Virtue Info wrote: > Dear all, > > > If you want to make a PHP web application, or need to <a href="http:// > www.example.com/php-developers/hire-php-programmers-developers-india.htm">Hire > PHP Developer</a>contact a leading <a href="http://www.example.com/ > php-developers/php-web-development.htm"> PHP Web Development Compnay</ > a> > > ><a href="http://www.example.com/php-developers/php-web-programming- > php-developers-india.htm">Offshore PHP web development India</a> > Third time's the charm? Not exactly a ringing endorsement of the skills you've got available or your testing method reliablity... -- 12. One of my advisors will be an average five-year-old child. Any flaws in my plan that he is able to spot will be corrected before implementation. --Peter Anspach's list of things to do as an ...

php notification through php sdk
Hi there I want to build a e-commerce website similar to wish.com and I have chosen opencast as my framework of choice. Now wish has a feature that when you save a product in wish and if you are logged in with Facebook or gmail all of your friends will get a notification that your friends has saved a item on wish. I want a similar feature on my site Now I know Facebook provide a sdk JavaScript and php and wish might be using something similar but I am using open cart can I open home page or product page in the sdk Thanks On 3/20/2015 7:30 AM, apoorv.kanungo@gmail.com wrote: &g...

Web resources about - sending PHP mail from my laptop? - comp.lang.php

Sending/receiving relationship - Wikipedia, the free encyclopedia
A sending/receiving relationship is one in which a public school district sends some or all of its students to attend the schools of another ...

U.K. Woman Faces 20 Months For Creating Fake Facebook Accounts, Sending Herself Abusive Messages
A woman in Cornwall in the U.K. came up with a creative way to use Facebook to accelerate a family spat, and it earned her 20 months in prison. ...

CHVRCHES - Dear guys, Please stop sending us emails like... - Facebook
Dear guys, Please stop sending us emails like this. This is one of the more polite ones. Other recent classics include "I'm going to give her ...

Facebook Sending Perez Hilton More Traffic than Google, Driving 3.3% of All US Traffic to Video Sites ...
For media companies evaluating their Facebook marketing strategy , here’s an interesting sign of the times: web analytics firm Hitwise is reporting ...

A better experience for sending Tweets and DMs - Twitter Blog
... panel New Tweet panel in da...... Skip to main content Blog Got an account? Sign in Search form Search &nbsp A better experience for sending ...

How to Go From Working 60 Hours a Week to 40 By Sending 2 Emails a Week
I’m convinced 95% of cubicle workers who work over 60 hours a week constantly can cut it down to 40-45 hours by sending 2 emails a week to their ...

Live Emoji - sending GIF Animation Emoji for Zoosk,Skype,Kik,Whatsapp,Facebook Messenger Etc. on the ...
Get Live Emoji - sending GIF Animation Emoji for Zoosk,Skype,Kik,Whatsapp,Facebook Messenger Etc. on the App Store. See screenshots and ratings, ...


Cynthia McKinney - responds to Obama on sending troops into Afghanistan - Debate Answer - YouTube
Cynthia McKinney, Green Party Presidential candidate, responds to Barack Obama on his support for sending troops into Afghanistan. Based on his ...

'Shark' providers sending unskilled workers to high-risk sites, say trainers
&#8203;West Australian training companies say dodgy providers they describe as 'sharks' and 'cowboys' are flooding high-risk mine sites with ...

Resources last updated: 3/23/2016 5:48:18 PM