Ok here r the code u can use to add ur site name from the staff tools
usage ontop of all pages where all actions are declare
usage
core.php
in sql u just add under
ibwf_settings
ownercp
ownerproc
usage ontop of all pages where all actions are declare
Code:
$stitle = htmlspecialchars(getstitle()); $sdomain = htmlspecialchars(getsdomain()); $date = htmlspecialchars(getdate2());
Code:
$stitle $sdomain $date
Code:
////////////////////////////////////////////get forum message function getsdomain() { $getdata = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='sdomain'")); return $getdata[0]; } ////////////////////////////////////////////get forum message function getdate2() { $getdata = mysql_fetch_array(mysql_query("SELECT value FROM ibwf_settings WHERE name='date'")); return $getdata[0]; }
ibwf_settings
Code:
name = stitle value = Site name name = sdomain value uk.to name = date value 2010
Code:
else if($action=="general") { echo "<card id=\"main\" title=\"owncp\">"; $xtm = getsxtm(); $pmaf = getpmaf(); $fvw = getfview(); $stitle = htmlspecialchars(getstitle()); $sdomain = htmlspecialchars(getsdomain()); $date = htmlspecialchars(getdate2()); $fmsg = htmlspecialchars(getfmsg()); $rm = htmlspecialchars(getrm()); if(canreg()) { $arv = "e"; }else{ $arv= "d"; } echo "<onevent type=\"onenterforward\">"; echo "<refresh> <setvar name=\"sesp\" value=\"$xtm\"/> <setvar name=\"pmaf\" value=\"$pmaf\"/> <setvar name=\"fmsg\" value=\"$fmsg\"/> <setvar name=\"areg\" value=\"$arv\"/> <setvar name=\"fvw\" value=\"$fvw\"/> <setvar name=\"stitle\" value=\"$stitle\"/> <setvar name=\"sdomain\" value=\"$sdomain\"/> <setvar name=\"date\" value=\"$date\"/> <setvar name=\"rm\" value=\"$rm\"/> "; echo "</refresh></onevent>"; echo "<p align=\"center\">"; echo "<b>General Settings</b><br/>"; echo "</p>"; echo "<p>"; echo "Session Period: "; echo "<input name=\"sesp\" format=\"*N\" maxlength=\"3\" size=\"3\"/>"; echo "<br/>PM Antiflood: "; echo "<input name=\"pmaf\" format=\"*N\" maxlength=\"3\" size=\"3\"/>"; echo "<br/>Forum Message: "; echo "<input name=\"fmsg\" maxlength=\"255\" />"; echo "<br/>Login Page Message: "; echo "<input name=\"rm\" maxlength=\"2550\" />"; echo "<br/>Registration: "; echo "<select name=\"areg\" value=\"$arv\">"; echo "<option value=\"e\">Enabled</option>"; echo "<option value=\"d\">Disabled</option>"; echo "</select><br/>"; echo "View:"; echo "<select name=\"fvw\" value=\"$fvw\">"; //$vname[0]="Drop Menu"; $vname[0]="Horizontal Links"; $vname[1]="Nothing"; for($i=0;$i<count($vname);$i++) { echo "<option value=\"$i\">$vname[$i]</option>"; } echo "</select>"; echo "<p align=\"center\">"; echo "<b>Site Name Details</b><br/>"; echo "</p>"; echo "Site Name: "; echo "<input name=\"stitle\" maxlength=\"255\" /><br/>"; echo "Site Domain: "; echo "<input name=\"sdomain\" maxlength=\"255\" /><br/>"; echo "Site Year: "; echo "<input name=\"date\" maxlength=\"255\" /><br/>"; echo " <br/><anchor>Submit <go href=\"ownproc.php?action=general&sid=$sid\" method=\"post\"> <postfield name=\"sesp\" value=\"$(sesp)\"/> <postfield name=\"fmsg\" value=\"$(fmsg)\"/> <postfield name=\"stitle\" value=\"$(stitle)\"/> <postfield name=\"sdomain\" value=\"$(sdomain)\"/> <postfield name=\"date\" value=\"$(date)\"/> <postfield name=\"areg\" value=\"$(areg)\"/> <postfield name=\"pmaf\" value=\"$(pmaf)\"/> <postfield name=\"fvw\" value=\"$(fvw)\"/> <postfield name=\"rm\" value=\"$(rm)\"/> </go></anchor> "; echo "</p>"; echo "<p align=\"center\">"; echo "<a href=\"index.php?action=owncp&sid=$sid\"><img src=\"images/admn.gif\" alt=\"*\"/>"; echo "owncp</a><br/>"; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo "</p></card>"; }
Code:
if($action=="general") { $xtm = $_POST["sesp"]; $fmsg = $_POST["fmsg"]; $areg = $_POST["areg"]; $pmaf = $_POST["pmaf"]; $fvw = $_POST["fvw"]; $stitle = $_POST["stitle"]; $sdomain = $_POST["sdomain"]; $date = $_POST["date"]; $rm = $_POST["rm"]; if($areg=="d") { $arv = 0; }else{ $arv = 1; } echo "<card id=\"main\" title=\"$stitle\">"; echo "<p align=\"center\">"; $res = mysql_query("UPDATE ibwf_settings SET value='".$fmsg."' WHERE name='4ummsg'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forum Message updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Forum message<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$rm."' WHERE name='rm'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Login Page Message updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Login Page<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$date."' WHERE name='date'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site Date updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Site Date<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$stitle."' WHERE name='stitle'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site Name updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Site Name<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$sdomain."' WHERE name='sdomain'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Site Domain updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Site Domain<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$xtm."' WHERE name='sesxp'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Session Period updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Session Period<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$pmaf."' WHERE name='pmaf'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>PM antiflood is $pmaf seconds<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating PM antiflood value<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$arv."' WHERE name='reg'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Registration updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Registration<br/>"; } $res = mysql_query("UPDATE ibwf_settings SET value='".$fvw."' WHERE name='fview'"); if($res) { echo "<img src=\"images/ok.gif\" alt=\"O\"/>Forums View updated successfully<br/>"; }else{ echo "<img src=\"images/notok.gif\" alt=\"X\"/>Error Updating Forums View<br/>"; } echo "<br/>"; echo "<a href=\"owncp.php?action=general&sid=$sid\">"; echo "Edit general settings</a><br/>"; echo "<a href=\"index.php?action=owncp&sid=$sid\"><img src=\"images/admn.gif\" alt=\"*\"/>"; echo "Admin CP</a><br/>"; echo "<a href=\"index.php?action=main&sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>"; echo "Home</a>"; echo "</p></card>"; }