Saturday, January 05, 2008

IE coming to a Linux near you

Well first up HAPPY NEW YEAR to everyone. Goodbye 2007, helooo 2008 :D. Ok now back to blogging...

If you're into web development AND you're on a Linux machine, testing your site to make sure it looks and plays well with IE is a definite must. Well thanks to the folks at IEs 4 Linux, we can now get it working on Linux without having to boot up windows. This script can install IE5, IE5.5 or IE6. Below are the steps to get it working :-
  • You must install wine and cabextract first.
    • sudo apt-get install wine cabextract
  • Download ies4linux here.
  • Untar it in a folder of your choice and switch to that directory.
  • Install it using "./ies4linux --no-gui" (if you're installing on a remote machine).
  • Watch it download and install the necessary stuff from Microsoft's website and Flash from Adobe.
  • After you're done, you can execute it by typing "ie6" from the command line or on the link from your desktop.
  • Test your site on IE to see how it looks ;)

It is also possible to install IE7 using the method described here. Google has been kind enough create a stand alone installer which can be obtained from this link for those who just wish to obtain IE7. I'm listing the quick steps to get IE7 working here. For a more comprehensive explanation, check out the link above.
  • Switch to your local ies4linux directory.
    • cd ~/.ies4linux
  • Copy your existing IE6 folder to IE7
    • cp -r ie6 ie7
  • Replace all references of ie7 to ie7
    • sed ~/.ies4linux/bin/ie6 -e 's/ie6/ie7/g' > ~/.ies4linux/bin/ie7
  • Make the new ie7 script executable
    • chmod +x ~/.ies4linux/bin/ie7
  • switch to the directory your downloaded IE7 to.
  • use cabextract to extract the files needed
    • cabextract IE7Setup_G.exe
  • now use cabextract on the IE7 setup actual
    • cabextract IE7-Setup.exe
  • now run this command
    • for i in wininet iertutil shlwapi urlmon jscript vbscript \
      ieframe mshtml mshtmled mshtmler advpack
      chmod +x $i.dll
      cp $i.dll ~/.ies4linux/ie7/drive_c/windows/system/$i.dll
    • chmod +x inetcpl.cpl
    • cp inetcpl.cpl ~/.ies4linux/ie7/drive_c/windows/system/
  • These 2 files are needed for IE7 to work
    • normaliz.dll =
    • inetcplc.dll =
  • Copy the 2 files to your IE7 folder
    • cp normaliz.dll ~/.ies4linux/ie7/drive_c/windows/system
    • cp inetcplc.dll ~/.ies4linux/ie7/drive_c/windows/system
  • Make sure WINE is using Windows XP as its container otherwise the there will be view pane corruption
    • WINEPREFIX=~/.ies4linux/ie7 winecfg
  • Lastly create a shortcut to IE7
    • ln -s ~/.ies4linux/bin/ie7 ~/bin/ie7

Happy browsing :D

No comments: