Got it! From the php manual http://uk.php.net/manual/en/function.odbc-connect.php way down in the comments bit...
$connection_string = 'DRIVER={SQL Server};SERVER=COMPUTER1;DATABASE=SampleASP';
$user = 'sa';
$pass = '';
$connection = odbc_connect( $connection_string, $user, $pass );
This works fine while trying to connect to sql server on localhost:
$dsn="sqlserver";
$username="sa";
$password="";
$sqlconnect=odbc_connect($dsn,$username,$password);
I have created a new sql server dns configuration on "COMPUTER1" (networked computer) with the same name "sqlserver" and I...
UPDATE - I was apparently wrong on this. you will get a browser redirect if you go to http://yoursite.com. You should do full URL http://www.yoursite.com to avoid 302 redirect error when trying remote http request. So for google (and anyone else):
remote http error - do full URL
OK I was joking about the star - notice I haven't given myself one....
Debugging is something we ALL do when things don't go as we expect - yes?
I have never used a remote http call before. The problem is that this procedure requires third party code, from my payment gateway AND it seems (like a...
Yes but I want the callback to work first, then I will re-write script to insert data. If the process doesn't work then there's no point in writing a script. I'm DEBUGGING first to iron out the problem. The problem is that the call back fails because there is too much data in the query string...
I think I've got this. The problem is because the $_GET query string was too long. I remember we use $_POST as we can take more data. $_GET is limited to 255 chars or something - I'm giving myself a star
That's the conclusion I have come to. I have sent off a ticket to them so I'll repost if I get a satisfactory answer in case anyone else has this problem...
Thanks for your help!
The script at http://www.audiochess.com/icc_callback.php does this:
$recipient ="webmaster@audiochess.com";
$subject = "new data1";
$from = "webmaster@audiochess.com";
$message="test";
$additional="test";
$sender = "webdesigner@audiochess.com";
$mailResult = mail (...
Yes, with a browser and my script works fine. But this needs to be done automatically hence the remote http call. I've done thing like:
print($_SERVER['SERVER_NAME'].$_SERVER['PHP_SELF']."<br>");
To determine the page's real URL but from a browser this obviously doesn't help. Why am I being...
Well sort of. The callback is configured to go to:
http:/www.audiochess.com/icc_callback.php
AND append data (as $_GET data) to the URL which is then supposed to be able to be parsed and inserted into database to confirm purchase or whatever.
That's what is supposed to occur, but, as you say I'm...
OK but the remote call is configured to go to http://www.audiochess.com/icc_callback.php
but when it does it says the page isn't there and to go to
http://www.audiochess.com/icc_callback.php (same page)
This makes no sense surely?
When a purchase is made from my site I have mals-e.com send a remote http request to a page that updates the database etc. However it always fails - in debug mode I get this:
HTTP/1.1 302 Moved Temporarily
Plus some other stuff about get vars...
If I hit the page in a browser, everything works...
OK ca8msm is totally correct, in case any newbies are following this thread, download this: visual web developer 2005 express edition from http://asp.net. I know php/mysql but this stuff is a different beast altogether!
Thanks - you're right, I've not heard of compiling web based applications, software yes, but backend server code? So I will read on. Thanks for your advice!
Hi I'm fairly new to asp.net. I've installed it on apache2 and things like:
<%
response.write(DateTime.Now.ToString())
%>
work fine. But when I try something a little more complex like trying to connect to sql server 2000 I get application errors. When I try to remove the offending code and...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.