473,561 Members | 3,917 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

xsl imports relative to current file instead of xsl file

In the directory /var/www/dynamo/xsl is the basic xsl file for xhtml
documents /var/www/dynamo/xsl/xhtml.xsl. In this file there is an import
statement: <xsl:import href="xhtml/basic.xhtml.xsl " />.
This import statement should load /var/www/dynamo/xsl/xhtml/basic.xhtml.xsl
as far as I know.

The current document is /var/www/dynamo/xml/index.xml (.xml documents are
handled by the PHP parser on my server). This is the error message I get:
Warning: I/O warning : failed to load external entity
"/var/www/dynamo/xml/xhtml/basic.xhtml.xsl "
in /var/www/dynamo/lib/xml/content.class.p hp on line 10

Warning: compilation error: file /var/www/dynamo/xml/ element import
in /var/www/dynamo/lib/xml/content.class.p hp on line 10

Warning: xsl:import : unable to
load /var/www/dynamo/xml/xhtml/basic.xhtml.xsl
in /var/www/dynamo/lib/xml/content.class.p hp on line 10

If I change the import statement to
<xsl:import href="../xsl/xhtml/basic.xhtml.xsl " /> the page is displayed

So from this I learn that the xsl imports are not relative to the parent xsl
file... This is confirmed by visiting the page
at /var/www/dynamo/xml/test/index.xml. With
the ../xsl/xhtml/basic.xhtml.xsl import statement I get the error:

Warning: I/O warning : failed to load external entity
"/var/www/dynamo/xml/xsl/xhtml/basic.xhtml.xsl "
in /var/www/dynamo/lib/xml/content.class.p hp on line 10

Warning: compilation error: file /var/www/dynamo/xml/test/ element import
in /var/www/dynamo/lib/xml/content.class.p hp on line 10

Warning: xsl:import : unable to
load /var/www/dynamo/xml/xsl/xhtml/basic.xhtml.xsl
in /var/www/dynamo/lib/xml/content.class.p hp on line 10

Same behaviour. I don't remember the XSL import to work like this :-(
Is it a change/bug in the latest xsl or php5 release? Can I change this
behaviour so that the imports are handled relative to the xsl file?

Thanks in advance,
Rutger Claes
Rutger Claes rg*@rgc.tld
Replace tld with top level domain of belgium to contact me pgp:0x3B7D6BD6
Do not reply to the from address. It's read by /dev/null and sa-learn only

Jul 17 '05 #1
0 1577

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

by: Doug | last post by:
If I were to write an include with a relative path like include("../conf/config.php"); What is the use? As far as I understand it, the path is relative to the first script that is called by php. In other words, if the current working directory is /www/ and you were
by: Randall Smith | last post by:
I've noticed the push by Guido and others to use absolute imports instead of relative imports. I've always enjoyed the ease of relative imports, but am starting to understand that "explicit is better than implicitly" as the Python philosophy goes. I'm trying to develop a strategy for writing packages using only absolute imports and would...
by: Alex VanderWoude | last post by:
I am trying to <include> some text into an XML documentation topic, but that text is stored in a file that is in a different directory than the "current" XML file. Using a relative path does not appear to work, because the base being used is the Common7\IDE directory, not my original source directory. Here is the situation: MyApp...
by: openleren | last post by:
Hi all, how can I use a relative path in my web.config file for an Access db?: Instead of using <configuration> <appSettings> <add key="conAccess" value="microsoft.jet.oledb.4.0;data source=c:/Inetpub/MyApp/data/database.mdb" /> ...
by: John Salerno | last post by:
I'm reading the "What's New" section of the 2.5 docs, and I'm a little confused by the last section of "Absolute and Relative Imports": ----------------------------------------------- For example, code in the A.B.C module can do: from . import D # Imports A.B.D from .. import E # Imports A.E from ..F import...
by: Kay Schluehr | last post by:
Since their introduction in Python 2.5 I only reviewed the new "relative import" notation briefly by reading the "What's new in Python 2.5" article. Now I wanted checkout if I get comfortable with them. Opening the tutorial I found following notice ( 6.4.2 ): "Note that both explicit and implicit relative imports are based on the name of...
by: John Millikin | last post by:
With the old import system, and a package that looks like this: foo/ __init__.py main.py bar/ __init__.py baz.py If I wanted to delay importing baz until it was actually used, I could
by: DG | last post by:
Alright, I have searched and searched and read many conversations on the topic of relative and absolute imports and am still not getting the whole thing through my skull. Highlights of what I've read: http://mail.python.org/pipermail/python-list/2007-January/422973.html...
by: Terry Reedy | last post by:
Download the latest beta for your system and give it a try.
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.