Fix for Bug 4504, Confirmation messages in opac account not translated
[koha.git] / koha-tmpl / opac-tmpl / prog / en / modules / opac-shelves.tmpl
index b738c38..217993c 100644 (file)
@@ -4,7 +4,8 @@
 <script type="text/JavaScript" language="JavaScript">
 //<![CDATA[
 var MSG_NO_TAG_SPECIFIED = _("No tag was specified.");
-
+var MSG_REMOVE_FROM_LIST = _("Are you sure you want to remove these items from the list?");
+var MSG_CONFIRM_DELETE_LIST = _("Are you sure you want to delete this list?");
 $.tablesorter.addParser({
     id: 'articles', 
     is: function(s) {return false;  }, 
@@ -225,7 +226,7 @@ $(function() {
                          <input type="hidden" name="display" value="privateshelves" />
                     <!-- /TMPL_IF -->
                          <input type="hidden" value="1" name="DEL-<!-- TMPL_VAR NAME="shelfnumber" -->"/>
-                         <input type="submit" class="deleteshelf" value="Delete List" onclick="return confirmDelete(_('Are you sure you want to remove this List?'));"/>
+                         <input type="submit" class="deleteshelf" value="Delete List" onclick="return confirmDelete(MSG_CONFIRM_DELETE_LIST);"/>
                       </form> <!-- /TMPL_IF -->
 
                      <a class="print tag_hides" href="opac-shelves.pl" onclick="print(); return false;">Print List</a>
@@ -233,7 +234,6 @@ $(function() {
                                | <span><a class="login" href="/cgi-bin/koha/opac-user.pl">Log in</a> to place holds or add tags</span><!-- /TMPL_UNLESS -->
                   </div>
 
-                <!-- /TMPL_IF -->
                 <!-- TMPL_IF NAME="manageshelf" -->
                   <form action="/cgi-bin/koha/opac-shelves.pl" method="post" name="myform" class="checkboxed">
                     <input type="hidden" name="viewshelf" value="<!-- TMPL_VAR NAME="shelfnumber" -->" />
@@ -305,12 +305,12 @@ $(function() {
               <!-- TMPL_IF NAME="itemsloop" -->
                 <input type="hidden" name="shelfnumber" value="<!-- TMPL_VAR NAME="shelfnumber" -->" />
                 <input type="hidden" name="modifyshelfcontents" value="1" />
-                <input type="hidden" name="viewshelf" value="<!-- TMPL_VAR NAME="shelfnumber" -->" /><input type="submit" value="Remove Selected Items" class="icon delete" onclick="return confirmDelete(_('Are you sure you want to remove these items from the list?'))" />
+                <input type="hidden" name="viewshelf" value="<!-- TMPL_VAR NAME="shelfnumber" -->" /><input type="submit" value="Remove Selected Items" class="icon delete" onclick="return confirmDelete(MSG_REMOVE_FROM_LIST)" />
               <!-- TMPL_ELSE -->
                 <form method="post" action="opac-shelves.pl">
                   <input type="hidden" name="DEL-<!-- TMPL_VAR NAME="shelfnumber" -->" value="1" />
                   <input type="hidden" name="shelves" value="1" />
-                  <input type="submit" class="icon delete" value="Delete this List" onclick="return confirmDelete(_('Are you sure you want to delete this List?'))" />
+                  <input type="submit" class="icon delete" value="Delete this List" onclick="return confirmDelete(MSG_CONFIRM_DELETE_LIST)" />
               <!-- /TMPL_IF -->
                 </form>
             <!-- /TMPL_IF -->
@@ -333,10 +333,10 @@ $(function() {
                         </select>
                       </li>
                       <li>
-                        <label for="category">Category: </label>
+                        <label for="category">Category:</label>
                         <select name="category" id="category">
-                          <option value="1">Private</option>
-                          <option value="2">Public</option>
+                          <!-- TMPL_IF NAME="category1" --><option value="1" selected="selected">Private</option><!-- TMPL_ELSE --><option value="1">Private</option><!-- /TMPL_IF -->
+                          <!-- TMPL_IF NAME="category2" --><option value="2" selected="selected">Public</option><!-- TMPL_ELSE --><option value="2">Public</option><!-- /TMPL_IF -->
                         </select>
                       </li>
                     </ol>
@@ -412,7 +412,7 @@ $(function() {
                                     <input type="hidden" name="CONFIRM-<!-- TMPL_VAR NAME="confirm" -->" value="1" />
                                     <input type="submit" class="confirm" value="Confirm" />
                               <!-- TMPL_ELSE -->
-                                    <input type="submit" class="deleteshelf" onclick="return confirmDelete(_('Are you sure you want to remove this List?'));" value="Delete" />
+                                    <input type="submit" class="deleteshelf" onclick="return confirmDelete(MSG_CONFIRM_DELETE_LIST);" value="Delete" />
                               <!-- /TMPL_IF -->
                                 </form>
                             <!-- /TMPL_IF -->&nbsp;
@@ -478,7 +478,7 @@ $(function() {
                                   <input type="hidden" name="CONFIRM-<!-- TMPL_VAR NAME="confirm" -->" value="1" />
                                   <input type="submit" class="confirm" value="Confirm" />
                                 <!-- TMPL_ELSE -->
-                                  <input type="submit" class="deleteshelf" onclick="return confirmDelete(_('Are you sure you want to remove this List?'));" value="Delete" />
+                                  <input type="submit" class="deleteshelf" onclick="return confirmDelete(MSG_CONFIRM_DELETE_LIST);" value="Delete" />
                                 <!-- /TMPL_IF -->
                               </form>
                             <!-- /TMPL_IF -->&nbsp;