'; echo''; echo''; echo''; echo''; echo''; echo''; echo'
'; echo ' '; echo '
'; echo '  '; echo ' '; echo '
'; echo '
'; echo ''; echo '
'; echo '
'; echo "\r"; echo "\r"; echo ''; echo ''; echo ''; echo ''; echo ''; echo '

'; echo $row[5]; echo '

'; echo "\r"; echo ''; echo ''; $region_id_chk=$region_id_chk+1; $current_regionid=$row[4]; } //executed every time the region changes. The last labels are added and a horizontal line. The next regions table is set up and the column set back to 1 if ($current_regionid != $row[4]) { echo ''; echo ''; echo ''; echo ''; echo ''; echo ''; $label[1]=""; $label[2]=""; $label[3]=""; $label[4]=""; $label[5]=""; echo ''; echo '

'; echo $label[1]; echo '

'; echo $label[2]; echo '

'; echo $label[3]; echo '

'; echo $label[4]; echo '

'; echo $label[5]; echo '

'; echo ''; echo ''; echo ''; echo ''; echo '

'; echo $row[5]; echo '

'; echo ''; echo ''; $current_regionid=$row[4]; $column=1; } //starts a new row and displays the labels after 5 images are displayed if ($column>$numcolumns) { echo ''; echo "\r"; echo ''; echo ''; echo ''; echo ''; echo ''; echo ''; echo ''; echo ''; $label[1]=""; $label[2]=""; $label[3]=""; $label[4]=""; $label[5]=""; //$label[6]=""; $column=1; } //displays one thumbnail with the link echo "\r"; echo "\t"; echo ''; $label[$column]=$row[3]; $column=$column+1; //end of loop } //ends the current row and starts a row for the last labels echo ''; echo ''; $counter=1; //displays labels only for the number of pictures in the final row while ($counter <= $column) { echo ''; $counter=$counter+1; } //Update views in database $sql80='SELECT * from country where country_id='; $sql81=$sql80.$countryNum; //echo $sql81; $result82 = @mysqli_query($conn,$sql81); $row82 = mysqli_fetch_row($result82); $views = $row82[5]+1; //echo $views; $sql40='UPDATE country SET views='; $sql41=' WHERE country_id='; $update_views_query=$sql40.$views.$sql41.$countryNum; //echo $update_views_query; mysqli_query($conn,$update_views_query); //closes the database connection mysqli_close($conn); ?>

'; echo $label[1]; echo '

'; echo $label[2]; echo '

'; echo $label[3]; echo '

'; echo $label[4]; echo '

'; echo $label[5]; echo '

'; echo ''; echo '
'; echo '

'; echo $label[$counter]; echo '


Africa

Asia

Europe

North America

South America

South Pacific