Archive

Posts Tagged ‘Mozilla’

Fix: Re-enable ClickOnce deployment at Mozilla Firefox

When you try to run a ClickOnce Windows application from Mozilla Firefox, on some machines you may see it try to save a .application (ClickOnce deployment manifest) instead of running the ClickOnce application installer/updater/launcher.

To fix that issue you can open Firefox add-ons dialog and search among available to download/install add-ons for "net framework assistant". From the results list select to install "Microsoft .NET Framework Assistant" (version 1.3.1 shown at the screenshot below).

You can try the ClickOnce installation process with ClipFlair‘s WebCapture tool.

image

Gotcha: must set document.location.hash only at end of page in Mozilla

I just came across a different behaviour between IE and Mozilla Firefox: scripts at the former seem to execute after the page has fully rendered, while the later they seem to execute when they’re met by the page parser or something like that.

The HTML script tag has a defer attribute for running scripts after page has rendered, but that is available only for script tags that load an external script, not for embedded scripts in the HTML page. So this seems like one of those different interpretations that usually plague "standards". 

So, at the following JSP code, I was creating a table of student entries with a named anchor (bookmark) at each of the entries (each named per student id), so that when coming back from another page to that one I could tell it to scroll down to a given student automatically.

The issue was that if I placed the script that set document.location.hash to the student id, then at IE it worked OK, but at Mozilla Firefox it just moved to the top of the page even though the URL at the address bar of the browser had the hash entry (e.g. #55555) at the end and would scroll down correctly if I pressed Refresh button there.

Moving the script to the end of the page made it work for both IE and Mozilla Firefox. Don’t you love HTML’s "debug everywhere"?

 

<%@ page contentType="text/html" session="true" pageEncoding="UTF-8" %>

<%
response.setHeader("Cache-Control", "no-cache, no-store"); //HTTP 1.1
response.setHeader("Pragma", "no-cache"); //HTTP 1.0
response.setDateHeader ("Expires", -1); //prevents caching at the proxy server
%>

<%@ page import="javax.portlet.*" %>
<%@ page import="java.util.ResourceBundle" %>

<%@ taglib uri="http://java.sun.com/portlet" prefix="portlet" %>
<%@ taglib uri="http://java.sun.com/jstl/fmt" prefix="fmt" %>

<%
  RenderRequest renderRequest = (RenderRequest) request.getAttribute("javax.portlet.request");
  RenderResponse renderResponse = (RenderResponse) request.getAttribute("javax.portlet.response");
          

  String studentId = (String)renderRequest.getAttribute(Constants.JSP_RENDER_STUDENTID);
  if (studentId == null) studentId = "";

  <%
       for(int i = 0; i < proposalsCount_supervisor; i++) {
        IProposalListItem proposal = proposals_supervisor.getProposalListItem(i); 
   %>
  <a name="<%=proposal.getStudentId()%>"></a>
   <div class="dissertation_subsection<%=(i%2)%>">

     <div>
     ….

   <%}%>

….

<script type="text/javascript"> <%– MAKE SURE THIS IS PLACED AT THE END, ELSE IT WON’T WORK AT MOZILLA –%>
document.location.hash="<%=studentId%>"; //scroll to previously examined student
<%– alert(document.location.hash); –%>
</script>

Try IE9 with HTML5 showcases from Microsoft, Mozilla, Google and Apple

Since IE9 final version is being released today (http://www.beautyoftheweb.com), here are some HTML5 showcases from different browser makers to test it out against:

Could even try some of Google’s Chrome specific demos in case they work with IE9 too: http://www.chromeexperiments.com/

 

IE9 RC (Release Candidate) wasn’t fully HTML5 compliant last time tested mind you, but neither the other browsers were as you can see at W3C tests:

http://test.w3.org/html/tests/reporting/report.htm

http://www.w3.org/html/wg/wiki/Testing

IE9 is way better though than IE8: http://samples.msdn.microsoft.com/ietestcenter/

Can also see lots of HTML5 tests for browsers at: http://html5demos.com/

 

BTW, it is very interesting that IE9 also supports the WOFF format (Web Open Font Format). Typeface lovers can drool freely here: http://lostworldsfairs.com/

 

Here’s a relevant post with nice video of Mozilla’s showcase: http://techtimely.wordpress.com/2011/03/08/html5-showcase-demos/

 

So should we start drooling on future WebGL support in the browsers’ world too now?

http://techtimely.wordpress.com/2011/03/04/webgl-1-0-specification-releasedwebcl-coming/

(see video at that post and find more WebGL apps at http://learningwebgl.com/blog/)

%d bloggers like this: