revised jq fn init and tweaked html demo