Welcome to WebmasterWorld Guest from

Forum Moderators: coopster & jatar k

Message Too Old, No Replies

xslt and php5



11:44 pm on Jul 28, 2010 (gmt 0)

10+ Year Member


I am trying to install the Open Source program, phpMyHotels. On the index.php page I get the error message:
Fatal error: Call to undefined function xslt_create() in /home/site/public_html/hotel/index.php on line 28

# If we re calling a nested module a normal Fusebox flow is executed
# otherwise we perform output buffering and XSLT processing

if (!isset($attributes['stoplayout']))


if (!$attributes['stoplayout']) {
$xml = ob_get_contents();
$xml = '<?xml version="1.0" encoding="utf-8"?>'.$xml;


# If debug mode activated write XML into /tmp/out.xml to ease debugging
$fp = fopen($GLOBALS['CONFIG']['DEBUGFILE'], 'w');
fwrite ($fp, $xml);

$arguments = array('/_xml' => $xml);

# Allocate a new XSLT processor
$xh = xslt_create();

# Process the document
$result = xslt_process($xh, 'arg:/_xml', $GLOBALS['rootpath'].'/layouts/layDefault.xsl', NULL, $arguments);

if ($result) {
print $result;
} else {
print 'Sorry, XML code could not be transformed. ';
print 'The reason is <b>' . xslt_error($xh) . '</b>';
print ' and the error code is ' . xslt_errno($xh);


I did a little research and found that there is a problem with xslt and Php5. I could not find any way to correct the code. I pay a hosting company so I don't have access to the server. Is there a way to correct this code to get it to work? Any coders out there that know a work around?

Thank you!


12:36 pm on Jul 31, 2010 (gmt 0)

10+ Year Member

I still can't find a solution. Should I find another program or is there a way to change this one to work with php5?

I appreciate any responses. Thank you.


1:06 pm on Jul 31, 2010 (gmt 0)

5+ Year Member


phpMyHotels is written for php4 and xslt is a php4-only extension. Looking at the sourceforge page for the project it looks as though phpMyHotels hasn't had any new releases in over five years, which would suggest it has been abandoned and there is little hope of it being made php5 compatible.


Featured Threads

Hot Threads This Week

Hot Threads This Month