File tree Expand file tree Collapse file tree 9 files changed +548
-0
lines changed Expand file tree Collapse file tree 9 files changed +548
-0
lines changed Original file line number Diff line number Diff line change
1
+ node_modules
Original file line number Diff line number Diff line change
1
+ # Welcome 🖐 to the SURVEY FORM
2
+ It is a simple Survey Form. We can use this form to take feedback from the customers and use it for the betterment.
3
+
4
+
5
+ ## 💻Tech Stack
6
+ <br >
7
+
8
+ ![ HTML] ( https://img.shields.io/badge/html5%20-%23E34F26.svg?&style=for-the-badge&logo=html5&logoColor=white )
9
+ ![ CSS] ( https://img.shields.io/badge/css3%20-%231572B6.svg?&style=for-the-badge&logo=css3&logoColor=white )
10
+ ![ JS] ( https://img.shields.io/badge/javascript%20-%23323330.svg?&style=for-the-badge&logo=javascript&logoColor=%23F7DF1E )
11
+
12
+ <br >
13
+
14
+
15
+ ### How to get the form on your local machine:
16
+
17
+ ---
18
+
19
+ - Download or clone the repository
20
+
21
+ ```
22
+ git clone https://github.com/Ayushparikh-code/Web-dev-mini-projects.git
23
+ ```
24
+
25
+ - Go to the directory
26
+ - Open Survey Form folder
27
+ - Open the terminal and run
28
+ ```
29
+ node app.js
30
+ ```
31
+ - Open * localhost:3000* in your browser.
32
+
33
+ ***
34
+ ###Remember:
35
+ If you are using node then you need to reload your server everytime you make changes in your file. Otherwise if you have nodemon installed, you can use nodemon.
36
+ ***
37
+
38
+ <br >
39
+
40
+ ##Screenshots
41
+
42
+ ![ Demo1] ( public/images/survey-demo1.png )
43
+ <br >
44
+
45
+ ![ Demo2] ( public/images/survey-demo2.png )
46
+ <br >
47
+
48
+
49
+ ## Happy Coding!
Original file line number Diff line number Diff line change
1
+ const express = require ( "express" ) ;
2
+
3
+ const app = express ( ) ;
4
+
5
+ app . use ( express . static ( "public" ) ) ;
6
+
7
+ app . get ( "/" , function ( req , res ) {
8
+ res . sendFile ( __dirname + "/index.html" ) ;
9
+ } ) ;
10
+
11
+ app . post ( "/" , ( req , res ) => {
12
+ res . send ( "<h1> Thankyou for filling up this feedback form. Go back to the previous page =) </h1>" ) ;
13
+ } )
14
+
15
+ app . listen ( 3000 , function ( ) {
16
+ console . log ( "Server started running on port 3000" ) ;
17
+ } )
Original file line number Diff line number Diff line change
1
+ <!DOCTYPE html>
2
+ < html lang ="en ">
3
+ < head >
4
+ < meta charset ="UTF-8 ">
5
+ < meta name ="viewport " content ="width=device-width, initial-scale=1.0 ">
6
+ < link rel ="stylesheet " type ="text/css " href ="css/style.css ">
7
+ < title > Survey Form</ title >
8
+ </ head >
9
+ < body >
10
+ < h1 > Please fill this Survey-Form.</ h1 >
11
+
12
+ < form method ="POST ">
13
+ < div >
14
+ < label for ="name "> < b > Name:</ b > </ label >
15
+ < input type ="text " placeholder ="Enter your name " name ="name " required >
16
+
17
+ < label for ="email "> < b > Email:</ b > </ label >
18
+ < input type ="email " placeholder ="Enter your Email " name ="email " required >
19
+
20
+ < label for ="tel "> < b > Phone Number:</ b > </ label >
21
+ < input type ="number " placeholder ="Enter your Phone Number " name ="phoneNumber " required >
22
+
23
+ < label > < b > How likely is that you would recommend Pizza Ghar to a family member or a friend?</ b > </ label >
24
+ < label > Definately</ label >
25
+ < input type ="radio " name ="same " name ="recommendation ">
26
+ < label > Maybe</ label >
27
+ < input type ="radio " name ="same " name ="recommendation ">
28
+ < label > Not Sure</ label >
29
+ < input type ="radio " name ="same " name ="recommendation ">
30
+
31
+ < label > < b > What do you like most in our Pizzas?</ b > </ label >
32
+ < textarea name ="" id ="" cols ="30 " rows ="5 "> </ textarea >
33
+
34
+ < button type ="submit " class ="btn "> Submit</ button >
35
+ </ div >
36
+ </ form >
37
+
38
+ </ body >
39
+ </ html >
You can’t perform that action at this time.
0 commit comments