Welcome To Snipplr


Everyone's Recent Snippets



1 ... 545 546 547 548 549 ... 553
It's a simple low pass filter with comparative graphs.
1 2081 posted 19 years ago by yuconner
Performance can be seen in link. This code, however, uses generator expression instead of list comprehension.
1 1837 posted 19 years ago by newtonapple
Find the process id using the dev
1 1663 posted 19 years ago by yuconner
0 2967 posted 19 years ago by leoh
Took 0.164692 seconds for array[] Took 0.395778 seconds for array_push As you can see array_push is more than twice as slow. Here are the reasons. Array_push is a function call, Function calls are always slower. Array_push takes mixed parameters,...
0 5399 posted 19 years ago by mthorn
strcmp with matching strings took 0.207852 seconds strcmp with non-matching strings took 0.215276 seconds === with matching strings took 0.067122 seconds === with non-matching strings took 0.057305 seconds === is the clear winner. Function call...
0 4041 posted 19 years ago by mthorn
Often PHP can't interpret POST data because it is not form-encoded. This is typical when the post data is XML from API's like Flash's XmlSocket. You can use the following methods to read the POST data directly.
1 3063 posted 19 years ago by mthorn
Since PHP is typeless odd things can happen when a variable is not the type you expected. PHP treats 0, null, '0', false, and '' as false. Sometimes you really want to know if the value is false. The solution is simple, use the triple equal (===) ope...
0 1946 posted 19 years ago by mthorn
Will create a thumnail no taller or wider than the supplied size. Also contains some tips for reading and writing images using GD.
22 21839 posted 19 years ago by mthorn
Sends as XHTML 1.1 + MathML if supported, falls back to XHTML 1.1 if supported, or falls back to HTML 4.01 Strict. Mixed two separate scripts: http://www.workingwith.me.uk/articles/scripting/mimetypes http://golem.ph.utexas.edu/~distler/blog/arc...
2 1516 posted 19 years ago by rolandog
Save this snippet via Safari as webarchive and replace an already created signature with this webarchive. Signatures are stored under ~/Library/Mail/Signatures
2 2150 posted 19 years ago by AlexK
Great little debuging snippet found while browsing. The code adds different coloured borders to the assets depending on its level. Leave commented out if not needed.
96 14314 posted 19 years ago by 1man
For bin iso you also need cdemu To convert between formats check: mdf2iso, nrg2iso and ccd2iso
3 3331 posted 19 years ago by yuconner
To make an ISO from your CD/DVD, place the media in your drive but do not mount it. If it automounts, unmount it.
0 1665 posted 19 years ago by yuconner
Note: This doesn't work in multi-threaded environments, check http://en.wikipedia.org/wiki/Singleton_pattern#C.2B.2B Singleton class model then: SingletonClass *pSC = SingletonClass::get_singleton_instance(); pSC->any_public_function(); or: Si...
4 3145 posted 19 years ago by yuconner
3 2854 posted 19 years ago by yuconner
1 2044 posted 19 years ago by yuconner
2 2063 posted 19 years ago by cochambre
Usefull Regular Expressions enhancement. Simplifies standard string operations escaping special chars. And also saves precompiled REs for a speed increase.
1 1732 posted 19 years ago by cochambre
Simple HTTP server daemon (webrick).
1 1696 posted 19 years ago by ishikawa
3 1994 posted 19 years ago by cochambre
guardar como flash.js
0 1843 posted 19 years ago by kanirasta
Para evitar problemas con IE. Hace referencia a un script que pongo en la parte de .js
0 2975 posted 19 years ago by kanirasta
1 ... 545 546 547 548 549 ... 553