Elgg
Version 2.3
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
views
default
output
friendlytime.php
Go to the documentation of this file.
1
<?php
9
$friendly_time
=
elgg_get_friendly_time
(
$vars
[
'time'
]);
10
$attributes
= array();
11
$attributes
[
'title'
] = date(
elgg_echo
(
'friendlytime:date_format'
),
$vars
[
'time'
]);
12
$attributes
[
'datetime'
] = date(
'c'
,
$vars
[
'time'
]);
13
$attrs
=
elgg_format_attributes
(
$attributes
);
14
15
echo
"<time $attrs>$friendly_time</time>"
;
$attrs
$attrs
Definition:
friendlytime.php:13
elgg_echo
elgg_echo($message_key, $args=array(), $language="")
Given a message key, returns an appropriately translated full-text string.
Definition:
languages.php:21
$vars
$vars['entity']
Definition:
plugin_settings.php:15
echo
elgg echo
Translates a string.
Definition:
languages.js:48
elgg_format_attributes
elgg_format_attributes(array $attrs=array())
Converts an associative array into a string of well-formed HTML/XML attributes Returns a concatenated...
Definition:
output.php:129
elgg_get_friendly_time
elgg_get_friendly_time($time, $current_time=null)
Formats a UNIX timestamp in a friendly way (eg "less than a minute ago")
Definition:
output.php:375
$attributes
$attributes
Definition:
friendlytime.php:10
$friendly_time
$friendly_time
Friendly time Translates an epoch time into a human-readable time.
Definition:
friendlytime.php:9
Generated on Sat Dec 21 2024 00:01:05 for Elgg by
1.8.11