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

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

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 (177.41 KB, 5 trang )

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 có Bài
viết nào cả"
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
<br /><table cellspacing="1" cellpadding="3" class="tableBorder"
align="center">
<tr class="tableLedger">
<td> + <% = strTxtAdv %> + </td>
</tr>
<tr>
<td colspan="5" class="tableRow"><div align="center"><img
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ẽ



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>
<td width="3%" align="center">&nbsp;</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">&nbsp;</td>
</tr><%
c.1. Tìm dòng code
Response.Write vbCrLf & " <tr class=""tableSubLedger""><td
colspan=""5""><a href=""default.asp?C=" & intCatID &
strQsSID2 & """>" & strCategory & "</a></td></tr>"
c.2. Thay thế bằng
Response.Write vbCrLf & " <tr class=""tableSubLedger""><td
colspan=""6""><a href=""default.asp?C=" & intCatID &
strQsSID2 & """>" & 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
strSubForums = strSubForums & "<a
href=""forum_topics.asp?FID=" & intSubForumID & strQsSID2 &
""" class=""smLink"">" & strSubForumName & "</a>"
e.2. Thay thế bằng
strSubForums = strSubForums & "<br /><img src=""" &
strImagePath & "mod/folder_line.gif"" border=""0""
align=""absmiddle"">&nbsp;<a href=""forum_topics.asp?FID=" &
intSubForumID & strQsSID2 & """ class=""smLink"">" &
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) &
"&nbsp;" & strTxtAt & "&nbsp;" &
TimeFormat(dtmLastEntryDate) & "" & _
"<br />" & strTxtBy & "&nbsp;<a
href=""member_profile.asp?PF=" & lngLastEntryUserID &
strQsSID2 & """ class=""smLink"">" & strLastEntryUser & "</a>
<a href=""get_last_post.asp?FID=" & intLastForumEntryID &
strQsSID2 & """><img src=""" & strImagePath &
"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) &
"&nbsp;" & strTxtAt & "&nbsp;" &
TimeFormat(dtmLastEntryDate) & "" & _
"<br />" & strTxtBy & "&nbsp;<a
href=""member_profile.asp?PF=" & lngLastEntryUserID &
strQsSID2 & """ class=""smLink"">" & strLastEntryUser & "</a>
<a href=""get_last_post.asp?FID=" & intLastForumEntryID &
strQsSID2 & """><img src=""" & strImagePath &

"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>")
%>
<a href="new_topic_form.asp?FID=<% = intForumID %>"
target="_self"><img src="<% = strImagePath
%>mod/icon_post.gif" border="0" align="absmiddle" alt="<% =
strTxtNewTopic %>"></a>
<a href="search_form.asp?FID=<% = intForumID %>"
target="_self"><img src="<% = strImagePath
%>mod/icon_search.gif" border="0" align="absmiddle" alt="<% =
strTxtSearch %>"></a>
<%
Response.Write(vbCrLf & " </td></tr>")
3. Copy file icon vào thư mục forum_images/mod



×