Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    PHP


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





How To Connect To A (mail) Server?


Can anyone tell me/show me how I can connect to a (mail) server?




View Complete Forum Thread with Replies

Related Forum Messages:
Connect To Mail Server
I got this script from a tutorial somewhere, its for conecting to a mail server and reading a list of the messages there. but for some reason it wont work. at all. the page just stays blank. (white). PHP Code:

View Replies !
Connect To Pop3 Mail Server
I have a piece of code that connects to a mail server running on the same machine. It all works fine but it just takes an age to connect to the mail server, like 30 seconds or so.
Looking at the log for the mail server, I noticed the following lines at the beginning of each request:

[Date / Time] CAPA
[Date / Time] -ERR Unknown Command
[Date / Time] AUTH
[Date / Time] -ERR Unknown Command

Could this be the reason that it takes so long to connect to the mail server? And if so is it possible to suppress certain commands sent to the server if they are not required?
The PHP code I use to connect is simply:

$mbox = imap_open ("{mailserver:110/pop3}INBOX", "username", "password");

And then imap_close($mbox); to clean up.

View Replies !
Use Fsockopen To Connect To Pop3 Mail Server
I am writing a application which use fsockopen to connect to pop3 mail server and check mails. It works fine for me. But, Now i am having problem with checking same server.

I mean when i try to connect to example.com from a script running at http://www.example.com/myscript.php it doesn't connect to server gives

PHP Code:

View Replies !
Mail Function - Can Not Connect To The SMTP Server
My host did something a couple of months ago to their mail server to make it more secure. YOu now have to delare more variables or something. NOw my PHPlist will not work because it can not connect to the SMTP server or something like that.

JUst wandering if any of you have run into the same problem and could tell me how to fix it?

View Replies !
Connect To The Server With A Password And Username And Then Allow Mail() Commands Normally.
It is with smtp authorization. I have been told that it is not possible. But I saw a script that made it possible. But I have users that have directories on my site and would like them to be able to use the mail() function without a complicated script.

My plan was, to find some way to connect to the server with a password and username and then allow mail() commands normally.

This file would be in the include directory so all the users would need to do is have a require('mail.php'); before their mail script and it would work. Does anyone know how to do this, Or can you refer me to a free mailer that doesnt use authorization?

View Replies !
Failed To Connect To Mailserver - Config Settings For The Mail Server
I am trying to send an email through a web form but I am getting an error. I am trying to use windows xp on my local machine.

Warning: mail() [function.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:wampwwwsendmail.php on line 19

Can someone tell me how to fix this. Here are my config settings for the mail server.....

[mail function]
; For Win32 only.
SMTP = localhost
smtp_port = 25

View Replies !
How To Connect Remote Site - Can't Connect To MySQL Server
Lets say, i have two php sites named Site-A and Site-B. I want to use MySql
Datbase of Site-B for Site-A.

Generally i use :

$Host="localhost";
$User="username";
$Pass="password";
$DB="databse";
mysql_connect($Host,$User,$Pass);
mysql_select_bd($DB);

When i connect to Site-B database from Site-A what will be the $Host name?
I have tried with: $Host="www.mysite.com";

but it shows the warning:
Warning: mysql_connect(): Can't connect to MySQL server on....

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver
Why do i keep getting this error:

Warning: mail() [function.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:wampwwwproject_upload Code:

View Replies !
Mail() [function.mail]: Failed To Connect To Mailserver
i need to know how to enable my mail function i have change my ini to localhost port 25 and enabled emnail but nothing is changing anyone experienced this problem before.

View Replies !
Mail Problem - Warning: Mail() [function.mail]: SMTP Server Response: 550 Invalid Recipient:
Whenever the recipient's email address includes a hyphen ( - ), I get the following error message...

Warning: mail() [function.mail]: SMTP server response: 550 Invalid recipient:

I should stress that this only seems to occur when the hyphen is in the URL portion of the address, i.e example@perfect-example.com

The current code works along the lines of...

mail ($_POST['email'], 'Email subject is here', $body, $headers);

View Replies !
Could Not Connect To MySQL: Can't Connect To Local MySQL Server Through Socket
To connect to a MySQL database, hosted on my machine, an iMAC G5 with OS 10.4, I am using the following code:

$dbc = mysql_connect ('localhost', 'guestuser', �')
OR die ('Could not connect to MySQL: '.mysql_error() );

However, I receive an error message: Could not connect to MySQL: Can't connect to local MySQL server through socket '/var/mysql/mysql.sock' (2). MySQL server is running, and user name/password are valid.

View Replies !
Connect To MySQL - Can't Connect To Local MySQL Server Through Socket
I've finished coding php, run it localhost and uploaded to my Apache server with Linux OS. However, I'm seemingly unable to connect to mysql at the server side. and received the following message: Could not connect to database: Can't connect to local MySQL server through socket '/tmp/mysql.sock'(111) What's this message abt? I tried to get into MySQL without php on the server. and received the same message at the console.

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver At "localhost" Port 25
Warning: mail() [function.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 send.php on line 9

Warning: Cannot modify header information - headers already sent by (output started at send.php:9) in send.php on line 10

why this warning and error coming when i am using this cording help me to solve this problem.

View Replies !
Warning: Mail() [function.mail]: Failed To Connect To Mailserver At "localhost"
Warning: mail() [function.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 D:SitescsitechsorderEmail.php on line 97

View Replies !
Connect To A Pop Server Before Use The Smtp Server
A mail sent from a host to my smtp server is refused. This happens
because you have to connect to a pop server before you can use the
smtp server. Does anybody have any code to achieve this (PHPmailer doesn't work)?

View Replies !
Mail() Connect Error
im having some trouble getting the mail() function to work. this is the error message returned:

Warning: Failed to Connect in c:/apache/apache/htdocs/turkey/turk_login.php4 on line 36

line 36 is where the mail() function is written. i am using win98 with apache and these are the settings for the mail function in my php.ini

SMTP = localhost
sendmail_from = admin@localhost.com

View Replies !
Php Mail() Problem - Warning: Mail(): Failed To Connect To Mailserver At "localhost" Port 25, Verify Your "SMTP"
I used dreamweaver as a tools for php coding..and Im using php version 4.3.3, Apache 2.0.47(win32) and MySQL as database. I found a problem with php mail() and the error says like 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().

View Replies !
Connect To Remote Server
I want to connect To Remote Server through my site done in php.
I got some file but it is in vbscript.
can anyone help me out for this file.

View Replies !
I Cant Connect To My Apache Server
I installed php-4.3.3, mysql and apache server 2.0.47.
but I can not connect to my apache server from my other computer, i use
static ip for my server, set ip address for server name on httpd.conf,
setup sua server on router. do i miss something here?

View Replies !
Connect To Php3 Server
I'm trying to write a small application that should connect to a pop3 server, and download all mails, but I'm having some small problems. I've checked the php manual, and what I have understood I should use is the imap_open() function? I've tested:

$inbox = imap_open("{mail.test.com/pop3:110}",
"test", "test") or die("Error");

echo "It Works!!";

But I get an error message that says that the imap_open() function doesn't exist? My phpinfo() says that mod_imap is a loaded Apache module. What am I doing wrong? And how can I fix it?

View Replies !
Connect To Db On Remote Server By Php
how i connect to db on remote server by php?

View Replies !
Can't Connect To SQL Server Via ODBC
I just installed PHP 5.1.4 with SQL Server 2005 on my laptop. PHP is
running fine and so is SQL Server 2005. When I try to connect to SQL
Server from my my PHP code I get this error.

Warning: odbc_connect() [function.odbc-connect]: SQL error:
[Microsoft][ODBC Driver Manager] Data source name not found and no
default driver specified, SQL state IM002 in SQLConnect in
C:Inetpubwwwrootindex.php on line 5

Here's my connection string that is causing the error

$connect_id = odbc_connect("Driver={SQL
Server};Server=mydbname;Database=myDB","myUser", "myPass");

View Replies !
Connect To A Database On An Other Server?
Is it possible to connect to a database on an other server? if yes how.

View Replies !
Using PHP To Connect To MYSQL Server
I am new to PHP and MYSQL. I recently installed both PHP and MYSQL (the community edition) on my computer and I have been trying to use PHP to connect to and access MYSQL (instead of using the MYSQL command line).

I used the mysql_connect() function on a test script but I am getting the following error message when I test the script.

Warning: mysql_connect() [function.mysql-connect]: Access denied for user ' '@'localhost' (using password: YES) in filename on line 10.

I understand that I am being denied access because I have not submitted the right credentials. However, I am testing this code on my local computer where I have full privileges. What might be the reasons I am getting this message? What are the possible solutions? Do I need to configure mysql such that it recognizes that I am using it on a local computer?

View Replies !
Connect To Apache Server
i need a script that can access files from my machine to another (remote)machine.

how do i go abt it. Connect to the Apache server tha's running from a remote computer?

View Replies !
Can't Connect To MySQL Server
I am getting this error, while try to connect to mysql, what might be the problem, I tried to download other version, all are giving me the same error.

ERROR 2003: Can't connect to MySQL server on 'localhost' (10061)

How can I correct it?

View Replies !
How To Connect To MS SQL Server Database With PHP
Could someone please explain to me how to connect to MS SQL Server Database with PHP. How does ODBC work and how is it actually setup?


View Replies !
Connect To A MSSQL Server
I am using PHP to connect to a MS-SQL Server.

In my SQL statement this snippet of code is giving me error:

... DATEPART(m, Changedate) ...
more statements...

I looked at online docs -Microsoft, the syntax is correct as far as I could tell, but this is where the SQL errors out...

The variable Changedate is a date and time column as:
2003-11-30 00:00:00

View Replies !
Mysql_connect - Can't Connect To The Server
i have installed Apache 2.0.52 + mysql 5.0.16 + php-5.1.0 + phpMyAdmin 2.6.4-pl4 exactly how it is described at but i can't connect to the mysql server. for example this script that i wrote only prints "1" And thats why i think that i can't connect to the server

<?php
echo "1";
$db = mysql_connect("localhost");
echo "2";
.....
?>

View Replies !
Connect To MySql Server
I have MySQL database in my web server. Now I have to create a form (in my website)to allow user enter data and then the data will be store in the MySQL database. In the same website, the data in the database will be display out for other user.

Can I know, how to connect my website to the database when user enter their data? Any guide or example? Any tutorial?

View Replies !
Connect With The MySQL From A Different Server
I need connect with the MySQL from a different server, if tried everything and it's still not letting me, through cpanel I allowed the host to access the mysql, and I'm trying to connect like this:

mysql_connect("11.111.1.111", "username", "password");

it's returning the error:

"Warning: mysql_connect(): Lost connection to MySQL server during query in /home/awesomea/public_html/csp.php on line 6" iv'e also tried connecting to ports: 11.111.1.111:3306 and its returning the same error.

View Replies !
Connect To Database From Another Server
the correct procedure to connect to a mysql database on another host? I have 2 websites on different hosts (servers) and would like to use the records stored on one database on another website. I used

$db_host= "www.mywebsite.com" instead of "localhost" and it worked fine for a day now it gives me a 'Lost connection to server' error constantly.

View Replies !
Connect To Exchange Server
I need to connect to MS Exchange Server and get any email with
attechments. Use of IMAP and POP3 are not allowed on this Exchange
Server.

Have anybody any idea, how can I resolve this problem with PHP?

View Replies !
Mail() Failure To Connect To Mailserver
I have wrote a simple mail script which was working fine - when I moved it to a different server I get the error: -

Warning: mail() [function.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 E:homeproject32sendmessage.php on line 219 code:

View Replies !
Send Mail By Connect PHP To Ms Outlook?
how can we send mail by connect PHP to ms outlook?

View Replies !
Connect An External Database Server With PHP
I Have two server, one in USA and one in Indonesia. I decide to apply mirror system for my portal.

The problem are, how my server in USA connect mysql server in my server in Indonesia?

View Replies !
How To Connect MSSQL In Remote Server
I try to connect my mssql DB in remote server from localhost.
But it fails to connect.

The connection succeed only if i connect a mssql DB present in localhost.

I can guess, this is due configuration settings in MYSQL my.ini

But i dont know what necessary changes to be made inorder to connect a mssql
DB in remote server from the localhost.

View Replies !
Can't Connect To Remote MySQL Server Using PHP
i am trying to connect to a remote mysql server through php. Here's the
code:

mysql_connect("my.hostname.edu", "username", "password") or die
(mysql_error());
mysql_select_db("db_name") or die ("unable to select
db".mysql_error());
$r1 = mysql_query('SELECT * FROM table') ;

Using the mysql prompt on the remote server, the mysql -h -u -p works
just fine with the parameters i've specified here. According to the
user table I have the proper permissions. I just can't figure out what
could be preventing the connection here, although I am no expert...can
anyone help?!

BTW, I am using PHP 4.4.1 and mysql 5.0.

View Replies !
How Do I Connect Php With Oracle Database Server
Am using wamp. How do I connect php with oracle database server? Can any one help me?

View Replies !
PHP With MS SQL 7 Server Service Pack 4 - Cannot Connect
I have PHP 4.3.1.1 running on Windows 2000 Server with IIS 5. This
connects to an MS SQL 7 server running on a seperate NT4 box.
Recently, this SQL7 Server had SQL7 Service Pack 4 applied to it.
After this Service Pack, the PHP apps could no longer connect to the
database.

Warning: mssql_connect() [function.mssql-connect]: Unable to connect
to server: <mySQLServer> in <myPHPapp.php> on line 12.

From what I understand, SP4 broke something in named pipes
connections, and the fix is to update the client to MDAC 2.7 or later.
This update was applied to the PHP server, but PHP still cannot
connect.

Anyone else run into this?

View Replies !
Ldap-start-tls To Connect To AD Server
I try to use ldap-star-tls to connect to a win2003 domain controller and
browse AD.

$ds = ldap_connect("ldap://$ad_server/") ,"389"); // Connect to an LDAP
server
echo $debug?"<BR>LDAP Connection handler:$ds<BR>":"";
if ($ds == 0) {
echo "<H1>Cannot connect to LDAP server to authenticate</H1>";
echo "<H3>Use the browser back button to continue</H3>";
exit;
}
else {
if (!ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3)) {
die ("Failed to set LDAP Protocol version to 3, TLS not
supported.");
}
if (!ldap_start_tls($ds)) {
die ("Ldap_start_tls failed");
}
if (ldap_bind ($ds, $serv_user, $serv_pass)) { # Bind Ok

The result is:
LDAP Connection handler:Resource id #2

Warning: ldap_start_tls() [function.ldap-start-tls]: Unable to start TLS:
Connect error in C:WEBROOTad.php on line 30
Ldap_start_tls failed

View Replies !
Connect To Remote MySQL Server
I have a fully functional page hosted on my PC that uses PHP and
connects to MySQL on my PC to generate it's code.

I now have some web hosting available which includes both PHP and MySQL
support, however the webhost is still in the process of getting the
MySQL support activated and functional.

I therefore have uploaded my webpage to the host and edited the webpage
code to access the MySQL server on my home PC - once the host gets
MySQL working then the webpage will of course use the MySQL that my
host will provide.

The original code in my webpage to connect to MySQL is:

$panorama_database=mysql_connect(localhost,$userna me,$password) or
mysql_fail("Unable to connect to MySQL database.");

I have edited this to:

$panorama_database=mysql_connect(ļ.207.???.???: 3306',$username,$password)
or mysql_fail("Unable to connect to MySQL database.");

(My IP masked by ?).
And it's works no problems - however i have a dynamic IP address and
wish to replace the hardcoded IP address with an alias from
www.no-ip.com.

So i tried both:

$panorama_database=mysql_connect('http://mynoipalias.no-ip.org:3306',$username,$password)
or mysql_fail("Unable to connect to MySQL database.");

and (with no port specified):

$panorama_database=mysql_connect('http://mynoipalias.no-ip.org',$username,$password)
or mysql_fail("Unable to connect to MySQL database.");

Both attempts to use my www.no-ip.com alias fail and i'm not sure where
to look for logs to debug the problem.

View Replies !
Cannot Connect To MySQL Server Using PHP On Localhost
I have set up MySQL on my home computer, and I am writing a PHP enabled web
site to run queries on this database.

I have created a database called 'weather' on mysql that I want to access
via my website.

I have also created a user with a password (this isn't the real one, but
I'll use this to illustrate my point)
User: carlotam
Password: blah
Host: localhost

To which user I have granted all on database weather.

Using a PHP call: I try:

$username="carlotam";
$password="blah";
$database="weather";
$host="localhost";

$var = $_POST['topic'];

echo "<center><h1>ESCape Database Query</h1></center>";
echo "You have queried <b>$var</b><br><br>";
echo "Your database is: <b>$database</b>.<br>";
echo "Your username is: <b>$username</b>.<br><br>";

mysql_connect($host, $username, $password);
@mysql_select_db($database) or die("Unable to select database
<b>$database</b> on <b>$host</b>.");
mysql_close();

And I keep getting the message "Unable to select database weather on
localhost."

Is there something wrong with the above, or is there something wrong with my
MySQL server configuration? My server is up and running, so I was wondering
if anybody can help with this problem?

If this information helps: I am running MySQL 5.0.15 server on a PowerMac G4
laptop. And yes, I did check to see if the server was running before I
checked the code.

View Replies !
Cannot Connect To Remote MySQL Server
Ok, I have done this MANY times before without a problem - so I don't know WHY this isn't working!

I am in the process of moving to a new server - so I am updating my mysql_connect statement to use our NEW server instead of the current one (@ localhost).

I went into MySQL on the NEW server an added two new users - same username - one for the domain name of our current/old server and one for the IP address of our current/old server ... and gave the users the appropriate rights. I then updated my "mysql_connect" statement to point to the NEW server... but I get the following error:

View Replies !
Code To Connect To A SMTP Server?
Is there anyway, while using the mail function in PHP, to write some code to connect to a SMTP server? I have a form for my website but it is not sending me the results when it is filled out and the only conclusion i have is that the site cannot connect because of authentication problem.

View Replies !
Connect To Mysql Through Proxy Server
How exactly would I set up a connecton to mysql in php, but through a proxy server and a port #.   

proxy.shr.secureserver.net   on port 3128

I have no idea where to start, so Here's my code:

View Replies !
Windows PHP Connect Into LINUX Server
I want to built a windows php website---> connect to the linux box--->read all settings value from the .ini files->display it into the php website->user can then change the values->save the .ini file base on the user modification close the file-->for back up reason of settings, also save the values into SQL database. I also need to reboot the linux box after apply changes to the .ini.

Anyone knows how to approach this problem? What do I need? Does php have a built in ssh?

View Replies !
Unable To Connect To Database Server
I am trying to install a PHP script on my server and get the following error message. I replaced username, directory, and folder name for security reasons.

---------------------------------------------------------------------------
Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'nobody'@'localhost' (using password: NO) in /bhome/username/directory/directory name/includes/functions/database.php on line 12 Unable to connect to database server!
-------------------------------------------------------------------------

Here is the DB Privileges. I subbed the personal data. Code:

View Replies !
Connect And Send Commands To Server?
I'm trying to create a user online detection script using PHP for a game I play. I have the commands that need to be sent to the server, I was just wondering how I could go about connecting to a reote server, and how I would go about sending commands to it.

View Replies !
A NuSoap Client That Will Connect To A C# Server
I am trying to write a NuSoap client that will connect to a C# server. I am getting the error "HTTP Error: cURL ERROR: 56: SSL read: error:00000000:lib(0):func(0):reason(0), errno 104". This is my code:

View Replies !
Code To Connect To SQL-server Database.
PHP-code to connect to SQL-server database.

View Replies !
Warning: Failed To Connect When Trying To Send Mail.
I have followed many tutorials but keep getting this message. PHP Code:

View Replies !

Copyright © 2005-08 www.BigResource.com, All rights reserved