Permalink
Browse files

better html(5) and css

  • Loading branch information...
1 parent a4ce456 commit 7845728927826962faad7b3c84e5b2ca26db1fad @pascalchevrel pascalchevrel committed Oct 31, 2012
Showing with 98 additions and 118 deletions.
  1. +55 −65 index.php
  2. +43 −53 style/main.css
View
120 index.php
@@ -3,28 +3,28 @@
include_once 'controller.inc.php';
?>
-
+<!DOCTYPE html>
<html>
<head>
- <meta http-equiv="content-type" content="text/html; charset=UTF-8"><!-- -->
- <link rel="icon" href="https://l10n-stage-sj.mozilla.org/favicon.ico" type="image/x-icon">
-
+ <meta charset="UTF-8">
<title>L10n Bug helper</title>
<script type="text/javascript" src="<?=$bugzilla_url?>config.cgi"></script>
<script>
var selectedProduct;
function toggleLocales(chk) {
- if (chk.checked == 1)
- {document.getElementById('locales').style.display = 'none';}
- else {document.getElementById('locales').style.display = 'block';}
+ if (chk.checked == 1) {
+ document.getElementById('locales').style.display = 'none';
+ } else {
+ document.getElementById('locales').style.display = '';
+ }
}
function updateProduct() {
var blah = document.getElementById('product-select').selectedIndex;
selectedProduct = document.getElementById('product-select').options[blah].text;
updateComponent();
updateVersion();
}
-
+
function updateComponent() {
var tempArray = component[selectedProduct];
var compSelect = document.getElementById('component-select');
@@ -52,77 +52,67 @@ function updateVersion() {
</head>
<body>
- <div id="menu">
- <div id="auth"><!-- -->
- <a onclick="$('#site_login').show();$(this).hide(); $('#id_username').focus(); return false;" href="">Log in</a>
-
- <form style="display: none;" onsubmit="return submit_site_login();" id="site_login" method="POST" action="/accounts/login"><input name="next" value="" type="hidden"><ul><li><label for="id_username">Username:</label> <input id="id_username" name="username" maxlength="75" type="text"></li>
- <li><label for="id_password">Password:</label> <input name="password" id="id_password" type="password"></li><li><input value="OK" type="submit"></li></ul></form>
- </div>
- <ul>
- <li>Mozilla Localization</li>
- <li><a href="https://l10n-stage-sj.mozilla.org/">Home</a></li>
- <li><a href="https://l10n-stage-sj.mozilla.org/teams/">Teams</a></li>
- <li><a href="https://wiki.mozilla.org/L10n">Documentation</a></li>
- </ul>
- <br>
- </div>
-
<div id="main-content">
- <div class="main-input" style="width: 550px;">
+ <div class="main-input">
<h2>Bugzilla C3PO</h2>
+
<form name="bugzilla" action="bugsfiled.php" method="post">
- <div><span class="text">Username:</span><span><input type="text" name="username" /></span></div>
- <div><span class="text">Password:</span><span><input type="password" name="pwd" /></span></div>
-
- <div>
- <span class="text">Product:</span>
- <span><select id="product-select" name="product" onchange="updateProduct()">
- <option default>Select a product</option>
+ <fieldset>
+ <label class="text">Username:</label><input type="text" name="username" /><br/>
+ <label class="text">Password:</label><input type="password" name="pwd" />
+ </fieldset>
+
+ <fieldset>
+ <label class="text">Product:</label>
+ <select id="product-select" name="product" onchange="updateProduct()">
+ <option value="null">Select a product</option>
<script>
for(var product in component) {
document.write('<option value=' + product + '>' + product + '</option>');
}
</script>
- </select></span>
- </div>
- <div>
- <span class="text">Component:</span>
- <span><select id="component-select" name="component">
- <option value="null">Select component</option>
- </select></span>
- </div>
- <div>
- <span class="text">Version:</span>
- <span><select id="version-select" name="version">
- <option value="null">Select version</option>
- </select></span>
- </div>
-
- <div><span class="text">Assign to:</span><span><input type="text" name="assign_to" /></span></div>
- <div><span class="text">Blocks:</span><span><input type="text" name="blocked" /></span></div>
- <div><span class="text">Whiteboard:</span><span><input type="text" name="whiteboard" /></span></div>
- <div><span class="text">URL:</span><span><input type="text" name="url" /></span></div>
- <div>
- <span class="text">List of locales:</span>
- <span><input id="locales" type="text" name="locales" /></span>
- <span><input style="text-align: right;" onclick="toggleLocales(this);" type="checkbox" name="all-locales" value="all" /> All locales</span>
- </div>
- <div><span class="text">Summary:</span><span><input type="text" name="summary" /></span></div>
- <span class="text">Description:</span>
- <div>
- <textarea name="description" rows="10" cols="80" />Write in your bug description here...</textarea>
- </div>
+ </select>
+ <br/>
+ <label class="text">Component:</label>
+ <select id="component-select" name="component">
+ <option value="null">Select component</option>
+ </select>
+ <br/>
+ <label class="text">Version:</label>
+ <select id="version-select" name="version">
+ <option value="null">Select version</option>
+ </select>
+
+ </fieldset>
+
+ <fieldset>
+
+ <label class="text">Assign to: </label><input type="text" name="assign_to" /><br/>
+ <label class="text">Blocks: </label><input type="text" name="blocked" /><br/>
+ <label class="text">Whiteboard: </label><input type="text" name="whiteboard" /><br/>
+ <label class="text">URL: </label><input type="text" name="url" /><br/>
+ <label class="text">List of locales:</label><input id="locales" type="text" name="locales" /><br/>
+ <input onclick="toggleLocales(this);" type="checkbox" name="all-locales" value="all" />
+ <label>All mozilla.org locales</label>
+ <input type="checkbox" name="tag" value="URGENT" />
+ <label>URGENT</label>
+
+ </fieldset>
+
+ <fieldset>
+
+ <label class="text">Summary:</label><input type="text" name="summary" /><br/>
+ <label class="text">Description:</label>
+ <textarea name="description" rows="20" placeholder="Write in your bug description here..." /></textarea>
+ </fieldset>
+
<div class="submit"><input type="submit" value="Submit" /></div>
</form>
</div>
</div>
- <div id="page_footer">
- <a href="https://l10n-stage-sj.mozilla.org/privacy/">Privacy policy</a>
- </div>
</body>
-
+
</html>
View
@@ -1,53 +1,43 @@
- #menu {
- margin: 0 0 2em;
- padding: 10px;
- font-size: small;
- font-style: italic;
- line-height: 1em;
- background-color: #eee;
- -moz-border-radius: .5em;
- }
- #menu ul {
- list-style: none;
- float: left;
- margin: 0;
- padding: 0;
- }
- #menu li {
- float: left;
- margin: 0 10px;
- }
- #menu br {
- clear: both;
- }
- #auth {
- float: right;
- }
- #page_footer {
- margin-top: 2em;
- padding: 10px;
- font-size: small;
- font-style: italic;
- line-height: 1em;
- background-color: #eee;
- -moz-border-radius: .5em;
- }
- div.buglink {
- float: left;
- padding: 2px;
- }
- #show-extra-fields small {
- color: blue;
- padding: 2px 3px;
- background-color: #eee;
- }
- #show-extra-fields small:hover {
- cursor: pointer;
- }
- .extra-field {
- display: none;
- }
- .text {
- display: inline-block;
- width: 300px;
- }
+body {
+ background:white;
+}
+
+.main-input {
+ width:800px;
+ margin: auto;
+}
+
+fieldset {
+ margin: 10px;
+ padding:10px 15px;
+ border: 1px outset rgb(200,200,255);
+ background-color: rgb(220,220,255);
+}
+
+label {
+ display: inline-block;
+ width:180px;
+}
+
+input {
+ margin-left:5px;
+ width: 450px;
+ display: inline-block;
+}
+
+input[type="submit"] {
+ float:right;
+ margin-top:5px;
+}
+
+input[name="summary"] {
+ width: 100%;
+}
+
+textarea {
+ width: 100%;
+}
+
+select {
+ min-width: 200px;
+}

0 comments on commit 7845728

Please sign in to comment.