Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

Java - JSP + XML

Name: Anonymous 2011-05-14 7:09

I don't get it.
My XML file is perfectly fine.
My JSP file is painfully simplistic.

So why is it giving me shit about a premature end of file when I try to do this?


<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/xml" prefix="x"%>

<html>
  <head>
    <title>cust_xml</title>
  </head>
  <body>

    <h1>Customer Information</h1>
    <c:import var="xmlFile" url="cust.xml" />
    <x:parse var="myDoc" xml="${xmlFile}" />

Name: Anonymous 2011-05-14 7:11

NO EXCEPTIONS

Also, if you can't see your blatant invalid XML you posted, you do not deserve even the air your breathing right now.

Name: Anonymous 2011-05-14 7:14

If you're talking about not capitalizing the CUST part of CUST.xml, you sir are incorrect! I changed the name of the file to have a more suitable placeholder for the code example.

Name: Anonymous 2011-05-14 7:18

It's not capitalization. It is more blatant. It made my eyes bleed. And theyn't stop bleeding.

You'll be liable for my death by blood loss. I'll sue you.

Name: Anonymous 2011-05-14 7:19

Sorry, but truth be told I've been up WAY too long doing shit, and I haven't the desire to beat around the bush with this. What am I overlooking?

Name: Anonymous 2011-05-14 7:21

I'm not here to solve your homework, ``faggot''.

Name: Anonymous 2011-05-14 7:23

It's 7:22 AM on a Saturday, what faggot does homework on a Friday night?

I just want to make this work. That's it. Load the XML file, so the JSP can move onto the shit I need to actually do. Take it or leave it.

Name: Anonymous 2011-05-14 7:25

Just looked up all the syntax and fields and shit:

<c:import var="importFile" url="employee.xml"/>
<x:parse var="doc" doc="${importFile}"/>


It's exactly the same as how I have it.

The only problem I see here is that I didn't include the rest of the JSP in my code, but that's of no consequence because the subsequent code is extraneous in this situation.

Name: Anonymous 2011-05-14 7:26

You could have a deadline fixed on Saturday or Sunday by uploading your homework to a server, which doesn't need human supervision at all.

You won't fool me.

Name: Anonymous 2011-05-14 7:27

and yes, I notice what I just posted has doc= instead of xml=, but it gives me the same error, so..

Name: Anonymous 2011-05-14 7:29

Actually, my last final was on Tuesday night. It was a Short Story class. That class was boring as fuck.

http://www.strose.edu/download.aspx?libitemid=24114&file=Spring%202011%20UG%20calendar%20for%20web.doc



Either offer a helpful suggestion or fuck off, I didn't come here to deal with you.

Name: Anonymous 2011-05-14 7:34

You sent the link in Microsoft Word format, a secret proprietary format, so it is hard for me to read. If you send me plain text, HTML, or PDF, then I will read it.

Distributing documents in Word format is bad for you and for others. You can't be sure what they will look like if someone views them with a different version of Word; they may not work at all.

Receiving Word documents is bad for you because they can carry viruses (see http://en.wikipedia.org/wiki/Macro_virus_(computing)). Sending Word documents is bad for you because a Word document normally includes hidden information about the author, enabling those in the know to pry into the author's activities (maybe yours). Text that you think you deleted may still be embarrassingly present. See http://news.bbc.co.uk/2/hi/technology/3154479.stm for more info.

But above all, sending people Word documents puts pressure on them to use Microsoft software and helps to deny them any other choice. In effect, you become a buttress of the Microsoft monopoly. This pressure is a major obstacle to the broader adoption of free software. Would you please switch to a different way of sending files to other people, instead of Word format?

To convert the file to HTML using Word is simple. Open the document, click on File, then Save As, and in the Save As Type strip box at the bottom of the box, choose HTML Document or Web Page. Then choose Save. You can then attach the new HTML document instead of your Word document. Note that Word changes in inconsistent ways—if you see slightly different menu item names, please try them.

To convert to plain text is almost the same—instead of HTML Document, choose Text Only or Text Document as the Save As Type.

Your computer may also have a program to convert to PDF format. Select File, then Print. Scroll through available printers and select the PDF converter. Click on the Print button and enter a name for the PDF file when requested.

See http://www.gnu.org/philosophy/no-word-attachments.html for more about this issue.

Name: Anonymous 2011-05-14 7:36

Either offer a helpful suggestion or fuck off

I'll choose to fuck off. It'll be less painful.

Name: Anonymous 2011-05-14 7:39

if anyone feels like helping me out with the OP, I'm ignoring any troll replies now

Name: Anonymous 2011-05-14 7:43

I'm afraid I can't help you, I'm far too much of a fag.  If anyone on here isn't a huge fag, maybe they can help you.  If no one helps you, I would presume, if I were you, that everyone who didn't help you but could have was too busy thinking of potential cocks they would like to suck.

Name: Anonymous 2011-05-14 7:45

Indeed that is correct

Name: Anonymous 2011-05-14 8:10

expecting useful advice from [spoiler]/prog/[spoiler]

............................................________
 ....................................,.-'"...................``~.,
 .............................,.-"..................................."-.,
 .........................,/...............................................":,
 .....................,?......................................................\,
 .................../...........................................................,}
 ................./......................................................,:`^`..}
 .............../...................................................,:"........./
 ..............?.....__.........................................:`.........../
 ............./__.(....."~-,_..............................,:`........../
 .........../(_...."~,_........"~,_....................,:`........_/
 ..........{.._$;_......"=,_......."-,_.......,.-~-,},.~";/....}
 ...........((.....*~_......."=-._......";,,./`..../"............../
 ...,,,___.\`~,......"~.,....................`.....}............../
 ............(....`=-,,.......`........................(......;_,,-"
 ............/.`~,......`-...............................\....../\
 .............\`~.*-,.....................................|,./.....\,__
 ,,_..........}.>-._\...................................|..............`=~-,
 .....`=~-,_\_......`\,.................................\
 ...................`=~-,,.\,...............................\
 ................................`:,,...........................`\..............__
 .....................................`=-,...................,%`>--==``
 ........................................_\..........._,-%.......`\
 ...................................,<`.._|_,-&``................`

Name: Anonymous 2011-05-14 10:17

</body>
</html>

You're welcome.

>>12 I'm pretty sure PDF is proprietary too. You should've asked for Latex.

Name: Anonymous 2011-05-14 10:21

>>18

See:
>>8

Name: Anonymous 2011-05-14 10:35

>>19
premature end of file
Of course, it's not at all extraneous.

Name: Anonymous 2011-05-14 11:24

>>18
ISO 32000-1:2008

Name: Anonymous 2011-05-14 11:30

>>21
Huh. I learnt something new today.

Name: Anonymous 2011-05-14 11:33

>>22
This is the true /prog/: unhelpful or those asking for help, yet enlighting for the enlighted.

Maybe we can still save this place.

Name: Anonymous 2011-05-14 12:11

>>21
ECMA-376
ISO/IEC 29500

Don't change these.
Name: Email:
Entire Thread Thread List