Blog


As much as I've tried to make this site about me and my family, I feel like I haven't been able to really express who I am and what my life is like. I hope that this blog will capture the essence of my life in a way that only an online journal could.



<% dim strDbPathAndName, strCon, adoCon, oRS, sql, Message dim Comment, CommentID, DateSubmitted, Author, Title strDbPathAndName = Server.MapPath("FamiliaDePerez.mdb") strCon = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + strDbPathAndName sql = "SELECT * FROM Blog WHERE " If Request("CommentID") <> "" Then sql = sql & " CommentID=" & cInt(Request("CommentID")) & " AND " sql = sql & "Author='Gerry P.' ORDER BY DateSubmitted desc" '------------------------------------------ '-- Create connection to the database and connect '------------------------------------------ Set adoCon = Server.CreateObject("ADODB.Connection") adoCon.Open strCon Set oRS = Server.CreateObject("ADODB.Recordset") oRS.open sql, adoCon, 2, 2 'Response.Write(sql) If Request("CommentID") <> "" Then '### If they choose a specific article, then show it If Not oRS.EOF AND NOT oRS.BOF Then Comment = oRS.fields("Comment").value DateSubmitted = oRS.fields("DateSubmitted").value Title = oRS.fields("Title").value Author = oRS.fields("Author").value %>

<%=Title %>

<%=DateSubmitted %>

<%=Comment %> <% Else Response.Write("No record found.") End If Else '### If there is no specific article, show a list of titles %> <% While Not oRS.EOF CommentID = oRS.fields("CommentID").value DateSubmitted = oRS.fields("DateSubmitted").value Title = oRS.fields("Title").value Author = oRS.fields("Author").value %> <% oRS.MoveNext Wend %>
<%=Title %> <%=DateSubmitted %>
<% End If oRS.close Set oRS = Nothing %>
Copyright (C) 2005. Familla de Perez. All rights reserved.
Contact Webmaster: "GerardoMPerez" at Yahoo