Showing posts with label Internet Explorer. Show all posts
Showing posts with label Internet Explorer. Show all posts

2016-12-19

Internet Explorer 11 Compatibility View

Internet Explorer 11 has a "compatibility view" setting so that you can open web sites or applications that rely on quirks in older versions of the browser. However, you can only specify compatibility view for a top-level domain (i.e. test.com), not a sub-domain (i.e. xyz.test.com) or even a URL (i.e. http://test.com/app), so it's useless if your organization has quirks-mode and standard-mode applications. An alternative is to create a compatibility list in a group policy. We are transitioning away from quirks-mode but the interim is a PIA for users and administrators (who have to explain to users how MSIE works).

2011-12-05

Google ChromeFrame incompatible with Oracle Hyperion DRM

If you have installed the Google ChromeFrame add-on for Internet Explorer (MSIE) 7 or 8, you may find that you cannot login to Oracle Hyperion Data Relationship Management (DRM) 11.1.2.1. After MSIE loads the DRM login page, you may see some Javascript errors and when you press the Log on button, nothing happens.

Coincidentally, I started seeing this error message on another web site: ERROR: Possible problem with your *.gwt.xml module file. The compile time user.agent value(ie8) does not match the runtime user.agent value (safari). Expect errors. It seems that Google ChromeFrame add-on, which I installed to improve Javascript performance when I was using IE7, can send the wrong user-agent information to a server (even if the add-on is disabled). I have since upgraded to MSIE8, which is fast enough, so I no longer needed ChromeFrame and I uninstalled it.

Now, I can login to DRM and the GWT error messages no longer appear.

2009-04-25

Internet Explorer Submit Button Bug

While testing a simple form in Firefox and MSIE 7, I found that my server-side program got different values for HTML submit buttons depending on the browser. Below is a test HTML file to demonstrate the problem. Copy and paste the text below into a test file, open the file in your browser and press the Test button.

<html>
  <body>
    <form method='get'>
      <button name='testSubmitButton' type='submit' value='value1'>Test</button>
    </form>
  </body>
</html>

Examine the URL in the address bar.

In Firefox 3.0.9 and Opera 9.52, the URL is: file:// … MsieSubmitButton.html?testSubmitButton=value1, so the value is sent from the browser with the button name.

In MSIE 6.0.2900.5512 and MSIE 7.0.6001.18000, the URL is: file:// … MsieSubmitButton.html?testSubmitButton=Test, so the text of the button is sent from the browser with the button name.

Both MSIE's behaviour doesn't conform to the HTML 4.01 recommendation on Controls:

Each control has both an initial value and a current value, both of which are character strings. … In general, a control's "initial value" may be specified with the control element's value (emphasis mine) attribute. …
The control's "current value" is first set to the initial value…

When a form is submitted for processing, some controls have their name paired with their current value and these pairs are submitted with the form. …

My workaround was to give each submit button a unique name and change the server-side program to use the button name instead of the button value. While this was adequate for my task, it was an annoying, basic problem that shouldn't still exist.

While researching this bug, I found other issues with MSIE when using submit buttons in HTML forms, so be careful!

See Also

2009-04-23

Enabling and Disabling Javascript in Internet Explorer 7

How to enable or disable Javascript in MSIE7:

  1. Select Tools / Internet Options.
  2. In the Internet Options dialog, select Security tab.
  3. In the Security tab, select Custom Level button.
  4. In the Security Settings dialog, scroll down the tree of properties in the Settings list until you find the Scripting / Active Scripting node, then select the Disable or Enable radio button to disable or enable Javascript, respectively.
  5. Press OK buttons to accept your change.

That's a lot of steps if you want test if your Web page works with and without Javascript! It's very annoying that Microsoft decided to call the feature Active scripting instead of Javascript, that you can't expand or collapse the nodes in the Settings tree, nor can you easily jump to the required node by typing the first few letters (the control jumps first to ActiveX controls … first)!

See Also

2008-08-27

What's the time?

14 quick ways to find the current time on your computer.

Cmd.exe has two built-in commands for the date and time. You have to add the /t option when calling these commands otherwise you are prompted to set the system time:

> date /t
Wed 27/08/2008
> time /t
07:42 PM

GnuWin's date command prints the date, time and time zone:

> date
Wed Aug 27 19:43:23 AUS Eastern Standard Time 2008

You can use the POSIX module in Perl to get the current date and time:

> perl -e "use POSIX; print asctime(localtime());"
Wed Aug 27 19:44:21 2008

Python has a time module similar to Perl's:

> python -c "import time; print time.asctime()"
Wed Aug 27 19:48:07 2008

PHP's time and date functions return an array, which you can dump using the print_r() function:

> php -r "print_r(get_date());"
Array
(
    [seconds] => 49
    [minutes] => 34
    [hours] => 14
    [mday] => 30
    [wday] => 6
    [mon] => 8
    [year] => 2008
    [yday] => 242
    [weekday] => Saturday
    [month] => August
    [0] => 1220070889
)

Ruby has a Time class:

> ruby -e "print Time.now"
Wed Aug 27 19:45:32 +1000 2008

PowerShell has a get-date cmdlet:

> get-date
Wednesday, 27 August 2008 7:50:13 PM

Or use the .Net System.DateTime.Now property in PowerShell:

> [System.DateTime]::Now
Thursday, 28 August 2008 9:53:21 AM

Firefox can tell you the time using the Javascript Date() object. Enter the following statement in your browser's address bar:

javascript:Date()
Wed Aug 27 2008 20:11:27 GMT+1000 (AUS Eastern Standard Time)

MSIE6 has a similar object but the output is different from Firefox's:

javascript:Date()
Thu Aug 28 10:06:59 2008

Groovy (and Java) has a java.util.Date object which defaults to the current time:

new java.util.Date()
Result: Thu Aug 28 09:58:45 EST 2008

2008-06-27

Firefox 3 SVG Performance Improvement

I did a quick check of my SVG Game of Life demonstration with Firefox 3 and found that it ran much faster compared to Adobe's ancient SVG Viewer 3.03 (ASV). The performance ratio used to be roughly 3:2 in favour of Firefox. Now, it's close to 5:1!

The raw numbers on the same computer: 24-27 fps on Firefox 3, 5-6 fps for MSIE6 + ASV.

2007-12-08

Renesis SVG Plug-in

It's old news that Adobe no longer develops its SVG Viewer plug-in. The only browser that really required an SVG plug-in is MSIE; Firefox, Opera and Safari browsers support SVG. If you're still using MSIE and want to view SVG, Examotion has a pre-release Renesis SVG plug-in.

I viewed some pages containing SVG with Renesis and found Renesis can display static images and Javascript animation in an <object> tag. Renesis doesn't currently support in-line SVG (essentially SVG code in XML).

2006-12-22

MSIE Autocomplete Annoyance

I had accidentally typed the wrong URL for my test system into MSIE6 one day and whenever I try to visit the same site, MSIE6's autocomplete feature would NOT let me change the URL. The wrong URL I first entered was local:7001/ when I meant localhost:7001/. Now, each time I try to enter localhost:7001/, MSIE6 would replace what I typed with local:7001/.

There's no way to delete that URL in the address (unlike Firefox, Shift-Delete doesn't work for MSIE6's address bar). So I used the Clear History feature in MSIE6 and blew away my history.

Then I found that auto-complete not longer had previously entered folder paths in Windows Explorer nor the name of programs in the Windows Run dialog. This is definitely unexpected and very annoying.

2006-02-27

IE6 MHTML Case-Sensitivity and CSS Paths

We wanted to generate and send an MHTML file to a customer. The source HTML page was on our file system and it referenced some image files and CSS files. We could have used a ZIP archive instead, but since IE6 could create .MHT files, we thought we had a simple solution.

After generating the MHTML file, we opened it on another computer and we noticed that the styles were not working. After some hacking, it turns out that there are two problems with the MHTML file generated by IE6:

  1. The <link> tag and Content-Location contain an absolute path to the CSS file. We had to replace those path strings with a relative path string.
  2. Harder to spot but very annoying was that IE6 now treated CSS class names as case sensitive, so class="footer" and class="Footer" are different. IE6 ignores the case of class names when it opens HTML files!

It turns out that Firefox's MAF extension is a better solution. MAF generates relative paths for files (the first problem) and in this sense, generates better MHT files than IE6. I found it a bit ironic since Firefox does not, by default, open MHT files.

2005-10-04

Software: IE6 Fieldsets Leak

When creating HTML forms with the <fieldset> element, I add some padding so that the elements within the fieldset do not touch their container's border. In the CSS box model, padding is the amount of space between a box's border and its contents.

Below is an example of a fieldset definition that has a legend in the fieldset, a label and a field:

<div style="background-color:9dbc80">
  Hello world
<fieldset style="background-color:#d1dfd6;margin:0px;
padding:4px;border:1px solid black">
  <legend>Test legend</legend>
 <label>Test:</label>
 <input type="text" value="This is a test"/>
</fieldset>
  Bye world.
</div>

And below is a rendering of the example defintion.

Hello world
Test legend
Bye world.

If you are using IE6, you should see that the background of the fieldset extends beyond the border to surround the legend text, while if you are using Firefox, the background is entirely enclosed within the border of the fieldset. Even worse in IE6, the amount of area beyond the margin depends on the padding value!

2005-07-26

Software: IE6 crops child elements

While trying to implement a list of buttons, I found that IE6 crops the tops and bottoms of child elements when the parent element is a block level element. For example, if the parent is a ul element, the li elements would be cropped.

If you are using IE6, you should see that the top and bottom borders of the following TEST boxes are missing. Firefox users would see two boxes with borders around each one, as expected.

  • TEST
TEST

Below is the code to generate the TEST boxes.

<ul style="position:absolute">
 <li style="border:1px solid darkgreen;display:inline;">TEST</li>
</ul>
<div style="position:absolute">
 <span style="border:1px solid darkgreen">TEST</span>
</div>

The work-around is to add padding at the top and bottom of the parent element, e.g. padding:1px 0px 1px 0px, resulting in …

  • TEST
TEST

2005-07-25

Software: Chubby IE6 buttons

I found that the padding IE6's form buttons is proportional to the length of the button's text. If you're using IE6 and viewing this page, you should see that the padding in the second button is larger than the padding in the first button.  

2005-07-18

JScript in IE6 to read database

Inspired by this Kuro5hin article, I hacked up a slightly nicer JScript implementation to read database tables and generate HTML tables in a browser using DOM functions such as insertRow() and insertCell().

Try it out

If you want to try it out, first create an Excel workbook called Test.xls with a page named DataTest. In DataTest, create one column with a heading StringValue and another column with a heading NumericValue. Enter some test data in those columns, then save the file.

Next, copy the HTML code at the end of this article, change the DSN path appropriately and save it in a file.

Finally, load the HTML file in IE6. When you select the Test button, the data in your workbook should be displayed in the browser.

Notes

If you start Excel and the user interface doesn't initialize properly, the cause is usually the Excel automation server not exiting. Just start Windows Task Manager, and kill the errant Excel.exe process in the Processes tab.

I chose Excel instead of Access as the database because it is easier to test simple programs without having to create a table design.

Sample JScript and HTML to read database

<html>
  <head>
    <title>DBTest for IE6</title>
    <script type="text/javascript">
      function readDb(tableId) {
        var conn = new ActiveXObject("ADODB.Connection")
        var dsn = "Provider=Microsoft.Jet.OLEDB.4.0;"
        dsn += "Data Source=C:\\CVS_STUFF\\HTML\\Database\\Test.xls;"
        dsn += 'Extended Properties="Excel 8.0;HDR=Yes;IMEX=1"'
        conn.Open(dsn)

        var rs = new ActiveXObject("ADODB.Recordset")
        rs.Open("[DataTest$]", conn)

        var outputTable = document.getElementById(tableId)
        if (!outputTable) {
          alert("Cannot find " + tableId)
          return
        }

        if (!rs.bof) {
          var rowIndex = 1
          rs.MoveFirst()
          while (!rs.eof) {
            var row = outputTable.insertRow(rowIndex)

            var c1 = row.insertCell(0)
            var data1 = rs.Fields('StringValue').value
            var text1 = document.createTextNode(data1)
            c1.appendChild(text1)

            var c2 = row.insertCell(1)
            var data2 = rs.Fields('NumericValue').value
            var text2 = document.createTextNode(data2)
            c2.appendChild(text2)

            ++rowIndex
            rs.MoveNext()
          }
        }

        rs.Close()
        conn.Close()
      }

    </script>
  </head>
  <body>
    <h1>DBTest for IE6</h1>
    <form action="javascript:readDb('testOut')">
      <input type="submit" value="Test"/>
    </form>

    <table id="testOut">
      <tr><th>StringValue</th><th>NumericValue</th></tr>
    </table>

  </body>
</html>

2005-07-07

Software: Mark of the Web partie deux

Faced with the prospect of having to add MotW on every page I develop on my local disk, I had to find a better solution. Luckily, some nice people at PHD Computer Consultants Ltd explained how to disable this — cough — feature in IE6. In Tools / Internet Options / Advanced dialog, check Security / Allow active content to run in files on My Computer. Restart IE6 and load the offending file. No more Information Bar. Yay!

2005-07-04

Software: Mark of the Web

Since "upgrading" to Windows XP Service Pack 2, IE6 annoys me with an information bar warning me about active content whenever I load a local HTML file with Javascript code. The information bar does not appear when I load the same file from a network drive or from a Web server. It turns out that this is a new feature to protect me from myself. The workaround is to insert a Mark of the Web, which is just a comment string that IE6 adds to every web page saved locally. For every day work, <!-- saved from url=(0014)about:internet --> inserted at the start of the file is enough. The number in the parentheses is just the number of characters after the closing parenthesis.