Geolocation and Weather App This web application is developed to show country and weather data using user's geolocation information. The user can enter a place name in the search box or get their current location using the "Find My Location" button.
By clicking the btnSearch button, country information and neighboring countries information are obtained according to the place name entered by the user. By clicking the btnLocation button, the user's current geographic location is obtained and the country information and weather data of this location are obtained. Geolocation information and weather data are obtained from services such as OpenCage Data API and OpenWeatherMap API. Using RESTCountries API, the application retrieves country information and displays the flags, official names of neighboring countries. In case of error, the corresponding error messages are displayed to the user. Users can use the "toggleDarkMode" function to switch between light/dark theme. This application is developed with HTML and CSS to get the geolocation of the user using JavaScript, interact with the APIs and display the results.
These codes contain the basic functionality of a simple web application that provides users with geolocation information and weather information.
Use To use this web application, you can follow the steps below:
Enter a place name in the search box or click the "Find My Location" button to use your current location. Click the search button or wait until your location is automatically retrieved and processed. The app will get the country information by place name or location and fetch the weather data. Country information and weather results will be displayed along with details such as flags, population, capital, language and currency in the respective regions. Also, the flags of neighboring countries will be displayed.
Contributing If you would like to contribute to this project, you can follow the steps below:
Fork this project on your own account. Create a new branch. Add your changes and write your commit message descriptively. Push your changes to the original project you forked (pull request). After going through the review process, your changes can be incorporated into the project.