how to create a professional website

Solutions on MaxInterview for how to create a professional website by the best coders in the world

showing results for - "how to create a professional website"
Jazmín
28 May 2018
1<html>
2<head>
3<meta name="viewport" content="width=device-width, initial-scale=1">
4<style>
5* {box-sizing: border-box}
6body {font-family: Verdana, sans-serif; margin:0}
7.mySlides {display: none}
8img {vertical-align: middle;}
9
10/* Slideshow container */
11.slideshow-container {
12  max-width: 1000px;
13  position: relative;
14  margin: auto;
15}
16
17/* Next & previous buttons */
18.prev, .next {
19  cursor: pointer;
20  position: absolute;
21  top: 50%;
22  width: auto;
23  padding: 16px;
24  margin-top: -22px;
25  color: white;
26  font-weight: bold;
27  font-size: 18px;
28  transition: 0.6s ease;
29  border-radius: 0 3px 3px 0;
30  user-select: none;
31}
32
33/* Position the "next button" to the right */
34.next {
35  right: 0;
36  border-radius: 3px 0 0 3px;
37}
38
39/* On hover, add a black background color with a little bit see-through */
40.prev:hover, .next:hover {
41  background-color: rgba(0,0,0,0.8);
42}
43
44/* Caption text */
45.text {
46  color: #f2f2f2;
47  font-size: 15px;
48  padding: 8px 12px;
49  position: absolute;
50  bottom: 8px;
51  width: 100%;
52  text-align: center;
53}
54
55/* Number text (1/3 etc) */
56.numbertext {
57  color: #f2f2f2;
58  font-size: 12px;
59  padding: 8px 12px;
60  position: absolute;
61  top: 0;
62}
63
64/* The dots/bullets/indicators */
65.dot {
66  cursor: pointer;
67  height: 15px;
68  width: 15px;
69  margin: 0 2px;
70  background-color: #bbb;
71  border-radius: 50%;
72  display: inline-block;
73  transition: background-color 0.6s ease;
74}
75
76.active, .dot:hover {
77  background-color: #717171;
78}
79
80/* Fading animation */
81.fade {
82  -webkit-animation-name: fade;
83  -webkit-animation-duration: 1.5s;
84  animation-name: fade;
85  animation-duration: 1.5s;
86}
87
88@-webkit-keyframes fade {
89  from {opacity: .4} 
90  to {opacity: 1}
91}
92
93@keyframes fade {
94  from {opacity: .4} 
95  to {opacity: 1}
96}
97
98/* On smaller screens, decrease text size */
99@media only screen and (max-width: 300px) {
100  .prev, .next,.text {font-size: 11px}
101}
102</style>
103</head>
104<body>
105
106<div class="slideshow-container">
107
108<div class="mySlides fade">
109  <div class="numbertext">1 / 3</div>
110  <img src="img_nature_wide.jpg" style="width:100%">
111  <div class="text">Caption Text</div>
112</div>
113
114<div class="mySlides fade">
115  <div class="numbertext">2 / 3</div>
116  <img src="img_snow_wide.jpg" style="width:100%">
117  <div class="text">Caption Two</div>
118</div>
119
120<div class="mySlides fade">
121  <div class="numbertext">3 / 3</div>
122  <img src="img_mountains_wide.jpg" style="width:100%">
123  <div class="text">Caption Three</div>
124</div>
125
126<a class="prev" onclick="plusSlides(-1)">&#10094;</a>
127<a class="next" onclick="plusSlides(1)">&#10095;</a>
128
129</div>
130<br>
131
132<div style="text-align:center">
133  <span class="dot" onclick="currentSlide(1)"></span> 
134  <span class="dot" onclick="currentSlide(2)"></span> 
135  <span class="dot" onclick="currentSlide(3)"></span> 
136</div>
137
138<script>
139var slideIndex = 1;
140showSlides(slideIndex);
141
142function plusSlides(n) {
143  showSlides(slideIndex += n);
144}
145
146function currentSlide(n) {
147  showSlides(slideIndex = n);
148}
149
150function showSlides(n) {
151  var i;
152  var slides = document.getElementsByClassName("mySlides");
153  var dots = document.getElementsByClassName("dot");
154  if (n > slides.length) {slideIndex = 1}    
155  if (n < 1) {slideIndex = slides.length}
156  for (i = 0; i < slides.length; i++) {
157      slides[i].style.display = "none";  
158  }
159  for (i = 0; i < dots.length; i++) {
160      dots[i].className = dots[i].className.replace(" active", "");
161  }
162  slides[slideIndex-1].style.display = "block";  
163  dots[slideIndex-1].className += " active";
164}
165</script>
166
167  <!--use your own text and images-->
168</body>
169</html>
similar questions
queries leading to this page
how to create a professional website