3,892 Posted Topics

Member Avatar for Ankita B

Are you sure you provided the path to JDK instead of JRE during Tomcat installation? If yes, then paste your code (JSP along with Java files) and we will see what can be done.

Member Avatar for ~s.o.s~
0
180
Member Avatar for Questions???

And "Questions??", don't forget to use code tags the next time you post code which is preferably properly indented.

Member Avatar for ~s.o.s~
0
98
Member Avatar for durahman

You shouldn't use scriptlets in your JSP file. They hamper readability, maintainability and re usability. Firing SQL queries / database access from JSP code is also bad in itself. Create a simple HTML login form. Create a form bean. When the form is submitted, redirect to a controller servlet which …

Member Avatar for ~s.o.s~
0
170
Member Avatar for pi415

From the Ecmascript specification: [quote]The dollar sign ($) and the underscore (_) are permitted anywhere in an identifier. The dollar sign is intended for use only in mechanically generated code.[/quote] The $() function is not standard javascript and is used by most libraries to stand for the most commonly used …

Member Avatar for ~s.o.s~
0
95
Member Avatar for fufu123
Member Avatar for jaepi

I won't allow such threads to degrade the quality of posts at Daniweb. Thread closed until someone on the mod team decides/thinks otherwise.

Member Avatar for ~s.o.s~
-1
107
Member Avatar for n33712

You need to iterate over the array and compare each array entry against the user input. Currently, you are comparing an array object with a string, hence the error. [code] for(var i = 0, max = arr.length; i < max; ++i) { var found = false; if(arr[i] == pwd) { …

Member Avatar for ~s.o.s~
0
83
Member Avatar for ndeniche

No worries, we will be on the lookout for good things and just ignore the bad things. ;-)

Member Avatar for ~s.o.s~
1
90
Member Avatar for Ancient Dragon
Member Avatar for sree22_happy
Member Avatar for ~s.o.s~
0
74
Member Avatar for abhi_elementx

> I have a little difficulty accessing a textbox value from a function. Your HTML markup is all broken up, make sure you validate your markup before posting it here. You are incorrectly accessing form fields. Read [URL="http://validator.w3.org/"]this [/URL]and [URL="http://www.jibbering.com/faq/faq_notes/form_access.html"]this[/URL]. > f = getElementById(formName); This is incorrect, getElementById is not …

Member Avatar for ~s.o.s~
0
119
Member Avatar for Ankita B

Though it works, it's an incorrect way of doing things.[ICODE] location[/ICODE] property of the [ICODE]window[/ICODE] object is an object, not a string. The location object in turn has an [ICODE]href[/ICODE] property of type string and hence [ICODE]location.href = "url";[/ICODE] is the correct, [ICODE]location = "url";[/ICODE] is not.

Member Avatar for ~s.o.s~
0
83
Member Avatar for sree22_happy

You have got to realize that when we talk of XML, the whitespaces in your document matter and they get counted as a "#text" node. Assuming that xmlObj has the reference of the root node of the document, something like [icode]alert(xmlObj.childNodes[1].firstChild.nodeValue);[/icode] should do the trick. Here: [quote] xmlObj -> <code> …

Member Avatar for sree22_happy
0
218
Member Avatar for bogdangwawa

IE doesn't like setAttribute as already mentioned. A cross browser compatible way of setting the attributes would be to treat them as object properties and modify them directly. [code] formElement.type = "button"; /* .... */ formElement.onclick = function() { someFunction(); }[/code]

Member Avatar for ~s.o.s~
0
86
Member Avatar for sree22_happy

This is because the value which you receive in the upload box is a Windows specific path. IE would obviously know how to interpret it but Mozilla won't. To make this possible, you have to convert your windows path into a file resource which can be used by all browsers …

Member Avatar for sree22_happy
0
225
Member Avatar for kavithareddy

[QUOTE=kavithareddy;519565]Hi , can any one tell me how to disable the back button in asp.net i have done like this <script > window.onlad = "window.document.forward(1)"; </script> but no use...is there any other way to do this.[/QUOTE] Look into the function [URL="http://www.w3schools.com/htmldom/met_loc_replace.asp"]window.location.replace[/URL]. It should solve your problem. But criplling the client …

Member Avatar for MidiMagic
0
92
Member Avatar for jan1024188

I guess no: [quote] int MessageBox( HWND [I]hWnd[/I], LPCTSTR [I]lpText[/I], LPCTSTR [I]lpCaption[/I], UINT [I]uType[/I] ); [I]lpText[/I] [in] Pointer to a null-terminated string that contains the message to be displayed.[I] lpCaption[/I] [in] Pointer to a null-terminated string that contains the dialog box title. If this parameter is NULL, the default title …

Member Avatar for Aia
0
129
Member Avatar for Lee-Pro

> Using the normal xmlHttp request, it retrieves a html document. But is there any way I could > actually handle it through some kind of DOM before actually displaying it? Make sure that the page you fetch using XHR is well formed. If that is the case, you can …

Member Avatar for Lee-Pro
0
127
Member Avatar for Ankita B

Never ever put business / backend logic in your JSP file. It's not what it was meant for. JSP is a presentation technology. Place your logic inside Servlets / EJB's and use DAO(Data Access Objects) to access your database. Reading the official [URL="http://java.sun.com/javaee/reference/index.jsp"]J2EE tutorial[/URL] would clear up things for you.

Member Avatar for Ankita B
0
127
Member Avatar for Serunson

Yes, Moderators, Super Moderators, Admins and Donators can have custom titles. [B]PS:[/B] And oh Dani, how is it that you have a rep power of 31 by having 4 dots and I have 21 inspite of having 6 dots?

Member Avatar for overwhelmed
0
145
Member Avatar for chitra1

> Have you tried this site: [url]http://www.roseindia.net/jsp/jsp.htm[/url] I wouldn't trust that site. The content seems to be substandard. Maybe you should try out the [URL="http://java.sun.com/javaee/reference/index.jsp"]official J2EE tutorial on Sun's site[/URL]. The next step in learning would be of course to grab hold of some decent titles than relying on online …

Member Avatar for electron33
0
103
Member Avatar for Ankita B

> I am a complete novice in java. Then what you ought to do is start studying. [URL="http://java.sun.com/javaee/5/docs/firstcup/doc/toc.html"]J2EE 1.5 first cup[/URL] and [URL="http://java.sun.com/javaee/5/docs/tutorial/doc/"]J2EE tutorials[/URL] on the official Sun site should be sufficient at this point in time. > I.m using oracle 9.1,tomcat 4.1 and java 1.4.1. Why are you stuck …

Member Avatar for jwenting
0
104
Member Avatar for toadzky

If you don't want server interaction, you can of course load the data from a local XML file and render it.

Member Avatar for ~s.o.s~
0
71
Member Avatar for mramrit
Member Avatar for peter_budo

> [ICODE]<script type="text/javascript"> getPropertyNum();</script>[/ICODE] This just means that you are executing the function [ICODE]getPropertyNum() [/ICODE]and ignoring the return value, nothing else. To make sure the value is reflected in the DOM tree, you need to either do [ICODE]document.write(getPropertyNum())[/ICODE] (not recommended) or use the HTML DOM. A few other things: [LIST] …

Member Avatar for ~s.o.s~
0
154
Member Avatar for Narue

> That's what I have right now, just a gibberish phrase that came out of nowhere and won't go > away: yaba yaba poi gatau. Are you by any chance surrounded by kids who have decided to get back to you? ;-)

Member Avatar for vegaseat
0
135
Member Avatar for n33712

Something like the below should do the trick: [code] function fuzzy(pwd) { if(!pwd || pwd.constructor == String || pwd.length < 3) return(pwd); var arr = pwd.split(""); return(arr[0] + new Array(arr.length - 1).join('*') + arr[arr.length - 1]); } /* OR */ function fuzzy(pwd) { if(!pwd || pwd.constructor == String || pwd.length …

Member Avatar for ~s.o.s~
0
87
Member Avatar for tayspen
Member Avatar for invisal
1
175
Member Avatar for KimJack

Don't read the file character by character. Always make sure your the I/O operations performed by your program are buffered unless needed otherwise. The less the I/O calls, the better. Instead, read the entire line in a string using BufferedReader / Scanner class and perform the processing. Of the many …

Member Avatar for KimJack
0
200
Member Avatar for sagedavis

> Further, all previouse data needs to be saved, without using the database to store it. Store the data in the user session using the server side language of your choice. > I need to figure out how to make it so that, if the user skips a question This …

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

Though I am not very clear as to what you mean, this snippet should give you a fair idea. If it doesn't, post your code: [code] <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Example</title> </head> <body> <script type="text/javascript"> (function doSomething() { while(true) { …

Member Avatar for n33712
0
98
Member Avatar for hooray

> Otherwise you would have to use the getElementsByName() method to get all the elements > with the name "states". Or simply [icode]document.forms[0].elements["states"].disabled = false;[/icode] which is the correct way of handling form elements.

Member Avatar for ~s.o.s~
0
135
Member Avatar for priddysharp

> when I try it in IE7, the countdown starts at 9 seconds no matter what. Works fine for me. Even though the semicolons are optional in Javscript, it's a good practice to explicitly put them to avoid some subtle bugs. A better solution would be to use setInterval. [code] …

Member Avatar for ~s.o.s~
0
131
Member Avatar for yenyen

> var obj = eval("document.list_photo." + objId); Don't use eval. It's like using a powerhouse to light a single bulb. The same thing can be done using [icode]var obj = document.forms['list_photo'].elements[objId[/icode]. The same can be said about the other places you have used eval. Read the [URL="http://www.jibbering.com/faq/faq_notes/form_access.html"]Javascript FAQ[/URL] for more …

Member Avatar for ~s.o.s~
0
173
Member Avatar for OmniX

> Now that has been annoying me and I have been trying to figure out a way to prevent this. Doing so wouldn't be a good idea unless it's absolutely necessary. Sure you can do it, but it won't be worth the kind of computational complexity it introduces. Long gone …

Member Avatar for ~s.o.s~
0
1K
Member Avatar for Serunson

MMORPG's FTW! BTW, the poll is broken as Multiplayer / Single Player games are not genres but playing modes.

Member Avatar for maravich12
0
139
Member Avatar for ShawnCplus

> Internet Exploer does not like this method for some reason Why? What made you reach that conclusion? In fact, my entire snippet for removing the selected option relies on removeChild and it works fine in IE/FF/Opera. Also a few things to keep in mind. [LIST] [*]Post the entire code …

Member Avatar for ShawnCplus
0
123
Member Avatar for Oxiegen

Look into [url=http://json.org/js.html]JSON[/url] for shipping data back and forth between your server and Javascript. It has become a de-facto standard like XML for shipping data in a platform / language agnostic manner.

Member Avatar for ~s.o.s~
0
4K
Member Avatar for raziane

> when I open my pages using ip (and not host name) thier javascript functions and events > don't fire. You mean [url]http://xxx.xxx.xxx.xxx:8080/webapp/test.html[/url] over [url]http://hostname:8080/webapp/test.html[/url] ? > can any one help? Use firefox to run your web app and look at the error console. (Tools -> Error Console)

Member Avatar for raziane
0
167
Member Avatar for daintydamsel

The content and links of [URL="http://www.daniweb.com/forums/post513862-4.html"]this [/URL]post are good enough to get you started.

Member Avatar for ~s.o.s~
0
36
Member Avatar for Xessa

> Or should i just create WEB-INF folder. Simply put, your application will be treated as a web application only if it has a WEB-INF (case matters) directory in it's tree structure. From the Servlet Specification: [quote]A special directory exists within the application hierarchy named “WEB-INF”. This directory contains all …

Member Avatar for ~s.o.s~
0
224
Member Avatar for Jishnu

Nothing, he was just being his usual self... ;-) Anyways, go to [URL="http://www.au.ioccc.org/years.html#2004"]this site[/URL] and read the hint files which come along with the code to get an understanding of whats going -- though if you are a beginner to intermediate programmer, it would be difficult for you make any …

Member Avatar for Jishnu
0
223
Member Avatar for manish_gajjar

Use the [URL="http://www.walterzorn.com/tooltip/tooltip_e.htm"]wztooltip[/URL] to ease your task. If you don't want to use an external library, study his code and you can easily implement your own minimalistic tooltip framework.

Member Avatar for kiwisites
1
75
Member Avatar for smilyswapna10

> i did uploading a file with using <input type=file> but is it possible to upload file without > using<input type=file> AFAIK, no.

Member Avatar for MidiMagic
0
71
Member Avatar for jianwu_chen

IE, of all the browsers out there seems to allow element references to be accessed by their id. This is a short hand notation not supported by any of the browsers out there. You need to make sure there are no such naming conflicts if you don't want your code …

Member Avatar for AbberLine
0
141
Member Avatar for armend90

> var codeofheight = "<?php echo $codeofheight; ?>"; When enclosed in script tags, this is JS, not PHP. > the opossite of this code Opposite in what sense?

Member Avatar for ShawnCplus
0
81
Member Avatar for Spartan552

> If need to type the contained ArrayLists but those can contain any type you can use > <ArrayList<ArrayList<?>> That way he would neither be able to instantiate nor insert elements into the given list. A better way would be to do something like: [code=java] public class Lists { public …

Member Avatar for Ezzaral
0
417
Member Avatar for Narue

[quote=Grunt;248320][COLOR=black]I totally agree to what [/COLOR][COLOR=black]Jerry Jongerius says: [/COLOR][/quote] I guess everyone has heard about the Promo event :cheesy: (just kidding) For anyone intrested in actually saving time while coding and to know of the best programming practices i actually recommend "The C++ programming languguage" by the inventor of C++. …

Member Avatar for bector
2
8K
Member Avatar for arunpawar

An embedded database having a small memory footprint would be a much better option considering the host of features you get along with it. Stay away from XML and flat files for the sake of your own sanity. >I'm confused abt SQl cause there are plenty of SQL database out …

Member Avatar for ~s.o.s~
0
91
Member Avatar for amithasija

Some links which might interest you: [URL="http://openjsan.org/"]Javascript archive network[/URL] [URL="http://javascriptlibraries.com/"]List of all Javascript libraries[/URL]

Member Avatar for amithasija
0
103

The End.