Crystal Report in PHP

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
dazed_confused
Forum Newbie
Posts: 1
Joined: Thu Aug 30, 2007 11:28 am

Crystal Report in PHP

Post by dazed_confused »

I am trying to run a Crystal Report accessing data in a MYSQL database in PHP. Although my desktop machine is W2K our PHP server is LINUX
PHP:
$crapp = new COM("CrystalRuntime.Application.11"); or die("cannot load cr com");
$my_report="C:\reports\report1.rpt";
$creport = $crapp->OpenReport($my_report,1);

I get the error FATAL error: Cannot instantiate non-existent class: com in /srv/www/htdocs/blah blah blah

any ideas on how to get around this. The other application developer here tells me that I can't use Com to call Crystal Reports because it is for PHP on Windows only.

I tried looking at the SOAP libraries but got totally lost.
User avatar
onion2k
Jedi Mod
Posts: 5263
Joined: Tue Dec 21, 2004 5:03 pm
Location: usrlab.com

Post by onion2k »

Yep, the other dev is right. Crystal Reports COM interface is Windows only. If you're on Linux I'm pretty sure you can't use Crystal Reports from PHP.
Post Reply