Profile
Achievement

inreflection7's Recent Snippets
- All /
« Prev 1 Next »
For those moments of weakness when .replace() looks like a good idea...
0
270
posted 8 years ago by inreflection7
It can be useful to take a peek at what Apache is doing but I always forget the location of the Apache logs so I can use tail.
0
194
posted 8 years ago by inreflection7
Extend jQuery :selector types
Ex: $("input:text")
$("input:email")
1
199
posted 8 years ago by inreflection7
Sorts a list by its 'data-' attribute. Customization is very easy.
0
298
posted 9 years ago by inreflection7
Search for a string, if matched replace with second provided paramater. Third parameter is the variable whose value is the string you'd like to search.
0
260
posted 9 years ago by inreflection7
Use PHP to get JSON
1) set the PHP to the URL of the JSON
2) echo a variable with the loaded data
3) use a request via jQuery to get the variable from PHP
0
268
posted 9 years ago by inreflection7
Why do this?
===========
*hopefully* this will cause the page to refresh and provide a stop button in the future. The idea is to use it while developing in a text editor, as in Vim or its ilk, and not have to alt+tab all the _*flipping*_ time.
F...
0
193
posted 9 years ago by inreflection7
image rollovers in jquery are usually super easy. However it sucks when working with absolute image paths - like a separate media server or CDN. Heres a quick snippet using substring and lastIndexOf to swap out the image src.
0
254
posted 9 years ago by inreflection7
Sometimes things look terrible in CMSDesk. With just a few adjustments to the master page and its CS file you can target elements in an admin.css page.
0
135
posted 9 years ago by inreflection7
Wanna lose the time portion of the date something was created in a smart search result!?!?
0
228
posted 9 years ago by inreflection7
IE7 can be a pain when it comes to input submit buttons. In order to get the value to disappear using the text-indent: -999em; trick make sure to set text-transform: capitalize;
0
188
posted 9 years ago by inreflection7
A really fucking cool and easy way to calculate the alpha value for microsoft gradient using Javascript. Particularly useful in the Firebug console. Like a calculator.
0
180
posted 9 years ago by inreflection7
This is just a simple page full of XHTML to follow along with my JS book. A template.
0
219
posted 9 years ago by inreflection7
The usual way to resolve a url file path doesn't work with JWPlayer. You'll need a different one because the "+" in ... ?guid="+ Eval("fieldName"))%> will throw an error...
0
225
posted 9 years ago by inreflection7
You don't modify the CMSDesk in order to display only the date or only the time. You do it through the aspx control.
http://authors.aspalliance.com/aspxtreme/sys/globalization/demos/DateTimeFormatInfoGetAllDateTimePatterns.aspx
0
293
posted 9 years ago by inreflection7
"This was a requirement that the client had because there were differences in how various browsers were displaying the same PDFs. By setting the "Content-Disposition" header to "attachment" it forces the user to download the file. I thought this was...
0
258
posted 9 years ago by inreflection7
When submitting a bizform in Kentico it has some crappy default message. Change them in this file.
0
208
posted 9 years ago by inreflection7
This will get the file path for something. Typically used with a cms:CMSRepeater
0
251
posted 9 years ago by inreflection7
.closest and .find are very useful - surprised I haven't heard of them before.
0
195
posted 9 years ago by inreflection7
ssh localhost -CgL 8080(your computer IP address or name):80
0
265
posted 9 years ago by inreflection7