How to display arabic charsin jsp

hello,
I try to display an arabic text on the jsp
<meta http-equiv="Content-Language" content="ar-ae">
<%@ page language="java" contentType="text/html;charset=windows-1256" pageEncoding="UTF-8"%>
<html>
   <p>&#1580;&#1575;&#1605;&#1593;&#1577; &#1575;&#1604;&#1593;&#1604;&#1608;&#1605;</p>
</html>
but I see only ????
why

anybody in thos world to help me ???

Similar Messages

  • How to display PDF in JSP using Iframe

    Hi All,
    I am using Struts 2. I am building my file in ActionClass with seperate Method like getGeneratedPDF() in which, I am setting header of response and writing into PDF.
    This method will be called from JSP by this way
    s:property value="getGeneratedPDF()" />
    But It displayed Junk Characters , and this PDF is not static (already Generated). It is generated and build on Fly.
    I have 2 questions 1 -- How to display PDF in JSP in proper way without Junk Character in it?
    questions 2 -- How to display it in Iframe?
    Please help me , If you know the solution.
    Thanks in Advance,
    Jimmy

    jamy_26 wrote:
    But It displayed Junk Characters , and this PDF is not static (already Generated). It is generated and build on Fly.A PDF file is a binary file, not a text file, and you're trying to display it as String. Of course you would get "junk characters". Have you ever tried opening a binary file (pdf, doc, jpg, xls, etc) using a text editor like Notepad?
    I have 2 questions 1 -- How to display PDF in JSP in proper way without Junk Character in it?Display it as binary stream, not as text stream. You can display it standalone, just let the link/form/addressbar URL point to some Servlet which writes the InputStream of the PDF file to the OutputStream of the response, along with a correct set of response headers (at least content-type, content-disposition and content-length), so that the browser can open it in the correct application (which is usually Acrobat Reader). If you want to embed the PDF file in a JSP, then one of the ways is indeed using the HTML <iframe> tag.
    questions 2 -- How to display it in Iframe? Just let the iframe URL point to the aforementioned Servlet.
    You can find here an example of a generic file servlet, you may find it useful to get the idea how to do it: [http://balusc.blogspot.com/2007/07/fileservlet.html].

  • How to display arabic Subtitle Language?

    How to display arabic Subtitle Language?
    i buy move with arabic subtitle.
    when i go to
    Settings > Audio & Video > Subtitle Language
    NO arabic option!!!!

    I don't think the apple tv has ever supported Arabic.  Tell Apple you want it via
    http://www.apple.com/feedback

  • How to display Arabic content in JSP ?

    Hi all,
    I used the following encoding method to display arabic content in JSP page.
    <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
    <meta content="text/html; charset=UTF-8" http-equiv="content-type"/>
    I also set -Dfile encoding=ISO-8859-6 in the JVM Options.As a result the arabic data is getting displayed .
    Variable "data" contains the actual arabic data.
    function updateArabicData(data){
    try{
    document.getElementById('divtag').innerHTML=""+data;
    }catch(err){
    <html>
    <body>
    <div id="divtag" lang="ar-sa"></div>
    </body>
    </html>
    But the problem is the arabic data getting displayed in JSP (within the <div>)seems to be jumbled up.The users say that the arabic words within a single sentence are not arranged correctly.They are mixed up.Please help me with a solution.
    Edited by: Alance on May 27, 2010 5:34 AM

    Data is retrieved as follows
    if(msg.getField("GEN_UNICODE_MESSAGE_1")!=null){
    resultString=resultString+"N"+""+new String((byte[])msg.getField("GEN_UNICODE_MESSAGE_1").value.get(0),"ISO-8859-6");
    with content Type set as response.setContentType("text/html;charset=ISO-8859-6");
    ISO-8859-6 -since the data contains arabic news.
    Edited by: Alance on May 27, 2010 11:05 PM

  • BB Bold 9000 How to display Arabic SMS text

    I'm new to these forums so sorry if I'm posting this in the wrong spot .. please redirect me if so.
    Recently bought BB bold 9000 from Vodafone Aust. Need to know how to display msgs or emails received in ARABIC text .. any help would be appreciated.
    Solved!
    Go to Solution.

    Hi,
    Download the OS for the carrier and use Application loader inside the Desktop manager software (that came with the Box)  and select Arabic with the language options (if that is an option).
    Alternatively you could install the OS from an Arabic carrier (involves deleting the vendor.xml file), but its not recommended....
    This is the instructions from my website (the short version):
     Get an OS from here:http://na.blackberry.com/eng/support/downloads/download_sites.jsp
    The Operating system software downloaded from the Blackberry website contains all the files required to reload the O/S.
    The Desktop Manager software is NOT required!
    Once downloaded and installed, follow these directions:
    Download the OS file from your carrier website to the PC then install it to the PC by running (double clicking) the file you downloaded.
    Go to c:\program files\common files\research in motion\apploader and delete the file named "vendor.xml."
    Plug in BB and double click on "Loader.exe." It's located in the same place as the above vendor.xml file.
    The process takes about 45 minutes to an hour depending on how much data you have to backup and restore during the process. Once it's done loading the new OS it will reboot (it may do this twice during the entire process.) You will see a white screen with an hourglass for up to 20 minutes at a time while the DM says "waiting for initialization." If, for some reason, you end up with a white screen with small icons and the number 507, simply connect to the PC again and run Loader.exe again and it should load the OS to the device.
    Checked out my Blackberry FAQ's and Links to Needed Articles here
    http://darkeen.homelinux.com/index.php/Blackberryfaq

  • How to display records in jsp

    i have 100 records can anybody tell me how i display records 10 at atime in jsp & by clicking the next button another 10 records displays in the same jsp. How i can do that thing.

    You have to implement a page breake yourself.
    Simple scenario would be to store a page number into a session:
    session.setAttribute("page", selectedPage)
    every time user clicks on a next page link
    When displaying the record read the page and display only those which should be on the page
    Integer selectedPage = session.getAttribute("page")
    if (selectedPage == null) selectedPage = 1;
    //display code goes here

  • How to display  table in jsp pages

    hi all ,
    i want to diaplay the table in jsp page...ie,if i click on some option then i need to get the table in jsp page
    wiil u plz help me
    thanks in advance
    chintu

    hi all..
    i didnt ask how to design table in jsp...i am asking how to diaplay the table with data already stored in database...i just want to retrive the values in table and display in jsp.....
    thanks in advance...
    chintu

  • How to display meesage in JSP from DAO.java

    Hi all,
    I have a Dao.java coding where i have my oracle queries executed.i have separate functions for every query.It should return boolean value.If the 1st functions returns true,then the second function should be called.if it returns false,i have to display some message like "You have received the message already" in my JSP.i use JSP,Servlet and Dao.
    How to execute this.How to display the message.Pardon me if its too silly.Help me out guys.
    If(true)
    call 2nd function
    else
    display message
    }

    What have you tried?
    What happened?

  • How To Display JasperReport From JSP ????

    Hi All ;
    I am new user for JasperReport ;
    Please Help ME :::
    How Can I Display JasperReport From JSP ????
    Regards;

    BalusC wrote:
    Follow those steps to get a listing of useful links how to learn JasperReport:
    1) Go to http://www.google.com, you'll see one input field and one button.
    2) Enter "jasperreport tutorial" in that input field.
    3) Hit the button next to that input field.and don't forget to pose this question @ http://jasperforge.org as that would be a better place where you can get better replies as people their specialize on the solution offered by jasper soft such as Reporting,BI and blah blah blah.
    and for the time being hope the below thread might give you a basic start if you have basic understanding of how Jasper Reporting works.
    http://forum.java.sun.com/thread.jspa?threadID=5203324&messageID=9811077
    http://forum.java.sun.com/thread.jspa?threadID=5212278
    Hope there are no hard issues on this,as it is just to point you to the right direction :)
    REGARDS,
    RaHuL

  • How to display photo in jsp through blob from oracle

    i am struggling here to retrieve an image which is stored in oracle-blob data type through jdbc-type-1.and i am unable to display that in jsp.i had a rich code library for this problem.but nothing gave me the exact solution.
    please give me exact the solution..
    pls ...

    What have you tried?
    What happened?

  • How to display arabic in forms

    hi friends
    I use Oracled database 10g in windows xp sp2
    previously I was just change the value NLS_LANG for the following keys :
    HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_DevSuiteHome1
    HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_OraDb10g_home1from
    AMERICAN_AMERICA.WE8MSWIN1252to
    ARABIC_SAUDI ARABIA.AR8MSWIN1256and i also change in ( Control Panel > Regional and Language Option ) this tabs ( Regional Option & Advanced) to Arabic Saudi Arabia
    then I could insert value and I also could query to display this data from both SQL*PLUS.exe and Forms
    but now I couldn't pleeeeeeeez someone tell me what i miss
    any help and advice I greatly appreciated
    thanks
    Edited by: user10947262 on Jun 10, 2010 6:00 PM

    hi CraigB
    thanks for reply this is my NLS_CHARACTERSET before updating
    SQL> select * from  nls_database_parameters;
    PARAMETER                      VALUE
    NLS_LANGUAGE                   AMERICAN
    NLS_TERRITORY                  AMERICA
    NLS_CURRENCY                   $
    NLS_ISO_CURRENCY               AMERICA
    NLS_NUMERIC_CHARACTERS         .,
    NLS_CHARACTERSET               WE8MSWIN1252      <==========
    NLS_CALENDAR                   GREGORIAN
    NLS_DATE_FORMAT                DD-MON-RR
    NLS_DATE_LANGUAGE              AMERICAN
    NLS_SORT                       BINARY
    NLS_TIME_FORMAT                HH.MI.SSXFF AM
    PARAMETER                      VALUE
    NLS_TIMESTAMP_FORMAT           DD-MON-RR HH.MI.SSXFF AM
    NLS_TIME_TZ_FORMAT             HH.MI.SSXFF AM TZR
    NLS_TIMESTAMP_TZ_FORMAT        DD-MON-RR HH.MI.SSXFF AM TZR
    NLS_DUAL_CURRENCY              $
    NLS_COMP                       BINARY
    NLS_LENGTH_SEMANTICS           BYTE
    NLS_NCHAR_CONV_EXCP            FALSE
    NLS_NCHAR_CHARACTERSET         AL16UTF16
    NLS_RDBMS_VERSION              10.2.0.1.0
    20 rows selected.
    SQL>and this is nls_charachterset after update
    SQL> select * from  nls_database_parameters;
    PARAMETER                      VALUE
    NLS_LANGUAGE                   AMERICAN
    NLS_TERRITORY                  AMERICA
    NLS_CURRENCY                   $
    NLS_ISO_CURRENCY               AMERICA
    NLS_NUMERIC_CHARACTERS         .,
    NLS_CHARACTERSET               AR8MSWIN1256   <==========
    NLS_CALENDAR                   GREGORIAN
    NLS_DATE_FORMAT                DD-MON-RR
    NLS_DATE_LANGUAGE              AMERICAN
    NLS_SORT                       BINARY
    NLS_TIME_FORMAT                HH.MI.SSXFF AM
    PARAMETER                      VALUE
    NLS_TIMESTAMP_FORMAT           DD-MON-RR HH.MI.SSXFF AM
    NLS_TIME_TZ_FORMAT             HH.MI.SSXFF AM TZR
    NLS_TIMESTAMP_TZ_FORMAT        DD-MON-RR HH.MI.SSXFF AM TZR
    NLS_DUAL_CURRENCY              $
    NLS_COMP                       BINARY
    NLS_LENGTH_SEMANTICS           BYTE
    NLS_NCHAR_CONV_EXCP            FALSE
    NLS_NCHAR_CHARACTERSET         AL16UTF16
    NLS_RDBMS_VERSION              10.2.0.1.0
    20 rows selected.
    SQL>plz man i still stucked could you guide me what's next
    thanks for reply again
    Craig could you tell me where i can find this document you mention (1015554.4 (How to Configure Forms for Use with Arabic Characters) )
    Edited by: user10947262 on Jun 11, 2010 11:11 AM

  • How to display arraylist in jsp

    I try to display arrayList
    past from servlet
    my code looks like
    <%@ include file="/expires.jsp" %>
    <%@ page language="java" import="java.sql.*" contentType="text/html;charset=UTF-8"%>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>CEDARS</title>
    </head>
    <body>
    <% String allFound = (String) session.getAttribute("allFound");
    hallA mydata= new hallA();
        for(int j=0; j<allFound.length(); j++){
                          mydata=(hallA)allFound.get(j);  %>
                     <tr>          
                     <td>mydata.getUniversityN()</td>
                      <td> mydata.getName()</td>
                      <td>mydata.getRnumber()</td>
                      <td>mydata.getCurricumlum()</td>
                      <td> mydata.getGender()</td>
                      <td>mydata.getYear()</td>
                      <td>mydata.getMobilNo()</td>
                      <td>mydata.getEmail()</td>
                      <td> mydata.getFinalYear()</td>
                      <td> mydata.getPeriodOne()</td>
                      <td> mydata.getPeriodTwo()</td>           
                    </tr>          
           <%}%>  
    </body>
    </html> and I got the error like
    Servlet.service() for servlet jsp threw exception
    org.apache.jasper.JasperException: Unable to compile class for JSP:
    An error occurred at line: 13 in the jsp file: /showResultA.jsp
    hallA cannot be resolved to a type
    10:
    11:  
    12: <% String allFound = (String) session.getAttribute("allFound");
    13: hallA mydata= new hallA();
    14:     for(int j=0; j<allFound.length(); j++){
    15:                       mydata=(hallA)allFound.get(j);  %>
    16:                  <tr>          
    An error occurred at line: 13 in the jsp file: /showResultA.jsp
    hallA cannot be resolved to a type
    10:
    11:  
    12: <% String allFound = (String) session.getAttribute("allFound");
    13: hallA mydata= new hallA();
    14:     for(int j=0; j<allFound.length(); j++){
    15:                       mydata=(hallA)allFound.get(j);  %>
    16:                  <tr>          
    An error occurred at line: 15 in the jsp file: /showResultA.jsp
    hallA cannot be resolved to a type
    12: <% String allFound = (String) session.getAttribute("allFound");
    13: hallA mydata= new hallA();
    14:     for(int j=0; j<allFound.length(); j++){
    15:                       mydata=(hallA)allFound.get(j);  %>
    16:                  <tr>          
    17:                  <td>mydata.getUniversityN()</td>
    18:                   <td> mydata.getName()</td>
    An error occurred at line: 15 in the jsp file: /showResultA.jsp
    The method get(int) is undefined for the type String
    12: <% String allFound = (String) session.getAttribute("allFound");
    13: hallA mydata= new hallA();
    14:     for(int j=0; j<allFound.length(); j++){
    15:                       mydata=(hallA)allFound.get(j);  %>
    16:                  <tr>          
    17:                  <td>mydata.getUniversityN()</td>
    18:                   <td> mydata.getName()</td>
    Stacktrace:
         at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)I don't know how to fix it
    thnak you

    hi evnafets,
    thnak you
    for the reply
    I presume you have a session.setAttribute() call in your servlet? yes so what is the mistake I made?1. I put both standard.jar and jstl.jar under E:\apache-tomcat-6.0.10\lib
    2. I copy the tld into E:\apache-tomcat-6.0.10\webapps\Hall\WEB-INF\
    3. I change my xml to<?xml version="1.0" encoding="UTF-8"?>
    <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd"
        version="2.5">
        <session-config>
            <session-timeout>10</session-timeout>
        </session-config>
             <welcome-file-list>
              <welcome-file>Hall1.jsp</welcome-file>
         </welcome-file-list>
        <servlet>
            <servlet-name>submit</servlet-name>
            <servlet-class>submit</servlet-class>
        </servlet>   
        <servlet-mapping>
            <servlet-name>submit</servlet-name>
            <url-pattern>/servlet/submit</url-pattern>
        </servlet-mapping> 
    <taglib>
        <taglib-uri>http://java.sun.com/jstl/fmt</taglib-uri>
        <taglib-location>/WEB-INF/fmt.tld</taglib-location>
      </taglib>
      <taglib>
        <taglib-uri>http://java.sun.com/jstl/core</taglib-uri>
        <taglib-location>/WEB-INF/c.tld</taglib-location>
      </taglib>
      <taglib>
        <taglib-uri>http://java.sun.com/jstl/sql</taglib-uri>
        <taglib-location>/WEB-INF/sql.tld</taglib-location>
      </taglib>
      <taglib>
        <taglib-uri>http://java.sun.com/jstl/x</taglib-uri>
        <taglib-location>/WEB-INF/x.tld</taglib-location>
      </taglib>
    </web-app>jsp<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@ include file="/expires.jsp" %>
    <%@ page import="java.util.*"%>
    <%@ page import="cedars.hallA"%>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>CEDARS</title>
    </head>
    <body>
    <% ArrayList allFound = (ArrayList) session.getAttribute("allFound"); %>
    hallA myData= new hallA();
    <c:forEach var="myData" values="${allFound}">
    <table>
      <tr>
        <td>${myData.name}"</td>
        <td><c:out value="${myData.name}"/></td>
        <td><c:out value="${myData.currculum}"/></td>
    </tr>
    </c:forEach>
    </table>
    </body>
    </html>
    *error is ���d�I: Servlet.service() for servlet jsp threw exception*
    *org.apache.jasper.JasperException: /showResultA.jsp(13,0) Attribute values invalid for tag forEach according to TLD*     at org.apache.jasper.compiler.DefaultErrorHandler.jspError(DefaultErrorHandler.java:40)
         at org.apache.jasper.compiler.ErrorDispatcher.dispatch(ErrorDispatcher.java:407)
         at org.apache.jasper.compiler.ErrorDispatcher.jspError(ErrorDispatcher.java:236)
         at org.apache.jasper.compiler.Validator$ValidateVisitor.checkXmlAttributes(Validator.java:1198)
         at org.apache.jasper.compiler.Validator$ValidateVisitor.visit(Validator.java:819)
         at org.apache.jasper.compiler.Node$CustomTag.accept(Node.java:1507)
         at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2336)
         at org.apache.jasper.compiler.Node$Visitor.visitBody(Node.java:2386)
         at org.apache.jasper.compiler.Node$Visitor.visit(Node.java:2392)
         at org.apache.jasper.compiler.Node$Root.accept(Node.java:489)
         at org.apache.jasper.compiler.Node$Nodes.visit(Node.java:2336)
         at org.apache.jasper.compiler.Validator.validate(Validator.java:1737)
         at org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:178)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:306)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:286)
         at org.apache.jasper.compiler.Compiler.compile(Compiler.java:273)
         at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:566)
         at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:308)
         at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:320)
         at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:266)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
         at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:687)
         at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:469)
         at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:403)
         at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
         at displayhallF.doPost(displayhallF.java:166)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         at org.apache.catalina.servlets.InvokerServlet.serveRequest(InvokerServlet.java:402)
         at org.apache.catalina.servlets.InvokerServlet.doPost(InvokerServlet.java:170)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:228)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:216)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:634)
         at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:445)
         at java.lang.Thread.run(Thread.java:619)
    {code}
    thank you                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • How to display JPEG in JSP w/o IMG tag?

    I have a working application where a jpeg image is ecoded on the server via a JavaBean. The bean is then forwarded to a JSP, which gets the unique jpeg filename from the bean and displays it with an html <IMG> tag. All's fine and well, but I'd like to get away from having lots of image files laying around on the server and just display the image encoded in the current request. I tried creating a custom tag to encode and display the jpeg using the com.sun.image.codec.jpeg.* package in this manner:
    ServletResponse res = pageContext.getResponse();
    OutputStream os = res.getOutputStream();
    JPEGImageEncoder encoder = JPEGCodec.createJPEGEncoder(os);
    encoder.encode(imageRef); //-- imageRef is instance of BufferedImage
    and in the JSP:
    html, other tags, etc.
    <graph:image imageRef='<%= imageBean.getImage() %>'/>
    The image displays, but nothing else in the JSP (ie. html, other custom tags). In all other tags I've written, JSPWriter is used for output, but I need an OutputStream for the createJPEGEncoder() method.
    Can anyone tell me if what I want to do is possible? I'm chasing my tail at the moment.
    TIA Mark

    Would this work for you:
    Create the IMG tag in the JSP with the SRC as a servlet.
    Also, add any parameters you may need to tell the servlet what image to send back.
    Something like this:out.print("<IMG SRC=\"/servlet/ImageProducerServlet?WhichImage=");
    out.print("MySpecialImage");
    ...The ImageProducerServlet can be setup to send back the JPEG image file.

  • How to display images in JSP

    Hi all,
    I created a Jsp page and I stored my images in the dist-->images folder and by using the following code
    <% String image = componentRequest.getWebResourcePath() + "/images/image.gif"; %>
    <img src="<%=image%>">
    I try to display the images in that page.
    Yes I am successful in displaying one image.
    But my problem here is to display more than two images which are present in that page.
    Can any body help me regarding this.
    Your help will be highly rewarded with points.
    Regards,
    Ramana.

    Hi Ramana,
    Set the image border to 1 and check atleast your borders get displayed. If it displays the border, then the problem may be with your image path.
    Before deploying for each modification in your JSP, check the preview of the page using "Preview" tab.
    Are you getting any exception?
    Check your whole JSP page once again (check all the scriplets).
    Regards,
    Uma
    Message was edited by: Uma Maheswari

  • How to Display Catalog in JSP ?

    Hi All
    I created one custom catalog but I am unable to display in jsp level.
    I ran the basic catalog maintenance service in dyn admin.
    Are there any other Configurations required ?
    Could anybody provide the solution ASAP .
    Thanks in Advance,
    user8729783

    Try This.
    <dsp:droplet name="/atg/dynamo/droplet/ForEach">
      <dsp:param name="array" bean="Profile.catalog.rootCategories"/>
      <dsp:oparam name="output">
      <dsp:droplet name="/atg/commerce/catalog/CategoryLookup">
      <dsp:param name="id" param="element.id"/>
      <dsp:oparam name="output">
      <dsp:droplet name="ForEach">
      <dsp:param param="element.childProducts" name="array" />
      <dsp:oparam name="output">
      <dsp:param name="deviceItem" param="element"/>
      <dsp:getvalueof var="productId" param="deviceItem.id" idtype="java.lang.String"/>
      <dsp:droplet name="ForEach">
      <dsp:param name="array" param="deviceItem.childSKUs"/>
      <dsp:param name="elementName" value="childSku"/>
      <dsp:oparam name="output">
      <div style="width:306px;float:left;padding:10px;">
      <div style="font-size: 12px;font-weight: bold;">
      <dsp:valueof param="childSku.displayName"
      valueishtml="true">Name Not Available</dsp:valueof>
      </div>
      <div style="float:left;padding:15px">
      <dsp:getvalueof id="imagepath" param="childSku.smallImage.url" idtype="java.lang.String">
      <%imagepath = "/dyn/dyn" + imagepath;%>
                  <dsp:img src="<%=imagepath%>"/>
                 </dsp:getvalueof>
      </div>
      <div>
      <div class="termPrice"><dsp:valueof param="childSku.listPrice" converter="currency"/></div>
      <div class="agreement">with No term</div>
      </div>
      <div>
      <dsp:valueof param="childSku.description"
      valueishtml="true">Name Not Available</dsp:valueof>
      </div>
      <div style="padding-left:150px;">
      <dsp:a href="sku_Selection.jsp">
      <dsp:param name="childEachSkuId" param="childSku.id" />
      <dspel:param name="productId" value="${productId}" />
      Learn More
      </dsp:a>
      </div>
      </div>
      </dsp:oparam>
      </dsp:droplet>
      </dsp:oparam>
      </dsp:droplet>
      </dsp:oparam>
      </dsp:droplet>
      </dsp:oparam>
      </dsp:droplet>
    Thanks,
    Mathew.

Maybe you are looking for

  • Closing the device deletes what has been typed to that point. Is this normal?

    Closing the device deletes what has been typed as an e-mail up to that point. Is this normal, and can it be avoided?

  • Delivery credit check

    Dear friends I have analyzed one customer, at present time During Sales order creation credit limit checking, we have created one sales order in development server with credit limit... We cannot make the delivery for that sales order. Now we have rem

  • [SOLVED] Gnome 3.4 - Super+R to launch terminal

    I added a new shortcut to "gnome-terminal" as Ctrl+Alt+T on keyboard shortcuts configuration program. However, I can only set it to <C-A-t> (control+alt+t), and not to Super+R, or Super+T, or Super+ENTER. It used to work on Gnome 3.2? Should I report

  • A lot of questions about sync

    Hello, 1) First, I want to view the tab opened on my firefox for android with my firefox for PC, how do I do that ? ''Solved'' it's under 'history'. 2) Then is there a limit to the number of tabs synchronized because I don't see all the tabs opened o

  • Flash video image problem with newest nVidia driver

    I've got a very weird display error since the last update. Basically, whenever I play flash video and afterwards close the browser (chromium), any purely black surfaces will display the full flash player image. The effect is only visible in the "firs