Jump to content
Chinese-Forums
  • Sign Up

Bookmarklet for Pinyin conversion


Recommended Posts

Posted

Inspired by this post (or maybe selfishly thinking "Then what about us, Chrome users?"), I decided to improve a little bit on this idea.

Rather then creating an extension, which seems to be too much effort for such a simple task, why don't we create a bookmarklet, which, by the nature of it, will also work in other browsers. The following bookmarklet should work in any reasonably modern browser*.

Unfortunately I couldn't place the link itself into this post, as the forum software strips JavaScript URLs. To get the bookmarklet follow this link. Clicking on the bookmarklet will convert numbered Pinyin in the currently focused text area into proper Pinyin with diacritical marks.

NB:

* Tested only in Chrome and Firefox. If it doesn't work in your browser (but you want it to), let me know.

  • Like 1
Posted

I'm trying it in FF, on Mac (Lion) and it's not working. Also from looking at the code, it looks like there are some parsing problems and issues handling the ü.

Edit: I'm on the newest version of FF.

Posted

Thanks. Completely forgot that it's possible to type "ü" with some keyboard layouts; was assuming there will always be "v" instead. Fixed that.

As for why it doesn't work in Firefox on Mac... it's really puzzling. I don't have Mac OS anywhere handy to look into this, but there is really no reason why OS should matter at all. May I ask you which version of Firefox you tried?

Join the conversation

You can post now and select your username and password later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Click here to reply. Select text to quote.

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...