Jump to content

load with title tag


Recommended Posts

Ok, what you do is on an ASP page, use <title>ASP CODE GOES HERE</title>, and extract the value from the database.

thnx but how can i use it with this script<%'Hieronder kun je het pad naar de database instellendim strConnstrConn = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath("db.mdb")'Hier kun je het aantal items per pagina instellendim intAantalintAantal = 1'Hier wordt de connectie met de database gemaaktdim adoCndim strSQLset adoCn = Server.CreateObject("ADODB.Connection")adoCn.Open strConn'Hier wordt de recordset opgehaald en in de SQL string is de gewenste volgorde en de "cursortype" opgegevendim adoRsset adoRs = Server.CreateObject("ADODB.Recordset")adoRs.CursorType = 1strSQL = "Select * From tbl_content order by id"adoRs.Open strSQL, adoCn, 3'Gedeelte om de page per page te regelendim intPageRecords, intRecords, intRecordCount, intCurrentPagedim intNumberOfPages, intDisplayPageintPageRecords = Request.Querystring("page")if intPageRecords = "" then intPageRecords = 1 : intRecords = 1intRecords = intPageRecordsintPageRecords = ((intPageRecords - 1) * intAantal) +1intRecordCount = 0%><html><head><title>ajuga</title><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"></head><body bgcolor="#FFFFFF" text="#000000"><%'Hier begint de loop, zolang er items in de recordset zitten'De recordset is onderverdeeld in stukje van 5 items (=intAantal)if not adoRs.EOF thenadoRs.Move (intPageRecords - 1)do while intRecordCount < intAantal and NOT adoRs.EOF%><center><table width="492" border="0"> <!--DWLayoutTable--> <tr> <td width="130" height="21" valign="top"><b>latijnse naam:</b></td> <td colspan="2" valign="top"><%=adoRs("plantnaam")%> </td> <br> <td width="65"> </td> </tr> <tr> <td height="21"><b>Nederlandse naam:</b></td> <td colspan="2" valign="top"><%=adoRs("nl_naam")%></td> <td> </td> </tr> <tr> <td height="21"><b>Hoogte:</b></td> <td colspan="2" valign="top"><%=adoRs("hoogte")%>cm</td> <td> </td> </tr> <tr> <td height="21"><b>Bloeitijd:</b></td> <td colspan="2" valign="top"><%=adoRs("bloeitijd")%></td> <td> </td> </tr> <tr> <td height="21"><b>Kleur:</b></td> <td colspan="2" valign="top"><%=adoRs("kleur")%></td> <td> </td> </tr> <tr> <td height="21" valign="top"><b>Standplaats:</b></td> <td colspan="2" valign="top"><%=adoRs("standp")%></td> <td> </td> </tr> <tr> <td height="204" colspan="2" valign="top"><b><img src="<%=adoRs("thumb")%>" width="227" height="202" border="0"></b></td> <td width="184"></td> <td></td> </tr> <tr> <td height="3"></td> <td width="93"></td> <td></td> <td></td> </tr></table></center><%'Hier loop je naar de volgende 5 (=intAantal) items in de recordsetadoRs.MoveNextintRecordCount = intRecordCount +1Loopend if%><br><% 'Als er items in de recordset zitten laat dan de page per page bediening zienif not adoRs.BOF then %><% 'Einde van de page per page bedieningend if %></body></html><%'Hier wordt de connectie afgeslotenadoRs.Close set adoRs = nothingadoCn.Close set adoCn = nothing%>
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...