Help-simple-stupid-problem

I am having jswdk1.0.1 . My servlets are working.
Now I want to run my JSP code. My JSP code contains "Hello World" in a loop .The for loop is in a JSP tag. Whatever may be the value of loop(0) , browser shows Hello World only once. In short JSP is not working.
The problem maybe in classpath variable.( I have Win98, Apache is not working on my m/c)
Please tell me where & how to write it.

<% for (....)
%>
<h1> hello world<\h1>
<\body>
<\html>What do you mean by "the jsp tags are not recognised"?
If the above code is the exact code you are using, then you need to close the for loop:
<% for (....)
%>
<h1>  hello world<\h1>
<%
%>
<\body>
<\html>However, the code shouldn't compile if that's the problem...
Does the JSP code get printed to the screen? or is it in the page source after you've opened the page? If so, then your page isn't getting served properly by the JSP engine - its probably oin the wrong place. What's the URL you use to accesss the page? and what directory is it in?

Similar Messages

  • Help! Stupid problem with user accounts!

    I got a very old, very cheap laptop (original ibook clamshell). The Short Name referred to one of the previous owners. I had a vague idea of changing it, but realised this might be difficult. I haven't really got a rescue CD at present; the OS must have gone through several OS versions on the way, and it won't run Tiger which is what I have on my desktop.
    The OS is up to late Panther. I haven't had any problems with it. Having some time on my hands, I picked up an O'Reilly book on 'Panther hacks', and went through the 'Change Short Name' routine with netinfo. Before doing this, I made sure there werent any document files on the machine I'd be bothered about losing. It has less than 1Gb hard drive space, so I've never regarded it as a machine to keep things on.
    Went through the process of doing this, and moving the home directory, without problems.
    Logged out. Discovered that there were two users with my name because I'd also created another user with my name but realised that the main account with the Short Name will run the machine. Logged in, and deleted one of them into Deleted Users.
    This took a suspiciously long time; I suspect I deleted the main user by mistake. Yes, I realise this was a Bad Thing.
    Suddenly, instead of having two administrator accounts with my name, I have one standard account with my name. (Yes, both accounts were administrator accounts before I deleted the wrong one by accident...)
    I haven't particularly lost data, because any data created on Methuselap the Ancient of Days's minuscule hard drive gets networked straight over to my main desktop, and I don't have a login password set (again, anything that needs to be secure can go on a flash drive or the desktop), I'm annoyed (mostly at my own stupidity) that I am now no longer able to fix my privileges to set myself up as admin.
    Has anybody got any particular bright ideas for what to do next?

    Ruth,It will be of benefit to others who may find a similar situation to yourself if you mark Niel's post as 'Helpful' or more probably 'Solved' and the overall case as answered.
    This will also credit Niel for providing the help and push him 10pts closer to getting his Level 5 status!
    thanks
    mrtotes

  • Help simple 3d problem

    Hey,
    I practice director and work simple car game.
    I have done moving and collision and motion but i have one problem.
    Now, player is #box and should be car model.
    I have in 3d scene model car what name is "killercar".
    Problem is how i change this sphere to killercar.
    My code is:
      --boxR = scene.newModelResource("player R",#box)
      --my = scene.newModel("player",boxR)
    These what i try, not work:
    boxR = scene.newModelResource("player R",model("killercar"))

    Is there anyway to reset to the original settings?
    You simply delete the prefs in C:\Users\You\AppData\Roaming. I'm still not clear what exactly you are doing, though. If you are using the 3D extruded text you'll just have to live with it. That stuff is slow as hog... Only the conventional flat text will render faster, but only if you set the comp to the Standard 3D renderer.
    Mylenium

  • HELP - Simple JMS Problem

    package com.tpc.jms.simpleProducer;
    import javax.jms.*;
    import javax.naming.*;
    import java.util.Hashtable;
    import java.util.Properties;
    public class SimpleJMSTest {
    public static final String PROVIDER_URL = "jms://localhost:7676";
    public static final String CONTEXT_FAC = "com.sun.jndi.cosnaming.CNCtxFactory";
    public static void main (String argv[]) {
    try {
    Properties properties = new Properties();
    properties.put(Context.PROVIDER_URL, PROVIDER_URL);
    properties.put(Context.INITIAL_CONTEXT_FACTORY, CONTEXT_FAC);
    properties.put(Context.SECURITY_PRINCIPAL, "guest");
    properties.put(Context.SECURITY_CREDENTIALS, "guest");
    InitialContext initialCtx = new InitialContext(properties);
    System.out.println("Good!");
    //TopicConnectionFactory topicConnFactory = (TopicConnectionFactory) initialCtx.lookup (fac);
    //Topic nasdaqTopic = (Topic)initialCtx.lookup(topic);
    /* System.out.println("Creating topic connection");
    TopicConnection topicConnection = topicConnFactory.createTopicConnection();
    topicConnection.start ();
    System.out.println("Creating topic session: not transacted, auto ack");
    TopicSession topicSession = topicConnection.createTopicSession(false, Session.AUTO_ACKNOWLEDGE);
    System.out.println("Creating topic, subscriber");
    TopicSubscriber nasdaqTopicSubscriber = topicSession.createSubscriber (nasdaqTopic);
    System.out.println ("Ready to subscribe for messages :");
    nasdaqTopicSubscriber.setMessageListener(new SubscriberListener());*/
    catch (Exception e) {
    e.printStackTrace ();
    This gives me an exception:
    javax.naming.ConfigurationException: Invalid URL: mq:localhost:7676 [Root exception is java.net.MalformedURLException: unknown protocol: mq]
    What is the protocol? I've tried http, mq, jms, mqtcp (I know its running on a TCP port).
    What is going on here?

    the protocol depends on ur jms vendor..say for weblogic they use t3..try uisng "iiop" btw..whats ur server?

  • Simple OOP Problem. Help!

    This is just a simple OOP problem that i cant decide on a best
    implementation for.
    im passing an object to an instance of, 'TabbedFrame', which is just
    a frame with a Tabbed Pane in it that is holding custom panels.
    however, these custom panels need access to the object being
    passed to 'TabbedFrame' and to some methods in it.
    i cant make them static however so how do i gain access to them?
    is my only option to pass the 'TabbedFrame' to each panel?
    like - jtabbedpane.add( "Panel 1", new mypanel1(this));
    here is code:
    new TabbedFrame( DataObject );
    public class TabbedFrame{
    public TabbedFrame(DataObject do){
    this.do = do;
    jtabbedpane.add( "Panel 1", new mypanel1() );
    DataObject do;
    public class mypanel1{
    public mypanel1(){
    // need access to DataObject of the 'TabbedFrame' object that instantiated
    // this 'mypanel1' and to some of its methods
    }i would just pass the DataObject to evey panel (there are 12) but
    i also need to be able to call methods in the 'TabbedFrame'.
    Any help would be appreciated!

    Modify mypanel1's constructor:
    public class mypanel1{
    TabbedFrame tf;
    public mypanel1(TabbedFrame tf){
    this.tf = tf;
    // need access to DataObject of the 'TabbedFrame' object that instantiated
    // this 'mypanel1' and to some of its methods
    DataObject theDo = tf.getDataObject();
    tf.someMethod(); // Call method on the TabbedFrame
    }In TabbedFrame:
    public TabbedFrame(DataObject do){
    this.do = do;
    // Modify call to constructor to pass "this" TabbedFrame.
    jtabbedpane.add( "Panel 1", new mypanel1(this) );
    }

  • Real simple xslt problem/question

    Hi, i have a real simple xslt problem but i just cant figure out how to do it by looking at various examples on the net. i have a xml document and in it are some elements with a "result" tag name. i want to use xslt to reproduce exactly the same xml document except with an attribute called "id" added to those elements with a "result" tag name. i'm sure that theres a simple solution to it but i just cant figure it out. any helps greatly appreciated, thanks

    Start with the XSLT identity transform (I don't have it handy and it's fairly long, but you should be able to google it up). Add this:<xsl:template match="result">
      <result id="">
        <xsl:apply-templates>
      </result>
    </xsl:template>

  • Help with systemd problems/reply to closed thread

    @Everyone; as the previopus topic was closed, I am opening a new one here, partly to reply to some things that was said to me in the previous thread/topic (and I do not like to leave people hanging), but mainly to try and get some help with my systemd config (that I was not able to find help with in the wiki or manpages).
    @czubek; eww, that sounds rather similiar to some other operating systems I've heard of (not just, but obviously including, windows)... For me, subjectively, that is not very attractive, as being able to have a single application do a single thing, and then mixing and matching as I personally see fit is a great thing.
    @tomegun: I can indeed see your point, but if I made direct quotes on all the things I reply too, my posts would reach biblical proportions.
    Mmm-hmm, I do indeed know of "the Arch Way"; however, the system that you expose can be of varying complexity as well, and I found that the system that was presented to me by way of Sysvinit/initscripts was a way simpler system than that presented to me by systemd.
    Indeed, and I do like that; I enjoy knowing how my system works and learning more about it; however, the truth is that reading manpages and the wiki isn't always enough. And I use the numbers instead of letters in certain places as a jest, please, do not get offended by that; if you have to, get offended by my opinions.
    Ah, I have now scanned the wiki, the manpages, and have already faced problems. While part of me is saddened by this fact (as I was hoping for a smooth transition to systemd), part of me is glad that I can at least prove that everything isn't quite as simple as some people would make it out to be. More on this later in this post, as I do need help with the problems I have faced.
    And I wouldn't say that the new and old way are equally trivial, as I immediatley faced problems with "the new way". More on this later.
    Ok, I find that if the debate is polarized, then there is nothing wrong with describing it as such. I spell what I see.
    Oh my... Ignored as a matter of principle? I would say that that is an excellent way to stagnate; by that logic, moviemakers, gamemakers etcetera should ignore any and all criticism they recieve, as the critics are not contributing.... Wouldn't that lead to a complete halt in development? Isn't criticism (so long as it is constructive, obviously) a key component of (media/software) evolution?
    Ah, I see, then I  misunderstood the current state of the install media
    "Some adjustements"... Well, I guess we'll have to see how that goes, then. Hopefully it'll be smooth.
    @Everyone; Awebb possesses stunning accuracy as far as his observations go.
    @zb3; My point exactly.
    @tomegun; I believe you to be wrong; complaining (but not whining) is the first step towards improvement, as I think that I and zb3 has shown.
    Further, your last point (where you talk about "deep understanding of Y" and whatnot) is basically saying that only devs and programmers can contribute, so zb3's observation would be correct.
    Also, making suggestions is part of constructive criticism; you can do that even if you can't code, e.g. by saying "X works badly because it makes Y crash; couldn't we replace X with something akin to Z?". This is a valid point even if you have no intricate understanding of X, Y or Z, and if it is impossible to replace X for one reason or the other, it's not hard to reply with "Replacing X is impossible because of reason Q", and then see if someone can solve reason Q etcetera.
    zb3's example is obviously helping; for one, it would allow people to know taht they can't boot with systemd in certain cases, or that installing/runing systemd can break their system. I would consider that rather important information.
    @Everyone; Now then, to see if I can (or rather, if I can get help to) shed some light on some problems I've been having.
    My transition to systemd went pretty smooth (besides the fact that I couldn't use 'systemctl' to set anything, and neither duckduckgo nor any posts in the forums could help me (the error I continously got was "Failed to issue method call: Launch helper exited with unknown return code 1") and that there are no manpages/tips on how to configure the files for "localtime" and "adjtime", which would've been good considering some syntax have changed) to about halfway through, to the point where I was supposed to start using systemd for my daemons.
    Now then, to the main problem; first, I tried running
    "systemctl enable syslog-ng.service"
    and got the following message;
    "ln -s '/usr/lib/systemd/system/syslog-ng.service' '/etc/systemd/system/syslog.service'
    ln -s '/usr/lib/systemd/system/syslog-ng.service' '/etc/systemd/system/multi-user.target.wants/syslog-ng.service'"
    Since it doesn't exclusively say that something went wrong (at least as far as I can understand), I pondered the message a bit, but moved on to try and start dbus by issuing
    "systemctl enable dbus.service",
    to which I got the reply
    "The unit files have no [Install] section. They are not meant to be enabled using systemctl."
    This I can only assume is an error message of some sort, especially seeing as it says "not meant to be enabled using systemctl", but the wiki rather explicitly states that that is what I am supposed to do.
    I dare not move on (or attempt to start other daemons) without further advice, as I fear I might break my system. Any ideas as to how to solve this would be greatly appreciated.

    tcmdvm wrote:
    The message;
    "ln -s '/usr/lib/systemd/system/syslog-ng.service' '/etc/systemd/system/syslog.service'
    ln -s '/usr/lib/systemd/system/syslog-ng.service' '/etc/systemd/system/multi-user.target.wants/syslog-ng.service'"
    indicates that running "systemctl enable syslog.service" is now enabled.
    If you try running sytemtctl enable <whatever>.service and get
    "The unit files have no [Install] section. They are not meant to be enabled using systemctl." means there is no <whatever>.service file available to enable.
    The dbus.service as far as I know is already enabled when installing systemd and doesn't require any action.
    Ah, right, systemd is chatty (I'm of the old skool; if nothing is/goes wrong, a program should keep quiet).
    Oh ok, then I should dare more on.
    ZekeSulastin wrote:To be a bit more precise, it means the service is there but it's only used as a dependency for something else; the [Install] section of the file is what tells systemctl where to link it and such.  Also, where exactly in the wiki were you told explicitly to 'systemctl enable dbus.service'?  I can easily point you to the sections in both installation guides that tell you how to set things like /etc/localtime et. al (also `man 7 archlinux`), but not the one that said to manually enable dbus.
    Ah, I see; and well, I was told right here, going from the top, to "Enable Daemons formerly listed in rc.conf [...] For a translation of the daemons from /etc/rc.conf to systemd services, see: List of Daemons and Services.", and, using the list, dbus is mentioned there, as you can see. Since I started from the top, I did not know that you didn't need to enable that service. Perhaps it could be added to the descriptions of the relevant services in the Wiki which ones are autostarted?
    ZekeSulastin wrote:Lastly, I don't think trying to continue conversations from a closed thread is a very good idea, let alone doing it in a giant undivided wall of text that makes it quite difficult to pick out much any single topic.
    Meh, I directly refer to the relevant people, they can easily see their own old posts in the previous thread, etcetera... I think te ones who have something to say will be able to find my replies to their previous statements (or so I hope). For now, as everyone can see, I quote stuff (but man might I make some huge posts if I ever post again in the future, if I quote what I reply to).
    fsckd wrote:This is not really a technical support subforum. Moving from Arch Discussion to Newbie Corner.
    Ah ok, thanks (or perhaps a cautious thanks? Moving it to "newbie corner" might, after all, be a subtle insult...).
    tomegun wrote:It is not really possible to follow your message as you don't quote what you are replying to. Moreover, as the thread was closed I think that means we should stop the discussion ;-)
    Hmm, I think it means cop-out for lack or proper arguments/responses... But ok, I'll let it slide, for now (mainly as I can't do much else).
    tomegun wrote:You are not meant to enable dbus.service as it is enabled unconditionally. To check the enabled/disabled state of your services try "systemctl list-unit-files". "static" means that you are not supposed to enabled/disable it.
    Ah ok, thank you. Now, having abandoned all hope, I'll start configuring again and see how it goes... May the void protect me. If I die, grieve not for me, but remember me in the fight against hard-to-configure applications.
    (edit/addon)
    Actually, what am I supposed to do with "hwclock"? the List of Daemons only says that I shouldn't run that in tandem with ntpd, but I'm not running ntpd, so... How do I get hwclock with systemd?
    Edited for additional question.
    Last edited by incassum (2012-11-07 08:44:42)

  • HT1386 How do I copy music from an old iPod?  Why do you have to make things so difficult?  These are my files that I paid for but once I put them on your devices, I no longer have control over them.  I've wasted so much time on these stupid problems.

    How do I copy music from an old iPod?  Why do you have to make things so difficult?  These are my files that I paid for but once I put them on your devices, I no longer have control over them.  I've wasted so much time on these stupid problems.  I used to be able to do this until you "improved" things.

    Thanks, Deggie. I thought Apple would see my feedback.  I would just like to know if there is a simple way to copy just a few music files from an old iPod.  I saw instructions on how to copy all of them from the iPod but it was complicated and I really didn't want to copy all the songs.  I guess I could delete all the songs but the ones I want to copy then go through that process again.  Do you know how to back up music to my computer?  I don't want to have to go through this again and possibly lose music.

  • Help racecar game problem

    im really not that good at java and this may just be a simple structure problem or there may be no way to do what i want but i thought id just make sure before i proceed and do it another less organised way
    im making a top down veiw car racing game where hte user can select different cars. i would like each car type to have a seperate class that just simply defines the varibles for that car (ie mass, length inertia etc). then a generic racingcar class that can access them.
    howver the problem im having is that since each cartype class has a different name so i cant extend or implement them in my racecar class (maybe theres a way to dynamically set what a class extends/implements?)
    and i cant have a varible pointing to it because id have to define one for each cartype
    if you have any insight or an obvious answer im just not seeing oculd you help me please

    abstract class BaseCar
       void update()
          //some logic code, including a call to getMaxSpeed()
       //definition is required in the subclass
       abstract float getMaxSpeed()
    class SuperCoolFastCar extends BaseCar
       float getMaxSpeed()
          return 10000.0;
    }and then in your main class
    BaseCar [] theCars = new BaseCar[numCars]
    theCars[0] = new SuperCoolFastCar();
    theCars[1] = new SlowButGrippyCar();
    //etc etc

  • Help ! n82 problem..

    help me...i cant start my n82...i press the on button , it vibrate and stuck at a black screen..after take out battery and restart many times , still the same...

    I have exactly the same problem since JANUARY when Nokia returned my phone exactly that way! yes, you are reading right, Nokia broke my n82 (initially, i send it in DECEMBER for a simple vibrant problem which was a fabrication problem) since then i'm fighting to get a refund or a new phone, you can't even imagine how i'm **bleep** of (excuse me for the language but sending a phone 3x times to the Care Service and waiting 3months for nothing makes people kinda nervous!
    First time=> 4weeks=> simple vibrant problem (never knew if it was solved cuz i never managed to start the phone)
    second time=> 3weeks=> the BLACK/WHITE SCREEN problem seemed solved...but it lasted few hours before blocking again while writing a simple text message
    third time=>1week=>  send the phone back on the 28FEBRUARY still waiting....
    ps:2 things are certain from my little experience, I'm over with Nokia and surely this post will get erased as I'm complaining on a Nokia forum.
    Message Edited by yvan1401 on 02-Mar-2009 04:41 PM
    Message Edited by yvan1401 on 02-Mar-2009 04:42 PM

  • Could someone Help please BlueJ Problem

    Ok I am a University Student, and I am at the moment learn Java, as part of my work I have to make a sun descend like the sunset
    I have wrote the method, and got it to work, at the moment though I havent gotten it to loop, and I do not know the command for looping, could someone please tell me the command so I can add it to my program.
    The program I am using to write this is called BlueJ
    Edited by: Devilslore on Oct 7, 2007 12:55 PM

    Devilslore wrote:
    I have wrote the method, and got it to work, at the moment though I havent gotten it to loop, and I do not know the command for looping, could someone please tell me the command so I can add it to my program.You should go to the Sun basic java tutorials on loops. Have a look here at the for loop tutorial:
    http://java.sun.com/docs/books/tutorial/java/nutsandbolts/for.html
    The general tutorial index is here:
    http://java.sun.com/docs/books/tutorial/java/index.html
    The program I am using to write this is called BlueJThis has nothing to do with your problem. It is a tool to help you write java, nothing more. The program you are really using is the java compiler. In fact, in your next post here, consider having a better subject header. The one you listed suggested that this was an IDE (Integrated Development Environment) problem rather than a simple java problem. By mislabeling this header, I will bet that you cut the number of folks reading your question by more than half.

  • Losing connection, support no help - said my problem

    We are located in North Carolina using a server in California & we have a U-verse account  For the past few weeks we've had steadily increasing problems with dropped connections which have ramped up during the past couple of days.  We are essentially dead in the water as I write.  Pings are showing repeated time outs.  Tracers are showing repeated time outs.  Sounds like a problem for AT&T support huh?  Nope, I've been told repeatedly it's OUR problem.  "Trace it, find the IP address were the halt is, find their phone number, call them & get it fixed".  The 2nd rep told me AT&T is only responsible for the 1st 3 hops, any after that are my problem. What?!?!  How can the customer be made responsible for fixing a network problem?  So I'm left sitting here watching our pings drop, and our business go down the drain because "support" thinks I should fix my own problems. What now? 

    Thank you Chris, I had already done the whois & found all the IPs were in the AT&T family which was why I was so insistent they help with the problem.  The bottleneck seems to be somewhere between NC and Atlanta, maybe Charlotte or even Columbia - who knows which way they run this thing. Their Net-Ranges seem to be registered with different cities - for instance 107.192.0.0-107.223.255.255 is registered with Richardson TX; 99.133.205.102 below is registered in Richardson TX although the hop is obviously between NC & Atlanta GA. It just seems to me it would be much, much simpler for AT&T to track this problem than it is for me/us to find it & try to explain to rep after rep what we are finding & convince them there actually is a problem. We had a tech come out & we knew up front he would know nothing about the internet service, but told he us who to contact that may be able to help (hey, we weren't getting anywhere with the support line)  - a cellphone salesman. On contacting the sales rep we were told to call back to the support line & ask to put in a "Tier 2" support ticket. That got us no where. Told us it was our router, not AT&T, even though pings show time outs on their networks, not their problem, that we have a router issue.  We have pinged google & two or three IP addresses at same time; google churns right along, as does yahoo, never times out while the server we really need loses connection over & over & over again.  They said just because we were having time outs did not mean a problem with their connection, said it meant a problem with our router. Giving them the benefit of doubt, we took down the tunnel to test. Same old, same old - bottleneck seems to be at same IP address.  We've had the server run a trace FROM California to us & they get the same error as we get going TO them.  Yes it's an AT&T IP address. Until this afternoon the address bottlnecking was 12.83.102.137 which is coming up an AT&T network IP.  This afternoon we starting getting these disconnects all along the tracer, but mostly before the Atlanta GA connect.  However, as I said, AT&T is stating not their issue, ours, & not even willing to do any checking of the network to help. Sure our ladies can surf the internet & buy stuff on ebay & play on facebook if they were allowed to do so from the workplace, but to do the jobs they get paid to do, nope. U-verse has virtually shut down our billing office.   Slowness we could deal with, shutting down our connection & not allowing us to reconnect is a whole different ballgame.  This is the route each & every one of the pings & tracers to our server are taking from our office address: 107-211-76-2.lightspeed.chrlnc.sbcglobal.net99.133.205.10212.83.102.137 12.122.154.134cr1.attga.ip.att.net [12.122.2.133]cr2.dlstx.ip.att.net [12.122.2.110]12.122.2.82cr84.la2ca.ip.att.net [12.123.30.249]gar3.lsrca.ip.att.net [12.122.129.149]12.116.103.46Server address Obviously AT&T does not want their business customers.  

  • Need help with getResource() problem under weblogic 6.1

    Hey all,
              I've got a serious problem that I can't figure out. This should be really
              simple - but it's alluding me. I have an ear file with a number of servlets
              inside it. This ear file also contains a resource that my servlets want to
              read from. This resource is located (within the ear file) at:
              "/content/structure/a.txt". The file contains raw ascii.
              To have my serlvet read from this file, I thought it would be as simple as:
              URL content =
              servlet.getServletContext().getResource("/content/structure/a.txt");
              // pw is an instance of PrintWriter
              pw.print(content.getContent());
              However, when I execute the above I get the following exception:
              java.lang.NullPointerException
              at
              java.net.URLConnection.stripOffParameters(URLConnection.java:1011)
              at java.net.URLConnection.getContentHandler(URLConnection.java:979)
              at java.net.URLConnection.getContent(URLConnection.java:581)
              OK, so fine - I figure that I'm new to this. The documentation for the URL
              class tells me there is another way around this. It says that rather then
              calling getContent() directly, I can open a stream on the URL and read from
              that, like so:
              URL content =
              servlet.getServletContext().getResource("/content/structure/scenario2resourc
              es.txt");
              FileInputStream fis = content.openStream();
              but when I do this I get the following different exception:
              java.lang.ClassCastException: weblogic.utils.zip.SafeZipFileInputStream^M
              at Utility.writeFileToOutput(Utility.java:134)^M
              Apparently this thing is trying to return a web-logic-specific stream (which
              is incompatible with an FileInputStream) - which I don't want to use or
              learn about since I want my stuff to work under other webservers.
              Can anyone tell me what I'm doing wrong? This should be simple.
              -john
              John Hilgedick
              WisdomTools, Inc.
              [email protected]
              

    Wenjin,
              I appreciate your response. I tried treating it as a normal InputStream -
              but it didn't make any difference. Here's what I did:
              URL content =
              servlet.getServletContext().getResource("/content/structure/scenario2resourc
              es.txt");
              InputStream is = (InputStream)content.getContent();
              And here's the exception:
              java.lang.NullPointerException^M
              at
              java.net.URLConnection.stripOffParameters(URLConnection.java:1011)^M
              at
              java.net.URLConnection.getContentHandler(URLConnection.java:979)^M
              at java.net.URLConnection.getContent(URLConnection.java:554)^M
              at java.net.URL.getContent(URL.java:807)^M
              at Utility.writeFileToOutput(Utility.java:134)^M
              You can see that it is definitely breaking somewhere in getContent().
              If you have any other ideas, I'd appreciate hearing about them.
              -john
              ----- Original Message -----
              From: "Wenjin Zhang" <[email protected]>
              Newsgroups: weblogic.developer.interest.servlet
              Sent: Wednesday, November 20, 2002 5:03 PM
              Subject: Re: Need help with getResource() problem under weblogic 6.1
              >
              > The "/" in getServletContext().getResource("/content/structure/a.txt")
              means the
              > web (WAR) application root, not your EAR root.
              >
              > The ClassCastException is because that content.openStream() is not
              FileInputStream
              > and has nothing to do with Weblogic. You should treat it as normal
              InputStream.
              >
              >
              > "John Hilgedick" <[email protected]> wrote:
              > >Hey all,
              > >
              > >I've got a serious problem that I can't figure out. This should be
              really
              > >simple - but it's alluding me. I have an ear file with a number of
              servlets
              > >inside it. This ear file also contains a resource that my servlets want
              > >to
              > >read from. This resource is located (within the ear file) at:
              > >"/content/structure/a.txt". The file contains raw ascii.
              > >
              > >To have my serlvet read from this file, I thought it would be as simple
              > >as:
              > >
              > >URL content =
              > >servlet.getServletContext().getResource("/content/structure/a.txt");
              > >// pw is an instance of PrintWriter
              > >pw.print(content.getContent());
              > >
              > >However, when I execute the above I get the following exception:
              > >
              > >java.lang.NullPointerException
              > > at
              > >java.net.URLConnection.stripOffParameters(URLConnection.java:1011)
              > > at
              java.net.URLConnection.getContentHandler(URLConnection.java:979)
              > > at java.net.URLConnection.getContent(URLConnection.java:581)
              > >
              > >OK, so fine - I figure that I'm new to this. The documentation for the
              > >URL
              > >class tells me there is another way around this. It says that rather
              > >then
              > >calling getContent() directly, I can open a stream on the URL and read
              > >from
              > >that, like so:
              > >
              > >URL content =
              >
              >servlet.getServletContext().getResource("/content/structure/scenario2resour
              c
              > >es.txt");
              > >FileInputStream fis = content.openStream();
              > >
              > >but when I do this I get the following different exception:
              > >
              > >java.lang.ClassCastException: weblogic.utils.zip.SafeZipFileInputStream^M
              > > at Utility.writeFileToOutput(Utility.java:134)^M
              > >
              > >Apparently this thing is trying to return a web-logic-specific stream
              > >(which
              > >is incompatible with an FileInputStream) - which I don't want to use
              > >or
              > >learn about since I want my stuff to work under other webservers.
              > >
              > >Can anyone tell me what I'm doing wrong? This should be simple.
              > >
              > >-john
              > >
              > >
              > >--
              > >John Hilgedick
              > >WisdomTools, Inc.
              > >[email protected]
              > >
              > >
              >
              

  • My Itunes is no longer allowing me to manage my music on my phone i can no longer select on my iphone to make playlists and delete music. Please help fix my problem.

    My Itunes is no longer allowing me to manage my music on my phone i can no longer select on my iphone to make playlists and delete music. Please help fix my problem. Iphone4s, 32gigs, IOS 7.1.2
    I don't know why it stopped working but it happened a month or two ago but the option on this phone that's usually all the way to the left when you select your device but now its not and I don't know what caused it. ive already tried troubleshooting my problem but have found no help.

    Hello Salmomma,
    Thank you for the details of the issue you are experiencing when trying to connect your iPhone to your Mac.  I recommend following the steps in the tutorial below for an issue like this:
    iPhone not appearing in iTunes
    http://www.apple.com/support/iphone/assistant/itunes/
    Additionally, you can delete music directly from the iPhone by swiping the song:
    Delete a song from iPhone: In Songs, swipe the song, then tap Delete.
    iPhone User Guide
    http://manuals.info.apple.com/MANUALS/1000/MA1658/en_US/iphone_ios6_user_guide.p df
    Thank you for using Apple Support Communities.
    Best,
    Sheila M.

  • I need advise and help with this problem . First , I have been with Mac for many years ( 14 to be exact ) I do have some knowledge and understanding of Apple product . At the present time I'm having lots of problems with the router so I was looking in to

    I need advise and help with this problem .
    First , I have been with Mac for many years ( 14 to be exact ) I do have some knowledge and understanding of Apple product .
    At the present time I'm having lots of problems with the router so I was looking in to some info , and come across one web site regarding : port forwarding , IP addresses .
    In my frustration , amongst lots of open web pages tutorials and other useless information , I come across innocent looking link and software to installed called Genieo , which suppose to help with any router .
    Software ask for permission to install , and about 30 % in , my instinct was telling me , there is something not right . I stop installation . Delete everything , look for any
    trace in Spotlight , Library . Nothing could be find .
    Now , every time I open Safari , Firefox or Chrome , it will open in my home page , but when I start looking for something in steed of Google page , there is
    ''search.genieo.com'' page acting like a Google . I try again to get raid of this but I can not find solution .
    With more research , again using genieo.com search eng. there is lots of articles and warnings . From that I learn do not use uninstall software , because doing this will install more things where it come from.
    I do have AppleCare support but its to late to phone them , so maybe there some people with knowledge , how to get this of my computer
    Any help is welcome , English is my learned language , you may notice this , so I'm not that quick with the respond

    Genieo definitely doesn't help with your router. It's just adware, and has no benefit to you at all. They scammed you so that they could display their ads on your computer.
    To remove it, see:
    http://www.thesafemac.com/arg-genieo/
    Do not use the Genieo uninstaller!

Maybe you are looking for

  • 550 5.7.1 RESOLVER.RST.AuthRequired; authentication required

    Following error i get  when sending mail to SharePoint mail enabled library. It create contac  with  non ruted domain. Domain is not public. Let say that ending of domain is LOC. So it is not registered public domain…  And it is A  contact, not Distr

  • Convert NTSC project to PAL

    I have a completed video project done in NTSC and want to make the identical project in PAL. Is there a set protocol to accomplish this? W

  • Recording User activity and sending it as an email

    Hey Guys... this is the first time I have ever asked a forum a question... but I am totally stumped. I desperately need help from the community. I have a flash project in a site and I don't know what it is you would call what I am trying to do in ord

  • ConfigMgr 2012 Update Source content deleted

    Greetings, I am experiencing a problem that is appears to be the same as the old thread here: http://social.technet.microsoft.com/Forums/en-US/bee18ffb-f779-4aa4-900d-046e7711424c/sccm-2012-source-content-gets-deleted?forum=configmanagergeneral Rathe

  • Strange Flickering

    Ok, here it goes. A guy who works for me made a graphic using photoshops brush strokes filters on a single frame of video that he had exported, he then put text over that layer and saved-for-web as a jpg, imported it into Final Cut Pro and output it