Summary Files Commits Branches @commit @diff @stats
path: root / src / index.php
diff options
context:
space:
mode:
Commitf9e2090a1028712ecc6e1b0c71390c821689b414 (patch)
Author
 Syndamia <kamen.d.mladenov@protonmail.com>
2021-04-01 09:43:48 +0300
Committer
 Syndamia <kamen.d.mladenov@protonmail.com>
2021-04-01 09:43:48 +0300
Filesfed1608498f34299d7e3039cf3290c81e3e84875 /src/index.php
devrix-job-board-f9e2090a1028712ecc6e1b0c71390c821689b414.tar
devrix-job-board-f9e2090a1028712ecc6e1b0c71390c821689b414.tar.gz
devrix-job-board-f9e2090a1028712ecc6e1b0c71390c821689b414.zip
Parente9ba7fbcff47f0e4a03d74b857e9864d67a8b163 (diff)
Implemented getById from DB and changed some method names
1 files changed, 6 insertions, 2 deletions
-rw-r--r--src/index.php8
diff --git a/src/index.php b/src/index.php
index ecebcd9..55bba39 100644
--- a/src/index.php
+++ b/src/index.php
@@ -3,8 +3,12 @@
include_once("models/JobOffer.php");
$jb = new JobOffer("Test", "A test", "TheTest", 11);
- JobOffer::insertInDB($jb);
- foreach(JobOffer::getAll() as $key => $obj) {
+ // JobOffer::insertInDB($jb);
+ foreach(JobOffer::getAllFromDB() as $key => $obj) {
echo "{$obj->id} {$obj->title}<br>";
}
+ echo "<br>";
+
+ $gottenjb = JobOffer::getFromDBById(1);
+ echo $gottenjb->title;
?>