473,770 Members | 1,902 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to use same menu html code on each page

KB
My fellow virtual friends, allow me to ask for your collaboration with this
simple yet not-so-trivial matter,

My application has a menu which is defined and stored in a database. This
menu will be part of any page. Currently I implemented it as a user control
which gets the menu from the database and then converts it into the html
code, which is then displayed in each page. For some reason I have a feeling
that it's not very smart to read the same data when each page loads. So I'm
thinking what would be the best way to preserve my menu over the entire
application life. The options that I have right now to implement it are 1)
storing the menu html in the Application or Session state object, and 2)
using frames.

Are there any other ways to implement this?

Your help is greatly appreciated
Nov 18 '05 #1
1 1404
the DB read should be quick enough to not really be an issue. Storing it in
the Session may be an issue as you'll end up, in theory, with the SAME menu
stored in memory for EVERY "active" user.....eek. Application may be better
in this case but I think you will find that going to the DB is going to be
fast enough, and efficient enough, to not really be an issue.

--
Curt Christianson
Owner/Lead Developer, DF-Software
Site: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"KB" <a@b.com> wrote in message
news:%2******** ********@TK2MSF TNGP11.phx.gbl. ..
My fellow virtual friends, allow me to ask for your collaboration with this simple yet not-so-trivial matter,

My application has a menu which is defined and stored in a database. This
menu will be part of any page. Currently I implemented it as a user control which gets the menu from the database and then converts it into the html
code, which is then displayed in each page. For some reason I have a feeling that it's not very smart to read the same data when each page loads. So I'm thinking what would be the best way to preserve my menu over the entire
application life. The options that I have right now to implement it are 1)
storing the menu html in the Application or Session state object, and 2)
using frames.

Are there any other ways to implement this?

Your help is greatly appreciated

Nov 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2217
by: Bizt | last post by:
Hi, I would like to create a menu where the menu options were taken from an XML file. The reason is that I would be able to update the xml file (by simply adding new child nodes) after I uploaded new web pages. Each page would run the same PHP script to create the menu. As the xml file would supply every page, this would mean less time taken up when adding new pages. Below is an example of the xml file content:
1
2501
by: Macamba | last post by:
Hi all, I am currently developing a website for a voluntary organisation. It is my first step in website development. The dynamic menu I developed has some bugs, which I addressed in another post. In this post I want to ask you why my code behaves differently in IE, while it behaves like I expect in Mozilla and Opera. What I would like to see addressed is what I need to do to get the same behaviour in all 3 browsers. I know each browser...
10
2034
by: John Ortt | last post by:
Hi Everyone, I have created a Javascript menu for my site which uses frames. The first stage loads fine but I want two drill down menus ("About Me Menu" and "Projects Menu"). The pages load fine, but the images aren't displayed, instead the alt text is shown. The images come up after you "Mouse Over" them but not before......can anybody spot any errors in my code which could be doing this please. For info, I have 4 images for each...
5
1593
by: michael | last post by:
How may the following script be modified to function with the list structure below it? In short: it is meant to apply a background style to groups of LI's and ULs depeding on the URL filename. <style> ..high {background-color: #99FFCC;} ..low {background-color: #33CC00;} </style>
6
3237
by: Sandy | last post by:
Hello - I have a book that illustrates pulling menu items from a Sql Server table into an ascx via a stored procedure. Is this something that is done in the real world? I do like the effect when viewing it in the source code, however, because it doesn't show the complete path to the file. (I'm talking about Internet Explorer click View, click source code.)
6
1952
by: dpomt | last post by:
I have a quite strange problem with the Menu control. I have ten languages and each language has a SiteMapDataSource and a Menu. For better performance, I am creating a hashtable (language -> (Menu, SitemapDataSource)) and holding this hashtable in the Cache object. On each page request, I am inserting the menu corresponding to the specified language to page. Hence, DataBinding is only done once per each language (when inserting the Menu...
0
1527
by: nonsensitor | last post by:
I would like to provide a scalable horizontal menu. Here's the twist: I want to keep the menu items on a single line for as many 'upscales' as possible. So I basically need 2 solutions: 1) For large-scale viewing, each <li><a> menu item should ideally be "shrinkwrapped". A marginally acceptable alternative would be an em-based standard width that applies to all menu items. 2) For normal viewing, all <li><a> menu items should be a standard...
3
2210
by: =?ISO-8859-1?Q?Jo=E3o_Maia?= | last post by:
Hi there, I am having a weird problem in trying to use a ASP.NET menu inside a custom web part. I am developing a custom web part that has a menu inside (just the menu, nothing else). The menu is a System.Web.UI.WebControls.Menu (ASP.NET 2.0) object. If I add the menu to a simple ASPX web form, it works nice. However, I am adding it to my web part, by overriding the RenderWebPart method and doing something like:
4
2377
by: N00b13 | last post by:
I have a great JS menu but I have to update every page each time I want to change a link. Is there a way to store my links in a file and call it so i only change that file? (what I have tried so far has not worked, but then again my JS really never works :) ) my .js: if (typeof Scl == "undefined") { var Scl = {}; } (function()
0
9617
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9453
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10254
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10099
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10036
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9904
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
6710
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4007
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2849
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.