-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMainLayout.Master
More file actions
103 lines (96 loc) · 4.96 KB
/
MainLayout.Master
File metadata and controls
103 lines (96 loc) · 4.96 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
<%@ Master Language="C#" AutoEventWireup="true" CodeBehind="MainLayout.Master.cs" Inherits="Bookstore.Site1" %>
<!DOCTYPE html>
<html>
<head runat="server">
<link id="tabIcon" rel="icon" href="/Assets/Logo.png" type="image/png">
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css" rel="stylesheet"/>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
<style>
html, body, form {
height: 100%;
margin: 0;
}
.background {
background: url("Assets/Background.png");
background-size: cover;
background-repeat: no-repeat;
background-position: right;
}
#Logo {
height: 45px;
padding-right: 5px;
}
#txtSearch {
width: 60%;
margin-left: 2%;
margin-right: 2%;
}
.fill-below {
height: calc(100% - 60px); /* 60px = header height */
background-color: #f5f5f5;
}
@media screen and (max-width: 1100px) {
.mobile {
flex-direction: column;
}
#Logo {
height: 25px;
padding-right: 3px;
}
#txtSearch {
width: 60%;
}
#title {
font-size: 12px;
}
.disablemobile {
display: none;
}
}
</style>
<asp:ContentPlaceHolder ID="MASTERHEAD" runat="server"/>
</head>
<body>
<form id="form1" runat="server">
<nav class="navbar navbar-expand-lg navbar-dark bg-dark">
<div class="container-fluid">
<a class="navbar-brand" href="/default.aspx" style="align-items: center; justify-items: center; display: flex; padding: 0;">
<asp:Image ID="Logo" src="/Assets/Logo.png" alt="Example Image" class="img-fluid" runat="server" />
<h5 style="margin: 0;" id="title">BookSmart</h5>
</a>
<asp:TextBox ID="txtSearch" runat="server" CssClass="form-control me-1" placeholder="Search..." aria-label="Search"></asp:TextBox>
<asp:Button ID="btnSearch" runat="server" CssClass="btn btn-primary disablemobile" Text="Search" OnClick="btnSearch_Click"></asp:Button>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav ms-auto">
<li class="nav-item">
<div class="mobile" style="display: flex; align-items: center; gap: 10px;">
<a class="nav-link" href="/contact.aspx" style="display: flex; padding: -10px; font-size: 16px; justify-content: center; width: 100px;">Contact Us</a>
<a class="nav-link" href="/about.aspx" style="display: flex; padding: -10px; font-size: 16px; justify-content: center; width: 90px;">About Us</a>
<asp:PlaceHolder ID="phRegister" runat="server">
<a class="nav-link" href="accounts/register.aspx" style="display: flex; font-size: 16px; border: 1px solid gray; border-radius: 5px; justify-content: center; width: 80px;">Register</a>
</asp:PlaceHolder>
<asp:PlaceHolder ID="phLogin" runat="server">
<a class="nav-link" href="accounts/login.aspx" style="display: flex; font-size: 16px; border: 1px solid gray; border-radius: 5px; justify-content: center; width: 80px;">Login</a>
</asp:PlaceHolder>
<asp:PlaceHolder ID="phProfile" runat="server">
<asp:Button ID="btnLogout" Visible="false" runat="server" Text="Log out" CssClass="btn btn-danger" Style="display: flex; font-size: 14px; border: 1px solid gray; border-radius: 5px; justify-content: center; width: 90px;" OnClick="btnLogout_Click" />
<a class="nav-link" href="profile.aspx" style="display: flex; gap: 5px; border: 1px solid gray; border-radius: 5px; align-items: center;">
<asp:Image ID="pfpavatar" runat="server" Width="30px" Height="30px" Style="border-radius: 50%" />
</a>
</asp:PlaceHolder>
</div>
</li>
</ul>
</div>
</div>
</nav>
<asp:ContentPlaceHolder ID="MASTERCONTENT" runat="server"/>
</form>
<footer class="bg-dark text-white text-center py-2 fixed-bottom">
© 2025 BookSmart. All rights reserved.
</footer>
</body>
</html>