3,892 Posted Topics

Member Avatar for samarudge

[URL="http://developer.mozilla.org/en/docs/DOM:window.setTimeout"]setTimeout [/URL]executes a given piece of code / a function after a given amount of time, though not repeatedly. For that, there is always [URL="http://developer.mozilla.org/en/docs/DOM:window.setInterval"]setInterval[/URL].

Member Avatar for ~s.o.s~
0
114
Member Avatar for jsl11

> I've come up with a solution and now I'm addressing the issue of mozilla and ie rendering > different results on getYear. [URL="http://www.quirksmode.org/js/introdate.html"]Linky[/URL]

Member Avatar for ~s.o.s~
0
122
Member Avatar for reezin14

[quote=Ancient Dragon;295750]Nothing wrong with it, its just that nobody outside educational instutions use it.[/quote] Not completely true. Though Lisp has come to a stage where its name is not heard in the mainstream software senario like that of Python or C# or Java, but its still out there, live and …

Member Avatar for swaira umar
0
589
Member Avatar for satigid

Try using [URL="http://tuckey.org/urlrewrite/"]UrlRewriteFilter [/URL]for serious uses or using a servlet for controller and making appropriate entry in the [ICODE]web.xml[/ICODE] file. With URLRewrite it would be something along the lines of: [code] <rule> <from>^/products/([0-9]+)$</from> <to>/products/index.jsp?product_id=$1</to> </rule>[/code] For e.g. suppose you have a controller which handles the application flow, the web.xml would …

Member Avatar for ~s.o.s~
0
147
Member Avatar for satheeshmanian

> even null is not equal to null [code]window.alert(null === null);[/code] There ya go!

Member Avatar for MattEvans
0
317
Member Avatar for Dave Sinkula

Yes, the concept seems to be useful, at least for those who are new to forum based systems though the downside here is that regular posters will have to go through an extra click to post their replies.

Member Avatar for WaltP
0
123
Member Avatar for SonxQ7

> Note that setSize() is not a member of ConfirmExitDialog() but inherited from a super > class... now "this" is used to access it??? [ICODE]this [/ICODE]simply stands for the reference to current instance in consideration. The execution of setSize() is no different than [ICODE]this.setSize()[/ICODE] for the very same reason. They …

Member Avatar for Alex Edwards
0
164
Member Avatar for jeetudaljit

Using normal HTML with embedded JSP tags. Take a look at the generated HTML markup by JSF and you will get a fair idea of how things are rendered under the hood.

Member Avatar for ~s.o.s~
0
65
Member Avatar for antwan1986

[code]> document.getElementById("ContactFormDiv").insertBefore(loadingImg, ContactForm); [/code] Where have you defined ContactForm?

Member Avatar for antwan1986
0
2K
Member Avatar for guravharsha

> So much nicer if data would be retrieved from DB in servlet, Not to mention that actually *nothing* should go in servlet except the processing of request parameters / attributes and invocation of the actual business logic components. This helps in ensuring that you don't repeat yourself when the …

Member Avatar for guravharsha
0
136
Member Avatar for macupryk
Member Avatar for DrWhoFan

> If not, why haven't developers pushed to have such an object created Pop-ups are a usability concern and are almost always handed by different browsers and specialized pop-up blockers in different ways. What would you gain from detecting whether pop-ups are blocked or not? If navigate the user to …

Member Avatar for DrWhoFan
0
98
Member Avatar for Alex Edwards

> I really like the idea of pieces not being capable of moving but knowing their legal moves. I am yet to see a game where the pieces don't move. Each and every piece is capable of moving though the set of legal moves differ from game to game. IMO, …

Member Avatar for Ezzaral
0
2K
Member Avatar for yenyen

Your best bet would be to intercept the point in the data flow which is causing this behavior. Before sending the Ajax request, do an alert and see whether is it an issue with the data being passed to the server. Try logging the data received at the server to …

Member Avatar for ~s.o.s~
0
90
Member Avatar for jakesee

> is not standard function avoid to use this. On the contrary, [URL="http://www.w3.org/TR/DOM-Level-2-HTML/html.html#ID-71555259"]it is.[/URL]

Member Avatar for jakesee
0
5K
Member Avatar for nav33n

This bug has already been brought up in the Mod section with still no reply. Maybe solving that thread will solve this one too.

Member Avatar for nav33n
0
76
Member Avatar for anuj_sharma

Javascript has variables, no? You can use them to maintain the state of your calculator app.

Member Avatar for R0bb0b
0
83
Member Avatar for GooberKing

> I've been banging my head against the wall all week on this, and I don't think I have much > skull left! Here, I will put you out of your misery. :-) Anyways, the bug in the program is pretty apparent here given that you make use of global …

Member Avatar for ~s.o.s~
0
89
Member Avatar for kishor_agrawal

AFAIK, there is no reliable way of capturing the page unload event hence not possible. The maximum you can do is come up with some browser specific mumbo jumbo which would surely fail in other browsers. The only reliable way is to keep sending postbacks to the server using Ajax …

Member Avatar for R0bb0b
0
117
Member Avatar for vit0

> Add a counter pause/unpause button. Set a Javascript variable which would be checked before invoking your countdown function. As soon as the 'Pause' button is clicked, set the flag variable, store the state of your counter variables and clear the timeout. As soon as the 'UnPause' button is clicked, …

Member Avatar for ~s.o.s~
0
147
Member Avatar for Keased

A solution has already been suggested to you. Move the dynamically generated Javascript out of the looping construct. To understand more, take a look at the generated source code by navigating to 'View' -> 'View Source' in Firefox.

Member Avatar for ~s.o.s~
0
84
Member Avatar for rejisha

> concentrate on eval() function in javascript by googling As in concentrate on swatting a fly with a hammer? [ICODE]eval [/ICODE]sort of fires off a mini-compiler which dynamically evaluates the string passed to it. Look for better ways of doing things and use [ICODE]eval [/ICODE]only when required. E.g. when evaluating …

Member Avatar for ~s.o.s~
0
157
Member Avatar for TheBuzzer

Glassfish is a full fledged application server while Tomcat is just a servlet container. The choice of which to use depends on your purpose of using the same.

Member Avatar for ~s.o.s~
0
62
Member Avatar for ghostrecog

> unable to swap images using arrays in javascript Not surprising considering that the [ICODE]marquee [/ICODE]tag is non-standard, deprecated and has no [ICODE]onclick [/ICODE]attribute.

Member Avatar for Troy III
0
164
Member Avatar for xaippo_script

...or just look at the Error Console in Firefox to get the most out of the goodies provided out-of-the-box with your browser. If you still can't pinpoint the cause, step by step debug using Firebug is the way to go.

Member Avatar for R0bb0b
0
132
Member Avatar for Diode

If you are pulling data from the server on fly using Ajax, you can't use events like [ICODE]onload [/ICODE]since there is as such no page refresh / loading happening here. This is the very reason why the dynamic content can't be seen in the static source. To view the modified …

Member Avatar for R0bb0b
0
166
Member Avatar for edek

I doubt the above code would even work in FF2 considering that you explicitly need to pass the event when registering the handler. [code]<a href="#" onclick="doSomething(event);">[/code]

Member Avatar for Troy III
0
105
Member Avatar for iamthwee
Member Avatar for sciwizeh

[URL="http://www.daniweb.com/forums/showpost.php?p=646185&postcount=13"]The One?[/URL]

Member Avatar for sciwizeh
0
82
Member Avatar for hooray

A simple script like this should do the job. Do keep it mind that it can be made better in a lot of ways but for your purpose it should serve well enough: [code] <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <meta http-equiv"Script-Content-Type" content="text/javascript"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> …

Member Avatar for hooray
0
168
Member Avatar for jakesee

Firefox comes with an excellent debugging utility called Firebug which you can put to your use in this case. Also, the problem might lie in the code which changes the [ICODE]INPUT [/ICODE]element to [ICODE]SELECT[/ICODE]. How are you making the switch? Are you removing the old element and adding a new …

Member Avatar for jakesee
0
148
Member Avatar for dips255

Firefox comes with a pre-packaged feature called Error Console (Tools -> Error Console) which highlights all the Javascript errors on your web page. You can also grab hold of Firebug, an advanced Javascript debugging utility which is a Firefox plugin.

Member Avatar for adaykin
0
112
Member Avatar for adaykin

Look into HTML DOM classes [URL="http://www.w3schools.com/HTMLDOM/dom_obj_table.asp"]Table, TableCell and TableRow[/URL].

Member Avatar for adaykin
0
131
Member Avatar for LevelSix

Also make sure you completely understand the implications of storing the contents of the entire file in a StringBuilder instance since this technique might just result in the entire file contents being loaded in memory which becomes a big issue for huge text files. Consider using a buffer which reads …

Member Avatar for LevelSix
0
1K
Member Avatar for devisrimari

> Error: document.getElementById(treeid) has no properties It simply means that no such object with the ID as 'treeid' (or if 'treeid' is a variable, then the value 'treeid' holds) exists in the document tree.

Member Avatar for kceleb9
0
90
Member Avatar for adaykin

Maybe something like this snippet will help you getting started. Ensure that the elements you are trying to access are form fields enclosed in the form tag. [code]<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <meta http-equiv="Script-Content-Type" content="text/javascript"> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Example</title> <script type="text/javascript"> /** * A placeholder …

Member Avatar for ~s.o.s~
0
140
Member Avatar for andy_aphale

You seem to be thoroughly confused there. Firstly, HTML is a markup language and used as a presentation layer technology. You don't connect to databases using HTML; you need a general purpose programming language like C/C++/Java/Ruby/Python to connect to databases. Google for 'HTML Tutorial' and start reading...

Member Avatar for andy_aphale
0
83
Member Avatar for CoolGamer48

> This would probably make your life a bit easier. And learning Java a bit tougher...

Member Avatar for ~s.o.s~
0
99
Member Avatar for konky911

> Can anyone help? Yes, only if you first post your attempt. If you are new to Javascript, start by googling Javascript tutorials and then giving it a try.

Member Avatar for ~s.o.s~
0
38
Member Avatar for JDOMPer

And how is it different from dynamically writing out JavaScript which developers have been using for times unknown? Plus Ajax is a different beast altogether dealing with shipping data to and fro *after* the entire page has been loaded in a manner which doesn't force a browser refresh. So yeah, …

Member Avatar for JDOMPer
0
483
Member Avatar for punithapary
Re: js

Put in simple terms, both are comparison operators of Javascript with the difference being that === is a type safe / type aware operator. If two operands are of the same type and same value, only then the === returns true. Whereas, in case of == if the two operands …

Member Avatar for ~s.o.s~
0
75
Member Avatar for mcx76

Look into [ICODE]window.open[/ICODE] and [ICODE]window.onload[/ICODE] for achieving your objective.

Member Avatar for ~s.o.s~
0
80
Member Avatar for friedguy

> Is javascript the way to go with this? No, AFAIK it can't be done in Javascript irrespective of whether the PDF's are pre-generated / generated on fly. The way to do it would be process the user input at the server and set the response headers accordingly when the …

Member Avatar for friedguy
0
130
Member Avatar for jmasta

[URL="http://www.dynamicdrive.com/dynamicindex1/contextmenu.htm"]Custom Context menus for IE and FF.[/URL]

Member Avatar for jmasta
0
143
Member Avatar for krapa

> i want my email field to be validated such that a user can enter only valid email id...how > should i do this? This check can't be reliably done at client side considering that there are a lot of valid email formats. For e.g. mail provider A might not …

Member Avatar for ~s.o.s~
0
103
Member Avatar for ishFady

Use the [URL="http://www.json.org/java/"]Java binding for JSON[/URL]. Its pretty simple and after your JSON object has been constructed, all you have to do is store the representation in a String variable which can be accessed by your JSP; i.e. the normal way in which you pass data to and fro from …

Member Avatar for ~s.o.s~
0
67
Member Avatar for new2jsp

> But when I click on Next link, I get "The requested resource (/getReleaseData) is not > available.". Take a look at the link which is displayed in the location bar of your web browser. Is path shown there same as that the location at which your servlet is present?

Member Avatar for ~s.o.s~
0
196
Member Avatar for darkraider

The RegExp you have there is incorrect. The correct one would be: [code] /* For Letters: [a-zA-Z] (dealing with both upper and lower case characters) For Space: [ ] Putting them together: [a-zA-Z ]+ Use a + instead of * since a blank string is not a valid letter nor …

Member Avatar for darkraider
0
67
Member Avatar for chickenlord500
Member Avatar for TofiLuk

> Then create a method in the class that loops the two arrays and checks one by one the > elements. Or just use the one provided by the standard library for the [URL="http://java.sun.com/j2se/1.5.0/docs/api/java/util/Arrays.html"]Arrays[/URL] class. If comparing two Object arrays, use the [ICODE]Arrays.deepEquals(Object[] a1, Object[] a2) [/ICODE]. When comparing arrays …

Member Avatar for ~s.o.s~
0
143

The End.