0

I've been facing a strange problem.

I've an application based on zend framework and i need to load this application using IFrame from another domain. While loading i need to pass a value from IFrame to the application based on Zend Framework. I tried it the following way but it's not working. It's giving Page Not Found Exception.

  1. Created _initRouting() method at bootstrap
  2. Integrated the application using IFrame

_initRouting()

public function _initRouting()
{
    $router = Zend_Controller_Front::getInstance()->getRouter();
    $router->addRoute(
            'deal',
            new Zend_Controller_Router_Route('/deal/:q', array(
                'module' => 'default',
                'controller' => 'index',
                'action' => 'index'
            ))
    );
}

IFrame Integration

<iframe src="http://www.example.com/deal/123" width="1022px" height="710px"></iframe>

Default Module->Index Controller->Index Action

public function indexAction()
{
    echo $this->_request->getParam('q');
}

Cant figure out the problem. Your help would be greatly appreciated.

Anindya
  • 61
  • 1
  • 1
  • 5
  • Explain more how this is specific to the iFrame. Does the route work directly in the address bar of the browser? – ficuscr Mar 29 '13 at 15:50
  • Suppose we have 2 domains. one is www.example1.com, another www.example2.com. Domain 1 ZF based application. I would like view domain1 into domain 2 using IFrame and integrating domain1 into domain 2, i would like to pass value from domain 2 to domain 1. That's the requirement. Yes, the route is working in the address bar of the browser at localhost but at test server it's not working. – Anindya Apr 01 '13 at 11:07

0 Answers0