Win a copy of Node.js Design Patterns: Design and implement production-grade Node.js applications using proven patterns and techniques this week in the Server-Side JavaScript and NodeJS forum!

Gowrishankar Mudaliar

Ranch Hand
+ Follow
since Oct 20, 2001
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Gowrishankar Mudaliar

I can obviously use response.sendRedirect. But I am trying to strictly follow the struts framework. SwitchAction is another type of Action. It actually extends Action and could be found in the "org.apache.struts.actions" package.
16 years ago
I can't use SwitchAction because it is available from struts 1.1 only and the version of struts we are using in our project is older than that.

Thanks anyways and any other suggestion would be welcome too.

Gowri
16 years ago
Hi All,

I have 2 webapplications. they are called MyHome and MyShop. When I login to MyHome, a form has to be submitted to MyShop. These two applications share different contexts and in production environment they are in different servers. So, my question is, Is it possible in struts to forward a request to an external application using the action -> forward or the global forward tags?

Thanks in advance,
Gowri Shankar
16 years ago
Hi All,

I have 2 webapplications. they are called MyHome and MyShop. When I login to MyHome, a form has to be submitted to MyShop. These two applications share different contexts and in production environment they are in different servers. So, my question is, Is it possible in struts to forward a request to an external application using the action -> forward or the global forward tags?

Thanks in advance,
Gowri Shankar
16 years ago
You can read the binary contents of your file without base64 by setting the mime type in the form as multipart/form-data and read the contents in the servlets.

This is how file-uploads and email attachments work in web-based applications. I am not sure if they are precisely applicable to your requirements.
16 years ago
I tried with LinkedHashMap and it worked.
16 years ago
I tried TreeMap, but i get the output as {one=1, three=3, two=2}

I don't need this too. Is there any other way?
16 years ago
Hi,

Is there any way i can retrieve keys and values in the same order that i put. I am not sure why hashtable.keys() does not give the keys back in the same order and i dont understand the order in which it returns the keys.

Consider the example program.

import java.util.Hashtable;

public class hashtest
{
public static void main(String c_strAr[])
{
Hashtable c_ht= new Hashtable();

c_ht.put("one","1");
c_ht.put("two","2");
c_ht.put("three","3");

System.out.println(c_ht);
}
}

The output is : {two=2, one=1, three=3}

It should have been..:{one=1, two=2, three=3}

Is there a way i can get the values back in the same order that i inserted ..?

Thanks in Advance.
Gowri
16 years ago
Hi All,

I am having a program like this.


It evaluates an expression like " 1.00*(100-99.99)/100 ".
The result is a number in exponential format. But i only want a number in normal format. Is there a way i can achieve this straight forwardly.

public class ATLDiscount
{
public static void main(String ar[]) throws ParseException
{
double dIntermediateCalcCost = 0,dPrice = 0,dVal = 0;

dPrice = 1.00;
dVal= 99.99;

dIntermediateCalcCost = dPrice*(100-dVal)/100;

System.out.println("Intermediate COst double..:"+dIntermediateCalcCost);



}
}

Thanks
Gowri
17 years ago
You can pass the arraylist as part of url only if you could convert it into a comma seperated values of string.
Alternatively you could put the arraylist in session or in the request using request.setAttribute.
17 years ago
JSP
You might have to exetend the datasource into bytearraydatasource.
Thats how i did it. Check this link for reference
http://www.developer.com/java/other/print.php/618471
Hope this helps
17 years ago
Implement your object cache as a Singleton. This should be accessible if all your applications use the same jvm.
I am not aware if tomcat provides any container level objects. You might also want to take a look into their documentation otherwise.
17 years ago
Implement your object cache as a Singleton. This should be accessible if all your applications use the same jvm.
I am not aware if tomcat provides any container level objects. You might also want to take a look into their documentation otherwise.
17 years ago
I have an Oracle stored procedure.I need to make a modification to it so that it returns me the value in the variable, which points to a field in the table.
the variable was declared like
pRetVal TABLE_NAME.FIELD_NAME%type
I would like to know how i can return this variable?
Thanks
Gowrishankar
17 years ago
If you configure a servlet name in web.xml, then you use the url like
http://<server>/<webapp>/<servletName>
Otherwise, the default way is to use the fully qualified name
http://<server>/<webapp>/<servlet>/[<packageName>][.]servletClassName
Note: contents within [] are optional.
17 years ago
JSP