BAIDU map return error like as attached screen - baidu-map

Map integrate with ionic app, it return error like as attached image.

Related

Flutter I want navigate to another screen while the current screen running

I want navigate to another screen while current screen is running. If in Firestore collection new document add then app listen it and navigate to another page. Please help me...
I don't think this is possible with the traditional navigator, however, one way of "emulating" something similar is by using an IndexedStack, which keeps both widgets loaded and you can simply select an index. I've used this successfully when I needed a fancy splash screen and wanted my other widget to load early.
However, it seems to me your problem is more to do with maintaining state. I'd recommend reading Flutter's page on lifting state up. You can use something like Provider above your MaterialApp to keep your data loading even when your widget isn't on screen or simply pass your state back and forth between pages using navigator arguments (I don't recommend that).
You can try something like this
void initState() {
listenFirestore();
super.initState();
}
listenFirestore() async {
Firestore.instance
.collection('availableDates')
.snapshots()
.listen((data) => {
// here you can call navigator method
});
}
Listen to Firebase changes and call a function to navigate for a new screen.
If you are using Flutter Bloc you can do this using BlocListener.
BlocListener official doc.

Whatsapp share link not working from mobile

I am using aspx to initialize the whatsApp click to chat feature to share a link.
The aspx code is :
The link was working fine. I was able to share the link. But in the recent months i am not able to share the link as i get a message from whatsapp in my mobile displayed as
Couldn't open link
Screen Shot:
NOTE: I am able to share from web browser but not from my mobile.
Is there anything wrong in the syntax or has whatsapp updated their feature, but i dont think so as their docs are still having the same info ?
Edit: The output url looks like this in chrome inspector:
https://wa.me/?text=https%3a%2f%2fwww.website.com%2fblog%2fPageName.aspx%3fblog%3dtitleword-your-titleword-system-using-titleword%26id%3d10%26temp%3dq
For computers, you will want to use this link...
https://api.whatsapp.com/send?text=YourTextHere
Otherwise, if you use wa.me, you will get an error page, unless you have the phone number included. For example, this links to an error: https://wa.me/?text=SomeTexttoShare
Typically, you don't know the number, and you want the user to specify. In that case, you MUST use the api.whatsapp.com domain.
I tried the same link in different android browser(FireFox) and it was working fine.
For chrome i changed the link to this -> whatsapp://send?text=
My code:
string WhatsappShareURL = "whatsapp://send?text=" + Request.Url.AbsoluteUri;
hlWhatsappMobile.NavigateUrl = Server.UrlEncode(WhatsappShareURL);
For Computers:
I use this link -> https://wa.me/?text=
My code:
string WhatsappShareURL = "https://wa.me/?text=" + Request.Url.AbsoluteUri;
hlWhatsappWeb.NavigateUrl = Server.UrlEncode(WhatsappShareURL);
Then i toggle them in jquery:
$(document).ready(function () {
if ($(window).width() < 520) {
//Show mobile link
}
else {
//Show Web link
}
});

Qt WebView and clicking on a google map

Has anyone tried to click on a google map displayed in Qt QWebView via one of QWebView's mouse event methods? I want to do this in this way becouse I need to run some actions both in Qt and in google map (when I click on map I want to add e. g. a bus stop - it'll load inside the programme and the marker will apear on the map). I've got a method for adding a placemark and I know I can call it, but I've got problem with passing correct position.
void MyWebView::mousePressEvent(QMouseEvent * e) {
QString command = "placeMarker(new google.maps.LatLng(";
command.append(new QString(e->x()));
command.append(", ");
command.append(QString(e->y()));
command.append("))");
this->page()->mainFrame()->evaluateJavaScript(command);
}

Error on GoogleMaps API while being generated

I've finished my last project that uses GoogleMaps API v3 sucessfully.
But now, with no reasons the map is not being generated anymore.
The window with all map controls is opened correctly but the map
itself is not. It shown only a gray screen.
There is no errors on the script before calls google.maps function and
there is no errors after it too!
Can anyone try to help me with this issue?
Thx anyway.
I had a similar problem when I used GoogleMaps API in a Jquery UI Dialog, the map div would be gray. I corrected this problem by resizing the map when I opened the Dialog. I am also using the GMAP3 Jquery plugin.
Here is the resizing function:
function resizeMyMap() {
var mymap = $('#map_canvas').gmap3({ action: 'get', name: 'map' });
google.maps.event.trigger(mymap, "resize");
$('.gmap3').gmap3({
action: 'autofit'
});
}
If you do not use the GMAP3 Jquery plugin, you can try this to resize the map:
google.maps.event.trigger(map, 'resize')

How to get latitude and longitude of center of google map

Please tell me how can i raise event just after user change his position in google map using dragging map and get the latitude and longitude of center of google map and the miles its showing from center. i have got lots of pages on google related to it.. but not able to solve this.. please give me solution (i am using asp.net and javascript)
GEvent.addListener(map, "moveend", function() {
var center = map.getCenter();
});
You can add moveend() or dragend() event (reference) and call getCenter() method to get the new map center
Further resources to search for the links and code related to google map api is :
http://groups.google.com/group/google-maps-api

Resources