code for the glide iphone app