<%@ Language=VBScript %> <%Option Explicit%> <% Response.CharSet="iso-8859-7" if session("LastNameOnTop") & "" = "" AND session("UserID") & "" <> "" then%> <%end if if session("UserID") & "" = "" then Response.Redirect "account.asp?fromnews=1" dim SQL, oConn, oRs, Data, DataExist, Access, newcateg, i dim DTData, DTExist,PHrecordCount,DTRecordCount newcateg = 1 set oConn = Server.CreateObject("ADODB.Connection") oConn.open Application("ConStr") set oRs = Server.CreateObject("ADODB.Recordset") if Session("UserID") & "" <> "" then SQL = "Select UCategID, UAccess from [User] where UID=" & session("UserID") oRs.open SQL, oConn, 3,1,1 if oRs.EOF = false then if oRs("UCategID")=7 AND oRs("UAccess") = true then Access = 1 else Access = 0 else Response.Redirect "account.asp?fromnews=1" end if oRs.close end if if Access = 1 then if lang = "GR" then SQL = "Select top 4 PHDID, PHTitle, PHThumbname, PHDate from Photos where PHDID in (select PHDID from DeltioTypou) order by PHDate" if lang = "EN" then SQL = "Select top 4 PHDID, PHTitleEN, PHThumbname, PHDate from Photos where PHDID in (select PHDID from DeltioTypou) order by PHDate" oRs.open SQL, oConn, 3,1,1 if oRs.EOF = False then DataExist = 1 Data = oRs.GetRows() PHrecordCount = oRs.RecordCount else DataExist = 0 end if oRs.close if lang = "GR" then SQL = "Select DID, DDate, DTitle, dbo.GetLessText(DText,100) from DeltioTypou" if lang = "EN" then SQL = "Select DID, DDate, DTitleEN, dbo.GetLessText(DTextEN,100) from DeltioTypou" oRs.open SQL, oConn, 3,1,1 if oRs.EOF = false then DTExist = 1 DTData = oRs.GetRows() DTRecordCount=oRs.RecordCount end if end if set oRs = nothing oConn.close : set oConn = nothing GoToPage = "news.asp" menu = "4" %> <%=PageTitle%>
<%if Access = 1 then%>
       <%if newcateg <> 1 then%><%=NCateg1(lg)%><%else%><%=NCateg1(lg)%><%end if%>       <%if newcateg <> 2 then%><%=NCateg2(lg)%><%else%><%=NCateg2(lg)%></font><%end if%>       <%if newcateg <> 3 then%><%=NCateg3(lg)%><%else%><%=NCateg3(lg)%><%end if%>  
<%end if%>
<%=Ntit(lg)%> > <%=Nsubtit1(lg)%>

<%if DataExist = 1 or DTRecordCount>=1 then%>
<%if PHrecordCount>=1 then%>
" width="<%=photosize3x%>" height="<%=photosize3y%>" alt="" border="0">
<%=Data(3,0)%>
<%=Data(1,0)%>
<%end if%>
<%if PHrecordCount>=2 then%>
" width="<%=photosize3x%>" height="<%=photosize3y%>" alt="" border="0">
<%=Data(3,1)%>
<%=Data(1,1)%>
<%end if%>
<%if PHrecordCount>=3 then%>
" width="<%=photosize3x%>" height="<%=photosize3y%>" alt="" border="0">
<%=Data(3,2)%>
<%=Data(1,2)%>
<%end if%>
<%if PHrecordCount>=4 then%>
" width="<%=photosize3x%>" height="<%=photosize3y%>" alt="" border="0">
<%=Data(3,3)%>
<%=Data(1,3)%>
<%end if%>


<%if DTExist = 1 then%> <%for i=0 to ubound(DTData,2)%> <%next%>
<%=DTData(1,i)%> :: <%=DTData(2,i)%>
<%=DTData(3,i)%>
 
<%end if%> <%else%>
<%=NoNews(lg)%>
<%end if%> <%if Access=0 then%>
<%=NAccessDenied(lg)%>
<%end if%>