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 Windwalker\Uri\Uri; | |
/** | |
* The AsyncRequest class. | |
* | |
* @since {DEPLOY_VERSION} | |
*/ | |
class AsyncRequest | |
{ | |
/** |
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
function AjaxHelper() { | |
this.ajax = function(url, type, dataType, data, callback) { | |
$.ajax({ | |
url: url, | |
type: type, | |
dataType: dataType, | |
data: data, | |
success: callback, | |
error: function(xhr, errorType, error) { | |
alert('Ajax request error, errorType: ' + errorType + ', error: ' + error) |
This is a set up for projects which want to check in only their source files, but have their gh-pages branch automatically updated with some compiled output every time they push.
You want a script that does a local compile to e.g. an out/
directory. Let's call this compile.sh
for our purposes, but for your project it might be npm build
or gulp make-docs
or anything similar.
The out/
directory should contain everything you want deployed to gh-pages
. That almost always includes an index.html
.
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 ruby | |
# encoding: UTF-8 | |
@dot_cycle = ['⣾','⣽','⣻','⢿','⡿','⣟','⣯','⣷'] | |
#braille random: 0x2800 - 0x28ff | |
@z_arrow = ['←','↖','↑','↗','→','↘','↓','↙'] | |
@z_b = ['b','ᓂ','q','ᓄ'] | |
@z_d = ['d','ᓇ','p','ᓀ'] |
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 | |
/** | |
* Part of ihealth project. | |
* | |
* @copyright Copyright (C) 2011 - 2014 SMS Taiwan, Inc. All rights reserved. | |
* @license GNU General Public License version 2 or later; see LICENSE | |
*/ | |
use Windwalker\Data\Data; |
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 | |
ini_set('display_errors', true); error_reporting(-1); // <- for debugging purposes only | |
$socket=socket_create(AF_INET, SOCK_RAW, SOL_TCP); | |
if ( !$socket ) { | |
$errno = socket_last_error(); | |
$error = sprintf('%s (%d)', socket_strerror($errno), $errno); | |
trigger_error($error, E_USER_ERROR); | |
} |
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 | |
include("./php-AES.php"); | |
$z = "abcdefgh01234567"; // 128-bit key | |
//$z = "abcdefghijkl012345678901"; // 192-bit key | |
//$z = "abcdefghijuklmno0123456789012345"; // 256-bit key | |
$aes = new AES($z); | |
$data = file_get_contents("./example.txt"); |
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 | |
// components/com_flower/model/sakura.php | |
// Model | |
class FlowerModelSakura extends \Windwalker\Model\CrudModel | |
{ | |
// CrudModel will auto getForm() | |
} | |
// Then add components/com_flower/model/form/sakura.xml |