Re: JS alert that links to a file

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Jul 26, 2009 at 09:55:14PM -0500, Skip Evans wrote:

> Okay, I know I've done this before, but now I'm blanking out.
>
> I have code that creates a CSV file, and when it's done I want
> a JS alert to pop up and let them save the file.
>
> Isn't this some kind of alert() type call on the JS side???
>
> I know I've done this before and I've been on Google an hour now!

Not sure I understand your question, but there is a function called
alert() in javascript. It opens a window with your error message in it.

I don't know of a way to trigger this from PHP, since PHP is server-side
and Javascript is client-side. You might be able to have javascript scan
for the existence/closing of the file in question and then alert the
user. Or you could have PHP, when the file is complete, launch a new
page which contains the javascript code to alert the user.

Paul

-- 
Paul M. Foster

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux