Results 1 to 1 of 1

Thread: Problem with window alert

  1. #1
    Join Date
    Apr 2015
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Problem with window alert

    Hi guys, i want to appear a new window in web browser application with a messege. i try with echo but it can't. as same as the window alert. the code is following

    PHP Code:
    <?php
    session_start
    ();
    if ((!(isset(
    $_SESSION['usertype'])))||($_SESSION['usertype']!="admintp")){
    header'Location: ../index.php');
    }
    $id $_POST['id'];
    include 
    'catalogdbinfo.php';
    //if he is captain then don't delete
    $specs=mysql_query("select speciality from tblemployee where id=".$id);  
    $captain=mysql_query("select empid from tblroute where empid=".$id);  
    if((
    mysql_result($specs,0,'speciality')=="Captain") && (mysql_numrows($captain)>0))
    [
    U]echo "the employer is captain and he can not delete";[/U]

    else
    {
    //else delete
    mysql_query("delete from tblemployee where id=".$id);
     [
    U]echo "  the employer delete";[/U]
     }
    mysql_close($link);
    ?>
     
        <script language="javascript">
        window.location="updateemp.php";
        </script>
    Last edited by jscheuer1; 04-04-2015 at 04:59 PM. Reason: format code

Similar Threads

  1. Encoding problem with alert popup (please help) !
    By winpeace in forum JavaScript
    Replies: 9
    Last Post: 04-18-2012, 10:55 PM
  2. How to display pop-up window/alert initiated by iframe
    By viens in forum Looking for such a script or service
    Replies: 2
    Last Post: 07-12-2009, 11:10 AM
  3. Window.alert script problem/question
    By themind in forum JavaScript
    Replies: 1
    Last Post: 09-16-2005, 03:31 AM
  4. No Right Click Alert... problem.
    By sprintbeans in forum Dynamic Drive scripts help
    Replies: 2
    Last Post: 08-25-2005, 02:55 PM
  5. Replies: 2
    Last Post: 02-20-2005, 09:09 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •