Rar! ϐs
"t@0 @f30 OMSx_4.3\add.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
If Session("admin") = false then Response.Redirect "login.asp?goto=add.asp"
Session.Codepage = 65001
Dim intcatID, strCatName, lngComposerID, lngSingerID, strSongName, strLyric, strSource, strComposerName, strSingername
intCatID = CInt(Request.Form("catID"))
lngComposerID = CLng(Request.Form("composerid"))
lngSingerID = CLng(Request.Form("singerid"))
strCatName = Replace(Trim(Request.Form("catname")),"'","''")
strSongName = Replace(Trim(Request.Form("songname")),"'","''")
strLyric = Replace((Request.Form("lyric")),"'","''")
strSource = Replace(Trim(Request.Form("Source")),"'","''")
strComposerName = Replace(Trim(Request.Form("composername")),"'","''")
strSingerName = Replace(Trim(Request.Form("singername")),"'","''")
If intCatID = 0 Then
If strCatName <> "" Then
strSQL = "INSERT INTO tblCat (CatName) VALUES ('" & strCatName & "');"
omsCon.Execute(strSQL)
rs.Open "SELECT TOP 1 CatID FROM tblCat ORDER BY CatID DESC;", omsCon
intCatID = CInt(rs("CatID"))
rs.Close
End If
End If
If lngComposerID = 0 Then
If strComposerName <> "" Then
strSQL = "INSERT INTO tblComposer (ComposerName) VALUES ('"&strComposerName&"');"
omsCon.Execute(strSQL)
rs.Open "SELECT Max(ComposerID) AS NewComposerID FROM tblComposer;", omsCon
lngComposerID = CLng(rs("NewComposerID"))
rs.Close
End If
End If
If lngSingerID = 0 Then
If strSingerName <> "" Then
strSQL = "INSERT INTO tblSinger (SingerName) VALUES ('"&strSingerName&"');"
omsCon.Execute(strSQL)
rs.Open "SELECT Max(SingerID) AS NewSingerID FROM tblSinger;", omsCon
lngSingerID = CLng(rs("NewSingerID"))
rs.Close
End If
End If
If strSongName <> "" AND strSource <> "" AND lngComposerID <> 0 AND lngSingerID <> 0 AND intCatID <> 0 Then
strSQL = "INSERT INTO tblSong(CatID,SongName,ComposerID,SingerID,Lyric,Source,SubmittedDate) VALUES ("&intCatID&",'"&strSongName&"',"&lngComposerID&","&lngSingerID&",'"&strLyric&"','"&strSource&"',Now());"
omsCon.Execute(strSQL)
Response.Write vbCrLf & "Đã thêm nhạc phẩm "&strSongName&" "
End If
%>
Thêm bài hát
Thêm bài hát mới
*t@5
berf30 OMSx_4.3\CatAdmin.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
If Session("admin") <> strSecCode then Response.Redirect "login.asp?goto=catAdmin.asp"
Dim intCatID, strCatName, intCatOrder, strCatDescription, blnDel
strSQL = "SELECT * FROM tblCat ORDER BY CatName ASC;"
rs.Open strSQL, omsCon
Do While NOT rs.EOF
intCatID = CInt(rs("CatID"))
strCatName = Replace(Trim(Request.Form("CatName"&intCatID)),"'","''",1,-1,1)
blnDel = CBool(Request.Form("delCat"&intCatID))
If strCatName <> "" Then
strSQL = "UPDATE tblCat Set CatName = '"&strCatName&"' WHERE CatID = "&intCatID&";"
omsCon.Execute(strSQL)
End If
If blnDel = True then
strSQL = "DELETE FROM tblSong WHERE CatID = "&intCatID&";"
omsCon.Execute(strSQL)
strSQL = "DELETE FROM tblCat WHERE CatID = "&intCatID&";"
omsCon.Execute(strSQL)
End If
rs.MoveNext
Loop
rs.Close
%>
Quản lý các thể loại
t@: D D qqf30 OMSx_4.3\ComposerAdmin.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
If Session("admin") <> strSecCode then Response.Redirect "login.asp?goto=ComposerAdmin.asp"
Dim lngComposerID, strComposerName, blnDel
strSQL = "SELECT * FROM tblComposer ORDER BY ComposerName ASC;"
rs.Open strSQL, omsCon
Do While NOT rs.EOF
lngComposerID = CLng(rs("ComposerID"))
strComposername = Replace(Trim(Request.Form("Composername"&lngComposerID)),"'","''",1,-1,1)
blnDel = CBool(Request.Form("DelComposer"&lngComposerID))
If strComposerName <> "" Then
strSQL = "UPDATE tblComposer Set Composername = '"&strComposername&"' WHERE ComposerID = "&lngComposerID&";"
omsCon.Execute(strSQL)
End If
If blnDel Then
strSQL = "DELETE FROM tblSong WHERE ComposerID = "&lngComposerID&";"
omsCon.Execute(strSQL)
strSQL = "DELETE FROM tblComposer WHERE ComposerID = "&lngComposerID&";"
omsCon.Execute(strSQL)
End If
rs.MoveNext
Loop
rs.Close
%>
Quản lý danh sách nhạc sĩ
7t@3 -f30 OMSx_4.3\delete.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
Dim lngSongID
lngSongID = CLng(Request.QueryString("SongID"))
If Session("admin") <> strSecCode Then Response.Redirect "login.asp?goto=delete.asp?SongID=" & lgnSongID
omsCon.Execute("DELETE FROM tblSong WHERE SongID = " & lngSongID & ";")
Set rs = Nothing
omsCon.Close
Set omsCon = Nothing
Response.Redirect "list.asp"
%>t@1 Y Y +f30 OMSx_4.3\edit.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
Session.Codepage = 65001
Dim lngSongID, strSongName, strSource, strLyric, intCatID, lngComposerID, lngSingerID, blnDelete
lngSongID = CLng(Request.QueryString("SongID"))
If Session("admin") = False Then Response.Redirect "login.asp?goto=edit.asp?songID="&lngSongID
intCatID = CInt(Request.Form("catID"))
lngComposerID = CLng(Request.Form("composerid"))
lngSingerID = CLng(Request.Form("singerid"))
strSongName = Replace(Trim(Request.Form("songname")),"'","''")
strLyric = Replace((Request.Form("lyric")),"'","''")
strSource = Replace(Trim(Request.Form("Source")),"'","''")
strCatname = Replace(Trim(Request.Form("catname")),"'","''")
strComposerName = Replace(Trim(Request.Form("composername")),"'","''")
strSingerName = Replace(Trim(Request.Form("singername")),"'","''")
blnDelete = CBool(Request.Form("delthissong"))
If intCatID = 0 Then
If strCatname <> "" Then
strSQL = "INSERT INTO tblCat(CatName) VALUES ('" & strCatName & "');"
omsCon.Execute(strSQL)
rs.Open "SELECT TOP 1 CatID FROM tblCat ORDER BY CatID DESC;", omsCon
intCatID = CInt(rs("CatID"))
rs.Close
End If
End If
If lngComposerID = 0 Then
If strComposerName <> "" Then
strSQL = "INSERT INTO tblComposer (ComposerName) VALUES ('"&strComposerName&"');"
omsCon.Execute(strSQL)
rs.Open "SELECT Max(ComposerID) AS NewComposerID FROM tblComposer;", omsCon
lngComposerID = CLng(rs("NewComposerID"))
rs.Close
End If
End If
If lngSingerID = 0 Then
If strSingerName <> "" Then
strSQL = "INSERT INTO tblSinger (SingerName) VALUES ('"&strSingerName&"');"
omsCon.Execute(strSQL)
rs.Open "SELECT Max(SingerID) AS NewSingerID FROM tblSinger;", omsCon
lngSingerID = CLng(rs("NewSingerID"))
rs.Close
End If
End If
If blnDelete Then
strSQL = "DELETE FROM tblSong WHERE SongID = "&lngSongID&";"
omsCon.Execute(strSQL)
Response.Redirect "list.asp"
End If
If strSongName <> "" AND intCatID <> 0 AND strSource <> "" AND lngComposerID <> 0 AND lngSingerID <> 0 Then
strSQL = "UPDATE tblSong SET SongName = '"&strSongName&"', CatID = "&intCatID&", ComposerID = "&lngComposerID&", SingerID = "&lngSingerID&", Source = '"&strSource&"', Lyric = '"&strLyric&"' WHERE SongID = "&lngSongID&";"
omsCon.Execute(strSQL)
Response.Redirect "play.asp?songID="& lngSongID
End If
strSQL = "SELECT * FROM tblSong WHERE SongID = "&lngSongID&";"
rs.Open strSQL, omsCon
If rs.EOF Then
Response.Redirect "list.asp"
End If
strSongName = rs("SongName")
intCatID = CInt(rs("CatID"))
lngComposerID = CLng(rs("ComposerID"))
lngSingerID = CLng(rs("SingerID"))
strSource = rs("Source")
strLyric = rs("Lyric")
rs.Close
%>
Sửa <% =strSongName %>
" & vbCrLf
End Function 'showPlayer
%>[t@. 30 OMSx_4.3\js.js//Coded by ducthuan@gmail.com
function explorer(divName) {
if (document.all[divName].style.display == 'none'){
document.all[divName].style.display = '';
}
else {
document.all[divName].style.display = 'none';
}
}
//Coded by Pham Huu Khang
function toggle(iself,name1,name2,divID) {
if (iself.src.lastIndexOf(name1)==iself.src.length-name1.length) {
iself.src = name2;
document.all[divID].style.display='';
}
else {
iself.src = name1;
document.all[divID].style.display='none';
}
}
//Coded by Bruce Corkhill
function PageJump(URL) {
if (URL.options[URL.selectedIndex].value != "") self.location.href = URL.options[URL.selectedIndex].value;
return true;
}?t@1 J J `I~qf30 OMSx_4.3\list.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
Private Sub showPageList()
If lngTotalPages > 1 Then %>
Trang: <% =lngCurrentPage %>/<%=lngTotalPages %>
<% If CLng(lngCurrentPage) > 1 AND CLng(lngCurrentPage) <= CLng(lngTotalPages) Then %>Trước<% End If %>
<% If CLng(lngCurrentPage) < CLng(lngTotalPages) AND CLng(lngCurrentPage) >=1 Then %>Sau<% End If %>
<% End If
End Sub
Dim rsSong, strShow, strOrder, strSort, intCatID
Dim i, lngSongID, strSongName, strComposerName, strSingerName, lngComposerID, lngSingerID, lngCurrentPage, lngTotalSongs, lngTotalPages, strPageTitle, strPageURL, lngVisits, dmlAveragePoints
Dim strKeyword, intKeywordLoopCounter, lngDownload
Dim strURLPart, strSQLPart, intRecordPerPage
strSQLPart = "song.SongID, song.SongName, song.CatID, song.ComposerID, song.SingerID, song.Visits, song.AveragePoints, cat.CatName, composer.ComposerName, singer.SingerName FROM tblSong AS song, tblCat AS cat, tblComposer AS composer, tblSinger AS singer WHERE song.CatID = cat.CatID AND song.ComposerID = composer.ComposerID AND song.SingerID = singer.SingerID "
'Ham nay cua Web Wiz Forums
Private Function searchHighlighter(ByVal strMessage, ByVal sarySearchWord)
Dim intHighlightLoopCounter 'Loop counter to loop through words and hightlight them
Dim strTempMessage 'Temporary message store
Dim lngMessagePosition 'Holds the message position
Dim intHTMLTagLength 'Holds the length of the HTML tags
Dim intSearchWordLength 'Holds the length of teh search word
Dim blnTempUpdate 'Set to true if the temp message variable is updated
'Loop through each character in the post message
For lngMessagePosition = 1 to Len(strMessage)
'Initilise for each pass
blnTempUpdate = False
'If an HTML tag is found then move to the end of it so that no words in the HTML are highlighted
If Mid(strMessage, lngMessagePosition, 1) = "<" Then
'Get the length of the HTML tag
intHTMLTagLength = (InStr(lngMessagePosition, strMessage, ">", 1) - lngMessagePosition)
'Place the HTML tag back into the tempary message store
strTempMessage = strTempMessage & Mid(strMessage, lngMessagePosition, intHTMLTagLength)
'Add the length of the HTML tag to the post message position variable
lngMessagePosition = lngMessagePosition + intHTMLTagLength
End If
'Loop through the search words to see if they are in the message post
For intHighlightLoopCounter = 0 to UBound(sarySearchWord)
'If there is a search word in the array position check it
If sarySearchWord(intHighlightLoopCounter) <> "" Then
'Get the length of the search word
intSearchWordLength = Len(sarySearchWord(intHighlightLoopCounter))
'If the next XX characters are the same as the search word then highlight them
If LCase(Mid(strMessage, lngMessagePosition, intSearchWordLength)) = LCase(sarySearchWord(intHighlightLoopCounter)) Then
'Highlight the search word
strTempMessage = strTempMessage & "" & Mid(strMessage, lngMessagePosition, intSearchWordLength) & ""
'Add the length of the replaced search word to the post message position variable
lngMessagePosition = lngMessagePosition + intSearchWordLength - 1
'Set the changed boolean to true
blnTempUpdate = True
End If
End If
Next
'If a search word is not highlighted then add the character from the post message being checked to the temp variable
If blnTempUpdate = False Then
strTempMessage = strTempMessage & Mid(strMessage, lngMessagePosition, 1)
End If
Next
'Return the function
searchHighlighter = strTempMessage
End Function
intRecordPerPage = Request.QueryString("perpage")
If intRecordPerPage = "" OR IsNumeric(intRecordPerPage) = False Then
intRecordPerPage = intDefaultSongPerPage
End If
intRecordPerPage = CInt(intRecordPerPage)
If intRecordPerPage > 50 Then intRecordPerPage = 50
If intRecordPerPage < 5 Then intRecordPerPage = 5
strOrder = Request.QueryString("order")
If strOrder = "" OR (LCase(strOrder) <> "descending" AND LCase(strOrder) <> "ascending") Then strOrder = strDefaultOrderMode
Function getOrderMode(strOrder)
Select Case LCase(strOrder)
Case "descending"
getOrderMode = "DESC"
Case "ascending"
getOrderMode = "ASC"
End Select
End Function
strSort = Request.QueryString("sort")
If strSort = "" Then strSort = strDefaultSortMode
Function getSortMode(strSort)
Select Case LCase(strSort)
Case "updatetime"
getSortMode = "song.SongID"
Case "songname"
getSortMode = "song.SongName"
Case "noofvisits"
getSortMode = "song.Visits"
Case "averagepoints"
getSortMode = "song.AveragePoints"
Case "catname"
getSortMode = "cat.CatName"
Case "composername"
getSortMode = "composer.ComposerName"
Case "singername"
getSortMode = "singer.SingerName"
Case Else
getSortMode = strDefaultSortMode
End Select
End Function
strShow = Request.QueryString("show")
If strShow = "" Then strShow = "all"
lngCurrentPage = Request.QueryString("page")
If lngCurrentPage = "" OR IsNumeric(lngCurrentPage) = False Then
lngCurrentPage = 1
End If
lngCurrentPage = CLng(lngCurrentPage)
If lngCurrentPage < 1 Then lngCurrentPage = 1
Select Case LCase(strShow)
Case "all"
strSQL = "SELECT " & strSQLPart & " ORDER BY " & getSortMode(strSort) & " " & getOrderMode(strOrder)
strURLPart = ""
strPageTitle = "Danh sách tất cả các bài hát"
Case "cat"
intCatID = CInt(Request.QueryString("CatID"))
rs.Open "SELECT CatName FROM tblCat WHERE CatID = " & intCatID & ";", omsCon
If rs.EOF Then
strPageTitle = "Thể loại không tồn tại"
Else
strCatName = rs("CatName")
strPageTitle = "Danh sách các bài hát trong thể loại "&strCatName&""
End If
rs.Close
strURLPart = "&CatID="&intCatID
strSQL = "SELECT " & strSQLPart & " AND cat.CatID = " & intCatID & " ORDER BY " & getSortMode(strSort) & " " & getOrderMode(strOrder)
Case "composer"
lngComposerID = CLng(Request.QueryString("ComposerID"))
rs.Open "SELECT ComposerName FROM tblComposer WHERE ComposerID = " & lngComposerID & ";", omsCon
If rs.EOF Then
strPageTitle = "Nhạc sĩ không tồn tại"
Else
strComposerName = rs("ComposerName")
strPageTitle = "Danh sách các bài hát do "&strComposerName&" sáng tác"
End If
rs.Close
strURLPart = "&ComposerID=" & lngComposerID
strSQL = "SELECT " & strSQLPart & " AND composer.ComposerID = " & lngComposerID & " ORDER BY " & getSortMode(strSort) & " " & getOrderMode(strOrder)
Case "singer"
lngSingerID = CLng(Request.QueryString("singerID"))
rs.Open "SELECT SingerName FROM tblSinger WHERE SingerID = " & lngSingerID & ";", omsCon
If NOT rs.EOF Then
strSingerName = rs("SingerName")
strPagetitle = "Danh sách các bài hát do " & strSingerName & " thể hiện"
Else
strPageTitle = "Ca sĩ không tồn tại"
End If
rs.Close
strURLPart = "&SingerID="&lngSingerID
strSQL = "SELECT " & strSQLPart & "AND singer.SingerID = " & lngSingerID & " ORDER BY " & getSortMode(strSort) & " " & getOrderMode(strOrder)
Case "search"
strKeyword = Replace(Trim(Request.QueryString("keyword")),"'","''",1,-1,1)
If strKeyword = "" Then Response.Redirect "list.asp"
Dim arrkeyword, strSearchMode
arrKeyword = Split(Replace(strKeyword,"_"," ",1,-1,1), " ")
strSearchMode = Trim(Request.QueryString("searchmode"))
If strSearchMode = "" Then strSearchMode = "songname"
Private Function getSearchMode(strSearchMode)
Select Case LCase(strSearchMode)
Case "songname"
getSearchMode = "song.SongName"
Case "lyric"
getSearchMode = "song.Lyric"
Case "catname"
getSearchMode = "cat.CatName"
Case "composername"
getSearchMode = "composer.ComposerName"
Case "singername"
getSearchMode = "singer.SingerName"
Case "source"
getSearchMode = "song.Source"
Case Else
getSearchMode = "song.SongName"
End Select
End Function
Private Function BuildQuery()
Dim intKeywordsLoopCounter
For intKeywordLoopCounter = 0 To UBound(arrKeyword)
BuildQuery = BuildQuery & " " & getSearchMode(strSearchMode) & " LIKE '%"&arrKeyword(intKeywordLoopCounter)&"%' "
If intKeywordLoopCounter < UBound(arrKeyword) Then
BuildQuery = BuildQuery & "OR "
End If
Next
End Function
strURLPart = "&keyword=" & strKeyword & "&searchmode=" & strSearchMode
strSQL = "SELECT " & strSQLPart & " AND (" & BuildQuery() & ") ORDER BY " & getSortMode(strSort) & " " & getOrderMode(strOrder)
strPageTitle = "Kết quả tìm kiếm cho "&strKeyword&""
Case "topvisited"
strSQL = "SELECT TOP 20 " & strSQLPart & " ORDER BY song.Visits DESC, song.SubmittedDate DESC"
strURLPart = ""
strPageTitle = "Danh sách 20 bài được nghe nhiều nhất"
Case "toprated"
strSQL = "SELECT TOP 20 " & strSQLPart & " ORDER BY song.AveragePoints DESC, song.Votes DESC, song.SongName ASC"
strURLPart = ""
strPageTitle = "Danh sách 20 bài được nhiều điểm nhất"
Case Else
Response.Redirect "list.asp"
End Select
%>
<%
Set rsSong = Server.CreateObject("ADODB.Recordset")
rsSong.CursorType = 3
rsSong.Open strSQL, omsCon
rsSong.PageSize = intRecordPerPage
lngTotalSongs = rsSong.RecordCount
lngTotalPages = rsSong.PageCount
If CLng(Request.QueryString("page")) > lngTotalPages Then lngCurrentPage = lngTotalPages
%>
<% =strPageTitle %><% If lngTotalSongs > 0 Then %> [Số bài hát <% =lngTotalSongs %>]<% End If %>
<%'Neu co bai hat thi hien thi
If NOT rsSong.EOF Then
rsSong.AbsolutePage = lngCurrentPage
If LCase(strShow) <> "topvisited" AND LCase(strShow) <> "toprated" Then %>
<% End If %>
<% showPageList() %>
<%
For i = 1 To intRecordPerPage
If rsSong.EOF Then Exit For
intCatID = CInt(rsSong("CatID"))
lngSongID = CLng(rsSong("SongID"))
lngComposerID = CLng(rsSong("ComposerID"))
lngSingerID = CLng(rsSong("SingerID"))
strSongName = rsSong("SongName")
lngVisits = rsSong("Visits")
dmlAveragePoints = Round(rsSong("AveragePoints"))
strCatName = rsSong("CatName")
strComposerName = rsSong("ComposerName")
strSingerName = rsSong("SingerName")
%>
<% End If %>
<% rs.Open "SELECT TOP 15 s.SongID, s.SongName, si.SingerID, si.SingerName, c.ComposerID, c.ComposerName FROM tblSong s, tblSinger si, tblComposer c WHERE s.ComposerID = c.ComposerID AND s.SingerID = si.SingerID AND s.CatID = " & intCatID & " AND s.SongID <> " & lngSongID & " ORDER BY s.SongID DESC;", omsCon
If NOT rs.EOF Then %>
<% End If
rs.Close%>
<% rs.Open "SELECT TOP 15 s.SongID, s.SongName, si.SingerID, si.SingerName, c.ComposerID, c.ComposerName FROM tblSong s, tblSinger si, tblComposer c WHERE s.ComposerID = c.ComposerID AND s.SingerID = si.SingerID AND s.ComposerID = " & lngComposerID & " AND s.SongID <> " & lngSongID & " ORDER BY s.SongID DESC;", omsCon
If NOT rs.EOF Then %>
<%End If
rs.Close %>
<% rs.Open "SELECT TOP 15 s.SongID, s.SongName, si.SingerID, si.SingerName, c.ComposerID, c.ComposerName FROM tblSong s, tblSinger si, tblComposer c WHERE s.ComposerID = c.ComposerID AND s.SingerID = si.SingerID AND s.SingerID = " & lngSingerID & " AND s.SongID <> " & lngSongID & " ORDER BY s.SongID DESC;", omsCon
If NOT rs.EOF Then %>
t@5 9$ 9$ 'g30 OMSx_4.3\playlist.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
Dim i, j, x, y, strAction, lngSongID, arrSongs, lngTotalSongs
If IsArray(Session("VNDesirePlaylist")) Then
arrSongs = Session("VNDesirePlaylist")
Else
ReDim arrSongs(0)
End If
lngTotalSongs = UBound(arrSongs)
Sub displayTheList()
Dim strSongname, lngVisits, dmlAveragePoints, lngDownload, strCatName, strComposerName, strSingerName, intCatID, lngComposerID, lngSingerID%>
VNDesire Playlist
<% Else %>
Không có bài nào
<% End If %>
<%End Sub 'displayTheList
Sub loadTheList()
Dim strSource %><% =strPlaylistName %><% =strWMPAbstract %><% =strWMPPlaylistAuthor %><% =strWMPCopyright %><%
For x = 1 TO UBound(arrSongs)
strSQL = "SELECT tblSong.SongName, tblSong.Visits, tblSong.AveragePoints, tblSong.Source, tblSong.CatID, tblSong.ComposerID, tblSong.SingerID, tblCat.CatName, tblComposer.ComposerName, tblSinger.SingerName FROM tblSong, tblCat, tblComposer, tblSinger WHERE tblSong.CatID = tblCat.CatID AND tblSong.ComposerID = tblComposer.ComposerID AND tblSong.SingerID = tblSinger.SingerID AND tblSong.SongID = "&CLng(arrSongs(x))&";"
rs.Open strSQL, omsCon
If NOT rs.EOF Then
strSongName = rs("SongName")
lngVisits = CLng(rs("Visits"))
dmlAveragePoints = Round(rs("AveragePoints"))
strSource = rs("Source")
strCatname = rs("CatName")
strComposerName = rs("ComposerName")
strSingerName = rs("SingerName")
loadASXItem strSongName, strCatName, strComposerName, strSingerName, strSource
omsCon.Execute("UPDATE tblSong SET Visits = Visits + 1 WHERE SongID = "&CLng(arrSongs(x))&";")
End If
rs.Close
If x = UBound(arrSongs) Then Exit For
Next %>
<%
End Sub 'loadTheList
strAction = Request.QueryString("action")
If strAction = "" Then strAction="display"
Select Case LCase(strAction)
Case "display"
displayTheList()
Case "add"
If Request.Form("addSongID") <> "" Then
For Each lngSongID In Request.Form("addSongID")
If lngSongID <> "" Then
ReDim Preserve arrSongs(UBound(arrSongs) + 1)
arrSongs(UBound(arrSongs)) = CLng(lngSongID)
End if
Next 'For Each lngSongID In Request.Form("addSongID")
Session("VNDesirePlaylist") = arrSongs
End If
Response.Redirect Replace(Request.QueryString, "action=add&done=", "", 1, -1, 1)
Case "remove"
If Request.Form("removeSongID") <> "" Then
For Each lngSongID In Request.Form("removeSongID")
If lngSongID <> "" Then
For x = 1 To UBound(arrSongs)
If CLng(arrSongs(x)) = CLng(lngSongID) Then
arrSongs(x) = arrSongs(UBound(arrSongs))
ReDim Preserve arrSongs(UBound(arrSongs)-1)
Session("VNDesirePlaylist") = arrSongs
Exit For 'x = 1 To UBound(arrSongs)
End If
Next
End If
Next 'For Each lngSongID In Request.Form("removeSongID")
End If
Response.Redirect "?"
Case "asx"
loadTheList()
Case Else
Response.Redirect "?"
End Select
Set rs = Nothing
omsCon.Close
Set omsCon = Nothing %>ˋt@3 S S V9g30 OMSx_4.3\report.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
Dim strSendername, strSenderEmail, strSubject, strMessage, lngSongID, strSongName
lngSongID = CLng(Request.QueryString("SongID"))
rs.Open "SELECT SongName FROM tblSong WHERE SongID = "&lngSongID&";", omsCon
If rs.EOF Then Response.Redirect "list.asp"
strSongName = rs("SongName")
rs.Close
strPageTitle = "Thông báo về bài hát "&strSongName&""
strSenderName = Trim(Request.Form("SenderName"))
If strSenderName <> "" Then strSenderName = Replace(strSenderName,"'","''",1,-1,1)
strSenderEmail = Trim(Request.Form("SenderEmail"))
If strSenderEmail <> "" Then strSenderEmail = Replace(strSenderEmail,"'","''",1,-1,1)
strSubject = Trim(Request.Form("Subject"))
If strSubject <> "" Then strSubject = Replace(strSubject,"'","''",1,-1,1)
strMessage = Trim(Request.Form("Message"))
If strMessage <> "" Then strMessage = Replace(strMessage,"'","''",1,-1,1)
If strSenderName <> "" AND strSenderEmail <> "" AND strSubject <> "" AND strMessage <> "" Then
omsCon.Execute("INSERT INTO tblReport(NameEmailSubject,Content) VALUES ('"&strSenderName&"-"&strSenderEmail&"-Report: "&strSongName&"-"&strSubject&"','"&strMessage&"');")
Response.Redirect "play.asp?songID="&lngSongID
End If %>
<% Set rs = Nothing
omsCOn.Close
Set omsCon = Nothing %>vt@8
$g30 OMSx_4.3\SingerAdmin.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<%
If Session("admin") <> strSecCode then Response.Redirect "login.asp?goto=SingerAdmin.asp"
Dim lngSingerID, strSingerName, blnDel
strSQL = "SELECT * FROM tblSinger ORDER BY SingerName ASC;"
rs.Open strSQL, omsCon
Do While NOT rs.EOF
lngSingerID = CLng(rs("SingerID"))
strSingername = Replace(Trim(Request.Form("Singername"&lngSingerID)),"'","''",1,-1,1)
blnDel = CBool(Request.Form("DelSinger"&lngSingerID))
If strSingerName <> "" Then
strSQL = "UPDATE tblSinger Set Singername = '"&strSingername&"' WHERE SingerID = "&lngSingerID&";"
omsCon.Execute(strSQL)
End If
If blnDel Then
strSQL = "DELETE FROM tblSong WHERE SingerID = "&lngSingerID&";"
omsCon.Execute(strSQL)
strSQL = "DELETE FROM tblSinger WHERE SingerID = "&lngSingerID&";"
omsCon.Execute(strSQL)
End If
rs.MoveNext
Loop
rs.Close
%>
Quản lý danh sách ca sĩ
Quản lý danh sách ca sĩ
LIt@6 Fv Fv
o:90 OMSx_4.3\viettyping.js/*********************************************************************/
/*** Freeware Open Source editted by Binh, Le Hai - 2003 */
/*** You can download at http://www.manguon.com */
/*** Original source by Vietdev http://vietdev.sourceforge.net */
/*** DON'T SELL IT */
/*** This file have new function: typing viet in WYSIWYG editor */
/*********************************************************************/
/*** CONFIGUARION HERE YOU CAN SET DEFAULT-VALUES */
/*** ON_OFF=0-> VietTyping 1:ON, 0:OFF */
/*** TYPMOD=0-> VietTyping-mode 0:Auto, 1:Vni, 2:Telex , 3:VIQR */
/*** SPELL=1-> Check vietnamese word 0:No-check, 1:Yes */
/*** POPSTATUS=1-> Status-Mode-Display 1:Popup, 0:Statusbar */
var ON_OFF=1;
var TYPMOD=2;
var SPELL=0;
var POPSTATUS=1;
var ENGLISH=0, CODE, CHANGE=0;
var hmenu;
var TXTOBJ=null; //*** TEXT Obj
function notWord(cc)
{
return ("\ \r\n#,\\;.:-_()<>+-*/=?!\"$%{}[]\'~|^?\@\&`0123456789".indexOf(cc)>=0);
}
function UNI(str1,key,codeA)
{
var codeH=new Array();
for(var i=0;i=0
CODE=''
for(var i=lenX;i>=0;i--)
{
sX1=str1.substring(0,i-1)
sX2=str1.substring(i,lenX)
c1X=str1.substring(i-1,i); code2=c1X.charCodeAt(0) ;
c2X=str1.substring(i-2,i-1); code=c2X.charCodeAt(0) ;
c3X=str1.substring(i-3,i-2); code1=c3X.charCodeAt(0) ;
c4X=(c3X+c2X).toLowerCase() ;
/**************** typing assistance *****************/
if( !key&&(code1==432||code1==431)&&(code==417||code==416) ) // Z+0 and u'o' -> undo
{
c3X= (code1==432) ? 'u':'U'; c2X= (code==417) ? 'o':'O' ; CODE=1;
return sX1.substring(0,sX1.length-2)+c3X+c2X+c1X+sX2
}
if(key&&'wW7'.indexOf(key)>=0)
{
if(c4X=='uo') // uon
{
c3X= (c3X=='u') ? 432:431 ; c2X= (c2X=='o') ? 417:416; CODE=1;
return sX1.substring(0,sX1.length-2)+String.fromCharCode(c3X)+String.fromCharCode(c2X)+c1X+sX2
}
if('aA'.indexOf(c1X)>=0 && (i=0 && 'uU'.indexOf(c1X)>=0) continue // ou by no' u'
else if( c2X && 'uU'.indexOf(c2X)>=0 && 'uUaA'.indexOf(c1X)>=0) continue // uu, ua
else if( c2X && 'aA'.indexOf(c2X)>=0 && 'uU'.indexOf(c1X)>=0) // au
{
c2X= (c2X=='a') ? 226:194; CODE=1; // a^ , A^
return sX1.substring(0,sX1.length-1)+String.fromCharCode(c2X)+c1X+sX2
}
}
if( c4X=='gi' && c1X && 'aAuU'.indexOf(c1X)>=0 ) {}
else if( c2X && c1X && 'oO'.indexOf(c2X)>=0 && 'oO'.indexOf(c1X)>=0 ) {}
else if( c2X && c1X && 'iI'.indexOf(c2X)>=0 && 'aAuU'.indexOf(c1X)>=0 )continue // ia,iu
else if( ('aAiIyY'.indexOf(c1X)>=0 && (i=0) ){} // --qua, qui, quy , ia, i..
else if( ACCENT && 'oO'.indexOf(c1X)>=0 && c2X && 'uU'.indexOf(c2X)>=0 ){} // uo and ACCENT
else if( ACCENT && first && 'aAeEiIoOuUyY'.indexOf(c1X)>=0
&& !( ('aA'.indexOf(c1X)>=0||'eE'.indexOf(c1X)>=0) && i=0)
{
delta= idx % 6;
strA[i] = String.fromCharCode(VIETVOCAL[idx-delta]);
}
}
str1= strA.join('');
return str1;
}
function notviet(wrd)
{
wrd= wrd.toLowerCase();
// special , ngoai. le^.
var yes= "giac|giam|gian|giao|giap|giat|giay|giua|giuo|"
yes += "ngoam|quam"
var reg= eval("/"+yes+"/") ;
var res= reg.test(wrd) ;
if(res) return ''
var no= '' ;
no +="f|j|w|z|"
no +="aa|ab|ad|ae|ag|ah|ak|al|aq|ar|as|av|ax|"
no +="aca|aco|acu|"
no +="aia|aic|aie|aim|ain|aio|aip|ait|aiu|"
no +="ama|ame|ami|amo|amu|amy|"
no +="ana|ane|ani|ano|anu|any|"
no +="aoa|aoc|aoe|aoi|aom|aon|aop|aot|aou|"
no +="apa|ape|aph|api|apo|apu|"
no +="ata|ate|ath|ati|ato|atr|atu|aty|"
no +="aua|auc|aue|aui|aum|aun|auo|aup|aut|auu|auy|"
no +="aya|aye|ayn|ayt|ayu|"
no +="bb|bc|bd|bg|bh|bk|bl|bm|bn|bp|bq|br|bs|bt|bv|bx|by|"
no +="bec|bem|bio|boa|boe|bom|bou|bue|buy|"
no +="cb|cc|cd|ce|cg|ci|ck|cl|cm|cn|cp|cq|cr|cs|ct|cv|cx|cy|"
no +="chy|coa|coe|cou|cue|cuy|"
no +="db|dc|dg|dh|dk|dl|dm|dn|dp|dq|dr|ds|dt|dv|dx|dy|"
no +="dio|doe|dou|duu|"
no +="ea|eb|ed|ee|eg|eh|ei|ek|el|eq|er|es|ev|ex|ey|"
no +="eca|eco|ecu|ema|eme|emi|emo|emu|emy|ena|ene|eni|eno|enu|eny|"
no +="eoa|eoc|eoe|eoi|eom|eon|eop|eot|eou|epa|epe|eph|epi|epo|epu|"
no +="eta|ete|eth|eti|eto|etr|etu|ety|eua|euc|eue|eui|eum|eun|euo|eup|eut|euu|euy|"
no +="gb|gc|gd|gg|gk|gl|gm|gn|gp|gq|gr|gs|gt|gv|gx|gy|"
no +="gec|geo|get|geu|gha|gho|ghu|ghy|gic|gip|git|"
no +="goe|gou|gua|gue|gum|gup|guu|"
no +="hb|hc|hd|hg|hh|hk|hl|hm|hn|hp|hq|hr|hs|ht|hv|hx|"
no +="hio|hou|hya|hye|hyn|hyt|hyu|"
no +="ib|id|ig|ih|ii|ik|il|iq|ir|is|iv|ix|iy|"
no +="iac|iam|ian|iao|iap|iat|iay|"
no +="ica|ico|icu|ima|ime|imi|imo|imu|imy|ina|ine|ing|ini|ino|inu|iny|ioa|ioe|iou|"
no +="ipa|ipe|iph|ipi|ipo|ipu|ita|ite|ith|iti|ito|itr|itu|ity|iua|iue|iuo|iuu|iuy|"
no +="kb|kc|kd|kg|kk|kl|km|kn|kp|kq|kr|ks|kt|kv|kx|khy|"
no +="kac|kai|kam|kan|kao|kap|kat|kau|kay|"
no +="kea|key|khy|kio|koa|koc|koe|koi|kom|kon|kop|kot|kou|"
no +="kua|kuc|kue|kui|kum|kun|kuo|kup|kut|kuu|kuy|kya|kye|kyn|kyt|kyu|"
no +="lb|lc|ld|lg|lh|lk|ll|lm|ln|lp|lq|lr|ls|lt|lv|lx|"
no +="lio|lou|lue|lya|lye|lyn|lyt|lyu|"
no +="mb|mc|md|mg|mh|mk|ml|mm|mn|mp|mq|mr|ms|mt|mv|mx|"
no +="mio|mip|miu|moa|moe|mou|mue|mup|muy|mya|mye|myn|myt|myu|"
no +="nb|nc|nd|nk|nl|nm|nn|np|nq|nr|ns|nt|nv|nx|"
no +="ngi|nge|nhy|nim|nio|nip|noe|nue|nuy|nya|nye|nyn|nyt|nyu|"
no +="ob|od|og|oh|ok|ol|oo|oq|or|os|ov|ox|oy|"
no +="oam|oap|oeo|oao|oau|oca|och|oco|ocu|oec|oem|oep|oeu|"
no +="oia|oic|oie|oim|oin|oio|oip|oit|oiu|oma|ome|omi|omo|omu|omy|"
no +="ona|one|onh|oni|ono|onu|ony|opa|ope|oph|opi|opo|opu|"
no +="ota|ote|oth|oti|oto|otr|otu|oty|oua|ouc|oue|oui|oum|oun|ouo|oup|out|ouu|ouy|"
no +="pa|pb|pc|pd|pe|pg|pi|pk|pl|pm|pn|po|pp|pq|pr|ps|pt|pu|pv|px|py|phy|"
no +="qa|qb|qc|qd|qe|qg|qh|qi|qk|ql|qm|qn|qo|qp|qq|qr|qs|qt|qv|qx|qy|"
no +="quc|qum|qun|qup|qut|quu|"
no +="rb|rc|rd|rg|rh|rk|rl|rm|rn|rp|rq|rr|rs|rt|rv|rx|ry|"
no +="rec|rio|roa|roe|rou|rue|"
no +="sb|sc|sd|sg|sh|sk|sl|sm|sn|sp|sq|sr|ss|st|sv|sx|"
no +="sec|sia|sic|sin|sio|sip|sit|siu|soe|sop|sou|sue|sum|sup|sya|sye|syn|syt|syu|"
no +="tb|tc|td|tg|tk|tl|tm|tn|tp|tq|ts|tt|tv|tx|"
no +="thy|tio|tou|tya|tye|tyn|tyt|tyu|"
no +="ub|ud|ug|uh|uk|ul|uq|ur|us|uv|ux|"
no +="uam|uca|uch|uco|ucu|uec|uem|uep|ueu|"
no +="uia|uic|uie|uim|uin|uio|uip|uma|ume|umi|umo|umu|umy|"
no +="una|une|unh|uni|uno|unu|uny|uoa|uoe|upa|upe|uph|upi|upo|upu|"
no +="uta|ute|uth|uti|uto|utr|utu|uty|uua|uuc|uue|uui|uum|uun|uuo|uup|uut|uuu|uuy|"
no +="vb|vc|vd|vg|vh|vk|vl|vm|vn|vp|vq|vr|vs|vt|vv|vx|"
no +="vec|vep|vic|vim|vio|vip|voa|voe|vou|vue|vum|vup|vuu|vuy|vya|vye|vyn|vyt|vyu|"
no +="xb|xc|xd|xg|xh|xk|xl|xm|xn|xp|xq|xr|xs|xt|xv|xx|xy|"
no +="xim|xio|xip|xou|xuu"
no +="yb|yd|yg|yh|yi|yk|yl|ym|yo|yp|yq|yr|ys|yv|yx|yy|"
no +="yac|yai|yam|yan|yao|yap|yat|yau|yay|yec|yem|yeo|yep|yna|yne|yng|yni|yno|ynu|yny|"
no +="yta|yte|yth|yti|yto|ytr|ytu|yty|yua|yuc|yue|yui|yum|yun|yuo|yup|yut|yuu|yuy"
reg= eval("/"+no+"/") ;
res= reg.test(wrd) ;
return res
}
/************* QUICKBUILD-MENU **********************/
function actInit()
{
if(!hmenu ) hmenu = new MoveLayTo('qbmenu')
var WHeight=document.body.offsetHeight
var WWidth =document.body.offsetWidth
// Here you can customize the position of qbmenu *********************
var wx = WWidth - parseInt(document.all['qbmenu'].style.width)/2 -25
var wy = WHeight - parseInt(document.all['qbmenu'].style.height)/2 -25
// or wx= 10 and wy=10 -> top+left
// or wx= 10 -> bottom+left
// or wy= 10 -> top+right
// End position customize ********************************************
var wx1= wx-0.001, wy1= wy-0.001;
setInterval("hmenu.moveLayTo(50,"+wx1+","+wy1+","+wx+","+wy+")",25)
}
function qbmenuActivate()
{
// Here you can customize the appearance of qbmenu **********************
var mwidth= 137, mheight= 111, mbgcolor='#CBE7FF'; // menu size and color
var fsize= 11, fcolor= 'red', fface= 'arial'; // font size and color
var talign= '' ; //text align -> left,center,right,justify
var fstyle= '' ; //text style -> italic,normal
var tdecor= '' ; // text decoration -> underline,none
var mpadding= 3 ; // space between border and contents
var mbordercolor= '#336699'
var mborderwidth= 2
var mborderstyle= 'outset' ; // borderstyle -> none,solid,dotted,dashed,double,
// groove,ridge,inset,outset
// End customize **********************************************************
var str, mnuobj;
if(!document.all['qbmenu'])
{
str = ''
document.body.insertAdjacentHTML("BeforeEnd",str)
with(document.all['qbmenu'].style)
{
width= mwidth
height= mheight
background= mbgcolor
fontSize= fsize
fontFamily= fface
color= fcolor
textAlign= talign
fontStyle= fstyle
textDecoration= tdecor
padding= mpadding
borderStyle= mborderstyle
borderColor= mbordercolor
borderWidth= mborderwidth
}
actInit()
}
mnuobj= document.all['qbmenu']
var cmd='Đổi kiểu gõ [F9]'
str += ' ' +cmd+ 'SPELL=1-SPELL; qbmenuActivate(); return false">Tắt mở kiểm từ [F8]'
str += ' ' +cmd+ 'ON_OFF=1-ON_OFF; qbmenuActivate(); return false">Tắt mở bộ gõ [F12]'
str += ' ' +cmd+ 'hideQBmenu(); return false">Giấu Menu này'
var str1= mnuobj.innerHTML
var str1= str1.substring(0,str1.indexOf(''))
str1= toUnicode(str1)
str1= str1.replace(/\r/,'')
str1= str1.replace(/\n/,'')
if(str1!=str0)
{
mnuobj.innerHTML= str
QBsetCookie();
}
}
function hideQBmenu()
{
document.all['qbmenu'].style.visibility='hidden'
POPSTATUS=0; statusMessage()
if(TXTOBJ) TXTOBJ.focus();
else document.frames[fID].focus()
}
function MoveLayTo(idC)
{
this.First= 1
this.x = 0
this.y=0
this.dx=0
this.dy=0
this.objC = document.all[idC].style
this.moveLayTo = moveQBmenuTo
}
function moveQBmenuTo (np,X1,Y1,WW,HH)
{
if( WW==0 && HH==0 )
{
HH=document.body.offsetHeight
WW=document.body.offsetWidth
}
if ( this.First )
{
this.First=0;
this.objC.left= X1 ;
this.objC.top= Y1;
this.x = X1 ;
this.y = Y1
this.dx = (WW - X1) / np
this.dy = (HH - Y1) / np
return
}
var wPosX = document.body.scrollLeft
var wPosY = document.body.scrollTop
var widthC = parseInt(this.objC.width)
var heightC = parseInt(this.objC.height)
WW += ( wPosX - widthC/2)
HH += ( wPosY - heightC/2)
this.x += this.dx
this.y += this.dy
if( (this.dx>0 && this.x>=WW) || (this.dx<0 && this.x<=WW) ||
(this.dy>0 && this.y>=HH) || (this.dy<0 && this.y<=HH)
)
{ this.x= WW ; this.y=HH }
this.objC.left = this.x
this.objC.top = this.y
}
/**************** End QUICKBUILDMENU **********************/
/**************************************/
document.onmousedown=doMousedown
document.onmouseup= doMouseup
document.onkeypress=doKeypress
document.onkeydown=doKeydown
function doMousedown()
{
var el=event.srcElement
if(!el.type || (el.type!='text'&&el.type!='textarea'&&el.type!='div'&&el.type!='iframe')) return
if( el.type=='text' || el.type=='textarea' || el.type=='div'){ TXTOBJ=el; fID='' }
}
function doMouseup()
{
var el=event.srcElement
if(!el.type) return
if(el.type!='text'&&el.type!='textarea'&&el.type!='div')
ENGLISH=0;
if(POPSTATUS==1) qbmenuActivate()
else statusMessage()
}
function keyDownInit(key)
{
if(key==32||key==13||key==8) ENGLISH=0;
if(key==120){ON_OFF=1; TYPMOD++ ; TYPMOD %= 4 } // F9 =0/1/2=AUTO/VNI/TELEX/VIQR
else if(key==123){ON_OFF=1-ON_OFF} // F12
else if(key==119){SPELL=1-SPELL} // F8
if(key==120 || key==123 || key==119)
{
if(POPSTATUS) qbmenuActivate()
else statusMessage()
}
}
DAUDB=0; THOAT=0;
function doKeydown()
{
var el=event.srcElement
if(el.type!='text' && el.type!='textarea'&&el.type!='div'&&el.type!='iframe') return
var shft= event.shiftKey
var key= event.keyCode
keyDownInit(key)
if(ON_OFF==0 || ENGLISH || TYPMOD==1 || TYPMOD==2) return;
if(!shft && key==220){ DAUDB=6; viewViet(el,''); return false;}
if(shft && key==221){ DAUDB=2; viewViet(el,''); return false;}
else if(key==221){ DAUDB=1; viewViet(el,''); return false;}
}
function keyPressInit(key,obj)
{
if(ON_OFF==0 || ENGLISH) return;
var chr= String.fromCharCode(key) ;
var chr1= chr.toUpperCase() ;
if(chr=='\\'){ THOAT=1; return }
if(key==223){ chr='?'; chr1='?' } // outlaw chu+~ etzess
if("SFRXJDAEOWZ1234567890/\'?~.-\#(+*".indexOf(chr1)>=0) viewViet(obj,chr)
else if(chr1==' ') correcturAccent(obj)
DAUDB=0; THOAT=0;
}
function doKeypress()
{
var el=event.srcElement
if(el.type=='text'||el.type=='textarea'||el.type=='div'||el.type=='iframe') keyPressInit(event.keyCode,el)
if( CHANGE ){ CHANGE=0; return false ; }// abort
else return true ; // no abort
}
function QBsetCookie()
{
var now = new Date();
var exp = new Date(now.getTime() + 1000*60*60*24*365);
exp= exp.toGMTString();
document.cookie = 'VTYPMOD='+ TYPMOD + '; expires='+ exp;
document.cookie = 'VSPELL='+ SPELL + '; expires='+ exp;
document.cookie = 'VONOFF='+ ON_OFF + '; expires='+ exp;
}
function QBgetCookie()
{
var cookie= document.cookie ;
var reg= eval('/VSPELL/');
var res= reg.test(cookie) ;
if(res)
{
var cookieA= cookie.split('; ')
var both ;
for(var i=0; i"t@7
@p
g30 OMSx_4.3\viewreport.asp<%
'#################################################################################
'## Thong tin ve tac gia ##
'## --------------------------------------- ##
'## OMSx phien ban 4.3 duoc xay dung va phat trien boi Nguyen Duc Thuan ##
'## Thong tin lien he tac gia: email - ducthuan@gmail.com. Phone: 0905433659 ##
'#################################################################################
'## Cac thanh phan ma nguon mo mien phi duoc su dung trong OMSx 4.3 ##
'## --------------------------------------- ##
'## - Ha`m searchHighlighter dung de danh dau tu khoa khi tim kiem cua Web Wiz ##
'## Forums (http://www.webwizforums.com) ##
'## - Bo go tieng Viet Viettyping cung cap boi Vietdev ##
'## (http://vietdev.sourceforge.net) phat trien boi manguon.com ##
'## (http://www.manguon.com) ##
'#################################################################################
%>
<% If Session("admin") <> strSecCode Then Response.Redirect "login.asp?goto=viewreport.asp"
Dim lngReportID, strSubject, strMessage, blnDel
rs.Open "SELECT * FROM tblReport ORDER BY ReportID DESC;", omsCon
Do While NOT rs.EOF
lngReportID = CLng(rs("ReportID"))
blnDel = CBool(Request.Form("DelReport"&lngReportID))
If blnDel Then
omsCon.Execute("DELETE FROM tblReport WHERE ReportID = "&lngReportID&";")
End If
rs.MoveNext
Loop
rs.Close %>