Create dynamic image, dump on server someplace and reference in JSP?

I was thinking about creating dynamic images and referencing them on a JSP
          (creating them is ok). I'm sure this is a pretty standard thing, but I
          don't know how to do it. Any ideas? I tried doing a search on the BEA
          support site (nice changes :>) but nothing very accurate came up.
          Thanks.
          

Assign an ID (e.g. 1234) to the uploaded file. You should abstract the store
          so that it will work on the file system or in the database.
          The JSP will include an image ref to that ID, e.g.
          http://www.myco.com/myapp/imageservlet?id=1234
          The image servlet will retrieve and stream the image. It has to set content
          type etc. You should also verify that the current user has access to the
          requested image if security/privacy is an issue.
          Peace,
          Cameron Purdy
          Tangosol, Inc.
          http://www.tangosol.com/coherence.jsp
          Tangosol Coherence: Clustered Replicated Cache for Weblogic
          "PHenry" <[RemoveBeforeSending][email protected]> wrote in message
          news:[email protected]...
          > Howdy. I just thought of something. If the img is coming across via the
          > stream, how do you reference it in the html/jsp file? I just thought
          about
          > that now as I was getting a cup of coffee. (I need to cut back! :>)
          >
          > Thanks.
          >
          >
          >
          >
          > "Cameron Purdy" <[email protected]> wrote in message
          > news:[email protected]...
          > > If you write it to a file, you are writing it to an OutputStream, right?
          > >
          > > Instead, just write it to the OutputStream that comes from the
          HttpRequest
          > > object. For example:
          > >
          > > <img src="http://www.mysite.com/myapp/my.jsp?name=whatever">
          > >
          > > That would hit your JSP (it would be better to use a Servlet in this
          case
          > > though), and you would stream back the image.
          > >
          > > Peace,
          > >
          > > Cameron Purdy
          > > Tangosol, Inc.
          > > http://www.tangosol.com/coherence.jsp
          > > Tangosol Coherence: Clustered Replicated Cache for Weblogic
          > >
          > >
          > > "PHenry" <[RemoveBeforeSending][email protected]> wrote in message
          > > news:[email protected]...
          > > > Interesting. I'm still a bit new to this stuff. Do you have/know
          where
          > > to
          > > > find some examples?
          > >
          > >
          > >
          >
          >
          

Similar Messages

  • How to create dynamic images in java servlets?

    I want to create dynamic images in java servlet. Can servlet create dynamic images that based on the input data files? The results can be displayed in GIF, JPG..format? how can this be done? any example in internet?
    What OS do I need to install and what other requirements needed if i want to build up a servlet server?
    Thanks a lot!

    Also worth having a look at SVG http://www.w3.org/TR/2001/REC-SVG-20010904/, you can get a viewer at http://www.adobe.com/svg/ or you can use Batik http://xml.apache.org/batik/index.html to convert SVG to other formats such as JPEG.
    HH

  • I need to create a image using some numeric values and i want to display values in image,

    I need to create a image using some numeric values and i want to display values in image, Numeric values be enterd by text file, excel file or user input by dialog box,
    this is the sample if image.
    http://s17.postimg.org/5xvtzbztn/5_01_03_I.png
    128 x 16 Pixels , Back ground Black, Numbers in Red, Should be same as above picture.
    Because i have hundreds of images to create like this.
    If any one can make a script for this it is very good.
    Sorry about my English.
    Thank you.

    Have you checked out data driven graphics?
    https://helpx.adobe.com/photoshop/using/creating-data-driven-graphics.html

  • Creating Dynamic Time Series in Hyperion Profitability and  Cost Management

    I am creating Dimensions in Dimension Library for Hyperion Profitability and Cost Management. Please let me know if we can set Dynamic Time Series for HPCM.
    I can see DTS Manager option for Period Dimension in Hyperion Planning but this option is not available for Period Dimension in HPCM Application.
    Is there any other way to drill down upto weeks level or day level data in Time Series.

    I am also facing the same issue. Does we have any option to create Dynamic time series in HPCM. Please let me know.

  • Dynamic images display issues in FF and Opera

    Dreamweaver 8
    http://daylily.net/polytepals/results.asp?CultivarName=Carolina%20Octopus
    Can someone please help me correct the following problem. The
    dynamic image
    on this page displays properly in Explorer but it will not
    display in Opera
    or Firefox. It works correctly in Netscape when Netscape is
    set to display
    as Explorer.
    This is affecting all my dynamic images.
    Thank you,
    Bobby

    <img src="\polytepals\PolyPhoto\carolina_octopus.jpg">
    there are no backslashes in urls.
    <img src="/polytepals/PolyPhoto/carolina_octopus.jpg">
    Alan
    Adobe Community Expert, dreamweaver
    http://www.adobe.com/communities/experts/

  • Using AS to Create Dynamic Images

    Hi all... hoping someone here can help me out.
    I'm working on
    this site for a
    client, and they're going to have a lot of inventory for me to
    add to it.
    If you enter the site and then click on "Sofas" on the left
    menu you'll see the layout I'm doing.
    I've uploaded a file of just the "sofas" section for
    you to download
    here.
    What I'm wondering is if there's an easy way to make just one
    movie clip called "thumbnail" and one called "big". Then, depending
    on the section the person goes to they would create all the movie
    clips and let the Loader component know what image to load in based
    on the section.
    Then I could just upload the jpgs to the server and not have
    to make 300+ movieclips for every one of them.
    Hope this makes sense.
    Oh yeah... you'll notice I'm using Blogger to get the content
    onto each sofa... but that may not matter one way or another.
    Hopefully not. If there's a better way to populate the text let me
    know.
    Thanks!

    Hi all... hoping someone here can help me out.
    I'm working on
    this site for a
    client, and they're going to have a lot of inventory for me to
    add to it.
    If you enter the site and then click on "Sofas" on the left
    menu you'll see the layout I'm doing.
    I've uploaded a file of just the "sofas" section for
    you to download
    here.
    What I'm wondering is if there's an easy way to make just one
    movie clip called "thumbnail" and one called "big". Then, depending
    on the section the person goes to they would create all the movie
    clips and let the Loader component know what image to load in based
    on the section.
    Then I could just upload the jpgs to the server and not have
    to make 300+ movieclips for every one of them.
    Hope this makes sense.
    Oh yeah... you'll notice I'm using Blogger to get the content
    onto each sofa... but that may not matter one way or another.
    Hopefully not. If there's a better way to populate the text let me
    know.
    Thanks!

  • Creating dynamic database connection (SQL server 2008) from Adf application

    Hello,
    I am creating an ADF Fusion Application. I use Jdev. 11.1.2.3.0 , WebLogic 10.3 and MS SQL server 2008 database. My question is that how can I create a database connection configuration file, now I connect to the database through hard coding, there should be a way to do this with sql server I think.
    my database name is : testDatabase
    my database username is : testUser
    my database password is : testPassword
    Anybody can help me please.
    Thanks,
    Shahe

    Hello Frank,
    The database schema is the same for all the users, but the location of the database differs, for example: I have set the hostname of the database to localhost because the database is installed on the local pc, but to other clients the database is installed on a managed server so in the hostname I should put the server's ip address or name. So I need an external file where I can set these options.
    Thanks,
    Shahe

  • CS6 creates tiled image when moving from LR4 and HDR Effex Pro

    Just recently I've had a problem with CS6 where it creates a partial (tiled) image when "Edit In" from LR4 and when saving back to CS6 from HDR Effex Pro. THe image may have one or several retangles which may be black, white, or part of the image that's in the wrong place if that makes any sense. All software is running with current updates. I've had the software about 6 months and never incurred this problem until the last week. Help!

    I've run through several scenarios and find that it's always in CS6 that I have the problem. I opened a file in all modules of Nik as well as OnOne's Perfect Photo Suite. When I go back (save) to CS6 there is always a problem. When I save in CS6 and then open up in LR the image is fine. So the file must not be corrupt, it just doesn't present it properly in CS6. The GPU driver appears to be up to date....last update was in 2011 and I've had this computer since late 2012.

  • How to enter one image to sql server 2000 and then view it ...

    for example x="g:\12.jpg"

    You may check this tip:
    How to store/retrieve image to/from SQLServer
    http://www.java-tips.org/content/view/203/29/

  • Response from Tomcat Server slow and Invariable to JSP

    Hello,
    I have developed an application which is an INTRANET PORTAL in advanced java. My database is MySQL and Server is Tomcat V5.5
    The problem is server response is very slow and sometimes it stops responding, also when I try accessing it from remote machine I don't get response from my server.
    Please help...
    Thank and Regards

    since you posted to web server forum, i have to also add that web server 7 bundles a tomcat like web container within and can be used for your web serving needs. you can download web server 7 from http://www.sun.com/webserver

  • How do I create an Image of my Solaris 10 (Intel) server?

    I'm currently running Solaris 10 (Intel) on a Dell PowerEdge 2650. I'd like to create an Image of the server now that I have all the extra software installed and configured correctly.
    I used Symantec Ghost for my Window based servers, does anyone have any suggestions for the best method/software to do the same for my Solaris servers? Any help would be appreciated.
    Thanks

    Using dd is about the most hideous thing to do since restoring the data will cause you much grief. The best approach would be to use the 'ufsdump' command. You can easily dump your slices into files, and perform either full or interactive restores.
    Better yet; whenever you get a bigger disk you won't be wasting space (or risk corrupting data) through the use of dd. Next to data the dd command would also restore the partition table, boot sector, etc. And thats not very good if the disks differ too much.

  • Class casting, creating an image and decompiling...

    Hi, I've got a couple of questions:
    1)
    How can I fully decompile classes, so with the implementation of the methods? Is it always possible to fully decompile a class file? When is it and when not?
    2)
    I aks this questions before, but I still haven't got it working, so sorry, but I ask it again :) :
    I want to create my own class, for example cMyClass which extends the java.awt.Image class, which has abstract methods. How do these methods(for example getGraphics etc) have to be implemented?
    3)
    I can't cast a Image to cMyClass... why not?
    Someone told me he did the following:
    Canvas c = new Canvas()
    cMyClass oImage = (cMyClass) c.createImage (100, 100);
    and that this worked... I tried to do this too, and it seemed to work, but it actually didn't!!
    I found out that c.createImage returns a null reference!!! That's why Java was able to cast it to my own cMyClass (not a problem to cast a null to something else), but when I created a Image (by doing a lot of unnessacary difficult stuff), and then tried to cast this Image to cMyClass it throw a ClassCastException or something like that...
    How can I cast the java.awt.Image class to my class anyway?
    3)
    Why can't you create a image like i've done above or even like below:
    Canvas c = new Canvas()
    Image oImage = c.createImage (100, 100);
    Why does this return a null reference?
    Isn't there a better way to create an image?
    4)
    The getWidth and getHeight need a I thought observer...? Why is this? I just want the width and height and don't have an observer or something like that. Is there a way around this?
    I tried getWidth(null) but this returns -1
    Please help! :)

    Hi, I've got a couple of questions:
    1)
    How can I fully decompile classes, so with the
    implementation of the methods? Is it always possible
    to fully decompile a class file? When is it and when
    not?You can always get a dump of the bytecode with 'javap -c'. If you don't want to figure things out yourself, try searching google for a class file decompiler, possibly a de-obfuscator.
    De-compilation is completely possible if the original author wanted that, by including debugging information. Depending on the degree of such information and the amount of code obfuscation, the decompiled code may lack variable names, line numbers, field and method names, class names, and even code structure. Names and line numbers are usually not re-creatable automatically, since the information is simply lost, but you can replace them with your own strings when analyzing an unknown class file (using the correct tools). Re-creating the original code structure may work in some cases, but to me the general case looks rather close to the halt problem (i.e. not solvable).
    Use a de-obfuscator, hope you've got good luck, and analyze the bytecode manually if that doesn't work.
    2)
    I aks this questions before, but I still haven't got
    it working, so sorry, but I ask it again :) :
    I want to create my own class, for example cMyClass
    which extends the java.awt.Image class, which has
    abstract methods. How do these methods(for example
    getGraphics etc) have to be implemented?I don't really understand the problem. 'abstract' means on the language level that your subclass must provide an implementation, i.e. a method body. What that method is expected to do is explained in the javadocs for Image. But in fact you're free to do anything. You could play a sound in the getWidth() method (replace with any method name if you want). Just consider the fact that a lot of code calls getWidth in the hope of getting the width of the image, not playing a sound. So much about the language level.
    On a higher level, a subclass of Image should implement a certain way to describe an image. AFAIK this means that your code must know the size of the image and know how to produce the pixels of the image. I can't tell you in general how you must do this, because it depends on your special case. This boils down to the question, why do you want to write a subclass of 'Image'? What new way of describing and image have you come up with?
    3)
    I can't cast a Image to cMyClass... why not?Simple, and that's certainly not an ALT. Because that specific Image is not a cMyClass. It's probably a BufferedImage or similar that was produced by AWT.
    Please read the specs carefully what casting is about.
    Someone told me he did the following:
    Canvas c = new Canvas()
    cMyClass oImage = (cMyClass) c.createImage (100,
    100);
    and that this worked... I tried to do this too, and it
    seemed to work, but it actually didn't!!
    I found out that c.createImage returns a null
    reference!!! That's why Java was able to cast it to my
    own cMyClass (not a problem to cast a null to
    something else), but when I created a Image (by doing
    a lot of unnessacary difficult stuff), and then tried
    to cast this Image to cMyClass it throw a
    ClassCastException or something like that...
    How can I cast the java.awt.Image class to my class
    anyway?You can't, and if you understood casting then you'd understand that it wouldn't make sense.
    3, 4(don't know)
    Maybe stupid question, but for example the BufferedImage, is this
    completly written in Java?
    How is the link made between the OS+hardware and the Java code? I
    mean, displaying images etc. is very platform dependend not?Look for JNI (Java Native Interface). It's a way to link native (e.g. C) code with Java code.

  • Displaying a dynamic image in a jsp

    I am interested in the way of dynamically generating an image in a web browser. The image should be formed on the servlet, more precisely with the aid of a servlet, and reloaded in the web browser every time it suffers modifications (for example, elements are drawn). The drawing and displaying part is already functioning not as a server application, but as a desktop one. The result of the drawing actions are displayed in a Bufferd Image view. What I have to do is to display this image in the browser, encoded as a gif (I already know how to do the encoding part).
    //code from TheServlet.java
    ImageViewPort view = new ImageViewPort(600, 600); // BufferedImage type
    Image image = view;
    g = image.getGraphics();
    response.setContentType("image/gif");
    GifEncoder encoder = new GifEncoder(image, out);
    encoder.encode();
    How would I correctly reference in the HTML form this servlet? In the HTML form I have to display the dynamically created GIF image as a server side image map?
    // code from the HTML form
    <img WIDTH=600 HEIGHT=600 BORDER="2" src="http://localhost:8080/servlet/TheServlet");
    ISMAP/>
    How should be written the source of these image map?

    you can use AJAX for this.. google maps is using ajax for rendering their maps..

  • Trying to make an image of a Server but getting error message

    I'm trying to make a disk image (.dmg) of an XServe. I boot the XServe off of an external drive, fire up disk utility and choose File>New>Disk Image from <server volume>
    Then I choose where I want the .dmg file to be created. It doesn't matter where I try to put it (one of the additional two unused hard drives in Bay 2 or Bay 3, or on a network volume), I get an error message: "Unable to create <server volume> (Resource Busy)."
    What am I doing wrong? Or what do I not understand yet?
    Thanks.

    Hi.
    Tried another tactic. I booted up the XServe into Target Disk Mode on a MacBook Pro. Then fired up Disk Utility again and chose File>New>Disk Image from "server volume". It started, but erred out with the "Resource Busy" message. Then I tried the same thing but this time instead of "server volume", I chose File>New>Disk Image from "698.6 GB AAPL FireWire Target Media". It still erred out with the "Resource Busy" message. Then I tried File>New>Disk Image from Folder, and then chose "server volume", and then selected where to save the .dmg and it started to create the image, but erred out with "Unable to create "server volume" (No such file or directory)." Then I tried "Disk Image from Folder" again, but this time chose "698.6 GB AAPL FireWire Target Media", selected where to save the .dmg, and once again, it started to create the image, but erred out again with "Unable to create "server volume" . I'm at a loss. I am unable to create an image of the XServe HD and I need to. Does anyone out there have any ideas? Thanks.

  • How to create thumbnail images on the fly from JSP or servlet?

    Hi all,
    Iam new to this forum. I need a solution for the problem iam facing in building my site. Ihave groups and briefcase section in my site. I allow users to upload files and pictures.
    When they upload pictures i need to create thumbnail for them on the fly.
    Is there any taglibs or java source to do this from JSP or servlets.
    It would be very greatful if i can get an early answer.
    Please let me know if there is any other forum where i can get better answer, if not here?
    thnx.

    Here is how you can create dynamic images:
    http://developer.java.sun.com/developer/JDCTechTips/2001/tt0821.html#tip2
    However, if you want to create gifs/jpegs and save them to the disk it depends from where you want to create the images. It is different if you are creating from another image or just drawing one from scratch etc.. But in the end you will probably need to use one of the imageencoder classes and write the result to the disk with the file io classes.

Maybe you are looking for