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
$('input[placeholder]').each(function(){ | |
$(this).focus(function(){ | |
if ($(this).val()==$(this).attr('placeholder')) $(this).val(''); | |
}).blur(function(){ | |
if ($(this).val()=='') $(this).val($(this).attr('placeholder')); | |
}); | |
}); | |
Or, using modernizer: |
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
$('.hitarea-container').each(function(){ | |
$(this).click(function(){ | |
$target = $(this).find('a.hitarea-source').first().attr('href'); | |
if ($target) window.location.href = $target; | |
}); | |
}); | |
// Relies on container to become 'clickable' having a class | |
// of 'hitarea-container' and the link that should be the | |
// target needs to be the href of the first link within that |
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 | |
$context = stream_context_create(array( | |
'http' => array( | |
'header' => "Authorization: Basic " . base64_encode("$username:$password") | |
) | |
)); | |
$data = file_get_contents($url, false, $context); |
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
<!DOCTYPE html> | |
<!doctype HTML> | |
<html> | |
<head prefix="og: http://ogp.me/ns# fb: http://ogp.me/ns/fb# blog: http://ogp.me/ns/blog#"> | |
<meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS"> | |