/    Sign up×
Community /Pin to ProfileBookmark

2 of my unsolve error in firefox javascript console…can help me?

In my javascript console, i got this 2 error msg…

top.frame2_2.document.getform1 has no properties Line:159

So, my coding is follwing…

if (top.frame2_2.document.form1.MEDIATYPE[1].checked) {
basket[basket.length].MEDIATYPE=1;
} else {
basket[basket.length].MEDIATYPE=0;
}


—————————————————————————————————-

Selector expected.Ruleset ignored due to bad selector. Line: 30

#itemcnt {position:absolute; top:0.3in; left:0.1in; text-align:center; z-index:4;}

to post a comment
JavaScript

9 Comments(s)

Copy linkTweet thisAlerts:
@MongusJun 08.2006 — If you copied and pasted your code directly the lines you posted aren't generating those errors.

The first error is from something trying to reference getform1 but the code you posted isn't trying to reference getform1.

The second error looks like you're trying to use invalid characters in a selector. #itemcnt is perfectly valid so that's not where the error is coming from. I would guess that the error is within a line or two above the one you posted.

Line numbers aren't always exactly right but they often will give you the general area to look. If you want to post the whole thing I can better help you.
Copy linkTweet thisAlerts:
@shean71authorJun 08.2006 — u try to using IE and FF to open it, then u will know what is my serious problem that i can't solve.

[upl-file uuid=2ccc0643-7a4f-439a-8f68-7ea7b68eb0b8 size=63kB]test_roc_js.zip[/upl-file]
Copy linkTweet thisAlerts:
@MongusJun 08.2006 — Notice the semicolon at the end of line 29 in general.css? That's not a valid selector. ?

The other error looks like there's a naming conflict. If you use top.frame2_2.document.forms['form1'].MEDIATYPE[1] it will work. There appears to be a different object assigned to top.frame2_2.document.form1. If you inspect it you'll find it's a NodeList instead of an HTMLFormElement.

I changed line 132 in ctos-roc_search.js to if (top.frame2_2.document.forms['form1'].MEDIATYPE[1].checked) {and it worked.

P.S. It looks like you're using VIM for editing. Good choice! ?
Copy linkTweet thisAlerts:
@shean71authorJun 08.2006 — After i had change the coding follow ur idea.But it still remain the same problem in here.Because it still keep on repeat the information if i open with firefox.... Do u mind to resubmit ur worked file to me.
Copy linkTweet thisAlerts:
@MongusJun 08.2006 — No problem. Here's the files I updated.

[upl-file uuid=cbc3bb0a-2253-4f5b-a07e-7c8b1d53efdf size=7kB]updates.zip[/upl-file]
Copy linkTweet thisAlerts:
@shean71authorJun 08.2006 — it is still have the same problem when display in firefox... Actually u open with IE or firefox? Anyway, you are very polite and helpful.
Copy linkTweet thisAlerts:
@MongusJun 08.2006 — I'm using Firefox 1.5.0.4 on Windows XP. I did get exactly the same errors as you with your original files and now with the updated files the errors are gone. Are you sure you're using the updated files? Could Firefox be pulling the files from somewhere other than where you think it is?
Copy linkTweet thisAlerts:
@shean71authorJun 08.2006 — U got try to run my system after u use the updated file? i used ur updated files to

replace my old file? is it will have problems? u sent ctoc_reg.js and general.css right? i

replace this 2 files into the old file. But the system still remain the same problem in my

firefox...im also using de same firefox with urs...in window xp.

How about you send the whole system file for me?

Can you? this problem cause i can't sleep well for 3 days...coz i can't solve it...and my customer said must need to use firefox.... :-(
Copy linkTweet thisAlerts:
@MongusJun 08.2006 — A little more testing showed there are several places that you were using document.form1. I replaced several of them with document.forms['form1'] but I may not have gotten all of them.

I put the current files online at [URL=http://www.scriptingmagic.com/Forums/test_roc_js/roc_main.html]ScriptingMagic.com[/URL] .
×

Success!

Help @shean71 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.29,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...