Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:59510 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 9653 invoked from network); 9 Apr 2012 15:53:13 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 9 Apr 2012 15:53:13 -0000 Authentication-Results: pb1.pair.com smtp.mail=nikita.ppv@googlemail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=nikita.ppv@googlemail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain googlemail.com designates 209.85.215.42 as permitted sender) X-PHP-List-Original-Sender: nikita.ppv@googlemail.com X-Host-Fingerprint: 209.85.215.42 mail-lpp01m010-f42.google.com Received: from [209.85.215.42] ([209.85.215.42:33940] helo=mail-lpp01m010-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DE/BA-56433-8E5038F4 for ; Mon, 09 Apr 2012 11:53:13 -0400 Received: by lahl5 with SMTP id l5so3675442lah.29 for ; Mon, 09 Apr 2012 08:53:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=mjkT8P1YK5kqTG7Wd01YB7mR/AbFKY48eHZZrOB9jho=; b=DbtnkPZAyElJALYCSLceDbM0KP7DZEVLoi2sWJUUfuvMgIgWPNI1NqXyUI023oB4ho fLj3VFgw617hrwogIkn4+Wr0zD7jc16cqQjpUUYHUbWQ85XtwMRJfmGuK9Tsm0SGbLK0 LZHFHsYrl2yjoa6ys6vKbouLmNY7/DT4k6C6EHUHSrqypg7hXgk5Yqe46p+eZYwgAkQX v0kGtCJb2IJ8r2WGnysTl9pbZouWjrLu8f/zvNb3fV6GH4tEIusXVzMLmoNRBXoC31vy HymQngFf5pJoFHXXf4IZ3dREPKe9V6qjG8zyCXJ6SIq8yzxTE45Ub84peph8321ACOOc Zusg== MIME-Version: 1.0 Received: by 10.152.131.9 with SMTP id oi9mr12134700lab.6.1333986789994; Mon, 09 Apr 2012 08:53:09 -0700 (PDT) Received: by 10.152.127.68 with HTTP; Mon, 9 Apr 2012 08:53:09 -0700 (PDT) In-Reply-To: References: Date: Mon, 9 Apr 2012 17:53:09 +0200 Message-ID: To: Tom Boutell Cc: PHP Internals Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [PHP-DEV] Object oriented page templates in PHP From: nikita.ppv@googlemail.com (Nikita Popov) On Mon, Apr 9, 2012 at 5:10 PM, Tom Boutell wrote: > What if PHP supported a short tag for calling a method of $this? > > Then one could write: > > A big -1 on this. If you want to roll your own template syntax, just do so. It's not that hard to run a quick str_replace('', $code) over the template. Especially consider that @ is already used for error suppression, so code that previously just wanted to suppress some errors will suddenly try to call class methods (which obviously will lead to fatal errors). Nikita