├── README.md ├── src ├── temp │ ├── img │ │ └── new logo.png │ ├── views │ │ ├── error404.hbs │ │ ├── index.hbs │ │ ├── about.hbs │ │ └── weather.hbs │ └── commponents │ │ ├── footer.hbs │ │ └── navbar.hbs └── index.js └── package.json /README.md: -------------------------------------------------------------------------------- 1 | 2 | # weather_forecasting 3 | -------------------------------------------------------------------------------- /src/temp/img/new logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Prasadlokhande-880/weather_forecasting/HEAD/src/temp/img/new logo.png -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "openweather", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1" 8 | }, 9 | "author": "", 10 | "license": "ISC", 11 | "dependencies": { 12 | "axios": "^1.4.0", 13 | "express": "^4.18.2", 14 | "hbs": "^4.2.0" 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /src/temp/views/error404.hbs: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 |{{error}}
34 |Return to the homepage.
35 | 36 | 37 | -------------------------------------------------------------------------------- /src/index.js: -------------------------------------------------------------------------------- 1 | const hbs = require("hbs"); 2 | const express = require("express"); 3 | const app = express(); 4 | const path = require("path"); 5 | 6 | const path_view = path.join(__dirname, "temp", "views"); 7 | const path_partials = path.join(__dirname, "temp", "commponents"); 8 | 9 | app.set("view engine", "hbs"); 10 | app.set("views", path_view); 11 | 12 | hbs.registerPartials(path_partials); 13 | 14 | app.get("/", (req, res) => { 15 | res.render("index"); 16 | }); 17 | 18 | app.get("/about", (req, res) => { 19 | res.render("about"); 20 | }); 21 | 22 | app.get("/weather", (req, res) => { 23 | res.render("weather"); 24 | }); 25 | 26 | app.get("/weather/*", (req, res) => { 27 | res.render("error404",{error:"There is no section name as this in weather"}); 28 | }); 29 | 30 | app.get("/about/*", (req, res) => { 31 | res.render("error404",{error:"There is no section name as this in About"}); 32 | }); 33 | 34 | app.get("*", (req, res) => { 35 | res.render("error404",{error:"The page you are looking for does not exist."}); 36 | }); 37 | 38 | 39 | 40 | app.listen(8000, () => { 41 | console.log("The server is listening on port 8000"); 42 | }); 43 | -------------------------------------------------------------------------------- /src/temp/commponents/footer.hbs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 |MONGODB AS DATABASE
171 |
181 | 182 | Current Weather Conditions: Weather forecasting websites display the current temperature, humidity, wind speed, air pressure, and other relevant weather parameters for a specific location. This information helps users understand the current state of the atmosphere. 183 | Weather Forecasts: These websites provide short-term and long-term forecasts. 184 |
185 |
190 | 191 | A database is an organized collection of structured information, or data, typically stored electronically in a computer system. A database is usually controlled by a database management system (DBMS). Together, the data and the DBMS, along with the applications that are associated with them, are referred to as a database system, often shortened to just database. 192 |
193 |
198 | 199 | Our team consists of passionate and dedicated students who are committed to making a positive impact on the world. We believe that by using technology and data to identify health risks, we can help individuals take proactive steps to maintain their health and prevent serious illnesses. 200 |
201 |
206 | 207 | We are constantly updating and improving our platform to ensure that it remains at the forefront of disease prediction technology. We welcome feedback and suggestions from our users, as we strive to provide the most accurate and user-friendly service possible. 208 |
209 |
214 | Thank you for visiting our website and joining us in our mission
215 | to improve health outcomes for individuals and communities.
216 |
Enter your city name
169 | 170 |