Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - latest 10 topics on main page
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

latest 10 topics on main page

 Post Reply Post Reply Page  <1234 6>
Author
dimoss View Drop Down
Groupie
Groupie


Joined: 18 March 2003
Location: Greece
Status: Offline
Points: 42
Post Options Post Options   Thanks (0) Thanks(0)   Quote dimoss Quote  Post ReplyReply Direct Link To This Post Posted: 30 December 2007 at 4:36pm
Originally posted by -boRg- -boRg- wrote:

You need to be running version 9.05, but if you are using a non-western character set then these often do not work well with RSS Feeds.


I use iso-8859-1 and I have the same error
Error: An invalid character was found in text content.

I use 9.06 MS-SQL
Back to Top
namtoday View Drop Down
Senior Member
Senior Member


Joined: 15 February 2005
Status: Offline
Points: 212
Post Options Post Options   Thanks (0) Thanks(0)   Quote namtoday Quote  Post ReplyReply Direct Link To This Post Posted: 06 January 2008 at 2:07pm
I didn't check the above post so i'm sorry if it's a double post, but since there's a request for last 10 topics, here's the mod:


<%


Set rsLatestPosts = Server.CreateObject("ADODB.Recordset")
strSql = "Select top 5 " & strDbTable & "Topic.Subject, " & strDbTable & "Topic.Topic_ID, " & strDbTable & "Forum.Forum_ID, " & strDbTable & "Forum.Forum_name, " & strDbTable & "Topic.Last_Thread_ID, " & strDbTable & "Topic.No_of_views "
strSql = strSql & "From " & strDbTable & "Topic, " & strDbTable & "Forum Where " & strDbTable & "Topic.Hide = False And " & strDbTable & "Topic.Forum_ID = " & strDbTable & "Forum.Forum_ID And " & strDbTable & "Topic.Forum_ID = 8  Order By " & strDbTable & "Topic.Last_Thread_ID desc"
rsLatestPosts.Open strSQL, adoCon






If rsLatestPosts.EOF Then
%>
      <p style="text-align: center">There's no topic to display. </p>
<%
Else

    Do while not rsLatestPosts.Eof

        Set rsLatestPosts2 = Server.CreateObject("ADODB.Recordset")
        sql2 = "SELECT tblThread.Thread_ID, tblThread.Topic_ID, tblThread.Message_date, tblAuthor.Username, tblAuthor.Author_ID FROM (tblAuthor INNER JOIN tblThread ON tblAuthor.Author_ID = tblThread.Author_ID) WHERE tblThread.Hide = False And Topic_ID= " & rsLatestPosts("Topic_ID") & " order by Message_date desc"
        rsLatestPosts2.Open sql2, adoCon

            LastLatestPostsDateTime = rsLatestPosts2("Message_date")
            LastLatestPostsDate = DateFormat(LastLatestPostsDateTime)
            LastLatestPostsTime = TimeFormat(LastLatestPostsDateTime)
            intForumColourNumber = intForumColourNumber + 1

%>   
   &nbsp;&nbsp;&nbsp;<img alt="" src="images/icon-arrow.png" align="absmiddle">&nbsp;<a class="smLink" href="forum_posts.asp?TID=<%= rsLatestPosts("Topic_ID")%>&get=last=<%= rsLatestPosts("Last_Thread_ID")%>" title=""><%= rsLatestPosts("Subject") %></a><br>
 
 
   
 <%
 rsLatestPosts.MoveNext
 loop
end if
%>


Back to Top
namtoday View Drop Down
Senior Member
Senior Member


Joined: 15 February 2005
Status: Offline
Points: 212
Post Options Post Options   Thanks (0) Thanks(0)   Quote namtoday Quote  Post ReplyReply Direct Link To This Post Posted: 06 January 2008 at 2:08pm
I'm sorry the above mod I took directly from my forum, so there's a line you will need to delete

find

&nbsp;&nbsp;&nbsp;<img alt="" src="images/icon-arrow.png" align="absmiddle">&nbsp;

Delete it.
Regards
Back to Top
kushty View Drop Down
Newbie
Newbie
Avatar

Joined: 20 April 2007
Location: United Kingdom
Status: Offline
Points: 8
Post Options Post Options   Thanks (0) Thanks(0)   Quote kushty Quote  Post ReplyReply Direct Link To This Post Posted: 17 January 2008 at 2:48pm
Originally posted by namtoday namtoday wrote:

I didn't check the above post so i'm sorry if it's a double post, but since there's a request for last 10 topics, here's the mod:


<%


Set rsLatestPosts = Server.CreateObject("ADODB.Recordset")
strSql = "Select top 5 " & strDbTable & "Topic.Subject, " & strDbTable & "Topic.Topic_ID, " & strDbTable & "Forum.Forum_ID, " & strDbTable & "Forum.Forum_name, " & strDbTable & "Topic.Last_Thread_ID, " & strDbTable & "Topic.No_of_views "
strSql = strSql & "From " & strDbTable & "Topic, " & strDbTable & "Forum Where " & strDbTable & "Topic.Hide = False And " & strDbTable & "Topic.Forum_ID = " & strDbTable & "Forum.Forum_ID And " & strDbTable & "Topic.Forum_ID = 8  Order By " & strDbTable & "Topic.Last_Thread_ID desc"
rsLatestPosts.Open strSQL, adoCon






If rsLatestPosts.EOF Then
%>
      <p style="text-align: center">There's no topic to display. </p>
<%
Else

    Do while not rsLatestPosts.Eof

        Set rsLatestPosts2 = Server.CreateObject("ADODB.Recordset")
        sql2 = "SELECT tblThread.Thread_ID, tblThread.Topic_ID, tblThread.Message_date, tblAuthor.Username, tblAuthor.Author_ID FROM (tblAuthor INNER JOIN tblThread ON tblAuthor.Author_ID = tblThread.Author_ID) WHERE tblThread.Hide = False And Topic_ID= " & rsLatestPosts("Topic_ID") & " order by Message_date desc"
        rsLatestPosts2.Open sql2, adoCon

            LastLatestPostsDateTime = rsLatestPosts2("Message_date")
            LastLatestPostsDate = DateFormat(LastLatestPostsDateTime)
            LastLatestPostsTime = TimeFormat(LastLatestPostsDateTime)
            intForumColourNumber = intForumColourNumber + 1

%>   
   &nbsp;&nbsp;&nbsp;<img alt="" src="images/icon-arrow.png" align="absmiddle">&nbsp;<a class="smLink" href="forum_posts.asp?TID=<%= rsLatestPosts("Topic_ID")%>&get=last=<%= rsLatestPosts("Last_Thread_ID")%>" title=""><%= rsLatestPosts("Subject") %></a><br>
 
 
   
 <%
 rsLatestPosts.MoveNext
 loop
end if
%>




namtoday,

where would this code be put?
Back to Top
namtoday View Drop Down
Senior Member
Senior Member


Joined: 15 February 2005
Status: Offline
Points: 212
Post Options Post Options   Thanks (0) Thanks(0)   Quote namtoday Quote  Post ReplyReply Direct Link To This Post Posted: 20 January 2008 at 5:46am
It should work in default file, or even you can save it as stand-alone file (asp extension), then include it @ ur own website, you will need to include common.asp and fucntion_format_date.asp file in order to get it work @ ur own site.
Back to Top
mattysdad View Drop Down
Groupie
Groupie


Joined: 24 February 2008
Status: Offline
Points: 47
Post Options Post Options   Thanks (0) Thanks(0)   Quote mattysdad Quote  Post ReplyReply Direct Link To This Post Posted: 15 March 2008 at 5:07pm
Hello all,
 
I tried inserting that code in to my default.asp file and it just crashed the site.
 
Could anybody explain to this idiot how I should do it?
 
Am running wwf 9.07
 
Thanks!
Back to Top
avsa.gen.tr View Drop Down
Newbie
Newbie
Avatar

Joined: 28 March 2008
Location: Avsa İsland
Status: Offline
Points: 1
Post Options Post Options   Thanks (0) Thanks(0)   Quote avsa.gen.tr Quote  Post ReplyReply Direct Link To This Post Posted: 28 March 2008 at 3:48pm

<table cellspacing="1" cellpadding="3" class="tableBorder" align="center">
<tr class="tableLedger">
  <td colspan="5">En Son Mesaj Yazılan Konular</td>
 </tr>
 <tr class="tableSubLedger">
    <td width="38%" align="center">Konu</td>
    <td width="19%" align="center">Forum</td>
    <td width="15%" align="center">Yazan</td>
    <td width="21%" align="center">Tarih</td>
    <td width="7%" align="center">Okunma</td>
  </tr>

<%
Dim rsLatestPosts
Dim intSay
Dim rsLatestPosts2
Dim sql2
Dim LastLatestPostsDateTime
Dim LastLatestPostsDate
Dim LastLatestPostsTime


Set rsLatestPosts = Server.CreateObject("ADODB.Recordset")
strSql = "Select " & strDbTable & "Topic.Subject, " & strDbTable & "Topic.Topic_ID, " & strDbTable & "Forum.Forum_ID, " & strDbTable & "Forum.Forum_name, " & strDbTable & "Topic.Last_Thread_ID, " & strDbTable & "Topic.No_of_views "
strSql = strSql & "From " & strDbTable & "Topic, " & strDbTable & "Forum Where " & strDbTable & "Topic.Hide = False And " & strDbTable & "Topic.Forum_ID = " & strDbTable & "Forum.Forum_ID Order By " & strDbTable & "Topic.Last_Thread_ID desc"
rsLatestPosts.Open strSQL, adoCon


For intSay = 1 to 30
if rsLatestPosts.Eof Then Exit For

Set rsLatestPosts2 = Server.CreateObject("ADODB.Recordset")
sql2 = "SELECT " & strDbTable & "Thread.Thread_ID, " & strDbTable & "Thread.Topic_ID, " & strDbTable & "Thread.Message_date, " & strDbTable & "Author.Username, " & strDbTable & "Author.Author_ID FROM (" & strDbTable & "Author INNER JOIN " & strDbTable & "Thread ON " & strDbTable & "Author.Author_ID = " & strDbTable & "Thread.Author_ID) WHERE " & strDbTable & "Thread.Hide = False And Topic_ID= " & rsLatestPosts("Topic_ID") & " order by Message_date desc"
rsLatestPosts2.Open sql2, adoCon

LastLatestPostsDateTime = rsLatestPosts2("Message_date")
LastLatestPostsDate = DateFormat(LastLatestPostsDateTime)
LastLatestPostsTime = TimeFormat(LastLatestPostsDateTime)


Response.Write "<tr class=""tableRow""><td><a href=""forum_posts.asp?TID=" & rsLatestPosts("Topic_ID") & strQsSID2 & """><img border=""0"" src=""" & strImagePath & "right_arrow.gif"" alt="""" /></a>&nbsp;<a href=""forum_posts.asp?TID=" & rsLatestPosts("Topic_ID") & "&get=last#" & rsLatestPosts("Last_Thread_ID") & strQsSID2 &""" title=""Son Mesajı Görüntülemek İçin Tıklayın"">" & rsLatestPosts("Subject") & "</a></td><td><a href=""forum_topics.asp?FID=" & rsLatestPosts("Forum_ID") & strQsSID2 & """ title=""Forum Ana Sayfasını Görüntülemek İçin Tıklayın"">" & rsLatestPosts("Forum_name") & "</a></td><td align=""center"">"&rsLatestPosts2("Username") &"</td><td align=""center"">" & LastLatestPostsDate & "-" & LastLatestPostsTime & "</td><td align=""center"">" & rsLatestPosts("No_of_views") & "</td></tr>"

rsLatestPosts2.Close

rsLatestPosts.MoveNext
Next

rsLatestPosts.Close

%>
</table>

Back to Top
mattysdad View Drop Down
Groupie
Groupie


Joined: 24 February 2008
Status: Offline
Points: 47
Post Options Post Options   Thanks (0) Thanks(0)   Quote mattysdad Quote  Post ReplyReply Direct Link To This Post Posted: 28 March 2008 at 4:37pm
Thanks, but it still does not work.
 
Back to Top
 Post Reply Post Reply Page  <1234 6>

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.