1,330 Posted Topics

Member Avatar for jasystweb

Jasystweb, How did you discover the inserted DIV tags; View Source or by inspecting the DOM? [QUOTE=AOlevel1;1153783]IE could be seeing extra child nodes from white space and not traversing the DOM as you intend.[/QUOTE] Surely it's Moz browsers (notably FF) that suffer from seeing white space and not behaving as …

Member Avatar for Airshow
0
241
Member Avatar for freggel2

freggel2, You need to style the document(s) that appear in the iframe with a black background, rather than the iframe itself. [B]Airshow[/B]

Member Avatar for Airshow
0
617
Member Avatar for albertkao

Albertkao, All your checkboxes have the same name ("checkboxChoice") and all your hidden fields have the same name ("checkboxvalue"). Browser behaviour is undefined (and therefore unpredictable) when form element names are dulpicated (except for radio buttons formed into mutually exclusive groups by giving all members of the group the same …

Member Avatar for Airshow
0
121
Member Avatar for styles_p

Styles_p, This is more of an ASP.NET question than Javascript/DHTML/AJAX. I think you will find that most folks who monitor this section (myself included), won't have a clue about ASP.NET. As far as I can tell, you can't mix and match raw html with asp: controls. They appear to be …

Member Avatar for vsmash
0
166
Member Avatar for gunnarflax

Gunnarflax, Most object-oriented languages have Classes; reusable blocks of code which define a named collection of properties and methods. Once a Class is defined, one or more instances thereof can be created with a code statement, typically of the form [ICODE]foo = new Bar(param1, param2 ....)[/ICODE];, where [ICODE]Bar[/ICODE] is the …

Member Avatar for vsmash
0
351
Member Avatar for iggy248

HTML/Javascript has no universal native support for drag & drop so you need to either write your own drag & drop functions (not recommended) or use a javascript productivity suite such as jQuery/Prototype/MooTools. With a bit of luck you will find a worked example somewhere on the web to do …

Member Avatar for Airshow
0
147
Member Avatar for MDanz

Easiest way is probably to insert a test into the mouseover handler(s) such that they return immediately when the popup is displayed, without performing their normal action. For example: [CODE]function mouseOverHandler(){ var popup = document.getElementById('popup'); if(popup && popup.style.display == 'block') { return; } // ............... // normal action // ............... …

Member Avatar for Airshow
0
116
Member Avatar for lam3r4370

You probably want to use jQuery's [URL="http://api.jquery.com/serializeArray/"].serializeArray()[/URL] method. The examples in the API should be enough to get you started. [B]Airshow[/B]

Member Avatar for Airshow
0
81
Member Avatar for bogdanxpose

I can't debug this but I can help you to do so. What you need is a debug strategy. The way I would do it is as follows: [LIST=1] [*]Browse the page [*]View source, select all, copy then paste into a new document. [*]Save as "debug.html" [*]Inspect the javascriopt & …

Member Avatar for Airshow
0
79
Member Avatar for cloud09

Aha, that won't work because [ICODE]name[i] = this.value;[/ICODE] will use the vlue of [ICODE]i[/ICODE] at the time of execution of the anonymouis function, not the value at the time the function is created. There's a number of ways round this. If you have time, read [URL="http://www.jibbering.com/faq/faq_notes/closures.html"]this[/URL], in particular the examples …

Member Avatar for Airshow
0
91
Member Avatar for alipica

[QUOTE=alipica;1149922]When I click from my homepage to the portfolio page is when it loads the content twice. Let me know if you need more info. I still have no clue what's happening! I've googled everything I could think of...[/QUOTE] Hard to say why it does that double load thing. I …

Member Avatar for alipica
0
2K
Member Avatar for ausmaya

It is a tribute to FF's tollerance to bad HTML that MyrtleTurtle got this to run without modification. [LIST] [*]<body> tag : missing > [*]onLoad attribute in <body> tag : missing " [*]<table> tag : not closed, missing </table> [/LIST] Also, those old MM_ functions are really looking their age …

Member Avatar for preetg
0
81
Member Avatar for albertkao

Mmmmm, HTML 5. Possibly OK for [U]intranet[/U] apps where you have knowledge of every browser in use but not yet for general internet deployment. Read [URL="http://www.nczonline.net/blog/2009/07/21/introduction-to-sessionstorage/"]here[/URL] for a reasonable discussion. [B]Airshow[/B]

Member Avatar for Airshow
0
75
Member Avatar for josephmcnelis

Before you do anything else, replace those “angled quotes” in the css with "straight'ns". [B]Airshow[/B]

Member Avatar for josephmcnelis
0
103
Member Avatar for albertkao

I don't know how tablekit's sort function works but I can make a shrewd guess that it is initialised with the id/class of the relevant table(s), and thereafter uses Javascript reference(s) to the corresponding DOM element(s) (probably stored in a closure). Your first AJAX blitz the original DOM elements (everything …

Member Avatar for Airshow
0
374
Member Avatar for dhananjaigaur

For ideas try [URL="www.csszengarden.com"]www.csszengarden.com[/URL]. [B]Airshow[/B]

Member Avatar for Airshow
0
27
Member Avatar for sassenach

The probelm could be something to do with [CODE] //GET - user submitted data using AJAX //POST - in case user does not support javascript, we'll use POST instead[/CODE] which is followed by a block that handles $_POST but not $_GET. Therefore if your web page submits via GET method, …

Member Avatar for Airshow
0
150
Member Avatar for blur_guava

[QUOTE=blur_guava;1145550]... I want the user to be able to click on an "X" beside every File Upload control, so that it will close those unnecessary (or unused) FIle Upload controls.[/QUOTE] You could do that but what about the case where a user opens more controls than he uses and fails …

Member Avatar for Airshow
0
318
Member Avatar for jeeter19

I think you will find that $_COOKIE, $_POST and $_GET (and others?) are not super-globals, therefore you must put [ICODE]global $_COOKIE;[/ICODE] inside functions (which have their own scope). [B]Airshow[/B]

Member Avatar for Airshow
0
133
Member Avatar for ganeshhsk

Because the event handler [ICODE]onChange="showCustomer6(document.myform1.project.value)"[/ICODE] is specified within the <select name="project"> tag you can simplify it to [ICODE]onChange="showCustomer6(this.value)"[/ICODE]. However, it seems more likely that your problem is caused by non-inclusion of the js file containing function showCustomer6(){...}. Is the path to the .js file correct in the tag [ICODE]<script ... …

Member Avatar for ganeshhsk
0
216
Member Avatar for Mike516

[QUOTE=Mike516;1144408]... executing a query in javascript...[/QUOTE] If you mean an SQL query then it will typically be performed server-side. I can't think of a context in which Javascript would be used to perform an SQL query though Javascript could initiate such a query via Ajax (or possibly ActiveX) and receive …

Member Avatar for Airshow
0
90
Member Avatar for PierlucSS

Given that the Ajax call might fail, you presumably want to set the checkmark to green only when the Ajax call has signalled that it has successfully completed. So I think what you need is to pass [ICODE]this[/ICODE] (as an additional parameter) into PutParam(), such that PutParam() knows which DOM …

Member Avatar for Airshow
0
112
Member Avatar for bananasplitkids

When I wrote a JavaScript card game several years ago, I came to the rapid conclusion that the only realistic way to manage it was to have constructor functions for Game, Pack, Suit, Stack, Card, with (multiple) instances of each. Internally, each instance: a) cross-referred to other instances by means …

Member Avatar for Airshow
0
92
Member Avatar for zm15

ZM, You need to give your page a doctype statement - right at the top. Any of these works for me (in IE 6): [CODE]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"--> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <!DOCTYPE html PUBLIC …

Member Avatar for kateross
0
147
Member Avatar for jrw89

JRW, In javascript [ICODE]function x(){...}[/ICODE] and [ICODE]var x = function(){...}[/ICODE] do exactly the same thing - namely define a function named x. From this, you will see that your second use of "compatibilityCheck" overwrites the first (without throwig an error). Your code makes a good a attempt at defining a …

Member Avatar for jrw89
0
127
Member Avatar for vgkarthi

VG, I think you will have to post some code before anyone can say what is wrong with it. [B]Airshow[/B]

Member Avatar for SKANK!!!!!
0
4K
Member Avatar for shridharmaster

In a stylesheet, urls are relative to the sheet itself, not to the html page on which the sheet is incuded. This allows a single stylesheet to be valid for inclusion on html pages in directories at any level. If "style sheet file is in the APP_THEMES folder and images …

Member Avatar for Airshow
0
91
Member Avatar for jagadeshms

Jagadeshms, I would suspect [ICODE]document.getElementsByName()[/ICODE]. I confess I've never used it and as far as I can recall, it doesn't get a mention in my DOM reference book (I'm currently away from home), and though it is in a W3C recommendation, I can't get it to work (not even in …

Member Avatar for Airshow
0
137
Member Avatar for jreddick82

Pop up marketing is about as unfriendly as it gets, which is why most users have a pop-up blocker installed. This is not the way to go either for you or your visitors. I think you should find a more more modern way to do it. [B]Airshow[/B]

Member Avatar for hielo
0
162
Member Avatar for jino

Jino, I'm not sure that jquery will handle this but there's a simple workaround based on the ability of HTML/DOM elements to have more than one class. So arrange for all the relevant divs to have an additional class name, eg. [ICODE]<div class="msg_body msg_body_3">[/ICODE] then select with [ICODE]$(".msg_body")[/ICODE]. That should …

Member Avatar for ShawnCplus
0
154
Member Avatar for kelvin33

Kelvin, Both JS and HTML can be be simplified considerably by looping, firstly to build the questions table, then to scan it when the "Update" button is pressed. [CODE=html] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title>survey2</title> <style> body, td { font-family:arial; } #questions_table { } #questions_table …

Member Avatar for Airshow
0
295
Member Avatar for pavithraCS

The RSS specification includes a Time To Live (<ttl>) element, which is an optional sub-element of <channel>, indicating the time in minutes that "a channel can be cached before refreshing from the source". This is the best clue you have as to the period your FF extension should use between …

Member Avatar for Airshow
0
84
Member Avatar for lifeworks

Lifeworks, In Javascript, you can indeed pass a function, both as an argument or as a returned result. This is because Javascript functions are "first-class objects" (see [URL="https://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Functions"]here[/URL] for example). A more typical ajax caller might look something like this: [CODE]function ajaxCall(url, successFn, failFn) { var httpRequest = GetXmlHttpObject(); if(!httpRequest) …

Member Avatar for lifeworks
0
81
Member Avatar for grungina

Grungina, Could be something to do with [ICODE]body's padding:5em 0 0;[/ICODE]? Pleased to see someone using a sprite. Great technique. [B]Airshow[/B]

Member Avatar for macneato
0
153
Member Avatar for newto

Newto, If you rephrase your code as follows (without actually changing anything), then you can see that only [ICODE]visa[/ICODE] gets attached. [ICODE]dolj[/ICODE] is never attached and never called. [CODE]function borja(){ var vanster = document.getElementsByTagName("h2"); for (i=0; i<vanster.length; i++){ vanster[i].nextSibling.nextSibling.className = "osynlig"; vanster[i].onclick = (vanster[i].nextSibling.nextSibling.className=="osynlig") ? visa : dolj; } } …

Member Avatar for newto
0
197
Member Avatar for Tekkno

Tekkno, The code can be made much simpler by framing the whole thing inside one function, for example an anonymous window.onload function, like this: [CODE=javascript] var $ = function(id){ return (document.getElementById) ? document.getElementById(id) : (document.all) ? document.all[id] : (document.layers) ? document.layers[id] : (window.opera) ? window.opera[id] : null; } window.onload = …

Member Avatar for Airshow
0
258
Member Avatar for CFROG

CFrog, First thing to check is that your document(s) have a valid doctype: For HTML: [CODE]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">[/CODE] For XHTML: [CODE]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">[/CODE] If in …

Member Avatar for CFROG
0
128
Member Avatar for pradeepktg

Pradeepktg, Use [ICODE]parentNode[/ICODE] rather than [ICODE]parentElement[/ICODE]. This will work in both browsers without needing to branch. [B]Airshow[/B]

Member Avatar for Airshow
0
116
Member Avatar for barjlund

There is a number of ways to do this. Here are a couple: Rule based (prepend "big_"): [CODE=javascript] function visa(){ var imgUrlArray = this.src.split('/'); imgUrlArray[imgUrlArray.length-1] = 'big_' + imgUrlArray[imgUrlArray.length-1]; open(imgUrlArray.join('/')); } [/CODE] Non rule based, with large image url coded as a custom attribute of the img tag: [CODE=javascript] function …

Member Avatar for barjlund
0
136
Member Avatar for hsthompson

HST, Like all things javascript, there are many ways to do this. Here's one (below). I'm pretty sure it's is not fully working but certainly offers a framework for monitoring multiple files. [CODE] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <style type="text/css"> .fNameDiv { margin: 10px 0 …

Member Avatar for Airshow
0
103
Member Avatar for MatrixClaw

[link] .... What game of hangman? All I get is advertising with more advertising in a popup!!!! No game. [B]Airshow[/B]

Member Avatar for Airshow
0
128
Member Avatar for weasel7711

Unfortunately, you have to loop to pick up the checked value from a radio group. AFAIK, there's no convenient method as for select menus. Try this: [CODE] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>MVC Student Information System - Search</title> <script type="text/javascript"> function …

Member Avatar for Airshow
0
172
Member Avatar for Roebuc

There's so much code there, I can't really work out what you are trying to do. Can you provide more explanation please and/or a complete page (as far as you have developed it). [B]Airshow[/B]

Member Avatar for Airshow
0
242
Member Avatar for stevenpetersen

Steven, That's 339 lines of javascript. How is anyone supposed to know why, where or how to add ajax-loader.gif to it with such a rudimentary introduction? [B]Airshow[/B]

Member Avatar for stevenpetersen
0
212
Member Avatar for muralibobby2015

What Bob says, plus ...... Typically, registration validation emails are in plain text and include a hyperlink which is displayed in a clickable form by most modern email clients (some of which may allow this feature to be turned off). No Javascript is necessary. The hyperlink will contain all the …

Member Avatar for almostbob
0
414
Member Avatar for BlackPhoenix

To inspect the data, you could do something like this: [CODE] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html> <head> <title>Airshow :: Untitled</title> <style type="text/css"> {} </style> <script> function viewData(dataString, headingsArray, containerID){ //Prepare the data var dataArray = dataString.split(";"); for(var i=0; i<dataArray.length; i++){ dataArray[i] = dataArray[i].split(','); } //Create Table …

Member Avatar for Airshow
0
125
Member Avatar for dougcb68

[ICODE]<body onload="initPhotoShow("<?php $inStr=$_GET['showName']; echo $showName; ?>")">[/ICODE] looks very suspicious. What does the served version of this line look like? [B]Airshow[/B]

Member Avatar for Airshow
0
207
Member Avatar for Mapper99

Mapper, Your onerror handler does nothing more than return (into a big void) the url of your default image. A return from a function attached as an event handler is completely meaningless because there's nothing (other than inaccessible native code) to receive the returned value. No error is thrown to …

Member Avatar for Airshow
0
209
Member Avatar for rouse

Rouse, Please, STOP CODING AND DO SOME READING - for about a day. You need to look at the jquery documentation and some examples. In particular you need to learn how to frame your code in a structure of the form: [CODE=javascript]$(document).ready(function() { // put all your jQuery goodness in …

Member Avatar for rouse
0
205
Member Avatar for eantz

Eantz, Sorry, I'm not sure I fully understand but here's my best guess ..... [ICODE]alert[/ICODE] is a native javascript function and as such doesn't have a [ICODE]title[/ICODE] (as do some HTML elements). The appearance/format of a javascript alert popup is browser-dependant and is not under programmatic control (except for the …

Member Avatar for Airshow
0
152

The End.