473,404 Members | 2,195 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

open post in new window HELP!!

I have the folowing code implimented. when the post button is pressed
it places the info in the existing window. How can I make it open a
new window for the new data?

htp.p('<TD><A HREF=javascript:_SubmitForm("PARAMETER_FORM")><IMG
SRC="/sec/image/info.bmp" TARGET="_top" BORDER=0
ALIGN=ABSMIDDLE></A></TD>');

Sorry if there is not enough info. I am new at this.
Jul 20 '05 #1
5 1703
DU
gregg wrote:
I have the folowing code implimented. when the post button is pressed
it places the info in the existing window. How can I make it open a
new window for the new data?

htp.p('<TD><A HREF=javascript:_SubmitForm("PARAMETER_FORM")><IMG
SRC="/sec/image/info.bmp" TARGET="_top" BORDER=0
ALIGN=ABSMIDDLE></A></TD>');

Sorry if there is not enough info. I am new at this.


This is item 4.37 covered by the comp.lang.javascript FAQ
In your code, img element can not have a target attribute. Also, you
should avoid using a href="javascript: construct which is known to be
bad, to create problems. This is again an item in the FAQ (4.24).

http://jibbering.com/faq/#FAQ4_37
http://jibbering.com/faq/#FAQ4_24

Finally, best is to give an url where we can examine the code of the
whole page.

DU
Jul 20 '05 #2
"gregg" <gf***@hotmail.com> wrote in message
news:da*************************@posting.google.co m...
I have the folowing code implimented. when the post button is pressed
it places the info in the existing window. How can I make it open a
new window for the new data?

htp.p('<TD><A HREF=javascript:_SubmitForm("PARAMETER_FORM")><IMG
SRC="/sec/image/info.bmp" TARGET="_top" BORDER=0
ALIGN=ABSMIDDLE></A></TD>');

Sorry if there is not enough info. I am new at this.


Change
TARGET="_top"
to
TARGET="_blank"
Jul 20 '05 #3
DU
McKirahan wrote:
"gregg" <gf***@hotmail.com> wrote in message
news:da*************************@posting.google.co m...
I have the folowing code implimented. when the post button is pressed
it places the info in the existing window. How can I make it open a
new window for the new data?

htp.p('<TD><A HREF=javascript:_SubmitForm("PARAMETER_FORM")><IMG
SRC="/sec/image/info.bmp" TARGET="_top" BORDER=0
ALIGN=ABSMIDDLE></A></TD>');

Sorry if there is not enough info. I am new at this.

Change
TARGET="_top"
to
TARGET="_blank"


target attribute in an <img> element is invalid markup and can not be
rendered anyway.

DU
Jul 20 '05 #4
"DU" <dr*******@hotREMOVETHISmail.com> wrote in message
news:bs**********@news.eusc.inter.net...
McKirahan wrote:
"gregg" <gf***@hotmail.com> wrote in message
news:da*************************@posting.google.co m...
I have the folowing code implimented. when the post button is pressed
it places the info in the existing window. How can I make it open a
new window for the new data?

htp.p('<TD><A HREF=javascript:_SubmitForm("PARAMETER_FORM")><IMG
SRC="/sec/image/info.bmp" TARGET="_top" BORDER=0
ALIGN=ABSMIDDLE></A></TD>');

Sorry if there is not enough info. I am new at this.

Change
TARGET="_top"
to
TARGET="_blank"


target attribute in an <img> element is invalid markup and can not be
rendered anyway.

DU


You're absolutely right. I saw the HREF tag and stopped thinking.

Try adding TARGET="_blank" inside the (unshown) <FORM> tag.

P.S. What good does TARGET="_top"inside the <IMG> tag do?
Jul 20 '05 #5
gregg wrote:
I have the folowing code implimented. when the post button is pressed
it places the info in the existing window. How can I make it open a
new window for the new data?
Du not use
vvvvv htp.p('<TD><A HREF=javascript:_SubmitForm("PARAMETER_FORM")><IMG

^^^^^ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
but window.open(...). And that is utter nonsense.
PointedEars
Jul 20 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Ben Smeets | last post by:
Hi folks, Have been trying to figure out a solution for the following problem by reading lots of threads here, but doesn't work out. Hope someone can help me. I have a parent window which...
17
by: Applebrownbetty | last post by:
Hi, I'd like to append/amend the following code from the Dreamweaver extension "Open Picture Window Fever" for the ability to center the PopUp window: By default, it allows the window to be...
3
by: MLH | last post by:
I seem to remember a post in the distant past discussing how to switch to another open application window. IE, if WordPad is running, some API function that'll allow me to switch the focus to that...
1
by: Nevyn Twyll | last post by:
I have a DataList; in the DataList's , I have a LinkButton and a few listboxes. When the LinkButton is pressed, I need to get the ID of the selected item in one of the Listbox controls. Then I...
3
by: ACaunter | last post by:
Hi all, I need to set a session variable and open a new window with a single click of an asp.net button. My problem is that it always takes two clicks.. one sets the session and the other opens...
2
by: Jules_Anime | last post by:
Is it possible to create an onclick event which is attached to individual datalist items? I have a Datalist with some details on employees, and when you click on one we would like to open a new...
19
by: Sonnich | last post by:
Hi! I have used JS, but I am still new to it. I have something like this: oNewWindow = new Object(); oNewWindow = open("sonnich.xls","Qopen","resizable=yes,scroll=yes, status=yes,...
9
by: wax | last post by:
Hello. // i/o example #include <iostream> using namespace std; int main () { int i;
0
by: hcuellar | last post by:
Hi. Please I need your help for this: After a database query, a table is created with a cell for each information retrieved, and for each record, two buttons, and second one have besides it...
4
by: Arivu PHP | last post by:
I have to open new window without clicking link or url.. i need to open autometically when entered the inside of my webpage. can any one help this task..
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.