Diskussion:GeoLocation

Wechseln zu: Navigation, Suche

Kleine Anmerkung zu den Python Strings. Statt

print
print "Information about " + givenMac
print
print "Accuracy: " + str(responseJson["location"]["accuracy"]) + "m"
print "Latitude: " + str(responseJson["location"]["latitude"])
print "Longitude: " + str(responseJson["location"]["longitude"])
print
print "Approximate address:"

kannst auch den """-String nehmen:

print """
Information about %{givenMac}s

Accuracy: %{accuracy}dm
Latitude: ....""" % \
{givenMac:"blabla", accuracy:str(responseJson["location"]["accuracy"]), ...}

Mehr Infos dazu gibt's in der [Python Doku] --Whiskey 08:44, 17. Jan. 2011 (UTC)

Danke, habe es angepasst. --Basti 20:56, 17. Jan. 2011 (UTC)

Meine Werkzeuge
Namensräume

Varianten
Aktionen
Navigation
Sensorik
Werkzeuge