Changes

Jump to: navigation, search

Learning Collaborative Development Lab Fall 2008 Results

935 bytes added, 20:41, 12 September 2008
no edit summary
}
})
</pre>
<br />
---
---
====Sherdog Fight Finder Search====
[[User:bbarcick]]
This command allows a user to search the Sherdog Fight Finder for a specific fighter. Currently only allows the first word to be the fighters first name and the second word to be the fighters last name.
<br />
<pre>
CmdUtils.CreateCommand({
name: "fight-finder",
author: {name:"Bartosz Barcicki", email:"bartb_69@hotmail.com"},
description: "Searches the Sherdog Fight Finder",
takes: {"search-string": noun_arb_text},
preview: function(pblock, search) {
pblock.innerHTML = "Sherdog Fight Finder Search: " + search.text;
},
execute: function(search) {
var name = search.text.split(' ');
if (name[1] = "undefined")
{
name[1] = "";
}
var url = "http://sherdog.com/fightfinder.php?firstname=" + name[0] + "&lastname=" + name[1] + "&search=yes&nickname=&association=&weight=";
Utils.openUrlInBrowser(url);
}
})
 
</pre>
<br />
---
1
edit

Navigation menu