Using Android 4.2.2 as an example.
- Run the Android SDK Manager.
- Windows:
/SDK Manager.exe
- Windows:
find . -name \* -print0 | perl -MFile::Basename -0nle 'rename $_, dirname($_)."/prefix_".basename($_)' |
var existsInAny = function(needle, propertyName, haystack){ | |
return haystack.map(function(el){return el[propertyName] === needle;}).reduce(function(a,b){return a||b;}); | |
} | |
/* | |
# CoffeeScript version | |
existsInAny = (needle, propertyName, haystack) -> | |
haystack.map((el)-> el[propertyName] is needle).reduce((a,b)-> a||b) | |
*/ |
# thing - {mixed}. Anything you want to get the type of. | |
getType: do => | |
unless @classToType? | |
@classToType = {} | |
for type in ['Boolean', 'Number', 'String', 'Function', 'Array', 'Date', 'RegExp', 'Undefined', 'Null'] | |
@classToType["[object #{type}]"] = type | |
return (thing) => | |
className = Object::toString.call thing | |
return if @classToType[className]? then @classToType[className].toLowerCase() else 'object' |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> |
/(<a[^>]*?>.*?)?(?!<[^>]*?)([a-zA-Z0-9.!\#$%&'*+\/=?^_`{|}~-])+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*(?![^<]*?>)/gi |
alert(JSON.stringify(YOUR_OBJECT_HERE, null, 4));//from: http://stackoverflow.com/a/8611131/727074 |
var e=document.querySelectorAll("*[id*=wrapper], *[class*=wrapper]"),r=["http://www.richincomeways.com/wp-content/uploads/2013/06/tupac.jpg","http://www.2freshbeats.com/wp-content/uploads/2012/05/snoop.jpg","http://cdn.hiphopwired.com/wp-content/uploads/2012/07/10428_The-Notorious-B_I_G_1.jpg"],rl=r.length;for(var i=0;i<e.length;i++){e[i].style.background="transparent url("+r[i%rl]+") center center repeat"};console.log( e.length); |
SELECT * | |
FROM table_name | |
WHERE LENGTH(column_name) != CHAR_LENGTH(column_name); |
/** | |
* Gets the value of a GET argument (URL parameter). Returns undefined if the argument doesn't exist | |
* | |
* @param name string | |
* @returns string|undefined | |
* | |
* @author adam-lynch | |
*/ | |
function _GET( name ){ | |
var regexS = "[\\?&]" + name.replace( /[\[]/, "\\\[" ).replace( /[\]]/, "\\\]" ) + "=([^&#]*)", |