From b29435ac027d4162583726ca6043450461301a40 Mon Sep 17 00:00:00 2001 From: "Pierre Habouzit (MadCoder" Date: Tue, 11 Jan 2005 15:18:09 +0000 Subject: [PATCH] XOrgPage::gassign This is sooooo useful : instead of : $page->assign('foo', $foo); you can now use : $page->gassign('foo'); beware of the fact that it cannot work in a function since it uses the global mechanism. it still saves from a lot of pain in the plain .php top level git-archimport-id: opensource@polytechnique.org--2005/platal--mainline--0.9--patch-288 --- include/xorg/page.inc.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/xorg/page.inc.php b/include/xorg/page.inc.php index f8dcd06..5b77edf 100644 --- a/include/xorg/page.inc.php +++ b/include/xorg/page.inc.php @@ -209,6 +209,15 @@ class XorgPage extends DiogenesCorePage } // }}} + // {{{ function gassign + + function gassign($varname) + { + global $$varname; + $this->assign($varname, $$varname); + } + + // }}} } // }}} -- 2.1.4