Jump to content
alexfung

Xslt_create() Suddenly Fails

Recommended Posts

I wrote this code last year and it has been fine since then. Last time I run it was some two or three weeks ago. Today it failed. What has happened?

 

 

I got:

 

<br />

<b>Fatal error</b>: Call to undefined function: xslt_create() in <b>/home/alexfun/public_html/bank/loadxxl.php</b> on line <b>48</b><br />

 

the php is essentially this:

 

header('Content-Type: text/xml; charset=UTF-8');

header('Cache-Control: private, max-age=60');

$hXML = xslt_create();

$output = xslt_process($hXML, $xml, 'private.xsl',

NULL, NULL, array('id' => $_SESSION['accid']));

xslt_free($hXML);

 

 

I'm on Server 24.

Share this post


Link to post
Share on other sites

Just an educated guess here: There was a problem on server 24 a couple of days ago. Apache was rebuilt on the server (and I imagine PHP was as well). When PHP was compiled, it was not compiled with support for XSLT functions (configure options --enable-xslt and --with-xslt-sablot). You can see the options PHP was compiled with (and a bunch of other information as well) by browsing to server 24's phpinfo page.

 

You'll need to submit a ticket to the Help Desk and ask them if they can recompile PHP with support for XSLT functions added back in.

Share this post


Link to post
Share on other sites

If you could open a support ticket with the URL that you are seeing that error, we can certainly look into it and see if PHP is missing something.

Share this post


Link to post
Share on other sites
Just an educated guess here:  There was a problem on server 24 a couple of days ago.  Apache was rebuilt on the server (and I imagine PHP was as well).  When PHP was compiled, it was not compiled with support for XSLT functions (configure options --enable-xslt and --with-xslt-sablot).  You can see the options PHP was compiled with (and a bunch of other information as well) by browsing to server 24's phpinfo page.

 

You'll need to submit a ticket to the Help Desk and ask them if they can recompile PHP with support for XSLT functions added back in.

You are right!

When I saw "--with-dom --with-dom-xslt --with-dom-exslt" I thought it is enabled, but comparing with an older phpinfo I saved, it used to have "'--enable-xslt' '--with-xslt-sablot' " as well, the two flags you mentioned. I'll go get the ticket.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...