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
Include "/usr/local/zend/etc/sites.d/http/__default__/0/*.conf" | |
<Directory "/usr/local/zend/var/apps/http/__default__/0/"> | |
Allow From All | |
</Directory> |
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
Include "/usr/local/zend/etc/sites.d/http/__default__/0/*.conf" | |
<Directory "/usr/local/zend/var/apps/http/__default__/0/"> | |
Allow From All | |
</Directory> |
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 | |
/** | |
* String representation of this object | |
* @return string | |
*/ | |
public function __toString() | |
{ | |
try { | |
return (string) $this->name; |
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
<pre> | |
<?php | |
// Host | |
$host = 'yourhostname.com'; | |
$port = 21; | |
$timeout = 90; | |
// Credentials | |
$username = 'yourusername'; |
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 TestFixfilesController extends Controller | |
{ | |
public function on_before_render() | |
{ | |
$originalsDirectory = '/var/www/your-website.com/missing-files/'; | |
$originalFilenames = scandir($originalsDirectory); |
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
CREATE TABLE `log` ( | |
`id` int(11) unsigned NOT NULL AUTO_INCREMENT, | |
`timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, | |
`priority` tinyint(1) NOT NULL, | |
`priorityName` varchar(5) CHARACTER SET ascii NOT NULL DEFAULT 'DEBUG', | |
`message` varchar(255) NOT NULL, | |
PRIMARY KEY (`id`) | |
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8; |
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 | |
$directories = scandir('/some_directory'); | |
array_shift($dirs); | |
array_shift($dirs); | |
$baseDirectory = '/another_directory'; | |
foreach($directories as $directory) { | |
$filename = current(explode('.', $directory)); |
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 | |
// Headings and rows | |
$headings = array('ID', 'Name', 'Colour'); | |
$array = array( | |
array(1, 'Apple', 'Green'), | |
array(2, 'Banana', 'Yellow'), | |
array(3, 'Orange', 'Orange'), | |
); |
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 | |
/* | |
* "Late Static Binding" namespace | |
*/ | |
$class = get_called_class(); | |
$lastSlashPosition = strrpos($class, '\\'); | |
$namespace = substr($class, 0, $lastSlashPosition); |
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
{ | |
"name": "andrewkirkpatrick/sample", | |
"description": "Sample project", | |
"homepage": "http://www.andrew-kirkpatrick.co.uk", | |
"repositories": [{ | |
"type": "package", | |
"package": { | |
"name": "andrewkirkpatrick/library", | |
"version": "0.1.0", | |
"source": { |
OlderNewer