Re: [PHP] Re: XSLTProcessor help

2009-02-17 Thread Tom Sparks
- Original Message 

From: Colin Guthrie 
Sent: Wednesday, 18 February, 2009 3:40:41 AM

'Twas brillig, and Tom Sparks at 17/02/09 15:17 did gyre and gimble:
> I have stopped XSLT from rendering out all the text
> but I am no further a long getting XSL stylescript  to work
> I have been reading w3schools (http://www.w3schools.com/xsl/default.asp )
> and XML 1.1 bible 3rd edition ( 
> http://www.amazon.com/XML-Bible-Elliotte-Rusty-Harold/dp/0764549863 )
> I am at a lost still!!

>It looks more or less OK to me...

>Infact I tried it via the command line:

>My XML:
>
>Hellooo


>The XSL is yours from the previous post:

>$ xsltproc test.xsl test.xml

>
>
>
>vehicle: Hellooo
>
>
>vehicle: Hellooo
>

>Works fine.

>Are you sure you are not doing something odd in the calling code? e.g. make 
>sure you are calling transformToXML() properly. Perhaps slap all your files 
>>somewhere so we can download and test for you.
I have no where to put it yet, it is also a semi-private

i am using XAMPP for windows specs
 + Apache 2.2.11
  + MySQL 5.1.30 (Community Server)
  + PHP 5.2.8 + PEAR (Support for PHP 4 has been discontinued)
  + PHP-Switch win32 1.0 (use "php-switch.bat" in the xampp main directory) 
  + XAMPP Control Version 2.5 from www.nat32.com
  + XAMPP Security 1.0
  + SQLite 2.8.15
  + OpenSSL 0.9.8i
  + phpMyAdmin 3.1.1
  + ADOdb 4.990
  + Mercury Mail Transport System v4.52
  + FileZilla FTP Server 0.9.29
  + Webalizer 2.01-10
  + Zend Optimizer 3.3.0 
  + eAccelerator 0.9.5.3 für PHP 5.2.8 (but not activated in the php.ini)

I have also got domi.class.php (http://domi.sourceforge.net/ )
but is not needed with the comment sections
I am calling code by vehicle.php?id=1
there is a 1.xml in ./../vehicles/ from where the php file is

the code is bellow
-cut here
Render('./../xsl/vehicle.xsl');

//   $xslDoc = new DOMDocument();
//   $xslDoc->load("./../xsl/vehicle.xsl");

//   $xmlDoc = new DOMDocument();
//   $xmlDoc->load("./../vehicles/".$id.".xml");

//   $proc = new XSLTProcessor();
//   $proc->importStylesheet($xslDoc);
//   echo $proc->transformToXML($xmlDoc);

?>
cut here

 
tom_a_sparks

Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html 


  Make Yahoo!7 your homepage and win a trip to the Quiksilver Pro. Find out 
more

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: XSLTProcessor help

2009-02-17 Thread Colin Guthrie

'Twas brillig, and Tom Sparks at 17/02/09 15:17 did gyre and gimble:

I have stopped XSLT from rendering out all the text
but I am no further a long getting XSL stylescript  to work
I have been reading w3schools (http://www.w3schools.com/xsl/default.asp )
and XML 1.1 bible 3rd edition ( 
http://www.amazon.com/XML-Bible-Elliotte-Rusty-Harold/dp/0764549863 )
I am at a lost still!!


It looks more or less OK to me...

Infact I tried it via the command line:

My XML:

Hellooo


The XSL is yours from the previous post:

$ xsltproc test.xsl test.xml




vehicle: Hellooo


vehicle: Hellooo


Works fine.

Are you sure you are not doing something odd in the calling code? e.g. 
make sure you are calling transformToXML() properly. Perhaps slap all 
your files somewhere so we can download and test for you.


Col

--

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mandriva Linux Contributor [http://www.mandriva.com/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Re: XSLTProcessor help

2009-02-16 Thread Tom Sparks
same result

cut here---


  Hyalearl, 100-ton Sulieman-Class Scout/Courier

2008
03
10

  All rights reserved 2008
  Onno Meyer
  n...@none.com
  10
  Traveller
  1.0


-cut here---
-cut here---

http://www.w3.org/1999/XSL/Transform";;>





















-cut here---

 tom_a_sparks


Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html



- Original Message 
From: Colin Guthrie 
To: php-general@lists.php.net
Sent: Monday, 16 February, 2009 9:41:46 PM
Subject: [PHP]  Re: XSLTProcessor help

'Twas brillig, and Tom Sparks at 16/02/09 10:49 did gyre and gimble:
> help, when I include 
> the XSLTProcessor only strips the XML tags and outputs the text see result
> 

> --cut here vehicle.xsl-
> 
>  xmlns:xsl="http://www.w3.org/1999/XSL/Transform";;>
> 
> 
> 
> 

XSL needs to know that you are outputting XML-derived data...

eg. try putting this before your :

  


Col



-- 
Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mandriva Linux Contributor [http://www.mandriva.com/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]


-- PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


  Make Yahoo!7 your homepage and win a trip to the Quiksilver Pro. Find out 
more

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: XSLTProcessor help

2009-02-16 Thread Colin Guthrie

'Twas brillig, and Tom Sparks at 16/02/09 10:49 did gyre and gimble:

help, when I include 
the XSLTProcessor only strips the XML tags and outputs the text see result




--cut here vehicle.xsl-

http://www.w3.org/1999/XSL/Transform";>






XSL needs to know that you are outputting XML-derived data...

eg. try putting this before your :

  omit-xml-declaration="yes"/>



Col



--

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mandriva Linux Contributor [http://www.mandriva.com/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php