|
Did you set the height for your element?
<div id="myelement" style="height:100px;" />
|
|
|
|
|
no, there is no size set for the element. at runtime, I fill it in with text and its size changes based on how much text is used.
I need to find out dynamically what the actual size turned out to be.
|
|
|
|
|
Dave Calkins wrote: there is no size set for the element. at runtime
If you don't set the height explicitly, you will get nothing from style.height. So, As Slang suggested, try to use clientHeight and offsetHeight..
|
|
|
|
|
Thanks, yes, clientHeight worked.
|
|
|
|
|
Check out the clientHeight[^] and offsetHeight[^] properties. With a bit of thought, you can probably make them work for what you need.
As Michael mentioned, you'll need to set an explicit height in order to use the style.* properties.
----
...the wind blows over it and it is gone, and its place remembers it no more...
|
|
|
|
|
Thanks! The clientHeight did the trick and seems to have worked in both IE and FireFox Adding more text to the element, which caused it to grow, resulted in the larger size being provided in clientHeight.
Interestingly, I have the O'Reilly Javascript book and it says nothing about this property. I'm not complaining of course, as the code is now working
|
|
|
|
|
We have a winform application which connects to the sql server through webservice. Some of the clients are in different time zone. The problem we run into is when client gets a date from the server, sometime the date is wrong. Since there is no date only data field in SQL, we store the date as 12/05/2007 00:00:00 which almost everybody does. The problem comes when the data was written to the server from a client in east coast and read by a client in west coast. Let say the SQL server is in east coast. The client store 12/05/2007 00:00:00 into the server, when the client in west coast read the data, he got 12/04/2007 21:00:00. That's a day behind!
Does anyone know of a solution to this?
|
|
|
|
|
Actually, you should convert all of your date as GMT date before inserting into the database..
|
|
|
|
|
i have sucessfully created a login system that enables users to register and login using visual studion 2005. It works fautlessly on the local machine. However when i run it remotely i get an error. the details of the error are not displayed to me. It is obviously a problem with IIS configuration???? can anyone help please.
|
|
|
|
|
solarthur01 wrote: when i run it remotely
running remotely means
1) accessing your webproject that is hosted on my machine from other's machine?
then, it might be because of firewall. Please turn off your firewall.
2) you move your project to server and you can't access your webpage?
then, have you configured to run the ASP.NET on your IIS? In Windows 2003 server, there is one more additional step to enable the ASP.NET.
|
|
|
|
|
while uploading am reading a file into byte[] and inserting into the database...
can i download the particular file from the byte[] without saving the file locally
|
|
|
|
|
choorakkuttyil wrote: can i download the particular file from the byte[] without saving the file locally
What do you want to do after downloading the file as byte[] data from Database?
|
|
|
|
|
I have coded a page to pop up a new window in the following way:
window.open("testing.htm","now","height=350,width=250,alwaysLowered=0,alwaysRaised=0,channelmode=0,dependent=0,directories=0,fullscreen=0,hotkeys=1,location=0,menubar=0,resizable=0,scrollbars=0,status=0,titlebar=1,toolbar=0,z-lock=0");
Clicking the button that opens the window while the window is currently open will not bring an additional window but, it will overwrite(not sure what action its doing) the values in the controls like text boxes. And not only that the window also goes minimised. Is there a way to bring it back maximised?
Please help.
|
|
|
|
|
If you want to open a new window, use "_blank" as the name.
If you're ok re-using the existing window but just wish to bring it to the foreground, call the focus() method on the object returned from window.open() :
var win = window.open(...);
win.focus(); BTW - generally, you can just avoid referencing options you do not want instead of explicitly setting them to 0.
----
...the wind blows over it and it is gone, and its place remembers it no more...
|
|
|
|
|
Thank you very much shog
One more question is it possible to check whether a window with a particular name already exist or not without using the reference to that window?
|
|
|
|
|
hi
how can be checked email id exist or not
with domain name
I will appreciate.....
You get the best out of others when you give the best of yourself.
|
|
|
|
|
If you have the right to access the Email server then you can get the list of Email addresses that are host in that server.. Otherwise, you can't... so, you may have to do trial-and-error
|
|
|
|
|
Hi All,
I want to change text in my html page to the language selected by the user in his/her PC.
how can i do this
im using only HTML and javascript(no asp.net)
With Regards
Amjath
|
|
|
|
|
Amjath Rahman wrote: im using only HTML and javascript(
You can get the client's IP address by using Javascript. (The fact whether JS can get the correct IP address or not is the different story. Generally, you can get it with JS.) then, In order to know the client's country based on IP address, you should the countries list and IP addresses range for all countries.. OR you can use the free service like GeoDirection[^] to get the country name based on the IP address. then, you can redirect the HTML page that is already localized. (example[^])
|
|
|
|
|
Hi,
I have a very long aspx page where i have some links followed by the description for those link headings. When i click the link in the top the focus has to go to the description mentioned some where below and vice versa. How can i achieve it.
|
|
|
|
|
Add a unique ID to the element at the bottom of the page. The link at the top can then refer to this using the # anchor and when clicked it will jump to your element.
For example:
<a href="#my_jump">Link at top</a>
blah
blah
<h3 id="my_jump">Thing at bottom</h3>
|
|
|
|
|
hi
1. how can be resized the web page.
2. how can I design the menu control like yahoo.com,google.com ...
recently I'm working on live project....
thanks 'n' regards
Harry
You get the best out of others when you give the best of yourself.
|
|
|
|
|
|
I have a strange problem that only happens with IE. Other browsers do not exhibit this problem and it seems to be because of caching.
I am displaying a video and it plays just fine when the page is first loaded. If I refresh the page the rendering stops just after the masthead image is rendered and the rest of the page doesn't get rendered.
If I go in to internet options and delete files the page works again for the first time but if I refresh it the rendering stops again after the masthead.
I tried not caching the page, both using meta tags and HTML headers and this doesn't fix the problem.
Below is the code I am using.
<br />
<?php<br />
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");<br />
header("Cache-Control: no-cache");<br />
header("Pragma: no-cache");<br />
?><br />
<br />
<meta http-equiv="Pragma" content="no-cache" /><br />
<meta http-equiv="Cache-Control" content="no-cache" /><br />
<meta http-equiv="Expires" content="Mon, 26 Jul 1997 05:00:00 GMT"><br />
I don't know anything else to try. Does anyone have any idea why IE would be caching the page in spite of headers saying not to?
The website is WebNationVideo.com
|
|
|
|
|
how can check the input data is character or numeric if input data accept the numeric and input data is character then error message
sanjeev
|
|
|
|