By Jeffrey Cobb on March 31, 2009
We have all see them and some of us love them. It’s those elements that seem to float on the page like hovering little angels. Ok enough with the sappy crap…down to business. So you need to create a browser independent simple script to position an element on a page. I put together a simple [...]
Posted in YUI Loader, YUI Mish Mash, YUI Util DOM
| Tagged createElement, Get, getPreviousSibling(), getViewPortHeight(), getViewPortWidth(), inDocument(), insertAfter, setStyle(), window.resize, YAHOO.Dom.Event, YAHOO.util.Event.addListner, YUI Event
By Jeffrey Cobb on March 9, 2009
An example of how to create elements in javascript then attach/append them to other elements using YUI.
Posted in YUI Util DOM
| Tagged createElement, generateID, getElementsByClassName, getLastChild, insertAfter, YAHOO.Util.Dom
By Jeffrey Cobb on March 8, 2009
At times it becomes necessary to add up the data with in a column. Here is a nice little snippet that can do just that.
Change DATATABLE with the name of the data table you need to read.
Change COLUMNNAME with the column key in the table you need to read.
// First get the record set from the [...]
Posted in YUI Datatable
By Jeffrey Cobb on March 8, 2009
You know and I know and everyone knows the alert boxes generated by the browsers are OLD-SCHOOL and look like garbage. Well using YUI you can easily change that by just including a little code in you page. Simply add the code below to the bottom of your page just before the end body tag [...]
Posted in Dialog, YUI Animation, YUI Container, YUI Get, YUI Loader, YUI Mish Mash
| Tagged Container, Dialog, Panel, Simple Dialog, window.alert
By Jeffrey Cobb on March 3, 2009
Using the YUI Loader and the script below will allow you to implement the YUI framework within your application with out downloading and installing the YUI framework to your server.
var loader = new YAHOO.util.YUILoader({
require: ["get","dom","event"],
loadOptional: true,
onSuccess: function() {
YAHOO.util.Event.onDOMReady(init);
[...]
Posted in YUI Loader, YUI Mish Mash
| Tagged Event, FireBug, Get, HTML DOM, init(), javascript, onDomReady, Rollup, Yahoo User Interface, YUI Framework, YUI Loader