Leaflet Routing Machine || Open Source Routing service || GeoDev

Поделиться
HTML-код
  • Опубликовано: 8 фев 2025
  • Leaflet routing machine GitHub: github.com/per...
    Source code: github.com/iam...
    #leafletjs #routing #location #opensource #trackLocation #locate
    ----------------------------------------------------------------------------------------
    Here are some playlists that you might interested with:
    ----------------------------------------------------------------------------------------
    1. Leaflet from basic to advance: • Leaflet from basic to ...
    2. GeoServer with leaflet web-GIS: • GeoServer and Leaflet ...
    3. GeoDjango project: • Bookmark note on map |...
    4. geoserver-rest: • geoserver-rest
    5. GIS training in Nepali: • Beginner GIS training ...
    6. LULC map production: • LandUse Land Cover Map...
    7. Geospatial analysis with python: • GeoSpatial analysis wi...
    8. GeoNode from basic to advance: • GeoNode from basic to ...
    --------------------------------------------------------------------------------------------------------------
    Check out my courses at the discounted price from the below link:
    --------------------------------------------------------------------------------------------------------------
    1. "Geospatial data analysis with python": www.udemy.com/...
    2. "Web GIS Development 2021": www.udemy.com/...
    3. "Web mapping and Web-GIS from Dev to Deploy 2021: GeoDjango": www.udemy.com/...
    4. "Introduction to Web Mapping and Web GIS 2020: GeoDjango": www.udemy.com/...
    ---------------------------------------------------------------------------------------------------
    Follow me on GitHub: github.com/iam...
    Follow me on Twitter: / iamtekson
    Follow me on Instagram: / iamtekson
    -----------------------------------------------------------------------------------------------------

Комментарии • 114

  • @aldoPieraccini
    @aldoPieraccini 2 года назад +4

    Bravo e grazie. Io seguo sempre i tuoi corsi ---- Bravo and thanks. I always take and follows your videos

    • @geodev
      @geodev  2 года назад +1

      Thanks Aldo, Your word inspire me to create more fruitful contents.

  • @julescherylumm4510
    @julescherylumm4510 Год назад +3

    Very good video thanks dude.

    • @geodev
      @geodev  Год назад

      You are welcome!

  • @vinayjumani9602
    @vinayjumani9602 10 месяцев назад +1

    Very good video thanks Bro 👍👍

    • @geodev
      @geodev  10 месяцев назад

      Thank you too

  • @iammr4lph4
    @iammr4lph4 10 месяцев назад +1

    This is so much valuable thank you so much

  • @sikeisdead
    @sikeisdead Год назад +1

    Dhanyabaad Daaju💖

    • @geodev
      @geodev  Год назад

      You are welcome!

  • @oliveselow-bw3py
    @oliveselow-bw3py Год назад +2

    Like it with python roadmap..!

    • @geodev
      @geodev  Год назад

      What do you mean by python roadmap?

  • @adamorowski2294
    @adamorowski2294 Год назад

    This is so helpful, thank you 🙌

    • @geodev
      @geodev  11 месяцев назад

      Glad it was helpful!

  • @nodehead9475
    @nodehead9475 11 месяцев назад +1

    amazing content bro

    • @geodev
      @geodev  11 месяцев назад

      Appreciate it

  • @jessynkwabong6627
    @jessynkwabong6627 Год назад +2

    great tutorial, please how to use it on a mobile phone ?

    • @geodev
      @geodev  Год назад

      I think you can run this function on mobile browser as well. No extra setup is needed for that.

  • @I_study_for_real
    @I_study_for_real Год назад

    Hi man i have watched most of your videos but this one is the most relevant for me. I'm working on my thesis and i have learnt some things thanks to your videos. I want to ask you if there is a way we can change this code for finding the shortest path via walking and not driving. Thanks in advance

  • @afnane21504
    @afnane21504 8 месяцев назад +1

    thank u so much.

    • @geodev
      @geodev  8 месяцев назад +1

      You are most welcome

  • @carljayricopalima5581
    @carljayricopalima5581 Год назад +2

    Hi! Thank you for this Tutorial it helps for our thesis. It very helpful. Is it possible to click only the route , it cannot click on mountains and oceans.

  • @nandakyawwin9006
    @nandakyawwin9006 6 месяцев назад +1

    nice

    • @geodev
      @geodev  6 месяцев назад

      Thanks

  • @ericzerna6863
    @ericzerna6863 Год назад +2

    How can you set the taxi travel time from point A to B that should be equal to the estimated time.? If estimated time is 2mins..then the taxi should move and arrive 2mins to the destination.

    • @geodev
      @geodev  Год назад

      That logic can be implemented by some mathematical logics.

  • @shrutinamdeo5460
    @shrutinamdeo5460 2 года назад +2

    Sir please make a video to how we can identifying forest fire prone zone in arcgis

    • @geodev
      @geodev  2 года назад

      That's a great suggestion. I will try to make it publish soon. Thanks!

  • @exzant
    @exzant Год назад +1

    Hi, thanks for amazing code.
    How to change icon A/B or remove it ?
    Thanks again

    • @geodev
      @geodev  Год назад

      You can remove the marker by map.removeLayer(marker)

  • @Damian1Ch93
    @Damian1Ch93 Год назад +2

    Thanks ;) It is possible to plan a route with many points in a leaflet?

    • @geodev
      @geodev  Год назад +1

      Yes, possible. Please check this resource: www.liedman.net/leaflet-routing-machine/tutorials/interaction/

  • @iNene233
    @iNene233 2 года назад +1

    Thanks for making this, quick one...what if you routing a river?

    • @geodev
      @geodev  2 года назад

      To route a river, you need a river network dataset and somehow need to publish it before designing the webapp.

  • @hugomaldonadonavia
    @hugomaldonadonavia Год назад

    Very good job, where can I complement this information, with the vehicle icon, follow the route in the direction, make the turns and continue following the route?

  • @harrybarcia3177
    @harrybarcia3177 2 года назад +1

    Thank you!!

    • @geodev
      @geodev  2 года назад

      You are welcome

  • @bryc42013
    @bryc42013 Год назад +2

    Is this routing option still good for production? The console says this is OSRM's demo server and is not suitable for production. I want to use this routing option but don't know how to set up my own OSRM server for it. Maybe an updated video about that could help, thanks!

    • @geodev
      @geodev  Год назад

      I think you can use this for the production. There are lots of source of geocoding API. you can use the suitable one from here: www.liedman.net/leaflet-routing-machine/tutorials/geocoders/

  • @truth-is-only-one
    @truth-is-only-one 2 года назад +3

    Will you make a Taxi map , real time update location.

    • @geodev
      @geodev  2 года назад

      I think, I already cover how to update real time location. Here is the video reference: ruclips.net/video/8KX4_4NK7ZY/видео.html

  • @ignRay
    @ignRay Год назад +2

    is it possible to increase the gap between each move? like each jump is 10% of the total route distance

    • @geodev
      @geodev  Год назад

      I think it is possible but I haven't tested with it. You can try to skip some of the geolocations or increase the speed of the market moving

  • @JainmiahSk
    @JainmiahSk 2 года назад +2

    Nice video. Can I use this leaflet map and routing in the android app for commercial purposes? without taking google maps API?

    • @geodev
      @geodev  2 года назад

      Yes, absolutely you can. I always recommend and support to use the open source solutions.

  • @pinoltas
    @pinoltas 2 года назад +3

    Nice Video, very helpful! Can I change the marker of the start and end point of the routing machine? (like color or something)

    • @geodev
      @geodev  2 года назад +1

      Yes, of course you can. You need to add the icon for both markers.

  • @programmer8360
    @programmer8360 Год назад +2

    Can this project be linked to Database?
    It displays the path of the person when he walks like an Uber and be real time

  • @woslake7576
    @woslake7576 2 года назад +1

    gracias

    • @geodev
      @geodev  2 года назад

      You are welcome!

  • @wellingtonmatos9970
    @wellingtonmatos9970 2 года назад +2

    Nice Video. Do you know how to change the Itineraty Layer to Another local?

    • @geodev
      @geodev  2 года назад

      Sorry I didn't get you.

  • @gobajoseph5064
    @gobajoseph5064 2 года назад

    Super

    • @geodev
      @geodev  2 года назад

      Thank you!

  • @LuisRodriguez-oy1sk
    @LuisRodriguez-oy1sk 2 года назад +2

    Thanks for making this video. It's very helpful. Is it possible to add a pause/stop while the car is moving? Like if I click on the car icon, the car stops and if I click back on the icon, it resumes until it gets to the final destination.

    • @geodev
      @geodev  2 года назад +1

      Yes, that can be done. But for that you need to add two more enentlistner in your javascript code.

  • @shashikasera6476
    @shashikasera6476 2 года назад +2

    Can we add number of waypoints from source to destination?? Also can we customize the waypoints as per our requirements???

    • @geodev
      @geodev  2 года назад

      Yes, if you know the waypoints. You can update it simply by just appending the waypoints to the response from leaflet routing machine.

  • @vosumittal9132
    @vosumittal9132 Год назад +1

    Is there any way same can be made for railway route

    • @geodev
      @geodev  Год назад

      Yes, you can, but not with the same way. The current route is generated using OSM routes. If you want to generate the new route, you need to add that route in your OSM or in your backend server.

  • @wilfridfopa9011
    @wilfridfopa9011 Год назад

    hi i would like to know how to add route positions on the map and display them when using routing

  • @marroquin92
    @marroquin92 2 года назад +1

    Good Job, You Master, Leaft or openstreet hace geofencing?

    • @geodev
      @geodev  2 года назад

      Thank you!

  • @oliverrodriguez3238
    @oliverrodriguez3238 2 года назад +2

    hello, I have this problem and I have put the code the same.
    Uncaught TypeError: Cannot read properties from undefined (reading 'control')

    • @geodev
      @geodev  2 года назад

      Looks like plugin issue. Please check whether your links are correct or not. And please try to debug based on the line number given in error msz.

    • @oliverrodriguez3238
      @oliverrodriguez3238 2 года назад

      @@geodevThank you

  • @Kyro_Kinesis
    @Kyro_Kinesis 2 месяца назад

    i love you bro

  • @stefanstankovic3046
    @stefanstankovic3046 2 года назад +1

    How to get multiple routes, I always get only 'the best' route? I want to display at least 2-3 routes to user even if they are longer, so he can pick the one he wants. Any help?

    • @geodev
      @geodev  2 года назад +1

      By default, the routing engine for leaflet router is "OSRM", and it provides only one route (You can check on the console, possible routes). If you use "GraphHopper" routing engine, it might provide you the multiple routes. Please check by yourself. I haven't tested it before.

  • @amaromanungu8842
    @amaromanungu8842 2 года назад +1

    Can we tracking route with leaflet?

    • @geodev
      @geodev  2 года назад

      Yes we can.

  • @dhruvinsheladiya272
    @dhruvinsheladiya272 9 месяцев назад

    bro create two input box to input city to city location with line-draft...

  • @fionngallaharhall7926
    @fionngallaharhall7926 Год назад +1

    Hi, i want to be able to choose my starting location on the map aswell as my destination, is this possible?

    • @geodev
      @geodev  Год назад

      Yes it is possible, you can pass the first point location through input form, same as we passed the destination point

  • @sokhnamaiseck4699
    @sokhnamaiseck4699 13 дней назад

    Cependant, en n'y intégrant L'API Direction de google Maps on peut avoir plus de fiabilité sur les résultats

  • @abdallhahamdy7454
    @abdallhahamdy7454 2 года назад +1

    How change car icon orientation according path direction ?

    • @geodev
      @geodev  2 года назад

      Not possible in easy way for such implementation, you need to write your own Js code and also need lots of car photo directing to all directions.

  • @ViewtheSpot
    @ViewtheSpot Год назад +1

    Open 3d point cloud based visual positioning and lidar positioning using navigation system this is my project statement can you please help me with problem

  • @JoanneDiaz-mz1ks
    @JoanneDiaz-mz1ks 2 года назад +1

    Hi! Thank you for this wonderful video. I wonder if this routing machine can also work using folium python? Thank you.

    • @geodev
      @geodev  2 года назад

      Since it is a plugin of leaflet, I don't think it is available in folium

    • @JoanneDiaz-mz1ks
      @JoanneDiaz-mz1ks 2 года назад

      @@geodev Thank you for replying! This is highly appreciated. If you could also recommend a library or module that I can use in python to do route distancing, I would appreciate it. God bless you! :)

  • @cassandra_tupiniquim
    @cassandra_tupiniquim Год назад +1

    E possível fazer edição com essa api? Faz um video

  • @fahathmohamed-l5q
    @fahathmohamed-l5q Год назад

    Hi thank you for valuable lesson.
    i want to between start route end route i want arrow icon instant of bar solid color please replay me

    • @geodev
      @geodev  Год назад

      Please check this plugin if you want to customize the path: github.com/bbecquet/Leaflet.PolylineDecorator

  • @aldoPieraccini
    @aldoPieraccini 2 года назад +1

    how can I translate the itinerary in other language and move the legend in other place of screen??

    • @geodev
      @geodev  2 года назад

      Sorry, I think it is only available on English but you can check the official documents and check whether there is another language or not

  • @JohnSmith-co1zv
    @JohnSmith-co1zv 2 года назад +1

    Cannot read properties of undefined (reading 'control')

    • @geodev
      @geodev  2 года назад

      I think you might have spelling error. Please check the code correctly

    • @JohnSmith-co1zv
      @JohnSmith-co1zv 2 года назад

      @@geodev Got it, so is this not suitable for production use?

  • @oliveselow-bw3py
    @oliveselow-bw3py Год назад +1

    Like it with python.

  • @abenhammou9
    @abenhammou9 Месяц назад

    how to hide the fix with the instructions ?

  • @angelicaadviento4804
    @angelicaadviento4804 Год назад

    Is this applicable on admin routes?

    • @geodev
      @geodev  Год назад

      Yes, it should be.

  • @auto-diciplime237
    @auto-diciplime237 2 года назад +1

    Thank you very much sir which of your course on #Udemy can solve my issue I what to great a web app with #Django that can track customer order when a costumer wont to see his order

    • @geodev
      @geodev  2 года назад

      Thats a great suggestion. I will think about it. Thanks for suggestion.

  • @ashavelankar3362
    @ashavelankar3362 2 года назад

    what will be map input event if i am having 2 input search box

    • @geodev
      @geodev  2 года назад

      what do you mean by 2 input search box?

    • @ashavelankar3362
      @ashavelankar3362 2 года назад

      @@geodev I have 2 search input box one is startpoint and endpoint and need to find distance between 2 cities . Implementing code in ts but not allowed me to track right location and distance between 2 cities . if you provide me google hangout then I can show you problem

  • @FatimaKhan-oq3ug
    @FatimaKhan-oq3ug 2 года назад

    MAP is not showing i dont know why this issue facing by me however i follow each step

    • @geodev
      @geodev  2 года назад

      Can you check the Full code in github? I pushed everything from this code.

    • @FatimaKhan-oq3ug
      @FatimaKhan-oq3ug 2 года назад

      @@geodev yes I checked and apply full code of git hub but map is not showing and tracking is working in GitHub code

    • @jairmt0808
      @jairmt0808 2 года назад

      I have the same problem. And I noted this msn in page of liedman (Update 2020-04-06: The example above relies on OSRM's demo server. At this moment, the demo server (which is outside scope and control of the plugin's author) is no longer maintained, and its SSL certificate has expired. The plugin will not work unless you configure a routing backend yourself. I am sorry to say that, to my knowledge, there is no good default.). I don't know how to solve.

    • @jairmt0808
      @jairmt0808 2 года назад

      @Fatima Khan The solution is change http for https in L.tileLayer('{s}.tile.osm.org/{z}/{x}/{y}.png', { attribution: 'Leaflet © ' + mapLink + ', contribution', maxZoom: 18 }).addTo(map). This solution was propose by Marketitsios in this video ruclips.net/video/H9c9CcEKj2I/видео.html

  • @azarudeen6054
    @azarudeen6054 2 года назад

    how to get current location using leaflet when mobile screen locked

    • @geodev
      @geodev  2 года назад

      Sorry, I don't know how to create mobile app. But i think you have to give the permission from phone for that

  • @MrBe-ast982
    @MrBe-ast982 Год назад

  • @ariodejohnson5712
    @ariodejohnson5712 2 года назад +3

    Thanks a lot. This tutorial is very helpful but I need assistance or improvement on what you did.
    What if I don't want to loop but update the map/marker A when A moves to the destination B?? Something like you did with this tutorial: ruclips.net/video/8KX4_4NK7ZY/видео.html
    How do I do that? What do I change/add??

    • @geodev
      @geodev  2 года назад +1

      Not sure what do you mean. This tutorial is about the routing and previous was about the real time location tracking. Both are different.

    • @ariodejohnson5712
      @ariodejohnson5712 2 года назад

      @@geodev thanks for your response. My question basically is how to integrate both. Like get points A and B then start real time location tracking as user in point A moves to destination B.

    • @geodev
      @geodev  2 года назад +1

      @@ariodejohnson5712 You need to implement the previous video settimeout function here instead of the settimeout function in `routesfond` event.

    • @ariodejohnson5712
      @ariodejohnson5712 2 года назад

      @@geodev thanks again for your response. Please will you be kind of to show me like a working example? Maybe on Codepen so I can the workings and the code. Please.
      Thank you.

  • @molugushashank9188
    @molugushashank9188 2 года назад

    hello bro
    i want the tracker to go back after touching its destination and
    we used on click function , but I want that to happen without clicking like automatic roaming of locations
    like :- ruclips.net/video/8KX4_4NK7ZY/видео.html
    you have shown in the starting of this vedio
    Please help

    • @geodev
      @geodev  2 года назад

      Hi Molugu, to track the multiple locations, you need to add the locational information in the database and update it in certain interval.

    • @molugushashank9188
      @molugushashank9188 2 года назад

      @@geodev please show me how to do all that

    • @molugushashank9188
      @molugushashank9188 2 года назад

      @@geodev How to make 3 or 4 vehicles move in Javascript
      ruclips.net/video/8KX4_4NK7ZY/видео.html
      like you have shown in this video starting ??