Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Aug 8th, 2013, 8:09 PM   #1
Doonan
Newbie
 
Join Date: Jul 2013
Posts: 1
Rep Power: 0 Doonan is on a distinguished road
Need help with html/javascript

So, i'm very new to programming
Here is my code,
<!doctype html>
<html>
<head>
<script>
function convert ()
{

var c = prompt.window("enter celsius")
var f = c*(9/5 +32)

{
document.write("The temperature in fahrenheit is" +f)
}
}
</script>

</head>

<body>
<button type="button" onclick="convert ()">Calculate </button>

</body>
</html>
it's supposed to convert celsius to fahrenheit. Very simple but it doesn't work in its current state.
any help would be very appreciated.
Doonan is offline   Reply With Quote
Old Aug 8th, 2013, 10:25 PM   #2
Troncoso
Hobbyist Programmer
 
Join Date: Oct 2011
Posts: 127
Rep Power: 6 Troncoso is on a distinguished road
Re: Need help with html/javascript

It should just be

var c = prompt(blablabla)
Troncoso is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

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

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
HTML/Javascript help nathanlikesmoney HTML / XHTML / CSS 3 Feb 27th, 2012 1:21 PM




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 2:25 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC