From 757037c3bfe7c8f23a8dbda2f7be7b1dfaacf739 Mon Sep 17 00:00:00 2001 From: fabrixxm Date: Thu, 7 Jun 2012 08:28:10 -0400 Subject: [PATCH 1/2] events: fix select events query select events that starts before display start date and/or ends after display end date. --- mod/events.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) mode change 100644 => 100755 mod/events.php diff --git a/mod/events.php b/mod/events.php old mode 100644 new mode 100755 index 069046ff9d..2a6fb692eb --- a/mod/events.php +++ b/mod/events.php @@ -230,8 +230,8 @@ function events_content(&$a) { $r = q("SELECT `event`.*, `item`.`id` AS `itemid`,`item`.`plink`, `item`.`author-name`, `item`.`author-avatar`, `item`.`author-link` FROM `event` LEFT JOIN `item` ON `item`.`event-id` = `event`.`id` WHERE `event`.`uid` = %d - AND (( `adjust` = 0 AND `start` >= '%s' AND `start` <= '%s' ) - OR ( `adjust` = 1 AND `start` >= '%s' AND `start` <= '%s' )) ", + AND (( `adjust` = 0 AND `finish` >= '%s' AND `start` <= '%s' ) + OR ( `adjust` = 1 AND `finish` >= '%s' AND `start` <= '%s' )) ", intval(local_user()), dbesc($start), dbesc($finish), From 1d832618a4340526092fce9e49f4580f767e1526 Mon Sep 17 00:00:00 2001 From: fabrixxm Date: Thu, 7 Jun 2012 08:49:33 -0400 Subject: [PATCH 2/2] fix a random profile error message --- include/oembed.php | 4 +++- view/oembed_video.tpl | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) mode change 100644 => 100755 include/oembed.php mode change 100644 => 100755 view/oembed_video.tpl diff --git a/include/oembed.php b/include/oembed.php old mode 100644 new mode 100755 index 1f45d28143..e2504b7eb8 --- a/include/oembed.php +++ b/include/oembed.php @@ -65,7 +65,8 @@ function oembed_fetch_url($embedurl){ } function oembed_format_object($j){ - $embedurl = $j->embedurl; + $a = get_app(); + $embedurl = $j->embedurl; $jhtml = oembed_iframe($j->embedurl,(isset($j->width) ? $j->width : null), (isset($j->height) ? $j->height : null) ); $ret=""; switch ($j->type) { @@ -78,6 +79,7 @@ function oembed_format_object($j){ $th=120; $tw = $th*$tr; $tpl=get_markup_template('oembed_video.tpl'); $ret.=replace_macros($tpl, array( + '$baseurl' => $a->get_baseurl(), '$embedurl'=>$embedurl, '$escapedhtml'=>base64_encode($jhtml), '$tw'=>$tw, diff --git a/view/oembed_video.tpl b/view/oembed_video.tpl old mode 100644 new mode 100755 index 5824d8d4e8..d3a9a93113 --- a/view/oembed_video.tpl +++ b/view/oembed_video.tpl @@ -1,4 +1,4 @@ -
+