Showing entries 1 to 9
Displaying posts with tag: jquery (reset)
jQuery and GIS distance in MariaDB

I’ve continued building on my MariaDB GIS and node.js example application that I wrote about two weeks back, The application shows how to load GPX information into MariaDB, using some MariaDB GIS functionality, and making use of the node.js platform together with MariaDB’s non-blocking client.

With the GPX data converted into GIS points in the MariaDB database, I wanted to further expand a little on both the GIS aspect and also look at how some additional data could be shown in the application by using jQuery’s Ajax calls to update a piece of the web based application UI.

To start with, an interesting thing to do when you have a bunch of GIS points in a …

[Read more]
Simple jQuery: how to validate IPv4 addresses and netmasks

Unfortunately jQuery doesn’t come with default form validation to check for ip-addresses or subnet masking. So without a long winded explanation here’s the code. Just include this as a separate JS file like the rest of your page’s JS.

// 'ipv4': IPv4 Address Validator
$.validator.addMethod('ipv4', function(value) {
    var ipv4 = /^[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}$/;    
    return value.match(ipv4);
}, 'Invalid IPv4 address');

// 'netmask': IPv4 Netmask Validator
$.validator.addMethod('netmask', function(value) {
    var mask = /^[1-2]{1}[2,4,5,9]{1}[0,2,4,5,8]{1}\.
    return value.match(mask);
}, 'Invalid IPv4 netmask');

You can use it like this.

        netmask:{ …
[Read more]
Automatically Download MySQL Enterprise Monitor Graphs as PNG Files Using Perl

I was giving a presentation of the MySQL’s Enterprise Monitor* application to a client recently. I was demonstrating the “graphs” section of MEM, where you can monitor MySQL sessions, connections, replication latency and more with 60+ graphs. Usually, you view the graphs from within the MEM Enterprise Dashboard (via a web browser). But the client asked if there was a way to automatically download graphs. I wasn’t sure why he wanted to download the graphs (I didn’t ask), but I knew it wasn’t possible by using MEM alone. However, in the past I have written Perl scripts to automatically download files from web sites, so I thought I would see if it was possible with MEM.

*The MySQL Enterprise Monitor (MEM) continuously monitors your MySQL servers and alerts you to potential …
[Read more]
Using MySQL, Perl and jQuery to Auto-Populate a Form Field on a Web Page

If you have ever built a form on a web page, you might have used a drop-down menu to display the choices available for a particular field. With a drop-down menu, you restrict the choices a user may select so that the user doesn’t enter invalid data (among other reasons). If a user misspells an entry, then a subsequent search for that value would not produce a found result.

A friend of mine who runs an online forum sent me an email about a problem he was having. He was trying to modify an existing registration web page using jQuery to auto-populate the state names, and then pass the state abbreviation back to his MySQL database. Believe it or not, he was actually having problems with people knowing their own state abbreviation. He had searched and found an example of what he wanted to do, but he couldn’t get it to work. So, I took the …

[Read more]
451 CAOS Links 2010.03.23

Marten Mickos joins Eucalyptus. Novell rejects Elliot. Perspectives on OSBC. And more.

Follow 451 CAOS Links live @caostheory on Twitter and
“Tracking the open source news wires, so you don’t have to.”

# Mårten Mickos was named CEO of Eucalyptus Systems.

# Novell’s board rejected Elliot’s takeover proposal as inadequate, will review other alternatives.

# North Bridge Venture Partners published the results of its Future of Open Source survey.

# Rob Bearden was appointed executive chairman of the board of Pentaho.

# The Eclipse Foundation …

[Read more]
Hidden Features Of Perl, PHP, Javascript, C, C++, C#, Java, Ruby, Python, And Others [Collection Of Incredibly Useful Lists]


StackOverflow is an amazing site for coding questions. It was created by Joel Spolsky of, Jeff Atwood of, and some other incredibly smart guys who truly care about user experience. I have been a total fan of SO since it went mainstream and it's now a borderline addiction (you can see my StackOverflow badge on the right sidebar).

The Story

Update 6/21/09: This server is currently under very heavy load (10-200), even with caching plugins enabled. Please bear with me as I try to resolve the situation.

Feel free to …

[Read more]
Mozilla Foundation Report for 2009 Week 4

This is Zak Greant's weekly report on his activities for the Mozilla Foundation from January 19th to 25th, 2009.

Wading through heaps of Mozilla email and feeds last week paid off this week. Instead of worrying about what I hadn't read or wondering where I was duplicating other's work, I was able to focus on program development with most of my effort going into developing the Mozilla Social Movement Program Concept, working on the Mozilla Manifesto Stories experiment and catching up with my peers. At 54 hours, the week was a bit long but I was glad to be able to focus. …

[Read more]
... Reglib or JQuery, IPS and UpdateCenter, and Wikipedia and MySQL

Some recent news of interest:

JQuery is a small and fast JavaScript Framework (Wikipedia, homepage). JQuery is very popular (Google Trends!), but Greg (Reimer - one of the developers of Sun.Com) was interested in exploring a declarative approach to JavaScript programming and created reglib (for registration library). JavaScript fiends can start at Reg's …

[Read more]
TOTD #40: jQuery Autcomplete widget with MySQL, GlassFish, NetBeans

TOTD #39 explained how to create an Autocomplete widget (server-powered autocompleting of text fields, similar to Google Suggest) using Prototype/ libraries with NetBeans, GlassFish and MySQL. This Tip Of The Day (TOTD) builds upon that project and shows how same functionality can be achieved using jQuery Library.

  1. Use the NetBeans project created in TOTD #39. Right-clicking on the project, select "New", "JSP...", enter the name as "index2" …
[Read more]
Showing entries 1 to 9