Here are 3 test results - they show what the internal values are for your variables and why they don't match
formattedDate =[3/23/2008 15:34]
e=[Sun Mar 23 15:34:00 EDT 2008]
f=[3/23/2008]
formattedDate =[3/23/2008 15:34]
e=[Sun Mar 23 15:34:00 EDT 2008]
f=[3/23/2008 15:34:00]...
Both suggestions will do the trick.
I offer the following only because it catches some additional date errors - and can be used in conjunction with Date object test.
NOTE - It does not validate the timestamp portion.
Based loosely on a forum FAQ ... I enhanced a date validation function...
One minor alternate suggestion to consider:
If you want to simplify work done by regular expression,
I would split the string on the decimal place character, and check the resulting array length (max 2).
Each array item can then be stripped of non-digits and the array re-joined into a string...
In IE this works:
<script>
function accept(){
return '* * Warning - You will lose your updated page contents * * ' ;
// force msg to modal dialog to accept exit from this page
}
</script>
<body onbeforeunload="return accept();">
This concept may be extended to allow
- a variable character (not just a literal constant value) to be counted
- multiple characters to be counted
I am shaky about RegExp ... and there may be a better way tha eval to make it variable ... so I am open to suggestions.
Here goes:
<body>...
Depends what your goal is.
A swear words filter may indeed be "easily breakable", but it is not always useless.
Granted, if you are looking for a foolproof way to detect deliberate culprits - it is not the way.
It has proven to be a god-send to some people.
Occasionally people in the heat...
(1) I have seen pages with too many issues with IFRAMES (pages even blow up if too many).
Please help me understand whether you could consider avoiding igframes and placing the image in an IMG as part of a link to the page.
I am thinking of something like:
<a href="www.google.com"...
You have to attach the new values to then form when the radio button changes.
Here is a starter: (insert after your first line below)
queryform.g.checked = true;// Check the Google option by default.
queryform.g.onclick = seteng0 ...
The website page is framed, there are no tables in the outermost frameset. Hence 0.
The frames are named: container, header, main and bottom.
By the way ... You can get the frame map of any page by running this bookmarklet...
MS-IE has a lot of trouble with the NAME attribute on dynamic elements.
See: http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/reference/properties/name_2.asp
YOUR VERY COOL CODE WORKS when you replace the create with the following statement...
I hope I get your gist, excuse my stumbling if I do not.
I had a lot of trouble with "rather than redirecting". It seems to me that this rules out the most direct solution.
maybe I do not understand you goal.
If a framed webpage is placed in the main window location URL - it will load as an...
Your example is too skimpy to be sure I am on the right track. Let me take a stab at helping.
(NOTE: This forum deals mainly with actual javascript issues, not asp functionality relating to placement of scripts. the asp forum may be more skillful at this)
Nonetheless, you may be helped by...
Let's tackle this in three steps:
(1) Find the presented image size,
so that you can refer to both the Bottom Right and the Upper Left Corners.
(2) Convert your grid position numbers
(relative to Bottom Right Corner BRC)
to the ones you need to set for the...
I want to traverse and inspect all current style properties of an object.
If it can be done, please tell me how.
The code I tried to obtain all style properties:
var traceAlerts = new Array(0);
var xmlDoc = xmloceaniframe.document.getElementById("xmlocean")...
I see 2 suggestions:
(a) add 1 to the getMonth() value - it is 0 to 11 not 1 to 12 as you want.
(b) multiply months by 100 not 1000
That should provide the right result.
Too many layers of coding for me.
I checked the base construct and it works ... if you put data in the contracted div and if the div is given a background color it becomes obvious that no issue exists at the basic level.
So either the data you put in the DIV is wierd (I got rid of that...
You have the answer. And it's a good one !
For the record, the issue with the original code was:
if (document.form1.select1.selectedIndex.value='USA'){
Requires dual equal signs for condition.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.