[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: WG: [docbook-apps] HTML- SVG problem: How to change HTML tags?
Dear Bob, thanks for your advice, but I still have not been successful. I have changed "<object data=..." to "<data data=..." and "</object>" to and "</data>" (because these start and end tags had worked, when I had changed the HTML code manually). Then I have tried to run the xsl transformation, but I have got the following error message: "line 170 element element unregistered variable tag xmlXPathCompiledEval: evaluation failed" (line 170 says: <xsl:element name="{$tag}">) So, the HTML code is evaluated with the result, that I am not allowed to replace the "object" tag by "data". This is a pity, because "object" does not work in the internet explorer for unknown reasons, and "data" does. - Is there a way to turn off the HTML evaluation? - Or do I have to customize further lines in the code of "graphics.xsl" file? Maybe, I have to write a transformation, which adjusts the HTML output after it has been transformed by my customization. But this would make everything even more complicated. Best regards, Martin >Von: Bob Stayton [mailto:bobs@sagehill.net] >Gesendet: Donnerstag, 8. März 2007 18:39 >An: Schramm, Martin; docbook-apps@lists.oasis-open.org >Betreff: Re: [docbook-apps] HTML- SVG problem: How to change HTML tags? > >Hi Martin, >I think you are very close. The part you found creates the HTML tags >and saves them as a result tree fragment in the 'img' variable. >Further down the big process.image template is <xsl:copy-of >select="$img"/> which then outputs the result tree fragment created >earlier. So where you see <object data= ... is where you should make >the change. Let me know if I'm not understanding your question. > >The process.image template really needs to be rewritten into smaller >modular pieces that are easier to customize. That template is almost >800 lines long! > >Bob Stayton >Sagehill Enterprises >DocBook Consulting >bobs@sagehill.net > > >----- Original Message ----- >From: "Schramm, Martin" <MSchramm@harmanbecker.com> >To: <docbook-apps@lists.oasis-open.org> >Sent: Thursday, March 08, 2007 9:15 AM >Subject: [docbook-apps] HTML- SVG problem: How to change HTML tags? > > >> Dear all, >> I would like to ask you for some support with my HTML customization: >> >> I've got a problem to transform my DocBook files with SVG graphics to >> HTML (by using XSLTProc and the .../html/docbook.xsl file). When I >> check the HTML output, the SVG graphics will only be displayed in >> Mozilla v 2.0.0.2 and Opera v 9.10 . In MS Internet Explorer v 6.0, >> though I have installed the Adobe SVG Viewer Plugin. In MS Internet >> Explorer the text is displayed normally, but only the empty viewport >> of the SVG graphics is visible. Obviously tries to load data but does >> not come to an successful end. I do not prefer MS IE, but most of the >> customers use it. >> >The HTML output, that IE cannot display, looks like this: > ><div class="figure"> > <a name="id512734" id="id512734"></a> > <div class="mediaobject"> > <table border="0" summary="manufactured viewport for HTML >img" >cellspacing="0" cellpadding="0" width="720"> > <tr> > <td><object >data="figures/060609_structure-guideline-b.svg" type="image/svg+xml" >width="720" height="540"> > </object></td> > </tr> > </table> > </div> > <p class="title"><b>Figure 1.1. structure of >guideline</b></p> > </div> > >By chance I have found out, that all browsers (including the MS IE) >manage to display the HTML file AND the SVG graphic, when I change the >HTML tag manually from "<object data="figures/...." to just >"<data="figures/...". So the HTML output looks like this: > ><div class="figure"> > <a name="id512734" id="id512734"></a> > <div class="mediaobject"> > <table border="0" summary="manufactured viewport for HTML >img" >cellspacing="0" cellpadding="0" width="720"> > <tr> > <td><data="figures/060609_structure-guideline-b.svg" >type="image/svg+xml" width="720" height="540"> > </data></td> > </tr> > </table> > </div> > <p class="title"><b>Figure 1.1. structure of >guideline</b></p> > </div> > >I know this is a dirty foul against the w3c rules, because this tagging >is not allowed. But it works and unless I find a better way to outsmart >this MS IE bug, I want to go this way. > >Now I would like to change my HTML Customization, so it will produce >the tagging like shown above. I have found the piece of code that >checks the parameter settings of the SVG image in the "graphics.xsl" >file >("<xsl:variable name="img"> <xsl:choose> <xsl:when >test="@format = >'SVG'"> <object data="{$filename}" type="image/svg+xml"> etc. "). But >I could not find the part of the code, where it produces the HTML tags. > >My question (it is rather an appeal): >========================== >Where do I have to change the code and how can I change it within my >customization, to produce an HTML tag "<data="figures/...". instead or >"<object data="figures/...." . > >Thanks a lot, I need to make my graphics visible and this problem >drives me mad. > >> Many thanks, >> Martin >> >> > >******************************************* >Harman Becker Automotive Systems GmbH >Geschaeftsfuehrung: Dr. Peter Geiselhart - Michael Mauser >- William S. >Palin - Edwin Summers - Regis Baudot Sitz der Gesellschaft: Karlsbad >- Registergericht: Mannheim HRB 361395 > >******************************************* >Diese E-Mail enthaelt vertrauliche und/oder rechtlich geschuetzte >Informationen. Wenn Sie nicht der richtige Adressat sind oder diese >E-Mail irrtuemlich erhalten haben, informieren Sie bitte sofort den >Absender und loeschen Sie diese Mail. Das unerlaubte Kopieren sowie die >unbefugte Weitergabe dieser Mail ist nicht gestattet. >This e-mail may contain confidential and/or privileged information. If >you are not the intended recipient (or have received this e-mail in >error) please notify the sender immediately and delete this e-mail. Any >unauthorized copying, disclosure or distribution of the contents in >this e-mail is strictly forbidden. >******************************************* > >--------------------------------------------------------------------- >To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org >For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org > > > > > >
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]