HI Brandon,

It's actually easy to do this is PHP.  A <FORM> tag will take a 
TARGET window attribute that will let you control what happens after 
the form is processed.  The resultant page can appear in a new 
window, in the parent window, to the same window the form was used, 
to the full browser window or to some named frame, i.e., 
TARGET=_blank or _parent or _self or _top or FrameName.

If you don't want to use the normal <INPUT TYPE=SUBMIT> tag to make 
the window change happen, you can use a .gif or .jpg image to start 
the page change.

<IMAGE TYPE="IMAGE" NAME="SUBMIT" SRC="CoolButton.jpg" WIDTH="20" 
HEIGHT="12" HSPACE="4" BORDER="0" ALT="Do It"></FORM>

Obviously, since you are using php, you can make this very simple, 
just to make the window change or you can make the form processing do 
extra things, i.e., remember the persons name, some ID, ...

Another not well known fact is that you can have multiple <FORMS> on 
a single page.

I've seen a calendar that uses this technique with dozens of forms to 
make "edit" buttons for each event.  Different INPUT type=hidden tags 
were used in each form to pass the date and event ID info.


Good Luck

Mike

>I wanted to know how I could have php open a window. Like can I have it
>print out some javascript to open a new window?  Instead of someone
>having to click a link.
>
>Thanks Brandon
>
>-----Original Message-----
>From: Mark Charette [mailto:[EMAIL PROTECTED]]
>Sent: Friday, December 14, 2001 2:08 PM
>To: PHP User Group
>Subject: RE: [PHP] Opening a new window.
>
>I would use "target="_blank" in the anchor tag  so it would work just
>fine
>_without_ javascript ...
>
>Mark C.
>
>-----Original Message-----
>From: Mehmet Kamil ERISEN [mailto:[EMAIL PROTECTED]]
>
>I would use javascript for that.
>--- Brandon Orther <[EMAIL PROTECTED]> wrote:
>>  Does anyone know how I could have php open a new windows
>>  with the url I
>>  specify?
>>
>>  Thanx,
>>  Brandon>
>
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>
>
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 

_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/_/
    Michael Seely      408-777-9949




                             

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


Reply via email to