My revised version
![]() ![]() |
I've posted a revised version of Simplepedia on pastebin. Nothing exciting but will help Greasekit and Opera users. http://aucg.pastebin.com/cUeU2cHb Changes:
Changes:
1.1: http://aucg.pastebin.com/g6n4nSKC Changes:
|
![]() ![]() |
Too cool. Smart rearrangement too. Given the include http://* settings, any reduction in execution is a major bonus. |
![]() ![]() |
Where were you seeing it run on google? |
![]() ![]() |
Once, I saw it run on Google where Wikipedia had a search result quite a while ago... don't think it happens any more. Execute would have been a better word... Changing that now. |
![]() ![]() |
Just looking over the code again, I see that the favicon is being fetched from your server. It would probably be better if the icon was base64 encoded and put directly in the script. What? You don't have a base64 encoder? Here's one: http://www.opinionatedgeek.com/dotnet/tools/Bas... |
![]() ![]() |
I need to quit tweaking the next version and release it - already have base64'd a better version of the icon in it.
// Add a new favicon if it is wikipedia
if (url.match(/http:\/\/?(\w*\.|)wikipedia\.org\//i)) {
var favicon = document.createElement('link');
favicon.setAttribute('type', 'image/x-icon');
favicon.setAttribute('rel', 'shortcut icon');
favicon.setAttribute('href', 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAALpJREFUeNrEU1ENhTAMHDjAwiw8C7PwLGABLWhAAlhAwpAwJAyaXJdbs7z3wQdNmjVlbe96o8s5uyfWu4f2fgOHHUQJbx/p04xcpJxHTtxLrSLYcH7ocqAib3IHvDTYfxRxXgcslkIFDVQkTjhnXFeqodTSO+A9KP+J9uCpaRnOKiwEM1DuQPHX0K0oKE+GHY0aiVA1EYgS5+2DUUYnDv8QiK20zLGhfbK19iVujbhoXskH617/Gy8BBgDHv1uI+O2cEwAAAABJRU5ErkJggg%3D%3D');
var head = document.getElementsByTagName('head')[0];
head.appendChild(favicon);
}
If I set up a github repository, could we use that to collaborate? |
![]() ![]() |
It's also only a matter of futzing with photoshop to include base64 representations of the alphabet, so that we can apply the first letter of the parent domain to any site. Fismapedia would get an F, and so on. Or we could make base64 representations of the major languages offered by wikipedia - ~30 should cover most users at first, and offer that as the favicon. |
![]() ![]() |
Yes, please set up a github repository. Err, isn't that favicon the same as the one on your server, or did you use Hmm... could we make the Simplepedia style selectable in the View -> Page Style menu, but selected by default? I wonder... but of course, that would take a bit of work... |
![]() ![]() |
Looks like my rearrangement influenced Grant: http://grantstavely.com/simplepedia/devpedia.us... Umm... you couldn't use a different function name for "addStyle(section,useCSS)"? I recommend you use my version for now, who knows what bugs Grant could accidentally add to the development version.... |
![]() ![]() |
Yup, the dev version is a mess right now, avoid it. School and work are both crazy right now and I haven't had time to get bak to this project. |





