Hi All, 

I am just started learning ZF and today I tried  simple ajax example with
prototype. On response I am getting whole html chunk of code . Even I use
disabled layout still no success  -- any body suggest why ??:-(
my code 
javascript code - 
function callAjax(s)
{
var myAjax = new Ajax.Request('index/getData',
{method: 'get', parameters: {state: s},
onComplete: handleResponse});
}
function handleResponse(transport)
{
        value =transport.responseText;
        alert(value );
}


Action Controller code
 function getDataAction()
    {
        $this->_helper->layout->disableLayout();
    $this->_helper->viewRenderer->setNoRender(true);
        
        if($this->getRequest()->isXMLHttpRequest())
        {
                $id = $this->_getParam('state');
                if($id == 'do')
                {
                        echo "Hello Ajax";
                }
        }
        }

--rakesh
-- 
View this message in context: 
http://www.nabble.com/ajax-error----returning-whole-html-tp25068453p25068453.html
Sent from the Zend Framework mailing list archive at Nabble.com.

Reply via email to