Login
Register
Add-Art
Wiki
Milestones
Tickets
New ticket
Search
Projects
Edit page
Title:
Add-Art Plugin development
Author:
Content:
Close preview
See also: * [[Development History]] * [[How to build and release a new version of AddArt]] * [[Version History]] ==Roadmap== -*v.5* Self contained plugin - keeps images in the plugin, images are updated when the plugin is updated. The add-art site doesn't automatically interact with the plugin. Changing the swapped images contained in the plugin happens manually.- DONE -*IMMEDIATE* - get add-on working in Firefox 3- *v1.0* Add-on updates images from a feed on the drupal site. ==How it works== Add-Art works with "AdBlockPlus":http://adblockplus.org # In artbanners.js our code makes a request for the AdBlockPlus object, then we parasite on it by substituting our function "shouldLoad" for ABP's old "shouldLoad" function. # Our new function first calls the old ABP "shouldLoad", which does the heavy lifting of finding out if an object is an ad or not. # If the object is an ad we then kick into our art substitution code. ## We generate a random number. *** This happens once per object rather than once per page. Moving this to the page level is key to fixing Ticket [#22]. ## We find images in our stuff that matches the dimensions of the object. ## We pick a random image from the best-dimension-matching images using the random number we picked earlier. # Code returns and firefox functions as normal. ==Problems== 1. -The fixing of this bug could make it very difficult to replace images that have been blocked in Firefox 3- -bug (now fixed): https://bugzilla.mozilla.org/show_bug.cgi?id=337246- -feature request to re-add this functionality (please add your comments): https://bugzilla.mozilla.org/show_bug.cgi?id=384778- 2. -Rhizome Commission celebration is at the New Museum on May 22nd.- See "ticket system":http://dev.eyebeam.org/projects/add-art/tickets ==What we need to do== * "get the plugin released on mozilla add-ons":http://dev.eyebeam.org/projects/add-art/ticket/42 - [[AOM nomination text]] * -"get the site ready for the public":http://dev.eyebeam.org/projects/add-art/tickets?milestone=11- * -"get xml file, parse it, and store images locally":http://dev.eyebeam.org/projects/add-art/ticket/44- CODED ===Greasemonkey code for harnessing Mozilla preferences=== "prefmanager.js":http://greasemonkey.devjavu.com/browser/trunk/src/chrome/chromeFiles/content/prefmanager.js This would be useful for choosing a new artist on each page load, sequentially instead of randomly. Also it would be useful for keeping track of when you last checked the server for new images. ===Helpful Links=== * "Building an Extension":http://developer.mozilla.org/en/docs/Building_an_Extension#Test * "Setting up extension development environment":http://developer.mozilla.org/en/docs/Setting_up_extension_development_environment ==Useful Files== === Extension building === Put this file in the main extension folder, and make sure that the name of the main folder is "extension-name". It generates the extension with only one mouse click. http://www.tobi-x.com/temp/build.bat (win/pc) === Artbanners.js === \trunk\artbanners\components\artbanners.js This is the file that provides the hook into ad block plus. We replace one of their hooks with one of ours. I suspect we may be able to grab a different page level hook on abp to roll the dice for a single gallery source per page. === addart.xml === \trunk\artbanners\chrome\content\addart.xml Provides the current actual function to load one of our images instead of the ad image. === scripts.xml and script_wrapper.js === These provide hooks to replace text only ads like google ad-sense with pictures. ==mistakes== * released on mozilla addons sandbox and didn't know I could update. User base went up, then down. * freaked out over the changes in FF3 and so far... there's been no problems. (fingers crossed) * ok that was wrong. FF3 was a problem. We should have put it on rent-a-coder sooner. * Hired the wrong developers. 3 developers have tried to start the project but don't get very far because of other jobs. ** Too generous giving time to work without results. In the future, ask for some measurable amount of progress within 1 week. Anyone agreeing to work on the project should be able to accomplish something on it within that amount of time. ** Didn't look for developers outside network of friends. Friends have jobs and are more likely to say yes because they want to help, even though they may not have enough time. * didn't break tasks into easier to accomplish parts, such as "fix this script" or make this 1 improvement. Instead explained the whole project. ** related with above, made a dumb mistake. Tried to accomplish the end result from the beginning instead of scaling up. For example, wanted first version of the plugin to load images from a server instead of starting smaller by having images load locally.
Markup reference
|
Preview content
|
Cancel