Skip to content

Instantly share code, notes, and snippets.

View cfjedimaster's full-sized avatar
😺
Happy, and tired.

Raymond Camden cfjedimaster

😺
Happy, and tired.
View GitHub Profile
var openRequest = indexedDB.open("notes",2);
//handle setup
openRequest.onupgradeneeded = function(e) {
console.log("running onupgradeneeded");
var thisDb = e.target.result;
//Create Note
if(!thisDb.objectStoreNames.contains("note")) {
console.log("I need to make the note objectstore");
var openRequest = indexedDB.open("notes",3);
//handle setup
openRequest.onupgradeneeded = function(e) {
console.log("running onupgradeneeded");
var thisDb = e.target.result;
//Create Note
if(!thisDb.objectStoreNames.contains("note")) {
console.log("I need to make the note objectstore");
var objectStore = thisDb.createObjectStore("note", { keyPath: "id", autoIncrement:true });
<!DOCTYPE html>
<html>
<head>
<script>
var db;
// https://developer.mozilla.org/en/IndexedDB/Using_IndexedDB
var indexedDB = window.indexedDB || window.webkitIndexedDB || window.mozIndexedDB || window.msIndexedDB;
var IDBTransaction = window.IDBTransaction || window.webkitIDBTransaction;
<!DOCTYPE html>
<html>
<head>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script>
var db;
// https://developer.mozilla.org/en/IndexedDB/Using_IndexedDB
var indexedDB = window.indexedDB || window.webkitIndexedDB || window.mozIndexedDB || window.msIndexedDB;
window.plugins.webintent.startActivity({
action: WebIntent.ACTION_VIEW,
url: 'geo:0,0?q=' + 'new york'},
function() {},
function(e) {alert('Failed to open URL via Android Intent');}
);
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.camden.intenttest"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="10" />
<supports-screens
android:largeScreens="true"
<!DOCTYPE html>
<html>
<head>
<script src="cordova-1.6.1.js"></script>
<script src="webintent.js"></script>
<script>
function init() {
document.addEventListener("deviceready",deviceReady,false);
}
<cfsetting requesttimeout="999">
<cfset x = 1>
<cfloop condition="x lt 100">
<cfscript>
stockList = ["APPL","ADBE","MSFT","GOOG","IBM","WOPR","CAT","DOG"];
/* BORKED!
arrayEach(stockList, function(itm) {
<cfset artService = new art()>
<cfset art = artService.getArtList()>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Art Lister</title>