Mime type help required

with following code
response.setContentType("application/vnd.ms-excel");
response.addHeader("Content-Disposition"," filename=OpportunityReport.xls");
dialog shows download dialog with three buttons
Open, Save, Cancel
i want to show only
Save and Cancel
how to adjust mime type?

That would have helped, I supposed :o)
However, I've resolved the issue.

Similar Messages

  • Return Record type - Help required

    Hi ,
    I have a package which uses a record type
    TYPE cont_rec IS RECORD
         (cont_id Number
         ,cont_number Number
         ,cont_number_modifier Number
    ,s_l_id Number);
    TYPE cont_tbl IS TABLE OF cont_rec INDEX BY BINARY_INTEGER;
    and then calls a function
    go_cont(p_id In Number,
    x_name in Varchar2,
    x_con out cont_tbl);
    I want to use this function in a procedure and receive the result set of go_cont. how can i do this??

    Here is one example:
    SQL>
    SQL> create or replace package prec is
      2 
      3  type cont_rec is record
      4  (cont_id Number
      5  ,cont_number Number
      6  ,cont_number_modifier Number
      7  ,s_l_id Number);
      8 
      9  type cont_tbl is table of cont_rec index by binary_integer;
    10 
    11  function go_cont(
    12  p_id In Number,
    13  x_name in Varchar2
    14  ) return cont_tbl;
    15 
    16  end;
    17  /
    Package created.
    SQL> show errors
    No errors.
    SQL>
    SQL> create or replace package body prec is
      2 
      3  function go_cont(
      4  p_id In Number,
      5  x_name in Varchar2
      6  ) return cont_tbl
      7  is
      8  v_r cont_rec;
      9  v_t cont_tbl;
    10  begin
    11    v_r.cont_id := 1;
    12    v_r.cont_number := 1;
    13    v_r.cont_number_modifier := 1;
    14    v_t(1) := v_r;
    15    v_r.cont_id := 2;
    16    v_r.cont_number := 2;
    17    v_r.cont_number_modifier := 2;
    18    v_t(2) := v_r;
    19    return v_t;
    20  end;
    21 
    22  end;
    23  /
    Package body created.
    SQL> show errors
    No errors.
    SQL>
    SQL> set serveroutput on
    SQL>
    SQL> declare
      2  tab prec.cont_tbl;
      3  begin
      4  tab:= prec.go_cont(1, NULL);
      5  for i in tab.first..tab.last
      6  loop
      7   dbms_output.put_line(tab(i).cont_id);
      8  end loop;
      9  end;
    10  /
    1                                                                              
    2                                                                              
    PL/SQL procedure successfully completed.
    SQL>
    SQL> exit

  • Image size and mime type.. non-java guy needs help

    Image size, mime type.. non-java guy needs help
    Im not at all familiar with java so this is really weird for me to work out. I?ve been doing it all day (and half of yesterday).
    Im trying to write a custom clodFusion tag in java that gets the width, height, size and MIME types of a given file. I?ve been trying to get it to work on the command line first. I can get the width and height but cant get the size and the MIME type.
    Here is what I got
    /*import com.allaire.cfx.*;*/
    import java.awt.image.renderable.*;
    import javax.media.jai.*;
    import com.sun.media.jai.codec.*;
    import java.io.*;
    import java.util.*;
    public class ImageInfo {
    private RenderedOp image = null;
    private RenderedOp result = null;
    private int height = 0;
    private int width = 0;
    private String type = "";
    private String size = "";
    public void loadf(String file) throws IOException
    file = "80by80.jpg";
    FileSeekableStream fss = new FileSeekableStream(file);
    image = JAI.create("stream", fss);
    height = image.getHeight();
    width = image.getWidth();
    System.out.println(height + "\n");
    System.out.println(width);
    System.out.println(type);
    public static void main(String[] args) throws IOException {
    ImageInfo test = new ImageInfo();
    test.loadf(args[0]);
    can anyone please help me out to modify the above so I can also print the mime type and the file size to screen.
    thanks for any help

    any suggestions?

  • MIME type setting on Tomcat server.  Please help.

    Hi all.
    Can someone shed me some lights on setting up MIME type. I added the followings to the web.xml file in /WEB-INF directory, restarted webserver, and still saw my jnlp file as text file in the browser. What did I do wrong?
    <init-param>
    <param-name>jnlp-extension</param-name>
    <param-value>.xjnlp</param-value>
    </init-param>

    do you use Apache as your web server?
    if so the just add the following line to the .mime.types configuration file:
    application/x-java-jnlp-file JNLP
    Tomcat is more a servlet server than a web server... so i don't know if it can be responsable for serving jnlp files or not....
    Anyhow, hope this helps in some way...

  • Proxy mime types problem (HELP!)

    I have an application which I have running ow two machines. On one
    machine, WebLogic is running on port 80. On the other machine I am
    using iPlanet Web Server with the NSAPI plugin pointing back to a
    WebLogic server running the same application.
    It appears as though the content types (read mime types) of the
    out put are different between the two servers. On the first
    server (weblogic only), the output appears to have a text/html
    content type whereas on the second server, (weblogic+iPlanet), seems
    to provide the result as text/plain. This does not seem to matter
    when I run with Netscape or IE, but has a significant impact when
    the client is a Palm VII.
    Any suggestions as to the problem and or solution?
    [bryon.vcf]

    You need to set the mime types in the web.xml file. For example:
    <mime-mapping>
    <extension>xls</extension>
    <mime-type>application/octet-stream</mime-type>
    </mime-mapping>
    <mime-mapping>
    <extension>doc</extension>
    <mime-type>application/octet-stream</mime-type>
    </mime-mapping>
    I have had good luck with "application/octet-stream" but you may want to try and
    experiment.
    Now for a question of my own :-) Anyone know how to set the default mime type
    --- that is, if none of the extensions that you explicitly specify matches the
    file, is there any way to indicate what MIME type to use?
    Clark
    "Christopher" <[email protected]> wrote:
    I am using Weblogic 6.0 sp2 on RedHat 6.2 as the web server and application
    server. I have a microsoft word document abc.doc under the default
    web-application. I try to get the file by "http://server/abc.doc". Normally,
    it will be opened by micsoft word inside the Internet Explorer or donwload
    box. But for Weblogic, the file show as text file with asicc data. Do
    I need
    to set the Mime types manually and where can I set it?
    Thanks.
    Chris

  • HELP : mime types ?

    I am using Weblogic 6.0 sp2 on RedHat 6.2 as the web server and application
    server. I have a microsoft word document abc.doc under the default
    web-application. I try to get the file by "http://server/abc.doc". Normally,
    it will be opened by micsoft word inside the Internet Explorer or donwload
    box. But for Weblogic, the file show as text file with asicc data. Do I need
    to set the Mime types manually and where can I set it?
    Thanks.
    Chris

    The container provides some standard "default" mime mappings out of the box
    but you can add any others to your web.xml deployment descriptor.
    From your list, I think that zip and exe should be among the default
    mappings. Are you sure they don't work for you unless you provide the
    mapping in web.xml?
    "Christopher" <[email protected]> wrote in message
    news:[email protected]..
    I checked other file types such as zip, xls, avi, swf, exe, asf, ram, dcr,
    pdf etc. Do I need to add them all to the web.xml?
    Thanks.
    Chris
    "Ian M. Goldstein" <[email protected]> wrote in message
    news:3b813eb6$[email protected]..
    You can configure mime mappings in your web application's
    WEB-INF/web.xml
    deployment descriptor -- see step 12 at
    http://e-docs.bea.com/wls/docs61//webapp/webappdeployment.html#1012209
    The mapping for Microsoft Word documents will look like this:
    <mime-mapping>
    <extension>doc</extension>
    <mime-type>application/msword</mime-type>
    </mime-mapping>
    Now, when you request http://myserver:myport/myapp/myword.doc the
    browser
    will open it as a Microsoft Word document.
    Regards,
    -- Ian
    "Christopher" <[email protected]> wrote in message
    news:[email protected]..
    I am using Weblogic 6.0 sp2 on RedHat 6.2 as the web server andapplication
    server. I have a microsoft word document abc.doc under the default
    web-application. I try to get the file by "http://server/abc.doc".
    Normally,
    it will be opened by micsoft word inside the Internet Explorer or
    donwload
    box. But for Weblogic, the file show as text file with asicc data. Do
    I
    need
    to set the Mime types manually and where can I set it?
    Thanks.
    Chris

  • HELP: Fail to surf a web contain MIME type file

    I am currently using Safari version 1.3.2
    I tried to surf a music website but the following message has shown.
    "The page has content of MIME type “application/x-oleobject”. Because you don’t have a plug-in installed for this MIME type, this content can’t be displayed."
    Does anyone know how to solve this problem?
    Many thanks!
    I BOOK G4   Mac OS X (10.3.9)  

    Hi Phe,
    The only solution is to use Microsoft Windows I'm afraid. OLE is a Windows only technology.
    Send feedback to the website about it only being accessible to Windows users.

  • Need to get the MIME type of Files

    hi
    I have a table which contains Partno and the images name i.e PRODUCT_AWG_20070416 and the data would be like that :-
    partno img_name
    PX1 px1.jpeg
    PX2 px2.jpeg
    PX3 px3.jpeg
    Now one by one i am Inserting those files into my table (img_temp -BLOB Column) which are exists in directory & the map file. but i also need to insert the MIME type of the inserted file. can you please provide me the way to generate MIME type on the basis of file type like (JPG,GIF,TXT etc).
    the procedure i am using is as follows :
    hi
    I have a TABLE which contains Partno AND THE IMAGES NAME i.e PRODUCT_AWG_20070416 AND THE DATA would be LIKE that :-
    partno img_name
    PX1 px1.jpeg
    PX2 px2.jpeg
    PX3 px3.jpeg
    Now one BY one i am INSERTING those files INTO my TABLE (img_temp -BLOB COLUMN) which are EXISTS IN DIRECTORY & THE map FILE. but i also need TO INSERT THE MIME TYPE OF THE inserted FILE. can you please provide me THE way TO generate MIME TYPE ON THE basis OF FILE TYPE LIKE (JPG,GIF,TXT etc).
    the reason of this requirement is, we need to use that table in APEX 2.2 fromwhere i can download the inserted file and to download the file we need to get correct MIME_TYPE of that file.
    Please Suggest me the way.
    Thanks.
    The Procedure which i am using is as follows :
    CREATE OR REPLACE PROCEDURE img_uploader IS
    CURSOR Cur_img IS SELECT part_no,image_file FROM PRODUCT_AWG_20070416
                             WHERE Transaction_id =1 ;
    l_bfile BFILE;
    l_blob BLOB;
    BEGIN
    FOR Cur_img_val IN Cur_img LOOP
    l_bfile := BFILENAME('SOLVS_PRODUCT_IMG', Cur_img_val.image_file);
    INSERT INTO img_temp (part_no,MIME_type,file_name, img)
    VALUES (Cur_img_val.Part_no,NULL, Cur_img_val.image_file,EMPTY_BLOB())
    RETURN img INTO l_blob;
    DBMS_LOB.fileopen(l_bfile, Dbms_Lob.File_Readonly);
    DBMS_LOB.loadfromfile(l_blob, l_bfile, DBMS_LOB.getlength(l_bfile));
    DBMS_LOB.fileclose(l_bfile);
    END LOOP ;
    COMMIT;
    END;

    Hello,
    Perhaps this can help:
    http://help.sap.com/saphelp_nw04/helpdata/en/ad/ebe5cc1d75aa43a2871717d76f475d/content.htm
    If you want to know the table name, turn on tracing (ST05) when accessing the MIME types.
    regards
    Rick Bakker
    Hanabi Technology

  • How to get the Mime Type of the file?

    Hi Everyone!,
    I want to upload a random file into my table as a BLOB and simultaneously want to fill the respective another column with its MimeType. Earlier I used Oracle Apex for this, but due to my new requirement I need to make this happen with the help of PL SQL and Forms. Could you help me in getting how we can upload the file and most importantly, how we can get its Mime-Type.
    My chosen file can be of any type; it can be doc ,pdf,txt,xls ,gif or any other format.
    If you could provide the example with your reply then it would be great.
    Thanks
    Harbinder

    hi
    for that u have to use webutil.
    declare
          f varchar2(100);
    begin
         f := webutil_file.file_open_dialog();
         if f is not null then
              :doc.doc_name := f;
              end if;
         end;and
         DECLARE
    filename VARCHAR2(256);
    BEGIN
    filename := CLIENT_GET_FILE_NAME (File_Filter => 'jpg (*.jpg)|*.*|');
    READ_IMAGE_FILE(filename, 'jpg', 'image');
    END; sarah

  • How to use JavaSript library stored in mime type repository???

    Hi Experts
    I currently have the situation that I would like to deploy several JavaScript functions in a multitude of templates. I need my own JavaScript functions as the provided functionality is not sufficient.
    I have figured that I can add my function by using the script item and that works fine, but it requires the script to be entered in every template.
    My idea is to store the central JS file in the mime type repository and then reference it, however it doesn't seem to work.
    Does anybody have an idea on how to make it work or alternatively have a central JavaScript library that is used by several different templates?
    Thanks for your help, regards,
    Minima

    Thanks for the answer, DEEPU's comment realer helped.
    Another solution is to create a Web Item that contains the coding. The Web Item can then be stored as reusable. This also looks like a neat solution for the problem.
    Hope it will help some people.
    Regards,
    Minima

  • File Download and Mime-Types

    I have some files (txt, xls, rtf, pdf) that need to be downloaded from our site. I
    have an http link to the files on the web page. I've set mime-types for each file
    type in web.xml for that web app. I'm using WLS 6sp2 on Windows 2K. I'm using an
    MVC model for the application with a Controller servlet. Every time anyone tries
    to click on the link and download it, the Contorller kicks them to a default page.
    Can anyone help?
    Thank you.

    Go to IIS Management console. At the server level, go to MIME Types. Add a new MIME type:
    File name extension:
    .mp4
    MIME type:
    video/mp4
    Restart IIS (can't remember if this is required).
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • How to use mime type..

    Hi frnds
    i have my data in a tabular format in jsp. my requirement is to create a EXCEL report for tht data using javascript (using MIME type change).
    can anyone help me to create xl report.

    Please search the forums. There are many discussions about it.

  • Mime-type tag in web.xml and attachment download

    i have set a mime-type in web.xml as below:
    <mime-mapping>
         <extension>xls</extension>
         <mime-type>application/vnd.ms-excel</mime-type>
    </mime-mapping>
    And i have a simple jsp that only shows a table and i am making this jsp to get downloaded as an excel attachment. To make it possible i have written the following line in the JSP:
    response.setHeader( "content-disposition", "attachment; filename=myexcel.xls" );
    But i am not setting the content type first by writing:
    response.setContentType( "application/vnd.ms-excel" );
    since i have already mentioned the appropriate mime-type for excel files in web.xml.
    I am using both mozilla and IE. Both are showing file download dialog. But IE is able to correctly identify the type of the attachment and opens it up with Microsoft Excel whereas mozilla fails to identify the type, assumes it to be an HTML document and opens it up in a new window of IE.
    mozilla works fine only when i set the content type in the JSP itself. But IE works in all conditions even without having the mime-type tag in web.xml.
    If i have already specified the mime-type for particular type of file in web.xml, is there any requirement to set the content type again in the JSP/servlet?
    Please help. I even changed the mime-type for .xls (excel) files in web.xml and made it text/plain, but still the same thing is happening. IE is always showing the correct file type where as mozilla is taking it as an HTML document.
    i am using weblogic server 8.1.

    the web xml mime type setting are for static files served by the server...
    if you print a file directly to the output of the servlet, you must set the mime type, so DO write :
    response.setContentType( "application/vnd.ms-excel" );
    IE "works fine" because it also uses the file extension to decide the mime type... but in the absolute, it's a wrong behaviour

  • How to get the mime type of the workflow attachment attached to workitem id

    Hi Experts,
    I can attach different types of attachment to the workitem id, lets suppost the attachment type attached is pdf, for this attachment I have an requirement to send the mime type as well. In this case the mime type is 'application/pdf' for pdf files.(for text file it is 'text/plain' and for zip file it is 'application/zip' and so on)
    Do I have any place in ABAP world where I can get the mime type for different types of attachments.
    I dont want to hard code the mime types, and I have checked the transaction 'SMW0', but not sure if this is the correct place to get the mime type.
    Do you see any other way or tables which stores all these mime types.
    Any help/suggestion would be appreciated.
    Thanks and Regards,
    Neerup.

    Hello,
    Perhaps this can help:
    http://help.sap.com/saphelp_nw04/helpdata/en/ad/ebe5cc1d75aa43a2871717d76f475d/content.htm
    If you want to know the table name, turn on tracing (ST05) when accessing the MIME types.
    regards
    Rick Bakker
    Hanabi Technology

  • Problems with MIME type in Safari

    Hi.
    Somebody send me files via some web page, but safari keeps asking this.
    The page “******* - QuickLink Delivery” has content of MIME type “application/x-aspera-web”. Because you don’t have a plug-in installed for this MIME type, this content can’t be displayed.
    I try to find the plug-in but i can't find it.

    Welcome to Apple Discussions
    Have a look here. This may be helpful.
    Would you post the URL sent to you. Curious to see the web site requiring the plug-in.

Maybe you are looking for

  • Problems Downloading iOS 6

    Okay so it's been a few days since the iPhone 5 has come out, yes? And same with the newer iOS 6 iPhone software. Ever since this update has been released I have been trying everything I can to download it, i've tried downloading it from my phone and

  • Oracle 9i and 10g Client

    First I installed 9i client on F:\ It was working and gettin connected to 10g servers. After this I installed 10g client on E:\ and even this was working... then I tried to change the oracle path from environment variables..to set path again for 9i c

  • Games not playing on facebook

    I bought a new laptop trying to play games on facebook, some work some doesn't. The ones that doesn't states flash player needs to be updated and when we try it states it is not needed flash player is part of internet explorer.  I don't understand wh

  • Locking desktop icons

    I've got a Macbook Pro with the multifinger trackpad. I have a problem accidentally shrinking or enlarging the desktop icons with finger swipes. I've tried looking to lock the size down but can't figure where to get that done. I don't want to lose th

  • FWSM PAT Overloading

    Hello, I ahve an issue in configuring PAT on my FWSM. I need to map many private IPs to one public IP. Here the conf : nat (CLT-INSIDE) 3 172.20.120. 255.255.255.0 outside global (OUTSIDE) 3 AAA.BBB.CCC.DDD I tyried with and without the outside keywo