This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
error_reporting(E_ALL); | |
define('PHPT_ACL_READ', 1 << 1); | |
define('PHPT_ACL_WRITE', 1 << 2); | |
define('PHPT_ACL_EXEC', 1 << 3); | |
define('PHPT_ACL_NONE', 1 << 4); | |
define('PHPT_ACL_FULL', 1 << 5); | |
define('PHPT_ACL_GRANT', 1); | |
define('PHPT_ACL_DENY', 2); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env php | |
<?php | |
/* | |
+----------------------------------------------------------------------+ | |
| PHP Version 5 | | |
+----------------------------------------------------------------------+ | |
| Copyright (c) 1997-2010 The PHP Group | | |
+----------------------------------------------------------------------+ | |
| This source file is subject to version 3.01 of the PHP license, | | |
| that is bundled with this package in the file LICENSE, and is | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* {{{ proto array http_parse_query(string encoded_string) | |
parses query string into array */ | |
PHP_FUNCTION(http_parse_query) | |
{ | |
char *arg; | |
int arglen; | |
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &arg, &arglen) == FAILURE) { | |
return; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// $Id$ | |
// vim:ft=javascript | |
ARG_WITH("libxml", "LibXML support", "yes"); | |
ARG_WITH("libxmlshared", "LibXML support", "no"); | |
if (PHP_LIBXMLSHARED == "yes") { | |
PHP_LIBXML = PHP_LIBXMLSHARED; | |
PHP_LIBXML_SHARED = PHP_LIBXMLSHARED_SHARED; | |
if (CHECK_LIB("libxml2.lib", "libxml") && |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
use G\Enum as Enum; | |
<?php | |
class Fruit extends Enum { | |
const Apple = 1; | |
const Pear = 2; | |
const Banana = 3; | |
} | |
$fruit = new Fruit(Fruit::Apple); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* public function set_image | |
* | |
* sets a background image for the splash screen | |
* | |
* @param string $image absolute path to splash background | |
* @return void | |
*/ | |
public function set_image($image) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Test { | |
public function foo() { | |
echo 'I am happy and called'; | |
} | |
} | |
$test = new Test(); | |
$test->foo = function() { echo 'dynamic'; }; |
NewerOlder