-
Notifications
You must be signed in to change notification settings - Fork 0
/
converter.html
195 lines (179 loc) · 7.09 KB
/
converter.html
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
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
<!DOCTYPE html>
<head> <!-- Head contents part of gridsystem. Stylesheets my own -->
<title>Wonderful World of Baking</title>
<meta charset="utf-8">
<meta name="description" content="This website is about baking. It has a few recipes, a converter and a list of substitutions">
<meta name="keywords" content="baking, recipes, converter, substitutions">
<meta name="author" content="Edel Smullen using the grid by www.grahamrobertsonmiller.co.uk">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- Stylesheets -->
<link rel="stylesheet" href="css+js/style.css" media="all">
<link rel="stylesheet" href="css+js/col.css" media="all">
<link href='https://fonts.googleapis.com/css?family=Dancing+Script' rel='stylesheet' type='text/css' />
<link href='https://fonts.googleapis.com/css?family=Petrona' rel='stylesheet' type='text/css' />
<style type="text/css">
</style>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="css+js/script.js"></script>
</head>
<body>
<div class="wrapper">
<div class="section group">
<div class="col span_12_of_12">
<header>Wonderful World of Baking <span class="tablettrigger"><img src="images/logo.jpg" alt="hamburger"></span></header>
<!-- the tablettrigger class is for the navigation on tablet version-->
</div>
</div>
<div class="section group">
<span class="trigger"><img src="images/menulogo.jpg" alt="hamburger"></span> <!-- Trigger class for mobile navigation-->
<nav class="col span_12_of_12">
<ul>
<li><a href="index.html">Home</a></li>
<li><a href="basics.html">Basics</a></li>
<li><a href="converter.html">Converter</a></li>
<li><a href="recipes.html">Recipes</a></li>
<li><a href="substitutions.html">Substitutions</a></li>
<li><a href="contact.html">Contact</a></li>
</ul>
</nav>
</div>
<div class="breadcrumb">
<a href="index.html">Home</a> >
Converter
</div>
<div class="spacer">
<br>
</div>
<div class="section group">
<div class="col span_3_of_12">
<br>
</div>
<div class="col span_6_of_12 background">
<h3>Converter</h3>
<table id="converter"> <!-- a converter from one unit to anther -->
<form action="" method="post">
<tr class="from">
<td>From:</td>
<td>
<select name="unit1" id="unit1"> <!-- user selects the unit they are going from -->
<option value="Null">Select a unit</option>
<option value="unit">--Weight--</option>
<option value="pounds">Pounds</option>
<option value="ounce">Ounces</option>
<option value="grams">Grams</option>
<option value="kg">Kgs</option>
<option value="unit">--Volume--</option>
<option value="ml">Millilitres</option>
<option value="litres">Litres</option>
<option value="floz">Fluid ounces</option>
<option value="tsp">Teaspoons</option>
<option value="tbsp">Tablespoons</option>
<option value="unit">--Length--</option>
<option value="mm">Millimetres</option>
<option value="cm">Centimetres</option>
<option value="in">Inches</option>
<option value="unit">--Temperature--</option>
<option value="celsius">Celsius</option>
<option value="fahrenheit">Fahrenheit</option>
</select>
</td>
<td> </td>
<td><input type="text" name="value1" id="value1" placeholder="0"></td> <!-- user enters a value for the unit they are going from-->
</tr>
<tr>
<td colspan="4"><br></td>
</tr>
<tr class="to">
<td>To:</td>
<td>
<select name="unit2" id="unit2"> <!-- user selects the unit they are going from -->
<option value="Null">Select a unit</option>
<option value="unit">--Weight--</option>
<option value="pounds">Pounds</option>
<option value="ounce">Ounces</option>
<option value="grams">Grams</option>
<option value="kg">Kgs</option>
<option value="unit">--Volume--</option>
<option value="ml">Millilitres</option>
<option value="litres">Litres</option>
<option value="floz">Fluid ounces</option>
<option value="tsp">Teaspoons</option>
<option value="tbsp">Tablespoons</option>
<option value="unit">--Length--</option>
<option value="mm">Millimetres</option>
<option value="cm">Centimetres</option>
<option value="in">Inches</option>
<option value="unit">--Temperature--</option>
<option value="celsius">Celsius</option>
<option value="fahrenheit">Fahrenheit</option>
</select>
</td>
<td> </td>
<td><input type="text" name="value2" id="value2" placeholder="0"></td> <!-- user can enter a value but it won't do anything. Answer written here-->
</tr>
<tr><td colspan="4"><br></td></tr>
<tr><td colspan="3"></td>
<td><button type="button" class="button" onclick="myConvert()">Convert</button></td></tr><!-- when the button is clicked, the javascript is implemented-->
</form>
</table>
</div>
<div class="col span_3_of_12">
<br>
</div>
</div>
<div class="spacer">
<br>
</div>
<div class="section group">
<div class="col span_2_of_12">
<br>
</div>
<div class="col span_8_of_12" id="convert_text">
<b>A note on converting to and from cups</b><br><br>
When converting with cups, it depends on whether the ingredient is flour, sugar, butter or a liquid as the volume is the same but the weight is different. Below is a guide for converting with cups. <br>
A full guide can be found at <a href="http://www.allrecipes.com/howto/cup-to-gram-conversions">Cup conversions</a><br>
<br>
<table id="cups">
<tr><th> </th>
<th>All-purpose flour</th>
<th>Butter</th>
<th>White sugar</th>
<th>Brown sugar</th>
</tr>
<tr><td>1 cup</td>
<td>128g</td>
<td>226g</td>
<td>201g</td>
<td>220</td>
</tr>
<tr><td>1/2 cup</td>
<td>64g</td>
<td>113g</td>
<td>100g</td>
<td>110</td>
</tr>
<tr><td>1/4 cup</td>
<td>32g</td>
<td>57g</td>
<td>50g</td>
<td>55</td>
</tr>
</table>
<br>
<p id="measure"><b>Measurements</b><br>I have included below a video on the proper way to measure out ingredients.</p>
<br>
<iframe src="https://www.youtube.com/embed/2R2ptMb7ygk" frameborder="0" allowfullscreen></iframe><!-- added iframe to give easy access to a video on measuring ingredients-->
<br>
</div>
<div class="col span_2_of_12">
<br>
</div>
<div class="section group">
<footer class="col span_12_of_12">
<b>© 2015 Edel Smullen</b>
</footer>
</div>
</div>
</div>
</body>
</html>