xsl-list
[Top] [All Lists]

Re: [xsl] Client-side XSLT

2011-09-25 00:59:42
Hi Vasu,
I think we may be wandering away from this list's focus. If so, someone please let me know if there is somewhere else I can go that would be more appropriate. What I want to do is invoke an XSLT processor in the client browser or on my host webserver, but I am not sure that is an actual XSLT question.

That said:

I don't need all the code, I just need to understand - as you suggested - how to position a Java Query or JavaScript call in place of what is now the href, then how to execute an XSLT stylesheet in either of those languages.

Right now, my content XML document contains the names of about 600 jpg images; it will eventually contain the names of over 3000 jpg images with associated text. A sample entry would be:

<Stamp>
     <CatNumbers number="635"/>
     <Value kc-value="3"/>
     <Inscriptions czech="Pravda vítězí" eng="Truth Prevails"/>
</Stamp>

The excerpt I gave in the original email is from one of my indexing html documents :

<a href="../aip/635.htm"> <img src="../cr/small/635.jpg" alt="stamp image"/></a>

and was generated from that XML with an XSLT stylesheet, as was the 635.htm page referred to in the href. However, having generated 600 of those static pages, I think I need to look for a different solution before I reach 3000 static pages. So, essentially what I want to do is substitute something in place of the href that would generate the "635.htm" page on the fly with XSLT when the user asks for it.

To better understand the problem, you can see the current static code in action at www.cpslib.org -- simply click on the "Years" button, then on any stamp image. That will open the current static page with the large image static htm page that I would like to replace with an on-demand XSLT generated version (a virtual instead of a static page). By the way, every static page on the current website is already generated using XSLT stylesheets off-line.

I found out I have PHP active on my web hosting server, and it is supposed to be able to invoke an XSLT processor, but I am having no luck with the xslt_create() and xslt_process() functions. - the PHP does work, but I have not been able to get the Sablotron and expat libraries to work. Since I don't know PHP, likely I am the problem. However, I would prefer not to use PHP.

Hope this explains things a bit better.
Thanks for offering your comments,
Mark



-----Original Message----- From: Vasu Chakkera
Sent: Saturday, September 24, 2011 10:07 PM
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: Re: [xsl] Client-side XSLT

Hi Mark,
what does your XML look like? Does it have the content of what each
image would display? Please give more information ... Mostly you need
some kind of combination of Javascript and XSLT. As I said, i need to
know more on where the content is coming from



On 24 September 2011 17:04, Mark <mark(_at_)knihtisk(_dot_)org> wrote:
I have a stylesheet that generates XHMTL like:
      >
Right now, clicking on the 635.jpg images opens the 635.htm page.

The difficulty is that in the final project, the aip/n.htm files would
number more than 3000 if each were constructed individually. Those pages are
quite simple and contain only an image and a few lines of text. What I am
looking for is a way to launch an XSLT style sheet that would build the page
within the browser on demand.

My idea is that clicking on the small/635.jpg image on my XHTML page would
launch a stylesheet to build the 636.htm page. I need some hints on how to
get started, where to look, or to know that this is not a good idea.

Thanks,
Mark


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--





--
Vasu Chakkera
NodeLogic Limited
Oxford
www.node-logic.com
==============

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--




--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--