Ok, So I made a custom login block for my drupal install and I type in information in and all, submit and it takes me to the login page. I type it in again and I finally login. I am not sure why this is not working, I found this code on this site and modified it slightly (can't remember where.)

<?php
global $user;
?>

<?php
if ($user->uid) :
?>

<?php
print l("logout","logout");
?>

<?php
else :
?>

Username:

Password:

Create account
Lost password

<?php
endif;
?>

I am running Drupal 6. Also if you could tell me where I can locate the code for the pre-installed blocks so I can use as reference that'd be great.

Comments

Sorry I didn't use the code tags, here is the code.

<?php global $user; ?>
<?php if ($user->uid) : ?>
<?php print l("logout","logout"); ?>
<?php else : ?>
<form action="/drupal/?q=user&amp;<?php print drupal_get_destination() ?>" method="post" id="user-login">
Username:
<br>
<input type="text" maxlength="60" name="edit[name]" id="edit-name" size="15" value="" class="form-text required" />
<br>
Password:
<br>
<input type="password" maxlength="" name="edit[pass]" id="edit-pass" size="15" class="form-text required" />
<br>
<input type="submit" name="op" value="Login" class="form-submit" />
<br>
<a href="/drupal/?q=user/register" title="Create account">Create account</a>
<a href="/drupal/?q=user/password" title="Retrieve lost password">Lost password</a>
<input type="hidden" name="edit[form_id]" id="edit-user-login" value="user_login" />
</form>
<?php endif; ?>

code for the login block would be in the user.module I believe.

I looked, yet can't figure out whats wrong with the form still... any ideas?

Did you ever figure this one out?
I am having that exact same issue.

Thanks!