Page = Class.create(); Page.prototype={ browser:null, templateDiv:null, templateHtml:'', FCK:null, initialize:function( FCKEditor){ this.FCK = FCKEditor; this.templateDiv = $('templateDiv'); }, pull_Template:function(templateId){ var p = 'templateId='+templateId; var callB = new Ajax.Request('./callBack/ajax.action',{method:'get', params:p ,onSuccess: this.fill_template.bind(this)}); }, fill_template:function( cb ){ this.templateDiv.style.display = 'none'; this.templateHtml = cb.responseText; this.templateDiv.innerHTML = this.FCK.Create(); this.FCK.setHTML(this.templateHtml); Effect.SlideDown(this.templateDiv); } };