SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
so i have this scenario, i installed my slackware 13 box in full installation so it has already mysl + php version 5 + apache.. right now my boss ask me if i can run their projects that has MS SQL + ODBC + PHP version 4.
my question is how can i change my php to version 4? and how can i install ms sql and odbc? is there a slackbuild for php ver 4 and for ms sql and odbc that i could just compile then installpkg it?
Are you sure about MS SQL? It is a Windows-only DB server and i seriously doubt than you can run it even under wine. About PHP, is there a reason for downgrading the version? isn't it backwards compatible?
Are you sure about MS SQL? It is a Windows-only DB server and i seriously doubt than you can run it even under wine. About PHP, is there a reason for downgrading the version? isn't it backwards compatible?
yes im sure about the mssql part.. i found some thing about the FreeTDS package used to allows your programs to natively talk to Microsoft SQL Server and Sybase databases.
we both came to the same solution i think. im planning to reconfigure the php using an older build..
well right now i can connect to the mssql server using freetds and as my senior said that it enough to connect to mssql..^^(thankfully i dont need to run mssql server on my box. phew..)
im only problem is the php. i have to downgrade from php 5 to php 4.(something).. i think i have to ./configure another php to to this then add a line in my httpd.conf file to make my apache and php4 to work together.. although i dont know how did slackware installed the apache.
so my question is the above method correct? or do i have to do something else.. does php 4 run on Apache2.2.14?
I think the safest way to go would be to first uninstall the slackware version of PHP (5.something) and then compile the latest php 4 from source (./configure, make, make install). "make install" should copy all necessary modules.
If it fails check the "--with-apxs2" parameter.
I think the safest way to go would be to first uninstall the slackware version of PHP (5.something) and then compile the latest php 4 from source (./configure, make, make install). "make install" should copy all necessary modules.
If it fails check the "--with-apxs2" parameter.
done that mate.. right now im on php4.. but it seems that my php doesnt recognize mysql.. it always says that i should upgrade to another version.
i have another question.. could i have 2 php eg. php4 and php5? where in i can just switch to php 5 for some certain projects that needs it and when i need to change to php 4 again i dont have to remove php 5 then install php 4?
got both working for a while now.. the only problem in mysql is that i have a password that was hashed by a newer version thats why the older version of php doesnt recognize it.. thanks mate for your feedback..
the only problem now is that php returns an error in the line where i tried to connect to the mssqlserver using odbc_connect();
Before trying to resolve odbc issues, first make sure that the tsql is working.
In your example you used "/usr/local/freetds/bin/tsql -S 198.168.100.2 -U sa",
which doesn't look right to me. If you use the -S option, then you have to
have that server name configured in the freetds.conf file - and i seriously
doubt that you named the server "196.168.100.2" !
To use the IP address, you need to use the -h AND the -p (host and port) options.
Personally I reckon it's better to use the freetds.conf file, where you could have
and entry like this :
[FredsDatabase]
host = 169.168.100.2
port = 1433
tds version = 7.0
I use freetds a lot, both from Linux and Solaris against many MS-SQL servers and
it works really well. I don't use odbc and I certainly don't use PHP either - but I
don't think that's where your problem lies (yet).
Before trying to resolve odbc issues, first make sure that the tsql is working.
In your example you used "/usr/local/freetds/bin/tsql -S 198.168.100.2 -U sa",
which doesn't look right to me. If you use the -S option, then you have to
have that server name configured in the freetds.conf file - and i seriously
doubt that you named the server "196.168.100.2" !
To use the IP address, you need to use the -h AND the -p (host and port) options.
Personally I reckon it's better to use the freetds.conf file, where you could have
and entry like this :
[FredsDatabase]
host = 169.168.100.2
port = 1433
tds version = 7.0
I use freetds a lot, both from Linux and Solaris against many MS-SQL servers and
it works really well. I don't use odbc and I certainly don't use PHP either - but I
don't think that's where your problem lies (yet).
thanks for the help mate..^^ but my tsql works fine as i have said.. i got the problem isolated and just yesterday figured out what was wrong.. now i got everything perfectly working..
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.