/    Sign up×
Community /Pin to ProfileBookmark

Can anybody help me answer some of these questions?

So I’m taking my first JavaScript class in school and the semester is very close to being over.
I have a lot of work to catch up on and my teacher isn’t the best professor.

Right now I have 6 questions left to answer before I try to start working on my actual programs, but I can’t really figure out the answers to them.

The questions are:

[I]1.Explain how to simulate limited dynamism and interactivity with simple hypertext links.

2.Why do you need to use the getElementById (), getElementByName (), or getElementByTagName () method?

3.Explain why you would use the sub expression.

4.How do you use DHTML to show and hide an underline beneath an <a> element when a user places his or her mouse pointer over a link?

5.Explain the difference between the display and visible properties.

6.Explain how to create traveling animation with DHTML.[/I]

You can be as descriptive as you want, as even a one sentence answer should be useful.
So if anyone would be so kind as to help me out with any of these questions, you’d be saving me from one extra step that would contribute to the loss of my sanity..because quite frankly this stuff is really confusing to me.

to post a comment
JavaScript

4 Comments(s)

Copy linkTweet thisAlerts:
@mrhooDec 02.2009 — 

# 5 should be, display and [B]visibility[/B], not visible.



The sub expression and travelling animations are terms specific to your class-

you must've had your ipod on, saving your sanity, when it was brought up in class.

Can't be too careful with your sanity- a mind is a terrible thing to use.

I bet you wish your name was hoppy...
Copy linkTweet thisAlerts:
@crh3675Dec 02.2009 — 1.Explain how to simulate limited dynamism and interactivity with simple hypertext links.

[I]If that actually made sense, I could help with the answer[/I]

2.Why do you need to use the getElementById (), getElementByName (), or getElementByTagName () method?

[I]This is rudimentary, learn it[/I]

3.Explain why you would use the sub expression.

[I]There is a "method" called "sub()" but if you use it in the real world, you will be shot because it has absolutely no use since it was added to Internet Explorer 3. (What the hell are they teaching you in school?)[/I]


4.How do you use DHTML to show and hide an underline beneath an <a> element when a user places his or her mouse pointer over a link?

[I]You don't. You use CSS :hover pseudo class.[/I]

5.Explain the difference between the display and visible properties.

[I]Since "visible" is only available in Netscape Navigator 4.0 (visibility="visible") (circa 1997), it has no relevance to modern internet browsers. "display" on the other hand is not a property but a CSS style rule.[/I]

6.Explain how to create traveling animation with DHTML.

[I]You don't. With modern internet Javascript libraries, you use built-in functions to animate the top and/or left position of a given DOM element[/I]

Truthfully, if this is the CRAP that they are teaching you in school, you might as well be learning FORTRAN!
Copy linkTweet thisAlerts:
@mvbf987authorDec 02.2009 — I managed to get something down for these with your help crh3675. But your comment at the end made me think. I mean if what we're "learning" isn't even right, then why bother with it?

The professor doesn't even teach us anything anyway, so actually mrhoo, it hardly was brought up. I can see why you'd think it would be though..considering it is a school, where beginners are supposed to be taught the subject matter. But no. It's pathetic.

Anyway thanks for the help. Hopefully I can at least get the credits for this class and maybe just get a book and teach myself afterwards.
Copy linkTweet thisAlerts:
@KorDec 02.2009 — some comments:

  • 1. [B]crh3675[/B] is absolutely right. What, for God's sake, means: [I]"to simulate limited dynamism"[/I] ? Or [I]"limited interactivity"[/I]? With [I]"simple hypertext links"[/I]? I wonder how a complex one could look like :rolleyes:


  • 2. The methods are getElement[B][COLOR="Blue"]s[/COLOR][/B]ByName() and getElement[B][COLOR="Blue"]s[/COLOR][/B]ByTagName(). They return always [I]collections[/I] of elements.


  • And the question "Why do you need to use ..." is absolutely silly. I could have answered : "Why not?" The referential methods are the basis of JavaScript - before doing anything with some document's elements, you must refer those elements, a way or another. Before aiming a target you must know where that target is.

  • 6. You can't. At least you can not a full [I]traveling[/I] animation on using external objects (images). All you can do is to move them on a 2D dimension plane, from a x1:y1 position to another x2:y2 position. And even there you can not rotate, skew or distort them. And changing their size will make the images out of shape or deformed. So far (at a cross-browser level), JavaScript is limited within this sort of movements.
  • ×

    Success!

    Help @mvbf987 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 6.2,
    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: @meenaratha,
    tipped: article
    amount: 1000 SATS,

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

    tipper: @AriseFacilitySolutions09,
    tipped: article
    amount: 1000 SATS,
    )...