Advertisement
Guest User

Untitled

a guest
Apr 19th, 2014
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.35 KB | None | 0 0
  1. @{
  2. ViewBag.Title = " Control Panel";
  3. Layout = "~/Views/Shared/_Layout.cshtml";
  4. }
  5. <script type="text/javascript">
  6. $(document).ready(function () {
  7. $("#tabs").tabs({
  8. beforeLoad: function (event, ui) {
  9. ui.jqXHR.error(function () {
  10. ui.panel.html(
  11. "Couldn't load this tab. We'll try to fix this as soon as possible. " +
  12. "If this wouldn't be a demo.");
  13. });
  14. },
  15. beforeLoad: function (event, ui) {
  16. $(ui.panel).siblings('.ui-tabs-panel').empty();
  17. },
  18. activate: function (event, ui) {
  19. window.location.hash = 'tab=' + $(this).tabs('option', 'active');
  20.  
  21. },
  22. create: function () {
  23. if (window.location.hash) {
  24. var active = parseInt(window.location.hash.replace('#tab=', ''));
  25. $(this).tabs("option", "active", active);
  26. }
  27. }
  28. });
  29. });
  30.  
  31. </script>
  32. <h2>Control Panel</h2>
  33. <div id="content">
  34.  
  35. <div id="rightdiv">
  36. <div id="tabs">
  37. <ul>
  38. <li id="CreateParentAccount"><a href="~/Account/CreateParentAccount">Create New Account</a></li>
  39. <li id="Search"><a href="~/Account/Search">Existing Account</a></li>
  40. <li id="SearchArchive"><a href="~/Account/Search">Archived Account</a></li>
  41. </ul>
  42. </div>
  43. </div>
  44. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement