ユーザーからアドレス情報を取得し、Google の地図に表示するメソッドを作成しました。これは私が書いた方法です
function doRemoteMapEmployee(e) {
var mapEmployeeAddressLine1 = (EmployeeInfo.at(0).EmployeeAddressLine1 !== null) ? EmployeeInfo.at(0).EmployeeAddressLine1 + ', ' : '',
mapEmployeeAddressLine2 = (EmployeeInfo.at(0).EmployeeAddressLine2 !== null) ? EmployeeInfo.at(0).EmployeeAddressLine2 + ', ' : '',
mapEmployeeAddressLine3 = (EmployeeInfo.at(0).EmployeeAddressLine3 !== null) ? EmployeeInfo.at(0).EmployeeAddressLine3 + ', ' : '',
mapEmployeeAddressCityTown = (EmployeeInfo.at(0).EmployeeAddressCityTown !== null) ? EmployeeInfo.at(0).EmployeeAddressCityTown + ', ' : '',
mapEmployeeAddressZipPostCode = (EmployeeInfo.at(0).EmployeeAddressZipPostCode !== null) ? EmployeeInfo.at(0).EmployeeAddressZipPostCode : '',
address = mapEmployeeAddressLine1 + mapEmployeeAddressLine2 + mapEmployeeAddressLine3 + mapEmployeeAddressCityTown + mapEmployeeAddressZipPostCode;
navigator.app.loadUrl("http://maps.google.co.uk/?q=" + address);
}
これを実行すると、 undefined のメソッド loadurl を呼び出せないというエラーが表示されます。アドレスを実際のアドレスに置き換えると、同じエラーが発生します。ここで何がうまくいかないのでしょうか?