Now, firefox -remote 'ping()' should be firefox -a firefox -remote 'ping()'. Also, firefox -remote 'openURL(http://slashdot.org/, new-tab)' should be firefox -a firefox -remote 'openURL(http://slashdot.org/, new-tab)'. Etc.
I know from experience that (some?) 1.x Bash versions have a bug in the getopt builtin. The bug seems to be fixed in 2.x versions (not sure what version fixed it). There is a workaround for the bug, but it breaks portability of the script. The workaround also causes the script to break for fixed versions of Bash.
Found a solution via Firefox Forums.
Now, firefox -remote 'ping()' should be firefox -a firefox -remote 'ping()'. Also, firefox -remote 'openURL(http://slashdot.org/, new-tab)' should be firefox -a firefox -remote 'openURL(http://slashdot.org/, new-tab)'. Etc.
I know from experience that (some?) 1.x Bash versions have a bug in the getopt builtin. The bug seems to be fixed in 2.x versions (not sure what version fixed it). There is a workaround for the bug, but it breaks portability of the script. The workaround also causes the script to break for fixed versions of Bash.