lundi 14 septembre 2015

tab opening pdf file doesn't show favicon

I am opening a pdf file in Rails project in new window using following method in the controller:

    def open_pdf
       file_path = @my_model.pdf_location + "/my_pdf.pdf"
       if(File.file?(file_path))
         send_file( file_path,
         :disposition => 'inline',
         :type => 'application/pdf',
         :x_sendfile => true )
    else
       render :html, :text => "pdf file not available."
    end

The below code is in my view file as a link to open in new tab:

    <%= link_to "My PDF", my_pdf_path(fv), :target => "_tab" %>

Now when I clear the cache and open this pdf file in IE 11, that tab doesn't show the favicon (favicon.ico) but rest all browsers download the favicon and show that. When any browser downloads the favicon and opens this pdf, then IE also starts picking the favicon file. Looks like IE11 is not able to download the fvicon. This issue is only for pdf tab not any other page in my web console project. rest are the web pages hence able to download the favicon.

Thanks

Aucun commentaire:

Enregistrer un commentaire