This file contains hidden or 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
if($("#some_element").is(":visible")) | |
{ | |
// element is visible | |
} |
This file contains hidden or 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 log(message) | |
{ | |
try { | |
console.log(message); | |
} catch(e) { | |
// do nothing | |
} | |
} |
This file contains hidden or 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
// put this in application/config/routes.php | |
$route['default_controller'] = "welcome"; | |
$route['scaffolding_trigger'] = ""; | |
$controllers = glob(APPPATH."controllers/*.php"); | |
$route_string = ""; | |
foreach($controllers as $controller) { | |
$controller = str_replace("../system/application/controllers/", "", $controller); | |
$controller = str_replace(".php", "", $controller); | |
This file contains hidden or 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
puts "Hello World" |
This file contains hidden or 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 | |
def hello(name) | |
puts "Hello #{name}" | |
end | |
hello("Joel") |
This file contains hidden or 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 hello($name) | |
{ | |
echo "Hello $name"; | |
} |
This file contains hidden or 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 | |
def hello_loop(names) | |
names.each do |name| | |
puts "Hello #{name}" | |
end | |
end | |
hello_loop(["Gafitescu", "D_Roch", "Steven Ng", "n0x13", "hosheng", "Pratik Desal", "r kumar", "Ashley Moran", "persiancoffee", "Andre Fischer"]) |
This file contains hidden or 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 href="http://bufferapp.com/add" class="buffer-add-button" data-text="<?php the_title(); ?>" data-url="<?php the_permalink(); ?>" data-via="(Your Twitter username, without @)" data-count="horizontal">Buffer</a><script type="text/javascript" src="http://static.bufferapp.com/js/button.js"></script> |
This file contains hidden or 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
<script type="text/javascript" src="http://static.bufferapp.com/js/button.v2.js"></script> | |
<a data-url="(URL to shorten)" data-text="(the tweet text)" data-no-replace="true" data-source="refynr">Add to Buffer</a> |
OlderNewer