Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:87292 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 30202 invoked from network); 25 Jul 2015 17:42:16 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 25 Jul 2015 17:42:16 -0000 Authentication-Results: pb1.pair.com header.from=scott@paragonie.com; sender-id=unknown Authentication-Results: pb1.pair.com smtp.mail=scott@paragonie.com; spf=permerror; sender-id=unknown Received-SPF: error (pb1.pair.com: domain paragonie.com from 209.85.220.171 cause and error) X-PHP-List-Original-Sender: scott@paragonie.com X-Host-Fingerprint: 209.85.220.171 mail-qk0-f171.google.com Received: from [209.85.220.171] ([209.85.220.171:35105] helo=mail-qk0-f171.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 9F/00-28932-67AC3B55 for ; Sat, 25 Jul 2015 13:42:15 -0400 Received: by qkbm65 with SMTP id m65so27458022qkb.2 for ; Sat, 25 Jul 2015 10:42:12 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=MBi0nEnTadEpIPOznPL0aOEJJxSH0zPxXe52SmgLQ8Q=; b=RoBHbD/3dg/yfXR76fVg8jhiJCgKn+8PkRgYgyZClchim5za2c8oQVZbNm3i4jh3W2 TQMUgxmJKHfealIYhY2cofDyxNr4gOpu8JUOiSaFHv79QkRexLSoR9pM2TKg2NKnTXLC 7wmxLlLXI02vUtPbM/uZlB8GXhmV/XMnk7UAzUw2ZGL4iyxlciOgIOm8qa/NCh8LtZiX Iix5WMmlHl3BfNSRIKRw1V6a8kMHOd+8RGjgABjfMCJTEtHORCrGNiisR6htKJ6YZqA3 TGitCOtvmxKjCY/NIm/wCMHqtcwhZxMkfNhqkuRy/N046Fm+vjySi3zXjS+/QZrnEix4 Jyjg== X-Gm-Message-State: ALoCoQk7puBJUP5DrV6aITz81Ts4tdjFw/nASZzg+D/IvwSdymm5kUkRTU0lKQ/NPr0g6jxIsBRE MIME-Version: 1.0 X-Received: by 10.55.41.84 with SMTP id p81mr29634647qkh.95.1437846132074; Sat, 25 Jul 2015 10:42:12 -0700 (PDT) Received: by 10.96.83.102 with HTTP; Sat, 25 Jul 2015 10:42:11 -0700 (PDT) In-Reply-To: <55B3991A.4060107@birkholz.biz> References: <55AF84C1.8070403@fedoraproject.org> <55B3991A.4060107@birkholz.biz> Date: Sat, 25 Jul 2015 13:42:11 -0400 Message-ID: To: Dennis Birkholz Cc: PHP Internals Content-Type: text/plain; charset=UTF-8 Subject: Re: [PHP-DEV] RFE to allow dirname($foo, 2) From: scott@paragonie.com (Scott Arciszewski) On Sat, Jul 25, 2015 at 10:11 AM, Dennis Birkholz wrote: > Hi, > > Am 23.07.2015 um 11:54 schrieb Josh Di Fabio: >> Now, most often, dirname(... dirname(__DIR__) ...) is used in application entry >> points during the bootstrapping process. In my experience, it's most commonly >> used in order to include an autoloader or some bootstrap file which itself is >> responsible for including the autoloader. > > doesn't work __DIR__.'/../../' on Windows also? Why do you need > dirname() here? > > Greets > Dennis > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > What's easier to read and less likely to result in bugs? require_once __DIR__ . '/../../../../autoload.php'; or require_once dirname(__FILE__, 5) . '/autoload.php'; Scott Arciszewski Chief Development Officer Paragon Initiative Enterprises