function phase_post($post, $id, $wiki_page = true)
 {
     global $wgOut, $wgOut, $wgParser;
     if ($post == '') {
         return $post;
     }
     // for sigs...
     $post = convert_pre($post);
     $post = remove_forum_tag_from_post($post);
     $post = awcf_hide_code2($post);
     if ($this->convert_wTitle == '1') {
         $post = wiki_links($post, $this->wiki_titles);
     }
     if ($this->displaysmiles == '1' and $this->viewing_mem_info['displaysmiles'] == '1') {
         $post = awcf_emotions($post, $this->emotions);
     }
     $post = br_convert($post);
     if ($wiki_page) {
         if (GetWikiPageOK($post)) {
             $post = GetWikiPage($post, $id);
         }
     }
     $post = awcf_unhide_code($post);
     $post = awc_wikipase($post, $wgOut);
     # awc_pdie($post);
     $post = Convert($post);
     // $post = Convert($post);
     # $f = array('&lt;/a&gt;', '&lt;a href', '"&gt;', "<a href=",);
     # $r = array('</a>', '<a href', '">', "<a target='blank' href=", '',);
     #  $post = str_replace($f, $r, $post ) ;
     #$post = str_replace("<a href=", "<a target='blank' href=", $post ) ;
     # $post = str_replace('rel="nofollow"', "", $post ) ;
     if (isset($sw[1])) {
         foreach ($sw as $test) {
             $post = HighLightSearchWord($post, $test);
         }
     } else {
         #$post = HighLightSearchWord($post,$extras['word']);
     }
     // needs to be in the loop to check against each post for other extensions triggered
     if (isset($wgParser->mOutput->mHeadItems)) {
         foreach ($wgParser->mOutput->mHeadItems as $k_ID => $mHeadItems) {
             $wgOut->addHeadItem($k_ID, $mHeadItems);
         }
     }
     return $post;
 }
         $type = $_FILES["musicfile"]["type"];
         $sid = $_SESSION["steamid"];
         $name = "";
         if (isset($_POST["musicname"]) and !($_POST["musicname"] == "")) {
             $name = urlencode($_POST["musicname"]);
         } else {
             $name = "Untitled";
         }
         if ($type == "audio/mp3" or $type == "audio/mpeg") {
             $uid = uniqid();
             $url = $uid . ".mp3";
             move_uploaded_file($_FILES["musicfile"]["tmp_name"], "/home/sam/sterling/upload/" . $url);
             Query("INSERT INTO tracks (steamid, name, url) VALUES ('{$sid}', '{$name}', '{$url}');");
             header("Location: https://the-sterling.co.uk/index.php");
         } else {
             $converted = Convert($_FILES["musicfile"]["tmp_name"], $type);
             if ($converted == FALSE) {
                 echo "You must upload an MP3, WAV, M4A, FLAC, OGG or WMA file. Go back and upload a compatible file instead of whatever you uploaded this time. You uploaded a " . $type;
             } else {
                 Query("INSERT INTO tracks (steamid, name, url) VALUES ('{$sid}', '{$name}', '{$converted}');");
                 header("Location: https://the-sterling.co.uk/index.php");
             }
             //header("Location: http://the-sterling.co.uk/index.php");
         }
     } else {
         echo "Upload error. Report to Top Hatted Cat. Here's some debug stuff: ";
         print_r($_FILES);
     }
 } else {
     echo "You have reached your upload quota. Please remove a track before attempting to add another.";
 }
{
// This needs to convert the UUID to a Name LastName combination
$host = "Unknown";
return $host;
}

# Make a new UNIX_TIMESTAMP
$now = time();
# Get all events that are in the future
$DbLink->query("select creatoruuid,dateUTC,eventid,name,eventflags from ossearch.events where dateUTC > $now ORDER BY dateUTC LIMIT 0,10");

while(list($creator,$time,$eventid,$eventname,$event_type) = $DbLink->next_record())
{
 $event_time = date("m/d/Y, h:i a",$time);

 $event_host = Convert($creator);

 if ($event_type == 0) $event_type = "<img height=25px width=25px title='PG Event' src = ./images/events/pink_star.gif>";
 if ($event_type == 1) $event_type = "<img height=25px width=25px title='Mature Event' src = ./images/events/blue_star.gif>";

?>
    <TR>

      <TD><B><?php 
echo $event_time;
?>
</B></TD>
 
      <TD align=center><B><?php 
echo $event_type;
?>
 function sig_get_edit()
 {
     global $wgOut;
     Set_AWC_Forum_SubTitle(get_awcsforum_word('mem_memCP'), $this->membername);
     Set_AWC_Forum_BreadCrumbs(get_awcsforum_word('mem_general_options'));
     Set_AWC_Forum_BreadCrumbs(get_awcsforum_word('mem_edit_sig_option'), true);
     $sig_is = isset($this->mem_info['m_sig']) ? $this->mem_info['m_sig'] : '';
     $html = '<form action="' . awc_url . $this->todo_url . 'save_sig" method="post">';
     $html .= '<table width="100%" cellpadding="0" cellspacing="0">';
     $html .= '<tr><td class="mem_name">';
     $raw_sig = $sig_is;
     $sig_is = remove_forum_tag_from_post($sig_is);
     $sig_is = br_convert($sig_is);
     $sig_is = awc_wikipase($sig_is, $wgOut);
     $sig_is = Convert($sig_is);
     $html .= $sig_is;
     $html .= '</tr></td></table>';
     $html .= '<table class="dl_maintable" cellpadding="0" cellspacing="0"><tr>';
     $html .= '<td width="100%" align="left">';
     $html .= $this->WikiToolBar;
     $html .= '<input name="mem_name" type="hidden" value="' . $this->membername . '">';
     $html .= '<input name="m_id" type="hidden" value="' . $this->m_id . '">';
     $html .= '<textarea name="wpTextbox1" id="wpTextbox1" cols="70%" rows="10" wrap="virtual" class="post_box" onKeyDown="limitText(this.form.wpTextbox1,this.form.countdown,' . $this->sig_length . ');" 
 onKeyUp="limitText(this.form.wpTextbox1,this.form.countdown,' . $this->sig_length . ');"">' . $raw_sig . '</textarea>';
     $html .= '<br />';
     $html .= ' <input type="submit" value="' . get_awcsforum_word('submit') . '">  ' . get_awcsforum_word('cf_SigLength') . ' ' . $this->sig_length . ' / <input readonly type="text" name="countdown" size="3" value="100"></form>';
     $html .= '</td>';
     $html .= '</tr></table></form>';
     self::display_memcp($html);
 }