source: subversion/sites/other/tilesAtHome/lib/log.inc @ 3655

Last change on this file since 3655 was 2272, checked in by ojw, 13 years ago

tiles at home website

File size: 316 bytes
Line 
1<?php
2
3function logMsg($Text, $Priority){
4  $Filename = sprintf("/home/ojw/public_html/Log/Data/messages_p%d.txt", $Priority);
5  $fp = fopen($Filename, "a");
6  if(!$fp)
7    return;
8 
9  fputs($fp, date("Y-m-d H:i:s ") . $Text . "\n");
10}
11
12function logSqlError(){
13  if(mysql_errno())
14    logMsg(mysql_error(), 2);
15}
16?>
Note: See TracBrowser for help on using the repository browser.