jjr0319
01-10-2006, 11:24 AM
i have a FAQ page created in ASP. the questions/answers are stored in microsoft access. on the main faq page is a listing of just the questions, which get called from the DB by a simple SELECT statement:
strSQL = strSQL & "SELECT * FROM FAQ ORDER BY FAQ.[DATE]DESC, FAQ.[QUESTION]"
i want to hyperlink these questions, so that when clicked, the question and it's answer will be in a popup box. right now, i just have the link setup as a .htm file, in which i have to manually code the question and answer. this is the hyperlink i have setup now (answeb field contains the name of the .htm page):
<a href="#" onclick="javascript:window.open('<%= answeb %>', 'newwin', 'width=800, height=400, scrollbars=yes, resizable=yes, left=112, top=184')"><font color="#003366"><%= ques %></font></a>
it works, but im thinking there's any easier way, possibly incorporating another ASP page which would select that particular question, and display it and the answer. the only thing i can't figure out is how to pass some type of variable (like DATE) through the hyperlink so that the ASP only pulls the particular FAQ with that date out of the DB.
any ideas?
thanks in advance.
strSQL = strSQL & "SELECT * FROM FAQ ORDER BY FAQ.[DATE]DESC, FAQ.[QUESTION]"
i want to hyperlink these questions, so that when clicked, the question and it's answer will be in a popup box. right now, i just have the link setup as a .htm file, in which i have to manually code the question and answer. this is the hyperlink i have setup now (answeb field contains the name of the .htm page):
<a href="#" onclick="javascript:window.open('<%= answeb %>', 'newwin', 'width=800, height=400, scrollbars=yes, resizable=yes, left=112, top=184')"><font color="#003366"><%= ques %></font></a>
it works, but im thinking there's any easier way, possibly incorporating another ASP page which would select that particular question, and display it and the answer. the only thing i can't figure out is how to pass some type of variable (like DATE) through the hyperlink so that the ASP only pulls the particular FAQ with that date out of the DB.
any ideas?
thanks in advance.