Skip to content

Commit

Permalink
Added Link to Policy Documents
Browse files Browse the repository at this point in the history
  • Loading branch information
juliansetiadi committed Jan 10, 2024
1 parent 9e09251 commit 5e5d1dc
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions public/pages/profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,22 @@

</table> -->

<h3 class="mt-5">Policy Documents</h3>
<ul>
<?php
// Specify the path to your PDF documents
$pdfDirectory = 'policy_documents/';

// Get all PDF files from the directory
$pdfFiles = glob($pdfDirectory . '*.pdf');

// Generate links for each PDF file without the ".pdf" extension
foreach ($pdfFiles as $pdfFile) {
$pdfFileName = basename($pdfFile, '.pdf');
echo '<li><a href="' . $pdfDirectory . $pdfFile . '" target="_blank">' . $pdfFileName . '</a></li>';
}
?>
</ul>

</div>
</div>
Expand Down
Binary file added public/policy_documents/Test 1.pdf
Binary file not shown.
Binary file added public/policy_documents/Test 2.pdf
Binary file not shown.
Binary file added public/policy_documents/Test 3.pdf
Binary file not shown.

0 comments on commit 5e5d1dc

Please sign in to comment.