2004-04-24 21:25:41 -04:00
|
|
|
<?php
|
|
|
|
require_once('../wp-includes/wp-l10n.php');
|
|
|
|
|
|
|
|
$title = "Profile";
|
2003-05-22 08:12:53 -04:00
|
|
|
/* <Profile | My Profile> */
|
|
|
|
|
|
|
|
function add_magic_quotes($array) {
|
|
|
|
foreach ($array as $k => $v) {
|
|
|
|
if (is_array($v)) {
|
|
|
|
$array[$k] = add_magic_quotes($v);
|
|
|
|
} else {
|
|
|
|
$array[$k] = addslashes($v);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return $array;
|
|
|
|
}
|
|
|
|
|
|
|
|
if (!get_magic_quotes_gpc()) {
|
2004-04-20 18:56:47 -04:00
|
|
|
$_GET = add_magic_quotes($_GET);
|
|
|
|
$_POST = add_magic_quotes($_POST);
|
|
|
|
$_COOKIE = add_magic_quotes($_COOKIE);
|
2003-05-22 08:12:53 -04:00
|
|
|
}
|
|
|
|
|
2003-12-18 04:36:13 -05:00
|
|
|
$wpvarstoreset = array('action','standalone','redirect','profile','user');
|
|
|
|
for ($i=0; $i<count($wpvarstoreset); $i += 1) {
|
|
|
|
$wpvar = $wpvarstoreset[$i];
|
|
|
|
if (!isset($$wpvar)) {
|
2004-04-20 18:56:47 -04:00
|
|
|
if (empty($_POST["$wpvar"])) {
|
|
|
|
if (empty($_GET["$wpvar"])) {
|
2003-12-18 04:36:13 -05:00
|
|
|
$$wpvar = '';
|
2003-05-22 08:12:53 -04:00
|
|
|
} else {
|
2004-04-20 18:56:47 -04:00
|
|
|
$$wpvar = $_GET["$wpvar"];
|
2003-05-22 08:12:53 -04:00
|
|
|
}
|
|
|
|
} else {
|
2004-04-20 18:56:47 -04:00
|
|
|
$$wpvar = $_POST["$wpvar"];
|
2003-05-22 08:12:53 -04:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2003-06-12 18:47:45 -04:00
|
|
|
require_once('../wp-config.php');
|
2003-12-31 19:55:31 -05:00
|
|
|
require_once('auth.php');
|
2003-05-22 08:12:53 -04:00
|
|
|
switch($action) {
|
|
|
|
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'update':
|
2003-05-22 08:12:53 -04:00
|
|
|
|
|
|
|
get_currentuserinfo();
|
|
|
|
|
|
|
|
/* checking the nickname has been typed */
|
2004-04-20 18:56:47 -04:00
|
|
|
if (empty($_POST["newuser_nickname"])) {
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: please enter your nickname (can be the same as your login)"));
|
2003-05-22 08:12:53 -04:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* if the ICQ UIN has been entered, check to see if it has only numbers */
|
2004-04-20 18:56:47 -04:00
|
|
|
if (!empty($_POST["newuser_icq"])) {
|
|
|
|
if ((ereg("^[0-9]+$",$_POST["newuser_icq"]))==false) {
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: your ICQ UIN can only be a number, no letters allowed"));
|
2003-05-22 08:12:53 -04:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* checking e-mail address */
|
2004-04-20 18:56:47 -04:00
|
|
|
if (empty($_POST["newuser_email"])) {
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: please type your e-mail address"));
|
2003-05-22 08:12:53 -04:00
|
|
|
return false;
|
2004-04-20 18:56:47 -04:00
|
|
|
} else if (!is_email($_POST["newuser_email"])) {
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: the email address isn't correct"));
|
2003-05-22 08:12:53 -04:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2004-04-20 18:56:47 -04:00
|
|
|
if ($_POST["pass1"] == "") {
|
|
|
|
if ($_POST["pass2"] != "")
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: you typed your new password only once. Go back to type it twice."));
|
2003-05-22 08:12:53 -04:00
|
|
|
$updatepassword = "";
|
|
|
|
} else {
|
2004-04-20 18:56:47 -04:00
|
|
|
if ($_POST["pass2"] == "")
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: you typed your new password only once. Go back to type it twice."));
|
2004-04-20 18:56:47 -04:00
|
|
|
if ($_POST["pass1"] != $_POST["pass2"])
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: you typed two different passwords. Go back to correct that."));
|
2004-04-20 18:56:47 -04:00
|
|
|
$newuser_pass = $_POST["pass1"];
|
2004-02-09 04:56:57 -05:00
|
|
|
$updatepassword = "user_pass=MD5('$newuser_pass'), ";
|
2004-05-19 03:05:40 -04:00
|
|
|
setcookie('wordpresspass_'.$cookiehash, " ", time() - 31536000, COOKIEPATH);
|
|
|
|
setcookie('wordpresspass_'.$cookiehash, md5(md5($newuser_pass)), time() + 31536000, COOKIEPATH);
|
2003-05-22 08:12:53 -04:00
|
|
|
}
|
|
|
|
|
2004-04-20 18:56:47 -04:00
|
|
|
$newuser_firstname=addslashes(stripslashes($_POST['newuser_firstname']));
|
|
|
|
$newuser_lastname=addslashes(stripslashes($_POST['newuser_lastname']));
|
|
|
|
$newuser_nickname=addslashes(stripslashes($_POST['newuser_nickname']));
|
2004-06-01 15:52:48 -04:00
|
|
|
$newuser_nicename=sanitize_title($newuser_nickname);
|
2004-04-20 18:56:47 -04:00
|
|
|
$newuser_icq=addslashes(stripslashes($_POST['newuser_icq']));
|
|
|
|
$newuser_aim=addslashes(stripslashes($_POST['newuser_aim']));
|
|
|
|
$newuser_msn=addslashes(stripslashes($_POST['newuser_msn']));
|
|
|
|
$newuser_yim=addslashes(stripslashes($_POST['newuser_yim']));
|
|
|
|
$newuser_email=addslashes(stripslashes($_POST['newuser_email']));
|
|
|
|
$newuser_url=addslashes(stripslashes($_POST['newuser_url']));
|
|
|
|
$newuser_idmode=addslashes(stripslashes($_POST['newuser_idmode']));
|
|
|
|
$user_description = addslashes(stripslashes($_POST['user_description']));
|
2003-12-31 19:55:31 -05:00
|
|
|
|
2004-06-01 15:52:48 -04:00
|
|
|
$query = "UPDATE $wpdb->users SET user_firstname='$newuser_firstname', $updatepassword user_lastname='$newuser_lastname', user_nickname='$newuser_nickname', user_icq='$newuser_icq', user_email='$newuser_email', user_url='$newuser_url', user_aim='$newuser_aim', user_msn='$newuser_msn', user_yim='$newuser_yim', user_idmode='$newuser_idmode', user_description = '$user_description', user_nicename = '$newuser_nicename' WHERE ID = $user_ID";
|
2003-06-01 02:45:53 -04:00
|
|
|
$result = $wpdb->query($query);
|
|
|
|
if (!$result) {
|
2004-04-24 21:25:41 -04:00
|
|
|
die (__("<strong>ERROR</strong>: couldn't update your profile..."));
|
2003-05-22 08:12:53 -04:00
|
|
|
}
|
2003-12-31 19:55:31 -05:00
|
|
|
header('Location: profile.php?updated=true');
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
|
|
|
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'viewprofile':
|
2003-05-22 08:12:53 -04:00
|
|
|
|
|
|
|
|
2003-06-01 04:05:56 -04:00
|
|
|
$profiledata = get_userdata($user);
|
2004-04-20 18:56:47 -04:00
|
|
|
if ($_COOKIE['wordpressuser_'.$cookiehash] == $profiledata->user_login)
|
2003-12-10 19:22:36 -05:00
|
|
|
header ('Location: profile.php');
|
2003-05-22 08:12:53 -04:00
|
|
|
|
2003-12-31 19:55:31 -05:00
|
|
|
include_once('admin-header.php');
|
2003-05-22 08:12:53 -04:00
|
|
|
?>
|
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<h2><?php _e('View Profile') ?> “
|
2003-06-01 04:05:56 -04:00
|
|
|
<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
switch($profiledata->user_idmode) {
|
|
|
|
case 'nickname':
|
|
|
|
$r = $profiledata->user_nickname;
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'login':
|
|
|
|
$r = $profiledata->user_login;
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'firstname':
|
|
|
|
$r = $profiledata->user_firstname;
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'lastname':
|
|
|
|
$r = $profiledata->user_lastname;
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'namefl':
|
|
|
|
$r = $profiledata->user_firstname.' '.$profiledata->user_lastname;
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
2003-06-01 02:45:53 -04:00
|
|
|
case 'namelf':
|
|
|
|
$r = $profiledata->user_lastname.' '.$profiledata->user_firstname;
|
2003-05-22 08:12:53 -04:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
echo $r;
|
|
|
|
?>
|
2003-06-01 04:05:56 -04:00
|
|
|
”</h2>
|
|
|
|
|
|
|
|
<div id="profile">
|
|
|
|
<p>
|
2004-04-24 21:25:41 -04:00
|
|
|
<strong><?php _e('Login') ?></strong> <?php echo $profiledata->user_login ?>
|
|
|
|
| <strong><?php _e('User #') ?></strong> <?php echo $profiledata->ID ?> | <strong><?php _e('Level') ?></strong>
|
|
|
|
<?php echo $profiledata->user_level ?> | <strong><?php _e('Posts') ?></strong>
|
2003-06-01 04:05:56 -04:00
|
|
|
<?php
|
|
|
|
$posts = get_usernumposts($user);
|
|
|
|
echo $posts;
|
|
|
|
?>
|
|
|
|
</p>
|
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('First name:') ?></strong> <?php echo $profiledata->user_firstname ?> </p>
|
2003-06-01 04:05:56 -04:00
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('Last name:') ?></strong> <?php echo $profiledata->user_lastname ?> </p>
|
2003-06-01 04:05:56 -04:00
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('Nickname:') ?></strong> <?php echo $profiledata->user_nickname ?> </p>
|
2003-06-01 04:05:56 -04:00
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('Email:') ?></strong> <?php echo make_clickable($profiledata->user_email) ?>
|
2003-06-01 04:05:56 -04:00
|
|
|
</p>
|
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('Website:') ?></strong> <?php echo $profiledata->user_url ?> </p>
|
2003-06-01 04:05:56 -04:00
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('ICQ:') ?></strong>
|
2003-06-01 04:05:56 -04:00
|
|
|
<?php if ($profiledata->user_icq > 0) { echo make_clickable("icq:".$profiledata->user_icq); } ?>
|
|
|
|
</p>
|
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('AIM:') ?></strong> <?php echo "<a href='aim:goim?screenname=". str_replace(' ', '+', $profiledata->user_aim) ."&message=Howdy'>$profiledata->user_aim</a>"; ?>
|
2003-06-01 04:05:56 -04:00
|
|
|
</p>
|
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('MSN IM:') ?></strong> <?php echo $profiledata->user_msn ?> </p>
|
2003-06-01 04:05:56 -04:00
|
|
|
|
2004-04-24 21:25:41 -04:00
|
|
|
<p> <strong><?php _e('Yahoo IM:') ?></strong> <?php echo $profiledata->user_yim ?> </p>
|
2003-06-01 04:05:56 -04:00
|
|
|
|
|
|
|
</div>
|
2003-05-22 08:12:53 -04:00
|
|
|
|
|
|
|
<?php
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
|
|
case 'IErightclick':
|
|
|
|
|
|
|
|
|
2004-03-01 01:13:32 -05:00
|
|
|
$bookmarklet_tbpb = (get_settings('use_trackback')) ? '&trackback=1' : '';
|
|
|
|
$bookmarklet_tbpb .= (get_settings('use_pingback')) ? '&pingback=1' : '';
|
|
|
|
$bookmarklet_height= (get_settings('use_trackback')) ? 590 : 550;
|
2003-05-22 08:12:53 -04:00
|
|
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
<div class="menutop"> IE one-click bookmarklet</div>
|
|
|
|
|
|
|
|
<table width="100%" cellpadding="20">
|
|
|
|
<tr><td>
|
|
|
|
|
|
|
|
<p>To have a one-click bookmarklet, just copy and paste this<br />into a new text file:</p>
|
|
|
|
<?php
|
2004-03-01 01:13:32 -05:00
|
|
|
$regedit = "REGEDIT4\r\n[HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\MenuExt\Post To &WP : ". get_settings('blogname') ."]\r\n@=\"javascript:doc=external.menuArguments.document;Q=doc.selection.createRange().text;void(btw=window.open('". get_settings('siteurl') ."/wp-admin/bookmarklet.php?text='+escape(Q)+'".$bookmarklet_tbpb."&popupurl='+escape(doc.location.href)+'&popuptitle='+escape(doc.title),'bookmarklet','scrollbars=no,width=480,height=".$bookmarklet_height.",left=100,top=150,status=yes'));btw.focus();\"\r\n\"contexts\"=hex:31\"";
|
2003-05-22 08:12:53 -04:00
|
|
|
?>
|
|
|
|
<pre style="margin: 20px; background-color: #cccccc; border: 1px dashed #333333; padding: 5px; font-size: 12px;"><?php echo $regedit; ?></pre>
|
2003-05-23 18:43:58 -04:00
|
|
|
<p>Save it as wordpress.reg, and double-click on this file in an Explorer<br />
|
2003-05-22 08:12:53 -04:00
|
|
|
window. Answer Yes to the question, and restart Internet Explorer.<br /><br />
|
|
|
|
That's it, you can now right-click in an IE window and select <br />
|
2003-05-23 18:43:58 -04:00
|
|
|
'Post to WP' to make the bookmarklet appear. :)</p>
|
2003-05-22 08:12:53 -04:00
|
|
|
|
|
|
|
<p align="center">
|
2004-02-01 06:03:43 -05:00
|
|
|
<form>
|
2003-05-22 08:12:53 -04:00
|
|
|
<input class="search" type="button" value="1" name="Close this window" />
|
2004-02-01 06:03:43 -05:00
|
|
|
</form>
|
2003-05-22 08:12:53 -04:00
|
|
|
</p>
|
|
|
|
</td></tr>
|
|
|
|
</table>
|
|
|
|
<?php
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
|
|
default:
|
|
|
|
|
2003-12-31 19:55:31 -05:00
|
|
|
include_once('admin-header.php');
|
2003-05-22 08:12:53 -04:00
|
|
|
$profiledata=get_userdata($user_ID);
|
|
|
|
|
2004-03-01 01:13:32 -05:00
|
|
|
$bookmarklet_tbpb = (get_settings('use_trackback')) ? '&trackback=1' : '';
|
|
|
|
$bookmarklet_tbpb .= (get_settings('use_pingback')) ? '&pingback=1' : '';
|
|
|
|
$bookmarklet_height= (get_settings('use_trackback')) ? 480 : 440;
|
2003-05-22 08:12:53 -04:00
|
|
|
|
|
|
|
?>
|
2004-05-07 19:56:33 -04:00
|
|
|
<?php if (isset($updated)) { ?>
|
2004-04-19 04:09:27 -04:00
|
|
|
<div class="updated">
|
2004-04-24 21:25:41 -04:00
|
|
|
<p><strong><?php _e('Profile updated.') ?></strong></p>
|
2003-12-31 19:55:31 -05:00
|
|
|
</div>
|
|
|
|
<?php } ?>
|
|
|
|
<div class="wrap">
|
2004-05-19 03:09:32 -04:00
|
|
|
<h2><?php _e('Profile'); ?></h2>
|
2003-12-10 19:22:36 -05:00
|
|
|
<form name="profile" id="profile" action="profile.php" method="post">
|
2004-02-01 06:03:43 -05:00
|
|
|
<p>
|
2003-06-01 02:45:53 -04:00
|
|
|
<input type="hidden" name="action" value="update" />
|
|
|
|
<input type="hidden" name="checkuser_id" value="<?php echo $user_ID ?>" />
|
|
|
|
</p>
|
2004-05-19 03:09:32 -04:00
|
|
|
|
2003-12-31 19:55:31 -05:00
|
|
|
<style type="text/css" media="screen">
|
|
|
|
th { text-align: right; }
|
|
|
|
</style>
|
|
|
|
<table width="99%" border="0" cellspacing="2" cellpadding="3">
|
2004-05-19 03:05:40 -04:00
|
|
|
<tr>
|
|
|
|
<th width="33%" scope="row"><?php _e('Login:') ?></th>
|
|
|
|
<td width="73%"><?php echo $profiledata->user_login; ?></td>
|
2004-05-19 03:09:32 -04:00
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<th scope="row"><?php _e('Level:') ?></th>
|
|
|
|
<td><?php echo $profiledata->user_level; ?></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
|
|
|
<th scope="row"><?php _e('Posts:') ?></th>
|
|
|
|
<td> <?php
|
|
|
|
$posts = get_usernumposts($user_ID);
|
|
|
|
echo $posts;
|
|
|
|
?></td>
|
|
|
|
</tr>
|
2003-12-31 19:55:31 -05:00
|
|
|
<tr>
|
2004-05-19 03:09:32 -04:00
|
|
|
<th scope="row"><?php _e('First name:') ?></th>
|
|
|
|
<td><input type="text" name="newuser_firstname" id="newuser_firstname" value="<?php echo $profiledata->user_firstname ?>" /></td>
|
2003-12-31 19:55:31 -05:00
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Last name:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_lastname" id="newuser_lastname2" value="<?php echo $profiledata->user_lastname ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Profile:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><textarea name="user_description" rows="5" id="textarea2" style="width: 99%; "><?php echo $profiledata->user_description ?></textarea></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Nickname:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_nickname" id="newuser_nickname2" value="<?php echo $profiledata->user_nickname ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Email:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_email" id="newuser_email2" value="<?php echo $profiledata->user_email ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Website:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_url" id="newuser_url2" value="<?php echo $profiledata->user_url ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('ICQ:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_icq" id="newuser_icq2" value="<?php if ($profiledata->user_icq > 0) { echo $profiledata->user_icq; } ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('AIM:') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_aim" id="newuser_aim2" value="<?php echo $profiledata->user_aim ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('MSN IM:') ?> </th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="text" name="newuser_msn" id="newuser_msn2" value="<?php echo $profiledata->user_msn ?>" /></td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Yahoo IM:') ?> </th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td> <input type="text" name="newuser_yim" id="newuser_yim2" value="<?php echo $profiledata->user_yim ?>" /> </td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('Identity on blog:') ?> </th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><select name="newuser_idmode">
|
|
|
|
<option value="nickname"<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
if ($profiledata->user_idmode == 'nickname')
|
|
|
|
echo " selected"; ?>><?php echo $profiledata->user_nickname ?></option>
|
2003-12-31 19:55:31 -05:00
|
|
|
<option value="login"<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
if ($profiledata->user_idmode=="login")
|
|
|
|
echo " selected"; ?>><?php echo $profiledata->user_login ?></option>
|
2003-12-31 19:55:31 -05:00
|
|
|
<option value="firstname"<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
if ($profiledata->user_idmode=="firstname")
|
|
|
|
echo " selected"; ?>><?php echo $profiledata->user_firstname ?></option>
|
2003-12-31 19:55:31 -05:00
|
|
|
<option value="lastname"<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
if ($profiledata->user_idmode=="lastname")
|
|
|
|
echo " selected"; ?>><?php echo $profiledata->user_lastname ?></option>
|
2003-12-31 19:55:31 -05:00
|
|
|
<option value="namefl"<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
if ($profiledata->user_idmode=="namefl")
|
|
|
|
echo " selected"; ?>><?php echo $profiledata->user_firstname." ".$profiledata->user_lastname ?></option>
|
2003-12-31 19:55:31 -05:00
|
|
|
<option value="namelf"<?php
|
2003-06-01 02:45:53 -04:00
|
|
|
if ($profiledata->user_idmode=="namelf")
|
|
|
|
echo " selected"; ?>><?php echo $profiledata->user_lastname." ".$profiledata->user_firstname ?></option>
|
2003-12-31 19:55:31 -05:00
|
|
|
</select> </td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2004-04-24 21:25:41 -04:00
|
|
|
<th scope="row"><?php _e('New <strong>Password</strong> (Leave blank to stay the same.)') ?></th>
|
2003-12-31 19:55:31 -05:00
|
|
|
<td><input type="password" name="pass1" size="16" value="" />
|
2004-04-21 18:49:11 -04:00
|
|
|
<br>
|
2003-12-31 19:55:31 -05:00
|
|
|
<input type="password" name="pass2" size="16" value="" /></td>
|
|
|
|
</tr>
|
|
|
|
</table>
|
2004-04-15 05:15:56 -04:00
|
|
|
<p class="submit">
|
2004-05-07 21:15:03 -04:00
|
|
|
<input type="submit" value="<?php _e('Update Profile »') ?>" name="submit" />
|
2004-04-15 05:15:56 -04:00
|
|
|
</p>
|
2003-12-31 19:55:31 -05:00
|
|
|
</div>
|
2004-02-01 06:03:43 -05:00
|
|
|
</form>
|
2003-12-31 19:55:31 -05:00
|
|
|
</div>
|
2004-02-01 06:03:43 -05:00
|
|
|
<?php if ($is_gecko && $profiledata->user_level != 0) { ?>
|
2003-12-31 19:55:31 -05:00
|
|
|
<div class="wrap">
|
2003-06-01 02:45:53 -04:00
|
|
|
<script language="JavaScript" type="text/javascript">
|
2003-05-22 08:12:53 -04:00
|
|
|
function addPanel()
|
|
|
|
{
|
|
|
|
if ((typeof window.sidebar == "object") && (typeof window.sidebar.addPanel == "function"))
|
2004-03-01 01:13:32 -05:00
|
|
|
window.sidebar.addPanel("WordPress Post: <?php echo get_settings('blogname'); ?>","<?php echo get_settings('siteurl'); ?>/wp-admin/sidebar.php","");
|
2003-05-22 08:12:53 -04:00
|
|
|
else
|
2004-04-24 21:25:41 -04:00
|
|
|
alert(<?php __("'No Sidebar found! You must use Mozilla 0.9.4 or later!'") ?>);
|
2003-05-22 08:12:53 -04:00
|
|
|
}
|
|
|
|
</script>
|
2004-05-23 13:24:38 -04:00
|
|
|
<strong><?php _e('SideBar') ?></strong><br />
|
|
|
|
<?php _e('Add the <a href="#" onClick="addPanel()">WordPress Sidebar</a>!') ?>
|
2003-06-01 02:45:53 -04:00
|
|
|
<?php } elseif (($is_winIE) || ($is_macIE)) { ?>
|
2004-05-23 13:24:38 -04:00
|
|
|
<strong><?php _e('SideBar') ?></strong><br />
|
|
|
|
<?php __('Add this link to your favorites:') ?><br />
|
|
|
|
<a href="javascript:Q='';if(top.frames.length==0)Q=document.selection.createRange().text;void(_search=open('<?php echo get_settings('siteurl');
|
|
|
|
?>/wp-admin/sidebar.php?text='+escape(Q)+'&popupurl='+escape(location.href)+'&popuptitle='+escape(document.title),'_search'))"><?php _e('WordPress Sidebar') ?></a>.
|
2003-12-31 19:55:31 -05:00
|
|
|
|
|
|
|
</div>
|
|
|
|
<?php } ?>
|
2003-05-22 08:12:53 -04:00
|
|
|
<?php
|
|
|
|
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* </Profile | My Profile> */
|
2004-02-09 04:56:57 -05:00
|
|
|
include('admin-footer.php');
|
2004-04-24 21:25:41 -04:00
|
|
|
?>
|