Welcome To Snipplr


Everyone's Recent Snippets



1 ... 428 429 430 431 432 ... 553
Instead of one element you can insert multiple at once: array($element1, $element2, $element3)
1 1745 posted 16 years ago by kurokikaze
6 1396 posted 16 years ago by joeydi
you have to collect the filenames from 'find' in an input file then open the input in this script
0 1381 posted 16 years ago by rowntreerob
Convert hexidecimal color codes (ie #C0C0C0) to decimal RGB (ie 255,255,255)
0 1638 posted 16 years ago by blackf0rk
If you have a component being bound from an ObjectDataSource (like a drop-down menu, or a grid view) and you wish to change the value's SelectParameters. Where # is which SelectParameter you'd like to change. If there's just one SelectParamter, defau...
0 1335 posted 16 years ago by blackf0rk
Dynamically change the content of meta tags from the code behind. This allows you to feed the meta tags with content from a database or other dynamic content.
0 1430 posted 16 years ago by blackf0rk
2 6093 posted 16 years ago by blackf0rk
Sometimes you want to return a bunch of data from a table, but you want it coming back in a random order. Maybe it's for keeping some content on a home page fresh. Here's how:
0 1252 posted 16 years ago by blackf0rk
If you're going to be using a common function throughout the Web site, you can include the function in your MasterPage and gain access to it from each aspx that inherits from this MasterPage; like so:
0 1873 posted 16 years ago by blackf0rk
Validating a decimal such as a measurement of time or currency (10.5 or 0.4). This function will return the correct number. If you feed in "10.5foo" the function will spit back 10.5. If you feed in "bar" the function will return nothing.
0 1252 posted 16 years ago by blackf0rk
Assuming your DataSet (named, ds) is already populated with Data and contains only one table.
0 2076 posted 16 years ago by blackf0rk
It's important that the newPn var that you pass into the Convert.ToInt64 function is in the xxxxxxxxxx format and that no characters are present.
1 2282 posted 16 years ago by blackf0rk
Passing in a seed and your string will return an encrypted string. Pass in the same seed and the encrypted string again and it will return the original unencrypted string.
1 1792 posted 16 years ago by blackf0rk
If you need to get the HTML from a Web page to rip it, process it, and/or display it in the way you want, the following function will work for you.
0 1748 posted 16 years ago by blackf0rk
This function will parse out the Google Maps coordinates from a Google Maps link url like this one: http://maps.google.com/?ie=UTF8&ll=43.068888,-87.978516&spn=23.565589,33.925781&t=h&z=5. The coordinates in this URL are 43.068888,-87.978516.
0 2344 posted 16 years ago by blackf0rk
0 1298 posted 16 years ago by smoover
Connects to a web page, reads in the content and strips whitespace.
2 1719 posted 16 years ago by gdvickery
A nice example of utilizing Groovy closures in order to create a when statement in Groovy (http://www.transentia.com.au/flatpress/?x=entry:entry090311-222726).
0 1657 posted 16 years ago by narkisr
1 1228 posted 16 years ago by muhammet
Adding a namespace to an event can make it easier to unbind. It is very easy to unbind all events with the same namespace.
1 1517 posted 16 years ago by 1man
Never used the index() method in jQuery but could be useful to know. Find a selected elements index when you click on it. Note the $('ul#mylist') inside the index method, gives the search some context of where to look for .selected, saves looking thr...
1 1504 posted 16 years ago by 1man
jquery ui/tabs initiation ensures screenreaders can focus content when selecting tabs. Tested using Jaws 8.
3 1209 posted 16 years ago by terrencewood
0 1256 posted 16 years ago by timstepp
Just add this in script tags in your Affiliate Center footer:
0 1113 posted 16 years ago by kickjoel
1 ... 428 429 430 431 432 ... 553