Welcome To Snipplr
Everyone's Recent Snippets
- All /
- JavaScript /
- HTML /
- PHP /
- CSS /
- Ruby /
- Objective C
A simple one page form with attachment that is meant to go straight to the email and not uploaded to the server. Emails an HTML version, a PlainText version and the attachment if there is one.
4
1265
posted 13 years ago by StevenW721
this will disable a button after the first click, but will continue to do its original postback. Note: if it has a custom css class, then the button will still appear clickable, with the exception that the text of the button gets the slight disabled...
0
983
posted 13 years ago by pjobson
These are just two css media queries you may want to use for your website development. With lots of smart-phones, and tablets being able to orientate their screens from landscape to portrait, you may want to include different styles for each. This is...
1
747
posted 13 years ago by paul66
IE7 by default uses an image resizing algorithm that means that scaled down images can look far from awesome. To solve this, we simply enable a much better resizing algorithm that is available in IE7 that produces results similar to what you’d expe...
0
713
posted 13 years ago by paul66
This snippet basically gives us the best of both worlds, allowing the best usability when it comes to link outlines for both screenreaders tabbing through links, and mouse users.
0
711
posted 13 years ago by paul66
Alignment of labels with their relevant inputs can be a horrible task to achieve in older browsers. This snippets solves that for us by making it consistent across browsers!
0
634
posted 13 years ago by paul66
This snippet simply makes the text wrap when it reaches the walls of its container, in this case, the pre tag, whilst still preserving line breaks and white space cross browser.
0
707
posted 13 years ago by paul66
Sometimes, pages can be shorter than the browser view-port, and when you load a page on the same site that has longer content and uses a scrollbar, content can jump side to side. By forcing a scrollbar no matter the height of our content, we stop thi...
0
743
posted 13 years ago by paul66
To get rid of rendering inconsistencies that can occur between browsers and OS’s when rendering fonts in pixels, this snippet allows you to size your fonts in such a way that the size and line-height will remain consistent across these platforms fo...
0
627
posted 13 years ago by paul66
Plenty of you will have used Eric Meyer’s css reset before now. It is included in many frameworks and so on, like 960.gs. This is a revamped version of that reset, that brings it into the present with full support for html5. It sets all the new str...
1
901
posted 13 years ago by paul66
Google Analytics is a very popular tool for tracking your website’s user behaviour, and visits. This is simply an optimised version of Google’s asynchronous tracking snippet. To learn what has been optimised, and why it is faster than Google’s...
0
693
posted 13 years ago by paul66
A vast majority of sites these days make use of the jQuery JavaScript library. A vast majority also make use of Google’s hosted version of the library for faster loading speed’s, and better cross site caching. However, what if there is ever a pro...
1
676
posted 13 years ago by paul66
Internet Explorer has many rendering engines ready for use. What this line of code basically does is force IE to use the most up to date rendering engine that it has available, so that your pages will render as well as possible. It then goes on to ta...
0
737
posted 13 years ago by paul66
The favicon is pretty much normality these day. the interesting bit here is the apple-touch-icon which is used if you save a bookmark to your home screen on an apple touch device such as an iPad or iPhone. Interestingly enough, android also supports...
3
839
posted 13 years ago by paul66
This help you cutting text without cut the last word. Any feedback appreciated!
0
645
posted 13 years ago by alesma
his code will show the child pages, and only the child pages, when on a parent or on one of the children.
This code will not work if placed after a widget block in the sidebar.
1
843
posted 13 years ago by raz