Hi,
I'm kind of new to this (just got my first mac), so maybe the answer is really easy, but I have 2 questions. I'm trying to set a bookmark that looks up selected Arabic text (from a webpage) in an online dictionary like so:
javascript:x=escape(getSelection());if(x.length){window.location='http://dictionary.sakhr.com/idrisidic_2MM.asp?Lang=E-A&Sub='+x;}else{alert('Nothing%20Selected');}
where this text is the location of a bookmark in Safari.
1. The text gets mangled, e.g. it becomes something like: %u0627%u0644%u062B%u0627%u0646%u064A
How do I prevent the text mangling that is going on? I tried unescape(x) in the location, but this gave a weird partly-Arabic-partly-gibberish font. Any ideas?
2. Maybe a simpler question. How do I get the bookmark to open in a new tab (i.e. by modifying the javascript line above)?
Thanks,
Noam
I'm kind of new to this (just got my first mac), so maybe the answer is really easy, but I have 2 questions. I'm trying to set a bookmark that looks up selected Arabic text (from a webpage) in an online dictionary like so:
javascript:x=escape(getSelection());if(x.length){window.location='http://dictionary.sakhr.com/idrisidic_2MM.asp?Lang=E-A&Sub='+x;}else{alert('Nothing%20Selected');}
where this text is the location of a bookmark in Safari.
1. The text gets mangled, e.g. it becomes something like: %u0627%u0644%u062B%u0627%u0646%u064A
How do I prevent the text mangling that is going on? I tried unescape(x) in the location, but this gave a weird partly-Arabic-partly-gibberish font. Any ideas?
2. Maybe a simpler question. How do I get the bookmark to open in a new tab (i.e. by modifying the javascript line above)?
Thanks,
Noam