Print Page | Close Window

Alignment Query

Printed From: Web Wiz Forums
Category: Web Wiz Web App Support Forums
Forum Name: Web Wiz Forums
Forum Description: Support forum for Web Wiz Forums application.
URL: https://forums.webwiz.net/forum_posts.asp?TID=17319
Printed Date: 15 April 2026 at 7:38pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Alignment Query
Posted By: Shayneh
Subject: Alignment Query
Date Posted: 23 November 2005 at 4:12am
Hi all,
 
A real easy question for you gurus out there but i cant seem to figure it out. I have Top posters code installed as below but it displays the top posters vertically when i need it to be displayed horizontally.
 
Example. It displays as below
 
    Poster1 xx
    Poster2 xx
    Poster3 xx
    Poster4 xx
    Poster5 xx
 
I need it display as Poster1 xx, Poster2 xx, Poster3 xx, Poster4 xx, Poster5 xx
 
Quote
<script  language="JavaScript">
<!-- Hide from older browsers...
//Function to open pop up window
function openWin(theURL,winName,features) {
   window.open(theURL,winName,features);
}
// -->
</script>
<%
Dim rsTopPostersMod
Dim strSQLTopPostersMod
Dim strTopPostersModCon
Dim adoTopPostersModCon
Dim strTopPosterUsername
Dim strTopPostersModForumPath
'The path to the forum
strTopPostersModForumPath = " "
'Database connection
'-----------------------------
'-----------------------------
'Default connection
strTopPostersModCon = "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & Server.MapPath("admin/database/wwforum.mdb")
'Uncomment for a full phsyical path. Then change the path
'strTopPostersModCon = "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=C:/yoursite/root/forum/admin/database/"
'Uncomment for a DSN connection
'strTopPostersModCon = "DSN=DSN_NAME"
'-----------------------------
'-----------------------------
Set adoTopPostersModCon = Server.CreateObject("ADODB.Connection")
adoTopPostersModCon.Open strTopPostersModCon
Set rsTopPostersMod = Server.CreateObject("ADODB.Recordset")
strSQLTopPostersMod = "SELECT TOP 5 tblAuthor.Author_ID, tblAuthor.Username, tblAuthor.No_of_posts FROM tblAuthor "
strSQLTopPostersMod = strSQLTopPostersMod & "ORDER BY tblAuthor.No_of_posts DESC;"
rsTopPostersMod.Open strSQLTopPostersMod, adoTopPostersModCon
Do WHILE NOT rsTopPostersMod.EOF
 If len(rsTopPostersMod("Username"))>18 then
  strTopPosterUsername = left(rsTopPostersMod("Username"),18)
 Else
  strTopPosterUsername = rsTopPostersMod("Username")
 End If
 Response.Write("<a href=""javascript:openWin('" & strTopPostersModForumPath & "pop_up_profile.asp?PF=" & rsTopPostersMod("Author_ID") & "','profile','toolbar=0,location=0,status=0,menubar=0,scrollbars=1,resizable=1,width=590,height=425' )"">" & strTopPosterUsername & "</a> (" & rsTopPostersMod("No_of_posts") & ")")
rsTopPostersMod.MoveNext
If NOT rsTopPostersMod.EOF Then Response.Write("<br>")
Loop
rsTopPostersMod.Close
Set rsTopPostersMod = Nothing
adoTopPostersModCon.Close
Set adoTopPostersModCon = Nothing
%>
 
Appreciate the help!
 
 



Replies:
Posted By: Ali Bilgrami
Date Posted: 23 November 2005 at 8:35am
first of all this is a topic related to MODS you shud be posting this in the relative topic in which this mod was discussed originally AND in the relative MODS FORUM unless you had some other reason for making a new one.
ANYWAY
 
change this
 
Quote
If NOT rsTopPostersMod.EOF Then Response.Write("<br>")
Loop
 
to this
 
Quote
If NOT rsTopPostersMod.EOF Then Response.Write(":")
Loop
 
OR if you do not want a spacer
 
Quote
Loop
 
simply delete the IF statement above LOOP.



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net