HEX
Server: Apache
System: Linux www3.pit.tblive.com 5.14.0-687.38.1.el9_8.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Aug 12 17:19:12 EDT 2026 x86_64
User: awaldron (1020)
PHP: 8.1.34
Disabled: exec,passthru,shell_exec,system
Upload Files
File: /home/awaldron/www/archive/demo/event_view.php
<?php
session_start();


echo "<html>\n";
echo "<head>\n";
echo "<title>".CMP_NAME_INF." : View Calendar Event</title>\n";
echo "</head>\n";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"default.css\">\n";
echo "<body style=\"margin:15px;font-size:12px;\">\n";



	include("_functions.php");
	dbconnect();
	
	$sql = "SELECT * FROM tbl_calendar_dates WHERE cal_date=".$_GET["d"]." AND calendar_id=".$_GET["cid"]." ORDER BY cal_date ASC";
	$result = mysql_query($sql);
	
	$d = date_tstounix($_GET["d"]."000000");
	echo "<P><b id=\"red\">".date("F j, Y",$d).":</b><P><ul>";
	for ($i=0; $i < mysql_num_rows($result); $i++) {
		$row = mysql_fetch_array($result);
		if ($row["cal_linkto"] != "0") echo "<li><a href=\"#\" onClick=\"window.opener.location.href='".$row["cal_linkto"]."';window.close();\">".$row["cal_title"]."</a>\n";
		else echo "<li>".$row["cal_title"]."\n";
		if ($row[username] == $_SESSION[auth_user]) echo " (<a href=\"/event_edit.php?cal_id=".$row[cal_id]."\">edit</a>)";
	} echo "</ul>\n";
	

	$bdays = "";
	$bsql = "SELECT fname,lname,username FROM tbl_employees WHERE emp_type_id<4 AND is_employee=1 AND acct_confirmed=1 AND birthday='".substr($_GET["d"],4,4)."'";
	$bres = mysql_query($bsql);	
	if (mysql_num_rows($bres) > 0) {
		for ($i=0; $i < mysql_num_rows($bres); $i++) {
			$bday = mysql_fetch_array($bres);
			$bdays .= "<li><a href=\"#\" onClick=\"window.opener.location.href='/profile.php?u=".$bday["username"]."';window.close();\">".$bday["fname"]." ".$bday["lname"]."</a>\n";
		}
	}	
	if (strlen($bdays) > 0) {
		echo "<P><b id=\"red\">Today's Birthdays:</b>";
		echo "<P><ul>".$bdays."</ul>\n";
	}
	
	echo "<br><br><a href=\"/event_add.php?d=".$_GET["d"]."&cid=".$_GET["cid"]."\" style=\"font-size:10px\">Add event to ".date("m/d",$d)." >></a>\n";
?>
</body>
</html>