You can find out what each function does
here
If you don't trust the code (or your friend), then just don't use it.
*edit*
The key function is
GetCursorInfo(), it's second return is the itemid. Itemid's are used by Wowhead (and the other sites) in their URLs, take a clase look at this URL:
http://www.wowhead.com/?item=6265