4 Replies - 12333 Views - Last Post: 22 June 2007 - 05:09 AM Rate Topic: -----

#1 Dami  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 6
  • Joined: 11-November 05

PHP "Alert Box" equivalent?

Post icon  Posted 19 June 2007 - 11:14 AM

Is there a PHP equivalent to javascript's Alert Box? I'll look up how to use it myself, I just don't know what to look for.

Thanks in advance.
Is This A Good Question/Topic? 0
  • +

Replies To: PHP "Alert Box" equivalent?

#2 snoj  Icon User is offline

  • Married Life
  • member icon

Reputation: 84
  • View blog
  • Posts: 3,564
  • Joined: 31-March 03

Re: PHP "Alert Box" equivalent?

Posted 19 June 2007 - 02:58 PM

No. PHP (used in a web environment) is server-side not client-side like Javascript. Thus you cannot affect the client's machine with PHP directly.
Was This Post Helpful? 0
  • +
  • -

#3 skyhawk133  Icon User is offline

  • Head DIC Head
  • member icon

Reputation: 1875
  • View blog
  • Posts: 20,282
  • Joined: 17-March 01

Re: PHP "Alert Box" equivalent?

Posted 19 June 2007 - 03:53 PM

However, you can output the code to produce a javascript alert box in PHP based on a certain criteria if you'd like.... javascript will still be the one producing the alert box though
Was This Post Helpful? 0
  • +
  • -

#4 harsha214  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 6
  • Joined: 22-June 07

Re: PHP "Alert Box" equivalent?

Posted 22 June 2007 - 04:40 AM

Here's how you do it from within php (but in reality this is javascript!)

Assuming that you have variable $success (TRUE on success) that holds whether the information was updated successfully.

[mod edit] Like Styx said, no effort, no code. Also it doesn't solve the problem or answer the question.

Will not work if your visitor's browser have javascript disabled.
Was This Post Helpful? 0
  • +
  • -

#5 Styx  Icon User is offline

  • D.I.C Head
  • member icon

Reputation: 5
  • View blog
  • Posts: 192
  • Joined: 04-March 07

Re: PHP "Alert Box" equivalent?

Posted 22 June 2007 - 05:09 AM

harsha, please don't give code unless they show some effort themselves first
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1