Тёмный

How to get IP information using JavaScript (Leafletjs and Ipify tutorial 2020) 

Coding With Siphiwo
Подписаться 1,4 тыс.
Просмотров 6 тыс.
50% 1

In this tutorial we will take a look at how we can get user IP information using Javascript and Ipify.
As with most of my tutorial, you can download the project below to reference the code. Feel free to edit and create something new using this as a guide.
Download full project here: github.com/Siphiwo/ip-address...
#javascript #ipify #leafletjs
Today we will be building a javascript application that will accept an IP address as an input, retrieve the data of that IP from ipify and update the information displayed and also the map location.
We will be building the #html, #css of the application and code the functionality. I will also show you how to bypass a CORS issue with ipify and localhost.

Опубликовано:

 

30 сен 2020

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 12   
@siphiwocode
@siphiwocode 3 года назад
Thank you for watching this videos and others on my channel. I encourage you to subscribe and like the videos to help others like you find this content. Thanks 👍
@azzykesuma4066
@azzykesuma4066 2 года назад
thanks! this is really helpful
@adeseyeadekunle198
@adeseyeadekunle198 3 года назад
Lovely video and the explanation in addition to the leaf documentation was helpful.However your bypass to help prevent the error is slightly fuzzy, can you please recommend a guide for further study on it? Thanks.
@siphiwocode
@siphiwocode 3 года назад
Thanks for the view, like and sub man really appreciate it. Would love to help but not sure what error your referring to. Can you refer the timestamp on the video
@adeseyeadekunle198
@adeseyeadekunle198 3 года назад
@@siphiwocode around the 7:17 mins,the const cors bypass url. You used a heroku url
@siphiwocode
@siphiwocode 3 года назад
@Adeseye the bypass here is due to CORS. Here is a quick overview of what CORS is and why a bypass like that would be needed.🙂 ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-4KHiSt0oLJ0.html
@adeseyeadekunle198
@adeseyeadekunle198 3 года назад
@@siphiwocode thanks alot
@adeseyeadekunle198
@adeseyeadekunle198 3 года назад
@@siphiwocode Hi,sorry for disturbing you again. Did everything and checked my solutions with yours which is close enough. Don't know if I can send my github repo here but I'm getting syntaxerror unexpected token t in json at position 0. I've been trying to solve this all day. Please help. Also I created my own cors heroku app to bypass the cross origin issue and it worked
@mahtajannatifar5265
@mahtajannatifar5265 Год назад
Hello, how do I show the current location of the user when the web page opens? How to get their IP address and display it initially? also, great video!
@siphiwocode
@siphiwocode Год назад
Hi Mahta, you will need to declare a document.ready function and inside that function run this script which will return a json format of the user IP details and location like the city. The document.ready will run once the user opens the web-page it has fully loaded. No need for a trigger event. Link: ipapi.co/json/
@godisgood2482
@godisgood2482 3 года назад
Can this track location of someone?
@siphiwocode
@siphiwocode 3 года назад
Hi, unfortunately not as is now. You will need to add some type of awake script that will keep getting the users location every second or so.
Далее
Телеграмм-Колян Карелия #юмор
00:10
Камень, ножницы, нейронка
00:33
Просмотров 1,2 млн
IP Address Tracker - Frontend Mentor Challenge
1:17:16
How to Do 90% of What Plugins Do (With Just Vim)
1:14:03
Просмотров 876 тыс.
Get User Location by IP Address - JavaScript Tutorial
15:57
Build any layout with tailwind | crash course
34:28
Просмотров 57 тыс.
Using the Geolocation API - JavaScript Tutorial
10:28
Where Does Bad Code Come From?
42:21
Просмотров 187 тыс.
Телеграмм-Колян Карелия #юмор
00:10