Hi all,
I've got two questions for you guys so I hope you can help me:
Firstly, I have written some nice simple ASP code that just reads from a database. For example, it just uses the query:
SELECT * FROM Jokes and this displays the joke title and put the link in which when clicked reads the correct joke from the database (usually!). Well I was wondering how I could set it up so that it limits the amount of jokes shown per page to, say 10, then displays a link which will the reload the page with the next 10. It's probably pretty straightforward but I haven't got it sorted yet.
Secondly, I did a site for a friend recently, where I just used the <!-- #INCLUDE FILE="top.asp" --> then the contents of the page then the bottom.asp include. This all worked fine on my server, so I sent it to him, he uploaded it to his server and it act kinda strange. If using a fast connection (cable or faster) it doesn't display all of the page and some images are missing, or it gives a 404 file not found until the page is refreshed. It works fine if you use a dial-up connection to view it though. Very strange, it seems like its sending out a page before it's been properly processed. The server people said the problem was that there might be a loop in the code, because, of course, it wouldn't be a problem at their end. Changing the files that are included made no difference.
Well I got round it with SSI instead, but just wondered what was going on with it. I'm more keen for an answer to the first question, but any help you could offer on either or both would be greatly appreciated!
Thanks!
I've got two questions for you guys so I hope you can help me:
Firstly, I have written some nice simple ASP code that just reads from a database. For example, it just uses the query:
SELECT * FROM Jokes and this displays the joke title and put the link in which when clicked reads the correct joke from the database (usually!). Well I was wondering how I could set it up so that it limits the amount of jokes shown per page to, say 10, then displays a link which will the reload the page with the next 10. It's probably pretty straightforward but I haven't got it sorted yet.
Secondly, I did a site for a friend recently, where I just used the <!-- #INCLUDE FILE="top.asp" --> then the contents of the page then the bottom.asp include. This all worked fine on my server, so I sent it to him, he uploaded it to his server and it act kinda strange. If using a fast connection (cable or faster) it doesn't display all of the page and some images are missing, or it gives a 404 file not found until the page is refreshed. It works fine if you use a dial-up connection to view it though. Very strange, it seems like its sending out a page before it's been properly processed. The server people said the problem was that there might be a loop in the code, because, of course, it wouldn't be a problem at their end. Changing the files that are included made no difference.
Well I got round it with SSI instead, but just wondered what was going on with it. I'm more keen for an answer to the first question, but any help you could offer on either or both would be greatly appreciated!
Thanks!