473,387 Members | 1,512 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Smart Navigation problem with Javascript

I have a Javascript menu bar on top of each of my aspx pages. The menu bar
would not display when I turn on SmartNavigation. I did some search on this
newsgroup and found the answer to my problem in this post
http://groups.google.com/groups?hl=e...%40tkmsftngp05

Apparently Smart Navigation does not work with Document.Write on the same
page and I use Document.Write to generate the menu bar. Does anyone have any
simple work around? Many thanks in advance!
Nov 18 '05 #1
1 1404
Let's assume that you are correct with Document.Write. Here's another
approach to inserting HTML.

Within javascript, write your new HTML into a string. Then assign it to the
innerHtml property of a <span> or <div> tag that you placed at the location
of where the HTML should go.

var vScript = "html";
var vSpan = document.all['ClientIDtoSpanTag'];
vSpan.innerHtml = vScript;

NOTE: Not all browsers support the innerHtml tag. IE for the Mac is buggy
when you set that value. Since SmartNavigation only works for IE/Windows, I
recommend using your original technique on all other browsers that you
support.

--- Peter Blum
www.PeterBlum.com
Email: PL****@PeterBlum.com
Creator of "Professional Validation And More" at
http://www.peterblum.com/vam/home.aspx

"Ying Huang-Isella" <yi**@sohar.com> wrote in message
news:xM********************@mpowercom.net...
I have a Javascript menu bar on top of each of my aspx pages. The menu bar
would not display when I turn on SmartNavigation. I did some search on this newsgroup and found the answer to my problem in this post
http://groups.google.com/groups?hl=e...%40tkmsftngp05
Apparently Smart Navigation does not work with Document.Write on the same
page and I use Document.Write to generate the menu bar. Does anyone have any simple work around? Many thanks in advance!

Nov 18 '05 #2

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

Similar topics

6
by: anon | last post by:
How *EXACTLY* does Smart Navigation work? (I would really really really like for this Smart Navigation to work in Mozilla.) The inner workings and the code is what I am looking for. Does it...
2
by: Benny | last post by:
Hello Experts, Currently I am writing a web application using vs.net 2002 with c#. In a customer info page of the application, i have set the smart navigation to true, so the application can...
0
by: Jason Rodman | last post by:
I have been working on a web app that uses IFrames for our edit screens. A main window contains static information, while an IFrame contains the editable page. I use javascript from the outer page...
2
by: Jay | last post by:
I have used Smart Navigation on several projects and it works wonderfully. For my last project I used some javascript menus. SmartNavigation caused them to not function. So I used SmartScoller...
1
by: Andy Pickering | last post by:
I'm having a major problem with smart navigation. My page uses the javascript 'setTimeout' function to automatically refresh the page after n seconds (it calls __doPostBack). When I turn on smart...
10
by: RodBillett | last post by:
Using SmartNavigation. Windows2003 Server Framework 1.0 (3705) IIS6 and I have IIS configured to utilize the 1.0 framework. Any Ideas why I would be getting the following jscript error within...
1
by: Priya | last post by:
I have enabled smart navigation for my ASP.Net web application. It works fine except for some of my pages where I'm using some Javascript code to open a page in a new window on a button click....
3
by: Devin | last post by:
I am having a problem of SmartNavigation, wher eit works fine on the test server, but not on the server that I load it up to. I tried placing "page.smartnavigation=false" right before I redirect, but...
3
by: roger31 | last post by:
My problem is to provide Customized smart navigation for any page in my website. I plan to divide my pages into sections and when I navigate from one page to another I would like any section within...
3
by: ajfish | last post by:
Hi, I have a web form with smart navigation turned on. the html has an onload event which calls a javascript function and the contents of this function are dynamically generated on the server...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
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,...
0
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...
0
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,...
0
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...

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.