Once an element is under our beck and call, we can send it somewhere else on the page.
In our HTML sketch, we are pretending to vote for the greater of two, very influential people. Each influence is represented by an element on the page with a unique ID attribute. Moving elements around when we know their unique ID attribute value is simple with the MooTool infused Element::inject()
method.
<script type="text/javascript" src="mootools-1.3.0.js"></script> </head> <body> <form action="javascript:" method="get"> Choose the greatest influence of the Internet:<br/> <select id="influence"> <option value="">Vote Now:</option> <option value="bill">Bill</option> <option value="linus">Linus</option> </select> <input type="button" value="..."/> </form> <img id="bill" src="bill_gates.bmp" alt="Bill"/> <img id="linus" src="linus_torvalds.bmp...