This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"title": "External Link Example (Get)", | |
"alert": "Sample Alert", | |
"icon": "little_star", | |
"badge": "+1", | |
"sound": "circus.wav", | |
"vibrate": false, | |
"callToAction": { | |
"action": "B", | |
"uri": "http: //www.example.com", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
var Tabletop = require('tabletop'); | |
var wrench = require('wrench'); | |
var public_url = "https://docs.google.com/spreadsheet/pub?key=0ArTqrFjFwISadGI4anRRZlM4UGZrcjNTMTJ0OWsydkE&output"; | |
var builder = require('xmlbuilder'); | |
var _ = require('underscore'); | |
var fs = require('fs'); | |
var path = require('path'); | |
var cwd; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
files=$(git diff --cached --name-only --diff-filter=ACM | grep ".js$") | |
if [ "$files" = "" ]; then | |
exit 0 | |
fi | |
pass=true | |
echo "\nValidating JavaScript:\n" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var images = { | |
"productBiscuits" : { | |
"boat" : "https://s3.amazonaws.com/razuna-server-tui/A3BCD0D5F6B7414BBDC94B5D505AC601/img/73B98337448B4A8B9F51888A7C7A8318/boat_73B98337448B4A8B9F51888A7C7A8318.png?AWSAccessKeyId=AKIAJKGCNZBGAX5FSCSQ&Expires=1725974249&Signature=%2Bew8AKJLxzIs8C6HgBCmp2jsHUQ%3D", | |
"camper" : "https://s3.amazonaws.com/razuna-server-tui/A3BCD0D5F6B7414BBDC94B5D505AC601/img/6B9CE162196A4455A77D128EAA9DF04D/camper_6B9CE162196A4455A77D128EAA9DF04D.png?AWSAccessKeyId=AKIAJKGCNZBGAX5FSCSQ&Expires=1725974407&Signature=r0CqD4bc%2BzBPZZmMfMT2IICL%2Fl0%3D", | |
"car" : "https://s3.amazonaws.com/razuna-server-tui/A3BCD0D5F6B7414BBDC94B5D505AC601/img/5031ADD80C014B16B7455B9132B6E998/car-hire_5031ADD80C014B16B7455B9132B6E998.png?AWSAccessKeyId=AKIAJKGCNZBGAX5FSCSQ&Expires=1725974445&Signature=2W8ix1a27Cit4rVvbvDGAzJsUcY%3D", | |
"extra" : "https://s3.amazonaws.com/razuna-server-tui/A3BCD0D5F6B7414BBDC94B5D505AC601/img/0906F231770D416EAAD822F8ADFB2821/extras_0906F231770D416EAAD822F8ADFB2821.pn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if (Alloy.CFG.theme === "meinetui") { | |
$.requestFN = "getContactByType"; | |
Alloy.Globals.Api[$.requestFN]({ | |
//can be 'general', 'mein-service', 'mein-service-excursions' | |
type : 'mein-service-excursions', | |
//excursionsId is ignored unless mein-service-excursions is used, in which case it is mandatory | |
excursionId: '1212' | |
}, $.successCallback, $.failedCallback); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function propDeep(target, path, rtn) { | |
"use strict"; | |
try { | |
target = target || {}; | |
var result = eval("target." + path); | |
} catch(e) { | |
return false; | |
} | |
if (result) { | |
return rtn ? result : true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var movie = Titanium.Filesystem.getFile(Titanium.Filesystem.applicationDataDirectory, 'mymovie.mov'); | |
var thumb = Titanium.Filesystem.getFile(Titanium.Filesystem.applicationDataDirectory, 'mymoviethumb.jpg'); | |
Titanium.Media.showCamera({ | |
success : function(event) { | |
var video = event.media; | |
if (movie.exists()) { | |
movie.deleteFile(); | |
} | |
movie.write(video); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Function ChangeFieldNamesInForm() | |
Try | |
Dim sourcePDF As String = "source.pdf" | |
Dim outputPDF As String = "destination.pdf" | |
Dim fsw As FileStream = New FileStream(outputPDF, FileMode.OpenOrCreate, FileAccess.ReadWrite) | |
Dim reader As PdfReader = New PdfReader(sourcePDF) | |
Dim stamper As PdfStamper = New PdfStamper(reader, fsw) | |
Dim root As PdfDictionary = reader.Catalog() | |
Dim form As PdfDictionary = root.GetAsDict(PdfName.ACROFORM) | |
Dim fields As PdfArray = form.GetAsArray(PdfName.FIELDS) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Imports Microsoft.Http | |
Imports System.Text | |
Public Class DrupalForm | |
Public Function create(ByVal type As String, ByVal formatoutput As Boolean, ByVal authenticate As Boolean) As HttpMultipartMimeForm | |
Dim form As New HttpMultipartMimeForm | |
Dim helper As New DrupalHelper | |
Dim method As String = Nothing | |
Dim methodstring As String = Nothing | |
Try |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Imports System.IO | |
Imports System.Text | |
Imports System.Security.Cryptography | |
Public Class DrupalHelper | |
'most of the ideas here came from an article at http://drupal.org/node/308629 | |
Public Function getUnixTimestamp() As String | |
Dim ts As New TimeSpan |
OlderNewer