当前位置: 首页>>代码示例>>PHP>>正文


PHP writeHead函数代码示例

本文整理汇总了PHP中writeHead函数的典型用法代码示例。如果您正苦于以下问题:PHP writeHead函数的具体用法?PHP writeHead怎么用?PHP writeHead使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了writeHead函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: ifaceButton

    ?>
    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . $_SERVER['PHP_SELF'] . "?save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . $_SERVER['PHP_SELF'] . "?save=1','" . urlencode($LegalCase->getId()) . "');", "Save");
            $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?LegalCase=" . urlencode($LegalCase->getId()), "Cancel");
        }
    } else {
        $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?edit=1&LegalCase=" . urlencode($LegalCase->getId()), "Edit") . ifaceButton($_SERVER['PHP_SELF'] . "?del=1&LegalCase=" . urlencode($LegalCase->getId()), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The LegalCase is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No LegalCase object selected - VIRO - ADL Prototype</TITLE>");
        ?>
<i>No LegalCase object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:sapray,项目名称:ampersand-models,代码行数:31,代码来源:LegalCase.php

示例2: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Pattern->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Pattern' => urlencode($Pattern->getId()))), "Cancel");
        }
    } else {
        $buttons = $buttons;
        $buttons = $buttons;
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Pattern is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Pattern object selected - Atlas - ADL Prototype</TITLE>");
        ?>
<i>No Pattern object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Pattern.php

示例3: writeHead

<?php

require_once '_base.php';
writeHead();
?>
<h1><?php 
echo $form_heading;
?>
</h1>
<h1><?php 
echo $form_content;
?>
</h1>
开发者ID:newsomc,项目名称:unify,代码行数:13,代码来源:form_cool.php

示例4: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Gebruiker->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Gebruiker' => urlencode($Gebruiker->getId()))), "Cancel");
        }
    } else {
        ifaceButton(serviceref($_REQUEST['content'], array('Gebruiker' => urlencode($Gebruiker->getId()), 'edit' => 1)), "Edit");
        ifaceButton(serviceref($_REQUEST['content'], array('Gebruiker' => urlencode($Gebruiker->getId()), 'del' => 1)), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Gebruiker is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Gebruiker object selected - Meterkast - ADL Prototype</TITLE>");
        ?>
<i>No Gebruiker object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Gebruiker.php

示例5: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Concept->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Concept' => urlencode($Concept->getId()))), "Cancel");
        }
    } else {
        $buttons = $buttons;
        $buttons = $buttons;
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Concept is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Concept object selected - Atlas - ADL Prototype</TITLE>");
        ?>
<i>No Concept object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Concept.php

示例6: mysql_real_escape_string

    $name = mysql_real_escape_string($name);
    mysql_select_db('thengamer_userdb');
    query("DELETE FROM users WHERE id = {$old_id} LIMIT 1");
    $rs = query("SELECT COUNT(*) FROM users WHERE id = {$id}");
    list($num) = mysql_fetch_row($rs);
    if ($num) {
        query("UPDATE users SET id = {$id}, name = '{$name}' WHERE id = {$old_id} LIMIT 1");
        logAction("updated user {$id} with username \"{$name}\" and old id {$old_id}");
    } else {
        query("INSERT INTO users (id, name) VALUES ({$id},'{$name}')");
        logAction("inserted user {$id} with username \"{$name}\"");
    }
    mysql_select_db('thengamer_forum');
    $message = "<p>User added/edited.</p>";
}
writeHead('GFuserDB Moderation');
if (@$_POST['action'] == 'Next...') {
    $id = (int) @$_POST['user'];
    mysql_select_db('thengamer_userdb');
    $rs = query("SELECT name FROM users WHERE id = {$id}");
    list($username) = @mysql_fetch_row($rs);
    mysql_select_db('thengamer_forum');
    $username = htmlspecialchars($username);
    echo <<<ADDEDIT
<h3>Add/edit a user</h3>

<form action="gfuserdb.php" method="post">
  <p>User ID: <input type="text" name="id" value="{$id}" /></p>
  <p>Username: <input type="hidden" name="old_id" value="{$id}" /><input type="text" name="username" value="{$username}" /> <input type="submit" name="action" value="Submit" /></p>  
</form>
ADDEDIT;
开发者ID:Albertoni,项目名称:GFUserDatabase,代码行数:31,代码来源:gfuserdb.php

示例7: die

    if ($Regels->save() !== false) {
        die('ok:' . serviceref($_REQUEST['content']));
    } else {
        die('Please fix errors!');
    }
    exit;
    // do not show the interface
}
$buttons = "";
if (isset($_REQUEST['edit'])) {
    $edit = true;
} else {
    $edit = false;
}
$Regels = new Regels();
writeHead("<TITLE>Regels - Atlas - ADL Prototype</TITLE>" . ($edit ? '<SCRIPT type="text/javascript" src="js/edit.js"></SCRIPT>' : '<SCRIPT type="text/javascript" src="js/navigate.js"></SCRIPT>') . "\n");
if ($edit) {
    echo '<FORM name="editForm" action="' . $_SERVER['PHP_SELF'] . '" method="POST" class="Edit">';
}
?>
<H1>Regels</H1>
    <DIV class="Floater Regellijst">
      <DIV class="FloaterHeader">Regellijst</DIV>
      <DIV class="FloaterContent"><?php 
$Regellijst = $Regels->get_Regellijst();
echo '
          <UL>';
foreach ($Regellijst as $i0 => $idv0) {
    $v0 = display('UserRule', 'display', $idv0);
    echo '
            <LI CLASS="item UI" ID="0.' . $i0 . '">';
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Regels.php

示例8: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Actie->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Actie' => urlencode($Actie->getId()))), "Cancel");
        }
    } else {
        ifaceButton(serviceref($_REQUEST['content'], array('Actie' => urlencode($Actie->getId()), 'edit' => 1)), "Edit");
        ifaceButton(serviceref($_REQUEST['content'], array('Actie' => urlencode($Actie->getId()), 'del' => 1)), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Actie is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Actie object selected - Meterkast - ADL Prototype</TITLE>");
        ?>
<i>No Actie object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Actie.php

示例9: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Populatie->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Populatie' => urlencode($Populatie->getId()))), "Cancel");
        }
    } else {
        $buttons = $buttons;
        $buttons = $buttons;
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Populatie is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Populatie object selected - Atlas - ADL Prototype</TITLE>");
        ?>
<i>No Populatie object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Populatie.php

示例10: die

    if ($Ops->save() !== false) {
        die('ok:' . serviceref($_REQUEST['content']));
    } else {
        die('Please fix errors!');
    }
    exit;
    // do not show the interface
}
$buttons = "";
if (isset($_REQUEST['edit'])) {
    $edit = true;
} else {
    $edit = false;
}
$Ops = new Ops();
writeHead("<TITLE>Ops - Meterkast - ADL Prototype</TITLE>" . ($edit ? '<SCRIPT type="text/javascript" src="js/edit.js"></SCRIPT>' : '<SCRIPT type="text/javascript" src="js/navigate.js"></SCRIPT>') . "\n");
if ($edit) {
    echo '<FORM name="editForm" action="' . $_SERVER['PHP_SELF'] . '" method="POST" class="Edit">';
}
?>
<H1>Ops</H1>
    <DIV class="Floater Operations">
      <DIV class="FloaterHeader">Operations</DIV>
      <DIV class="FloaterContent"><?php 
$Operations = $Ops->get_Operations();
echo '
          <UL>';
foreach ($Operations as $i0 => $idv0) {
    $v0 = $idv0;
    echo '
            <LI CLASS="item UI" ID="0.' . $i0 . '">';
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Ops.php

示例11: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Bestand->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Bestand' => urlencode($Bestand->getId()))), "Cancel");
        }
    } else {
        ifaceButton(serviceref($_REQUEST['content'], array('Bestand' => urlencode($Bestand->getId()), 'edit' => 1)), "Edit");
        ifaceButton(serviceref($_REQUEST['content'], array('Bestand' => urlencode($Bestand->getId()), 'del' => 1)), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Bestand is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Bestand object selected - Meterkast - ADL Prototype</TITLE>");
        ?>
<i>No Bestand object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Bestand.php

示例12: ifaceButton

    ?>
    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . $_SERVER['PHP_SELF'] . "?save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . $_SERVER['PHP_SELF'] . "?save=1','" . urlencode($Session->getId()) . "');", "Save");
            $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?Session=" . urlencode($Session->getId()), "Cancel");
        }
    } else {
        $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?edit=1&Session=" . urlencode($Session->getId()), "Edit") . ifaceButton($_SERVER['PHP_SELF'] . "?del=1&Session=" . urlencode($Session->getId()), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Session is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Session object selected - VIRO - ADL Prototype</TITLE>");
        ?>
<i>No Session object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:sapray,项目名称:ampersand-models,代码行数:31,代码来源:Session.php

示例13: ifaceButton

    ?>
    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . $_SERVER['PHP_SELF'] . "?save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . $_SERVER['PHP_SELF'] . "?save=1','" . urlencode($Party->getId()) . "');", "Save");
            $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?Party=" . urlencode($Party->getId()), "Cancel");
        }
    } else {
        $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?edit=1&Party=" . urlencode($Party->getId()), "Edit") . ifaceButton($_SERVER['PHP_SELF'] . "?del=1&Party=" . urlencode($Party->getId()), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Party is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Party object selected - VIRO - ADL Prototype</TITLE>");
        ?>
<i>No Party object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:sapray,项目名称:ampersand-models,代码行数:31,代码来源:Party.php

示例14: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Session->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Session' => urlencode($Session->getId()))), "Cancel");
        }
    } else {
        ifaceButton(serviceref($_REQUEST['content'], array('Session' => urlencode($Session->getId()), 'edit' => 1)), "Edit");
        ifaceButton(serviceref($_REQUEST['content'], array('Session' => urlencode($Session->getId()), 'del' => 1)), "Delete");
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Session is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Session object selected - Meterkast - ADL Prototype</TITLE>");
        ?>
<i>No Session object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Session.php

示例15: ifaceButton

    <?php 
    if ($edit) {
        echo '</FORM>';
    }
    if ($del) {
        echo "<P><I>Delete failed</I></P>";
    }
    if ($edit) {
        if ($new) {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1',document.forms[0].ID.value);", "Save");
        } else {
            $buttons .= ifaceButton("JavaScript:save('" . serviceref($_REQUEST['content']) . "&save=1','" . urlencode($Relatiedetails->getId()) . "');", "Save");
            $buttons .= ifaceButton(serviceref($_REQUEST['content'], array('Relatiedetails' => urlencode($Relatiedetails->getId()))), "Cancel");
        }
    } else {
        $buttons = $buttons;
        $buttons = $buttons;
    }
} else {
    if ($del) {
        writeHead("<TITLE>Delete geslaagd</TITLE>");
        echo 'The Relatiedetails is deleted';
    } else {
        // deze pagina zou onbereikbaar moeten zijn
        writeHead("<TITLE>No Relatiedetails object selected - Atlas - ADL Prototype</TITLE>");
        ?>
<i>No Relatiedetails object selected</i><?php 
    }
    $buttons .= ifaceButton($_SERVER['PHP_SELF'] . "?new=1", "New");
}
writeTail($buttons);
开发者ID:4ZP6Capstone2015,项目名称:ampersand-models,代码行数:31,代码来源:Relatiedetails.php


注:本文中的writeHead函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。