473,326 Members | 2,127 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

NodeValue

15
Hi

Can somebody advise if I can / how to do something like this:

getNodeValue.....add this to something.....than set added value to the Node.

Basically, the CityName displays correctly (onclick update). I have a value stored in the CityTime that equals the difference in hours between GMT/UTC and the time for the city (e.g. Frankfurt = 1).

How do I add this to a UTCString to get the actual value and than return this to the Node? Is it possible?

Ive tried many different functions but can't get any positive results. Can this be done? Do I need to change my approach?

Expand|Select|Wrap|Line Numbers
  1. function showCityInfo(form)
  2. {
  3. var cIndex = -1; // Selected city
  4. cIndex = form.selCityList.selectedIndex;
  5.  
  6. // Update city info fields with selected city data
  7. setNodeValue("CityName", cityData[cIndex].name);
  8. setNodeValue("CityTime", cityData[cIndex].time);
  9.  
  10. }  
  11.  
Thanks
Oct 9 '07 #1
1 1258
acoder
16,027 Expert Mod 8TB
Use the Date object's setUTC* methods.
Oct 10 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Deryck | last post by:
Hi, I am trying to update part of a webpage using javascript. The bit that gets updated will have a variable number of links written to it. I have done this successfully by rewriting the whole...
1
by: Stone Chen | last post by:
Hello, When I try to insert this line of code into my script, Firefox refuses to render. Could someone explain to me why that is? if (x.firstChild.firstChild.nodeValue==productID) { some code...
14
by: madtom1999 | last post by:
I'm trying to put a non-breaking space ( or any other entity for that matter) into a node eg: node.nodeValue+='&nbsp'; however the actual code is written in the html -ie it displays as >&nbsp;<...
2
by: pascalwitzig | last post by:
Hi Guys, I'm a newbie to XML so I tried to create my first "hello-world". Actually I already failed here. The Code returns 'null'. I'm aware of the white-space bug and I actually think, that I...
1
by: Michael Landberg | last post by:
Hi I am looking for the other properties of nodeValue. I know only firstChild.nodeValue and lastChild.nodeValue. What other properties are there? Is there a property whit which I can get a...
1
by: yawnmoth | last post by:
What's the difference between the DOMNode proprties of nodeValue and textContent?
7
by: yawnmoth | last post by:
http://www.frostjedi.com/terra/scripts/demo/xml.html The first alert() shows the XML that the server is returning. The second alert() shows a particular elements nodeValue and, as you can see,...
7
by: Adam David Moss | last post by:
All, Long time since I've done some proper coding in ASP and I've hit a wee snag that has got me baffled. Well two actually but the other is to do with running pages under Sun ASP so we'll not...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.