Expanding text java script

I got a java script from a coworker that allows me to click
on a button and display expanded text. The problem is, when its
clicked, the page jumps back to the top of the page. Any ideas?
Here is a sample of the code:
<a href="#"
onclick="document.getElementById('what_is').style.display=(document.getElementById('what_ is').style.display=='block')?'none':'block';"><img
src="Images/More.jpg" border="0" align="left" />
Thanks!!!!
PS- please be gentle, I have never used java script before.
:)

nst_21710 wrote:
> I got a java script from a coworker that allows me to
click on a button and
> display expanded text. The problem is, when its clicked,
the page jumps back to
> the top of the page. Any ideas?
>
> Here is a sample of the code:
> <a href="#"
>
onclick="document.getElementById('what_is').style.display=(document.getElementBy
>
Id('what_is').style.display=='block')?'none':'block';"><img
> src="Images/More.jpg" border="0" align="left" />
>
> Thanks!!!!
>
> PS- please be gentle, I have never used java script
before. :)
>
replace:
<a href="#"
with:
<a href="javascript:;"
seb ( [email protected])
http://webtrans1.com | high-end web
design
Downloads: Slide Show, Directory Browser, Mailing List

Similar Messages

  • Expand Collapse Feature in OBIEE 10.1.3.4 version using Java script Issue

    Hi All,
    Tried to implement this script in OBIEE 10.1.3.4, but throughs error. Can any one help me in this regards
    Steps followed
    1. Create an answers report pulling Top Relations, Sub Relationship and Customer from the dimension and sales amount from the Sales fact
    2. For Sub Relationship and Customer give the left padding as 25.
    3. Create a pivot table view make Top Relationship, Sub Relationship hidden and select show the total before and select labels only (no totals) in the pivot table.
    4.Add the image files in and the following code for Top Relationship, Sub Relationship columns select the data format to as HTML image and change it to custom text and add the following.
    @[html]<img onclick="ExpandCollapse(this)" src="res/s_oracle10/images/PropertyGroup_minus.gif">@H
    5. Add a narrative view and add the following java script.
    // Java Script
    function ExpandCollapse( el )
         // Grab the ROW that was clicked and the TABLE that contains it
         var tr = el.parentElement.parentElement;
         var tbl = tr.parentElement.parentElement;
         // Set the alternating display values for hiding/showing the row
         var sDisplay = ( el.src.indexOf( "minus" ) == -1 ) ? "" : "none";
         var sDisplayReverse = ( el.src.indexOf( "minus" ) == -1 ) ? "none" : "";
         //Switch the icon for the clicked row
         el.src = "C:/Manohar/HTMLTest/PropertyGroup_" + ( el.src.indexOf( "minus" ) == -1 ? "minus" : "plus" ) + ".gif";
         // Starting with the row below the clicked row, start checking each row
         for ( var i = tr.rowIndex + 1; i < tbl.rows.length; i++ )
              // Set the Current row indicator nad the left padding value
              var trCurrent = tbl.rows( i );
              var trCurrentLeft = trCurrent.cells(0).style.paddingLeft;
              // if the current row contains an IMG in it, it's a clickable level and we either have to stop processing,
              // or reset the icons to a + as it's being collapsed
              if ( trCurrent.cells( 0 ).firstChild && trCurrent.cells( 0 ).getElementsByTagName( "IMG" ).length )
                   // If the current row is at the same level or above in the tree, then stop processing,
                   // else reset all the signs below it, essentially collapsing all branches underneath the one that is beig collapsed.
                   if ( stripTrailing(trCurrentLeft , UOM_SIZE) <= stripTrailing(tr.cells(0).style.paddingLeft , UOM_SIZE) )
                   { break; }
                   else
                        if (el.src.indexOf( "minus" ) == -1 )
                             trCurrent.cells(0).getElementsByTagName("IMG").item(0).src = "C:/Manohar/HTMLTest/PropertyGroup_plus.gif";
              // Now, we determine if the row should be hidden or shown.
              if ( eval(stripTrailing(tr.cells(0).style.paddingLeft, UOM_SIZE)+ INDENT_SIZE) < stripTrailing(trCurrentLeft, UOM_SIZE) && el.src.indexOf( "minus" ) >0 )
                   trCurrent.style.display = sDisplayReverse;
              } else
                   trCurrent.style.display = sDisplay;
    Thanks,
    Kumaravel
    Edited by: 840515 on Feb 28, 2011 10:00 PM

    Since the SP is on connection pool (and looks like expecting a input value), that may causing for error.
    Column in the report, pass PS variable and hide it if it not required in the report.
    Pls mark if helps

  • Need to compare html text area values by using java script

    I have one html text area in my JSP file. when i click on that text area, a pop-up will come, in that pop-up i have list of items. So after selecting a item from that pop-up list, need to click okay. so that text area will update with the selected value.
    In this case, i need to compare the first text area value and updated text area value. How can i do that in Java Script.

    I suggest you look for a Javascript forum to ask questions about Javascript. This is a Java forum.

  • Read Text file using Java Script

    Hi,
    I am trying to read a text file using Java Script within the webroot of MII as .HTML file. I have provided the path as below but where I am not able to open the file. Any clue to provide the relative path or any changes required on the below path ?
    var FileOpener = new ActiveXObject("Scripting.FileSystemObject");
    var FilePointer = FileOpener.OpenTextFile("E:\\usr\\sap\\MID\\J00\\j2ee\\cluster\\apps\\sap.com\\xapps~xmii~ear\\servlet_jsp\\XMII\\root\\CM\\OCTAL\\TestTV\\Test.txt", 1, true);
    FileContents = FilePointer.ReadAll(); // we can use FilePointer.ReadAll() to read all the lines
    The Error Log shows as :
    Path not found
    Regards,
    Mohamed

    Hi Mohamed,
    I tried above code after importing JQuery Library through script Tag. It worked for me . Pls check.
    Note : You can place Jquery1.xx.xx.js file in the same folder where you saved this IRPT/HTML file.
    <HTML>
    <HEAD>
        <TITLE>Your Title Here</TITLE>
        <SCRIPT type="text/javascript" src="jquery-1.9.1.js"></SCRIPT>
        <script language="javascript">
    function Read()
    $.get( "http://ldcimfb.wdf.sap.corp:50100/XMII/CM/Regression_15.0/CrossTab.txt", function( data ) {
      $(".result").html(data);
      alert(data);
    // The file content is available in this variable "data"
    </script>
    </HEAD>
    <BODY onLoad="Read()">
    </BODY>
    </HTML>

  • Creating a text with a java script on fixed position

    Hello i want to know how to create a text with a java script on fixed position
    thanx

    Hi,
    Your next steps are hidden here:
    http://www.jongware.com/idjshelp.html
    Object you created (textFrame, page, text) have properties to set or methods to execute.
    You could find them all inside above Jongware's Kingdom of Knowledge.
    In example:
    to set your text size use:
    myTextFrame.texts[0].pointSize = 12;
    Jarek

  • How to write Java script for refering the 1st page text field from 2nd page?

    Hello I am developing an VISITOR info interactive form with webdynpro ABAP, its with 2 pages. Their heirarchy is,
    VISITOR_form
        |
        |
        |------Page_1
        |            |
        |            |
        |            |------Text_Field_A_1
        |            |
        |            |------Text_Field_A_2
        |
        |------Page_2
                     |
                     |
                     |------Text_Field_B_1
                     |
                     |------Text_Field_B_2
    Now, i have selected the 'Text_Field_B_1' of page_2 and writing the Java script, my requirement is; If Page_1's 'Text_Field_A_2' has a value of "Value_ABCD", THEN the 'Text_Field_B_1' of page_2 should be 'readOnly'. Pls let me know Wht is the Java script for this requirement?

    if (xfa.event.newText=="ABCD")
    VISITOR_form.Page_2.Text_FieldB_1.access ="readOnly";
    place script on change event of Text_FieldA_2

  • How to use java script in jsf?

    my requirement is
    i have to pass the id of the component to the java script function .that component is inside data table.
    how to solve this problem?

    following code is the generated html code.
    see it is generating duplicate ids : check it
    this is the id repeating 3 times "helper:table1:table14:0:command5"
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <HTML>
    <script>
    function showHideNavigation(item) {
    var temp = document.getElementById("plexIndex");
    taskImg = document.getElementById(item.id.substring(0, item.id.lastIndexOf(':')) + ':image'+item.id.substring(item.id.length-1));
    taskDiv = document.getElementById(item.id.substring(0, item.id.lastIndexOf(':')) + ':child_div'+item.id.substring(item.id.length-1));
              if (taskDiv.style.display == "block" ) {
                   taskDiv.rendered = "true";
                   taskDiv.style.display = "none";
    taskImg.src = "../images/arrow_collapsed.gif";
    } else {
                   taskDiv.style.display = "block";
                   taskDiv.rendered = "false";
         taskImg.src = "../images/arrow_expanded.gif";
    </script>
    <head>
    </head>
         <form id="helper" method="post" action="/datatabledemo-app/pages/WLMHome.faces" enctype="application/x-www-form-urlencoded">
         <div id="helper:div0" style="margin-left:0.3em;">
                        <a id="helper:command0" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:image0" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />plexes</a>
         </div>
         <div id="helper:child_div0" style="display : none">
         <table id="helper:table1" width="100%">
    <tbody>
    <tr>
    <td><span id="plexIndex" title="helper:table1:0:column1"></span><div id="helper:table1:0:div2" style="margin-left:0.9em;"><a id="helper:table1:0:command1" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:0:image1" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:0:t1">plex1</span></a></div><div id="helper:table1:0:child_div1" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><div id="helper:table1:0:div4" style="margin-left:2.1em;"><a id="helper:table1:0:command2" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:0:image2" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />attributes</a></div><div id="helper:table1:0:child_div2" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table12" width="100%">
    <thead>
    <tr>
    <th scope="col"><span id="helper:table1:table12:text2" style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">session_scale_1</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">session_scale_2</span></td>
    <td><span style="margin-left:3.0em;">2.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_scale_2</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_limit</span></td>
    <td><span style="margin-left:3.0em;">600.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">connection_scale</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_limit_1</span></td>
    <td><span style="margin-left:3.0em;">5</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_limit_2</span></td>
    <td><span style="margin-left:3.0em;">10</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_adjustment</span></td>
    <td><span style="margin-left:3.0em;">0.10</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_scale_2</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_adjustment</span></td>
    <td><span style="margin-left:3.0em;">0.05</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_scale_2</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">normalise_scale</span></td>
    <td><span style="margin-left:3.0em;">0.00833</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">equal_delta</span></td>
    <td><span style="margin-left:3.0em;">0.0001</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_2</span></td>
    <td><span style="margin-left:3.0em;">10.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_3</span></td>
    <td><span style="margin-left:3.0em;">100.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_4</span></td>
    <td><span style="margin-left:3.0em;">1000.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_5</span></td>
    <td><span style="margin-left:3.0em;">10000.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_timeout</span></td>
    <td><span style="margin-left:3.0em;">120.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">score_limit</span></td>
    <td><span style="margin-left:3.0em;">5000.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">retry_limit</span></td>
    <td><span style="margin-left:3.0em;">2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">reselection_limit</span></td>
    <td><span style="margin-left:3.0em;">2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_resend_timeout</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_retry_timeout</span></td>
    <td><span style="margin-left:3.0em;">10.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_retry_limit_1</span></td>
    <td><span style="margin-left:3.0em;">5</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_retry_limit_2</span></td>
    <td><span style="margin-left:3.0em;">1</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_fail_timeout</span></td>
    <td><span style="margin-left:3.0em;">600.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">autoinstall_load</span></td>
    <td><span style="margin-left:3.0em;">3.0</span></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:0:div6" style="margin-left:2.1em;"><a id="helper:table1:0:command3" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:0:image3" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />groups</a></div><div id="helper:table1:0:child_div3" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table13" width="100%">
    <thead>
    <tr><th colspan="1" scope="colgroup">Group Value</th></tr>
    </thead>
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">type1</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">type2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">type3</span></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:0:div8" style="margin-left:2.1em;"><a id="helper:table1:0:command4" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:0:image4" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />programs</a></div><div id="helper:table1:0:child_div4" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14" width="100%">
    <tbody>
    <tr>
    <td><div id="helper:table1:table14:0:div10" style="margin-left:2.7em;"><a id="helper:table1:table14:0:command5" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><span id="program" title="helper:table1:table14:0:command5"></span><img id="helper:table1:table14:0:image5" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:table14:0:t2">called1</span></a></div><div id="helper:table1:table14:0:child_div5" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14:table141" width="100%">
    <thead>
    <tr>
    <th scope="col"><span style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:0:coloumn41"></span><span style="margin-left:3.0em;">load</span></td>
    <td><span style="margin-left:3.0em;">0.25</span></td>
    </tr>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:1:coloumn41"></span><span style="margin-left:3.0em;">dynamic</span></td>
    <td><span style="margin-left:3.0em;">yes</span></td>
    </tr>
    </tbody>
    </table>
    </div></td>
    </tr>
    <tr>
    <td><div id="helper:table1:table14:1:div10" style="margin-left:2.7em;"><a id="helper:table1:table14:1:command5" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><span id="program" title="helper:table1:table14:1:command5"></span><img id="helper:table1:table14:1:image5" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:table14:1:t2">called2</span></a></div><div id="helper:table1:table14:1:child_div5" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14:table141" width="100%">
    <thead>
    <tr>
    <th scope="col"><span style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:0:coloumn41"></span><span style="margin-left:3.0em;">load</span></td>
    <td><span style="margin-left:3.0em;">0.25</span></td>
    </tr>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:1:coloumn41"></span><span style="margin-left:3.0em;">dynamic</span></td>
    <td><span style="margin-left:3.0em;">yes</span></td>
    </tr>
    </tbody>
    </table>
    </div></td>
    </tr>
    <tr>
    <td><div id="helper:table1:table14:2:div10" style="margin-left:2.7em;"><a id="helper:table1:table14:2:command5" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><span id="program" title="helper:table1:table14:2:command5"></span><img id="helper:table1:table14:2:image5" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:table14:2:t2">called3</span></a></div><div id="helper:table1:table14:2:child_div5" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14:table141" width="100%">
    <thead>
    <tr>
    <th scope="col"><span style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:0:coloumn41"></span><span style="margin-left:3.0em;">load</span></td>
    <td><span style="margin-left:3.0em;">0.25</span></td>
    </tr>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:1:coloumn41"></span><span style="margin-left:3.0em;">dynamic</span></td>
    <td><span style="margin-left:3.0em;">yes</span></td>
    </tr>
    </tbody>
    </table>
    </div></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:0:div12" style="margin-left:2.1em;"><a id="helper:table1:0:command6" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:0:image6" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />transactions</a></div><div id="helper:table1:0:child_div6" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table15" width="100%">
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">TRN1</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">TRN2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">TRN3</span></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:0:div14" style="margin-left:2.1em;"><a id="helper:table1:0:command7" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:0:image7" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />nodes</a></div><div id="helper:table1:0:child_div7" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table151" width="100%">
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">argon.in.ibm.com</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">alina.in.ibm.com</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">ampere.in.ibm.com</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">txdt32.in.ibm.com</span></td>
    </tr>
    </tbody>
    </table>
    </div></div></td>
    </tr>
    <tr>
    <td><span id="plexIndex" title="helper:table1:1:column1"></span><div id="helper:table1:1:div2" style="margin-left:0.9em;"><a id="helper:table1:1:command1" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:1:image1" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:1:t1">plex2</span></a></div><div id="helper:table1:1:child_div1" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><div id="helper:table1:1:div4" style="margin-left:2.1em;"><a id="helper:table1:1:command2" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:1:image2" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />attributes</a></div><div id="helper:table1:1:child_div2" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table12" width="100%">
    <thead>
    <tr>
    <th scope="col"><span id="helper:table1:table12:text2" style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">session_scale_1</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">session_scale_2</span></td>
    <td><span style="margin-left:3.0em;">2.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_scale_2</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_limit</span></td>
    <td><span style="margin-left:3.0em;">600.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">connection_scale</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_limit_1</span></td>
    <td><span style="margin-left:3.0em;">5</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_limit_2</span></td>
    <td><span style="margin-left:3.0em;">10</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_adjustment</span></td>
    <td><span style="margin-left:3.0em;">0.10</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_scale_2</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_adjustment</span></td>
    <td><span style="margin-left:3.0em;">0.05</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_scale_2</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">normalise_scale</span></td>
    <td><span style="margin-left:3.0em;">0.00833</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">equal_delta</span></td>
    <td><span style="margin-left:3.0em;">0.0001</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_2</span></td>
    <td><span style="margin-left:3.0em;">10.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_3</span></td>
    <td><span style="margin-left:3.0em;">100.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_4</span></td>
    <td><span style="margin-left:3.0em;">1000.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_adjustment_5</span></td>
    <td><span style="margin-left:3.0em;">10000.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">health_timeout</span></td>
    <td><span style="margin-left:3.0em;">120.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">score_limit</span></td>
    <td><span style="margin-left:3.0em;">5000.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">retry_limit</span></td>
    <td><span style="margin-left:3.0em;">2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">reselection_limit</span></td>
    <td><span style="margin-left:3.0em;">2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_resend_timeout</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_retry_timeout</span></td>
    <td><span style="margin-left:3.0em;">10.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_retry_limit_1</span></td>
    <td><span style="margin-left:3.0em;">5</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_retry_limit_2</span></td>
    <td><span style="margin-left:3.0em;">1</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">wcm_fail_timeout</span></td>
    <td><span style="margin-left:3.0em;">600.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">autoinstall_load</span></td>
    <td><span style="margin-left:3.0em;">3.0</span></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:1:div6" style="margin-left:2.1em;"><a id="helper:table1:1:command3" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:1:image3" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />groups</a></div><div id="helper:table1:1:child_div3" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table13" width="100%">
    <thead>
    <tr><th colspan="1" scope="colgroup">Group Value</th></tr>
    </thead>
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">type1</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">type2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">type3</span></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:1:div8" style="margin-left:2.1em;"><a id="helper:table1:1:command4" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:1:image4" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />programs</a></div><div id="helper:table1:1:child_div4" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14" width="100%">
    <tbody>
    <tr>
    <td><div id="helper:table1:table14:0:div10" style="margin-left:2.7em;"><a id="helper:table1:table14:0:command5" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><span id="program" title="helper:table1:table14:0:command5"></span><img id="helper:table1:table14:0:image5" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:table14:0:t2">called1</span></a></div><div id="helper:table1:table14:0:child_div5" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14:table141" width="100%">
    <thead>
    <tr>
    <th scope="col"><span style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:0:coloumn41"></span><span style="margin-left:3.0em;">load</span></td>
    <td><span style="margin-left:3.0em;">0.25</span></td>
    </tr>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:1:coloumn41"></span><span style="margin-left:3.0em;">dynamic</span></td>
    <td><span style="margin-left:3.0em;">yes</span></td>
    </tr>
    </tbody>
    </table>
    </div></td>
    </tr>
    <tr>
    <td><div id="helper:table1:table14:1:div10" style="margin-left:2.7em;"><a id="helper:table1:table14:1:command5" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><span id="program" title="helper:table1:table14:1:command5"></span><img id="helper:table1:table14:1:image5" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:table14:1:t2">called2</span></a></div><div id="helper:table1:table14:1:child_div5" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14:table141" width="100%">
    <thead>
    <tr>
    <th scope="col"><span style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:0:coloumn41"></span><span style="margin-left:3.0em;">load</span></td>
    <td><span style="margin-left:3.0em;">0.25</span></td>
    </tr>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:1:coloumn41"></span><span style="margin-left:3.0em;">dynamic</span></td>
    <td><span style="margin-left:3.0em;">yes</span></td>
    </tr>
    </tbody>
    </table>
    </div></td>
    </tr>
    <tr>
    <td><div id="helper:table1:table14:2:div10" style="margin-left:2.7em;"><a id="helper:table1:table14:2:command5" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><span id="program" title="helper:table1:table14:2:command5"></span><img id="helper:table1:table14:2:image5" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:table14:2:t2">called3</span></a></div><div id="helper:table1:table14:2:child_div5" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><table id="helper:table1:table14:table141" width="100%">
    <thead>
    <tr>
    <th scope="col"><span style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:0:coloumn41"></span><span style="margin-left:3.0em;">load</span></td>
    <td><span style="margin-left:3.0em;">0.25</span></td>
    </tr>
    <tr>
    <td><span id="program" title="helper:table1:table14:table141:1:coloumn41"></span><span style="margin-left:3.0em;">dynamic</span></td>
    <td><span style="margin-left:3.0em;">yes</span></td>
    </tr>
    </tbody>
    </table>
    </div></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:1:div12" style="margin-left:2.1em;"><a id="helper:table1:1:command6" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:1:image6" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />transactions</a></div><div id="helper:table1:1:child_div6" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table15" width="100%">
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">TRN1</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">TRN2</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">TRN3</span></td>
    </tr>
    </tbody>
    </table>
    </div><div id="helper:table1:1:div14" style="margin-left:2.1em;"><a id="helper:table1:1:command7" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:1:image7" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />nodes</a></div><div id="helper:table1:1:child_div7" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table151" width="100%">
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">argon.in.ibm.com</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">alina.in.ibm.com</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">ampere.in.ibm.com</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">txdt32.in.ibm.com</span></td>
    </tr>
    </tbody>
    </table>
    </div></div></td>
    </tr>
    <tr>
    <td><span id="plexIndex" title="helper:table1:2:column1"></span><div id="helper:table1:2:div2" style="margin-left:0.9em;"><a id="helper:table1:2:command1" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><img id="helper:table1:2:image1" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" /><span id="helper:table1:2:t1">plex3</span></a></div><div id="helper:table1:2:child_div1" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><div id="helper:table1:2:div4" style="margin-left:2.1em;"><a id="helper:table1:2:command2" href="#" onclick="javascript:showHideNavigation(this)" style="color: rgb(0, 0, 0); text-decoration: none; display : block;"><img id="helper:table1:2:image2" src="../images/arrow_collapsed.gif" alt="Expand / Collapse" style="border : 0;" />attributes</a></div><div id="helper:table1:2:child_div2" style="color: rgb(0, 0, 0); text-decoration: none; display : block"><table id="helper:table1:table12" width="100%">
    <thead>
    <tr>
    <th scope="col"><span id="helper:table1:table12:text2" style="margin-left:2.4em;">Attribute Name</span></th>
    <th scope="col"><span style="margin-left:2.1em;">Attribute Value</span></th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td><span style="margin-left:3.0em;">session_scale_1</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">session_scale_2</span></td>
    <td><span style="margin-left:3.0em;">2.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_scale_2</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">load_limit</span></td>
    <td><span style="margin-left:3.0em;">600.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">connection_scale</span></td>
    <td><span style="margin-left:3.0em;">1.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_limit_1</span></td>
    <td><span style="margin-left:3.0em;">5</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_limit_2</span></td>
    <td><span style="margin-left:3.0em;">10</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_adjustment</span></td>
    <td><span style="margin-left:3.0em;">0.10</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">same_scale_2</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_adjustment</span></td>
    <td><span style="margin-left:3.0em;">0.05</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_scale_1</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">known_scale_2</span></td>
    <td><span style="margin-left:3.0em;">0.0</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">normalise_scale</span></td>
    <td><span style="margin-left:3.0em;">0.00833</span></td>
    </tr>
    <tr>
    <td><span style="margin-left:3.0em;">equal_delta</span></td>
    <td><span style="margin-left:3.0em;">0.0

  • Adobe Dreamweaver CS5.5 - Windows 7 - Java Script Problem

    I am having trouble with Anchor.htm.
    When I try to insert an anchor in the text (Insert > Named Anchor> I get this error message:
    "While executing insertObject in Anchor.htm a Java Script error occurred."
    I recently downloaded both the 32- and 64-bit Java Script applications when I received a message that the existing version of Java Script was out-of-date. Anchor.htm worked before I installed the update.
    The files I downloaded and installed are:
    jre-7u9-windows-i586.exe
    jre-7u9-windows-x64.exe
    Please can anyone help me with this problem?

    From Dreamweaver FAQ
    http://forums.adobe.com/thread/429114
    "If Dreamweaver is acting erratically, or if you see a message saying "the following JavaScript error(s) occurred",  it's usually a sign of a corrupt cache file. The first thing to try should always be to delete the file cache. If that doesn't work, delete your personal Configuration folder. Full instructions are in Deleting a corrupted cache file.
    http://forums.adobe.com/thread/494811"
    Nancy O.

  • Why this code is not working??? java script

    gen_validatorv2.js
         JavaScript Form Validator
    Version 2.0.2
         Copyright 2003 JavaScript-coder.com. All rights reserved.
         You use this script in your Web pages, provided these opening credit
    lines are kept intact.
         The Form validation script is distributed free from JavaScript-Coder.com
         You may please add a link to JavaScript-Coder.com,
         making it easy for others to find this script.
         Checkout the Give a link and Get a link page:
         http://www.javascript-coder.com/links/how-to-link.php
    You may not reprint or redistribute this code without permission from
    JavaScript-Coder.com.
         JavaScript Coder
         It precisely codes what you imagine!
         Grab your copy here:
              http://www.javascript-coder.com/
    function Validator(frmname)
    this.formobj=document.forms[frmname];
         if(!this.formobj)
         alert("BUG: couldnot get Form object "+frmname);
              return;
         if(this.formobj.onsubmit)
         this.formobj.old_onsubmit = this.formobj.onsubmit;
         this.formobj.onsubmit=null;
         else
         this.formobj.old_onsubmit = null;
         this.formobj.onsubmit=form_submit_handler;
         this.addValidation = add_validation;
         this.setAddnlValidationFunction=set_addnl_vfunction;
         this.clearAllValidations = clear_all_validations;
    function set_addnl_vfunction(functionname)
    this.formobj.addnlvalidation = functionname;
    function clear_all_validations()
         for(var itr=0;itr < this.formobj.elements.length;itr++)
              this.formobj.elements[itr].validationset = null;
    function form_submit_handler()
         for(var itr=0;itr < this.elements.length;itr++)
              if(this.elements[itr].validationset &&
         !this.elements[itr].validationset.validate())
              return false;
         if(this.addnlvalidation)
         str =" var ret = "+this.addnlvalidation+"()";
         eval(str);
    if(!ret) return ret;
         return true;
    function add_validation(itemname,descriptor,errstr)
    if(!this.formobj)
         alert("BUG: the form object is not set properly");
              return;
         }//if
         var itemobj = this.formobj[itemname];
    if(!itemobj)
         alert("BUG: Couldnot get the input object named: "+itemname);
              return;
         if(!itemobj.validationset)
         itemobj.validationset = new ValidationSet(itemobj);
    itemobj.validationset.add(descriptor,errstr);
    function ValidationDesc(inputitem,desc,error)
    this.desc=desc;
         this.error=error;
         this.itemobj = inputitem;
         this.validate=vdesc_validate;
    function vdesc_validate()
    if(!V2validateData(this.desc,this.itemobj,this.error))
    this.itemobj.focus();
              return false;
    return true;
    function ValidationSet(inputitem)
    this.vSet=new Array();
         this.add= add_validationdesc;
         this.validate= vset_validate;
         this.itemobj = inputitem;
    function add_validationdesc(desc,error)
    this.vSet[this.vSet.length]=
         new ValidationDesc(this.itemobj,desc,error);
    function vset_validate()
    for(var itr=0;itr<this.vSet.length;itr++)
         if(!this.vSet[itr].validate())
              return false;
         return true;
    function validateEmailv2(email)
    // a very simple email validation checking.
    // you can add more complex email checking if it helps
    if(email.length <= 0)
         return true;
    var splitted = email.match("^(.+)@(.+)$");
    if(splitted == null) return false;
    if(splitted[1] != null )
    var regexp_user=/^\"?[\w-_\.]*\"?$/;
    if(splitted[1].match(regexp_user) == null) return false;
    if(splitted[2] != null)
    var regexp_domain=/^[\w-\.]*\.[A-Za-z]{2,4}$/;
    if(splitted[2].match(regexp_domain) == null)
         var regexp_ip =/^\[\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\]$/;
         if(splitted[2].match(regexp_ip) == null) return false;
    }// if
    return true;
    return false;
    function V2validateData(strValidateStr,objValue,strError)
    var epos = strValidateStr.search("=");
    var command = "";
    var cmdvalue = "";
    if(epos >= 0)
    command = strValidateStr.substring(0,epos);
    cmdvalue = strValidateStr.substr(epos+1);
    else
    command = strValidateStr;
    switch(command)
    case "req":
    case "required":
    if(eval(objValue.value.length) == 0)
    if(!strError || strError.length ==0)
    strError = objValue.name + " : Required Field";
    }//if
    alert(strError);
    return false;
    }//if
    break;
    }//case required
    case "maxlength":
    case "maxlen":
    if(eval(objValue.value.length) > eval(cmdvalue))
    if(!strError || strError.length ==0)
    strError = objValue.name + " : "+cmdvalue+" characters maximum ";
    }//if
    alert(strError + "\n[Current length = " + objValue.value.length + " ]");
    return false;
    }//if
    break;
    }//case maxlen
    case "minlength":
    case "minlen":
    if(eval(objValue.value.length) < eval(cmdvalue))
    if(!strError || strError.length ==0)
    strError = objValue.name + " : " + cmdvalue + " characters minimum ";
    }//if
    alert(strError + "\n[Current length = " + objValue.value.length + " ]");
    return false;
    }//if
    break;
    }//case minlen
    case "alnum":
    case "alphanumeric":
    var charpos = objValue.value.search("[^A-Za-z0-9]");
    if(objValue.value.length > 0 && charpos >= 0)
    if(!strError || strError.length ==0)
    strError = objValue.name+": Only alpha-numeric characters allowed ";
    }//if
    alert(strError + "\n [Error character position " + eval(charpos+1)+"]");
    return false;
    }//if
    break;
    }//case alphanumeric
    case "num":
    case "numeric":
    var charpos = objValue.value.search("[^0-9]");
    if(objValue.value.length > 0 && charpos >= 0)
    if(!strError || strError.length ==0)
    strError = objValue.name+": Only digits allowed ";
    }//if
    alert(strError + "\n [Error character position " + eval(charpos+1)+"]");
    return false;
    }//if
    break;
    }//numeric
    case "alphabetic":
    case "alpha":
    var charpos = objValue.value.search("[^A-Za-z]");
    if(objValue.value.length > 0 && charpos >= 0)
    if(!strError || strError.length ==0)
    strError = objValue.name+": Only alphabetic characters allowed ";
    }//if
    alert(strError + "\n [Error character position " + eval(charpos+1)+"]");
    return false;
    }//if
    break;
    }//alpha
              case "alnumhyphen":
    var charpos = objValue.value.search("[^A-Za-z0-9\-_]");
    if(objValue.value.length > 0 && charpos >= 0)
    if(!strError || strError.length ==0)
    strError = objValue.name+": characters allowed are A-Z,a-z,0-9,- and _";
    }//if
    alert(strError + "\n [Error character position " + eval(charpos+1)+"]");
    return false;
    }//if                
                   break;
    case "email":
    if(!validateEmailv2(objValue.value))
    if(!strError || strError.length ==0)
    strError = objValue.name+": Enter a valid Email address ";
    }//if
    alert(strError);
    return false;
    }//if
    break;
    }//case email
    case "lt":
    case "lessthan":
    if(isNaN(objValue.value))
    alert(objValue.name+": Should be a number ");
    return false;
    }//if
    if(eval(objValue.value) >= eval(cmdvalue))
    if(!strError || strError.length ==0)
    strError = objValue.name + " : value should be less than "+ cmdvalue;
    }//if
    alert(strError);
    return false;
    }//if
    break;
    }//case lessthan
    case "gt":
    case "greaterthan":
    if(isNaN(objValue.value))
    alert(objValue.name+": Should be a number ");
    return false;
    }//if
    if(eval(objValue.value) <= eval(cmdvalue))
    if(!strError || strError.length ==0)
    strError = objValue.name + " : value should be greater than "+ cmdvalue;
    }//if
    alert(strError);
    return false;
    }//if
    break;
    }//case greaterthan
    case "regexp":
                   if(objValue.value.length > 0)
         if(!objValue.value.match(cmdvalue))
         if(!strError || strError.length ==0)
         strError = objValue.name+": Invalid characters found ";
         }//if
         alert(strError);
         return false;
         }//if
    break;
    }//case regexp
    case "dontselect":
    if(objValue.selectedIndex == null)
    alert("BUG: dontselect command for non-select Item");
    return false;
    if(objValue.selectedIndex == eval(cmdvalue))
    if(!strError || strError.length ==0)
    strError = objValue.name+": Please Select one option ";
    }//if
    alert(strError);
    return false;
    break;
    }//case dontselect
    }//switch
    return true;
         Copyright 2003 JavaScript-coder.com. All rights reserved.
    example.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <title>Example for Validator</title>
    <script language="JavaScript" src="gen_validatorv2.js" type="text/javascript"></script>
    </head>
    <body>
    <form action="" name="myform" >
    <table cellspacing="2" cellpadding="2" border="0">
    <tr>
    <td align="right">First Name</td>
    <td><input type="text" name="FirstName"></td>
    </tr>
    <tr>
    <td align="right">Last Name</td>
    <td><input type="text" name="LastName"></td>
    </tr>
    <tr>
    <td align="right">EMail</td>
    <td><input type="text" name="Email"></td>
    </tr>
    <tr>
    <td align="right">Phone</td>
    <td><input type="text" name="Phone"></td>
    </tr>
    <tr>
    <td align="right">Address</td>
    <td><textarea cols="20" rows="5" name="Address"></textarea></td>
    </tr>
    <tr>
    <td align="right">Country</td>
    <td>
         <SELECT name="Country">
              <option value="" selected>[choose yours]
              <option value="008">Albania
              <option value="012">Algeria
              <option value="016">American Samoa
              <option value="020">Andorra
              <option value="024">Angola
              <option value="660">Anguilla
              <option value="010">Antarctica
              <option value="028">Antigua And Barbuda
              <option value="032">Argentina
              <option value="051">Armenia
              <option value="533">Aruba     
         </SELECT>
         </td>
    </tr>
    <tr>
    <td align="right"></td>
    <td><input type="submit" value="Submit"></td>
    </tr>
    </table>
    </form>
    <script language="JavaScript" type="text/javascript">
    //You should create the validator only after the definition of the HTML form
    var frmvalidator = new Validator("myform");
    frmvalidator.addValidation("FirstName","req","Please enter your First Name");
    frmvalidator.addValidation("FirstName","maxlen=20",
         "Max length for FirstName is 20");
    frmvalidator.addValidation("FirstName","alpha");
    frmvalidator.addValidation("LastName","req");
    frmvalidator.addValidation("LastName","maxlen=20");
    frmvalidator.addValidation("Email","maxlen=50");
    frmvalidator.addValidation("Email","req");
    frmvalidator.addValidation("Email","email");
    frmvalidator.addValidation("Phone","maxlen=50");
    frmvalidator.addValidation("Phone","numeric");
    frmvalidator.addValidation("Address","maxlen=50");
    frmvalidator.addValidation("Country","dontselect=0");
    </script>
    </body>
    </html>
    documentation.html
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
    <html>
    <head>
         <title>JavaScript Form Validator Documentation</title>
    <Style>
    BODY, P,TD{ font-family: Arial,Verdana,Helvetica, sans-serif; font-size: 10pt }
    H1{ font-family: Arial,Verdana,Helvetica, sans-serif; font-size: 18pt; color : #000066}
    H3{ font-family: Arial,Verdana,Helvetica, sans-serif; font-size: 12pt; color : #000066 }
    A{font-family: Arial,Verdana,Helvetica, sans-serif;}
    B {     font-family : Arial, Helvetica, sans-serif;     font-size : 12px;     font-weight : bold;}
    CODE {font-family : Courier,monospace;font-size: 10pt;color : #800000;}
    CODE.htm {font-family : "Courier New", Courier, monospace;     font-size : x-small;     color : #000080;}
    </Style>
    </head>
    <body>
    <center>
    <table cellspacing="2" cellpadding="2" border="0" width="600">
    <tr><td>
         <h1>JavaScript Form Validations Made Easy!</h1>
         <h3>Documentation for JavaScript Form Validator</h3>
         <HR size=1>
         <P>
         The Form validation script is distributed free from JavaScript-Coder.com<br>
         You can use the script in your web pages for free.
         </P>
         <P>
         You may please add a link to JavaScript-Coder.com,
         making it easy for others to find this script.<br>
         Checkout the <A href="http://www.javascript-coder.com/links/how-to-link.php
         target="_blank">Give a Link & Get a Link!</A> page.
         </P>
         <P>
         <B>JavaScript Coder</B><br>
         It precisely codes what you imagine!<br>
         Grab your copy here: http://www.javascript-coder.com
         </P>
         <HR size=1>
         <P>
         Using client side JavaScript is an efficient way to validate the user input
         in web applications. When there are many fields in the form, the JavaScript
         validation becomes too complex.
         </P>
         <P>
    The JavaScript class presented here makes the form validations many times easier.
         </P>
         <P>
         The idea is to create a set of "validation descriptors" associated with each element
         in a form. The "validation descriptor" is nothing but a string specifying the type of
         validation to be performed.
         </P>
         <P>
         Each field in the form can have 0, 1, or more validations. For example, the input should
         not be empty, should be less than 25 chars, should be alpha-numeric, etc
         </P>
         You can associate a set of validation descriptors for each input field in the form.
         <a name="3"></a>
         <h3>Using The Script</h3>
         1.Include gen_validatorv2.js in your html file just before closing the HEAD tag<br><br>
         <CODE>
         <script language="JavaScript" src="gen_validatorv2.js" type="text/javascript"></script><BR>
         </head><BR>
         </CODE><br>
         2. Just after defining your form,
         Create a form validator object passing the name of the form<br><br>
         <CODE class='htm'>
          <FORM name='myform' action=""><BR>
          <!----Your input fields go here --><BR>
          </FORM><BR>
         </CODE><CODE>
          <SCRIPT language="JavaScript"><BR>
          var frmvalidator  = new Validator("myform");<BR>
         </CODE>
         <br>
         <br>
         3. Now add the validations required<br><br>
         <CODE>
              frmvalidator.addValidation("FirstName","alpha");
         </CODE><br><br>
         the first argument is the name of the field and the second argument is the
         validation descriptor, which specifies the type of validation to be performed.<br>
         You can add any number of validations.The list of validation descriptors are provided
         at the end of the documentation.<br>
         The optional third argument is the error string to be displayed if the validation
         fails.<br>
         <br>
         <CODE>
              frmvalidator.addValidation("FirstName","alpha");<br>
              frmvalidator.addValidation("FirstName","req","Please enter your First Name");<br>
              frmvalidator.addValidation("FirstName","maxlen=20",<br>
                   "Max length for FirstName is 20");          <br>
         </CODE>     <br>
         <br>
         4. Similarly, add validations for the fields where validation is required.<br>
         That's it! You are ready to go.
         <A name="3"></A>
         <h3>Example</h3>
         The example below will make the idea clearer<br>
         <CODE class="htm">
                   <form action="" name="myform" ><BR>
                   <table cellspacing="2" cellpadding="2" border="0"><BR>
                   <tr><BR>
                     <td align="right">First Name</td><BR>
                     <td><input type="text" name="FirstName"></td><BR>
                   </tr><BR>
                   <tr><BR>
                     <td align="right">Last Name</td><BR>
                     <td><input type="text" name="LastName"></td><BR>
                   </tr><BR>
                   <tr><BR>
                     <td align="right">EMail</td><BR>
                     <td><input type="text" name="Email"></td><BR>
                   </tr><BR>
                   <tr><BR>
                     <td align="right">Phone</td><BR>
                     <td><input type="text" name="Phone"></td><BR>
                   </tr><BR>
                   <tr><BR>
                     <td align="right">Address</td><BR>
                     <td><textarea cols="20" rows="5" name="Address"></textarea></td><BR>
                   </tr><BR>
                   <tr><BR>
                     <td align="right">Country</td><BR>
                     <td><BR>
                          <SELECT name="Country"><BR>
                             <option value="" selected>[choose yours]<BR>
                             <option value="008">Albania<BR>
                             <option value="012">Algeria<BR>
                             <option value="016">American Samoa<BR>
                             <option value="020">Andorra<BR>
                             <option value="024">Angola<BR>
                             <option value="660">Anguilla<BR>
                             <option value="010">Antarctica<BR>
                             <option value="028">Antigua And Barbuda<BR>
                             <option value="032">Argentina<BR>
                             <option value="051">Armenia<BR>
                             <option value="533">Aruba     <BR>
                         </SELECT><BR>
                        </td><BR>
                   </tr><BR>
                   <tr><BR>
                     <td align="right"></td><BR>
                     <td><input type="submit" value="Submit"></td><BR>
                   </tr><BR>
                   </table><BR>
                   </form><BR>
                   </CODE><CODE>
                   <script language="JavaScript" type="text/javascript"><BR>
                    var frmvalidator = new Validator("myform");<BR>
                    frmvalidator.addValidation("FirstName","req","Please enter your First Name");<BR>
                    frmvalidator.addValidation("FirstName","maxlen=20",<BR>
                        "Max length for FirstName is 20");<BR>
                    frmvalidator.addValidation("FirstName","alpha");<BR>
                    <BR>
                    frmvalidator.addValidation("LastName","req");<BR>
                    frmvalidator.addValidation("LastName","maxlen=20");<BR>
                    <BR>
                    frmvalidator.addValidation("Email","maxlen=50");<BR>
                    frmvalidator.addValidation("Email","req");<BR>
                    frmvalidator.addValidation("Email","email");<BR>
                    <BR>
                    frmvalidator.addValidation("Phone","maxlen=50");<BR>
                    frmvalidator.addValidation("Phone","numeric");<BR>
                    <BR>
                    frmvalidator.addValidation("Address","maxlen=50");<BR>
                    frmvalidator.addValidation("Country","dontselect=0");<BR>
                   </script><BR>     
         </CODE>
         <A name="4"></A>
         <h3>Some Additional Notes</h3>
         <LI type="disc">The form validators should be created only after defining the HTML form
         (only after the </form> tag. )<br>
         <LI type="disc">Your form should have a distinguished name.
         If there are more than one form
         in the same page, you can add validators for each of them. The names of the
         forms and the validators should not clash.
         <LI type="disc">You can't use the javascript onsubmit event of the form if it you are
         using this validator script. It is because the validator script automatically overrides the
         onsubmit event. If you want to add a custom validation, see the section below
         </LI>
         <A name="5"></A>
         <h3>Adding Custom Validation</h3>
         If you want to add a custom validation, which is not provided by the validation descriptors,
         you can do so. Here are the steps:
         <LI type="disc">Create a javascript function which returns true or false depending on the validation.<br>
         <CODE>
              function DoCustomValidation()<BR>
              {<BR>
                var frm = document.forms["myform"];<BR>
                if(frm.pwd1.value != frm.pwd2.value)<BR>
                {<BR>
                  alert('The Password and verified password does not match!');<BR>
                  return false;<BR>
                }<BR>
                else<BR>
                {<BR>
                  return true;<BR>
                }<BR>
              }<BR>
         </CODE><br>
         <LI type="disc">Associate the validation function with the validator object.<br>
         <CODE>
         frmvalidator.setAddnlValidationFunction("DoCustomValidation");
         </CODE><br>
         </LI>
         <P>
         The custom validation function will be called automatically after other validations.
         </P>
         <P>
         If you want to do more than one custom validations, you can do all those
         validations in the same function.
         </P>
         <CODE>
              function DoCustomValidation()<BR>
              {<BR>
                var frm = document.forms["myform"];<BR>
                if(false == DoMyValidationOne())<BR>
                {<BR>
                  alert('Validation One Failed!');<BR>
                  return false;<BR>
                }<BR>
                else<BR>
                if(false == DoMyValidationTwo())<BR>
                {<BR>
                  alert('Validation Two Failed!');<BR>
                  return false;<BR>
                }<BR>
                else<BR>
                {<BR>
                  return true;<BR>
                }<BR>
              }<BR>
         </CODE><br>
         where DoMyValidationOne() and DoMyValidationTwo() are custom functions for
         validation.
         <A name="6"></A>
         <h3>Clear All Validations</h3>
         In some dynamically programmed pages, it may be required to change the validations in the
         form at run time. For such cases, a function is included which clears all validations in the
         validator object.<br><br>
         <CODE>
         frmvalidator.clearAllValidations();
         </CODE><br>
         <br>
         this function call clears all validations you set.<br>
         You will not need this method in most cases.
         <a name="7"></a>
         <h3>Table of Validation Descriptors</h3>     
    <table cellspacing="2" cellpadding="2" border="1" width="520px">
    <tr>
    <td><FONT face=Arial size=2>
         required<BR>
         req </FONT>
         </td>
    <td><FONT face=Arial size=2>The field should not be
    empty </FONT>
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>
         maxlen=???<BR>
         maxlength=???
         </td>
    <td><FONT face=Arial size=2>checks the length entered data to the maximum. For
    example, if the maximum size permitted is 25, give the validation descriptor as "maxlen=25"
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>
         minlen=???<BR>
         minlength=???
         </td>
    <td><FONT face=Arial size=2>checks the length of the entered string to the
    required minimum. example "minlen=5"
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>
         alphanumeric /<BR>
         alnum </FONT>
         </td>
    <td><FONT face=Arial size=2>Check the data if it
    contains any other characters other than alphabetic or numeric characters
    </FONT>
         </td>
    </tr>     
    <tr>
    <td><FONT face=Arial size=2>num <BR>
         numeric </FONT>
         </td>
    <td><FONT face=Arial size=2>Check numeric data
    </FONT>
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>alpha <BR>
         alphabetic </FONT>
         </td>
    <td><FONT face=Arial size=2>Check alphabetic data.
    </FONT>
         </td>
    </tr>     
    <tr>
    <td><FONT face=Arial size=2>email </FONT>
         </td>
    <td><FONT face=Arial size=2>The field is an email
    field and verify the validity of the data. </FONT>
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>lt=???<BR>
         lessthan=???
         </td>
    <td><FONT face=Arial size=2>
         Verify the data to be less than the value passed.
         Valid only for numeric fields. <BR>
         example: if the
    value should be less than 1000 give validation description as "lt=1000"
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>gt=???<BR>
         greaterthan=???     </td>
    <td><FONT face=Arial size=2>
         Verify the data to be greater than the value passed.
         Valid only for numeric fields. <BR>
         example: if the
    value should be greater than 10 give validation description as "gt=10"
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>regexp=??? </FONT>
         </td>
    <td><FONT face=Arial size=2>
         Check with a regular expression the value should match the regular expression.<BR>
         example: "regexp=^[A-Za-z]{1,20}$" allow up to 20 alphabetic
         characters.
         </td>
    </tr>
    <tr>
    <td><FONT face=Arial size=2>dontselect=?? </FONT>
         </td>
    <td><FONT face=Arial size=2>This
    validation descriptor is valid only for select input items (lists)
    Normally, the select list boxes will have one item saying 'Select One' or
    some thing like that. The user should select an option other than this
    option. If the index of this option is 0, the validation description
    should be "dontselect=0"
         </td>
    </tr>
    </table>
         <P>
              <table cellspacing="2" cellpadding="2" border="1" width="520">
              <tr>
              <td>
                   <B>NOTE:</B><br>
                   The HTML Form Wizard included in JavaScript Coder contains still more
                   number of validations
                   (comparison validations, check box & radio button validations and more)<br>
                   Using the wizard, you can add validations to your forms
                   without writing a single line of code! <br>
                   JavaScript Coder takes care of
                   generating the code and inserting the code in to the HTML file.<br>
                   <A href="http://www.javascript-coder.com/index.phtml
                   target="_blank">Read more about JavaScript Coder</A>
                   </td>
              </tr>
              </table>
         </P>
         <A name="8"></A>
         <h3>Example Page</h3>     
         See the <a href="example.html target="_blank"
         >JavaScript form validation example here</a>
    </td>
    </tr>
    <tr><td align="center">
         <HR><br>
         Copyright &copy; 2003 JavaScript-Coder.com. All rights reserved.
    </td></tr>
    </table>     
    </center>
    </body>
    </html>

    The code is not working because you made a mistake somewhere, duh! So figure out what (hint: firefox javascript console, it's your friend) and fix it!
    And next time when you post code: use the [ code ]  tags to pretty format your code, as it is now it's unreadable.
    http://forum.java.sun.com/help.jspa?sec=formatting

  • OBIEE variables in custom java script

    Hello all
    Can I use OBIEE variables like presentation and session variables in my custom java script code that I am writing in text view on a dashboard page. Is it possible to do that. please me soon if somebody knows the solution to do that.
    Thanks in Advance

    Hi john
    Thanks for reply, I am able to generate javascript using text view on a dashboard page.
    But I want to access OBIEE variables in javascript. How I can do that in narrative view. Can u explain me or give me any link.
    Thanks

  • Data transfer B/W parent windonw and child window with out java script

    hi ,
    i am using h:outputLink Tag to open child window , i am unable to pass parent window text box value to child window with out java script , Here i am using two different backing beans for parent and child windows . Plz help me .

    Hi -- I pass details between pages regularly. The following has worked for me:
    ApplicationFactory factory = (ApplicationFactory) FactoryFinder.getFactory(FactoryFinder.APPLICATION_FACTORY);
    ValueBinding binding = factory.getApplication().createValueBinding("#{beanName}");
    BeanName beanProperty = (BeanName) binding.getValue(FacesContext.getCurrentInstance());
    ... then set the you can set the values. Can't recall if I need to use SaveStates for the items. Probably if you use request scope beans.

  • Problem with Java Script after upgrade from BW 3.5 to BI7

    Dear Colleagues,
    We're facing the issue with Java Script after upgrade of BW 3.5 to BI7.
    Just after update we checked the basic functionality and it occured that some of web templates that use Java Script don't work. They generate seelction screen, but after selection the screen becomes blank without any error messages.
    We're currently stucked since web templates weren't converted to BI7 version so they should work exactly as before the upgrade.
    We compared the Java code with other environment that was not upgraded - it's perfectly the same.
    The only explanation that comes to my mind is that some Java Script settings on the server level were changed during the upgrade but I have no idea where I can check that.
    Thanks in advance for any suggestions,
    Andrzej Bobula

    Hi Deepu,
    Thanks, it was great to read your reply and then few minutes later talk to you live on SDN Day!
    Unfortunately, http cache clean-up did not help. But there is another funny thing I found - for exactly the same 3.5 webtemplate html code returned from WebAS 3.5 was different then from 7.0.
    Unfortunately, this editor does not allow to paste complete code, even in CODE brackets, but here are main differences:
    <b>3.5</b>
       if (navigator.appName == "Microsoft Internet Explorer")
    <frame src="/sap/bw/BEx?SAP-LANGUAGE=E&PAGENO=1&REQUEST_NO=1&CMD=GET_TEMPLATE"
    name="Content">
    and
    <b>7.0</b>
       if (navigator.appName.indexOf("Microsoft Internet Explorer")!=-1)
    <frame src="/sap/bw/BEx?SAP-LANGUAGE=E&PAGENO=8&REQUEST_NO=0&CMD=GET_TEMPLATE"
    name="Content" 0nLoad="javascript:loadTitle()">
    (I intentionaly put 0 i/o o in 0nLoad, otherwise Forum's editor does not accept the text.
    How about SAP's claim that technical upgrade from 3.x to 7.0 changes nothing?
    Regards,
    Vitaliy

  • How to read the value of Inputfield in WAD in JAVA script?

    Hi Experts,
    I have a requirement in WAD .
    I have put an Input Field (text box), a button and a script control  in the web template.
    In my script control function , I want to read the value entered in the input field using java script. How do I achieve it?
    Thanks in advance.
    Regards
    akshay

    Hi,
    To do this, first you may want to view the HTML source of the report. So, when you have the report launched with the input field, right click and select View Source. Usually it is under a <span> tag with id something like sapbi_snippet_YOURWEBITEMNAME. Most useful commands here are document.getElementById and document.getElementsByTagName.
    You can also access the input web item value using standard sap command SET_SELECTION_STATE_BY_BINDING. Take a look at the documentation on this.
    Hope the above helps.
    Regards,
    wira

  • Page failure when attempting to save java script in html header

    Currently there is java script code for a function that is seeded in the html header of a forms page by apex when the form is generated. This code is for the chicken test for the DELETE button.
    The function works as designed, but if I try to "APPLY CHANGES" to the the page definition I get the The page cannot be displayed "Cannot find server or DNS Error". "the url is http://nldg-3.appl.devjones.com:7777/pls/apex/wwv_flow.accept" If I remove the script coding from the HTML header the page will save just fine, but of course no more java script.
    I need to add a java script function to the page and I am unable to do so at this time because of this issue. I can reproduce this error on any of the sample apps that I have loaded into apex.
    the Apache error log contains:
    [Fri Feb 13 06:11:06 2009] [error] [client 172.16.85.122] [ecid: 1234527066:192.168.211.127:31922:0:17188,0] mod_plsql: /pls/apex/wwv_flow.accept HTTP-500 Error Reading Data from Client!!
    The Apache access gets:
    172.16.85.122 - APEX_PUBLIC_USER [13/Feb/2009:06:23:47 -0600] "POST /pls/apex/wwv_flow.accept HTTP/1.1" 500 653
    Apex is version 3.1.2.00.02 and uses on iAS on a Linux server. The Database is 10g. The browser is IE 6.0.2900.2180.
    I have been developing for about 3 months in Apex and this is the first issue of this kind that I have run into. Any help will be greatly appreciated as I have no clue at this time.

    Luis,
    All the forms are created by Apex with a default function in the html header for a delete chicken test as follows:
    <scrpt language="JavaScript" type="text/javascript">
    <!--
    htmldb_delete_message='"DELETE_CONFIRM_MSG"';
    //-->
    Even though the function is already a part of the page, if I try to save it, it will fail. I will look into the "black list" a little deeper. I have asked around abit as I also had suspected that, but so far all the answers were that it should not be a problem. If I take out the "SCRIPT" word I can get the page to save, but of course the code is worthless at that point.
    Keith

  • Is there any way to determine if a link is a book mark or hyperlink in java script

    Is there any way to determine if a link is a book mark or hyperlink in java script
    Sub Problem:
    I am making an array of quads of all the hyperlinks in a document. I would like to automatically skip over all the bookmarks in the starting pages of a document and just get the links of the hyperlinks.
    Now I have to manually set the pages that contain bookmarks so they are not included in the array.
    Is there any way to determine if a link is a book mark or hyperlink in java script?
    It would help automate the conversion I need below
    John
    Main Problem:
    I have been working on converting a set of pdf files with 1000’s of hyperlinks like www.site.com\folder1\file1.pdf#page=10
    To jump to a local copy of the files with a relative type link
    ../folder1/file1.pdf and then go to the proper page.
    I have found that it can be done manually by changing the hyperlink to a javascript
    var otherDoc = app.openDoc('../folder1/file1.pdf', this);otherDoc.pageNum = 10 - 1;
    and setting each destination file with a disclose()=true;
    Based on the help so far that java script cannot access the hyperlink value in a link
    See: http://forums.adobe.com/thread/1039908?tstart=60
    I have resorted to the following plan using acrobat javascript, an external keyboard macro recorder and excel in combination to get around the problem
    Four folder level acrobat javascripts with “buttons”
    One to get all the link quads in an array, in the pdf and report the total number
    The second creates a form field in the far corner of the first page and moves there.
    The third jumps to each link found by creating a form field just to the left of the link and zooms in so it can be selected by a “mouse click” from the keyboard macro recorder 
    The forth deletes the form field
    The keyboard macro recorder runs javascript 2 and then 3 then clicks on the link just to the right of the middle of the screen and uses keys to get to the advanced editing to get to edit the hyperlink .
    The hyperlink is then copied to excel where it is converted using string functions to the needed javascript text to be copied back.
    To the acrobat file into a java script (after deleting the hyperlink)
    Rinse/lather/repeat
    I have been able to convert about 150 links an hour.
    Better then hand typing, but not like having java access to the links.
    I am looking to improve the solution

    thanks for your help.
    I may have been confusing a "acrobat bookmark" and a bookmark in a word file that is converted to a pdf and ends up being a
    link of the type:
    "Go to a page in this document"
    which I do not want in my array vs
    a link of the action type:
    "Open a web link"
    Which I do want
    John
    My code, note how I have to skip pages with "Go to a page in this document" links depending on the document, I would like to use the same code for each document and skip over the "Go to a page in this document" links :
    global.ilinkindex = 1; 
    global.aLinkquads = [ [0, 1, 1, 0, 0],
           [0, 0, 0, 0, 0] ];
    function GetLinkArray()
    global.ilinkindex = 1;
    var iTotalLinks=0;
    // for ( var p = 0; p < this.numPages - 8 ; p++)                   // end before bookmarks for each page of the file x.pdf
    //  for ( var p = 0; p < this.numPages; p++)                     // for each page of the file
    for ( var p = 23; p < this.numPages; p++)                     // start after bookmarks for each page of the file y.pdf
      var cropbox = this.getPageBox("Crop", p);
      var alinksonpage = this.getLinks(p, cropbox);            // get array of links on page
      for ( var ll = 0; ll < alinksonpage.length; ll++)
       var linkquads = alinksonpage[ll].rect;     // get link Quads
       linkquads[4] = p;          // add page number to link Quads array
        global.aLinkquads[global.ilinkindex] = linkquads; // add quads to global link Quads array
        global.ilinkindex++;
    iTotalLinks = global.aLinkquads.length - 1;
    global.ilinkindex = 1;
    app.alert("Number of Links in Document is " + iTotalLinks );

Maybe you are looking for

  • Java.nio and databases

    Please, need help. I'm using java.nio to get large files contents (txt) and need to put these data into MSSQL SERVER 2000 database tables. NIO have capabilityies to get data and transfer directly to the tables? If so, how can i do it? Thanks a lot Al

  • HT1864 Can I still use iCloud if I don't have Vista or Windows 7?  I have XP.

    Can I still use iCloud if I don't have Vista or Windows 7?  I only have XP on my computer.

  • Maximum Amount for a Payment

    Dear Expert, i have set a limit 1,500,000.00 u20AC within the tcode FBZP so in case of the outgoing supplier payment and the paid amount > on what I have defined I got an exception , I think that it is logic. My question what are the possibilities th

  • How To connect More Then One database

    How To Connect More the One Database In Single form. I want to use Access And Oracle In the Same Form. I want to Transfer data from Access file To oracle database. Chirag

  • Painting In Color Mode

    Hello to anyone reading! I seek dire assistance when painting in 'color' mode. When I select a color and begin painting, it is completely different to the color I originally selected. But when my friend does it, hers is the same color? I don't unders