InstitutionCode_Specimen; $CollectionCode_Specimen = $row->CollectionCode_Specimen; $UnitID_Specimen = $row->UnitID_Specimen; $BasisOfRecord = $row->FK_BasisOfRecord; $KindOfUnit = $row->FK_KindOfUnit; $AccessionNo = $row->AccessionNo; $AccessionName = $row->AccessionName; $PrepType = $row->FK_PrepType; $PrepDate = $row->PrepDate; $PrepStaff = $row->FK_PrepStaff; $PrepMaterials = $row->PrepMaterials; $PrepProcess = $row->PrepProcess; $ExpeditionDetails = $row->ExpeditionDetails; $BiogeoRegion = $row->FK_BiogeographicRegion; $CountryName = $row->FK_Country; $Region = $row->Region; $Locality = $row->Locality; $Locality_ID = $row->Locality_ID; $SeasAndOceans = $row->FK_SeasAndOceans; $AltitudeMin = $row->AltitudeMin; $AltitudeMax = $row->AltitudeMax; $AltitudeUnit = $row->AltitudeUnit; $AltitudeRaw = $row->AltitudeRaw; $AltitudeMethod = $row->AltitudeMethod; $AltitudeAccuracy = $row->AltitudeAccuracyStatement; $DepthMin = $row->DepthMin; $DepthMax = $row->DepthMax; $DepthUnit = $row->DepthUnit; $DepthRaw = $row->DepthRaw; $DepthMethod = $row->DepthMethod; $DepthAccuracy = $row->DepthAccuracyStatement; $CoordinatesAccuracy = $row->CoordinatesAccuracyStatement; $CoordinatesError = $row->CoordinatesErrorDistance; $LatitudeMin = $row->LatitudeMin; $LatitudeMax = $row->LatitudeMax; $LatitudeRaw = $row->LatitudeRaw; $LongitudeMin = $row->LongitudeMin; $LongitudeMax = $row->LongitudeMax; $LongitudeRaw = $row->LongitudeRaw; $GeoDatum = $row->GeodeticDatum; $Collectors = $row->Collectors; $CollectorsNo = $row->CollectorsNo; $CollectionDateMin = substr($row->CollectionDateMin, 0, -9); if($CollectionDateMin == "0000-00-00") { $CollectionDateMin = "YYYY-MM-DD"; } $CollectionDateMax = substr($row->CollectionDateMax, 0, -9); if($CollectionDateMax == "0000-00-00") { $CollectionDateMax = "YYYY-MM-DD"; } $CollectionYear = $row->CollectionYear; $CollectionMethod = $row->CollectionMethod; $CollectionNotes = $row->CollectionNotes; $Habitat = $row->Habitat; $SoilTexture = $row->FK_SoilTexture; $SoilpH = $row->FK_SoilpH; $HabitatCode = $row->FK_HabitatCode; $LandUseCode = $row->FK_LandUseCode; $Slope = $row->FK_Slope; $Aspect = $row->FK_Aspect; $Type = $row->FK_Type; $TypeDesignation = $row->TypeDesignation; $Sex = $row->FK_Sex; $GeoMethod = $row->FK_GeocodeMethod; $LifeStage = $row->LifeStage; $LifeForm = $row->LifeForm; $EscapedCoordinates = $row->EscapedCoordinates; $Permission = $row->Permission; $BlockedUntil = $row->Blocked_Until; $BlockedLoan = $row->Blocked_For_Loaning; $BlockedPublish = $row->Blocked_For_Publishing; $LoanConditions = $row->Loan_Conditions; $Notes = $row->Notes; $Notes_Internal = $row->Notes_Internal; } if($_GET['SubSample'] == true) { $formParentFK = $SpecimenTemplate; $result2 = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptoolcollection.ID_Collection, " . " sptooltaxa.NameAuthorYear, " . " sptooltaxa.Genus, " . " sptooltaxa.Subgenus, " . " sptooltaxa.SpecificEpithet, " . " sptooltaxa.Rank, " . " sptooltaxa.InfraspecificEpithet, " . " sptooltaxa.AuthorParenth, " . " sptooltaxa.YearParenth, " . " sptooltaxa.Author, " . " sptooltaxa.Year, " . " sptooltaxa.KindOfIdentification, " . " sptooltaxa.Identifier, " . " sptooltaxa.IdentificationDate, " . " sptooltaxa.IdentificationNotes, " . " sptooltaxa.PreferredFlag " . " FROM sptoolcollection, sptooltaxa " . " WHERE sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptooltaxa.Synecology IS NULL "); while($row = mysqli_fetch_object($result2)) { $NameAuthorYear = $row->NameAuthorYear; $Genus = $row->Genus; $Subgenus = $row->Subgenus; $SpecificEpithet = $row->SpecificEpithet; $InfraspecificEpithet = $row->InfraspecificEpithet; $Rank = $row->Rank; $AuthorParenth = $row->AuthorParenth; $YearParenth = $row->YearParenth; $Author = $row->Author; $Year = $row->Year; $KindOfIdentification = $row->KindOfIdentification; $Identifier = $row->Identifier; $IdentificationDate = $row->IdentificationDate; $IdentificationNotes = $row->IdentificationNotes; $PreferredFlag = "Yes"; } $resultregnum = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptooltaxa.FK_Collection, " . " sptooltaxa.ID_TaxonIdentified, " . " sptoolhighertaxon.HigherTaxon, " . " sptoolhighertaxon.TaxonRank " . " FROM sptooltaxa, sptoolhighertaxon " . " WHERE sptoolhighertaxon.FK_TaxonIdentified = sptooltaxa.ID_TaxonIdentified " . " AND sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptoolhighertaxon.TaxonRank = 'regnum' "); while($row = mysqli_fetch_object($resultregnum)) { $Regnum = $row->HigherTaxon; } $resultphylum = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptooltaxa.FK_Collection, " . " sptooltaxa.ID_TaxonIdentified, " . " sptoolhighertaxon.HigherTaxon, " . " sptoolhighertaxon.TaxonRank " . " FROM sptooltaxa, sptoolhighertaxon " . " WHERE sptoolhighertaxon.FK_TaxonIdentified = sptooltaxa.ID_TaxonIdentified " . " AND sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptoolhighertaxon.TaxonRank = 'phylum' "); while($row = mysqli_fetch_object($resultphylum)) { $Phylum = $row->HigherTaxon; } $resultclassis = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptooltaxa.FK_Collection, " . " sptooltaxa.ID_TaxonIdentified, " . " sptoolhighertaxon.HigherTaxon, " . " sptoolhighertaxon.TaxonRank " . " FROM sptooltaxa, sptoolhighertaxon " . " WHERE sptoolhighertaxon.FK_TaxonIdentified = sptooltaxa.ID_TaxonIdentified " . " AND sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptoolhighertaxon.TaxonRank = 'classis' "); while($row = mysqli_fetch_object($resultclassis)) { $Classis = $row->HigherTaxon; } $resultordo = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptooltaxa.FK_Collection, " . " sptooltaxa.ID_TaxonIdentified, " . " sptoolhighertaxon.HigherTaxon, " . " sptoolhighertaxon.TaxonRank " . " FROM sptooltaxa, sptoolhighertaxon " . " WHERE sptoolhighertaxon.FK_TaxonIdentified = sptooltaxa.ID_TaxonIdentified " . " AND sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptoolhighertaxon.TaxonRank = 'ordo' "); while($row = mysqli_fetch_object($resultordo)) { $Ordo = $row->HigherTaxon; } $resultfamilia = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptooltaxa.FK_Collection, " . " sptooltaxa.ID_TaxonIdentified, " . " sptoolhighertaxon.HigherTaxon, " . " sptoolhighertaxon.TaxonRank " . " FROM sptooltaxa, sptoolhighertaxon " . " WHERE sptoolhighertaxon.FK_TaxonIdentified = sptooltaxa.ID_TaxonIdentified " . " AND sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptoolhighertaxon.TaxonRank = 'familia' "); while($row = mysqli_fetch_object($resultfamilia)) { $Familia = $row->HigherTaxon; } $resultsubfamilia = mysqli_query($GLOBALS["___mysqli_ston"], "SELECT sptooltaxa.FK_Collection, " . " sptooltaxa.ID_TaxonIdentified, " . " sptoolhighertaxon.HigherTaxon, " . " sptoolhighertaxon.TaxonRank " . " FROM sptooltaxa, sptoolhighertaxon " . " WHERE sptoolhighertaxon.FK_TaxonIdentified = sptooltaxa.ID_TaxonIdentified " . " AND sptooltaxa.FK_Collection = '$SpecimenTemplate' " . " AND sptooltaxa.PreferredFlag = '1' " . " AND sptoolhighertaxon.TaxonRank = 'subfamilia' "); while($row = mysqli_fetch_object($resultsubfamilia)) { $Subfamilia = $row->HigherTaxon; } } ?>