My problem lies in the fact that i can parse the database using PHP and get the information i need but i don't want the Windows machine to be my "Primary" server.
What i was hoping, was to just have a "connection.php" file on the windows machine that would be used on the Linux server in a php script with "include ". Now, i can get the posted value to the Windows server and i can see reults IF VIEWED from the Windows Apache server but what i want is to have the "connect.php" hold the values so that i could use those on my Linux server.
So, far, i have tried many things - mostly stuff like
Code: Select all
// "connect.php"
<?php
// Start the session
session_start();
//connect to the database
$connectionstring = odbc_connect('SysDSN','user','password');
//SQL query
$Query = " SELECT Ship_to_Address.Customer_No_, Ship_to_Address.Name FROM Ship_to_Address WHERE Ship_to_Address.Customer_No_='666'";
//execute query
$queryexe = odbc_do($connectionstring, $Query);
while(odbc_fetch_row($queryexe))
{
$name = odbc_result($queryexe, 1);
$name2 = odbc_result($queryexe, 2);
}
// echo $name; - this does print a result.
?>Code: Select all
<?
// Start the session
session_start();
include 'http://remote-windows-server/connect.php';
echo $name;
?>Basically - in it's simplest form - i want to use variables established on the Windows machine on my Linux machine.
And yes i could make it nice and messy using POST or GET (maybe a little Redirect in there for goog measure) but i'm not really good with PHP and i have no clue how to carry the values over seamlessly.
Any help would be great. Thank you.
Phorem.