473,699 Members | 2,417 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

unable to laod particular division when window is loading.

5 New Member
Below is my code.i want the first division should be load when window is loading.

Expand|Select|Wrap|Line Numbers
  1. <HTML>
  2. <HEAD>
  3. <script>
  4. function tabFunc(getthis)
  5. {
  6.     var getIn=getthis.innerHTML;
  7.     var getId=getIn+'_content';
  8.     var divId=document.getElementById('content');
  9.     var divlen=divId.getElementsByTagName('div');
  10.  
  11.     for (var i=0;i<divlen.length;i++ )
  12.     {
  13.         if(divlen[i].id != getId)
  14.         {
  15.             divlen[i].style.display='none';
  16.         }
  17.         else
  18.         {
  19.             divlen[i].style.display='block';
  20.         }
  21.     }
  22.  
  23.     var par=getthis.parentNode;
  24.     var mm=par.getElementsByTagName('td');
  25.     for(var i=0;i<mm.length-1;i++)
  26.     {
  27.         if(mm[i]==getthis)
  28.         {
  29.             mm[i].className='click';
  30.  
  31.         }
  32.         else
  33.         {
  34.  
  35.             mm[i].className='Normal';
  36.         }
  37.     }
  38. }
  39. </script>
  40. <style>
  41. .Normal {background-color:#FF0000;cursor:pointer;}
  42. .click {background-color:#FFFFFF;cursor:pointer;}
  43. td{
  44.     border:none;
  45.     font-family:verdana,arial;
  46.     font-size:12px;
  47.     }
  48. table{
  49.     border:none;
  50.     }
  51. </style>
  52.  </HEAD>
  53.  
  54.  <BODY>
  55.   <table border="0" background="back.gif" height="100%" width="100%">
  56.     <tr>
  57.         <td>
  58.             <table cellspacing="0" cellpadding="0" width="100%" border="2" height="100%">
  59.                 <tr height="23px">
  60.                     <td class="Normal" onclick="tabFunc(this);" style="width:50px; background-position:right; padding-left:20px;padding-right:20px;border-left:1px solid #000000;">Home</td>
  61.                     <td class="Normal" onclick="tabFunc(this);" style="width:50px;background-position:right; padding-left:20px;padding-right:20px;border-left:1px solid #000000;" >Operation</td>
  62.                     <td class="Normal" onclick="tabFunc(this);" style="width:50px;background-position:right; padding-left:20px;padding-right:20px;border-left:1px solid #000000;" >Administration</td>
  63.                     <td width="100%" style="border-bottom:1px solid #000000;">&nbsp;</td>
  64.                 </tr>
  65.                 <tr>
  66.                     <td colspan="4" id="content" style="height:100%;width:100%;border-top:0px;border-left:1px solid #000000;border-bottom:1px solid #000000;border-right:1px solid #000000;">
  67.                         <div id="Home_content" style="display:none;height:100%;width:100%;border:0px solid #000000;">Home_contentet</div>
  68.                         <div id="Operation_content" style="display:none;height:100%;width:100%;border:0px solid #000000;">Operation_contentet</div>
  69.                         <div id="Administration_content" style="display:none;height:100%;width:100%;border:0px solid #000000;">Administration_content</div>
  70.                     </td>
  71.                 </tr>
  72.             </table>
  73.         </td>
  74.     </tr>
  75.   </table>
  76.  </BODY>
  77. </HTML>
  78.  
in the above code i want the Home_Content should be default loaded when i running the script.please help me.
Sep 20 '08 #1
1 1746
risk32
98 New Member
Try giving your Home DIV an id, then use your tab function to call the id instead of (this). It might work, it might not. Just giving an idea that sounds right.
Nov 5 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
2055
by: Rob Tweed | last post by:
I have a customer who is having problems when their Windows 2000/IIS/PHP-based system begins to experience a level of loading that isn't, in my view, unreasonably high. I'm wondering what others think, specifically: - are these volumes, for this kind of configuration, at or beyond the levels at which PHP should be able to cope? I hope not ! - what might be done to alleviate these problems? One of our suspicions is that Windows...
10
3074
by: soup_or_power | last post by:
The pop up window has several checkboxes. I'm unable to access the checkboxes using the handle from window.open. Any way to do this? var display; function showSugg(but_id, sugg1, sugg2, sugg3, sugg4, sugg5) { display=window.open('','_blank','menubar=0,location=no,status=no,directories=no,toolbar=no,scrollbars=yes,height=150,width=190')
0
1359
by: Satish | last post by:
Dear all, Iam unable to laod images at runtime from the file folder / database through C# code with asp. net and Crystal reports All the solutions given are through RDC COM Component.. but no information is available for CR for VS.net this is with File server based image loading using OLE object. Thanks in advance. -satish
53
8391
by: souporpower | last post by:
Hello All I am trying to activate a link using Jquery. Here is my code; <html> <head> <script type="text/javascript" src="../../resources/js/ jquery-1.2.6.js"</script> <script language="javascript" type="text/javascript">
0
8685
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
8613
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
9172
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
9032
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
8908
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
7745
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4374
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
3054
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
2008
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.