hello Donkeybob,

many thanks for your reply.

I just use standard AJAX call a php and render xmlHttp.responseText
( return from php ) result back to the page. AJAX approach work fine
without jquery inside any  normal page loading.

also, i tested include a JS alert() inside a AJAX loaded page, it
seems didnt trigger that JS at all...I thought it just normal load a
page and then run those JS inside that page, but no luck..:(

function display_nickpage_tab_content(uid,pid,tab_id,tab_page){

        xmlHttp = GetXmlHttpObject()

        if(xmlHttp == null){
                alert ("Your browser does not support AJAX!");
                return;
          }

        xmlHttp.onreadystatechange = function(){

        var loader_menu = document.getElementById
('x_nickpage_tab_loading_'+pid);
                if (xmlHttp.readyState == 4){
                        var res = xmlHttp.responseText;
                        loader_menu.innerHTML = res;

                } else {
                        loader_menu.innerHTML = '<img 
src="./templates/current-version/
images/page-loading.gif" style="margin:5px;" alt="loading" />';
                }

        }

        var url = "ajax-display-nickpage-tab-content.php";
        var params = "uid="+uid
                        +"&pid="+pid
                        +"&tab_id="+tab_id
                        +"&tab_page="+tab_page
                        + "";

        xmlHttp.open("POST",url,true);
        xmlHttp.setRequestHeader("Content-type", "application/x-www-form-
urlencoded");
        xmlHttp.setRequestHeader("Content-length", params.length);
        xmlHttp.setRequestHeader("Connection", "close");
        xmlHttp.send(params);

}

many thanks for your help./Davis.

Reply via email to