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
class XMLFeed | |
{ | |
private $xmlHeader = '<products>'; | |
private $xmlFooter = '</products>'; | |
private $xmlFeedFile = 'products.xml'; | |
public function feed() | |
{ | |
$offeset = 0; | |
$perLoop = 1000; |
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
cd /path/to/repo.git | |
chgrp -R groupname . | |
chmod -R g+rwX . | |
find . -type d -exec chmod g+s '{}' + |
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
<table id="employee-grid" cellpadding="0" cellspacing="0" border="0" class="display" width="100%"> | |
<thead> | |
<tr> | |
<th>Employee name</th> | |
<th>Salary</th> | |
<th>Age</th> | |
</tr> | |
</thead> | |
</table> |
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
// Uppercase | |
$('example').Datatable(); | |
// Lowercase | |
$('example').datatable(); |
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 getGAClient() { | |
$result = explode('.', $_COOKIE['_ga'], 3); | |
$count = count($result); | |
if ($count == 3) { | |
list($version, $depth, $clientId) = $result; | |
} else { | |
return false; | |
} | |
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 is_anagram($a, $b) { | |
return(count_chars($a, 1) == count_chars($b, 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
const echoPostRequest = { | |
url: 'https://<my url>.auth0.com/oauth/token', | |
method: 'POST', | |
header: 'Content-Type:application/json', | |
body: { | |
mode: 'application/json', | |
raw: JSON.stringify( | |
{ | |
client_id:'<your client ID>', | |
client_secret:'<your client secret>', |
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
a { | |
display: block; | |
width: 200px; | |
height: 200px; | |
overflow: hidden; | |
margin: 10px; | |
position: relative; | |
border: solid 1px #353535; | |
} |
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 edit($id = NULL){ | |
if(!empty($id)){ | |
// LOAD SESSION DATA | |
$session_data = $this->session->userdata('userLogData'); | |
// LOAD DATA FROM DATABASE | |
$assetObj = $this->assetModel->getAssetRow($id); | |
$categoryList = $this->assetModel->getDataList('category'); |