JavaScript - Jkmegamenu Alignment Issue
Hello,
I'm using the jk mega menu found at: http://www.javascriptkit.com/script/...megamenu.shtml My menu is about 600px wide. When I resize the browser window smaller, the menu seems to auto adjust to the new window size and aligns the menu bottom/ extending left of the anchor, as opposed to the default (bottom/extending right.) I'd like to force the menu always extending right because extending left is sending it off the page left. Collapse this window smaller and roll over the menu and you'll see the issue: http://www.javascriptkit.com/script/...megamenu.shtml Thanks for any help you can provide and I appreciate your time, Similar TutorialsI wasn't sure whether this needed to go in Javascript or in CSS. In the code I have below, I have a popup box that's displayed via javascript. It is supposed to be displayed in the center of the screen no matter what the location of the link is when it is clicked. All the JS part works fine, I believe the issue is in the HTML/CSS itself, but I'm not sure. As it is now, it works fine on IE, and everything is aligned properly, but it is offset to the right (by roughly 150px or so, I think) in Firefox. However, if I uncomment the line that is commented out (which would define the "right" attribute" of #outside and #behindoutside, instead of leaving it to default), the problem is reversed. Does this have something to do with a difference in FF/IE's handling of the "position" attribute in CSS? That has been my best guess so far but I still haven't been able to fix the error. Also, the box does not appear to fade in/out at all in IE. This is less of a concern to me than the alignment, but still somewhat of a problem. EDIT: I've come up with a (hopefully temporary) solution of using an if statement to determine if the browser is Firefox, but I would prefer to fix the actual source issue instead of just fixing the problem is causes.so Code: <html> <head> <meta http-equiv="content-type" content="text/html;charset=iso-8859-1"> <meta name="generator" content="Adobe GoLive"> <title>Untitled Page</title> <script type="text/javascript" src="http://207.200.19.180/images/10000/6000/170BE/user/jquery-1.3.2.js" /></script> <style type="text/css"> #behindoutside{ opacity:0.90 !important; text-align: center; position: absolute; width: 100% !important; z-index: 0; } #x{ filter:alpha(opacity=90) !important; opacity:0.90 !important; } #image{ filter:alpha(opacity=90) !important; background-color: silver; border: 1px solid black; width: 100%; height: 100%; } #insidebehindoutside{ height: 420px; width: 550px; } #outside{ width: 100%; text-align: center; position: absolute; z-index: 1; } #popup{ text-align: center; height: 420px; width: 550px; } </style> <script language="javascript"> $(document).ready(function(){ $('#start').click(function(){ $("#outside, #behindoutside").fadeIn('normal'); var boxheight = $("#insidebehindoutside").height(); var tall = jQuery(window).height(); var scroll = jQuery(window).scrollTop(); var heightShift=((tall/ 2 ) - (boxheight / 2 )) + scroll; $("#outside, #behindoutside").css("top", heightShift); //$("#outside, #behindoutside").css("right", "2px"); }); $('#x').click(function(){ $('#outside, #behindoutside').fadeOut('normal'); }); }); </script> </head> <body> <div id="behindoutside" style="display:none;"> <center> <div id="insidebehindoutside"> <img id="image" src="http://207.200.19.180/images/10000/3000/914BE/user/blank.png"/> </div> </center> </div> <div id="outside" style="display:none;"> <center> <div id="popup"> <img id="x" style="float:right; position: relative; right: 5px; top:5px; cursor:pointer;" onmousedown="getElementById('x').src='http://207.200.19.180/images/10000/6000/170BE/user/xdown.gif'" onmouseup="getElementById('x').src='http://207.200.19.180/images/10000/6000/170BE/user/xup.gif';" onmouseout="getElementById('x').src='http://207.200.19.180/images/10000/6000/170BE/user/xup.gif'" src="http://207.200.19.180/images/10000/6000/170BE/user/xup.gif" /> <br><br> <p>Popup Content</p></div> </center> </div> <div> <center> <font size="3">Supply Lists</font> <hr align="center" width="25%" /> </center> <p align="center"><a id="start" style="color: blue; text-decoration: underline; cursor:pointer;" onclick="appear();">Click for popup box!</a></p> </div> </body> </html> Hey just a quick question... I have something centered on my page (its a table). How can I align something to the left of what I already have centered?
I've having a problem with alignment on my portfolio. It works in mozilla although you may need to refresh the page, and it doesn't work in chrome at all. does anyone know why? the address is townsendwebdd.com thanks, I am totaly stuck Hello everyone, I am new to CSS and am having some difficulties with javascript alignment. I have inserted the proper script into my banner and it is in the proper spot but its too far left. I would like to be able to move it into the center. What should I be adjusting? Not really sure how padding etc all works and not sure if that's how i would go about fixing it. Thanks I would like to change the alignment of an image which currently under div which is under iframe. the page which is called under iframe is readymade html from some other site. I dont have any control on that HTML page which is under iframe. Please tell me how to align image under iframe.
Freaking IE. Must die. Really it must. Unfortunately, I have to code for it, and I can't figure out what went wrong he http://wyqued-design.com/dev/skyview/index.html The navigation, and layout, breaks in IE 7. Any ideas? -Emilie I have the following sample html file (attached). I am trying to display the calculated field using javascript and I created a function (I am a newbie) to do so. However, it persistently shows NaN instead of the required number. I have tried my best over a coupla hours racking my brains and the internet as to why it shows as not a number. I will appreciate any help. Thanks, I have created a quick little pricing engine to price some of the products that we sell. I was able to use a nice template online and it worked for most of what we offer. However, I needed to add a few filters and while doing so, needed to tweak the JS even further than I was originally comfortable with doing. Long story short, here is the main pricing page - www.pricemyleads.com - and this is the page in question as of now - www.pricemyleads.com/taxaged.html The js file for this page is - http://www.pricemyleads.com/js/taxag...alculations.js Any help is greatly appreciated. You'll see the issue when you start clicking on the check boxes. Thanks, brmacdon hi, i have a problem with innerHTML if i wrote document.getElementById('someid').innerHTML = "ok"; then it wroks but when i wrote document.getElementById('someid').innerHTML = "<sometext> ok"; it does not work. i.e. <sometext> is not visible if check on firebug / dom it display.. <sometext> ok </sometext> please help.. how do i print / display above string as it as. you may download file or check below link.. please click here I'm trying to add an event handler for to my body, and for some reason which I can't figure out, it only works on Google Chrome. I wouldn't expect it to work in IE, but am wondering why it's not working in Firefox. Here's the relevant parts of the code: Javascript (in an external file) Code: var body = document.body; body.addEventListener("load", Foo(), false); function Foo(){ addEventListener(document.getElementsByName("start"),"click", alert("hello"), false); } HTML Code: <html> <head> <title>BREAKOUT!</title> <script src="breakout.js" type="text/Javascript" > </script> <LINK REL="stylesheet" HREF="breakout.css" TYPE="text/css"> </head> <body id="body"> <!-- etc.... --> Alright,ill go straight to the problem. I want to get all the elements with a certain tag.However i can only get the first one. my code: Code: function getTags(tag) { var x = document.getElementsByTagName(tag); var y = x.length; for(var i = 0; i <= y;i++) { return x[i]; } } I am very new to coding, I am currently working on this design as my very first: http://img822.imageshack.us/img822/6533/unled1pd.jpg. I am currently working on the Image slider which is on the left side next to the login bar and headlines. I don't know where to start with this. If someone could walk me through or help me in anyway i would greatly appreciate it. Here is my current project LIVE: http://visionarycreativegrp.com/Demos/ForSale%20RED/# Hi I am new here and also to java Any help you can give me would be gratefuly appreciated as I feel I am being very dumb over what should be a simple fix. The following code is working accept for the part where the original image (Main Image) is replaced with either Image1/Image2 when mouse over occurs but wont revert back to its original image (MainImage) once onmouseout? There-in lies my problem: Code: <body> <tr> <!-- <td><table width="100%" bgcolor="#b0b0b0" border="0" cellpadding="10" cellspacing="1"> --> <tbody><tr> <td bgcolor="#ffffff"> <table width="86%" border="0" cellpadding="0" cellspacing="0"> <tbody><tr> <script language="JavaScript" type="text/javascript"> function fda(pic){ document.getElementById("PicViewer").src=pic; } </script> </table> <div align="center"> <table border="0" cellPadding="0" width="950" height="650" style="border-collapse: collapse" bordercolor="#111111"> <tr> <td width="15" bgcolor="#111111" height="542" rowspan="3"> <p align="center"> </td> <td bgcolor="#405E76" height="650" colspan="9" background="http://www.mypersonalpage.talktalk.net/ebay/Webpage/polaroid.jpg" valign="top"> <p align="center"> <img src="http://i99.photobucket.com/albums/l290/big_poppa_duke/mainimg.png" class="biankuang2" id="PicViewer" border="0" width="640" height="480" vspace="55" hspace="0"></td> <td width="15" bgcolor="#111111" height="542" rowspan="3"> </td> </tr> <tr> <td width="15" bgcolor="#405E76" height="80"> </td> <td width="121" bgcolor="#405E76" align="center"> </td> <td width="145" bgcolor="#405E76" align="center"> </td> <td width="145" bgcolor="#405E76" align="center"> <img border="2" src="http://i99.photobucket.com/albums/l290/big_poppa_duke/img2.png"class="biankuang2" onmouseover="fda(this.src)" width="125" height="93" vspace="2"></td> <td bgcolor="#405E76" align="center" width="145"> </td> <td width="145" bgcolor="#405E76" align="center"> <img border="2" src="http://i99.photobucket.com/albums/l290/big_poppa_duke/img3.png"class="biankuang2" onmouseover="fda(this.src)" width="125" height="93" vspace="2"></td> <td width="145" bgcolor="#405E76" align="center"> </td> <td width="121" bgcolor="#405E76" align="center"> </td> <td width="14" bgcolor="#405E76"> </td> </tr> </table> P.s something I found strange when loading my page it seems to load twice with a defining click. Very annoying and wonder if it's possible to remove that bit too. Thank you very much for any help. The problem that I am facing is my total amount comes out to $102.46 through my calculations on the page. But when it is moved over to PayPal, the value becomes $102.44. I have many more amount that are also either up .2 cents or down .2 cents. I managed to track this down as a rounding issue. Anytime I do the math, it rounds the amount off and gives the total. But since quantity is involved which is done through PayPal, I had to divide my total by the quantity to bring it back to its original amount thus allowing PayPal to multiply the amount by the quantity. I've pulled my hair out on this one. Ay help would be appreciated. Thank you Code: <html> <head> <title>TESTING</title> <script src="SpryAssets/SpryValidationSelect.js" type="text/javascript"></script> <script src="SpryAssets/SpryValidationCheckbox.js" type="text/javascript"></script> <script src="SpryAssets/SpryValidationTextField.js" type="text/javascript"></script> <link href="SpryAssets/SpryValidationSelect.css" rel="stylesheet" type="text/css"> <link href="SpryAssets/SpryValidationCheckbox.css" rel="stylesheet" type="text/css"> <link href="SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css"> </head> <td width="95%" align="center" class="TextoImageSpace"><table border="0" cellpadding="0" cellspacing="0" class="TextoImageSpace_center"> <tr> <td align="center"><h2>Pricing</h2> <form action="https://www.paypal.com/cgi-bin/webscr" method="post" name="price" id="price"> <p>Select amount please.</p> <p> <input type="hidden" name="cmd" value="_xclick" /> State: <br /> <span id="spryselect1"> <!-- selects the state // onclick changes the variables specified values --> <select name="combo0" id="combo_0" onclick="roundNumber(amount2.value, 2);roundNumberTax(tax.value, 2);roundNumberProduct(product.value, 2);roundNumberShipping(shipping.value, 2);roundNumberAmount(amount2.value, 2)" style="width:200px;"> <option selected="selected"> </option> <option value="70">Arizona</option> </select> <span class="selectRequiredMsg"></span></span><br /> Quantity: <br /> <span id="spryselect2"> <!-- selects the quantity // onclick changes the variables specified values --> <select name="combo1" id="combo_1" onclick="roundNumber(amount2.value, 2);roundNumberTax(tax.value, 2);roundNumberProduct(product.value, 2);roundNumberShipping(shipping.value, 2);roundNumberAmount(amount2.value, 2)" style="width:200px;"> <option selected="selected"> </option> <option value="4">4 - $20.95</option> </select> <span class="selectRequiredMsg"></span></span><br /> Product: <br /> <span id="sprytextfield11"> <label> <input type="text" name="product" id="txt_product" disabled="disabled" value="" style="width:200px;" /> </label> </span><br /> Shipping: <br /> <span id="sprytextfield9"> <label> <input type="text" name="shipping" id="txt_shipping" disabled="disabled" value="" style="width:200px;" /> </label> </span><br /> Taxes: <br /> <span id="sprytextfield10"> <label> <input type="text" name="tax" id="txt_tax" disabled="disabled" value="" style="width:200px;" /> </label> </span><br /> Total: <span id="sprytextfield8"> <input type="hidden" name="amount" id="txt_price" value="" style="width:200px;" /> </span> <input type="hidden" name="amount3" id="txt_price3" value="" style="width:200px;" /> <br /> <span id="sprytextfield7"> <input type="text" name="amount2" id="txt_price2" disabled="disabled" value="" style="width:200px;" /> </span></p> <hr width="100%" /> <p>Please fill in details.</p> <p> <input type="hidden" name="item_name" value="TEST ITEM" /> <input type="hidden" name="button_subtype" value="products" /> <input type="hidden" name="rm" value="1" /> <input type="hidden" name="return" value="http://www.example.com/" /> <input type="hidden" name="cancel_return" value="http://www.example.com/" /> <input type="hidden" name="currency_code" value="USD" /> <input type="hidden" name="bn" value="PP-BuyNowBF:btn_buynowCC_LG.gif:NonHosted" /> <input type="hidden" name="address_override" value="1" /> <input type="hidden" name="shipping" value="0" /> <input type="hidden" name="business" value="wayne@lifelikemedia.ca" /> <input type="hidden" name="quantity" id="quantity" value="1" /> <input type="hidden" name="state" id="state" value="" /> First Name: <br /> <span id="sprytextfield1"> <input type="text" name="first_name" value="TEST" style="width:200px;" /> <span class="textfieldRequiredMsg"></span></span><br /> Last Name: <br /> <span id="sprytextfield2"> <input type="text" name="last_name" value="TEST" style="width:200px;" /> </span> <br /> Address: <br /> <span id="sprytextfield3"> <input type="text" name="address1" value="1234 TEST STREET" style="width:200px;" /> <span class="textfieldRequiredMsg"></span></span><br /> City: <br /> <span id="sprytextfield4"> <input name="city" type="text" value="Scottsdale" style="width:200px;" /> <span class="textfieldRequiredMsg"></span></span><br /> ZIP Code: <br /> <span id="sprytextfield5"> <input type="text" name="zip" value="85260" style="width:200px;" /> </span><br /> Country: <br /> <span id="sprytextfield6"> <input name="country" type="text" disabled="disabled" value="US" style="width:200px;" /> </span><br /> <br /> <span id="sprycheckbox1"> <label> <input type="checkbox" name="replacePolicy" id="replacePolicy" /> </label> <span class="checkboxRequiredMsg">Please read policy.</span></span> <a href="#" class="style10" onClick="window.open('replace.html','popup','width=400,height=300,scrollbars=yes,resizable=yes,toolbar=no,directories=no,location=no,menubar=no,status=no,left=50,top=0'); return false">Please read policy.</a><br /> <br /> <input type="image" name="submit" border="0" src="http://www.thinkanddone.com/finance/buynow.jpg" alt="PayPal - The safer, easier way to pay online" /> </p> </form></td> </tr> </table> <script type="text/javascript"> var shipping = document.getElementById("txt_shipping").value; var tax = document.getElementById("txt_tax").value; var product = document.getElementById("txt_product").value; // rounds total amount off function roundNumber(rnum, rlength) { // Arguments: number to round, number of decimal places var v1 = document.getElementById("combo_1").value, v2 = document.getElementById("combo_0").value; var newnumber = Math.round(rnum*Math.pow(10,rlength))/Math.pow(10,rlength); var newnumber2 = Math.round(rnum*Math.pow(10,rlength))/Math.pow(10,rlength); document.price.amount2.value = newnumber.toFixed(2); // Output the result to the form field document.price.amount.value = (newnumber2 / v1).toFixed(2); } // rounds tax off function roundNumberTax(rnum, rlength) { // Arguments: number to round, number of decimal places var taxnumber = Math.round(rnum*Math.pow(10,rlength))/Math.pow(10,rlength); document.price.tax.value = taxnumber.toFixed(2); // Output the result to the form field } // rounds product off function roundNumberProduct(rnum, rlength) { // Arguments: number to round, number of decimal places var productnumber = Math.round(rnum*Math.pow(10,rlength))/Math.pow(10,rlength); document.price.product.value = productnumber.toFixed(2); // Output the result to the form field } // rounds shipping off function roundNumberShipping(rnum, rlength) { // Arguments: number to round, number of decimal places var shippingnumber = Math.round(rnum*Math.pow(10,rlength))/Math.pow(10,rlength); document.price.shipping.value = shippingnumber.toFixed(2); // Output the result to the form field } // rounds paypal amount off function roundNumberAmount(rnum, rlength) { // Arguments: number to round, number of decimal places var amountnumber = Math.round(rnum*Math.pow(10,rlength))/Math.pow(10,rlength); document.price.amount2.value = amountnumber.toFixed(2); // Output the result to the form field } window.onload = function() { var dropChange = function() { // Declaring variables var v1 = document.getElementById("combo_1").value, v2 = document.getElementById("combo_0").value; var amount3 = document.getElementById("txt_price3").value, amount = document.getElementById("txt_price").value; document.getElementById("txt_price3").value = (amount); document.getElementById("quantity").value = (v1); if (v2 == 70) { document.getElementById("state").value = ("AZ"); } <!-- when state is selected, these calculations are done --> if (v2 == 70) { if (v1 == 4) { document.getElementById("txt_price2").value = v1 * 20.95; document.getElementById("txt_product").value = document.getElementById("txt_price2").value; document.getElementById("txt_price2").value = document.getElementById("txt_product").value * 0.0795; document.getElementById("txt_tax").value = document.getElementById("txt_price2").value; document.getElementById("txt_price2").value = 12; document.getElementById("txt_shipping").value = document.getElementById("txt_price2").value; document.getElementById("txt_price2").value = v1 * 20.95 * 1.0795 + 12.00; } } }; document.getElementById("combo_0").onchange = dropChange; document.getElementById("combo_1").onchange = dropChange; }; </script> <script type="text/javascript"> <!-- var spryselect1 = new Spry.Widget.ValidationSelect("spryselect1", {validateOn:["change"]}); var spryselect2 = new Spry.Widget.ValidationSelect("spryselect2", {validateOn:["change"]}); var sprycheckbox1 = new Spry.Widget.ValidationCheckbox("sprycheckbox1", {validateOn:["change"]}); var sprytextfield6 = new Spry.Widget.ValidationTextField("sprytextfield6", "none"); var sprytextfield5 = new Spry.Widget.ValidationTextField("sprytextfield5", "zip_code", {validateOn:["change"]}); var sprytextfield4 = new Spry.Widget.ValidationTextField("sprytextfield4", "none"); var sprytextfield3 = new Spry.Widget.ValidationTextField("sprytextfield3", "none"); var sprytextfield2 = new Spry.Widget.ValidationTextField("sprytextfield2", "none"); var sprytextfield1 = new Spry.Widget.ValidationTextField("sprytextfield1", "none"); var sprytextfield7 = new Spry.Widget.ValidationTextField("sprytextfield7", "none", {validateOn:["change"]}); var sprytextfield8 = new Spry.Widget.ValidationTextField("sprytextfield8", "currency", {validateOn:["change"]}); var sprytextfield10 = new Spry.Widget.ValidationTextField("sprytextfield10"); var sprytextfield9 = new Spry.Widget.ValidationTextField("sprytextfield9"); var sprytextfield11 = new Spry.Widget.ValidationTextField("sprytextfield11"); //--> </script> </body> </html> So I have a search function that searches through an XML file depending on which criteria the user wants to search. It works great so far in Firefox, OK in IE and not at all in Chrome. There's only one problem I have with IE which is you have to click submit, you cant hit the enter key to search. Is this fixable? Ive tried writing a function where if it detects the enter key press, it "clicks" submit, but that didn't work. In chrome, I search for something but it says there's nothing to be found. My code is below and any help or a point in the right direction would be greatly appreciated. Code: <script type="text/javascript"> if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari xmlhttp=new XMLHttpRequest(); } else {// code for IE6, IE5 xmlhttp=new ActiveXObject("Microsoft.XMLHTTP"); } function getType() { for (var i=0; i < 3; i++) { if (document.frmMain.criteria[i].checked) { var rad_val = document.frmMain.criteria[i].value; } } return rad_val; } window.onload = loadIndex; function loadIndex() { // load indexfile // most current browsers support document.implementation if (document.implementation && document.implementation.createDocument) { xmlDoc = document.implementation.createDocument("", "", null); xmlDoc.load("wdparts.xml"); } // MSIE uses ActiveX else if (window.ActiveXObject) { xmlDoc = new ActiveXObject("Microsoft.XMLDOM"); xmlDoc.async = "false"; xmlDoc.load("wdparts.xml"); } } function searchIndex() { // search the index (duh!) if (!xmlDoc) { loadIndex(); } // get the search term from a form field with id 'searchme' var searchterm = document.getElementById("searchme").value; var searchtype = getType(); var allitems = xmlDoc.getElementsByTagName("item"); results = new Array; if (searchterm.length < 3) { alert("Enter at least three characters"); } else { // see if the XML entry matches the search term, // and (if so) store it in an array \ for (var i=0;i<allitems.length;i++) { var name = allitems[i].getAttribute(searchtype); var exp = new RegExp(searchterm,"i"); if ( name.match(exp) != null) { results.push(allitems[i]); } } // send the results to another function that displays them to the user showResults(results, searchterm); } } // Write search results to a table function showResults(results, searchterm) { if (results.length > 0) { // if there are any results, write them to a table var reout = 'You searched for <b><i>'+searchterm+'</i></b><br><br>'; reout += '<table border="1" style="width: 100%;">'; reout += '<tr><th>Manufacturer</th><th>Product Number</th><th>Description</th><th>Link</th></tr>'; for(var i=0; i<results.length; i++) { reout += '<tr>'; reout += '<td>' + results[i].getAttribute("line") + '</td>'; reout += '<td>' + results[i].getAttribute("pnum") + '</td>'; reout += '<td>' + results[i].getAttribute("description") + '</td>'; reout += '<td>' + results[i].getAttribute("link") + '</td>'; reout += '</tr>'; } reout += '<table>'; document.getElementById('test').innerHTML = reout; } else { // else tell the user no matches were found alert('No results found for '+searchterm+'!'); } } </script> Code: <p><form name="frmMain" id="frmMain" action=""> <b>Search by: </b> <input type="radio" name="criteria" value="line" checked="checked">Manufacturer <input type="radio" name="criteria" value="pnum">Product Number <input type="radio" name="criteria" value="description">Description <br><br> <input id="searchme" type="text" size="20"> <input value="Search" id="btnSearch" onclick="searchIndex(); return false;" type="submit"> </form></p> <p id = "test"></p> </div> EDIT: I also noticed that if i have a description like "Aluminum painted brush", I can search single words("aluminum" or "brush"), or words next to each other ("aluminum painted" or "painted brush") but I cant search separate words like "aluminum brush" and have it return the item because their is another word between the two. How would I edit it so that I can return the item? I have a big issue. I am doing this: I have a menu and when you click tje linsk it loads content using jquery post into a div. It alway loads javascript with it. But I find when they click another menu item it loads a different section into the div along with different javascript. But the dom is still keeping the old javascript. After about 40 clicks the site wants to stop working. How can I resolve this? Thanks Hello, I've got a strange image with mouse overs on a menu. my code; Code: function SwapImage(strName,strImage){ ImageFlip= new Image() ImageFlip.src = "images/" + strImage; var strImageOn = document.getElementById(strName); strImageOn.src = ImageFlip.src; return true; } <table border='0' cellpadding='5' cellspacing='5'> <tr> <td width='33' onMouseOver=\"SwapImage('MenuItem1','MouseOver.png');\" onMouseOut=\"SwapImage('MenuItem1','MouseOut.png');\"><a href='/'><img src='images/home_btn.png' border='0' /></a></td> <td width='11'><img src='images/MouseOut.png' border='0' id='MenuItem1' /></td> </tr> <tr> <td width='33' onMouseOver=\"SwapImage('MenuItem2','MouseOver.png');\" onMouseOut=\"SwapImage('MenuItem2','MouseOut.png');\"><a href='/artwork.php'><img src='images/artwork_btn.png' border='0' /></a></td> <td width='11'><img src='images/MouseOut.png' border='0' id='MenuItem2' /></td> </tr> <tr> <td width='33' onMouseOver=\"SwapImage('MenuItem3','MouseOver.png');\" onMouseOut=\"SwapImage('MenuItem3','MouseOut.png');\"><a href='/artists.php'><img src='images/artists_btn.png' border='0' /></a></td> <td width='11'><img src='images/MouseOut.png' border='0' id='MenuItem3' /></td> </tr> <tr> <td width='33' onMouseOver=\"SwapImage('MenuItem4','MouseOver.png');\" onMouseOut=\"SwapImage('MenuItem4','MouseOut.png');\"><a href='/about.php'><img src='images/about_btn.png' border='0' /></a></td> <td width='11'><img src='images/MouseOut.png' border='0' id='MenuItem4' /></td> </tr> <tr> <td width='33' onMouseOver=\"SwapImage('MenuItem5','MouseOver.png');\" onMouseOut=\"SwapImage('MenuItem5','MouseOut.png');\"><a href='/links.php'><img src='images/links_btn.png' border='0' /></a></td> <td width='11'><img src='images/MouseOut.png' border='0' id='MenuItem5' /></td> </tr> </table> this is in a php page, thats the reason for the extra slashes/espaces. for some reason, only the last row of the menu works with the mouse over, maybe I'm missing something, but it seems like it should all work. any ideas would be really helpful. cheers, -Ken I had someone develop the javascript code to randomize the ads on my website: VillageOfManito dotcom and it worked great for many years. The ads were all contained in the left hand column which were called into the page via ASP code. Now I've been asked to split the ads into two columns, but when I divided the code and ads, the randomizer broke. See: VillageOfManito dotcom /template.asp You can also view the code for the columns he VillageOfManito dotcom /left_column.htm VillageOfManito dotcom /right_column.htm when I call up the individual columns (htm/javascript pages) by themselves, the randomizer works fine. the "break" occurs when the asp page is opened, where the 2 htm/javascript pages are called into the main page... are they causing conflict with each other? Hello, The code below assigns a value to the Latitude and to the Longitude table cells when the submit button is pressed. I would like to have these values appear in text boxes instead. Obviously I need to amend onclick="javascript:usePointFromPostcode(document.getElementById('postcode').value, placeMarkerAtPoint)" to make this work but I can't seem to. Assuming two text boxes with names lng and lat, how would I amend the line? Thanks Code: <p align="left"> <table bgcolor="#FFFFCC" width="300"> <tr> <td width="100"> <b>Latitude</b></td> <td id="lat"> </td> </tr> <tr> <td width="100"> <b>Longitude</b></td> <td id="lng"> </td> </tr> </table> </p> <p> Postcode: <input type="text" id="postcode" size="10" value="IG3 8PY" /><br /> <input type="submit" value="Find" onclick="javascript:usePointFromPostcode(document.getElementById('postcode').value, placeMarkerAtPoint)" /><br /> <div id="map" style="width: 500px; height: 500px"> </div> <p> <script src="http://maps.google.com/maps?file=api&v=2.x&key=ABQIAAAA43oi4HUU6ay_KI5aLlgqqxRs1CMn3rnBr6PSR_9LSokba_k_xRRX9T_bJ1PRZQ_1n4nF3EOK" type="text/javascript"></script> <br /> <script src="http://www.google.com/uds/api?file=uds.js&v=1.0&key=ABQIAAAA43oi4HUU6ay_KI5aLlgqqxRs1CMn3rnBr6PSR_9LSokba_k_xRRX9T_bJ1PRZQ_1n4nF3EOK" type="text/javascript"></script> <br /> <script src="gmap.js" type="text/javascript"></script> </p> </body> </html> |