Tidying up the inputs

This commit is contained in:
Tom Slominski
2015-03-06 14:49:02 +00:00
parent e583a73009
commit bcd6bb68a0
2 changed files with 29 additions and 6 deletions

View File

@@ -10,10 +10,25 @@ $title = isset( $_REQUEST['title'] ) ? yourls_sanitize_title( $_REQUEST['title
<h2><?php yourls_e( 'Enter a new URL to shorten', 'isq_translation'); ?></h2> <h2><?php yourls_e( 'Enter a new URL to shorten', 'isq_translation'); ?></h2>
<h3><?php yourls_e( 'Hover over the labels to see more information', 'isq_translation'); ?></h3> <h3><?php yourls_e( 'Hover over the labels to see more information', 'isq_translation'); ?></h3>
<form method="post" action="result.php"> <form method="post" action="result.php">
<p><label for="url" title="<?php yourls_e( 'Paste the long URL here', 'isq_translation'); ?>"><?php yourls_e( 'Long URL (required):', 'isq_translation'); ?></label> <input type="text" id="url" class="right" name="url" value="<?php echo($url); ?>" /></p> <div class="full-width">
<p><label for="keyword" title="<?php yourls_e( 'A keyword replaces the default short string', 'isq_translation'); ?>"><?php yourls_e( 'Custom keyword:', 'isq_translation'); ?></label> <input type="text" id="keyword" class="right" name="keyword" value="<?php echo($keyword); ?>" /></p> <label for="url" title="<?php yourls_e( 'Paste the long URL here', 'isq_translation'); ?>"><?php yourls_e( 'Long URL (required):', 'isq_translation'); ?></label>
<p><label for="title" title="<?php yourls_e( 'Optional title used when sharing a link from YOURLS using social sharers', 'isq_translation'); ?>"><?php yourls_e( 'Optional title:', 'isq_translation'); ?></label> <input type="text" id="title" class="right" name="title" value="<?php echo($title); ?>" /></p> <input type="url" id="url" name="url" value="<?php echo($url); ?>" />
<div class="recaptcha-container"><label title="<?php yourls_e( 'Verification used to ensure the user is not a bot', 'isq_translation'); ?>"><?php yourls_e( 'reCAPTCHA:', 'isq_translation'); ?></label> <div class="g-recaptcha right" data-sitekey="<?php echo ISQ::$recaptcha['sitekey']; ?>"></div></div> </div>
<div class="half-width">
<label for="keyword" title="<?php yourls_e( 'A keyword replaces the default short string', 'isq_translation'); ?>"><?php yourls_e( 'Custom keyword:', 'isq_translation'); ?></label>
<input type="text" id="keyword" name="keyword" value="<?php echo($keyword); ?>" />
</div>
<div class="half-width">
<label for="title" title="<?php yourls_e( 'Optional title used when sharing a link from YOURLS using social sharers', 'isq_translation'); ?>"><?php yourls_e( 'Optional title:', 'isq_translation'); ?></label>
<input type="text" id="title" value="<?php echo($title); ?>" />
</div>
<div class="recaptcha-container">
<label title="<?php yourls_e( 'Verification used to ensure the user is not a bot', 'isq_translation'); ?>"><?php yourls_e( 'reCAPTCHA:', 'isq_translation'); ?></label>
<div class="g-recaptcha" data-sitekey="<?php echo ISQ::$recaptcha['sitekey']; ?>"></div>
</div>
<p><input type="submit" value="<?php yourls_e( 'Shorten', 'isq_translation'); ?>" /></p> <p><input type="submit" value="<?php yourls_e( 'Shorten', 'isq_translation'); ?>" /></p>
</form> </form>

View File

@@ -100,8 +100,16 @@ a, a:visited {
} }
/* Forms */ /* Forms */
.recaptcha-container { input:not([type=submit]):not([type=file]) {
overflow: hidden; padding: 10px;
}
.full-width input:not([type=submit]):not([type=file]) {
width: 100%;
}
.half-width input:not([type=submit]):not([type=file]) {
width: 50%;
} }
/* Tooltips */ /* Tooltips */