diff --git a/public/main.css b/public/main.css index 7f43f7dbc6fa2cf6c65cf871714137d6cf624cca..b8d2be68d3873c40a80da86a03a47a6687aa5f38 100644 --- a/public/main.css +++ b/public/main.css @@ -36,7 +36,7 @@ h6 { p{ font-family: Arial, Helvetica, sans-serif; font-size: 19px; - color: rgb(247, 246, 246); + color: rgb(100, 100, 100); margin: 15px 0 20px 0; } @@ -50,12 +50,15 @@ p{ .body{ - width: 100%; + min-height: 100vh; } .logo{ max-width: 20%; +} +.logo2{ + max-width: 20%; } @@ -141,6 +144,23 @@ p{ font-size: 15px; background-color: #89a53a; padding: 15px 40px; + +} + +#hero a:link { + text-decoration: none; +} + +#hero a:visited { + text-decoration: none; +} + +#hero a:hover { + text-decoration: none; +} + +#hero a:active { + text-decoration: none; } @@ -208,62 +228,75 @@ p{ } +/* Styling the footer */ -/* Listing page css */ - -#items { - text-align: center; - padding-top: 20px; - padding-left: 20px; - - -} - -#items .pro-container{ +footer{ display: flex; - justify-content: space-between; - padding-top: 20px; flex-wrap: wrap; + justify-content: space-between; + position: sticky; + top: 100%; } -#items .pro{ - width: 13%; - min-width: 250px; - padding: 0px 12px; - border: 1px solid #d4cadf; - border-radius: 25px; - cursor: pointer; - box-shadow: 20px 20px 30px rgb(0, 0,0,0.02 ); - transition: 0.2s ease; - position: relative; + +footer .col{ + display: flex; + flex-direction: column; + align-items: flex-start; + margin-bottom: 20px; + margin-right: 200px; } -#items .pro:hover{ - box-shadow: 20px 20px 30px rgb(0, 0,0,0.06 ); - +footer .logo2 { + margin-bottom: 30px; + } -#items .pro .listing{ - width: 100%; - border-radius: 20px; +footer h4{ + font-size: 14px; + padding-bottom: 20px; } -#items .pro .des{ - text-align: start; - padding: 10px 0; + + +footer p{ + font-size: 12px; + padding-bottom: 20px; + margin: 0 0 8px 0; } -#items .pro.des.spam{ - color: #606063; +footer a{ font-size: 12px; + text-decoration: none; + color: #222; + margin: 10px; +} + + + + +/* Listing page css */ + +#items { + text-align: center; + padding-top: 20px; + padding-left: 20px; + display: inline-block; + } +#items .pro-container{ + display: flex; + justify-content: space-between; + padding-top: 20px; + flex-wrap: wrap; +} -#items .pro2{ +#items .pro{ width: 13%; min-width: 250px; - padding: 0px 12px; + padding: 20px 12px; border: 1px solid #d4cadf; border-radius: 25px; cursor: pointer; @@ -283,7 +316,7 @@ p{ } -#items .pro .des{ +#items .pro.des{ text-align: start; padding: 10px 0; } @@ -295,12 +328,26 @@ p{ - - - - - @media (max-width: 799px ){ + + #navbar{ + display: flex; + flex-direction: column; + align-items: flex-start; + justify-content: flex-start; + position: fixed; + top: 0; + right: -300px; + height: 100vh; + width: 300px; + background-color: #d4cadf; + box-shadow: 0 40px 60px rgb(0, 0,0,0.02); + padding: 80px 0 0 10px; + } + + #navbar li { + margin-bottom: 25px ; + } } diff --git a/routes/main.js b/routes/main.js index 2dc3a31bb51a22d950683b550a1c028af95bdc6f..7c6869e1c7e6a077f00470a08c294ded0e3c56cc 100644 --- a/routes/main.js +++ b/routes/main.js @@ -39,6 +39,10 @@ module.exports = function(app, shopData) { res.render('itemlist.ejs', shopData) }); + app.get('/listingdone',function(req,res){ + res.render('/listingdone.ejs', shopData) + }); + app.get('/search-result',[check('name').isEmpty()],function (req, res) { @@ -54,7 +58,7 @@ module.exports = function(app, shopData) { if (err) { res.redirect('./'); } - let newData = Object.assign({}, shopData, {availableItem:result}); + let newData = Object.assign({}, shopData, {listingAdded:result}); console.log(newData) res.render("itemlisted.ejs", newData) }); @@ -72,30 +76,31 @@ module.exports = function(app, shopData) { username = req.session.userId; image =req.file.buffer.toString("base64"); - let sqlquery ="INSERT INTO items (title,name,price,info,condi,img,username) VALUES(?,?,?,?,?,?,?)"; + let sqlquery ="INSERT INTO items(title,name,price,info,condi,img,username) VALUES(?,?,?,?,?,?,?)"; let newListing = [req.sanitize(title),req.sanitize(product), req.sanitize(price),req.sanitize(info), - req.sanitize(condition),req.sanitize(image),username] + req.sanitize(condition),image,username] db.query(sqlquery, newListing,(err, result) => { if (err){ return console.error(err.message); } else{ - let newData = Object.assign({}, shopData, {listingAdded: result}); - res.render("itemlisted.ejs", newData) + + let newData = Object.assign({}, shopData, {listingAdded: newListing}); + res.render("listingdone.ejs", newData) } }); - }); app.get('/itemlisted',function(req,res){ + let sqlquery = "SELECT * FROM items"; // query database to get all the books // execute sql query - db.query(sqlquery, (err, result) => { + db.query(sqlquery,(err, result) => { if (err) { res.redirect('./'); } diff --git a/views/about.ejs b/views/about.ejs index eaa9f6082cbb2f186a9e8c39ec3e7ecd6af76429..658c31df99e5b355e110a916a6f3ac16f68d31e5 100644 --- a/views/about.ejs +++ b/views/about.ejs @@ -12,6 +12,7 @@ <div> <ul id="navbar"> <li><a href="about">About </a></li> + <li><a href="itemlisted">Explore</a></li> <li><a href="search">Search </a></li> <li><a href="itemlist">List </a></li> <li><a href="register">Register </a></li> @@ -22,6 +23,39 @@ </section> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> + </body> diff --git a/views/correct.ejs b/views/correct.ejs index 6cd81cf48ed0239060bfe3f48a516ae13df60df7..55436833aee498432acffba235f94e828a1eaec2 100644 --- a/views/correct.ejs +++ b/views/correct.ejs @@ -6,8 +6,59 @@ <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.15.4/css/all.css"/> </head> <body> + <section id = "header"> + <a href="/."> <img src = "/public/logo.png" class ="logo" alt = ""> </a> + <div> + <ul id="navbar"> + <li><a href="about">About </a></li> + <li><a href="/itemlisted">Explore</a></li> + <li><a href="search">Search </a></li> + <li><a href="itemlist">List </a></li> + <li><a href="register">Register </a></li> + <li><a href="login">Login</a></li> + <li><a href="logout">Logout</a></li> + </ul> + </div> + </section> + + <h1> <%=shopName%></h1> - <p>Correct Password</p> - <p><a href="/">Home Page</a></p> + <h3>Correct Password</h3> + <h3><a href="/">Home Page</a></h3> + + + + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> </html> \ No newline at end of file diff --git a/views/incorrect.ejs b/views/incorrect.ejs index 215d4e97b1544b83b5bbd3f2ce72d6fa59f5fffb..e7531a38cad7d159134d4590d778cf3327fb924c 100644 --- a/views/incorrect.ejs +++ b/views/incorrect.ejs @@ -9,5 +9,38 @@ <h1>Error <%=shopName%></h1> <p>Incorrect Username or password</p> <p><a href="login">Login page</a></p> + + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> </html> \ No newline at end of file diff --git a/views/index.ejs b/views/index.ejs index 6c901b76f31608b29d055f4b9830ae50cf42f521..509fc562af97ce8a06e2b57359f0c9acb99dee5c 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -12,6 +12,7 @@ <div> <ul id="navbar"> <li><a href="about">About </a></li> + <li><a href="/itemlisted">Explore</a></li> <li><a href="search">Search </a></li> <li><a href="itemlist">List </a></li> <li><a href="register">Register </a></li> @@ -19,6 +20,9 @@ <li><a href="logout">Logout</a></li> </ul> </div> + <div id="mobile"> + <i id= "bar" class="fas fa-outdent"></i> + </div> </section> <section id ="hero"> @@ -30,7 +34,7 @@ <p> For a more sustainable future</p> - <button> Explore now</button> + <a href="/itemlisted" class="a"><button> Explore now</button></a> </section> @@ -66,9 +70,38 @@ </section> - <section id = ""> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> - </section> + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> diff --git a/views/itemlist.ejs b/views/itemlist.ejs index 3ecb1c46f53db6580c8976c4e21cb9a94e1a1622..a0e271701701f3664f84f212506032072f25a403 100644 --- a/views/itemlist.ejs +++ b/views/itemlist.ejs @@ -5,21 +5,67 @@ <link rel="stylesheet" type="text/css" href="main.css" /> <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.15.4/css/all.css"/> </head> + <section id = "header"> + <a href="/."> <img src = "/public/logo.png" class ="logo" alt = ""> </a> + <div> + <ul id="navbar"> + <li><a href="about">About </a></li> + <li><a href="itemlisted">Explore</a></li> + <li><a href="search">Search </a></li> + <li><a href="itemlist">List </a></li> + <li><a href="logout">Logout</a></li> + </ul> + </div> +</section> + <body> <h1>List on <%=shopName%></h1> - <form method ="POST" enctype="multipart/form-data" action = "photoDB"> - <input type = "text" placeholder="Title of product" name = "title"> - <input type = "text" placeholder="Name of product" name = "name"> - <input type = "text" placeholder="Cost of shipping" name = "price"> - <input type = "text" placeholder="Information" name = "info"> - <input type = "text" placeholder="Condition of product" name = "condition"> - <input type = "file" name = "ProductImage"> - <button class = "button"> List </button> + <form method ="POST" enctype="multipart/form-data" action = "/photoDB"> + <h3>Title of product <input type = "text" placeholder="" name = "title"></h3> + <h3>Name of product <input type = "text" placeholder="" name = "name"></h3> + <h3>Cost of shipping <input type = "text" placeholder="" name = "price"></h3> + <h3>Information <input type = "text" placeholder="" name = "info"></h3> + <h3>Condition of product <input type = "text" placeholder="" name = "condition"></h3> + <h3><input type = "file" name = "ProductImage"></h3> + <h3><button class = "button"> List </button></h3> </form> <!-- Redirects to home page --> - <p><a href="/">home page</a></p> + <p><a href="/">Home page</a></p> + + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> </html> \ No newline at end of file diff --git a/views/itemlisted.ejs b/views/itemlisted.ejs index 7334486413cd5a13781ed6c5bfc6b914db6aec35..50d71977df2146dc130c3f3cdee63705ebf6eee1 100644 --- a/views/itemlisted.ejs +++ b/views/itemlisted.ejs @@ -12,6 +12,7 @@ <div> <ul id="navbar"> <li><a href="about">About </a></li> + <li><a href="itemlisted">Explore</a></li> <li><a href="search">Search </a></li> <li><a href="itemlist">List </a></li> <li><a href="logout">Logout</a></li> @@ -19,21 +20,21 @@ </div> </section> - <section id = "items" class="section-p2"> - <%listingAdded.forEach(function(list){%> + <section id = "items"> + <% listingAdded.forEach(function(list){%> <div class = "pro-container"> <div class = "pro"> - <img alt=" Embedded Image" src = "data:image/png;base64,<%=list.img%>" class="listing"> + <img alt= "Embedded Image" src = "data:image/png;base64,<%=list.img%>" class="listing"> <div class = "des"> - <span><%=list.username%></span> - <h5><%=list.title%></h5> - <h5><%=list.condi%></h5> - <h4><%=list.price%></h4> + <span>Listed by: <%=list.username%></span> + <h5> <%=list.title%> </h5> + <h5> Condition of item: <%=list.condi%></h5> + <h4> Shipping: £ <%=list.price%></h4> </div> <a href="#"> <i class="fa-sharp fa-solid fa-cart-shopping fa-beat"></i></i></i></a> + </div> </div> - </div> - <% })%> + <%})%> </section> @@ -42,6 +43,38 @@ + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> diff --git a/views/listingdone.ejs b/views/listingdone.ejs new file mode 100644 index 0000000000000000000000000000000000000000..aa01879907bdbaeee8785582383100c00ac853f7 --- /dev/null +++ b/views/listingdone.ejs @@ -0,0 +1,45 @@ +<!doctype html> +<html lang="en"> + <head> + <title> You have added a new listing on <%=shopName%></title> + <!-- Linking my CSS --> + <link rel="stylesheet" type="text/css" href="main.css" /> + </head> + <body> + <h1>You have successfully added a new listing on <%=shopName%></h1> + + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> + </body> + <p><a href="/">home page</a></p> +</html> \ No newline at end of file diff --git a/views/loggedout.ejs b/views/loggedout.ejs index 615e5569e065c9869cfcaaff3bf57925991b410b..c4504865bc08518c4aa4c1d08622afb8cef586a3 100644 --- a/views/loggedout.ejs +++ b/views/loggedout.ejs @@ -9,5 +9,37 @@ <h1> <%=shopName%> </h1> <p>You are now logged out.</p> <p><a href="/">Home Page</a></p> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> </html> \ No newline at end of file diff --git a/views/login.ejs b/views/login.ejs index 194aa640ec27deda39f55faf4610ea526e24b147..862d52272dee2f60c1d2b9e4c741b299dccb0e2e 100644 --- a/views/login.ejs +++ b/views/login.ejs @@ -21,10 +21,42 @@ <h2>Login for <%=shopName%></h2> <form method="POST" action="/loggedin"> - <p>Username: <input id="username" type="username" name="username" value="" /></p> - <p>Password: <input id="password" type="password" name="password" value="" /></p> + <h3>Username: <input id="username" type="username" name="username" value="" /></h3> + <h4>Password: <input id="password" type="password" name="password" value="" /></h4> <input type="submit" value="login" /> </form> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> diff --git a/views/register.ejs b/views/register.ejs index fabd0ef32c645f617393e929e300bf816951edad..e8270ecc19b1eaea6d07f51f30af07d916d1c37d 100644 --- a/views/register.ejs +++ b/views/register.ejs @@ -17,5 +17,37 @@ </form> <!-- Redirects to home page --> <p><a href="/">home page</a></p> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> </html> \ No newline at end of file diff --git a/views/registered.ejs b/views/registered.ejs index c2aea3a59a6fb482309923db1dbd1af2525618a0..77480f463924cdea03b635e311665889a31df704 100644 --- a/views/registered.ejs +++ b/views/registered.ejs @@ -9,6 +9,39 @@ <p>Hello <%=newUser[1]%> <%=newUser[2]%>, you are now registered! We will send an email to you at <%=newUser[3]%>. Your hashed password is <%=newUser[4]%> </p> </body> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> <!-- Redirects to home page --> <p><a href="/">home page</a></p> + </html> \ No newline at end of file diff --git a/views/search.ejs b/views/search.ejs index 1491b321221cd5db8f510a99c2ee27194145ad58..f47aead07b9934d2f4170433b2ff3d29db81b168 100644 --- a/views/search.ejs +++ b/views/search.ejs @@ -14,5 +14,37 @@ </form> <!-- Redirects to home page --> <p><a href="/">home page</a></p> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body> </html> \ No newline at end of file diff --git a/views/singleproduct.ejs b/views/singleproduct.ejs new file mode 100644 index 0000000000000000000000000000000000000000..1c4817f5617db4d0852ea7f25fc5400df15cd8ae --- /dev/null +++ b/views/singleproduct.ejs @@ -0,0 +1,57 @@ +<!doctype html> +<html> + <head> + <title><%=shopName%></title> + <link rel="stylesheet" type="text/css" href="main.css" /> + <script src="https://kit.fontawesome.com/ad1bd830b9.js" crossorigin="anonymous"></script> + </head> + <body> + + <section id = "header"> + <a href="/."> <img src = "/public/logo.png" class ="logo" alt = ""> </a> + <div> + <ul id="navbar"> + <li><a href="about">About </a></li> + <li><a href="itemlisted">Explore</a></li> + <li><a href="search">Search </a></li> + <li><a href="itemlist">List </a></li> + <li><a href="logout">Logout</a></li> + </ul> + </div> + </section> + + <section id = "items"> + <% listingAdded.forEach(function(list){%> + <div class = "pro-container"> + <div class = "pro"> + <img alt= "Embedded Image" src = "data:image/png;base64,<%=list.img%>" class="listing"> + <div class = "des"> + <span>Listed by: <%=list.username%></span> + <h5> <%=list.title%> </h5> + <h5> Condition of item: <%=list.condi%></h5> + <h4> Shipping: £ <%=list.price%></h4> + </div> + <a href="#"> <i class="fa-sharp fa-solid fa-cart-shopping fa-beat"></i></i></i></a> + </div> + </div> + <%})%> + + + </section> + + + + + + + + + + + + + + </body> + + +</html> \ No newline at end of file diff --git a/views/stock.ejs b/views/stock.ejs index 790f06fd97b6cac6db09f63be9bb6870395d721e..476f645c91f7ee326687827ba9781ff03f553501 100644 --- a/views/stock.ejs +++ b/views/stock.ejs @@ -18,6 +18,38 @@ </ul> </div> </section> + <footer class = "section-p1"> + <div class = "col"> + <img class="logo2" src="/public/logo.png" alt=""> + <h4>Contact</h4> + <p><strong> Address: </strong> 92 New Street London NW06 9ZS</p> + <p><strong> Hours: </strong> 12:00 - 18:00, Mon-Friday</p> + </div> + <div class="col"> + <h4> About </h4> + <a href="#">About us</a> + <a href="#">Privacy Policy</a> + <a href="#">Terms & Conditions</a> + <a href="#">Contact Us</a> + </div> + + <div class="col"> + <h4> My Account </h4> + <a href="#">Sign in</a> + <a href="#">View Cart</a> + <a href="#">Track My Order</a> + </div> + + + <div class="col"> + <h4> Selling on Re-turn </h4> + <a href="#">Sellers Protection</a> + <a href="#">Sellers Fees</a> + <a href="#">Selling Basics</a> + <a href="#">Selling Guide</a> + </div> + + </footer> </body>