From: <tim...@us...> - 2010-07-13 18:12:25
|
Revision: 3618 http://web-erp.svn.sourceforge.net/web-erp/?rev=3618&view=rev Author: tim_schofield Date: 2010-07-13 18:12:18 +0000 (Tue, 13 Jul 2010) Log Message: ----------- Gjergj Sheldija: MiscFunctions.php - Correctly show sourceforge logo only when an internet connection exists Modified Paths: -------------- trunk/doc/Change.log.html trunk/includes/MiscFunctions.php trunk/includes/footer.inc Modified: trunk/doc/Change.log.html =================================================================== --- trunk/doc/Change.log.html 2010-07-13 18:12:00 UTC (rev 3617) +++ trunk/doc/Change.log.html 2010-07-13 18:12:18 UTC (rev 3618) @@ -1,5 +1,6 @@ <p><font SIZE=4 COLOR=BLUE><b>webERP Change Log</b></font></p> <p></p> +<p>13/07/10 Gjergj Sheldija: MiscFunctions.php - Correctly show sourceforge logo only when an internet connection exists</p> <p>13/07/10 Tim: MRPDemandTypes.php - Bug fixes, correctly do the workflow, fix sql quoting errors and layout changes</p> <p>13/07/10 Tim: MRPDemands.php - Bug fixes, correctly do the workflow, fix sql quoting errors and layout changes</p> <p>13/07/10 Tim: MiscFunctions.js - Revert formatting changes till I can ascertain why the numbers only function stopped working</p> Modified: trunk/includes/MiscFunctions.php =================================================================== --- trunk/includes/MiscFunctions.php 2010-07-13 18:12:00 UTC (rev 3617) +++ trunk/includes/MiscFunctions.php 2010-07-13 18:12:18 UTC (rev 3618) @@ -273,7 +273,7 @@ // Either function args, or included file name(s) $msg .= ' ('; foreach( $frame['args'] as $val ) { - + $typ = gettype( $val ); switch( $typ ) { case 'array': @@ -293,15 +293,15 @@ case 'string': $msg .= $val . ', '; break; - + case 'integer': $msg .= sprintf( "%d, ", $val ); break; - + default: $msg .= '<' . gettype( $val ) . '>, '; break; - + } $msg .= ' )'; } @@ -313,4 +313,14 @@ return; } + +function http_file_exists($url) { + $f=@fopen($url,"r"); + if($f) { + fclose($f); + return true; + } + return false; +} + ?> \ No newline at end of file Modified: trunk/includes/footer.inc =================================================================== --- trunk/includes/footer.inc 2010-07-13 18:12:00 UTC (rev 3617) +++ trunk/includes/footer.inc 2010-07-13 18:12:18 UTC (rev 3618) @@ -25,7 +25,7 @@ echo '<tr><td class="footer">webERP ' . _('Copyright') . ' © weberp.org - '.date('Y').'</td></tr>'; - if(file_exists('http://sflogo.sourceforge.net/sflogo.php')) { + if(http_file_exists('http://sflogo.sourceforge.net/sflogo.php')) { echo '<tr><td class="footer"><a href="https://sourceforge.net/projects/web-erp"><img src="http://sflogo.sourceforge.net/sflogo.php?group_id=70949&type=12" width="120" height="30" border="0" alt="Get webERP web-based ERP Accounting at SourceForge.net. Fast, secure and Free Open Source software downloads" /></a></td></tr>'; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |