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 | |
require_once (dirname(__FILE__)) . '/engine/start.php'; | |
$options = array( | |
'type' => 'object', | |
'subtype' => 'paraleltest', | |
'limit' => 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
<?php | |
/** | |
* Group file module | |
*/ | |
$group = elgg_get_page_owner_entity(); | |
if ($group->file_enable == "no") { | |
return true; | |
} |
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
package org.wamped.playground; | |
import java.io.BufferedReader; | |
import java.io.IOException; | |
import java.io.InputStreamReader; | |
import java.io.UnsupportedEncodingException; | |
import java.net.HttpURLConnection; | |
import java.net.URL; | |
import java.net.URLEncoder; |
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 get_friendly_time($time, $current_time = null) { | |
if (!$current_time) { | |
$current_time = time(); | |
} | |
$diff = abs((int)$current_time - (int)$time); | |
$minute = 60; | |
$hour = $minute * 60; |
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 | |
function isAnagram($string1, $string2) { | |
if (!is_string($string1) || !is_string($string2)) { | |
return false; | |
} | |
$map1 = []; | |
$map2 = []; | |
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 | |
require 'toursxml.php'; | |
function xmlToCSV($text) { | |
$columns = ['Title', 'Code', 'Duration', 'Inclusions', 'MinPrice']; | |
$separator = '|'; | |
$header = implode($separator, $columns); |
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
var myObj = { | |
a: 5, | |
b: function() { | |
console.log(this.a); | |
} | |
}; | |
myObj.b(); // What will be the output of this call? | |
var myRef = myObj.b; |
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
const StringSetBase = require("./string-set-base"); | |
class StringSet extends StringSetBase { | |
constructor() { | |
super(); | |
this.stringSet = new Set(); | |
} | |
/** |
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
abstract class Bunny { | |
String name; | |
void attack(); | |
} | |
class Fluffy extends Bunny { | |
void attack() { | |
print('Licks hands violently'); | |
} | |
} |
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
JsObject dataLayer = context['dataLayer']; | |
dataLayer ??= new JsObject(context['Array']); | |
Map<String, dynamic> productInfo = { | |
'name': '1 month subscription', | |
'price': 21000, | |
'currency': 'HUF' | |
}; | |
dataLayer.callMethod('push', [new JsObject.jsify(productInfo)]); | |
context['dataLayer'] = dataLayer; |
OlderNewer