(* google.article.fix v.1.01 * written: Sasaki Atsushi * last modified: Sun, 19-May-2002; * * This script fixes a mangled (Moji-Bake) Japanese article on Google Groups. * works with Internet Explorer 5.x for Mac OS 8-9. * does not support multiple articles. * * Google Groups *) tell application "Internet Explorer" set theURI to GetWindowInfo -1 set theURI to item 1 of theURI if theURI contains ".google." and theURI contains "/groups?" then if theURI contains "output=gplain" then if theURI does not contain "&oe=iso-2022-jp" then set theURI to theURI & "&oe=iso-2022-jp" OpenURL theURI toWindow -1 return false else display dialog "This article might be already encoded by ISO-2022-JP." buttons "Done" default button "Done" with icon note return false end if else if theURI contains "&selm=" then set dlimTmp to AppleScript's text item delimiters set AppleScript's text item delimiters to "&selm=" set MID to last text item of theURI as text set AppleScript's text item delimiters to dlimTmp set theURI to "http://groups.google.com/groups?selm=" & MID & "&oe=iso-2022-jp&output=gplain" else display dialog "This script does not support multiple articles." & return & "Show one article by \"Original Format\", then run this scrip." buttons "Done" default button "Done" with icon stop return false end if OpenURL theURI toWindow -1 else display dialog "This script works on only Google Groups." buttons "Done" default button "Done" with icon stop return false end if end tell -- EOF