Tải bản đầy đủ (.pdf) (53 trang)

Hướng dẫn thiết kế thiết kế forum nhanh chóng và đơn giản

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (1.17 MB, 53 trang )

Simpo PDF Merge and Split Unregistered Version -

Bài 1: Việt hóa

Hướng dẫn thiết kế : Thiết kế Forum nhanh chóng và đơn giản

1. Down code Wwf 8.03
Thông tin đăng nhập:
 Username: admin
 Password: admin
2. Mở file browser_page_encoding_inc.asp
a.1. Tìm dòng code
Const strPageEncoding = "iso-8859-1"
a.2. Thay thế bằng
'Const strPageEncoding = "iso-8859-1"
b.1. Tìm dòng code
'Const strPageEncoding = "utf-8"
b.2. Thay thế bằng
Const strPageEncoding = "utf-8"
3. Mở file common.asp
a.1. Tìm dòng code
Server.ScriptTimeout = 90
Session.Timeout = 20
a.2. Thêm xuống dưới
Session.Codepage=65001
4. Mở file footer.asp
a.1. Tìm dòng code
</body>
</html>
a.2. Thêm lên trên
<div align=center>




<hr style="width: 50%;">


Simpo PDF Merge and Split Unregistered Version -

<!--#includes file="../Viettyping/Viettyping.asp"-->
<% Call VietTypeMod()%>
<%="<span class=""smText"">HREF="""">" & strWebsiteName & "</A> Website của những người đam
mê lập trình ASP
</span>"%>
<!-- #include file="../clock.asp" -->
<%="<span class=""smText"">Xem tốt nhất
với IE 6.0, độ phân giải
màn hình 800x600 pixels
Developed by target=_blank HREF="""">Hoai An
Net</A></span>"%>


</div>
5. Mở file admin_footer_inc.asp
a.1. Tìm dòng code
</td>
</tr>
a.2. Thêm lên trên
<!--#includes file="footer.asp"-->
6. Tạo file ha_language_file_inc.asp trong thư mục language_files có

nội dung
<%
Const strTxtAuto = "Tự động"
Const strTxtTELEX = "TELEX"
Const strTxtVNI = "VNI"
Const strTxtVIQR = "VIQR"
Const strTxtOff = "Tắt"
Const strTxtRemember = "Ghi nhớ"
%>
7. Mở file language_file_inc.asp
a.1. Tìm dòng code


Simpo PDF Merge and Split Unregistered Version -

Const strTxtSecurityCodeDidNotMatch2 = "The Security Code
entered did not match that displayed."
%>
a.2. Thêm xuống dưới
<!--#include file="ha_language_file_inc.asp"-->
8. Copy thư mục Viettyping vào website của bạn (wwf)
9. Copy file clock vào website của bạn (wwf)
10. Down Unikey 3.63, sau khi install xong, chọn bảng mã là NCR
Decimal
a.1. Hình vẽ

a.2. Mở file language_file_inc.asp
a.1.1. Tìm dòng code
Const strTxtWelcome = "Welcome"
a.1.2. Thay thế bằng

Const strTxtWelcome = "Chào mừng"
a.1.3. Việc thay thế ở đây chính là việc bạn nhập chữ “Chào mừng”
thay cho chữ “Welcome” theo kiểu gõ bạn đang chọn bằng bảng mã
NCR Decimal mà bạn đã chọn ở trên. Nó tự động hiện ra chữ
"Chào mừng"
a.1.4. Làm tương tự cho các dòng còn lại trong file này và các file
khác trong thư mục language_files


Simpo PDF Merge and Split Unregistered Version -

Bài 2: Giới tính

1. Mở table wwForum.mdb
a.1. Mở tblAuthor, thêm trường: Sex, kiểu: Yes/No, giá trị default:
True
a.2. Hình vẽ

2. Mở file register.asp
a.1. Tìm dòng code
Dim strAdminNotes
about the user

'Holds admin/modertor info/notes

a.2. Thêm xuống dưới
Dim blnSex

'Holds the member Sex


b.1. Tìm dòng code
blnConfirmPassOK = true
b.2. Thêm xuống dưới
blnSex = true
c.1. Tìm dòng code
blnShowEmail = CBool(Request.Form("emailShow"))
c.2. Thêm xuống dưới


Simpo PDF Merge and Split Unregistered Version -

blnSex = CBool(Request.Form("sex"))
d.1. Tìm dòng code
.Fields("Show_email") = blnShowEmail
d.2. Thêm xuống dưới
.Fields("Sex") = blnSex
e.1. Tìm dòng code
blnShowEmail = CBool(rsCommon("Show_email"))
e.2. Thêm xuống dưới
blnSex = CBool(rsCommon("Sex"))
f.1. Tìm dòng code
<tr class="tableRow">
<td><% = strTxtEmail %><%
f.2. Thêm lên trên
<tr class="tableRow">
<td><% = strTxtSex %></td>
<td>  
border="0"
src="forum_images/mod/male.gif">  <%

=
strTxtMale %>  value="True" <% If blnSex = True Then Response.Write
"checked" %> checked>
    
border="0"
src="forum_images/mod/female.gif">  <%
=
strTxtFemale %>  value="False" <% If blnSex = False Then Response.Write
"checked" %> />
</td>
</tr>
3. Mở file ha_language_file_inc.asp
a.1. Tìm dòng code
Const strTxtRemember = "Ghi nhớ"


Simpo PDF Merge and Split Unregistered Version -

a.2. Thêm xuống dưới
Const strTxtSex = "Giới tính"
Const strTxtMale = "Nam"
Const strTxtFemale = "Nữ"
4. Mở file member_profile.asp
a.1. Tìm dòng code
Dim blnAccSuspended
suspended


'Holds if the user account is

a.2. Thêm xuống dưới
Dim strSex

'Hold the sex of member

b.1. Tìm dòng code
strEmail = rsCommon("Author_email")
b.2. Thêm xuống dưới
strSex = CBool(rsCommon("Sex"))
c.1. Tìm dòng code
<tr>
<td><% = strTxtInterests %>:</td>
<td><% If strInterests = "" OR IsNull(strInterests) Then
Response.Write(strTxtNotGiven) Else Response.Write(strInterests)
%></td>
</tr>
c.2. Thêm xuống dưới
<tr>
<td><% = strTxtSex %>:</td>
<td><% If strSex = True Then Response.Write("src='forum_images/mod/male.gif'>") Else Response.Write("src='forum_images/mod/female.gif'>") %></td>
</tr>
5. Mở file forum_posts.asp
a.1. Tìm dòng code
Dim strForumPassword

'Holds the forum password



Simpo PDF Merge and Split Unregistered Version -

a.2. Thêm xuống dưới
Dim strSex

'Hold the sex of member

b.1. Tìm dòng code
& "Author.Avatar_title, "
b.2. Thêm xuống dưới
& strDbTable & "Author.Sex, "
c.1. Tìm dòng code
'16 = tblGroup.Name,
'17 = tblGroup.Stars,
'18 = tblGroup.Custom_stars
'19 = tblGuestName.Name
c.2. Thay thế bằng
'16 = tblAuthor.Sex,
'17 = tblGroup.Name,
'18 = tblGroup.Stars,
'19 = tblGroup.Custom_stars
'20 = tblGuestName.Name
d.1. Tìm dòng code
'16 = tblGroup.Name,
'17 = tblGroup.Stars,
'18 = tblGroup.Custom_stars
'19 = tblGuestName.Name
d.2. Thay thế bằng

'16 = tblAuthor.Sex,
'17 = tblGroup.Name,
'18 = tblGroup.Stars,
'19 = tblGroup.Custom_stars
'20 = tblGuestName.Name
e.1. Tìm dòng code
strGroupName = sarryPosts(16,intCurrentRecord)


Simpo PDF Merge and Split Unregistered Version -

intRankStars = CInt(sarryPosts(17,intCurrentRecord))
intRankStars = CInt(sarryPosts(17,intCurrentRecord))
strGuestUsername = sarryPosts(19,intCurrentRecord)
e2. Thay thế bằng
strSex = sarryPosts(16,intCurrentRecord)
strGroupName = sarryPosts(17,intCurrentRecord)
intRankStars = CInt(sarryPosts(18,intCurrentRecord))
strRankCustomStars = sarryPosts(19,intCurrentRecord)
strGuestUsername = sarryPosts(20,intCurrentRecord)
f.1. Tìm dòng code
Response.Write(vbCrLf & "

" & strTxtJoined & ": "
& DateFormat(dtmAuthorRegistration))
f.2. Thêm xuống dưới
'Show the sex
Response.Write(vbCrLf & "
" & strTxtSex & ": ")
If strSex = True then

strSex = "<img src='forum_images/mod/male.gif'>"
Elseif strSex = False then
strSex = "<img src='forum_images/mod/female.gif'>"
End If
Response.Write(vbCrLf & strSex)
6. Copy thư mục sex vào thư mục forum_images


Simpo PDF Merge and Split Unregistered Version -

Bài 3: Chào mừng

1. Mở file ha_language_file_inc.asp
a.1. Tìm dòng code
Const strTxtFemale = "Nữ"
a.2. Thêm xuống dưới
Const strTxtWelcomeHA = "Chào mừng bạn
đến với Cộng đồng
ASP Việt Nam"
Const strTxtWelcomeDetail1 = "Nếu là lần
đầu
tiên
bạn
duyệt
Diễn đàn này, hãy click
chuột vào"
Const
strTxtWelcomeDetail2
=
"để

hướng dẫn. Bạn nên"

xem

Const strTxtWelcomeDetail3 = "trước khi gửi
bài. Để xem các bài viết,
hãy chọn các Diễn đàn
mà bạn muốn ở bên
dưới. "
2. Mở file default.asp
a.1. Tìm dòng code
vbCrLf & " </td>")
End If

%>
</table>
a.2. Thêm xuống dưới
align="center">

cellpadding="3"

<tr class="tableLedger">
<td> + <% = strTxtWelcomeHA %> + </td>

class="tableBorder"


Simpo PDF Merge and Split Unregistered Version -


</tr>
<tr>
colspan="5"
class="tableRow"><%
=
strTxtWelcomeDetail1 %> <a href="help.asp"><% = strTxtHelp
%></a>
<%
=
strTxtWelcomeDetail2
%>
href="registration_rules.asp?FID=0"><% = strTxtRegister %></a>
<% = strTxtWelcomeDetail3 %></td>
</tr>
</table>


Bài 4: Thành viên tích cực – thành viên mới – chủ đề mới – bài viết
mới

1. Mở file ha_language_file_inc.asp
a.1. Tìm dòng code
Const strTxtWelcomeDetail3 = "trước khi gửi
bài. Để xem các bài viết,
hãy chọn các Diễn đàn
mà bạn muốn ở bên
dưới. "
a.2. Thêm xuống dưới

Const strTxtBestMember = "Thành viên tích
cực"
Const strTxtNewMember = "Thành viên mới"
Const strTxtLastNewTopic
mới"

=

"Chủ

đề

Const strTxtLastNewPost = "Bài viết mới"
Const strTxtNoMember = "Không có Thành
viên nào cả"
Const strTxtNoTopic = "Không có Chủ
đề nào cả"
Const strTxtNoPost = "Không
viết nào cả"



Bài


Simpo PDF Merge and Split Unregistered Version -

2. Mở file default.asp
a.1. Tìm dòng code
'Clean up

Call closeDatabase()
a.2. Thay thế bằng
'Clean up
'Call closeDatabase()
b.1. Tìm dòng code
%>
</table>


class="basicTable"
border="0"
cellspacing="0"
cellpadding="2" align="center" style="width:550px;">
<tr class="smText">
b.2. Thêm lên trên
'Clean up
Set rsCommon = Nothing
Call closeDatabase()
c.1. Tìm dòng code
<td colspan="5" class="tableRow"><% = strTxtWelcomeDetail1
%> <a href="help.asp"><% = strTxtHelp %></a> <% =
strTxtWelcomeDetail2
%>
href="registration_rules.asp?FID=0"><% = strTxtRegister %></a>
<% = strTxtWelcomeDetail3 %></td>
</tr>
</table>


c.2. Thêm xuống dưới
<%Dim intLoop%>
align="center">
<tr class="tableLedger">


Simpo PDF Merge and Split Unregistered Version -

<td width="25%" align="center"> + <% = strTxtBestMember %>
+ </td>
<td width="25%" align="center"> + <% = strTxtNewMember %>
+ </td>
<td width="25%" align="center"> + <% = strTxtLastNewTopic
%> + </td>
<td width="25%" align="center"> + <% = strTxtLastNewPost
%> + </td>
</tr>
<tr class="tableRow">
<td valign=top align="left">
<%
strSQL = "SELECT TOP 10 " & strDbTable &
"Author.Username, " & strDbTable & "Author.Author_ID , " &
strDbTable & "Author.No_of_posts " & _
"FROM " & strDbTable & "Author" & strDBNoLock & " "
&_
"WHERE " & strDbTable & "Author.No_of_posts > 0 " & _
"ORDER BY " & strDbTable & "Author.No_of_posts
DESC;"
'Query the database

rsCommon.Open strSQL, adoCon, 3, 3
if rsCommon.RecordCount > 0 then
For intLoop = 1 To rsCommon.RecordCount
if rsCommon.EOF then exit For
if Len(intLoop) < 2 then intLoop = 0 & intLoop
Response.Write intLoop & ". HREF=""member_profile.asp?PF=" & rsCommon("Author_ID")
& " & rsCommon("Username") & "</A> [" & strTxtPosts & ": " &
rsCommon("No_of_posts") & "]<BR>"
rsCommon.MoveNext
Next
else


Simpo PDF Merge and Split Unregistered Version -

Response.Write(vbCrLf & " " & strTxtNoMember)
end if
'Clean up
rsCommon.close
%>
</td>
<td valign=top align="left">
<%
strSQL = "SELECT TOP 10 " & strDbTable &
"Author.Username, " & strDbTable & "Author.Author_ID , " &
strDbTable & "Author.No_of_posts " & _
"FROM " & strDbTable & "Author" & strDBNoLock & " "
&_

"WHERE " & strDbTable & "Author.Author_ID > 2 " & _
"ORDER BY " & strDbTable & "Author.Author_ID DESC;"
'Query the database
rsCommon.Open strSQL, adoCon, 3, 3
if rsCommon.RecordCount > 0 then
For intLoop = 1 To rsCommon.RecordCount
if rsCommon.EOF then exit For
if Len(intLoop) < 2 then intLoop = 0 & intLoop
Response.Write intLoop & ". HREF=""member_profile.asp?PF=" & rsCommon("Author_ID")
& """>" & rsCommon("Username") & "</A> [" & strTxtPosts & ":
" & rsCommon("No_of_posts") & "]<BR>"
rsCommon.MoveNext
Next
else
Response.Write(vbCrLf & " " & strTxtNoMember)


Simpo PDF Merge and Split Unregistered Version -

end if
'Clean up
rsCommon.close
%>
</td>
<td valign=top align="left">
<%
strSQL = "SELECT TOP 10 " & strDbTable &
"Topic.Topic_ID, " & strDbTable & "Topic.Subject , " &

strDbTable & "Topic.No_of_replies " & _
"FROM " & strDbTable & "Topic" & strDBNoLock & " " &
_
"ORDER BY " & strDbTable & "Topic.Topic_ID DESC;"
'Query the database
rsCommon.Open strSQL, adoCon, 3, 3
if rsCommon.RecordCount > 0 then
For intLoop = 1 To rsCommon.RecordCount
if rsCommon.EOF then exit For
if Len(intLoop) < 2 then intLoop = 0 & intLoop
Response.Write intLoop & ". HREF=""forum_posts.asp?TID=" & rsCommon("Topic_ID") &
""">" & Left(rsCommon("Subject"), 20) & "</A> [" &
strTxtReplies & ": " & rsCommon("No_of_replies") & "]<BR>"
rsCommon.MoveNext
Next
else
Response.Write(vbCrLf & " " & strTxtNoTopic)
end if
'Clean up


Simpo PDF Merge and Split Unregistered Version -

rsCommon.close
%>
</td>
<td valign=top align="left">
<%

strSQL = "SELECT TOP 10 " & strDbTable &
"Topic.Topic_ID, " & strDbTable & "Topic.Subject , " &
strDbTable & "Topic.No_of_replies, " & strDbTable &
"Topic.Last_Thread_ID, " & strDbTable & "Thread.Message, " &
strDbTable & "Thread.Message_date, " & strDbTable &
"Thread.Thread_ID " & _
"FROM " & strDbTable & "Topic" & strDBNoLock & "," &
strDbTable & "Thread" & strDBNoLock & " " & _
"WHERE " & strDbTable & "Topic.Last_Thread_ID = " &
strDbTable & "Thread.Thread_ID " & _
"ORDER BY " & strDbTable & "Topic.Last_Thread_ID
DESC;"
'Query the database
rsCommon.Open strSQL, adoCon, 3, 3
if rsCommon.RecordCount > 0 then
For intLoop = 1 To rsCommon.RecordCount
if rsCommon.EOF then exit For
if Len(intLoop) < 2 then intLoop = 0 & intLoop
Response.Write intLoop & ". removeHTML(rsCommon("Message"), 150, true) & """
HREF=""forum_posts.asp?TID=" & rsCommon("Topic_ID") &
"&get=last#" & rsCommon("Thread_ID") & """>" &
Left(rsCommon("Subject"), 20) & "</A> [" & strTxtReplies & ": "
& rsCommon("No_of_replies") & "]<BR>"
rsCommon.MoveNext
Next
else
Response.Write(vbCrLf & " " & strTxtNoTopic)



Simpo PDF Merge and Split Unregistered Version -

end if
'Clean up
rsCommon.close
%>
</td>
</tr>
</tr>
</table>



Simpo PDF Merge and Split Unregistered Version -

Bài 5: Quảng cáo

1. Mở file ha_language_file_inc.asp
a.1. Tìm dòng code
Const strTxtNoPost = "Không
viết nào cả"



Bài

a.2. Thêm xuống dưới
Const strTxtAdv = "Dành cho Quảng cáo"
2. Mở file default.asp

a.1. Tìm dòng code
<!-- #include file="includes/footer.asp" -->
a.2. Thêm lên trên

align="center">
<tr class="tableLedger">
<td> + <% = strTxtAdv %> + </td>
</tr>
<tr>
<td colspan="5" class="tableRow"><div align="center">src="forum_images/adv/qc.gif" width="468" height="60"
border="0"></div></td>
</tr>
</table>
3. Copy thư mục adv vào thư mục forum_images

Bài 6: Sắp xếp lại trang default.asp

1. Hình vẽ


Simpo PDF Merge and Split Unregistered Version -

2. Mở file default.asp
a.1. Tìm dòng code
<td width="56%"><% = strTxtForum %></td>
<td width="6%" align="center"><% = strTxtTopics %></td>
<td width="6%" align="center"><% = strTxtPosts %></td>
<td width="28%" align="center"><% = strTxtLastPost %></td>

</tr>
<tr>
<td colspan="5" class="tableRow"><% = strTxtNoForums
%></td></tr>
a.2. Thay thế bằng
<td width="52%"><% = strTxtForum %></td>
<td width="25%" align="center"><% = strTxtLastPost %></td>
<td width="8%" align="center"><% = strTxtTopics %></td>
<td width="8%" align="center"><% = strTxtPosts %></td>


Simpo PDF Merge and Split Unregistered Version -

<td width="3%" align="center"> </td>
</tr>
<tr>
<td colspan="6" class="tableRow"><% = strTxtNoForums
%></td></tr>
b.1. Tìm dòng code
<td width="56%"><% = strTxtForum %></td>
<td width="6%" align="center"><% = strTxtTopics %></td>
<td width="6%" align="center"><% = strTxtPosts %></td>
<td width="28%" align="center"><% = strTxtLastPost %></td>
</tr><%
b.2. Thay thế bằng
<td width="52%"><% = strTxtForum %></td>
<td width="25%" align="center"><% = strTxtLastPost %></td>
<td width="8%" align="center"><% = strTxtTopics %></td>
<td width="8%" align="center"><% = strTxtPosts %></td>
<td width="3%" align="center"> </td>

</tr><%
c.1. Tìm dòng code
Response.Write vbCrLf & " <tr class=""tableSubLedger"">colspan=""5"">
" & strCategory & "</a></td></tr>"
c.2. Thay thế bằng
Response.Write vbCrLf & " <tr class=""tableSubLedger"">colspan=""6"">
" & strCategory & "</a></td></tr>"
d.1. Tìm dòng code
If strSubForums <> "" Then strSubForums = strSubForums & ", "
d.2. Thay thế bằng
If strSubForums <> "" Then strSubForums = strSubForums
e.1. Tìm dòng code


Simpo PDF Merge and Split Unregistered Version -

strSubForums = strSubForums & "href=""forum_topics.asp?FID=" & intSubForumID & strQsSID2 &
""" class=""smLink"">" & strSubForumName & "</a>"
e.2. Thay thế bằng
strSubForums = strSubForums & "
strImagePath & "mod/folder_line.gif"" border=""0""
align=""absmiddle""> 
" &
strSubForumName & "</a>"
f.1. Tìm dòng code
vbCrLf & " <td align=""center"">" & lngNumberOfTopics &

"</td>" & _
vbCrLf & " <td align=""center"">" & lngNumberOfPosts &
"</td>" & _
vbCrLf & " <td class=""smText"" align=""right"" nowrap>")
If lngNumberOfPosts <> 0 Then 'Don't disply last post details if
there are none
Response.Write(DateFormat(dtmLastEntryDate) &
" " & strTxtAt & " " &
TimeFormat(dtmLastEntryDate) & "" & _
"
" & strTxtBy & " href=""member_profile.asp?PF=" & lngLastEntryUserID &
strQsSID2 & """ class=""smLink"">" & strLastEntryUser & "</a>
"right_arrow.gif"" align=""absmiddle"" border=""0"" alt=""" &
strTxtViewLastPost & """ /></a>")
End If
Response.Write("</td>" & _
f.2. Thay thế bằng
vbCrLf & " <td class=""smText"" align=""right"" nowrap>")
If lngNumberOfPosts <> 0 Then 'Don't disply last post details if
there are none
Response.Write(DateFormat(dtmLastEntryDate) &


Simpo PDF Merge and Split Unregistered Version -

" " & strTxtAt & " " &
TimeFormat(dtmLastEntryDate) & "" & _

"
" & strTxtBy & " href=""member_profile.asp?PF=" & lngLastEntryUserID &
strQsSID2 & """ class=""smLink"">" & strLastEntryUser & "</a>
"right_arrow.gif"" align=""absmiddle"" border=""0"" alt=""" &
strTxtViewLastPost & """ /></a>")
End If
Response.Write("</td>" & _
vbCrLf & " <td align=""center"">" & lngNumberOfTopics &
"</td>" & _
vbCrLf & " <td align=""center"">" & lngNumberOfPosts &
"</td><td>")
%>
target="_self"><% =<br />strTxtNewTopic %></a>
target="_self"><% =<br />strTxtSearch %></a>
<%
Response.Write(vbCrLf & " </td></tr>")
3. Copy file icon vào thư mục forum_images/mod


Simpo PDF Merge and Split Unregistered Version -


Bài 7: Thay skin

1. Hình vẽ

2. Copy images đè lên các file trong thư mục forum_images
3. Copy default_style vào thư mục css_styles

Bài 8: Music

1. Mở file functions_format_post.asp
a.1. Tìm dòng code
'Return the function
searchHighlighter = strTempMessage


Simpo PDF Merge and Split Unregistered Version -

End Function
a.2. Thêm xuống dưới
Function formatWMAPL(ByVal strMessage)

'Declare variables
Dim lngStartPos

'Holds search start postions

Dim lngEndPos

'Holds end start postions


Dim saryWMAAttributes 'Holds the features of the input
WMA file
Dim intAttrbuteLoop

'Holds the attribute loop counter

Dim strWMAWidth
of the WMA file

'Holds the string value of the width

Dim intWMAWidth
width of the WMA file

'Holds the interger value of the

Dim strWMAHeight
height of the WMA file

'Holds the string value of the

Dim intWMAHeight
height of the WMA file

'Holds the interger value of the

Dim strBuildWMALink 'Holds the converted BBcode for
the WMA file
Dim strTempWMAMsg 'Tempoary store for the BBcode
Dim strWMALink 'Holds the link to the WMA file


'Loop through all the codes in the message and convert them
to formated WMA links
Do While InStr(1, strMessage, "[MUSIC", 1) > 0 AND
InStr(1, strMessage, "[/MUSIC]", 1) > 0
'Initiliase variables
intWMAWidth = 300


Simpo PDF Merge and Split Unregistered Version -

intWMAHeight = 300
strWMALink = ""
strBuildWMALink = ""
strTempWMAMsg = ""
'Get the WMA BBcode from the message
lngStartPos = InStr(1, strMessage, "[MUSIC", 1)
lngEndPos = InStr(lngStartPos, strMessage,
"[/MUSIC]", 1) + 8
'Make sure the end position is not in error
If lngEndPos < lngStartPos Then lngEndPos =
lngStartPos + 6
'Get the original WMA BBcode from the message
strTempWMAMsg = Trim(Mid(strMessage,
lngStartPos, lngEndPos-lngStartPos))

'Get the start and end in the message of the attributes
of the WMA file
lngStartPos = InStr(1, strTempWMAMsg, "[MUSIC",
1) + 6

lngEndPos = InStr(lngStartPos, strTempWMAMsg,
"]", 1)
'Make sure the end position is not in error
If lngEndPos < lngStartPos Then lngEndPos =
lngStartPos


Simpo PDF Merge and Split Unregistered Version -

'If there is something returned get the details (eg.
dimensions) of the WMA file
If strTempWMAMsg <> "" Then
'Place any attributes for the WMA file in an
array
saryWMAAttributes =
Split(Trim(Mid(strTempWMAMsg, lngStartPos, lngEndPoslngStartPos)), " ")
'Get the dimensions of the WMA file
'Loop through the array of atrributes that are for
the falsh file to get the dimentions
For intAttrbuteLoop = 0 To
UBound(saryWMAAttributes)
'If this is the width attribute then read in
the width dimention
If InStr(1,
saryWMAAttributes(intAttrbuteLoop), "WIDTH=", 1) Then
'Get the width dimention
strWMAWidth =
Replace(saryWMAAttributes(intAttrbuteLoop), "WIDTH=", "", 1,
-1, 1)
'Make sure we are left with a

numeric number if so convert to an interger and place in an interger
variable
If isNumeric(strWMAWidth) Then
intWMAWidth = CInt(strWMAWidth)
End If
'If this is the height attribute then read in
the height dimention