|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #62647 Example not working
Submitted: 2012-07-24 06:15 UTC Modified: 2017-10-24 07:59 UTC
Avg. Score:3.0 ± 0.0
Reproduced:0 of 0 (0.0%)
From: deep at coollider dot com Assigned:
Status: Open Package: yaf (PECL)
PHP Version: 5.3.15 OS: Debian 6
Private report: No CVE-ID: None
Have you experienced this issue?
Rate the importance of this bug to you:

 [2012-07-24 06:15 UTC] deep at coollider dot com
Yaf example not working. I am testing default controler.

My PHP: 5.3.3-7+squeeze13 with Suhosin-Patch (cli) (built: Jun 10 2012 09:35:18) 
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
    with Xdebug v2.1.2, Copyright (c) 2002-2011, by Derick Rethans
    with Suhosin v0.9.32.1, Copyright (c) 2007-2010, by SektionEins GmbH

Test script:
class IndexController extends Yaf_Controller_Abstract {
   /* default action */
   public function indexAction() {
       $this->view->word = "hello world";

Expected result:
        <title>Hello World</title>
    <body>hello world</body>

Actual result:
PHP Notice:  Undefined variable: word in /var/www/localhost/re27/app/application/views/index/index.phtml on line 6
PHP Stack trace:
PHP   1. {main}() /var/www/localhost/re27/app/index.php:0
PHP   2. Yaf_Application->run() /var/www/localhost/re27/app/index.php:9
PHP   3. Yaf_View_Simple->render() /var/www/localhost/re27/app/index.php:0

        <title>Hello World</title>


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2012-07-26 14:44 UTC] rhofmeyr at gmail dot com
Can you post your view script?

You need to echo out $this->word in index.phtml.
 [2012-07-26 15:12 UTC]
thanks , it's my fault :)
 [2012-07-29 09:30 UTC]
-Assigned To: +Assigned To: laruence
 [2017-10-24 07:59 UTC]
-Status: Assigned +Status: Open -Assigned To: laruence +Assigned To:
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Thu Aug 05 00:01:23 2021 UTC