Page 2 of 2
Posted: Sat Oct 19, 2002 3:08 pm
by volka
or something about invalid login/password - or what ever. But blank?
"cannot connect" was simply the error I could generate quickly on my own system and I'm astonished that mysql_connect returned FALSE but no error was set.
Is a much simpler script on the same server able to connect the database and perform without errors?
Code: Select all
<?php $username=... $password = ...
$connection_one = mysql_connect("10.100.120.1",$username,$password);
$result = mysql_db_query ('mmlsdb', 'SELECT count(*) FROM Module', $connection_one);
$row = mysql_fetch_row($result);
echo $rowї0]; ?>
Posted: Mon Oct 21, 2002 4:04 am
by psmshankar
Sorry for the delay volka, as our network was down...so just got it and replying u ...
yes with the code u gave i am able to get the result "4". there are 4 records in that table....
Posted: Mon Oct 21, 2002 4:13 am
by psmshankar
even i modified ur code and did as follows
Code: Select all
<?php
$connection_one = mysql_connect("10.100.120.1",$username,$password);
$result = mysql_db_query ('mmlsdb', 'SELECT count(*) FROM Module', $connection_one);
$row = mysql_fetch_row($result);
echo $rowї0];
$result1 = mysql_db_query ('Student_Monitor', 'SELECT count(*) FROM tempreport', $connection_one);
$row1 = mysql_fetch_row($result1);
echo "<br>$row1ї0]";
?>
i am getting the correct result - 4 and 19
Posted: Mon Oct 21, 2002 4:58 pm
by volka
the next step is to test
Code: Select all
<?php $username=... $password = ...
$connection_one = mysql_connect("10.100.120.1",$username,$password, TRUE);
$result = mysql_db_query ('mmlsdb', 'SELECT count(*) FROM Module', $connection_one);
$row = mysql_fetch_row($result);
echo $rowї0]; ?>
to see wether the new-link parameter causes the error or not
Posted: Mon Oct 21, 2002 9:01 pm
by psmshankar
i didn't get anything except blank page...
i even tried to display mysql_error(), but this also returns empty...

Posted: Tue Oct 22, 2002 1:28 am
by volka
http://www.php.net/manual/en/function.m ... quote]Note: The new_link parameter became available in PHP 4.2.0[/quote]
psmshankar wrote:What could be the problem?
My machine(localhost) - MySQL 3.23/PHP 4.0.6/Apache 1.39/Win98
Server(10.100.120.1) - MySQL 3.23/PHP 4.0.6/Apache 1.39/Win2K
Is it any configuration i need to do???
I think it's
upgrade time 
Posted: Tue Oct 22, 2002 2:02 am
by psmshankar
oooooppppppsssss.... now back to Square 1
hope u remember i asked about 'DCOM in PHP' under 'PHP forum'...
and this one also supports ver > 4.2 or whatever...
Now i understand ...

why from the machine when i run that program it worked , wheras when run from server it doesn't
10days back i donwloaded the latest version 4.2.3 (win installer exe) and installed in my machine.... so from my machine i can have more that one connection thru PHP....hmmmmmmm
but this installer was giving me problem w.r.t extension dlls
m lookin in to this also...now downloaded the other zip file and installed....
after this , i need to upgrade the server also...
will do that and get back to u....
Its so nice of you in answering ....debugging...analysing step-by-step and then giving suggestions....its good work volka....i like these kinda people...becos i also of that category...i hav been reading ur post for sometime now in this forum(i am newbie to this forum..not only to this forum but also new to PHP since 6monhts i am in to this...before that i was in VB/SQL Server)
i am curious in knowing about you...v can have private communication
Nice to hear from you too personally...may be v can send private msgs apart from posting here.....expecting urs...
Posted: Tue Oct 22, 2002 2:13 am
by volka
since I found the webaware flag in
trillian (

) the icq-indicator works again

Posted: Tue Oct 22, 2002 2:22 am
by psmshankar
but i dont hav ICQ no?
do u hav yahoo/hotmail id????
oops.. from ur profile i saw that u r a student...good work...
Posted: Tue Oct 22, 2002 2:31 am
by volka
until now mail, icq & irc were sufficient for me
!! warning: commerical

!!
even though there are better clients for each medium
trillian has the advantage of bundleing AIM, ICQ, IRC, MSN & YAHOO messaging.
'student' maybe should be 'collegian' or 'college student'.
I earn a living with software development now since 4 years
oh oh, three

's in such a short post (with this 4)
How could there be life on earth before emoticons........
Posted: Tue Oct 22, 2002 2:52 am
by psmshankar
until now mail, icq & irc were sufficient for me

what mail you are using? send ur mail ID over private msg...
I earn a living with software development now since 4 years
thats good...
How could there be life on earth before emoticons........
