Dépot lié au service LSTU
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
1.5 KiB

% # vim:set sw=4 ts=4 sts=4 ft=html.epl expandtab:
% title 'Lstu';
<form class="form" method="POST" action="<%== url_for 'add' %>">
<label class="sr-only" for="lsturl"><%= l('URL to shorten') %></label>
<input type="url" name="lsturl" id="lsturl" class="form-control" placeholder="<%= l('URL to shorten') %>" required>
<label class="sr-only" for="lsturl-custom"><%= l('Custom shortened text') %></label>
<input type="text" name="lsturl-custom" id="lsturl-custom" class="form-control" placeholder="<%= l('Custom shortened text') %>">
<%= submit_button l('Go!'), class => 'button' %>
% if (defined(stash('short')) && defined(stash('url'))) {
<fieldset class="result">
<img class="qrcode-result" alt="QRCode" src="data:image/png;base64,<%= stash('qrcode') %>">
<label><%= link_to stash('url') => begin %><h4><%= stash('url') %></h4><%= end %></label>
⟹ <input id="input-short" value="<%== stash('short') %>" class="form-control">
<span id="js" class="hidden"><a href="#" id="clipboard" class="button button-clear" title="<%= l('Copy to clipboard') %>" data-short="<%== stash('short') %>"><h5><span class="icon icon-clipboard"></span></h5></a><span>
% }
% if (defined(flash('msg'))) {
<h3 class="alert alert-danger"><%= flash('msg') %></h3>
% }
% if (defined(stash('msg'))) {
<h3 class="alert alert-danger"><%= stash('msg') %></h3>
% }