[wp-trac] [WordPress Trac] #3731: Bookmarklet not available in Opera
WordPress Trac
wp-trac at lists.automattic.com
Wed Jan 31 18:08:09 GMT 2007
#3731: Bookmarklet not available in Opera
----------------------------+-----------------------------------------------
Reporter: kelson | Owner: anonymous
Type: defect | Status: new
Priority: normal | Milestone: 2.2
Component: Administration | Version: 2.1
Severity: normal | Keywords: opera browser
----------------------------+-----------------------------------------------
When using Opera with WordPress 2.1, the link to the Press It! bookmarklet
does not appear on the Write Post page. Copying the link from a Firefox
window into Opera's bookmarks demonstrates that the bookmarklet code does
work in Opera 9. (I have not tested the current bookmarklet with older
versions.)
It looks like you're doing excessive browser sniffing in post-new.php,
assuming (incorrectly) that Opera cannot handle the feature:
{{{
if ($is_NS4 || $is_gecko) {
...
} else if ($is_winIE) {
...
}
}}}
Since WebKit, Gecko, and Opera all work with the same JavaScript, perhaps
a better way would be something like this:
{{{
if ($is_winIE) {
...
} else {
...
}
}}}
Note for browser sniffing purposes: Beginning with Opera 9, Opera uses its
own user-agent by default instead of spoofing MSIE or Mozilla. Neither
$is_winIE nor $is_NS4 nor $is_gecko will fire. Example:
{{{
Opera/9.10 (X11; Linux i686; U; en)
}}}
--
Ticket URL: <http://trac.wordpress.org/ticket/3731>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list