PDA

View Full Version : Include with DB Call


Yarrokon
03-17-2009, 11:21 PM
Hello,

Have a Menu include that is now being dynamically built via DB, so I am assuming my include will no longer work, and I have to drop the use of the Nav Include and drop the code directly into the page instead of the include.

Someone smack me if I am wrong...

:eek:

Old Pedant
03-18-2009, 02:02 AM
Depends.

HOW are you building the menu?? As a file? As generated HTML, on the spot? When?

HOW are you including it???

Are you aware of SERVER.EXECUTE? (Not that I'm a big fan of it...it's a performance hog...but as we noted, your site surely isn't all the busy.)

Yarrokon
03-18-2009, 07:29 AM
The include contains a sql statment to build the menu so there is vbscript, sql and html in the document that is a include.asp file and calling the include is via the file method.

I've used SERVER.EXECUTE before, but have run into timing issues and have tried to stay away from it as much as possible. Yes it can be a resource hog when used incorrectly. :D

The link I gave you before would have two includes, the TOP menu and the menu on the right for the Resource Area. I don't see why I'm having a problem, I believe I've done this before in the past but it keeps failing to build the menu with 0 errors and when I load the page on it's own, it builds just fine.

Go figure!

Yarrokon
03-18-2009, 11:50 AM
This is strange... 4 includes deep was another include to the same connection string I was using, however it did not display ANY error. When I loaded the 4th include I could see the error.

Wee!

:eek: