% Option Explicit ' ModuleName: admin.asp ' System: CWR (Church Without the Religion) ' Description: CWR Media Choices dynamically links supported media player links based on url program. ' Usage: Program=CWRnnn parm specifies the program to display: ' http://www.ptm.org/cwr/cwrMediaChoices.asp?program=cwrnnn ' Author: Marv Wegner ' '*MODS ' 23-Jan-2007 GG - Wired to dynamically show program info and link to media. ' 14-Jun-2008 GG - Add Hymn page references. ' %> <% dim dbconnstr dim conn, cm1, rs dim airdate,pgmtitle,pgmdesc,pgmfile,pgmscripture dbconnstr = "DSN=PTMRadio" ' Set up Database Access set conn = server.createobject("adodb.connection") set rs = server.createobject("adodb.recordset") conn.open dbconnstr set cm1 = createCommand() cm1.commandText = "SELECT top 1 program, airdate, title, description, scripture FROM CWRadioSchedule WHERE program='"&request("program")&"'" 'response.Write "
" & cm1.commandText & "
" & chr(10) rs.open cm1,, adOpenForwardOnly, adLockReadOnly if (not rs.eof) then pgmfile = rs("program") airdate = cdate(rs("airdate")) pgmtitle = preftitle(pgmfile,trim(rs("title"))) pgmdesc = trim(rs("description")) pgmscripture = trim(rs("scripture")) end if ' Close connection to preserve server resources rs.close function HymnLinks(myprogram) dim ret ret = "" if not isnull(myprogram) then 'create hymn page string cm1.commandText = "SELECT hymnno, title, htmlfilename FROM CWRProgramHymnsQuery WHERE program='"&myprogram&"'" rs.open cm1,, adOpenForwardOnly, adLockReadOnly while not rs.eof if len(ret)>0 then ret = ret & ", " end if ret = ret & "Page " & trim(cstr(rs("hymnno"))) & "" rs.MoveNext wend rs.close end if HymnLinks = ret end function %>
Christianity Without the Religion—Worship With Us |
Viewing/Listening Options—Make Your Selection: |
|||
| Download MP3 (audio) | Podcast (audio) | |||
| File plays across your Internet connection. Gives you control over how video appears and offers playback controls. | Download file to your computer's hard drive for later playback. Good if you're having problems with your connection. | Subscribe to free automatic mp3 downloads for your iPod or other portable players. | ||
| Back to main CWR Page | ||||
<% set rs=nothing set cm1=nothing set conn=nothing %>