Hallo zusammen,
ich weiß, dass das hier schon längst schon 100x behandeltes Alteisen ist - ich habe es sogar vor einem halben Jahr mal selbst hinbekommen, aber einfach vergessen, wie es geht - und finde jetzt trotz allem Suchen die richtige Erklärung nicht, tut mir leid ... Also:
Ich habe zwei Sidebars rechts und links, möchte die rechte abschalten (mit einem Seitentemplate ohne Aufruf der sidebar2, habe ich fertig, hier pageneu.php), aber der Text in der Mitte stoppt davor und glaubt offensichtlich, die Sidebar wäre noch da.
Also gehe ich in die CSS und ändere das: zum content kommt content1 hinzu, ich schreibe die entsprechenden Angaben hinein, rufe in der pageneu.php content1 auf - und dann fällt es mir doch immer wieder auseinander: Entweder ist die Sidebar links plötzlich elend breit oder der Text aus der Mitte rutscht mir darunter und geht nun über die ganze Seite. Wo liegt mein Fehler?
Das hier ist mein bisher bester Versuch:
Die CSS
/* begin LayoutCell */
.art-contentLayout .art-content
{
position: relative;
margin: 0;
padding: 0;
border: 0;
float: left;
overflow: hidden;
width: 562px;
}
.art-contentLayout1 .art-content1
{
position: relative;
margin: 0;
padding: 0;
border: 0;
float: left;
overflow: hidden;
width: 749px;
}
.art-contentLayout .art-content-sidebar1
{
position: relative;
margin: 0;
padding: 0;
border: 0;
float: left;
overflow: hidden;
width: 810px;
}
.art-contentLayout .art-content-sidebar2
{
position: relative;
margin: 0;
padding: 0;
border: 0;
float: left;
overflow: hidden;
width: 748px;
}
.art-contentLayout .art-content-wide
{
position: relative;
margin: 0;
padding: 0;
border: 0;
float: left;
overflow: hidden;
width: 997px;
}
/* end LayoutCell */
/* begin LayoutCell */
.art-contentLayout .art-sidebar2
{
position: relative;
margin: 0;
padding: 0;
border: 0;
float: left;
overflow: hidden;
width: 187px;
}
/* end LayoutCell */
Alles anzeigen
Und hier die pageneu.php:
<?php
/*
Template Name: OneSidebar.php
*/
?>
<?php get_header(); ?>
<div class="art-contentLayout">
<?php include (TEMPLATEPATH . '/sidebar1.php'); ?><div class="art-content">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<div class="art-Post">
<div class="art-Post-cc"></div>
<div class="art-Post-body">
<div class="art-Post-inner art-article">
<h2 class="art-PostHeader">
<a href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__('Permanent Link to %s', 'kubrick'), the_title_attribute('echo=0')); ?>">
<?php the_title(); ?>
</a>
</h2>
<div class="art-PostContent">
<?php if (is_search()) the_excerpt(); else the_content(__('Read the rest of this entry »', 'kubrick')); ?>
<?php if (is_page() or is_single()) wp_link_pages(array('before' => '<p><strong>Pages:</strong> ', 'after' => '</p>', 'next_or_number' => 'number')); ?>
</div>
<div class="cleared"></div>
</div>
<div class="cleared"></div>
</div>
</div>
<?php comments_template(); ?>
<?php endwhile; endif; ?>
</div>
</div>
<div class="cleared"></div>
<?php get_footer(); ?>
Alles anzeigen
Irgendwie habe ich ein Brett vorm Kopf. Kann mir jemand sagen, wie ich es los werde?
Danke!