mysqli更新函数不更新行

时间:2015-09-08 05:24:57

标签: php mysql mysqli

我正在尝试更新某个项目,我不知道为什么var latitude = 0; var longitude = 0; function getLocation() { if (navigator.geolocation) { navigator.geolocation.getCurrentPosition(displayLocation); } else { alert("Geolocation is not supported by this browser."); } } function displayLocation(position) { latitude = position.coords.latitude; longitude = position.coords.longitude; return; } jQuery(document).ready(function($) { $.ajax({ url : "http://api.wunderground.com/api/7c5cbc3e4db2885a/geolookup/conditions/q/" + latitude + "," + longitude + ".json", dataType : "jsonp", success : function(parsed_json) { var location = parsed_json['location']['city']; var temp_f = parsed_json['current_observation']['temp_f']; var desc = parsed_json['current_observation']['weather']; var wind_dir = parsed_json['current_observation']['wind_dir']; ("Current temperature in " + location + " is: " + temp_f); $('#location').html(location); $('#temp_f').html(temp_f); $('#desc').html(desc); $('#wind_dir').html(wind_dir); $('#icon_url').attr('http://icons.wxug.com/i/c/i/clear.gif', img); } }); }); 返回'0。

一些数据,在检查时似乎正确:

$q->affected_rows - var_dump($query_parts)

string(40) "item_description = ?, item_publisher = ?" - var_dump($prep)

string(3) "sii"

var_dump($values)

array(3) { [0]=> &string(12) "Description" [1]=> &string(1) "1" [2]=> &string(3) "729" } - var_dump($q)

bool(true)

0 个答案:

没有答案