Sollte mit den Author-TemplateTags gehen: Template Tags/the author description ? WordDoku
z.B.:
Um schreiben oder kommentieren zu können, benötigen Sie ein Benutzerkonto.
Sie haben schon ein Benutzerkonto? Melden Sie sich hier an.
Jetzt anmeldenHier können Sie ein neues Benutzerkonto erstellen.
Neues Benutzerkonto erstellenSollte mit den Author-TemplateTags gehen: Template Tags/the author description ? WordDoku
z.B.:
Von welcher Version möchtest du updaten?
Den wp-content Ordner und die wp-config.php solltest du auf jeden Fall sichern!! Upgrade ? WordDoku
Ein Datenbank-Update ist auch immer sinnvoll!
Wo hast du den rot markierten Code hingeschrieben? Bitte nicht in die widgets.php ![]()
<!-- begin l_sidebar -->
<div id="l_sidebar">
<ul id="l_sidebarwidgeted">
<?php if ( function_exists('dynamic_sidebar') && dynamic_sidebar(1) ) : else : ?>
<li id="Recent">
<h2>Recently Written</h2>
<ul>
<?php get_archives('postbypost', 10); ?>
</ul>
</li>
<li id="Categories">
<h2>Categories</h2>
<ul>
<?php wp_list_cats('sort_column=name'); ?>
</ul>
</li>
<li id="Archives">
<h2>Archives</h2>
<ul>
<?php wp_get_archives('type=monthly'); ?>
</ul>
</li>
<li id="Admin">
<h2>Admin</h2>
<ul>
<?php wp_register(); ?>
<li><?php wp_loginout(); ?></li>
<li><a href="http://wordpress.org/">WordPress</a></li>
<?php wp_meta(); ?>
<li><a href="http://validator.w3.org/check?uri=referer">XHTML</a></li>
</ul>
<?php endif; ?>
<!-- Letzte Kommentare -->
<!-- Suche die letzten 10 vom Typ Comment die akzeptiert wurden und sortiere es nach Datum absteigend -->
[COLOR=Red]<?php $comments = $wpdb->get_results("SELECT comment_post_ID, comment_author, comment_author_email, comment_content, comment_date
FROM $wpdb->comments
WHERE comment_type = ''
&& comment_approved = '1'
ORDER BY comment_date DESC LIMIT 10"); ?>[/COLOR]
<!-- ab hier der Ausgabeteil -->
<h2>Zuletzt diskutiert</h2>
<ul>
<?php $commenttype = 'even';
foreach($comments as $comment) {
$post = get_postdata($comment->comment_post_ID); ?>
<li class="<?php echo $commenttype; ?>">
<a href="<?php echo get_permalink($post['ID']); ?>" title="<?php echo $post['Title'];?>">Von
<?php echo $comment->comment_author; ?> zu
<?php echo $post['Title']; ?>
</a>
</li>
<?php if($commenttype == "even") { $commenttype = "odd"; } else { $commenttype = "even"; } ?>
<?php } ?>
</ul>
</ul>
</div>
<!-- end l_sidebar -->
Alles anzeigen
Das "Heiß diskutiert" könntest du mit dem Plugin most-commented erledigen: WordPress › Most Commented WordPress Plugins
Bitte mal den ganzen Code aus der sidebar_l.php ![]()
Was meinst du mit "identischen Änderungen"?
Wahrscheinlich, dass bei Änderungen am selben Tag nur einmal das Datum erscheint.
Wird am the_date liegen, schau mal hier unter SPECIAL NOTE: Template Tags/the date WordPress Codex
Sollte ich den PHP Code nich in Widgets.php schreiben ?
Was jetzt, wie jetzt, wo jetzt?
Entweder nur Code in der sidebar.php oder nur Widgets? Aber nix in der widgets.php ändern.
Poste dann mal den Code aus der sidebar_l.php.
Alles anzeigender page.php muß man sagen, dass sie den more tag nehmen muß, weil sie das per se nicht drin hat in ihrer Grundprogrammierung ---
du mußt
dazufügen
lg
Aber Monikas Lösung hast du probiert :confused:
Weil du es doch als Page aufruftst!
ansonsten einfach in der sidebar.php ... eifügen an der stelle wo es sein soll.
sChen meinte in die sidebar.php. Dafür darfst du dann aber nicht mehr mit Widgets arbeiten bzw. müsstest die sidebar.php dahin gehend ändern, dass beides geht.
Bitte nicht in die widgets.php. Beim nächsten WP-Update ist der Code vermutlich wieder weg.
sChen
Warum postest du im Minutentakt :confused:
Gibt doch einen sehr schönen Edit-Button für die Posts ![]()
doch, du könntest das Widget rausschmeißen und ohne in der sidebar.php arbeiten:
Zitat
Sidebar Modification: If you aren't using widgets then you'll need to change your template to use the new sort parameter, "orderby=order":[INDENT]wp_list_categories('orderby=order&hierarchical=0&title_li=');[/INDENT]
oder du könntest in der sidebar.php erst die Widgets abfragen und dann den restlichen Code ausgeben:
<div id="sidebar">
<ul>
<?php /* Widgetized sidebar, if you have the plugin installed. */
if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar() ) : ?>
<li>
<?php include (TEMPLATEPATH . '/searchform.php'); ?>
</li>
<!-- Author information is disabled per default. Uncomment and fill in your details if you want to use it. -->
<li>
<h2>Author</h2>
<p>A little something about you, the author. Nothing lengthy, just an overview.</p>
</li>
<?php endif; ?>
<ul class="blogroll">
<?php get_links(-1, '<li>', '</li>', '', FALSE, 'name', FALSE, FALSE, -1, FALSE); ?>
</ul>
<?php if ( is_404() || is_category() || is_day() || is_month() ||
is_year() || is_search() || is_paged() ) {
?>
<li>
<?php /* If this is a 404 page */ if (is_404()) { ?>
<?php /* If this is a category archive */ } elseif (is_category()) { ?>
<p>You are currently browsing the archives for the <?php single_cat_title(''); ?> category.</p>
<?php /* If this is a yearly archive */ } elseif (is_day()) { ?>
<p>You are currently browsing the <a href="<?php bloginfo('url'); ?>/"><?php echo bloginfo('name'); ?></a> blog archives
for the day <?php the_time('l, F jS, Y'); ?>.</p>
<?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
<p>You are currently browsing the <a href="<?php bloginfo('url'); ?>/"><?php echo bloginfo('name'); ?></a> blog archives
for <?php the_time('F, Y'); ?>.</p>
<?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
<p>You are currently browsing the <a href="<?php bloginfo('url'); ?>/"><?php echo bloginfo('name'); ?></a> blog archives
for the year <?php the_time('Y'); ?>.</p>
<?php /* If this is a monthly archive */ } elseif (is_search()) { ?>
<p>You have searched the <a href="<?php echo bloginfo('url'); ?>/"><?php echo bloginfo('name'); ?></a> blog archives
for <strong>'<?php the_search_query(); ?>'</strong>. If you are unable to find anything in these search results, you can try one of these links.</p>
<?php /* If this is a monthly archive */ } elseif (isset($_GET['paged']) && !empty($_GET['paged'])) { ?>
<p>You are currently browsing the <a href="<?php echo bloginfo('url'); ?>/"><?php echo bloginfo('name'); ?></a> blog archives.</p>
<?php } ?>
</li> <?php }?>
<?php wp_list_categories('show_count=0&title_li=<h2>Categories</h2>'); ?>
<li><h2>Archives</h2>
<ul>
<?php wp_get_archives('type=monthly'); ?>
</ul>
</li>
<?php if ( is_front_page() ) : ?>
<li><h2>Über leidenschaftlich.net</h2>
Gestrandet in meinem Blog? Noch mal Glück gehabt! Denn hier erfahren Sie die wirklich wichtigen Dinge rund um die Liebe – das Leben - Leidenschaft und Sex. Neuigkeiten, Tipps, Erfahrungen, Humorvolles….- Lassen auch Sie sich inspirieren! <em>Ihre Jill</em>
</li>
<?php endif; ?>
<ul class="blogroll">
<?php get_links(-1, '<li>', '</li>', '', FALSE, 'name', FALSE, FALSE, -1, FALSE); ?>
</ul>
<?php /* If this is the frontpage */ if ( is_home() || is_page() ) { ?>
<?php wp_list_bookmarks(); ?>
<?php } ?>
</ul>
</div>
Alles anzeigen
So könntest du Widgets und gleichzeitig den Code aus der sidebar.php nutzen.
Und zum Schluss schau noch mal auf den validator: [Invalid] Markup Validation of http://www.leidenschaftlich.net/ - W3C Markup Validator
dann schätze ich mal einfach, das du über das AdminPanel ein Widget aktiviert hast. Wenn Widgets aktiviert sind, wird der Code in der sidebar.php nicht mehr beachtet.
Ohhh ... und ich dachte du gehörst dazu :lol:
nochmals danke!
ja danke, soweit verstanden. Aber warum nur ein schließendes p-tag?
Hey marX ... wieder mal erstklassig! Funktioniert!!
Aber hast du auch noch eine Erklärung dafür? Warum ist es so wie es ist :confused:
seit einer Woche? Schade, hättest früher hier landen sollen ![]()
<?php get_header(); ?>
<div id="post-index">
<?php if (have_posts()) : ?>
<h2>Browsing <?php single_cat_title(); ?>™</h2>
<?php while (have_posts()) : the_post(); ?>
<div class="post-meta" id="post-<?php the_ID(); ?>">
<h1 class="post-title"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title(); ?>"><?php the_title(); ?></a></h1>
<div class="postedby">
<div class="post-status">
<strong><?php _e('Geschrieben von'); ?></strong> <?php the_author_posts_link(); ?> in <?php the_time('F jS, Y') ?> <?php edit_post_link('Edit', '', ''); ?>
</div>
<div class="comment-stats"><?php comments_popup_link('Kommentar Schreiben', '1 Kommentar', '% Kommentare'); ?></div>
</div>
<div class="fileunder">
<div class="atgcat"><?php _e('Kategorie'); ?>: <?php the_category(', ') ?> <?php if(function_exists("UTW_ShowTagsForCurrentPost")) : ?><?php UTW_ShowTagsForCurrentPost("commalist", array('last'=>' and %taglink%', 'first'=>'Tags in: %taglink%',)) ?><?php else : ?><?php if(function_exists("the_tags")) : ?><?php the_tags() ?><?php endif; ?><?php endif; ?> </div>
</div>
<div class="post-content">
[COLOR=Red]<?php the_content('weiterlesen ...'); ?>[/COLOR]
</div>
</div>
<?php endwhile; ?>
<div class="clear-fix"></div>
<?php if(file_exists(TEMPLATEPATH . '/paginate.php')): ?>
<?php include (TEMPLATEPATH . '/paginate.php'); ?>
<?php else: ?>
<?php endif; ?>
<?php else: ?>
<h2>Sorry the category you looking for did not exist or already removed by author</h2>
<?php endif; ?>
</div>
<?php get_sidebar(); ?>
<?php get_footer(); ?>
Alles anzeigen
Ach so, hier noch ein Link zu the_content: http://doku.wordpress-deutschland.org/Template_Tags/the_content
Danke jottlieb! Hab extra schon alle Plugins deaktiviert und die functions.php soweit geleert ... aber keine Besserung :sad:
Geb mir mal bitte einen Tip, wäre nett
Versuch mal den TinyMCE Advanced LaptopTips
Ein freundliches Hallo in die Runde,
ich hab versucht die category_description in meine category.php einzubauen:
Leider tritt nun bei Kategorien ohne Description das Problem auf, dass nur ein schließendes </p>-Tag in den DIV Container geschrieben wird. Da meckert natürlich der validator:
Woher kommt das schließende p und warum setzt WP dann nicht auch ein öffnendes p?
Kann das jemand nachvollziehen bzw. hat da jemand ne Lösung für?
Thx & Greets
maxe
Du könntest es so versuchen: WordPress: Letzte Kommentare ausgeben - I am Jeriko