Reply to Re: PHP quit navigator

Your name:

Reply:


Posted by Erwin Moller on 02/27/07 15:16

Mike Roetgers wrote:

> sousimou@gmail.com schrieb:
>> i want to create an application web by PHP.
>> i want to create un command buttum whit must close de navigator
>> (internet explorer, mosilla, ...)
>> can you help me
>>
> PHP is a server-side scripting language, so it can't close the browser
> on the client. You are looking for javascript.
> I'm not really into this js-thing, but this should work:
> OnClick="javascript:window.close()"

Good idea, but bad JS. (Well you told us you are not into it. :))

The 'javascript:' thingy is called pseudo protocol, and can be used in
hyperlinks, allthough not advisable because the link will fail in JS
challanged browsers.
When you use an eventhandler (like the onClick) the browser knows it is JS,
so this is enough: OnClick="window.close();"

Regards,
Erwin Moller

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация