From 6b5de8070f19f2cbe36da71cd981005132b36770 Mon Sep 17 00:00:00 2001 From: RuseDanielStefan <48377557+RuseDanielStefan@users.noreply.github.com> Date: Thu, 13 Jun 2019 19:16:44 +0300 Subject: [PATCH] modified oracle database connection --- .../database/smart_search/NeuralNetwork.sql | 4 +- application/mail_site_MVC.php | 4 +- application/makeaccount.php | 10 +- application/security_search/SecurityView.php | 2 +- application/softvuln.php | 28 ----- application/stylesheet.css | 107 +++++++++--------- 6 files changed, 68 insertions(+), 87 deletions(-) diff --git a/application/database/smart_search/NeuralNetwork.sql b/application/database/smart_search/NeuralNetwork.sql index ba8bb52..e17e261 100644 --- a/application/database/smart_search/NeuralNetwork.sql +++ b/application/database/smart_search/NeuralNetwork.sql @@ -496,7 +496,7 @@ END getPredictions; /* * test runs */ - /* +/* DECLARE myTab STRING_TABLE := STRING_TABLE(); myMap MapStringInt := MapStringInt(); @@ -520,4 +520,4 @@ BEGIN DBMS_OUTPUT.PUT_LINE(myMap.getVal(myTab(5))); END; / -*/ \ No newline at end of file +*/ diff --git a/application/mail_site_MVC.php b/application/mail_site_MVC.php index ca7062c..d1c9079 100644 --- a/application/mail_site_MVC.php +++ b/application/mail_site_MVC.php @@ -171,7 +171,7 @@ public function SafeBrowsing($info){ $matches = array(); $matches = $json['matches']; $matches_no = count($matches); - $this->return .= '
Found ' . $matches_no . ' matches.

'; + $this->return .= '
Found ' . $matches_no . ' threats.

'; $this->return .= '
'; if($matches_no != 0){ @@ -190,7 +190,7 @@ public function SafeBrowsing($info){ } } else{ - $this->return .= '
No matches found.

'; + $this->return .= '
No threats found. The site is dafe.

'; } $this->return .= ''; diff --git a/application/makeaccount.php b/application/makeaccount.php index a5ec68f..7de6ca7 100644 --- a/application/makeaccount.php +++ b/application/makeaccount.php @@ -76,18 +76,22 @@ function register(){ $email = $_POST['email']; $result = $conn->query("select id from user where username='".$username."'"); if ($result->num_rows > 0){ - echo "Username exists!"; + echo '
Username exists!query("select id from user where email='".$email."'"); if ($result->num_rows > 0){ - echo "Email exists!"; + echo '
Email exists!
'; return; } $password1 = $_POST['password1']; $password2 = $_POST['password2']; if ($password1 != $password2){ - echo "Passwords does not match!"; + echo '
+ Passwords does not match!
'; return; } if (isset($_POST['age'])){ diff --git a/application/security_search/SecurityView.php b/application/security_search/SecurityView.php index a6d90c9..c55e74d 100644 --- a/application/security_search/SecurityView.php +++ b/application/security_search/SecurityView.php @@ -36,7 +36,7 @@ public function printSecurityInfo($googleEngine) { $keyword = $_POST["keyword"]; - $db = new OracleDatabase("STUDENT", "student0", "localhost/XE"); + $db = new OracleDatabase("student", "STUDENT", "localhost/orcl"); $dbConn = $db->getConn(); $query = " diff --git a/application/softvuln.php b/application/softvuln.php index b1fb14c..d85ebc6 100644 --- a/application/softvuln.php +++ b/application/softvuln.php @@ -26,23 +26,6 @@ require_once("Navbar.php"); ?>
-
-

Filter type 1

-
    -
  • filter 1
  • -
  • filter 2
  • -
  • filter 3
  • -
  • filter 4
  • -
-

Filter type 2

-
    -
  • filter 1
  • -
  • filter 2
  • -
  • filter 3
  • -
  • filter 4
  • -
- -
-
-
-
Date
-
D
-
A
-
V
-
Title
-
Type
-
Platform
-
-
diff --git a/application/stylesheet.css b/application/stylesheet.css index 4e4a23f..5cbf539 100644 --- a/application/stylesheet.css +++ b/application/stylesheet.css @@ -470,12 +470,58 @@ nav ul { /* -------------- FORGOT PASSWORD END --------------*/ + +/* -------------- MAIN START -------------- */ +main {} +/* -------------- MAIN END -------------- */ + +/* -------------- SECTION SLIDESHOW START -------------- */ +.slideshow-container { + display: flex; + justify-content: center; + align-items: center; + height: 75vh; + margin-top: 2em; + margin-bottom: 5em; +} + +.slideshow-container #slide { + display: flex; + justify-content: center; + align-items: center; + width: 90%; + height: 100%; + opacity: 1; + transition: opacity 1.6s; +} + +.slideshow-container #slide.fadeOut { + opacity : 0; +} + +#slide h2 { + position: absolute; + background-color: white; + color: darkblue; + padding: .2em; + font-size: 2em; + opacity: .7; +} + +#slide img { + z-index: -1; + width: 100%; + height: 100%; + +} +/* -------------- SECTION SLIDESHOW END -------------- */ + + + /* -------------- SOFTWARE VULNERABILITIES START -------------- */ @media(min-width:900px){ #softvuln{ - display: grid; - grid-template-columns: 15% 85%; - grid-template-rows: 100%; + text-align: center; } #filter{ @@ -494,9 +540,10 @@ nav ul { } #vuln{ - grid-column: 2; - grid-row: 1; - margin: 1em; + max-width: 60%; + margin-left: auto; + margin-right: auto; + margin-top: 1%; padding: 1em; width: 90%; background-color: #333333; @@ -505,6 +552,8 @@ nav ul { .search{ width: 70%; padding: 1em; + margin-right: auto; + margin-left: auto; } .search img{ width: 3em; @@ -513,7 +562,7 @@ nav ul { margin: 0.1em; } .search button{ - width: 10%; + width: 13%; height: 4em; background-color: white; border: 1px solid darkgray; @@ -546,50 +595,6 @@ nav ul { /* -------------- SOFTWARE VULNERABILITIES START -------------- */ -/* -------------- MAIN START -------------- */ -main {} -/* -------------- MAIN END -------------- */ - -/* -------------- SECTION SLIDESHOW START -------------- */ -.slideshow-container { - display: flex; - justify-content: center; - align-items: center; - height: 75vh; - margin-top: 2em; - margin-bottom: 5em; -} - -.slideshow-container #slide { - display: flex; - justify-content: center; - align-items: center; - width: 90%; - height: 100%; - opacity: 1; - transition: opacity 1.6s; -} - -.slideshow-container #slide.fadeOut { - opacity : 0; -} - -#slide h2 { - position: absolute; - background-color: white; - color: darkblue; - padding: .2em; - font-size: 2em; - opacity: .7; -} - -#slide img { - z-index: -1; - width: 100%; - height: 100%; - -} -/* -------------- SECTION SLIDESHOW END -------------- */ /* -------------- FOOTER START -------------- */ footer {