Transform newbie
Hi,
I'm using eclipse + WTP to create my first JSP. I'm trying to use XSLT, so I have the JSTL (nightly build) in. For some reason my (seemingly simple) JSP produces error when invoked. It looks like this:
<%@taglib uri="http://java.sun.com/jsp/jstl/xml" prefix="x"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<c:import var="xml" url="restaurants.xml" />
<c:import var="xslt" url="restaurant_names.xsl" />
<x:transform xml="${xml}" xslt="${xslt}" />
When invoked I get:
[Fatal Error] :-1:-1: Premature end of file.
ERROR: 'Premature end of file.'
FATAL ERROR: 'Could not compile stylesheet'
Nov 29, 2005 12:26:54 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet jsp threw exception
javax.xml.transform.TransformerConfigurationException: Could not compile stylesheet
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTemplates(TransformerFactoryImpl.java:824)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTransformer(TransformerFactoryImpl.java:619)
at org.apache.taglibs.standard.tag.common.xml.TransformSupport.doStartTag(Unknown Source)
at org.apache.jsp.select_005frestaurant_jsp._jspx_meth_x_transform_0(org.apache.jsp.select_005frestaurant_jsp:154)
at org.apache.jsp.select_005frestaurant_jsp._jspService(org.apache.jsp.select_005frestaurant_jsp:73)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
Why?
maybe I missed something, but I'm having trouble doing it to multiple notes at once...
When I select multiple notes and use the scissors on the first note, it only cuts that one...
[----][----][----][----] >>>>> [--][--][----][----][----]
Similar Messages
-
Newbie problem with JAXM - Transformer Exception
Hi there!
I am looking for some start- up help.
I have this SOAP message in a file (test.xml)
<soap-env:Envelope xmlns:soap-env="http://schemas.xmlsoap.org/soap/envelope/">
<soap-env:Header>
<m:SessionID xmlns:m="Some-URL" value="2123123"/>
</soap-env:Header>
<soap-env:Body>
<m:StartSession xmlns:m="Some-URL">
<username>TestUser</username>
</m:StartSession>
</soap-env:Body>
</soap-env:Envelope>I use the following lines of code
StreamSource src = new StreamSource(new File("c:/test.xml"));
TransformerFactory tFact=TransformerFactory.newInstance();
Transformer trans = tFact.newTransformer(src);And i get an Transformer exception saying
javax.xml.transform.TransformerException: stylesheet requires attribute: versionAny hint? Thanks a lot!I think I found the problem because I managed to use the transformer ..and to read from the xml file.Aftwards with the output of the transformrt i produced a separaye xml
WRONG ->>The passing parameter src
Transformer trans = tFact.newTransformer(src);
Anyway thats ok because I had to search through the XSLTC thing and read some usefull things! -
Newbie help with 'transforming'
Please bear with me.
I've just bought Final Cut Express (last Sunday), having been used to video editing on a PC.
I'm doing a project where I need to crop an image, and for that crop to fill the screen ...I did it with a movie editing programme on a PC and I'm trying to find out how to do it on my imac...This is what I am trying to do:
http://stuhughes.com/T1.mov
If anyone can direct me to a tutorial on this I would be grateful.
I also have just got Visual Quick Start Final Cut Express book but haven't yet been able to find the info in that.See if this gets you started
http://www.fcpbook.com/MotionControl_inFCE.html -
HI! I'm using Photoshop Elements 3. After I transfer my pictures to a background layer I try using the Free Transform Command. I hit the link (maintaining ratio) With the bounding box I am dragging the photos (to appear by my eye) to a size that "looks" the size I would like. I guess I'm at a loss as to why I crop them in the first place, if I'm going to resize them?? They are out of perspective--the people look skinny!
I am really a newbie and blonde to boot!Terri,
Yes, resizing the image before dragging it onto a new background is a good
idea. Question is how to go about it. Once you drag the image onto the
background it will be the same resolution as the background. Let's say you
have an 8x10 background with a 300 ppi resolution and you want to put four
images on it. Ideally, you have all four exactly sized at 3.5x4.5 and 300
ppi. That won't look all that wonderful. But, do it anyway.
Using the Crop Tool, go ahead and resize your images that way and drag them
onto the background. Now, with the Move Tool, you can position AND resize
them.
When using the Crop Tool you'll have to set the width and height and the
resolution in the options bar. While resizing with the Move Tool you have
to hold the shift key while dragging a corner. There will be some
resampling occurring which can possibly degrade the quality of the image(s),
but we can worry about that at another time.
HTH
Juergen -
ABAP XSLT Transformation using element include
Hi there,
I am trying to convert data from SAP-DATA -> DOM over XSLT to a Stream.
For achieving this I have to use certain modularized XSL-Files which will later be accessible over http. At the moment however, those files are on my local hard drive (client) only. I tried to access these files using:
<xsl:transform version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:sap="http://www.sap.com/sapxsl"
>
*<xsl:include href="D:\XSL\include.xsl"/>*
<xsl:strip-space elements="*"/>
<xsl:template match="/">
</xsl:template>
</xsl:transform>
I get the message "D:\XSL\include.xsl doesn't exist" when checking the syntax. When I test this in my OS however, it works perfectly. Being an SAP- and XML-Newbie my question is the following: Does SAP not know my hard drive mappings while I'm in a transformation or can i only access directories over al11/http. Or is it complete nonsense at all?
Regards, Lukas
Edited by: Lukas Weigelt on Jun 9, 2010 4:18 PMHi,
according to:
>
Michal_Krawczyk_PIXI wrote:
> as per:
> http://help.sap.com/saphelp_470/helpdata/EN/84/2e4d3ce624b800e10000000a114084/frameset.htm
> "The href attribute no longer applies in this case."
it appears the include element only works with the repository.... I tried
<xsl:include sap:name="<Name_of_the_Transformation_in_Repository>"/>
and it works.
However this would mean, all includes i have to make have to be imported to the repository. If that's really the case, it'll be a huge problem, because the xsl-files i want to include are outside of my reference
Regards, Lukas -
Hi,
I'm a real newbie in XML and Java. But I must use Java for this.
But all I want to do is the following:
I generate a XML file like this:
<day atday=12><hour athour=10><minute atminute=10>
<second atsecond=20>value1</second>
<second atsecond=21>value2</second>
<second atsecond=22>value3</second>
</minute></hour>
<hour athour=11><minute atminute=10>
<second atsecond=10>value4</second>
<second atsecond=11>value5</second>
</minute></hour></day>
Now I want to transform this to csv. Such that there is for every value in row2 the suitable date in row1.
Something like that:
12 10 10 20, value1
12 10 10 21, value2
12 10 10 22, value3
12 11 10 22, value4
If you have some similar code...please send it.
I need code which I can modify.
Thxplease refering jasperreports project in www.sourceforge.com.
-
Not getting required output from XML transform in servlet
I have an XML document and an XSL stylesheet that will produce the output I require when I use the Xalan in-line parser. However, I cannot manage to do the same in a servlet. I have trawled through loads of examples but can't find anything that works. It appears that the servlet is choking when I try to use:
Document document = builder.parse(datafile);
and the output in the browser is:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=windows-1252"></HEAD>
<BODY></BODY></HTML>
Which bears no resemblance to what I am expecting.
I can provide contents of servlet source and xml files if someone can help, please.Thanks for your comments.
I have tested the XML and XSL and they are OK but the servlet won't sned out the HTML as expected.
The servlet code is as follows (I haven't included the whole servlet - just the core of the body):
public class FormTwo extends HttpServlet {
public void doPost(HttpServletRequest req, HttpServletResponse res)
throws ServletException, IOException, FileNotFoundException {
res.setContentType("text/html");
//PrintWriter out = res.getWriter();
PrintStream out = new PrintStream (res.getOutputStream());
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
TransformerFactory tFactory = TransformerFactory.newInstance();
try {
File stylesheet = new File("children.xsl");
File datafile = new File("children.xml");
int NumChildren = Integer.parseInt(req.getParameter("Numchildren"));
String fullname = req.getParameter("Title") + " " + req.getParameter("Lastname");
DocumentBuilder builder = factory.newDocumentBuilder();
Document document = builder.parse(datafile);
// Use a Transformer for output
StreamSource stylesource = new StreamSource(stylesheet);
Transformer transformer = tFactory.newTransformer(stylesource);
DOMSource source = new DOMSource(document);
StreamResult result = new StreamResult(out);
transformer.transform(source, result);
}The XML is:
<?xml version="1.0"?>
<pagedef pagehead="Form two test page">
<bodydef bodytext=", could you please enter details of each child and indicate if they are currently at school">
<rows NumReq="3">
<cols type="text" size="25" name="firstname">First Name</cols>
<cols type="text" size="25" name="lastname">Last Name</cols>
<cols type="checkbox" name="atschool">At school?</cols>
</rows>
</bodydef>
</pagedef>The XSLT is:
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns="http://www.apache.org/xslt">
<xsl:output method="html" indent="yes"/>
<xsl:template match="/">
<html>
<head><title><xsl:value-of select="/pagedef/@pagehead"/></title></head>
<body bgcolor="#ffffcc" text="#0000ff">
<xsl:apply-templates/>
</body>
</html>
</xsl:template>
<xsl:template match="bodydef">
<xsl:value-of select="@bodytext"/>
<form>
<table>
<xsl:apply-templates/>
</table>
</form>
</xsl:template>
<xsl:template match="rows">
<thead>
<xsl:for-each select="cols">
<td><xsl:value-of select="."/></td>
</xsl:for-each>
</thead>
<xsl:call-template name="output-row">
<xsl:with-param name="thisrow" select="0"/>
</xsl:call-template>
</xsl:template>
<xsl:template name="output-row">
<xsl:param name="thisrow"/>
<xsl:choose>
<xsl:when test="number($thisrow) != number(/pagedef/bodydef/rows/@NumReq)">
<tr>
<xsl:for-each select="cols">
<td>
<input>
<xsl:copy-of select="@*"/>
</input>
</td>
</xsl:for-each>
</tr>
<xsl:call-template name="output-row">
<xsl:with-param name="thisrow" select="number($thisrow) + 1"/>
</xsl:call-template>
</xsl:when>
<xsl:otherwise/>
</xsl:choose>
</xsl:template>
</xsl:stylesheet>As a newbie to Java I am more confident about the XML and XSL than the servlet code. Any advice would be appreciated.
Thanks... -
Transforming XML into complex type in ADF/Java
Hi all,
Maybe a simple question for you all - maybe too simple for some of you - but not for me as a Java newbie. So I'd appreciate any help.
I have used a WebService Proxy and created a new Pojo in order to create a Data Control. The WS proxy works quite good and I can get this XML response as expected.
<ns0:kunden xmlns:ns0="http://www.oracle.com/hbv">
<ns0:kunde>
<ns0:Kundennummer>0000000047</ns0:Kundennummer>
<ns0:Name>Laue</ns0:Name>
<ns0:Vorname>Ingo</ns0:Vorname>
<ns0:Straße>Kühnehöfe</ns0:Straße>
<ns0:Hausnr/>
<ns0:PLZ>22761</ns0:PLZ>
<ns0:Ort>Hamburg</ns0:Ort>
<ns0:Telefon>040/89091-456</ns0:Telefon>
</ns0:kunde>
<ns0:kunde>
<ns0:Kundennummer>0000000048</ns0:Kundennummer>
<ns0:Name>Brüning</ns0:Name>
<ns0:Vorname>Arne</ns0:Vorname>
<ns0:Straße>Kühnehöfe</ns0:Straße>
<ns0:Hausnr/>
<ns0:PLZ>22761</ns0:PLZ>
<ns0:Ort>Hamburg</ns0:Ort>
<ns0:Telefon>040/89091-220</ns0:Telefon>
</ns0:kunde>
</ns0:kunden>
Now I want to transfer the XML into a complex type in Java, for instance
ArrayList<MyKunde> retKundenliste = new ArrayList<MyKunde>();
The type MyKunde is defined with all needed attributes and the corresponding getter/setter methods. My object getting the XML response from the WS is kundenliste of type javax.xml.soap.SOAPElement (defined by the WS proxy) . What method do I have to use to get all elements from the XML structure transformed into an array of MyKunde?
I can imagine that this task is a standard but as I said I'm new in Java programming.
Many thanks for your help
DetlefI'm not sure but the Wizard should have created accessors for the char_list Adobe in the generated AbcXyzObj.java class. Check this class for the attributes and their getters and setters.
Timo -
Hi all, I'm a newbie in JAVA programming and encountered a problem in XPath.
My XML file is in the form like below:
<Parent index="1">
<Child name="A">11111</Child>
<Parent index="2">
<Child name="A">00000</Child>
I managed to get the value of the child using
(String) xPath.evaluate("//Parent@index='1'/Child", new InputSource(new FileReader(file)));
But is there a way to get the value using a variable named "index" so I can choose which "parent" to obtain?
(String) xPath.evaluate("//Parent@index='{color:#ff0000}index{color}'/Child", new InputSource(new FileReader(file)));
Thanks.
DavidI tried to use the above code but I encountered the following errors. Any ideas? Thanks.
Exception in thread "main" javax.xml.transform.TransformerException: Expected ], but found:
at com.sun.org.apache.xpath.internal.compiler.XPathParser.error(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.consumeExpected(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.Predicate(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.Step(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.RelativeLocationPath(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.LocationPath(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.PathExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.UnionExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.UnaryExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.MultiplicativeExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.AdditiveExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.RelationalExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.EqualityExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.AndExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.OrExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.Expr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.initXPath(Unknown Source)
at com.sun.org.apache.xpath.internal.XPath.<init>(Unknown Source)
at com.sun.org.apache.xpath.internal.XPath.<init>(Unknown Source)
at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.eval(Unknown Source)
at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.evaluate(Unknown Source)
at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.evaluate(Unknown Source)
at FusechainValidator.main(FusechainValidator.java:24)
--------------- linked to ------------------
javax.xml.xpath.XPathExpressionException
at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.evaluate(Unknown Source)
at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.evaluate(Unknown Source)
at FusechainValidator.main(FusechainValidator.java:24)
Caused by: javax.xml.transform.TransformerException: Expected ], but found:
at com.sun.org.apache.xpath.internal.compiler.XPathParser.error(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.consumeExpected(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.Predicate(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.Step(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.RelativeLocationPath(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.LocationPath(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.PathExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.UnionExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.UnaryExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.MultiplicativeExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.AdditiveExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.RelationalExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.EqualityExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.AndExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.OrExpr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.Expr(Unknown Source)
at com.sun.org.apache.xpath.internal.compiler.XPathParser.initXPath(Unknown Source)
at com.sun.org.apache.xpath.internal.XPath.<init>(Unknown Source)
at com.sun.org.apache.xpath.internal.XPath.<init>(Unknown Source)
at com.sun.org.apache.xpath.internal.jaxp.XPathImpl.eval(Unknown Source)
... 3 more -
Best approach to transfer and transform data between two Oracle Instances
Let me first preface this post with the fact that I am an Oracle newb.
The current problem I am trying to solve is how to quickly transfer data from a customers legacy database into a new normalized destination that is modeled differently than the legacy data. So, the data not only has to be transferred, but also transformed (into normalized tables)
We have discovered, the hard way, that reading the data using a C++ application and performing inserts (even with indexing and constraints disabled) is just way too slow for what we need. We are dealing with around 20 million records here. I need to determine what the best approach extracting this data out of the source and inserting it into the destination. Any comments or tips are greatly appreciated.
Note: I have read about SQL*Loader and mentioned it to management, but they seem resistant to this approach. It's not totally out of the question though.Oracle has a lot of technologies that fall under the general heading of "replication" to choose from. Going from a database to a flat file and back to another database is generally not the most efficient solution-- it's generally much easier to go straight from one database to another.
Oracle provides materialized views, Streams, and Change Data Capture (CDC)-- any of these would be able to give your new system incremental feeds of data from the old system's data and could be used by whatever routines you write to transform the data between data models.
Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC -
SQL Transformation - Static connection information is inappropriate
Hello,
I'm a newbie to Informatica and I have a problem with the SQL Transformation.
The mapping I created is valid. I created a session and a workflow. I set correct DB connections for the source and target in the "mapping" properties of the session.
But when I start the task it fails with the errors:
[ERROR] Failed to get the connections
[ERROR] Static connection information is inappropriate to create a valid Database handle
In the Informatica help it is written for SQL Transformation for Static connection - which type of connection is my SQL Transformation - "Configure the connection object in the session. You must first create the connection object in Workflow Manager." What does it mean?
Why static information could be inappropriate?
Informatica Version: 8.6.0
Oracle DB Version: 11g2
Informatica is installed on Windows XPHi,
According to your post, my understanding is that you got an error in your PowerView report.
The error may be caused by Kerberos authentication issue due to missing SPN. In order to make the Kerberos authentication work, you need to configure the Analysis Services to run under a domain account, and register the SPNs for the Analysis
Services server.
To create the SPN for the Analysis Services server that is running under a domain account, run the following commands at a command prompt:
Setspn.exe -S MSOLAPSvc.3/Fully_Qualified_domainName OLAP_Service_Startup_Account
Note: Fully_Qualified_domainName is a placeholder for the FQDN.
Setspn.exe -S MSOLAPSvc.3/serverHostName OLAP_Service_Startup_Account
For more information, please see:
How to configure SQL Reporting Services 2012 in SharePoint Server 2010 / 2013 for Kerberos authentication
As this issue is related to PowerView report, if the issue still exists, I recommend you can post you question to PowerView forum.
http://social.technet.microsoft.com/Forums/windows/en-US/home?forum=sqlreportingservices
More experts will assist you, then you will get more information relation to PowerView.
Thank you for your understanding and support.
Thanks & Regards,
Jason
Jason Guo
TechNet Community Support -
Formatting Text - XML newbie wants everything!
Greetings Folks
I am a newbie to this Forum and a relatively newbie to XML.
As usual I want to know everything and do everything . . .
and I want it now! Just kidding!
Here is my first challenge with code following:
Can I add tags to "text" in my .xml file so that I can have
bold, italic, underline and link info embedded when using an .xsl
stylesheet to format same?
Here is my sample .xml file called "demo.xml" produced using
DW8:
quote:
<?xml version="1.0" encoding="iso-8859-1"?>
<?xml-stylesheet href="demo.xsl" type="text/xsl"?>
<demo>
<text>
<start>The quick brown fox</start>
<finish>jumps over the lazy dog</finish>
</text>
</demo>
And here is my .xsl file called "demo.xsl":
quote:
<?xml version="1.0" encoding="iso-8859-1"?><!--
DWXMLSource="demo.xml" --><!DOCTYPE xsl:stylesheet [
<!ENTITY nbsp " ">
<!ENTITY copy "©">
<!ENTITY reg "®">
<!ENTITY trade "™">
<!ENTITY mdash "—">
<!ENTITY ldquo "“">
<!ENTITY rdquo "”">
<!ENTITY pound "£">
<!ENTITY yen "¥">
<!ENTITY euro "€">
]>
<xsl:stylesheet version="1.0" xmlnssl="
http://www.w3.org/1999/XSL/Transform">
<xsl
utput method="html" encoding="iso-8859-1"
doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
doctype-system="<A href="
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/">http://www.w3.org/TR/xhtml1/DTD /xhtml1-transitional.dtd"/>
<xsl:template match="/">
<html xmlns="
http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1"/>
<title>Untitled Document</title>
</head>
<body><table width="300" border="0" cellspacing="0"
cellpadding="0">
<tr>
<td><div align="right"><xsl:value-of
select="demo/text/start"/></div></td>
<td> <xsl:value-of
select="demo/text/finish"/></td>
</tr>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
By asking IE or Firefox to display demo.xml I get the
following result:
The quick brown fox jumps over the lazy dog.
Challenge: Can I have it rendered like this -
The quick
brown
fox jumps
over the
lazy dog
If lazy dog can be made a hyperlink as well then I would say
XML really "ROCKS".
The 2nd challenge is:
Can I have a lengthy passage of text and be able to assign
paragraph breaks so the browser will display sentences in
paragraphs? (I trust this does not need an example and my request
is self explanitory)
If you can help me, with say a working example, I would be so
appreciative.
Thanks in anticipation
AceTutorOdd quesiton but why are you doing it like this ?
XHTML sounds like what you want ...
Anyhow, you can do all you want - but its a little more
complicated - and
hard to explain here - you need to explicitly state how they
should appear,
within your XSLT ... (I Think, never having done it)
G
"AceTutor@Warwick" <[email protected]> wrote
in message
news:[email protected]...
> Greetings Folks
>
> I am a newbie to this Forum and a relatively newbie to
XML.
> As usual I want to know everything and do everything . .
. and I want it
> now!
> Just kidding!
>
> Here is my first challenge with code following:
> Can I add tags to "text" in my .xml file so that I can
have bold, italic,
> underline and link info embedded when using an .xsl
stylesheet to format
> same?
>
>
> Here is my sample .xml file called "demo.xml" produced
using DW8:
>
> <blockquote>quote:<br><hr><?xml
version="1.0" encoding="iso-8859-1"?>
> <?xml-stylesheet href="demo.xsl" type="text/xsl"?>
> <demo>
> <text>
> <start>The quick brown fox</start>
> <finish>jumps over the lazy dog</finish>
> </text>
> </demo>
> <hr></blockquote>
>
> And here is my .xsl file called "demo.xsl":
>
> <blockquote>quote:<br><hr><?xml
version="1.0" encoding="iso-8859-1"?><!--
> DWXMLSource="demo.xml" --><!DOCTYPE xsl:stylesheet
> <!ENTITY nbsp " ">
> <!ENTITY copy "?">
> <!ENTITY reg "?">
> <!ENTITY trade "?">
> <!ENTITY mdash "?">
> <!ENTITY ldquo "?">
> <!ENTITY rdquo "?">
> <!ENTITY pound "?">
> <!ENTITY yen "?">
> <!ENTITY euro "?">
> ]>
> <xsl:stylesheet version="1.0" xmlnssl="<a
target=_blank
> class=ftalternatingbarlinklarge
> href="
http://www.w3.org/1999/XSL/Transform">
> <xsl
utput">
http://www.w3.org/1999/XSL/Transform">
> <xsl
utput</a> method="html" encoding="iso-8859-1"
> doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
doctype-system="<A
> href="<a target=_blank
class=ftalternatingbarlinklarge
> href="
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/">http://www.w3.o
> rg/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>
>
> <xsl:template">
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/">http:/
> /www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>
> <xsl:template</a> match="/">
> <html xmlns="<a target=_blank
class=ftalternatingbarlinklarge
> href="
http://www.w3.org/1999/xhtml">
> <head>
> <meta">
http://www.w3.org/1999/xhtml">
> <head>
> <meta</a> http-equiv="Content-Type"
content="text/html;
> charset=iso-8859-1"/>
> <title>Untitled Document</title>
> </head>
> <body><table width="300" border="0"
cellspacing="0" cellpadding="0">
> <tr>
> <td><div align="right"><xsl:value-of
select="demo/text/start"/></div></td>
> <td> <xsl:value-of
select="demo/text/finish"/></td>
> </tr>
> </table>
> </body>
> </html>
> </xsl:template>
> </xsl:stylesheet>
>
>
>
> By asking IE or Firefox to display demo.xml I get the
following result:
>
>
> The quick brown fox jumps over the lazy dog.
>
>
> Challenge: Can I have it rendered like this -
>
> The quick <b>brown</b>
<u>fox</u> jumps <i>over</i> the <a
target=_blank
> class=ftalternatingbarlinklarge href="
http://www.google.com">lazy
dog</a>
>
> If lazy dog can be made a hyperlink as well then I would
say XML really
> "ROCKS".
>
>
> The 2nd challenge is:
> Can I have a lengthy passage of text and be able to
assign paragraph
> breaks so
> the browser will display sentences in paragraphs? (I
trust this does not
> need
> an example and my request is self explanitory)
>
>
> If you can help me, with say a working example, I would
be so
> appreciative.
>
> Thanks in anticipation
>
>
> AceTutor
>
> -
PS CC newbie with layer translate question
I am a newbie in PS. Currently I am using Adobe PS CC, in which I want to merge quite a number of images together to form a "collage". Those images are already named with coordinates, like (0, 1).png with size 1280 x 1280 pixel, and I already load all of them into a PS document by photomerge. I suppose each of them is contained in a independent layer, and I can use free transform to move those layers to my required position such that those images can resemble into a large image like a puzzle. When the number of layers is large, doing this by hand is really a tedious work. So I want to automate it with the script. I have try the following script and run it, but without any response; please correct me as I am new (and also new in JavaScript as well)
# target photoshop
function Main()
MoveLayerTo = function(l, x, y) {
var b = l.bounds;
var x1 = b[0].as("px");
var y1 = b[1].as("px");
var x2 = b[2].as("px");
var y2 = b[3].as("px");
var xc = x1 + (x2-x1)/2;
var yc = y1 + (y2-y1)/2;
l.translate(x-xc, y-yc);
var i = 0;
var j = 0;
for (i = -6; i < 3; i++) {
for (j = 3; j > -11; j--) {
MoveLayerTo(app.activeDocument.layers.getByName("(" + i + ", " + j + ").png"), new UnitValue(640 + (i + 6) * 1280, "px"), new UnitValue(640 + (3 - j) * 1280, "px"))Photo Collage Toolkit
Photoshop scripting is powerful and I believe this package demonstrates this A video showing a 5 image collage PSD template being populates with images:
The package includes four simple rules to follow when making Photo Collage Template PSD files so they will be compatible with my Photoshop scripts.
Size the photo collage templates for the print size you want - width, height and print DPI resolution.
Photo collage templates must have a Photoshop background layer. The contents of this layer can be anything.
Photo collage templates must have alpha channels named "Image 1", "Image 2", ... "Image n".
Photo collage templates layers above the background layers must provide transparent areas to let the images that will be placed below them show through.
There are twelve scripts in this package they provide the following functions:
TestCollageTemplate.jsx - Used to test a Photo Collage Template while you are making it with Photoshop.
CollageTemplateBuilder.jsx - Can build Templates compatible with this toolkit's scripts.
LayerToAlphaChan.jsx - Used to convert a Prototype Image Layer stack into a template document.
InteractivePopulateCollage.jsx - Used to interactively populate Any Photo Collage template. Offers most user control inserting pictures and text.
ReplaceCollageImage.jsx - use to replace a populated collage image Smart Object layer with an other image correctly resized and positioned.
ChangeTextSize.jsx - This script can be used to change Image stamps text size when the size used by the populating did not work well.
PopulateCollageTemplate.jsx - Used to Automatically populate a Photo Collage template and leave the populated copy open in Photoshop.
BatchOneImageCollage.jsx - Used to Automatically Batch Populate Collage templates that only have one image inserted. The Collage or Image may be stamped with text.
BatchMultiImageCollage.jsx - Used to Automatically Batch Populate Any Photo Collage template with images in a source image folder. Easier to use than the interactive script. Saved collages can be tweaked.
BatchPicturePackage.jsx - Used to Automatically Batch Populate Any Photo Collage template with an image in a source image folder
PasteImageRoll.jsx - Paste Images into a document to be print on roll paper.
PCTpreferences.jsx - Edit This File to Customize Collage Populating scripts default setting and add your own Layer styles.
Documentation and Examples -
Complete newbie to Adobe Photoshop Elements 10.
When using 'Free Transform' how do you stop a blue background/outline appearing?
I've tried repositioning revised image but cannot avoid getting some blue showing.
All and any help appreciated.Thanks very much Elements User
I thought that was the way but there are so many choices of Layer I wasn't sure which one to use.
Also confused at the difference between 'Layer by Copy' and 'Duplicate Layer' - aren't they the same thing????
Also didn't get the option or understand instruction given in Help, which I don't think are very clear :-
Note: If you select a photo that is a Background layer (such as a photo imported from a camera or scanner), you are given the option of turning it into a regular layer so that you can transform it.
I now assume the option mentioned is done by choosing from Layer menu.
Was trying to make flower larger (altho still got outline) & I have now succeeded following your instructions.
Thanks again.
73/92 -
Help!!! Newbie here!
Alright. I have CS3 and am 'trying' to get used to it. I am trying to do a vintage effect and of course this takes many steps. One of the steps (almost one of the lasts) is to go to Filter>Distort>Lens Correction AND then from there, use the Vignette Slider, etc...
Well, Under MY Filter, there is NO distort, there was in my CS2, so I dunno what the deal is. I used the Help Search and it found the distort under the Edit>Transform>Distort. BUT, the distort is greyed out! I have tried everything. It IS in 8 bit, I've even tried 16 bit... NOT working. The only time distort even comes up is if I go to another 'blank' layer... and of course, I can't do anything with it! :(
so, what do i need to do to get the distort working... it's there, but it's greyed out. Please help. And I don't know if this will give my email or not, please feel free to email me also with your help! :D thanks!
[email address deleted]
A*Andrea,
>Help!!! Newbie here!
I know you're new here, and I'd like to welcome you to this forum. However, please understand that (in addition to the previous posts here), a generic "HELP!!!" subject line won't bring you responses: Folks scanning the topics have no idea what the problem is, and even if they may have an answer, they may not bother to click on the generic topic, read it and post.
As a Forum Host, I can change your topic subject line to be more useful and drive more traffic to it, if you wish. Please post back how you'd like to change it.
Neil
Maybe you are looking for
-
Hello. I am having some issues localizing JSP to Japanese. I have read a lot of stuff on the topic. I have my .properties file in unicode with native2ascii, etc. When I debug under Eclipse 3.0, I see the Japanese characters correctly displayed in my
-
Right-clic​king titlebar halts Ethernet
I have an application that is receiving a stream of 19B messages over Ethernet at 12.8kHz. Within the 19B, I have a counter used to check integrity of the message ensuring I do not miss any messages. The stream works, and my application can process t
-
Problem opening workbook with parameter LOV
hi, i have created a parameter LOV that contains a huge amount of data. i have set the query timing in discov admin as well as desktop so that it comes fine there. but when i try to open the LOV page in the workbook in viewer its giving me the error
-
Migrated all apps ok except Office for Mac 2008
I just bought a new iMac and migrated all data from my old Mac using Migration Assistant. Everything works fine except for Office for Mac 2008. When I try to open eg a s/sheet (Excel being the default app) Microsoft setup assistant wants to set up ac
-
IE Problem with opening XLS from remote host
So Im having a problem opening/saving my generated Excel Spreadshhet in Internet Explorer on a remote client. Basically, I click on my button to generate the spreadsheet, it then sends the data to my servlet that generates the document and then send