| 1 |
<?php |
<?php |
| 2 |
// $Id: xmlsitemap_user.module,v 1.12.2.52 2009/03/01 01:34:19 kiam Exp $ |
// $Id: xmlsitemap_user.module,v 1.12.2.53 2009/03/01 01:57:41 kiam Exp $ |
| 3 |
|
|
| 4 |
/** |
/** |
| 5 |
* @file |
* @file |
| 112 |
case 'insert': |
case 'insert': |
| 113 |
$row = new stdClass(); |
$row = new stdClass(); |
| 114 |
$row->uid = $account->uid; |
$row->uid = $account->uid; |
| 115 |
$row->changed = time(); |
$row->changed = XMLSITEMAP_TIME; |
| 116 |
$row->previously_changed = $account->created; |
$row->previously_changed = $account->created; |
| 117 |
$row->priority_override = isset($edit['xmlsitemap_user_priority']) ? $edit['xmlsitemap_user_priority'] : -2.0; |
$row->priority_override = isset($edit['xmlsitemap_user_priority']) ? $edit['xmlsitemap_user_priority'] : -2.0; |
| 118 |
drupal_write_record('xmlsitemap_user', $row); |
drupal_write_record('xmlsitemap_user', $row); |
| 124 |
$row = new stdClass(); |
$row = new stdClass(); |
| 125 |
$row->uid = $account->uid; |
$row->uid = $account->uid; |
| 126 |
$row->previously_changed = $account->created; |
$row->previously_changed = $account->created; |
| 127 |
$row->changed = time(); |
$row->changed = XMLSITEMAP_TIME; |
| 128 |
} |
} |
| 129 |
else { |
else { |
| 130 |
$row = $result; |
$row = $result; |
| 131 |
$row->previously_changed = $row->changed; |
$row->previously_changed = $row->changed; |
| 132 |
$row->changed = time(); |
$row->changed = XMLSITEMAP_TIME; |
| 133 |
} |
} |
| 134 |
if (module_exists('comment')) { |
if (module_exists('comment')) { |
| 135 |
$row->comments = (integer) db_result(db_query("SELECT COUNT(cid) FROM {comments} WHERE uid = %d", $user->uid)); |
$row->comments = (integer) db_result(db_query("SELECT COUNT(cid) FROM {comments} WHERE uid = %d", $user->uid)); |
| 198 |
$row->loc = 'user/'. $user->uid; |
$row->loc = 'user/'. $user->uid; |
| 199 |
$row->id = $user->uid; |
$row->id = $user->uid; |
| 200 |
$row->changed = $user->changed; |
$row->changed = $user->changed; |
| 201 |
$row->changefreq = max(time() - $user->changed, empty($user->previously_changed) ? 0 : $user->changed - $user->previously_changed); |
$row->changefreq = max(XMLSITEMAP_TIME - $user->changed, empty($user->previously_changed) ? 0 : $user->changed - $user->previously_changed); |
| 202 |
if ($user->priority_override != -2.0) { |
if ($user->priority_override != -2.0) { |
| 203 |
$row->priority = $user->priority_override; |
$row->priority = $user->priority_override; |
| 204 |
} |
} |