Just make a link called 'Printer Friendly' on your page that causes a
popup ... and have the news articles ID wrte into the link like so ...
<a href="#"
onClick="MyWindow=window.open('/yourPrinterFriendlyPage.asp?newsID=<%
=theNewsID
%>','MyWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=600,height=500,left=50,top=50');
return false;">Printer Friendly</a>
Then have a page called yourPrinterFriendlyPage.asp ...
((you can get my DBConn.asp file at the following link))
http://www.coolpier.com/cp/cp_scripts/index.asp
<!-- #include virtual="/coolpier_scripts/_database_tools/DBConn.asp"
-->
<html><body>
<table width="100%" cellpadding="4" cellspacing="0" align="center"
valign="top">
<tr><td align="center" valign="top">
<img src="/images/logo.jpg">
</td></tr><tr><td align="left" valign="top">
<%
Dim newsArticleArray '// will be a single dimensionsal array with only
one value.
Dim yourSQL '// your sql statement to your article
yourSQL = "select theStory from newsArticles where theID = '" &
Request.QueryString("theNewsID") & "';"
cp_TheConnectionString = "yourConnectionString;"
cp_DBConn("open")
newsArticleArray = cp_SqlArray(yourSQL)
cp_DBConn("close")
IF ISArray(newsArticleArray) THEN
'//Story found
Response.Write newsArticleArray(0)
ELSE
'// Story Not Found
Response.Write "Story Not Found ... contact webmaster with the error."
END IF
%>
</td></tr></table>
</body></html>
Now this is about as good of an answer here as it gets ... lol.
Do you know much about ASP ... of are you a designer that doesn't know
too much about programming. I have PLENTY of friends that are
designers (which I suck at) that trade me graphics for programming all
the time ... hehe.
If you need help further, I may be able to help, but it would have to
be off the group.
Take Care,
Brynn
www.coolpier.com
Its Exactly like the site I should you
http://www.gulf-daily-news.com
Yes I am using MS Access and I store all my news in MS ACCESS DB
SO can you tell me how can I print friendly
with only my Defines logo above the news
please see the above website for a good example
thanks
I participate in the group to help give examples of code. I do not guarantee the effects of any code posted. Test all code before use!
Brynn
www.coolpier.com