- Unnamed
- Saturday, September 16th, 2006 at 11:04:14pm UTC
- <?php
- // Other code
- function addnews129($id) {
- global $db;
- session_start();
- if(!isset($_SESSION['admin']) && !isset($_SESSION['password'])){
- echo '<center><h3>Error!</h3></center>You do not have sufficeint permission to view this page.';
- }else{
- $query = "SELECT * FROM news WHERE id=$id";
- $result = mysql_query ($query);
- echo "<center><h3>Add News</h3></center>\n";
- echo "<FORM action=\"{$_SERVER['PHP_SELF']}" .
- "?action=addnews\" method=POST>\n";
- echo "Title: <input type=\"text\" " .
- "size=\"30\" name=\"title\"><BR>\n";
- echo "<TEXTAREA cols=\"40\" rows=\"5\" " .
- "name=\"news\"></TEXTAREA><BR>\n";
- echo "<input type=\"submit\" name=\"submit\" " .
- "value=\"Add News\"\n";
- echo "</FORM>\n";
- }
- }
- // Other code that has nothing to do with this function...just a switch statement...
- ?>
Update the Post
Either update this post and resubmit it with changes, or make a new post.
You may also comment on this post.
Please note that information posted here will expire by default in one month. If you do not want it to expire, please set the expiry time above. If it is set to expire, web search engines will not be allowed to index it prior to it expiring. Items that are not marked to expire will be indexable by search engines. Be careful with your passwords. All illegal activities will be reported and any information will be handed over to the authorities, so be good.