<%@ Language=VBScript %>
<!--#include File="Functions.asp"-->
<%
Dim SitcomID, Size

SitcomID = Request("SitcomID")
Size = Request("Size")

Dim MyConn, RS, SqlSelect
Set MyConn = Server.CreateObject("Adodb.Connection")
Set MyConn = GetConnection
Set RS = Server.CreateObject("Adodb.RecordSet")

SqlSelect = "SELECT * FROM SitcomInfo Where SitcomID=" & SitcomID
RS.Open SqlSelect, MyConn, 1, 3

If LCase(Trim(Size)) = "small" Then
	If Not (IsNull(RS("SmallPicture")) Or IsEmpty(RS("SmallPicture"))) Then
		Response.ContentType = "image/jpg"
		Response.BinaryWrite RS("SmallPicture")
	End If
End If
If LCase(Trim(Size)) = "large" Then
	If Not (IsNull(RS("LargePicture")) Or IsEmpty(RS("LargePicture"))) Then
		Response.ContentType = "image/jpg"
		Response.BinaryWrite RS("LargePicture")
	End If
End If
	

RS.Close
Set RS = Nothing
MyConn.Close
Set MyConn = Nothing
%>