diff options
69 files changed, 93 insertions, 91 deletions
@@ -1,4 +1,5 @@ <?php +/** @file */ require_once('include/config.php'); require_once('include/network.php'); diff --git a/include/BaseObject.php b/include/BaseObject.php index 200831e15..4bfac5fa0 100644 --- a/include/BaseObject.php +++ b/include/BaseObject.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ if(class_exists('BaseObject')) return; diff --git a/include/Contact.php b/include/Contact.php index 36f4cbcf7..6978b45bc 100644 --- a/include/Contact.php +++ b/include/Contact.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function abook_connections($channel_id, $sql_conditions = '') { diff --git a/include/ConversationObject.php b/include/ConversationObject.php index 37633369e..7e412803b 100644 --- a/include/ConversationObject.php +++ b/include/ConversationObject.php @@ -1,4 +1,5 @@ -<?php +<?php /** @file */ + if(class_exists('Conversation')) return; diff --git a/include/ItemObject.php b/include/ItemObject.php index a44784b42..94afaaac4 100644 --- a/include/ItemObject.php +++ b/include/ItemObject.php @@ -1,4 +1,5 @@ -<?php +<?php /** @file */ + if(class_exists('Item')) return; diff --git a/include/Photo.php b/include/Photo.php index de3d30c39..d470de0ad 100644 --- a/include/Photo.php +++ b/include/Photo.php @@ -1,6 +1,6 @@ -<?php +<?php /** @file */ + -if(! class_exists("Photo")) { class Photo { private $image; @@ -605,7 +605,7 @@ class Photo { } return $r; } -}} +} /** diff --git a/include/ProtoDriver.php b/include/ProtoDriver.php index a39881e9a..7585a0135 100644 --- a/include/ProtoDriver.php +++ b/include/ProtoDriver.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /* * Abstraction class for dealing with alternate networks (which of course do not exist, hence the abstraction) diff --git a/include/Scrape.php b/include/Scrape.php index 806106ef1..b1138091c 100644 --- a/include/Scrape.php +++ b/include/Scrape.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('library/HTML5/Parser.php'); require_once('include/crypto.php'); diff --git a/include/account.php b/include/account.php index a31dbba4b..6f3499a0f 100644 --- a/include/account.php +++ b/include/account.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/config.php'); require_once('include/network.php'); diff --git a/include/acl_selectors.php b/include/acl_selectors.php index f4dacb74a..eabd2169f 100644 --- a/include/acl_selectors.php +++ b/include/acl_selectors.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /** * */ diff --git a/include/activities.php b/include/activities.php index ced9f3d18..089418635 100644 --- a/include/activities.php +++ b/include/activities.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function profile_activity($changed, $value) { $a = get_app(); diff --git a/include/api.php b/include/api.php index 4d74eb298..1456ec29a 100644 --- a/include/api.php +++ b/include/api.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("bbcode.php"); require_once("datetime.php"); diff --git a/include/attach.php b/include/attach.php index 64d6a1689..10a2b91f2 100644 --- a/include/attach.php +++ b/include/attach.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /* * File/attach API with the potential for revision control. diff --git a/include/auth.php b/include/auth.php index 14751f5a2..59145df83 100644 --- a/include/auth.php +++ b/include/auth.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/security.php'); diff --git a/include/bb2diaspora.php b/include/bb2diaspora.php index ee070b4fe..8d3089a29 100644 --- a/include/bb2diaspora.php +++ b/include/bb2diaspora.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("include/oembed.php"); require_once("include/event.php"); diff --git a/include/bbcode.php b/include/bbcode.php index d43929ef5..6d29954cb 100644 --- a/include/bbcode.php +++ b/include/bbcode.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("include/oembed.php"); require_once('include/event.php'); diff --git a/include/cache.php b/include/cache.php index 567046f7a..b546cd0e9 100644 --- a/include/cache.php +++ b/include/cache.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /** * cache api diff --git a/include/cli_startup.php b/include/cli_startup.php index d9f6ecb8e..863f97d7c 100644 --- a/include/cli_startup.php +++ b/include/cli_startup.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('boot.php'); diff --git a/include/config.php b/include/config.php index 44606e329..6e1196af1 100644 --- a/include/config.php +++ b/include/config.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /** * diff --git a/include/contact_selectors.php b/include/contact_selectors.php index 76d005305..adcca2c52 100644 --- a/include/contact_selectors.php +++ b/include/contact_selectors.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function contact_profile_assign($current,$foreign_net) { diff --git a/include/contact_widgets.php b/include/contact_widgets.php index 54e2ad967..ca212796f 100644 --- a/include/contact_widgets.php +++ b/include/contact_widgets.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function follow_widget() { diff --git a/include/conversation.php b/include/conversation.php index 285c64cbb..90a6aaa7f 100644 --- a/include/conversation.php +++ b/include/conversation.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/items.php'); diff --git a/include/cronhooks.php b/include/cronhooks.php index 9ff8141c4..a314593d2 100644 --- a/include/cronhooks.php +++ b/include/cronhooks.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('boot.php'); require_once('include/cli_startup.php'); diff --git a/include/crypto.php b/include/crypto.php index a646910a1..ed32356ec 100644 --- a/include/crypto.php +++ b/include/crypto.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('library/ASNValue.class.php'); require_once('library/asn1.php'); diff --git a/include/datetime.php b/include/datetime.php index a573e43a2..94c2e4f1c 100644 --- a/include/datetime.php +++ b/include/datetime.php @@ -1,8 +1,8 @@ -<?php +<?php /** @file */ // two-level sort for timezones. -if(! function_exists('timezone_cmp')) { + function timezone_cmp($a, $b) { if(strstr($a,'/') && strstr($b,'/')) { if ( t($a) == t($b)) return 0; @@ -12,10 +12,10 @@ function timezone_cmp($a, $b) { if(strstr($b,'/')) return 1; if ( t($a) == t($b)) return 0; return ( t($a) < t($b)) ? -1 : 1; -}} +} // emit a timezone selector grouped (primarily) by continent -if(! function_exists('select_timezone')) { + function select_timezone($current = 'America/Los_Angeles') { $timezone_identifiers = DateTimeZone::listIdentifiers(); @@ -52,13 +52,13 @@ function select_timezone($current = 'America/Los_Angeles') { } $o .= '</optgroup></select>'; return $o; -}} +} // return a select using 'field_select_raw' template, with timezones // groupped (primarily) by continent // arguments follow convetion as other field_* template array: // 'name', 'label', $value, 'help' -if (!function_exists('field_timezone')){ + function field_timezone($name='timezone', $label='', $current = 'America/Los_Angeles', $help){ $options = select_timezone($current); $options = str_replace('<select id="timezone_select" name="timezone">','', $options); @@ -69,7 +69,7 @@ function field_timezone($name='timezone', $label='', $current = 'America/Los_Ang '$field' => array($name, $label, $current, $help, $options), )); -}} +} // General purpose date parse/convert function. // $from = source timezone @@ -77,7 +77,7 @@ function field_timezone($name='timezone', $label='', $current = 'America/Los_Ang // $s = some parseable date/time string // $fmt = output format -if(! function_exists('datetime_convert')) { + function datetime_convert($from = 'UTC', $to = 'UTC', $s = 'now', $fmt = "Y-m-d H:i:s") { // Defaults to UTC if nothing is set, but throws an exception if set to empty string. @@ -124,7 +124,7 @@ function datetime_convert($from = 'UTC', $to = 'UTC', $s = 'now', $fmt = "Y-m-d $d->setTimeZone($to_obj); return($d->format($fmt)); -}} +} // wrapper for date selector, tailored for use in birthday fields @@ -180,7 +180,7 @@ function datesel_format($f) { // $m = already selected month // $d = already selected day -if(! function_exists('datesel')) { + function datesel($f,$pre,$ymin,$ymax,$allow_blank,$y,$m,$d) { $o = ''; @@ -231,9 +231,9 @@ function datesel($f,$pre,$ymin,$ymax,$allow_blank,$y,$m,$d) { $o .= "</select>"; return $o; -}} +} + -if(! function_exists('timesel')) { function timesel($pre,$h,$m) { $o = ''; @@ -250,7 +250,7 @@ function timesel($pre,$h,$m) { $o .= "</select>"; return $o; -}} +} @@ -264,7 +264,7 @@ function timesel($pre,$h,$m) { // Results relative to current timezone // Limited to range of timestamps -if(! function_exists('relative_date')) { + function relative_date($posted_date,$format = null) { $localtime = datetime_convert('UTC',date_default_timezone_get(),$posted_date); @@ -300,7 +300,7 @@ function relative_date($posted_date,$format = null) { return sprintf( $format,$r, (($r == 1) ? $str[0] : $str[1])); } } -}} +} @@ -341,7 +341,7 @@ function age($dob,$owner_tz = '',$viewer_tz = '') { // $month[1] = 'January'; // to match human usage. -if(! function_exists('get_dim')) { + function get_dim($y,$m) { $dim = array( 0, @@ -353,7 +353,7 @@ function get_dim($y,$m) { if(((($y % 4) == 0) && (($y % 100) != 0)) || (($y % 400) == 0)) return 29; return $dim[2]; -}} +} // Returns the first day in month for a given month, year @@ -361,11 +361,11 @@ function get_dim($y,$m) { // returns 0 = Sunday through 6 = Saturday // Months start at 1. -if(! function_exists('get_first_dim')) { + function get_first_dim($y,$m) { $d = sprintf('%04d-%02d-01 00:00', intval($y), intval($m)); return datetime_convert('UTC','UTC',$d,'w'); -}} +} // output a calendar for the given month, year. // if $links are provided (array), e.g. $links[12] => 'http://mylink' , @@ -376,8 +376,6 @@ function get_first_dim($y,$m) { // TODO: provide (prev,next) links, define class variations for different size calendars - -if(! function_exists('cal')) { function cal($y = 0,$m = 0, $links = false, $class='') { @@ -442,6 +440,6 @@ function cal($y = 0,$m = 0, $links = false, $class='') { $o .= '</tr></table>'."\r\n"; return $o; -}} +} diff --git a/include/dba.php b/include/dba.php index d1502af12..3117744aa 100644 --- a/include/dba.php +++ b/include/dba.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/datetime.php'); diff --git a/include/deliver.php b/include/deliver.php index 471ea580d..c5ed35c87 100644 --- a/include/deliver.php +++ b/include/deliver.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/cli_startup.php'); require_once('include/zot.php'); diff --git a/include/dir_fns.php b/include/dir_fns.php index da74cc57f..677420c54 100644 --- a/include/dir_fns.php +++ b/include/dir_fns.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/permissions.php'); diff --git a/include/directory.php b/include/directory.php index b0b975358..9c5f8d644 100644 --- a/include/directory.php +++ b/include/directory.php @@ -1,4 +1,5 @@ -g<?php +<?php /** @file */ + require_once('boot.php'); require_once('include/zot.php'); require_once('include/cli_startup.php'); diff --git a/include/enotify.php b/include/enotify.php index 32f4cc2e7..c24c15188 100644 --- a/include/enotify.php +++ b/include/enotify.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function notification($params) { diff --git a/include/event.php b/include/event.php index 8bf65016f..6a35bd0ad 100644 --- a/include/event.php +++ b/include/event.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function format_event_html($ev) { diff --git a/include/expire.php b/include/expire.php index 3a914a41d..f1002b890 100644 --- a/include/expire.php +++ b/include/expire.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('boot.php'); require_once('include/cli_startup.php'); diff --git a/include/fcontact.php b/include/fcontact.php index 8821a985f..50ac5f3f3 100644 --- a/include/fcontact.php +++ b/include/fcontact.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ diff --git a/include/features.php b/include/features.php index 094e96c78..23e5485e9 100644 --- a/include/features.php +++ b/include/features.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /* * Features management diff --git a/include/follow.php b/include/follow.php index a094a979f..88418926b 100644 --- a/include/follow.php +++ b/include/follow.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ // diff --git a/include/friendica_smarty.php b/include/friendica_smarty.php index 2f4694c58..b9ed2e982 100644 --- a/include/friendica_smarty.php +++ b/include/friendica_smarty.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("library/Smarty/libs/Smarty.class.php"); diff --git a/include/gprobe.php b/include/gprobe.php index 2cc87d149..48c1c8e14 100644 --- a/include/gprobe.php +++ b/include/gprobe.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/cli_startup.php'); require_once('include/zot.php'); diff --git a/include/group.php b/include/group.php index 6042acbb4..52a0fe522 100644 --- a/include/group.php +++ b/include/group.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function group_add($uid,$name) { diff --git a/include/html2bbcode.php b/include/html2bbcode.php index 985c36eaa..9bb755da5 100644 --- a/include/html2bbcode.php +++ b/include/html2bbcode.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /* html2bbcode.php Converter for HTML to BBCode diff --git a/include/html2plain.php b/include/html2plain.php index b8c9c440d..b86d88710 100644 --- a/include/html2plain.php +++ b/include/html2plain.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once "html2bbcode.php"; function breaklines($line, $level, $wraplength = 75) diff --git a/include/identity.php b/include/identity.php index 9d798866f..ae3aab972 100644 --- a/include/identity.php +++ b/include/identity.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/zot.php'); require_once('include/crypto.php'); diff --git a/include/iquery.php b/include/iquery.php index 0d51134a4..e3ac215b7 100644 --- a/include/iquery.php +++ b/include/iquery.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function network_query($a,$arr) { diff --git a/include/items.php b/include/items.php index 3fd43ca4e..5e67b7935 100755 --- a/include/items.php +++ b/include/items.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/bbcode.php'); require_once('include/oembed.php'); diff --git a/include/js_strings.php b/include/js_strings.php index 60a3e1a86..2e4f70774 100644 --- a/include/js_strings.php +++ b/include/js_strings.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function js_strings() { return replace_macros(get_markup_template('js_strings.tpl'), array( diff --git a/include/language.php b/include/language.php index 56d5f1cf4..853b6ebee 100644 --- a/include/language.php +++ b/include/language.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /** diff --git a/include/message.php b/include/message.php index 00cf30512..4fd10ad8c 100644 --- a/include/message.php +++ b/include/message.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /* Private Message backend API */ diff --git a/include/nav.php b/include/nav.php index 5490d6cd4..6ad7b58d0 100644 --- a/include/nav.php +++ b/include/nav.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function nav(&$a) { diff --git a/include/network.php b/include/network.php index 555e76802..a31c64f1b 100644 --- a/include/network.php +++ b/include/network.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ diff --git a/include/notifier.php b/include/notifier.php index b22f77d91..60cae2dc0 100644 --- a/include/notifier.php +++ b/include/notifier.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("boot.php"); require_once('include/queue_fn.php'); diff --git a/include/notify.php b/include/notify.php index 3bfd1e58c..aa96fa279 100644 --- a/include/notify.php +++ b/include/notify.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function format_notification($item) { diff --git a/include/oauth.php b/include/oauth.php index 99fc16eef..2f70f21fb 100644 --- a/include/oauth.php +++ b/include/oauth.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ /** * OAuth server * Based on oauth2-php <http://code.google.com/p/oauth2-php/> diff --git a/include/oembed.php b/include/oembed.php index 6fc4c5371..7ef6d561f 100755 --- a/include/oembed.php +++ b/include/oembed.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function oembed_replacecb($matches){ // logger('oembedcb'); $embedurl=$matches[1]; diff --git a/include/onepoll.php b/include/onepoll.php index 8b0c5211b..a225edfd8 100644 --- a/include/onepoll.php +++ b/include/onepoll.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('boot.php'); require_once('include/cli_startup.php'); diff --git a/include/permissions.php b/include/permissions.php index 72e002ace..97f1fe8e6 100644 --- a/include/permissions.php +++ b/include/permissions.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function get_perms() { diff --git a/include/photos.php b/include/photos.php index 885d2f958..b4e05ccca 100644 --- a/include/photos.php +++ b/include/photos.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/permissions.php'); require_once('include/items.php'); diff --git a/include/plugin.php b/include/plugin.php index 6660fba59..281488791 100644 --- a/include/plugin.php +++ b/include/plugin.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("include/friendica_smarty.php"); diff --git a/include/poller.php b/include/poller.php index ef4b93fe7..6f4736855 100644 --- a/include/poller.php +++ b/include/poller.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('boot.php'); require_once('include/cli_startup.php'); diff --git a/include/profile_advanced.php b/include/profile_advanced.php index 749c79a3b..f008d1c8f 100644 --- a/include/profile_advanced.php +++ b/include/profile_advanced.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function advanced_profile(&$a) { diff --git a/include/profile_selectors.php b/include/profile_selectors.php index 8d29fd099..1ffcd49be 100644 --- a/include/profile_selectors.php +++ b/include/profile_selectors.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function gender_selector($current="",$suffix="") { diff --git a/include/queue.php b/include/queue.php index c74a08ac9..44816673c 100644 --- a/include/queue.php +++ b/include/queue.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once("boot.php"); require_once('include/cli_startup.php'); require_once('include/queue_fn.php'); diff --git a/include/queue_fn.php b/include/queue_fn.php index c9782b939..512edb531 100644 --- a/include/queue_fn.php +++ b/include/queue_fn.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function update_queue_time($id) { logger('queue: requeue item ' . $id); diff --git a/include/security.php b/include/security.php index e691939fb..29a0fc0bc 100644 --- a/include/security.php +++ b/include/security.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function authenticate_success($user_record, $login_initial = false, $interactive = false,$return = false,$update_lastlog = false) { diff --git a/include/session.php b/include/session.php index 6c32e299f..0a6576bdd 100644 --- a/include/session.php +++ b/include/session.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ // Session management functions. These provide database storage of PHP // session info. diff --git a/include/socgraph.php b/include/socgraph.php index 7de51b36b..3c77a59a1 100644 --- a/include/socgraph.php +++ b/include/socgraph.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/zot.php'); diff --git a/include/system_unavailable.php b/include/system_unavailable.php index bd7196cdf..dfe7c5e6b 100644 --- a/include/system_unavailable.php +++ b/include/system_unavailable.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ function system_down() { echo <<< EOT diff --git a/include/template_processor.php b/include/template_processor.php index 61526e570..0b4b4142f 100644 --- a/include/template_processor.php +++ b/include/template_processor.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ define ("KEY_NOT_EXISTS", '^R_key_not_Exists^'); class Template { diff --git a/include/text.php b/include/text.php index 523970bf4..b6fa49f81 100644 --- a/include/text.php +++ b/include/text.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ // This is our template processor. // $s is the string requiring macro substitution. diff --git a/include/zot.php b/include/zot.php index 524f958ad..60fec9316 100644 --- a/include/zot.php +++ b/include/zot.php @@ -1,4 +1,4 @@ -<?php +<?php /** @file */ require_once('include/crypto.php'); require_once('include/items.php'); diff --git a/version.inc b/version.inc index 1cbdaf030..49d6ae9a6 100644 --- a/version.inc +++ b/version.inc @@ -1 +1 @@ -2013-02-24.234 +2013-02-25.235 |