site announcement 4 lavalair

Started on the old forum in May 2011 · view the original in the archive · old links redirect here

No replies · 403 views · started 15 years ago · 1 min read

aditya4569 Newbie · 3 posts #1

Guys anyone have script for site announcement?? here what am tried to make one

else if ($action="oshout")
{
$oantx=$_POST["oantx"];
addonline(getuid_sid($sid),"Owner Shouting","");
echo"<head>";
echo"<title>Announcing</title>";
echo"<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">';
echo"</head>";
echo"<body>";
echo"<p align=\"center\")";
$oshtxt=$oshtxt;
//$uid=getuid_sid($sid);
$oshtm=time();
$res=mysql_query("INSERT INTO ibwf_oannouncements  SET oantext='".$oantx."',oantime='".$oshtm."',id='".$uid."'");

if($res)
{
echo"<img src=\"../images/ok.gif\"alt=\"o\"/>Announcement Added!";
}
else{
        echo "<img src=\"../images/notok.gif\" alt=\"X\"/>Database Error";
    }
    
echo "<br/><br/><b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
    echo "</p>";
    echo "</body>";
}
/////index/////////
$sql="SELECT id ,oantext,oantime FROM ibwf_oannouncements ORDER BY antime DESC LIMIT 1";
$itmes=mysql_query($sql);
$oannc = htmlspecialchars($item[1]);
echo"$oannc";
///form///
echo"<form action=\"ownrproc.php?action=oannc&sid=$sid&amp method=\"post\">";
echo"Text :<input name=\"oantx\" maxlength=\"200\"><br/>";
echo"<input type=\"submit\" name=\"announce!\"></form>';
///sql///
CREATE TABLE `oibwf_announcements` (
  `id` int(100) NOT NULL auto_increment,
  `oantext` varchar(200) NOT NULL default '',
  
  `oantime` int(100) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

Write your reply now; next you create a free account (or sign in) and it is posted right away. Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close