Basic function of Chickenfoot

Go to http://groups.csail.mit.edu/uid/chickenfoot/ and download the Chickenfoot plugin to your Firefox browser. 1. Write a simple query script that goes to any kind of search engine except Google, type in a keyword and click the submit button with your script. Try to write it both manually and using the action recorder. 2. Write a script that highlights some fixed keywords you give in bold face, and define a trigger on which pages this should be used. 3. Write a Chickenfoot script that generates a different formatting of the results of a search in the TU Wien Publication Database (http://publik.tuwien.ac.at), e.g. removing the source information or condensing the result presentation.
1 answer

Chikenfoot basic functions

Install Chickenfoot
Chickenfoot's user interface is a Firefox sidebar. Use View >> Sidebar >> Chickenfoot (or press F8) to make it appear.

Script Editor: Type Javascript or Chickenfoot code here and press Run to run it.

Output: View the result of the last script you ran. Use the output() command to display messages here from anywhere in your script.

Patterns: Enter keyword patterns here to see what they match on the web page.

Triggers: Install Chickenfoot scripts so that they run any time you visit a certain web page.

Solution for part 1: Write a simple query script that goes to any kind of search engine except Google, type in a keyword and click the submit button with your script.

go('http://www.yahoo.com/');
enter('search the web', 'Lady gala');
click('web search');

Solution for part 2: Write a script that highlights some fixed keywords in bold face, and define a trigger on which pages this should be used.


var a = new Array();
a[0]="phone";
a[1]="iphone";
a[2]="network";
for (var i=0; i<=a.length-1; i++)
{
var b = document.body.innerHTML;
var g = "/"+a[i]+"/gi";
b = b.replace (eval(g), ""+a[i]+"");
document.body.innerHTML =b ;
}

Solution for part 3: Write a Chickenfoot script that generates a different formatting of the results of a search in the TU Wien Publication Database (http://publik.tuwien.ac.at), e.g. removing the source information or condensing the result presentation.


with(openTab('http://publik.tuwien.ac.at/start.php?lang=2', true))
{
  enter('web data')
click('Search button')
for each (word in find('Quelle'))
{ remove(word) }
}