Hello
Actually I m just a beginner in php so I m facing very basic problems.So can u help me how to insert a new line in php?
Through search I found that "\n" is for new line character, but applying to my code its not working.
Here is my code:
Actually I m just a beginner in php so I m facing very basic problems.So can u help me how to insert a new line in php?
Through search I found that "\n" is for new line character, but applying to my code its not working.
Here is my code:
Code:
<?php
error_reporting (E_ALL ^ E_NOTICE);
$con = mysql_connect("localhost","root","");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("genomics", $con);
$Accession = $_GET['Accession'];
$Locus = $_GET['Locus'];
$Definition = $_GET['Definition'];
$Sequencetype = $_GET['Sequencetype'];
$Sequencelength = $_GET['Sequencelength'];
$Version = $_GET['Version'];
$GI = $_GET['GI'];
$Organism = $_GET['Organism'];
$Authors = $_GET['Authors'];
$Publication = $_GET['Publication'];
$Labaddress = $_GET['Labaddress'];
$Dateofsequencesubmission = $_GET['Dateofsequencesubmission'];
$collabrationown = $_GET['collabrationown'];
$result = mysql_query("SELECT * FROM maintable WHERE Accession = '$Accession'");
while($row = mysql_fetch_array($result))
{
echo "Accession <input type='text' name='Accession' value='".$row['Accession']."'>";
echo "Locus <input type='text' name='Locus' value='".$row['Locus']."'>";
echo "Sequence length <input type='int' name='Sequencelength' value='".$row['Sequencelength']."'>";
echo "Sequence type <input type='text' name='Sequencetype' value='".$row['Sequencetype']."'>";
}
mysql_close($con);
?>
Comment