Solved

JSP positioning

Posted on 2010-08-17
8
354 Views
Last Modified: 2012-05-10
I have a jsp which has a button.

On click i open up a new independent jsp. How do i position it to place i require.

I know onload option calling js. But i dont want onload.

This should happen as soon as jsp is triggered before processing happens.

Any experts?
0
Comment
Question by:mahalasa
8 Comments
 
LVL 3

Expert Comment

by:drcheap
Comment Utility
See: http://www.pageresource.com/jscript/jwinopen.htm

Most notably the last section entitled "Set the Window Position"
0
 
LVL 3

Expert Comment

by:drcheap
Comment Utility
Here is also a handy way to obtain the main window's size/position.  With that and a little math you can then position your popup window relative to the main window instead of at specific monitor coordinates.

http://javascript.about.com/od/guidesscriptindex/a/screen.htm
0
 

Author Comment

by:mahalasa
Comment Utility
can resize sometimes lead to loss of data?  i see that sporadically it goes blank.
0
 

Author Comment

by:mahalasa
Comment Utility
Hi drcheap...i have whole set of data to be passed to new jsp through js. How do i do it?
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:mahalasa
Comment Utility
any experts on jsp?
0
 
LVL 20

Expert Comment

by:Sathish David Kumar N
Comment Utility
sorry i didnt get your question clealy?
when u click button that timw new window or same window will open the new Jsp??
can you tell clearly?
0
 
LVL 10

Accepted Solution

by:
Hegemon earned 500 total points
Comment Utility
Open the window and move it to where you want to be:

...

function f() {
   wnd = window.open (url, name, options);
   wnd.moveTo (123, 456);
}
..
<a href="" onclick="f()" />

0
 

Author Closing Comment

by:mahalasa
Comment Utility
will check with these solutions
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Describes a method of obtaining an object variable to an already running instance of Microsoft Access so that it can be controlled via automation.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now