Page 3 of 14

Brand New to Tiggzi

Posted: Sat Mar 16, 2013 2:26 pm
by Joe Paisley

In the Facebook Tutorial Doc, I'm confused as to what you put in the url field of the settings tab in the getdata service. I should have a unique url there correct? Where would I get that url?


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 8:05 am
by Kateryna Grynko

GetData service should have URL: https://graph.facebook.com/me
as it's said in:
http://docs.tiggzi.com/tutorials/buil...


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 8:08 am
by Kateryna Grynko

Hi Joe,

I mean that how to i manipulate the components on each page so that they are sized to fit whatever the device screen is?

All the components (except for Image, Panel and Separator) are stretched by screen width by default. You can fit to screen these three components via CSS.

Have you had any luck with finding out how to change the "mode" of transportation and the "bicycle overlay" on the google maps window?

You can add Bicycle layer to Google map via JavaScript:

codevar bikeLayer = new google.maps.BicyclingLayer();
bikeLayer.setMap(Tiggzi('googlemap1').gmap)/code
Replace "googlemap1" with Map component name in Tiggzi.

I'm having trouble with the geolocation button also, it won't work when I scan the QR code to test the app, and it doesn't access that part of the phone sensor array.
The "Take a Photo" button doesn't access the camera on my phone either.

Please share your app so I can take a look.


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 1:43 pm
by Joe Paisley

I believe it should already be shared with a href="mailto:support@tiggzi.com" rel="nofollow"support@tiggzi.com/a

I added those javascript variables in my document.

The way I understand it, the var bikeLayer is for the green bike routes layer..but I don't see this when I test it.

Also, I think I figured out how to change the "mode" property, along with a few others.

Last night, when I scanned the QR code, and the phone prompted me about location settings, which I agreed to, but it didn't actually show my location on the map.

Right now though, buttons aren't working again. I was logging in and testing by using the QR scanner, as the Tiggzi mobile app tester wasn't working for me. Although the web browser was working (I'm using Chrome) the navigational buttons aren't working today. Still no luck on the Camera. My javascript page is below:

code
var bikeLayer = new google.maps.BicyclingLayer();
bikeLayer.setMap(Tiggzi('directionsMap').gmap)

var directionDisplay;
var directionsService = new google.maps.DirectionsService();

function initialize() {
directionsDisplay = new google.maps.DirectionsRenderer();
}

function displayDirections(sourceAddress, destinationAddress, map, panel) {
var request = {
origin: sourceAddress,
destination: destinationAddress,
travelMode: google.maps.DirectionsTravelMode.BICYCLING
avoidHighways: true,

Code: Select all

 }; 
 directionsService.route(request, function(response, status) { 

if (panel != null) {
directionsDisplay.setPanel(panel);
}
directionsDisplay.setMap(map);

Code: Select all

   if (status == google.maps.DirectionsStatus.OK) { 
  directionsDisplay.setDirections(response); 
   } else { 

alert("Directions query unsuccessful. Response status: " + status);
}
});
}
/code

I really appreciate all of your support in this matter! I feel like we're close!


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 5:03 pm
by Maryna Brodina

Hello! Could you clarify your app name please?


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 5:07 pm
by Joe Paisley

"Pedal Collective Mobile"


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 5:08 pm
by Maryna Brodina

Thank you!


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 7:18 pm
by Maryna Brodina

1) Replace your JavaScript1.js with next code:

codevar bikeLayer, directionDisplay, directionsService, directionsDisplay;
function initialize() {
bikeLayer = new google.maps.BicyclingLayer();
bikeLayer.setMap(Tiggzi('directionsMap').gmap);
directionDisplay;
directionsService = new google.maps.DirectionsService();
directionsDisplay = new google.maps.DirectionsRenderer();
}

function displayDirections(sourceAddress, destinationAddress, map, panel) {
var request = {
origin: sourceAddress,
destination: destinationAddress,
travelMode: google.maps.DirectionsTravelMode.BICYCLING,
avoidHighways: true

Code: Select all

 }; 
 directionsService.route(request, function(response, status) { 

if (panel != null) {
directionsDisplay.setPanel(panel);
}
directionsDisplay.setMap(map);

Code: Select all

   if (status == google.maps.DirectionsStatus.OK) { 
  directionsDisplay.setDirections(response); 
   } else { 

alert("Directions query unsuccessful. Response status: " + status);
}
});
}/code

2) On click on Show Location replace

codevar map = Tiggr('googlemap1');/code
with
codevar map = Tiggr('directionsMap');/code

3) To show current location on map on success GeolocationService event add

codevar sfLatlng = new google.maps.LatLng(data.coords.latitude, data.coords.longitude);
var googleMapDiv = Tiggzi("directionsMap").get(0);
var mapOptions = {
zoom: 10,
center: sfLatlng,
mapTypeId: google.maps.MapTypeId.ROADMAP
};
/Add mark to screen/
var map = new google.maps.Map(googleMapDiv, mapOptions);
var marker = new google.maps.Marker({
position: sfLatlng,
map: map
});/code


Brand New to Tiggzi

Posted: Mon Mar 18, 2013 10:25 pm
by Joe Paisley

Where do I add 3? I'm sorry, I don't see where I can add JavaScript to the Geolocation service event. Where's that? I'm having trouble logging in again for some reason. any luck with the camera?


Brand New to Tiggzi

Posted: Tue Mar 19, 2013 8:50 am
by Kateryna Grynko

Hi,

You can add JavaScript to the Geolocation service event in Data tab: Image

Camera won't work on browser. You would need to build APK for Adnroid or IPA for iOS and open your app in Tiggzi Tester.