Ich arbeite an einem site für einen Client, der jquery Tabbed-Inhalt hat.Wie erhalte ich einen Link zum Öffnen eines bestimmten Tabs auf einer Seite?
Die Verknüpfung mit der richtigen Seite ist leicht genug, aber die Herausforderung besteht darin, auf der richtigen Registerkarte zu öffnen, wenn Sie dort ankommen. Blättern Sie auf der About-Seite nach unten und klicken Sie auf das Symbol Verschieben Sie es (das mit dem LKW). Dies bringt Sie zum move it page. Das funktioniert gut, aber ich möchte es in der Lage sein, die Specialty Registerkarte zu öffnen.
Hier ist der Code, der auf der Seite Links:
<li><a id="moveit" href="services_move_it.html">Move It</a></li>
Ich versuche dies, aber es funktioniert nicht richtig
<li><a id="moveit" href="services_move_it.html#specialty">Move It</a></li>
Hier ist der Code für die Registerkarten auf der Zielseite:
<div id="specialty-content" class="content">
<p class="intro">Moving Simplified specializes in moving items such items as pool tables, pianos, antiques, and anything else you can throw at us.</p>
<div class="video-link">
<a href="#">Watch the Move It Specialty Videos Now.</a>
</div>
<p> Moving such items is more complicated than most would understand, and is an art form in itself. We take pride in making sure that your priceless possessions are delivered damage free. The employees sent to move your belongings are highly experienced in these types of items. They will always be well equipped to complete the move with the most up to date technology in the moving industry.</p><p> We will always pad and wrap each individual piece, as well as provide custom crates to ensure the safety of your pool table slate.</p>
<div class="msg">
<p><strong>Want to download the Move It Specialty guide?</strong> Go here <a href="#">now</a>.</p>
</div>
</div>
ist hier die jquery für den Reiter Betrieb:
$(document).ready(function() {
/* this is for the tabbed content */
$("a.tab").click(function(evt) {
evt.preventDefault();
$(".active").removeClass("active");
$(this).addClass("active");
$(".content").slideUp();
var content_show = $(this).attr("id");
$("#" + content_show + '-content').slideDown();
});
Da ich dies auf mehrere Link/Tab-Combos tun muss, würde ich gerne einen systematischen Ansatz finden.
Danke für jede Hilfe!
Vielen Dank für das Weitergeben. Das ist genau die Funktionalität, die ich brauchte. – fmz
Ihre Links sind kaputt :( –