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 | |
if (isset($_COOKIE['one'])) { | |
$new_one = $_COOKIE['one'] += 1; | |
$new_two = $_COOKIE['two'] += 1; | |
setcookie('one', $new_one); | |
setcookie('two', $new_two); | |
$response = "One says " . $new_one . " but Two says ". $new_two; | |
} else { | |
setcookie('one', 1); |
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/python | |
import sys | |
from chatterbotapi import ChatterBotFactory, ChatterBotType | |
factory = ChatterBotFactory() | |
bot1 = factory.create(ChatterBotType.CLEVERBOT) | |
bot1session = bot1.create_session() |
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 | |
$headers = array( | |
"X-Language: en-US", | |
"X-Service: FullAuto", | |
"X-Reference: voicecloud-reference-123", | |
"Content-Type: audio/wav", | |
"Content-Transfer-Encoding: base64", | |
"Content-Length: " . filesize("test2.64.wav") | |
); |
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
// models/User.php | |
/** | |
* Check if the user used the domain prefix | |
* to login. If they did pass param through | |
* unchanged. If they didn't, prepend it and | |
* return it. | |
* @param string $username | |
* @return string | |
*/ |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<methodResponse> | |
<params> | |
<param> | |
<value> | |
<struct> | |
<member> | |
<name>LastUpdatedBy</name> | |
<value> | |
<i4>-1</i4> |
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 | |
header('Content-type: image/gif'); | |
echo base64_decode("R0lGODlhAQABAIAAAP///wAAACH5BAUUAAAALAAAAAABAAEAAAICRAEAOw=="); | |
?> |
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
[root@ip-10-40-206-29 log]# /opt/bigcouch/bin/bigcouch | |
{error_logger,{{2012,3,6},{21,32,8}},"Protocol: ~p: register error: ~p~n",["inet_tcp",{{badmatch,{error,duplicate_name}},[{inet_tcp_dist,listen,1},{net_kernel,start_protos,4},{net_kernel,start_protos,3},{net_kernel,init_node,2},{net_kernel,init,1},{gen_server,init_it,6},{proc_lib,init_p_do_apply,3}]}]} | |
{error_logger,{{2012,3,6},{21,32,8}},crash_report,[[{initial_call,{net_kernel,init,['Argument__1']}},{pid,<0.21.0>},{registered_name,[]},{error_info,{exit,{error,badarg},[{gen_server,init_it,6},{proc_lib,init_p_do_apply,3}]}},{ancestors,[net_sup,kernel_sup,<0.10.0>]},{messages,[]},{links,[#Port<0.120>,<0.18.0>]},{dictionary,[{longnames,true}]},{trap_exit,true},{status,running},{heap_size,610},{stack_size,24},{reductions,486}],[]]} | |
{error_logger,{{2012,3,6},{21,32,8}},supervisor_report,[{supervisor,{local,net_sup}},{errorContext,start_error},{reason,{'EXIT',nodistribution}},{offender,[{pid,undefined},{name,net_kernel},{mfargs,{net_kernel,start_link,[[bigcou |
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 A { | |
protected static function doStuff() { | |
return "Hello "; | |
} | |
} | |
class B extends A { | |
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 | |
/** | |
* What will the following code output? (No cheating!) | |
*/ | |
class Test { | |
private $a; | |
private $b; | |
public function getFunction() |
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
{ | |
"service": { | |
"name": "consul", | |
"tags": ["server"] | |
} | |
} |