delicious star rater

By thomd Last update Sep 29, 2010 — Installed 1,106 times.

Awesome script.

in
Subscribe to Awesome script. 3 posts, 2 voices



troglodita User

I love the idea of rating the bookmarks. The script is also nicely finished!.

The only thing I didn't like is having to use on the script to tag new bookmarks, I wanted to be able to fully edit this kind of tags without it. So I changed a bit the script.
BTW also lowered the number of stars to 3, otherwise it would create too many different tags IMHO.

These are the change I made:

38c38
< var tag_utf8_hex = "%E2%98%85";
---
> var tag_utf8_hex = "*";//"%E2%98%85";
44c44
< var max = 5;
---
> var max = 3;
97c97
< return (encodeURI($x(".//input[@name='tags']", contextNode)[0].value).match(/%E2%98%85/g) || []).length;
---
> return (encodeURI($x(".//input[@name='tags']", contextNode)[0].value).match(/\*/g) || []).length; // WAS: /%E2%98%85/g
139c139
< var tagsValue = encodeURI(tagsField.value).replace(/%E2%98%85/g, "");
---
> var tagsValue = encodeURI(tagsField.value).replace(/\*/g, ""); // WAS: /%E2%98%85/g
149c149
< tagsField.value = decodeURI(encodeURI(tagsField.value).replace(/%E2%98%85/g, ''));
---
> tagsField.value = decodeURI(encodeURI(tagsField.value).replace(/\*/g, '')); // WAS: /%E2%98%85/g

 
troglodita User

I forgot to mention that with those modifications the boomarks are actually tagged with asterisks (*) instead of stars.

 
thomd Script's Author

I was not aware of this problem about using UTF-8 symbols (which may be hard sometimes to enter). Thanks for this hint.

I'm thinking about making the rating-symbol and the number of symbols configurable in one of the next updates. Maybe this will fit your desires.

Cross
Presentational HTML allowed.
Use <code> for inline code and <pre> for code blocks. Use &lt; and &gt; for literal < and >.
We help break paragraphs and link your links.
or cancel