| | |
Newbie: Creating Blog-style Messageboard (Dreamweaver 8)
Please support our ASP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
![]() |
•
•
Join Date: Oct 2006
Posts: 3
Reputation:
Solved Threads: 0
Hello,
I am very new to ASP and have been taught by one of my colleagues that I could leverage Dreamweaver (i have version 8) to create ASPx pages that collaborate with Microsoft Access -- to implement a webpage that displays, as I would like to call it, news snippets -- this is relatively easy thing to do.
Now comes the problem of segregation: I need to start separating each individual news snippets. Why? Each news snippet will have a functionality where users can leave comments on that particular news snippet.
I believe blogs have this kind of functionality.
In my MS Access database, there are 2 tables. Here's the tables and their columns.
news_items
news_id (autonumber, primary key)
subject
title
by_who
user_comments
belonging_to_id (foreign key, value populated automatically as users submit comments via the front-end ASP page)
the_comment
When I look at Dreamweaver's generated code, it seems likely that I could start a dataset by writing a block of code (forgot how it looks like) with the corresponding SQL code injected inside this block of code.
I am trying to
1. Display the news snippets (think this part is ok for me)
2. Display the user's comments below each and every news snippet
3. Count the number of comments per news snippet
Should I use SQL and its "Count" and "Where" functionality to do #2 and #3? Or must I use VB?
Thanks for understanding. I come from client-end webpage programming background (JavaScript, DHTML and HTML) so I'm really interested in learning VB. Of course, Dreamweaver has to be part of the learning process
I am very new to ASP and have been taught by one of my colleagues that I could leverage Dreamweaver (i have version 8) to create ASPx pages that collaborate with Microsoft Access -- to implement a webpage that displays, as I would like to call it, news snippets -- this is relatively easy thing to do.
Now comes the problem of segregation: I need to start separating each individual news snippets. Why? Each news snippet will have a functionality where users can leave comments on that particular news snippet.
I believe blogs have this kind of functionality.
In my MS Access database, there are 2 tables. Here's the tables and their columns.
news_items
news_id (autonumber, primary key)
subject
title
by_who
user_comments
belonging_to_id (foreign key, value populated automatically as users submit comments via the front-end ASP page)
the_comment
When I look at Dreamweaver's generated code, it seems likely that I could start a dataset by writing a block of code (forgot how it looks like) with the corresponding SQL code injected inside this block of code.
I am trying to
1. Display the news snippets (think this part is ok for me)
2. Display the user's comments below each and every news snippet
3. Count the number of comments per news snippet
Should I use SQL and its "Count" and "Where" functionality to do #2 and #3? Or must I use VB?
Thanks for understanding. I come from client-end webpage programming background (JavaScript, DHTML and HTML) so I'm really interested in learning VB. Of course, Dreamweaver has to be part of the learning process
•
•
Join Date: Jun 2005
Posts: 107
Reputation:
Solved Threads: 3
•
•
•
•
I am trying to
1. Display the news snippets (think this part is ok for me)
2. Display the user's comments below each and every news snippet
3. Count the number of comments per news snippet
Should I use SQL and its "Count" and "Where" functionality to do #2 and #3? Or must I use VB?
Thanks for understanding. I come from client-end webpage programming background (JavaScript, DHTML and HTML) so I'm really interested in learning VB. Of course, Dreamweaver has to be part of the learning process
After that you just pull all the comments related to the snippet like
ASP Syntax (Toggle Plain Text)
"SELECT * FROM user_comments WHERE belonging_to_id =" & news_id
To count the number of comments you could either count as you loop through them, or make vb count the number of rows in the recordset.
ASP Syntax (Toggle Plain Text)
While Not recordset.EOF counter = counter + 1 recordset.MoveNext Wend ' OR counter = recordset.RecordCount ' OR ' read the sql results into an array and get the upper bounds RS.Open "SELECT * FROM user_comments WHERE belonging_to_id =" & news_id, connectionObject comsArray = RS.GetRows() counter = UBound(comsArray)-1 for i = 0 to ubound(comsArray)-1 response.write comsArray(1) 'write out the comment Next
The recordCount method will return "-1" unless you use the correct CursorType.
Last edited by madmital; Oct 3rd, 2006 at 12:14 pm.
Web Developer
When something seems too good to be true...it usually is
When something seems too good to be true...it usually is
![]() |
Similar Threads
- Tutorial: Create a cross-browser compatible, single-level, drop-down menu (Site Layout and Usability)
- Photoshop web photo gallery to dreamweaver (Site Layout and Usability)
- Using an Online Forum as a BLOG? (Growing an Online Community)
- Creating a Python ANSII game (dos) (Python)
- Page Rank on Google? (Search Engine Optimization)
- Creating rss feeds (ASP.NET)
- Am I Doing A Good Job? (DaniWeb Community Feedback)
- i made my first site (Website Reviews)
Other Threads in the ASP Forum
- Previous Thread: asp with vbscript and javascript
- Next Thread: Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
| Thread Tools | Search this Thread |
archive asp asp.net aspandmssqlserver2005 aspandmssqlserver2005connection aspconnection connection database databaseconnection dreamweaver excel fso iis msmsql mssql2005 mssqlserver2005 mssqlserver2005andasp mssqlserverandasp opentextfile record searchbox selectoption single specfic sqlserver sqlserverconnection windows7





