| <?php |
| preg_match( '/[A-Za-z0-9\.\_\-]*/', $_REQUEST['id'], $matches ); |
| $id = $matches[0]; |
| ?><a target="_new" href="http://www.eclipse.org/projects/explain/projects-table.php"><?php |
| include "/home/data/httpd/eclipse-php-classes/system/dbconnection_foundation_ro.class.php"; |
| $_dbc = new DBConnectionFoundation(); |
| $_dbh = $_dbc->connect(); |
| $query = "SELECT ProjectPhase FROM Projects WHERE ProjectID = '$id'"; |
| $result = mysql_query($query,$_dbh); |
| if (!$result) { |
| echo("MySQL Error: ".mysql_error()); |
| } else { |
| while( $row = mysql_fetch_assoc($result) ) { |
| // ---- Phase ---- |
| if( $row['ProjectPhase'] == 'Regular' ) { |
| ?><img src="//www.eclipse.org/projects/images/ok.gif" align="middle" border="0"><?php |
| } else if( $row['ProjectPhase'] == 'Incubation' ) { |
| ?><img src="//www.eclipse.org/projects/images/egg.gif" align="middle" border="0"><?php |
| } else if( $row['ProjectPhase'] == 'Incubation.nc' ) { |
| ?><img src="//www.eclipse.org/projects/images/egg-redx.jpg" align="middle" border="0"><?php |
| } else { |
| ?>?<?php |
| } |
| } |
| } |
| ?></a> |