Quantcast
Channel: Forums, Blogs, Wikis » Coding
Browsing latest articles
Browse All 10 View Live

Why blocking right-clicks is a waste of time

There's another forum I'm on where the discussion of blocking right-clicks comes up every few days it seems.  People put up their first website and are terrified when they find out how easy it is to...

View Article



Bookmarking threads on an SMF board

This is one of those features I've been wanting to add to my photography forum for a while now, but I just got around to it this weekend. With the addition of a database table, a new template file, a...

View Article

JavaScript progress bar indicator

Need a way to show the progress on a long process on your web page? Here's a quick little JavaScript routine that will do it for you. The trick is to create a fixed size div with the background image...

View Article

WordPress: Get custom field function

On several WordPress projects I've needed to get the value of a custom field.  Not too difficult using the get_post_meta command, but I wanted a little quicker way.  So I now add this little function...

View Article

isDivisible function for PHP

A quick function to check if a number is divisible by another. PLAIN TEXT PHP: function isDivisible($number, $divisibleBy)     {     if ($number % $divisibleBy == 0)         return true;     return...

View Article


Editing a page from FireFox

Found a quick little JavaScript trick that lets you edit page content from within FireFox. Copy and paste the following into your address bar and press enter....

View Article

Prototype returning status code 0 in Opera

Seems like browsers don't handle Ajax calls returning a 204 no content status code very well. I've had issues with IE7 gets a 1223 status code instead of the 204. Well, it looks like Opera, at least...

View Article

How to add a timer to Eventum

I've been using Eventum for a while to keep track of bugs in a web application of mine. There was one feature missing that I really needed, and which made me switch to dotProject for a few months and...

View Article


nextSaturday and lastSunday functions for PHP

I needed a way to find the first second of a week and the last second of a week based on a Unix timestamp. Credit for the previous Sunday goes to Shaun who posted a way to find it on the PHP site for...

View Article


PHP – Return first n words from a string

Do you ever find yourself needing to shorten a string in PHP? Maybe return the first 25 words of a long story? Give this routine a try. It will return the first n words from a string, or the entire...

View Article
Browsing latest articles
Browse All 10 View Live




Latest Images