Re: mysql_connect noob question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Completely different function call().

mysql_connect() - the port is part of the host.

*server*

The MySQL server. It can also include a port number. e.g. "hostname:port"
or a path to a local socket e.g. ":/path/to/socket" for the localhost.

If the PHP directive
mysql.default_host<itss://chm/res/mysql.configuration.html#ini.mysql.default-host>is
undefined (default), then the default value is 'localhost:3306'. In
SQL
safe mode <itss://chm/res/ini.core.html#ini.sql.safe-mode>, this parameter
is ignored and value 'localhost:3306' is always used.


mysqli_connect() - the port is a parameter.



I think you got the answers to the question you asked.




On 23 April 2013 18:14, Jim Giner <jim.giner@xxxxxxxxxxxxxxxxxx> wrote:

> On 4/23/2013 10:39 AM, Glob Design Info wrote:
>
>> Well all, it turns out the *correct* answer to my question, which no one
>> answered, and which only degenerated into a kindergarten-like argument is:
>>
>> "You need to add the port # to the *end* of the mysql_connect() call".
>>
>> i.e.:
>>
>> $link = mysqli_connect( $host, &user, pass, $database, $port );
>>
>> Glad to see the maturity level of posters on this list, as in most of IT
>> these days is that of a bunch of squabling 5-year olds.
>>
>> On 4/23/13 5:47 AM, Tedd Sperling wrote:
>>
>>> On Apr 21, 2013, at 3:33 PM, Glob Design Info <info@xxxxxxxxxxxxxx>
>>> wrote:
>>>
>>>  What question did I not answer?
>>>>
>>>
>>> That proves that you're not listening -- you are total waste of time
>>> for anyone trying to help.
>>>
>>> Welcome to my ignore file.
>>>
>>> tedd
>>>
>>> _____________________
>>> tedd.sperling@xxxxxxxxx
>>> http://sperling.com
>>>
>> Tedd - you got off easy on this post.  You should have seen the shouting
> tirade I received offline from this guy.  What a putz!
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


-- 
Richard Quadling
Twitter : @RQuadling
EE : http://e-e.com/M_248814.html
Zend : http://bit.ly/9O8vFY

[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux