| Server IP : 172.67.201.108 / Your IP : 216.73.216.11 Web Server : Apache/2.4.68 (Amazon Linux) OpenSSL/3.5.5 System : Linux ip-172-31-69-123.ec2.internal 6.1.176-223.369.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Jul 24 13:34:27 UTC 2026 x86_64 User : ec2-user ( 1000) PHP Version : 8.4.23 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /home/home2/cgny/public_html/newadmin/ |
Upload File : |
<cfinclude template="header.cfm">
<div id="content">
<div id="content-header">
</div>
<div class="container-fluid" style="margin-left:200px;"><cfif parameterexists(getuser.id)>
<table border=0 width=100% cellpadding=0 cellspacing=0>
<tr><td valign=top>
<cfset ds='cityguide'>
<cfif IsDefined("action")>
<cfset imagedir="https://www.cityguideny.com/calendarphotos">
<cfset thumbdir="https://www.cityguideny.com/calendarphotos">
<cfoutput><span class="header">Upload Calendar Photos</span></strong><table width=100% cellspacing=0 cellpadding=0 bgcolor=#color#><tr><td></td></tr></table></cfoutput>
<p>
<cfset imagepath="/home2/cgny/www/calendarphotos/">
<cffile action="upload"
accept="image/jpeg,image/pjpeg"
nameconflict="makeunique"
filefield="photo"
destination="#imagepath#">
<cfif #left(photo,3)# is not 'bmp'>
<cfset photo = "#File.ServerFile#">
<cfset photo = replace(photo," ","_","ALL")>
<cffile
action = "rename"
source = "#imagepath#/#File.ServerFile#"
destination = "#imagepath#/#photo#"
mode = "644">
<cfset thumbnail = 'nd#photo#'>
<!---Outputs the variables #photo# and #thumbnail#--->
<CFQUERY datasource="cg22">
UPDATE ActivityPlanner SET
photo = '#photo#',
thumbnail = '#thumbnail#'
where id = #url.itemid#
</cfquery>
<cflocation url="calendarphotos/phpupload.php?name=#photo#">
</cfif>
<cfelseif parameterexists(url.name)>
<cfset imagedir="https://www.cityguideny.com/calendarphotos">
<cfset thumbdir="https://www.cityguideny.com/calendarphotos">
<cfoutput><center><p>
<font face=arial size=-1>
<strong> Here's the image you uploaded:<br></strong>
<img src="#imagedir#/#url.name#" border=1><br><br>
<strong> Here's the dynamic thumbnail we've created:<br></strong>
<img src="#thumbdir#/nd#url.name#" border=1><br><br>
</cfoutput> </div>
<p>
<a href="https://www.cityguideny.com/admin/activityplanneredit.cfm?mag=5">Back to Calendar Edit</a>
<cfelse>
<table border=0 cellspacing=0 cellpadding=6 100%>
<tr><td width=100% valign=top>
<cfoutput><span class="header">Upload Calendar Photo</span></strong><table width=100% cellspacing=0 cellpadding=0 bgcolor=#color#><tr><td></td></tr></table></cfoutput>
<p>
</ul>
</font>
<p>
<cfquery name="Getphoto" datasource="#ds#">
select *
from ActivityPlanner
where id = #url.itemid#
</cfquery>
<p>
<cfif #getphoto.thumbnail# is not ''>
<Cfoutput>
<img src="https://www.cityguideny.com/calendarphotos/#getphoto.thumbnail#" />
<a href="deletecalenderphoto.cfm?id=#url.itemid#">delete photo</a>
</Cfoutput>
</cfif>
<cfoutput>
<form action="uploadcalendarphoto.cfm?action=submit&itemid=#url.itemid#" method=post enctype="multipart/form-data"></cfoutput>
<table>
<tr><td valign=top><font face=verdana size=-1><strong>Image:</strong> </font></td><td><input type=file name="photo"><input TYPE="hidden" NAME="photo_required" VALUE="Please press browse to select a photo to upload.">
</td></tr>
<input type=hidden name=checker>
<input type=hidden name=maxsize value="">
<input type=hidden name=thumbsize value="150">
<cfoutput query=getuser>
<input type=hidden name=prefix value="#id#">
</cfoutput>
</table>
<p>
<div align="center"><input type=submit name=submit value="Upload"></div>
</form>
</td></tr></table>
</cfif>
</td></tr></table>
</cfif>