Please don't do it off-list, several of us could be interested.
In case anyone is interested, as Claude recommended, It was relatively easy
to check for the foreign script injection by myturfads.com. There is a
test page with the code located at http://www.uxb.net/adtest/ that will look
to
Just throwing ideas out there. :)
All my pontificating aside for this particular purpose I am just trying to
detect if the string adx.myturfads.com exists anywhere on the DOM.
For my sister, I've already stopped it from loading by editing the hosts
file on the PC to disallow that domain.
Second, if you use TLS (SSL) exclusively, you should be able to prevent
this.
I tested for this and yes it does prevent it. However that is not actually
the point. The point is much bigger than the pennies they sole from my
websites ad revenue. Maybe I am the only one but to me this
: http://www.uxbinternet.com
W: http://www.ctbusinesslist.com
-Original Message-
From: Dave Watts [mailto:dwa...@figleaf.com]
Sent: Tuesday, March 3, 2015 8:08 AM
To: cf-talk
Subject: Re: (ot) JavaScript detecting foreign scripts
Second, if you use TLS (SSL) exclusively
, Wolcott, CT 06716 - T:203-879-2844
W: http://www.uxbinternet.com
W: http://www.ctbusinesslist.com
-Original Message-
From: Dave Watts [mailto:dwa...@figleaf.com]
Sent: Tuesday, March 3, 2015 8:08 AM
To: cf-talk
Subject: Re: (ot) JavaScript detecting foreign scripts
On Mon, Mar 2, 2015 at 8:52 PM, UXB Internet denn...@uxbinternet.com
wrote:
I apologize for this off topic post. A while back someone posted a thread
where they were working on a script that would enumerate the DOM and detect
foreign JS scripts running or loaded. I am looking to consult
I am looking to consult with that person off-list
Please don't do it off-list, several of us could be interrested.
I developped a client side javascript error trackink tool and it helped me a
lot to debug my scripts, but I get many errors happening in foreign JS scripts.
I fixed my program to
I developped a client side javascript error trackink tool and it helped
me a lot
to debug my scripts, but I get many errors happening in foreign JS
scripts.
I fixed my program to detect 5 or 6 of them and now the system is almost
perfect.
Should have known it was you smile. What is
It appears as if in some locations Comcast's proxies are intercepting
advertising scripts (google/doubleclick) and replacing them with their own
JS that substitutes their own contracted ads. I am looking for a way to
detect this on a test page to determine how wide spread the practice is.
Thanks Dave I do appreciate the information.
First, my understanding is that this only happens for users of Comcast
public
access hotspots, not for subscribed users:
http://arstechnica.com/tech-policy/2014/09/why-comcasts-javascript-ad-
injections-threaten-security-net-neutrality/
In
You could set different IDs for them, then reference these...
Something like
select name=ID id=sel1
option value=Please Select/option
option value=11/option
/select
select name=ID id=sel2
option value=Please Select/option
option value=11/option
/select
Why would you have two selects with the same name? Radio Buttons? Sure.
But not selects...
Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer
Co-Author of Learning Ext JS
http://www.packtpub.com/learning-ext-js/book
_
You can in FF3.
You have some typos that'll stop it working though.
A closing double quote for the name attribute in your selects.
You need a . in between the [0] options.
Have a look at using jQuery though. It'll make this code a lot smaller.
Adrian
-Original Message-
From: Chad
Are you the originator of the code? I mean can you change the source code?
Because having two objects on the page with the same ID is bad mojo. I think
you're going to run into lots of problems, and inconsistencies in different
browsers if you keep them named the same.
andy
-Original
Message-
From: Cutter (ColdFusion) [mailto:cold.fus...@cutterscrossing.com]
Sent: Thursday, July 30, 2009 11:38 AM
To: cf-talk
Subject: Re: OT javascript
Why would you have two selects with the same name? Radio Buttons? Sure.
But not selects...
Steve Cutter Blades
Adobe Certified
Chad...
Here's what I'd suggest...leave the name value as is, even though that's not
the best idea. Add an ID attribute to each, with an increasing numeric value:
cb1, cb2, cb3, etc.
Give each combobox the same class, comboBox or something like that.
Then, you could try something like this:
That's ok. Having duplicate names is cool.
Adrian
-Original Message-
From: Chad Gray [mailto:cg...@careyweb.com]
Sent: 30 July 2009 16:46
To: cf-talk
Subject: RE: OT javascript
When you submit it makes a comma delimited list of ID's that we loop
over and use.
Some pages
There's probably something in jquery that'll do it on one line of
cross browser code...
mxAjax / CFAjax docs and other useful articles:
http://www.bifrost.com.au/blog/
2009/7/9 Michael Muller mich...@mullertech.com:
Ok, I need some Javascript help.
I just cannot get this script (residing in
Someone told me that IE cannot talk to an embed tag, only an object tag, but
I believe
the ID vs NAME issue is tripping me up.
I don't think IE uses the EMBED tag at all. Give your OBJECT an ID of
its own, and use that when you're in IE.
Dave Watts, CTO, Fig Leaf Software
var myObj = {
variableA: 'some value',
variableB: 12,
variableC: function(){
// a function
}
};
I think, you'll want to test.
Steve Cutter Blades
Adobe Certified Professional
Advanced Macromedia ColdFusion MX 7 Developer
_
You can do this:
Var something = somethingelse = onemorething = 0;
-Original Message-
From: Ian Skinner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, November 12, 2008 1:34 PM
To: cf-talk
Subject: OT JavaScript question.
Quick question that I just can not think of the right terms to find
Or do you mean with?
with someObject {
var1 = not;
var2 = sure;
var3 = about;
var4 = this;
var5 = syntax;
var6 = or;
var7 = whether;
var8 = it's a JavaScript;
var9 = thing or not;
}
alert(someObject.var1);
Adrian
Building a
Adrian Lynch wrote:
Or do you mean with?
with someObject {
var1 = not;
var2 = sure;
var3 = about;
var4 = this;
var5 = syntax;
var6 = or;
var7 = whether;
var8 = it's a JavaScript;
var9 = thing or not;
}
alert(someObject.var1);
On Wed, Nov 12, 2008 at 1:14 PM, Ian Skinner [EMAIL PROTECTED] wrote:
Yes that is the one I was looking for!. I found 'with' to be a very
poor search term on Google, or any search engine for that matter.
heh. reminds me of http://bash.org/?514353 :)
--
I have failed as much as I have
-Original Message-
From: Ian Skinner [mailto:[EMAIL PROTECTED]
Sent: Wednesday, November 12, 2008 4:15 PM
To: cf-talk
Subject: Re: OT JavaScript question.
Adrian Lynch wrote:
Or do you mean with?
with someObject {
var1 = not;
var2 = sure;
var3 = about
I use this:
http://tredosoft.com/Multiple_IE
You can install 3.0 through 6.0 as stand-alone. I then have IE 7 as my
system install.
On Fri, Jul 11, 2008 at 6:30 PM, Claude Schneegans
[EMAIL PROTECTED] wrote:
You might want to take a look at IE7 stand alone.
I will sure do.
Thanks.
--
You can try this.
http://www.debugbar.com/
Hi, are you using it yourself?
I tried it, there are a lot of interesting options, however two main flaws:
1º the error message is still the same stupidity:
- it does not give the true file name the error occurs,
- it gives the line number, but
Actually I have it installed but I rarely use IE except for cross browser
css issues. (i.e. after I work out all the gremlins using Firebug). I have
yet to run into a IE only JS bug.
Here try CompanionJS. It is geared more toward JS debugging:
http://www.my-debugbar.com/wiki/CompanionJS/HomePage
Actually I have it installed but I rarely use IE except for cross browser
css issues.
I see. In my case, most my Javascript is used in my CMS used by
administrators,
and none of them use FF, so developing for IE is a must.
--
___
REUSE CODE! Use custom
Did you try CompanionJS? I think it is just what you need.
http://www.my-debugbar.com/wiki/CompanionJS/HomePage
~G~
On Fri, Jul 11, 2008 at 1:29 PM, Claude Schneegans
[EMAIL PROTECTED] wrote:
Actually I have it installed but I rarely use IE except for cross
browser
css issues.
I
Did you try CompanionJS? I think it is just what you need.
Ah ha! Now this looks better ;-)
Thanks.
--
___
REUSE CODE! Use custom tags;
See http://www.contentbox.com/claude/customtags/tagstore.cfm
(Please send any spam to this address: [EMAIL PROTECTED])
Subject: Re: (ot) javascript problem
You can try this.
http://www.debugbar.com/
Hi, are you using it yourself?
I tried it, there are a lot of interesting options, however two main flaws:
1º the error message is still the same stupidity:
- it does not give the true file name the error occurs
I haven't worked with DebugBar itself, yet, but Companion.JS that works
with it was helpful in my case - not perfect but helpful. (Better than
nothing, certianly.)
If you are not already aware of it, the tool of choice for many developers
is Firebug: http://getfirebug.com/
It is absolutely
Companion.JS that works with it was helpful in my case - not perfect
but helpful. (Better than nothing, certianly.)
I tried it, but unfortunately it requires the MS debugger, and for some
reason,
I've never been able to get this piece od ?%$! to work under IE6.
All I get is a new window with
You might want to take a look at IE7 stand alone. It allows you to run IE 6
and 7 on the same machine.
http://tredosoft.com/IE7_standalone
I need to support both IE 6 and 7. This allows you to run both side by side.
Very handy.
~G~
On Fri, Jul 11, 2008 at 4:57 PM, Claude Schneegans
[EMAIL
You might want to take a look at IE7 stand alone.
I will sure do.
Thanks.
--
___
REUSE CODE! Use custom tags;
See http://www.contentbox.com/claude/customtags/tagstore.cfm
(Please send any spam to this address: [EMAIL PROTECTED])
Thanks.
On Tue, Jul 8, 2008 at 6:42 AM, Stephens, Larry V wrote:
I'm using a DHTML javascript menu (from DynamicDrive) that works fine in
Mozilla (shows no errors in the error console). The sample works fine in IE
but my revision (no
Thanks again for all the suggestions.
I figured it out by taking
You can try this.
http://www.debugbar.com/
On Tue, Jul 8, 2008 at 8:42 AM, Stephens, Larry V [EMAIL PROTECTED]
wrote:
I'm using a DHTML javascript menu (from DynamicDrive) that works fine in
Mozilla (shows no errors in the error console). The sample works fine in IE
but my revision (no
If things aren't working after you made a change, show us a before and after
sample of the code.
Adrian
-Original Message-
From: Stephens, Larry V [mailto:[EMAIL PROTECTED]
Sent: 08 July 2008 13:43
To: CF-Talk
Subject: (ot) javascript problem
I'm using a DHTML javascript menu (from
Any clues on how to trace javascript errors in IE?
Error messages in IE are simply retarded.
The error could be in any file, and it does not even give the file name.
Furthermore, the line number is always one unit higher.
Then your error must be in one of the included files, at line 347.
--
Thanks - installing now.
-Original Message-
From: Gerald Guido [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 08, 2008 8:58 AM
To: CF-Talk
Subject: Re: (ot) javascript problem
You can try this.
http://www.debugbar.com/
On Tue, Jul 8, 2008 at 8:42 AM, Stephens, Larry V [EMAIL PROTECTED
The best means I have found of working out JS errors in IE is to create
a project in Visual Web Developer 2008 (free). Launch the project which
will open a browser window (IE needs to be set as your default browser)
then navigate to your page. When the error occurs choose to debug the
error,
IE JS errors suck...it's almost impossible to debug. Your best bet then is
to start commenting out lines, or chunks, of code (including JS includes).
At the very least it should help you narrow down your issue. You could also
extract the content from your included files one at a time, and replace
Look for a trailing comma in a javascript array perhaps? That one
gets me in IE every once in a while.
On Tue, Jul 8, 2008 at 6:42 AM, Stephens, Larry V wrote:
I'm using a DHTML javascript menu (from DynamicDrive) that works fine in
Mozilla (shows no errors in the error console). The sample
On Tue, Jul 8, 2008 at 6:42 AM, Stephens, Larry V wrote:
I'm using a DHTML javascript menu (from DynamicDrive) that works fine in
Mozilla (shows no errors in the error console). The sample works fine in IE
but my revision (no
Thanks for all the suggestions.
I installed the debug bar that
Maybe:
this.resizeTo(Wdth,Hght)}
to
this.resizeTo(Wdth,Hght);
}
and
this.style.zIndex=RcrsLvl+Ztop}
to
this.style.zIndex=RcrsLvl+Ztop;
}
On Tue, Jul 8, 2008 at 11:53 AM, Stephens, Larry V [EMAIL PROTECTED] wrote:
On Tue, Jul 8, 2008 at 6:42 AM, Stephens, Larry V wrote:
I'm using a
try document.getElementById(FTDTYPEe). And then go get some library
that will take care of all that for you (jQuery, Prototype, etc.).
cheers,
barneyb
On Wed, Jun 11, 2008 at 10:34 AM, Chad Gray [EMAIL PROTECTED] wrote:
Can any javascript gurus tell me why this does not work? I want the br
because br isn't an element of form?
try removing the tabbedTicket or use getElementById
On Wed, Jun 11, 2008 at 12:34 PM, Chad Gray [EMAIL PROTECTED] wrote:
Can any javascript gurus tell me why this does not work? I want the br tag
to display on the page so I get a carriage return between
I may be way off-base, but do you need that trailing e in FTDTYPEe?
Could it be the missing e from Firbug?
m!ke
On Wed, Jun 11, 2008 at 10:34 AM, Chad Gray [EMAIL PROTECTED] wrote:
Can any javascript gurus tell me why this does not work? I want the
br tag to display on the page so I get a
There's an easier way to do this...
Rather than using a br and assigning an id to it, use a div. Divs have built
in properties that aren't included in br tags.
-Original Message-
From: Chad Gray [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 11, 2008 12:34 PM
To: CF-Talk
Subject: (ot)
Quite a few issues there...
First off, you can generally use one or the other of visibility or
display properties. In your case you'd probably want to use display
since this will actually create or destroy the space that the br occupies.
Then, in makeNewEntry you'd want this one line:
Ah... that makes sense.
Thanks everyone for the help!
-Original Message-
From: Greg Morphis [mailto:[EMAIL PROTECTED]
Sent: Wednesday, June 11, 2008 1:39 PM
To: CF-Talk
Subject: Re: (ot) javascript help
because br isn't an element of form?
try removing the tabbedTicket or use
window.open()
most popup blockers will block it though.
..:.:.:.:.:.:.:.:.:.:.:.:.
Bobby Hartsfield
http://acoderslife.com
http://cf4em.com
-Original Message-
From: Che Vilnonis [mailto:[EMAIL PROTECTED]
Sent: Friday, May 16, 2008 4:14 PM
To: CF-Talk
Subject: (ot) Javascript
Thanks. Because of popup blockers I guess a regular href will have to do.
-Original Message-
From: Bobby Hartsfield [mailto:[EMAIL PROTECTED]
Sent: Friday, May 16, 2008 4:21 PM
To: CF-Talk
Subject: RE: (ot) Javascript Question...
window.open()
most popup blockers will block it though
In Ext, the Element class has built-in methods to get just about
anything you need from an element, including position info.
http://extjs.com/deploy/dev/docs/?class=Ext.Element
jQuery, out of the box, can provide offset, width and height only and
enhanced capabilities via the dimensions
Doesn't sound fun though-- maybe someone will post and show us a
pre-built function in the prototype library or something. :)
Many libraries include a method to get the coordinates of any element.
Right now I am thinking just about the one available in Mootools:
-Original Message-
From: Rey Bango [mailto:[EMAIL PROTECTED]
Sent: Tuesday, February 12, 2008 3:50 PM
To: CF-Talk
Subject: Re: OT Javascript - when is an element visible
In Ext, the Element class has built-in methods to get just about
anything you need from an element, including
I'm not sure if scrollTop is part of the spec for DOM (or widely
supported -- innerHTML for example is not but widely supported).
Assuming that scrollTop is supported in the browser though, I'd think
something like this might work:
var ct = container.scrollTop;
var ch = container.offsetHeight;
I know there is a JS method called .scrollIntoView() (IE only??) which
will cause the an element to scroll to where it is visible. Not sure
how to tell if it is visible though. I suppose if you know the edges of
the viewable area, you can calculate the position of the element in
question via its
I would like to make javascript that when the window.onUnload is
fired to pop up a confirm() saying hey if you leave now your form
information will not be saved. Do you wish to continue?. But I think
once onUnload fires there is no stopping the user from leaving the
page. Can you cancel
dealey [mailto:[EMAIL PROTECTED]
Sent: Friday, February 01, 2008 3:49 PM
To: CF-Talk
Subject: Re: OT: javascript to keep a user from navigating away
I would like to make javascript that when the window.onUnload is
fired to pop up a confirm() saying hey if you leave now your form
information
missing a comma after left=450 ?
On 8/21/07, Steve LaBadie [EMAIL PROTECTED] wrote:
I have created a mouse over effect and it works fine. The only problem
I am having is that the top= in the below example does not work in
Firefox. Are there any ideas to resolve this issue? The window stay
in this case, you don't need 'foo'. just 'moo'. even though they
could be in different forms, an id value should not be repeated on a
page.
so...
function disabler(textInputID) {
document.getElementById(textInputID).style.disabled=true;
}
form id=foo
input type=text id=moo /
input
: Thursday, May 17, 2007 9:26 AM
To: CF-Talk
Subject: Re: OT: javascript
in this case, you don't need 'foo'. just 'moo'. even though they could be
in different forms, an id value should not be repeated on a page.
so...
function disabler(textInputID) {
document.getElementById(textInputID
On 5/17/07, Daniel Baughman [EMAIL PROTECTED] wrote:
I'm pretty sure you want
document.getElementById(textInputID).disabled =
true
not
document.getElementById(textInputID).style.disabled
= true;
indeed. sorry 'bout that.
return false in your a href tag.
a href=# onclick=doFunction(args); return false;foo/a
On 12/19/06, Joshua Cyr [EMAIL PROTECTED] wrote:
I am playing with YUI and spry and have a fun task of having content from
other pages load into a tab system in spry. All is working well so far.
Next I
, December 19, 2006 1:48 PM
To: CF-Talk
Subject: Re: OT: javascript to prevent a normal link from working
return false in your a href tag.
a href=# onclick=doFunction(args); return false;foo/a
On 12/19/06, Joshua Cyr [EMAIL PROTECTED] wrote:
I am playing with YUI and spry and have a fun task of having
]
Sent: Tuesday, December 19, 2006 2:00 PM
To: CF-Talk
Subject: RE: OT: javascript to prevent a normal link from working
Ah, but these are links I have no control over from other pages. The trick
is that they are just normal pages that are pulled in to the tab.
Joshua Cyr
Savvy Software
Dave Francis wrote:
Hi,
I have a window from which I open pop-up with JS window.open();. When I
close this pop-up - self.close(); - is there any way to force a refresh of
the parent window?
opener.window.location.reload()
Well, that was quick. Thanks Jim
-Original Message-
From: Jim Wright [mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 20, 2006 9:43 AM
To: CF-Talk
Subject: Re: OT: Javascript - Refresh a window
Dave Francis wrote:
Hi,
I have a window from which I open pop-up with JS
[mailto:[EMAIL PROTECTED]
Sent: Wednesday, September 20, 2006 8:43 AM
To: CF-Talk
Subject: Re: OT: Javascript - Refresh a window
Dave Francis wrote:
Hi,
I have a window from which I open pop-up with JS window.open();. When I
close this pop-up - self.close(); - is there any way to force
I should have replied earlier, but for the sake of completeness, the
Brainjar.com menu has always helped me out, we've even integrated it in
our CMS. Check it out at: http://www.brainjar.com/dhtml/menubar/ There
are other menu's out ther that have a smaller footprint, or some that
have an
Mingo,
Thanks, that looks really nice. I'll keep that in mind for the future.
But for right now, I found something really simple. An almost entirely CSS
solution, which much less Javascript to worry about.
Ali
I should have replied earlier, but for the sake of completeness, the
The Brain Jar menu carries a GNU General Public License. To quote from it:
2. b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third
Matt Robertson wrote:
The Brain Jar menu carries a GNU General Public License. To quote from it:
2. b) You must cause any work that you distribute or publish, that in
whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no
Thanks for all the fish
Actually I kind of figured this out.
I found some free CSS menus, which via-css convert an Unordered List to an
invisible Iframe, so now the drop-downs display over the select boxes an
IFrames.
Ali
Ali,
I've used a trick to get drop downs to float over select
Ali,
I've used a trick to get drop downs to float over select boxes in IE.
The trick is to put an relatively positioned empty iframe behind each
one of your drop down menu.
On 7/14/06, Ali Awan [EMAIL PROTECTED] wrote:
I know this is not a CF question, but since this list has a lot more
jsdomenu from dynamic drive does that, I think.
It's pretty cool, but leaks memory, I think.
One option is to use hidden fields and mouseovers to have dynamic variables.
Let me know if you want more info, I've done something similar.
:D
On 6/2/06, Andy Matthews [EMAIL PROTECTED] wrote:
I've
nevermind, it works now, i guess i had another problem the day i was testing
this, and that was not the issue.
it works all good.
thanks!
tony
On 5/25/06, Tony [EMAIL PROTECTED] wrote:
Hi there... this should be quick and easy for you Jscript ninja's...
in this line:
try dropping #chr(10)# into the string, I think that will work.
might be nicer to set one display variable earlier
cfset infoText = url.address chr(10) url.city chr(10)
then you can just refer to #infoText in the js.
On 5/25/06, Tony [EMAIL PROTECTED] wrote:
Hi there... this should be
true.
its still very alpha stage...
but its very simple to change to that!
good idea.
tw
On 5/25/06, Michael Traher [EMAIL PROTECTED] wrote:
try dropping #chr(10)# into the string, I think that will work.
might be nicer to set one display variable earlier
cfset infoText = url.address
the most I can think of is to evaluate the value right at the function
declaration:
objA.onclick = eval ('function(){ alert( ' + intI + ' ); };');
On 4/20/06, Ben Nadel [EMAIL PROTECTED] wrote:
Not really for CF, but though someone here could lend some insight
There is one problem in
-Original Message-
From: Zaphod Beeblebrox [mailto:[EMAIL PROTECTED]
Sent: Thursday, April 20, 2006 10:31 AM
To: CF-Talk
Subject: Re: OT: Javascript help
the most I can think of is to evaluate the value right at the function
declaration:
objA.onclick = eval ('function(){ alert( ' + intI
Asking your question of my javascipt list, the responses were as follows:
Repsonse 1
Have you tried this?
objA.onclick = new Function (alert( + intI + ) );
Response 2
for (var intI = 0 ; intI 10 ; intI++){
var objA = document.createElement( div );
Place one var objA; before the
Hi Ben,
I ran into this problem recently - these really helped me out:
http://joust.kano.net/weblog/archive/2005/08/08/a-huge-gotcha-with-javascript-closures
and
http://jibbering.com/faq/faq_notes/closures.html
/t
~|
to an object that doesn't inherently have that
attribute.
...
Ben Nadel
www.bennadel.com
-Original Message-
From: Cutter (CFRelated) [mailto:[EMAIL PROTECTED]
Sent: Thursday, April 20, 2006 1:00 PM
To: CF-Talk
Subject: Re: OT: Javascript help
Asking your question of my
, April 20, 2006 1:19 PM
To: CF-Talk
Subject: Re: OT: Javascript help
Hi Ben,
I ran into this problem recently - these really helped me out:
http://joust.kano.net/weblog/archive/2005/08/08/a-huge-gotcha-with-javascrip
t-closures
and
http://jibbering.com/faq/faq_notes/closures.html
/t
Does anyone have any ideas about this? I've talked to two other js guys and
none of us can figure out what's going wrong. I'd really appreciate some input.
Thanks.
You have to be careful what IE and Firefox calls a child node. IE only makes
element child nodes, FF makes everything,
I'd suggest adding in an additional check.
if ( ci.name != undefined ci.style )
ci.style.display = none;
-Original Message-
From: Andy Matthews [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 02, 2006 4:17 PM
To: CF-Talk
Subject: OT javascript Q: Show/hide
: RE: OT javascript Q: Show/hide divs...works in IE, not in FF.
Does anyone have any ideas about this? I've talked to two other js guys and
none of us can figure out what's going wrong. I'd really appreciate some
input. Thanks.
You have to be careful what IE and Firefox calls a child node. IE
So can you test for node.name?
Yes I often do something like:
if (something.childnode[i].nodeName == P)
do something to a paragraph node.
You can also use the test suggested by Steve.
if ( ci.name != undefined ci.style )
ci.style.display = none;
Or of couse combine both
Andy Matthews wrote:
function switchDiv(pNode,name) {
var pNode = document.getElementById(pNode);
for (i=0;ipNode.childNodes.length;i++) {
ci = pNode.childNodes[i];
if (ci.name != undefined) {
ci.style.display = none;
:10 PM
To: CF-Talk
Subject: Re: OT javascript Q: Show/hide divs...works in IE, not in FF.
Andy Matthews wrote:
function switchDiv(pNode,name) {
var pNode = document.getElementById(pNode);
for (i=0;ipNode.childNodes.length;i++) {
ci = pNode.childNodes[i
try this:
var xmlFile=C:\\test\\menu.xml;
I am successfully parsing an XML document using the javascript below. I am
running into trouble, however, when I try to parse an xml file that doesn't
exist in the same directory as the calling page. See inline comments below.
Good suggestion, but no dice; same error as the C:/\test/\menu.xml
attempt...
-Original Message-
From: Robert Munn [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 04, 2005 10:28 AM
To: CF-Talk
Subject: Re: OT: Javascript XML parsing
try this:
var xmlFile=C:\\test\\menu.xml
: Robert Munn [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 04, 2005 10:28 AM
To: CF-Talk
Subject: Re: OT: Javascript XML parsing
try this:
var xmlFile=C:\\test\\menu.xml;
~|
Discover CFTicket - The leading ColdFusion Help Desk
Well that certainly makes sense now that I consider it. Thanks!
-Original Message-
From: Robert Munn [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 04, 2005 12:12 PM
To: CF-Talk
Subject: Re: OT: Javascript XML parsing
Oh, brain fart, sorry. Your browser doesn't know about the drive
Does it matter if you put the element ID in quotes?
getElementById(CurrentHighlightedCell)...
- Jim
Jeff W wrote:
Can anyone tell me WHY this won't work in NS6.1 but work fine in ie5-6,
firefox and NS8??
document.getElementById(CurrentHighlightedCell).style.background='#006600';
NS6 was a bastard that didn't work. Did you try backgroundColor?
cheers,
barneyb
On 8/11/05, Jeff W [EMAIL PROTECTED] wrote:
Can anyone tell me WHY this won't work in NS6.1 but work fine in ie5-6,
firefox and NS8??
document.getElementById(CurrentHighlightedCell).style.background='#006600';
if it's a literal ID value, then yes, he'd need quotes. I'm guessing
it's a variable.
Try backgroundColor (note the casing) instead of background.
On 8/11/05, Jim Campbell [EMAIL PROTECTED] wrote:
Does it matter if you put the element ID in quotes?
1 - 100 of 376 matches
Mail list logo