IIS and Inherited/Local MIME Types

Alright guys I've spent a good 3 hours this morning finding out why images/css wouldn't work in a proof of concept environment with Server 2012/SQL 2014. My application has been far from easy to get working. I have 3 environments that have MIME type .woff set to local and my new one is using inherited. (I had to remove the entry in the web.config for this to pull properly via browser.) I was wondering how I can get this one set to local as well but it's currently only working with inherited without the web.config entry of: Just trying to make all environments consistent so when I do deploy new builds I avoid any unneeded complications. Thanks in advance for the assistance!
This topic first appeared in the Spiceworks Community

[att1.html]

Similar Messages

  • Web server and setting up mime type

    All,
    We have written a httpd server program that handles http calls. I want to use this server to execute jnlps. I am confused as how to set the jnlp mime type on this server. Anybody has their own server and able to set the mime type? or is there any idea anyone has to set up mime type?
    Please reply. It is very critical.
    Thanks,
    Rama

    We have written a httpd server program that handles
    http calls. I want to use this server to execute
    jnlps. I am confused as how to set the jnlp mime type
    on this server. Anybody has their own server and able
    to set the mime type? or is there any idea anyone has
    to set up mime type?This is easy. Your server does not execute the jnlps. It just tells Java Web Start (the jnlp client) this is a jnlp and then hands it the jnlp file.
    For this the header part of the HTTP response needs to prove the jnlp mime type as content type.
    Example:
    If I log in by hand and hack in a request for a jnlp doc
    $ telnet zope 8080
    Trying 192.168.0.250...
    Connected to zope
    Escape character is '^]'.
    GET http://zope:8080/public/GUI/WebStart/Versant.jnlp HTTP/1.0then the server replies with
    HTTP/1.0 200 OK
    Server: Zope/Zope 2.2.2 (source release, python 1.5.2, linux2) ZServer/1.1b1
    Date: Fri, 21 Sep 2001 10:01:30 GMT
    Connection: close
    Content-Type: application/x-java-jnlp-file
    Content-Length: 1223
    Last-Modified: Mon, 03 Sep 2001 15:30:13 GMT
    <?xml version="1.0" encoding="UTF-8"?>
    <jnlp spec="1.0+" codebase="http://zope:8080/public/GUI/WebStart" href="Versant
    jnlp">
      <information>
      <!-- ... -->
    </jnlp>
    Connection closed by foreign host.You should use such a content type like above.
    Regards,
    Marc

  • Mime Types for .ps1 files

    I am trying to setup IIS to display .ps1 files in text format (i.e. same way it deals with .txt files, where it displays the contents in the browser). I set it up to be a text/plain but it still prompts me to download the file when I browse to it.
    What else am I missing?

    Hi Daniel,
    Agree with Mr X, in addition, you can also refer to this similar disscusion:
    In your IIS Manager, select the server node on the tree, and click "MIME Types". Then click "Add..." on the right panel. For extension, set it to .ps1, and set the MIME type to text/plain.
    You can do this for a specific web application or virtual directory, too. If you are doing this through web.config, it would look something like this, please backup this configuration file before edit:
    <configuration>
    <system.webServer>
    <staticContent>
    <mimeMap fileExtension=".ps1" mimeType="text/plain" /><!-- or application/octet-stream -->
    </staticContent>
    </system.webServer>
    </configuration>
    Refer to:
    Download powershell (.ps1) file via ASP.NET
    If you have any feedback on our support, please click here.
    Best Regards,
    Anna Wang
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact [email protected]

  • MIME Types

    I need to know how to alter MIME type settings in OS X. I would like to use another media player other than QT to play MPEGS off the web because I would like the ability to go full screen. I have tried unchecking the MPEG file types in Quicktitme, in theory removing QT as the default player, but Safari and Firefox both still default to QT when I click on that type of link.
    Can someone please tell me where I can make changes to and manually add MIME types?
    Thanks!

    Hi, Echomancer.
    Two suggestions for you:
    1. See "Mac OS X 10.4 Help: Changing the application that opens a document."
    2. Try the freeware application RCDefaultApp. Safari, unlike many other browsers, doesn't provide a way to assign "helper apps" to specific MIME types.
    Good luck!
    Dr. Smoke
    Author: Troubleshooting Mac® OS X

  • MIME type of attachments in CRM

    Hi there,
    could you please assist with the following question.
    There is an attachment in CRM system which is stored with MIME text/x-doctype - can the MIME type be changed afterwards somehow? Maybe using some report?
    thanks for your help!
    cheers,
    Johannes

    I do not know of a standard report, but something bespoke could be written.
    Class CL_CRM_DOCUMENTS has a method change_properties.  This should allow you to change the value for the MIME_TYPE property.  A bespoke report could use this to access and change the mime type of documents.

  • Mime Types : application/octet-stream

    When using CFFILE, I am allowing "text/xml". Client is saving
    MS Excel as XML. Many test done and has worked until today when the
    error started occuring that the MIME type is not accepted. I do
    understand that the "application/octet-stream" MIME type is
    generated (sometimes) when a file is viewed or save in a word
    process or spreadsheet application.
    The question is ... are there security concerns if I allow
    "application/octet-stream" MIME type to be uploaded to the server?
    Any thoughts or conerns would be appreciated.
    -jb

    The MIME type is provided by the client browser. Is the
    browser posting an XML file and sending the MIME type as
    pplication/octet-stream instead of text/xml? In Windows/Internet
    Explorer MIME types and extensions are associated by a registry
    entry. If you have access to the client's PC you may wish to check
    this.
    If you allow application/octet-stream you are opening
    yourself up. I also recommend you check file extensions and only
    accept uploads from trusted sources.

  • Cfcontent IIS and particular mime types

    I have an application this is using flowplayer to play various video files. The video files are passed to flowplayer using a cfm script with the cfcontent tag. What I am finding is that for some file types this process fails; the player hangs and the video doesn't play. An example file type is mp4. The problem is specific to our server running IIS 6. On my local box I have Apache installed and the script works fine for mp4 files. I have the mp4 mime type defined in IIS 6 as "video/mp4" and that is what I use in the type attribute of the cfcontent tag. (I've also tried "video/mpeg" without success.) If I change my process so that I pass the file directly to flowplayer then it plays fine on IIS 6. Here is the basic code I have for providing the file.
    <cfdirectory directory="#fileDir#" action="list" filter="#getAllFileInfoRet.result.file_name#" name="dirFileInfo" />
    <cfif dirFileInfo.recordcount gt 0>
        <cfheader name="Content-Length" value="#dirFileInfo.size#">
    </cfif>
    <cfheader name="Expires" value="Thu, 19 Nov 1981 08:52:00 GMT">
    <cfset tz = GetTimeZoneInfo() />
    <cfset gmtNow = DateAdd("h",tz.utcHourOffset,Now()) />
    <cfheader name="Last-Modified" value="#DateFormat(gmtNow,"ddd, d mmm yyyy")# #TimeFormat(gmtNow,"hh:mm:ss")# GMT">
    <cfheader name="Content-Disposition" value="attachment;filename=#getAllFileInfoRet.result.file_name#">
    <cfheader name="Content-Type" value="#getAllFileInfoRet.result.file_ext_mime#">
    <cfheader name="Cache-Control" value="no-store, no-cache, must-revalidate, post-check=0, pre-check=0">
    <cfheader name="Pragma" value="no-cache">
    <cfcontent deletefile="false" file="#fileDir##getAllFileInfoRet.result.file_name#" type="#getAllFileInfoRet.result.file_ext_mime#" />
    I've tried various combinations of the cfheader tags without having any effect. If anyone has some suggestions or has encountered something similar, I'll take whatever help I can get.

    Hi Adam,
    In the end, the only way that I could get it to work in all browsers was to create a temporary file.  However, the cfheader info was useful, so thanks.
    Michael
    Code I used:
    <cffile action="write"
    file="#GetTempDirectory()#/#varFileName#"
            output="#structDocument.Filecontent#"
    >
    <!--- Output doc --->
    <cfheader name="Content-Disposition" value="#var_content_dis#">
    <cfheader name="Content-Length" value="#var_content_len#">
    <cfcontent type="#var_content_type" file="#GetTempDirectory()#/#varFileName#">

  • 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.

  • Setting MIME type in IIS 4 & 5

    Well I am very impressed with this Web Start technology but it was a little slow downloading via sun's site.
    I set about trying to set it up on my company Intranet server before I demonstrated to my IT director.
    I saved the swingset2.jnlp file from the sun demo's page, used the Swingset2.jar file from the JDK 1.3.1 demos and got the swingset2.jnlp images and put them in an images subdirectory. Next I amended the swingset.jnlp to my own web server by changing the cobebase parameter. I then created a simple web page wrapper with a link to the jnlp file.
    In my directories I have the following files:
    swingset2.html
    swingset2.jar
    swingset2.jnlp
    images\swingset2.small
    On the server side IIS 5.0, I go into master properties for my web server, go to HTTP headers and hit the file types button.
    I then add a new entry with associated extension .jnlp and content type of application/x-java-jnlp-file
    Also found and changes the IIS.inf file just in case.
    Rebooted the web server to make sure everything is initialised correctly.
    When I launch the jnlp file from a client PC "Java Web Start" starts but I get the following error "Unable to launch Swingset2", details "category: download error. Bad MIME type returned from server when accessing resource: http://Newgreg/jaws/Swingset2.jnlp - text/html.
    The jnlp used is listed:
    <!--
    # @(#)template.jnlp     1.2 01/04/25
    # JNLP File for SwingSet2 Demo Application
    -->
    <?xml version="1.0" encoding="utf-8"?>
    <jnlp spec="1.0+"
    codebase="http://NewGreg/jaws/apps"
    href="SwingSet2.jnlp">
    <information>
    <title>SwingSet2</title>
    <vendor>Sun Microsystems, Inc.</vendor>
    <homepage href="../demos.html"/>
    <description>SwingSet2 Demo</description>
    <description kind="short">A demo of the capabilities of the Swing Graphical User Interface.</description>
    <icon href="images/swingset2.small.jpg"/>
    <offline-allowed/>
    </information>
    <resources>
    <j2se version="1.3+"/>
    <jar href="SwingSet2.jar" main="true" download="eager"/>
    </resources>
    <application-desc main-class="SwingSet2"/>
    </jnlp>
    Can anyone help??? I would love to start using this technology, it looks very promising.
    Email: [email protected]

    Have you been able to write your own java app and deploy it on that same server by any chance? It's hard to say whether it's something to do with the swing start demo configuration or whether it's your server's configuration. Since it's reporting bad MIME type I'm wondering if it's more related to the web server configuration.

  • How To Get FileType and MIME Type from a File

    Hi,
    I am using following ways to get FileType and MIME Type.
    I am able to get file type, but I am getting MIME Type as */*
    Can any one please let me know how to get MIME Type, but it should not be time consuming process.
    For File Type I am using following Code:
    private String getFileData(InputStream inStream) {
    fileName = C:\temp\temp.tiff
    String filePath = Util.createTempFile(fileName);
    RandomAccessFile raf = new RandomAccessFile(filePath, "rw");
    while (inStream.available() > 0) {
         byte[] buf = new byte[inStream.available()];
         inStream.read(buf);
         raf.write(buf);
    inStream.close();
    raf.close();
    File file = new File(filePath);
    JFileChooser chooser = new JFileChooser();
    String fileType = chooser.getTypeDescription(file);
    file.delete();
    //MIME Type I am getting from
    DataHandler data = new DataHandler(new DocumentSource(inStream));
    data.getContentType();
    data.getContentType() is not working well in all cases.
    Can any one help me on this.
    Thanks in advance,
    Ram.
    Edited by: javausers07 on Apr 15, 2009 4:25 PM

    javausers07 wrote:
    Hi,
    I am using following ways to get FileType and MIME Type.
    I am able to get file type, but I am getting MIME Type as */*
    Can any one please let me know how to get MIME Type, but it should not be time consuming process.
    For File Type I am using following Code:
    private String getFileData(InputStream inStream) {
    fileName = C:\temp\temp.tiff
    String filePath = Util.createTempFile(fileName);
    RandomAccessFile raf = new RandomAccessFile(filePath, "rw");
    while (inStream.available() > 0) {
         byte[] buf = new byte[inStream.available()];
         inStream.read(buf);
         raf.write(buf);
    inStream.close();
    raf.close();
    File file = new File(filePath);Why do you do all above?
    JFileChooser chooser = new JFileChooser();
    String fileType = chooser.getTypeDescription(file);
    file.delete();
    //MIME Type I am getting from
    DataHandler data = new DataHandler(new DocumentSource(inStream));
    data.getContentType();
    data.getContentType() is not working well in all cases.That's because there's no way to get MIME type of all files on all filesystems.
    Kaj

  • When I try to click on a download link for a .pdf file Firefox does not recognize the MIME type and tries to download the file as "index.php"

    When visiting a site I frequent I tried to download a linked .pdf file. Previously I've used Firefox 7.0.1 to download the link with no problem. Using Firefox 8 however I the browser does not recognize the .pdf link's mime type. Instead of recognizing the download link as a .pdf file Firefox 8 tries to download it as "index.php". Firefox 8 does this with .doc files and .txt files as well. When I downgrade to 7.0.1 again the problem disappears.

    Hi hakmacpace,
    I'd try starting Firefox in [[Safe Mode]]. If you don't have the issue while all of your add-ons, extensions, and themes are disabled, you can try adding them back in one by one until you find the culprit. You should look at the [https://support.mozilla.org/en-US/kb/Troubleshooting-extensions-themes Extensions and Themes troubleshooting guide ] and the [[Troubleshooting plugins]] article as well.
    You could also try [https://support.mozilla.org/en-US/kb/Managing-profiles?s=create+a+new+profile&r=2&e=es&as=s#w_creating-a-profile Creating a new profile].
    Hopefully this helps!

  • Gnome: mime types, file associations and defaults.list

    I installed the new Gnome 2.8 during the weekend and now my file type associations is completely bloated. The mime system is intact - Nautilus recognises files properly. However, Nautilus doesn't know which applications to open a specific file with. I have read other posts and found useful information, but not the solution.
    This post in FedoraForum gave me a hint to what's causing the problem:
    http://fedoraforum.org/forum/showthread … post127530
    It seems that the file defaults.list is missing from /usr/share/mime/applications. Apparently this file contains the associations  between applications and mime types. I have not be able to find out which package should provide this file or how to recreate it. Can anyone help - maybe provide the name of the package that provides this file?
    Thanks,

    Yeah, I got tired of Evolution not knowing about opening *.docs in openoffice.  After several hours of research, the key is the /usr/share/applications/mimeinfo.cache,  /opt/gnome/share/applications/mimeinfo.cache, and the MimeType fields in the *.desktop files.  The mimeinfo.cache in /usr was empty and the /opt one had gthumb and other apps but no OO:
    [MIME Cache]
    application/x-gnome-stones=gnome-stones.desktop
    image/jpeg=gthumb.desktop
    application/postscript=ggv.desktop
    ...snip...
    That's a lot of blather to say that the fix for Evolution/OpenOffice was to add the proper MimeType entry to /usr/share/applications/ooo645writer.desktop:
    MimeType=application/vnd.ms-word;application/msword
    and then run "update-desktop-database".  Problem solved.
    Another problem is that within Evolution it says an attached doc is a "application/msword" and not a "Microsoft Word Document".  Unfortunately this is because freedesktop.org decided to use application/vnd.ms-word instead of application/msword like the rest of the world.  If you check the vnd.ms-word entry in /usr/share/mime/packages/freedesktop.org.xml it defines an alias msword but the new mime system doesn't appear to recognize aliases yet.  The solution I used was to rename the entry to msword.  Another possible solution might be to remove the msword alias from the vnd.ms-word entry and create a new msword entry based on the vnd.ms-word one.  Then run "update-mime-database /usr/share/mime".  Hope that made sense.
    I think the defaults.list is part of the previous GNOME MIME setup cause I don't have one and I'm not experiencing any problems.  For other apps check for the associations in the mimeinfo.cache's and if missing add the MimeType's to the app's *.desktop.

  • 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 and/or extension of script file

    I would like to generate a script file dynamically on my web server and then have it downloaded to my users such that they can simply double-click the file and have it execute. I've gotten pretty close by using the ".command" extension, but it still requires a "chmod +x filename" after download in order to work properly. Is there another extension or a mime-type that I could use that would cause Mac OS X 10.4 and/or 10.5 to grant execute rights to the user that downloaded it? I'm not married to it being shell script if it can be done with AppleScript, Ruby, etc that would be great. It basically just has to be text file (non-binary format) so I can dynamically generate it on the server side.

    Hi Daniel,
    do you use EPG, mod_plsql or APEX Listener? Have you changed the connection mechanism after upgrading to 4.2.1?
    If you use the APEX Listener, which version do you use? Which browser and version do you use to upload the file? Does it reproduce with other browsers as well?
    Regards
    Patrick
    Member of the APEX development team
    My Blog: http://www.inside-oracle-apex.com
    APEX Plug-Ins: http://apex.oracle.com/plugins
    Twitter: http://www.twitter.com/patrickwolf

  • 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

Maybe you are looking for

  • How can i restart my iPhone 4 accidentally erased from remotely of fine me

    Hiiii I one to restar my son's iphone 4, last night i was using fine me in my iphone 4s and i erase my son's iphone 4 dives in my iphone 4s, i accidentally erase from fine me, pls. help me how to restar? it's not starting, there are in serch mode now

  • Why can't I get Adobe Reader to download on my mac?

    Error message 'installation failed' comes up only a few seconds after starting download. Have had my MacBook Pro OS X 10.7.2 for less than a year, and downloaded microsoft office for word processing. Does the error message "PKInstallSandbox-tmp" rela

  • Java.lang.UnsatisfiedLinkError in Eclipse 3.2.1

    Deal all, sorry for the basic question, i met the following error when i try to use swing through swt , "Exception in thread "main" java.lang.UnsatisfiedLinkError: no swt-win32-3235 in java.library.path" and i already add "org.eclipse.swt.win32.win32

  • Read from text file, pls help!!

    hi, I am new to java. i made a scribble applet and saved the painting out as a text file. Now I want to read the 'paint' lines from the text files back to the applet, so that they appear on the canvas. Does any one konow how to paint the lines back t

  • Benchmarking line in the chart

    Hi I have created one VC model for comparitive analysis of feedack of the training program. Based on this i want some benchmark so that i can compare this with others. To do this i want to show some benchmarking line in my chart. How do i do this? Th