User Name Password Register
DaniWeb IT Discussion Community
All
What is DaniWeb IT Discussion Community?
You're currently browsing the JavaScript / DHTML / AJAX section within the Web Development category of DaniWeb, a massive community of 397,609 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,577 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our JavaScript / DHTML / AJAX advertiser: Lunarpages Web Hosting
Views: 759 | Replies: 2 | Solved
Reply
Join Date: Oct 2007
Location: USA
Posts: 6
Reputation: angelinajade is an unknown quantity at this point 
Rep Power: 0
Solved Threads: 0
angelinajade's Avatar
angelinajade angelinajade is offline Offline
Newbie Poster

Help Javascript newbie help!

  #1  
Oct 27th, 2007
quick question, I am a newbie, first with this site, and with programming. this is my first semester and I am learning the basics. I am having a problem with Javascript. this simple code is supposed to just create a web page with the tile , my name and then I am supposed to add text to the page (using astericks), according to the visitor input information. I have the code working to the point of asking which object (right trangle, left triangle, isoceles triangle or rectangle), I have it then alerting the question about the height of the object, (the while loop i have in there set to give an invalis response it working well, the problem I have it getting the actual text on the page in the shape of the object as astericks, anytime I use the document.write(), i get a number (from the user) that screams across the page and gives me a scriptting error. This is probably something simple, dont laugh too hard. O have tried several different ways and used the w3schools website for more info and cant seem to get this to work. any suggestions, maybe another website with more examples.

thanks ahead of time for the help

Angela
AddThis Social Bookmark Button
Reply With Quote  
Join Date: Feb 2006
Posts: 1,363
Reputation: masijade is a jewel in the rough masijade is a jewel in the rough masijade is a jewel in the rough masijade is a jewel in the rough 
Rep Power: 8
Solved Threads: 117
masijade's Avatar
masijade masijade is offline Offline
Nearly a Posting Virtuoso

Re: Javascript newbie help!

  #2  
Oct 27th, 2007
JavaScript != Java

This is the Java forum, not the JavaScript forum. The designers did not just simply forget to include "Script" in the name, they are really two different things.

Next time post into the JavaScript forum. I have already asked the moderators to move this thread.
Java Programmer and Sun Systems Administrator

----------------------------------------------

Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
Reply With Quote  
Join Date: Jan 2007
Posts: 2,524
Reputation: MidiMagic is on a distinguished road 
Rep Power: 7
Solved Threads: 105
MidiMagic's Avatar
MidiMagic MidiMagic is offline Offline
Posting Maven

Re: Javascript newbie help!

  #3  
Oct 28th, 2007
Let's see the relevant part of the code.

I have a few thoughts:

- Could the problem be an "unable to render as instructed" case? If your designed shape doesn't fit in the available space, the browser will alter the rendering.

- Could it be a 'condensing whitespace" case? The browser will throw away all whitespace except one blank character, unless you specifically tell it not to.

- Could it be a problem with a variable-width font? Spaces are not the same width as asterisks in most fonts.

- Is the browser substituting fonts? Remember that each user can pick his own default rendering font. Also remember that your chosen font might not exist on the user's computer.
Daylight-saving time uses more gasoline
Reply With Quote  
Reply

Only community members can participate in forum threads. You must register or log in to contribute.

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 

DaniWeb JavaScript / DHTML / AJAX Marketplace
Thread Tools Display Modes

Similar Threads
Other Threads in the JavaScript / DHTML / AJAX Forum

All times are GMT -4. The time now is 7:38 pm.
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC