Database Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsOther TechnologiesDatabase Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
You eat, breathe and sleep innovation. Build your mobile intelligence with BlackBerry® experts this July. Register Today!
  #1  
Old September 3rd, 2002, 05:11 PM
Fredrik Fredrik is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Posts: 3 Fredrik User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Sybase connect

Hi!

This is the code i am running:

<?php
$dbconn = sybase_connect("Myserver", "sa", "some_WRONG_passwd");

if (!$dbconn) {
echo "Could not open database.";
exit;
}
?>

now I would think that this little code would give me the following output:

Could not open database.

Nothing more. But instead i get the error message from the sybase server..

like:
Warning: Sybase error: Login failed for user 'sa'. (severity 14) in /WWW/connect.php on line 2

I never get the output i want, even if i put error_reporting(0) i don't get the output..

why?

The php manual says that sybase_connect() should give me an linkid on success and false on failure.. but it never returns false, it just ends the script after it outputs the warning error...! why ?

Anybody please help!

Reply With Quote
  #2  
Old September 3rd, 2002, 05:33 PM
Anonymous Anonymous is offline
Registered User
Codewalkers God 35th Plane (22000 - 22499 posts)
 
Join Date: Apr 2007
Posts: 22,309 Anonymous User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 24
RE: Sybase connect

Try using the @ to supress the warnings:

$dbconn = @sybase_connect("Myserver", "sa", "some_WRONG_passwd");

Reply With Quote
Reply

Viewing: Codewalkers ForumsOther TechnologiesDatabase Help > Sybase connect


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway