Notes by James
Displaying notes 91 - 100
Created by James on September 28, 2010 19:16:22
Last update: September 28, 2010 19:16:22
Processing.js is an open programming language for people who want to program images, animation, and interactions for the web without using Flash or Java applets. Processing.js uses Javascript to draw shapes and manipulate images on the HTML5 Canvas element. The code is light-weight, simple to learn and makes an ideal tool for visualizing data, creating user-interfaces and developing web-based games.
URL: http://processingjs.org/
Created by James on September 28, 2010 19:09:27
Last update: September 28, 2010 19:09:27
It depends on jQuery 1.4.2 and jQuery UI 1.8. The widget is styleable using Themeroller. It works in an unobtrusive fashion, by just turning html multiple select inputs into a sexier equivalent. There's no extra markup needed.
URL: http://quasipartikel.at/multiselect/
Created by James on September 28, 2010 16:14:21
Last update: September 28, 2010 16:14:21
// lookup first element with class logcat-filt...
Created by James on September 27, 2010 23:14:51
Last update: September 27, 2010 23:15:12
Use the length attribute. Length would be zero if the matched set is empty. For example:
$('.module-selector:first').siblings('div.log-data...
Created by James on September 20, 2010 22:30:46
Last update: September 20, 2010 22:30:46
<html>
<head>
<style type="text/css">
...
Created by James on September 10, 2010 23:01:14
Last update: September 10, 2010 23:01:14
By default, heights for jQuery UI tab panels expand or contract depending on the height of each tab. The code snippet here sets the height of all tabs to be equal to that of the container.
<!DOCTYPE html>
<html>
<head>
<title>jQu...
Created by James on September 07, 2010 22:12:01
Last update: September 07, 2010 22:13:45
I had a need to use Ajax to get a response from the server and conditionally render the results based on a status code. Additionally, I need to update multiple areas on the page from the results of one request. The code presented here uses jQuery and an XML response with CDATA sections to achieve that goal.
Server side code (perl cgi):
#!C:/perl/bin/perl.exe
##
## redirect
##...
The HTML page:
<html>
<head>
<script type="text/javascript...
Created by James on September 03, 2010 20:43:28
Last update: September 03, 2010 20:43:48
Match a regex:
'Free online videos for $.10 each'.match(/each$/);...
Search for a regex pattern:
'Jack Jake Jason'.search(/son/);
// 12
Replace by regex match:
'Jack Jake Jason'.replace(/.a/g, 'Ma');
// Mack...
Split by regex:
'She sells seashells by the seashore'.split(/\s/);...
Created by James on September 03, 2010 20:00:44
Last update: September 03, 2010 20:00:44
.title {
font-variant: small-caps;
text-tr...
Created by James on September 03, 2010 16:12:30
Last update: September 03, 2010 16:12:30
Hide all DIV within contents except the one selected by a dropdown selector:
function displayDiv(selector) {
$('#contents')...
This is the description of end() from jQuery doc :
End the most recent filtering operation in the current chain and return the set of matched elements to its previous state.