Difference between revisions of "Genesetdb"

From Pathology Education Instructional Resource
Jump to: navigation, search
(Created page with "<?php $con= mysqli_connect("localhost", "jrsinger", "U6d19lrBFC48z2fpF1K5PcRy80XS17QC", "genesetdb"); if(mysqli_connect_errno()) { die( "could not connect: " . mysqli_connect...")
 
Line 1: Line 1:
 +
<syntaxhighlight lang="php">
 
<?php
 
<?php
 
$con= mysqli_connect("localhost", "jrsinger", "U6d19lrBFC48z2fpF1K5PcRy80XS17QC", "genesetdb");
 
$con= mysqli_connect("localhost", "jrsinger", "U6d19lrBFC48z2fpF1K5PcRy80XS17QC", "genesetdb");
Line 44: Line 45:
 
';
 
';
 
?>
 
?>
 +
</syntaxhighltight>

Revision as of 02:26, 26 October 2013

<syntaxhighlight lang="php"> <?php $con= mysqli_connect("localhost", "jrsinger", "U6d19lrBFC48z2fpF1K5PcRy80XS17QC", "genesetdb"); if(mysqli_connect_errno()) { die( "could not connect: " . mysqli_connect_error()); } echo' <html>

 <head>
   <title>genetable</title>
 </head>
 <body>

Genetable

'; $sql="SELECT * FROM `workaround`;"; $result= mysqli_query($con,$sql); $pid=1; $genes=0; while ($row=mysqli_fetch_array($result)) { for($i=0; $i<200; $i++) { mysqli_query($con,"INSERT INTO TABLE `finalgeneset` VALUES(BIGINT UNSIGNED AUTO_INCREMENT PRIMARY KEY" . $pid . ",". $row[$genes] . ");"); echo ' '; $genes++; } $pid++; $genes = 0; } echo'
Experiment Number Gene ID
' . $pid . ' ' . $row[$genes] . '
 </body>

</html> '; ?> </syntaxhighltight>