Scroll to scrolls to top and not away from page

Scroll to scrolls to top and not away from page

I have installed the scrollto plugin which works fine. 

The problem I have now is that when I click on an external link i.e http://google.com it just ignores it and scrolls to the top of my page instead?



  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

  5. <title>Manoucher Products</title>

  6. <link href="style.css" rel="stylesheet" type="text/css" />
  7. <link href="sidemenu.css" rel="stylesheet" type="text/css" />



  8.    <!--[if IE]>
  9.         <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
  10.         
  11.         <style type="text/css">
  12.         .clear {
  13.           zoom: 1;
  14.           display: block;
  15.         }
  16.         </style>

  17.         
  18.         <![endif]-->

  19. </head>

  20. <body >

  21.      <section id="page"> <!-- Defining the #page section with the section tag -->
  22.     <div class="scroll"></div>

  23.             <header> <!-- Defining the header section of the page with the appropriate tag -->
  24.             
  25.                 <hgroup>

  26.                 </hgroup>
  27.                           
  28.             
  29.             </header>
  30.             
  31.             <section id="articles"> <!-- A new section with the articles -->

  32. <div id="sidebar">
  33. <nav id="rightsidemenu" class="clear"> <!-- The nav link semantically marks your main site navigation -->
  34. <ul id="buts">
  35.    <li><a href="/#1" class="but_home"></a></li>
  36.   <li><a href="#1" class="but_history"></a></li>
  37. <li><a href="/products" class="but_products"></a></li>
  38. <li><a href="/news/news.html" class="but_news"></a></li>
  39. <li><a href="http://manoucher.net/commingsoon/shopsoon.html" class="but_shop"></a></li>
  40. <li><a rel="shadowbox" href="http://maps.google.com/maps?f=q&amp;source=s_q&amp;hl=en&amp;geocode=&amp;q=manoucher+foods&amp;aq=&amp;sll=37.0625,-95.677068&amp;sspn=53.432436,79.013672&amp;ie=UTF8&amp;hq=manoucher+foods&amp;hnear=&amp;ll=43.72854,-79.526255&amp;spn=53.30452,112.5&amp;z=4&amp;iwloc=A&amp;cid=7380407805238199153&amp;output=embed" class="but_find"></a></li>
  41. <li><a href="/contact" class="smcf-link"></a></li>
  42. <li><a href="/blog" class="but_talk"></a></li>
  43. <li><a href="#8" class="but_gallery"></a></li>
  44. </ul>
  45. </nav>
  46. </div>
  47. <article id="article_products">

  48.   <p><img src="products-home.jpg" alt="" align="middle" /></p>

  49. </article>

  50. <article id="article_breads">
  51.  
  52.   

  53.   <p> <img src="ourbreads.jpg" alt="" align="middle" />
  54.  <div id="more_pizza">  
  55.   <li><a class="morebutton" href=""></a></li>
  56.   </div>
  57.   </p>
  58. </article>

  59. <article id="article_pizzas">
  60.   <p> <img src="ourpizzas.jpg" alt="" align="middle" />
  61.   <div id="more_bread">
  62.   <li><a class="morebutton" href=""></a></li>
  63.   </div>
  64.     </p>
  65. </article>

  66. <article id="article_other">
  67.   <p> <img src="otherproducts.jpg" alt="" align="middle" /></p>
  68. </article>

  69.             </section>

  70.         <footer> <!-- Marking the footer section -->
  71.               
  72.  <nav id="footernav" class="clear"> <!-- The nav link semantically marks your main site navigation -->
  73.                     
  74.                         <a id="breadimglink" href="#article_breads">Breads</a>
  75.                         <a id="pizzaimglink" href="#article_pizzas">Pizzas</a>
  76. <a id="otherimglink" href="#article_other">Other</a>
  77.                     
  78.                 </nav>
  79.            <a href="#" class="up">Go UP</a>        
  80. <p>Copyright 2011 - manoucher.com</p> <!-- Change the copyright notice -->
  81.         </footer>
  82.             
  83. </section> <!-- Closing the #page section -->

  84.    <!-- JavaScript Includes -->
  85.         
  86.         <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
  87.         <script src="jquery.scrollTo-1.4.2/jquery.scrollTo.js"></script>
  88.         <script src="script.js"></script>
  89. <script type='text/javascript' src='js/resolution-test.js'></script>

  90. <!-- JavaScript Fade Menu -->
  91. <script type="text/javascript">
  92. $(document).ready(function() {
  93. $('.but_home,.but_history,.but_products,.but_news,.but_shop,.but_find,.smcf-link,.but_talk,.but_gallery').append('<span class="hover"></span>').each(function () {
  94.   var $span = $('> span.hover', this).css('opacity', 0);
  95.   $(this).hover(function () {
  96.     $span.stop().fadeTo(500, 1);
  97. }, function () {
  98.   $span.stop().fadeTo(500, 0);
  99.   });
  100. });
  101. });
  102. </script>
  103. </body>



  104. </html>
    • Topic Participants

    • alan