Changeset 4890

Show
Ignore:
Timestamp:
02/16/07 04:36:51 (1 year ago)
Author:
markjaquith
Message:

Detect whether a user is logged in for popup comments templates in default and classic themes. props skippy, Nazgul, rob1n. fixes #1065

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-content/themes/classic/comments-popup.php

    r4656 r4890  
    5757 
    5858<form action="<?php echo get_option('siteurl'); ?>/wp-comments-post.php" method="post" id="commentform"> 
     59<?php if ( $user_ID ) : ?>  
     60    <p>Logged in as <a href="<?php echo get_option('siteurl'); ?>/wp-admin/profile.php"><?php echo $user_identity; ?></a>. <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?action=logout" title="Log out of this account">Logout &raquo;</a></p> 
     61<?php else : ?>  
    5962    <p> 
    6063      <input type="text" name="author" id="author" class="textarea" value="<?php echo $comment_author; ?>" size="28" tabindex="1" /> 
     
    7376       <label for="url"><?php _e("<abbr title=\"Universal Resource Locator\">URL</abbr>"); ?></label> 
    7477    </p> 
     78<?php endif; ?> 
    7579 
    7680    <p> 
  • trunk/wp-content/themes/default/comments-popup.php

    r4656 r4890  
    5757 
    5858<form action="<?php echo get_option('siteurl'); ?>/wp-comments-post.php" method="post" id="commentform"> 
     59<?php if ( $user_ID ) : ?>  
     60    <p>Logged in as <a href="<?php echo get_option('siteurl'); ?>/wp-admin/profile.php"><?php echo $user_identity; ?></a>. <a href="<?php echo get_option('siteurl'); ?>/wp-login.php?action=logout" title="Log out of this account">Logout &raquo;</a></p> 
     61<?php else : ?>  
    5962    <p> 
    6063      <input type="text" name="author" id="author" class="textarea" value="<?php echo $comment_author; ?>" size="28" tabindex="1" /> 
     
    7376       <label for="url"><abbr title="Universal Resource Locator">URL</abbr></label> 
    7477    </p> 
     78<?php endif; ?> 
    7579 
    7680    <p>