/[drupal]/contributions/themes/clearblue/template.php
ViewVC logotype

Contents of /contributions/themes/clearblue/template.php

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download) (as text)
Mon Dec 29 00:23:59 2008 UTC (10 months, 4 weeks ago) by ktleow
Branch: MAIN
CVS Tags: DRUPAL-6--1-0-BETA1, HEAD
File MIME type: text/x-php
*** empty log message ***
1 <?php
2
3 /*****************************************************************************
4 Replace feed icon with theme's feed icon.
5 *****************************************************************************/
6 function phptemplate_feed_icon($url, $title) {
7 if ($image = theme('image', path_to_theme() . '/images/rss.png', t('Syndicate content'), $title)) {
8 return '<a href="'. check_url($url) .'" class="feed-icon">'. $image .'</a>';
9 }
10 }
11
12 /*****************************************************************************
13 Override theme_username() function to remove "(not verified)" from comments.
14 *****************************************************************************/
15 function phptemplate_username($object) {
16 if ($object->uid && $object->name) {
17 if (drupal_strlen($object->name) > 20) {
18 $name = drupal_substr($object->name, 0, 15) .'...';
19 }
20 else {
21 $name = $object->name;
22 }
23
24 if (user_access('access user profiles')) {
25 $output = l($name, 'user/'. $object->uid, array('attributes' => array('title' => t('View user profile.'))));
26 }
27 else {
28 $output = check_plain($name);
29 }
30 }
31 else if ($object->name) {
32 if (!empty($object->homepage)) {
33 $output = l($object->name, $object->homepage, array('attributes' => array('rel' => 'nofollow')));
34 }
35 else {
36 $output = check_plain($object->name);
37 }
38 }
39 else {
40 $output = variable_get('anonymous', t('Anonymous'));
41 }
42
43 return $output;
44 }

  ViewVC Help
Powered by ViewVC 1.1.2