Last active
December 30, 2015 21:49
-
-
Save iugonet/7890548 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$link = mysql_connect('localhost','selectOnlyUser','pass'); | |
if (!$link){ | |
die('[WDSJ] Connection Error'.mysql_error()); | |
} | |
$db_selected = mysql_select_db('wdsj', $link); | |
if (!$db_selected){ | |
die('[WDSJ] Database Selection Error'.mysql_error()); | |
} | |
?> | |
<?php | |
$result = mysql_query('SELECT * FROM doc'); | |
if (!$result) { | |
die('[WDSJ] Query failed.'.mysql_error()); | |
} | |
?> | |
IUGONET TABLE | |
<TABLE> | |
<TR><TH>DOI suffix</TH><TH>Version</TH><TH>User ID</TH><TH>DOC_TYPE_ID</TH><TH>Document</TH></TR> | |
<?php | |
while ($row = mysql_fetch_assoc($result)){ | |
print('<TR><TD>'.$row['doi_suffix'].'</TD><TD>'.$row['version'].'</TD><TD>'.$row['user_id'].'</TD><TD>'.$row['doc_type_id'].'</TD><TD>'.$row['document'].'</TD></TR>'); | |
} | |
?> | |
</TABLE> | |
<?php | |
mysql_close($link); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment