Skip to content
This repository was archived by the owner on Apr 18, 2021. It is now read-only.

Commit 8131f8b

Browse files
committed
Removed Bug
Shopping Cart session is maintained.
1 parent ab19b9b commit 8131f8b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+3
-6
lines changed

README.md

100644100755
File mode changed.

about.php

100644100755
File mode changed.

account.php

100644100755
File mode changed.

admin-update.php

100644100755
File mode changed.

admin.php

100644100755
File mode changed.

bolt-new-phpmyadmin.sql

100644100755
File mode changed.

bolt.sql

100644100755
File mode changed.

cart.php

100644100755
File mode changed.

config.php

100644100755
File mode changed.

contact.php

100644100755
File mode changed.

css/foundation.css

100644100755
File mode changed.

css/foundation.min.css

100644100755
File mode changed.

css/normalize.css

100644100755
File mode changed.

humans.txt

100644100755
File mode changed.

images/.gitkeep

100644100755
File mode changed.

images/bolt-landscape.jpg

100644100755
File mode changed.

images/bolt-mobile.jpg

100644100755
File mode changed.

images/bolt.jpg

100644100755
File mode changed.

images/products/cap.jpg

100644100755
File mode changed.

images/products/sports_band.jpg

100644100755
File mode changed.

images/products/sports_shoes.jpg

100644100755
File mode changed.

index.php

100644100755
File mode changed.

insert.php

100644100755
File mode changed.

js/foundation.min.js

100644100755
File mode changed.

js/foundation/foundation.abide.js

100644100755
File mode changed.

js/foundation/foundation.accordion.js

100644100755
File mode changed.

js/foundation/foundation.alert.js

100644100755
File mode changed.

js/foundation/foundation.clearing.js

100644100755
File mode changed.

js/foundation/foundation.dropdown.js

100644100755
File mode changed.

js/foundation/foundation.equalizer.js

100644100755
File mode changed.

js/foundation/foundation.interchange.js

100644100755
File mode changed.

js/foundation/foundation.joyride.js

100644100755
File mode changed.

js/foundation/foundation.js

100644100755
File mode changed.

js/foundation/foundation.magellan.js

100644100755
File mode changed.

js/foundation/foundation.offcanvas.js

100644100755
File mode changed.

js/foundation/foundation.orbit.js

100644100755
File mode changed.

js/foundation/foundation.reveal.js

100644100755
File mode changed.

js/foundation/foundation.slider.js

100644100755
File mode changed.

js/foundation/foundation.tab.js

100644100755
File mode changed.

js/foundation/foundation.tooltip.js

100644100755
File mode changed.

js/foundation/foundation.topbar.js

100644100755
File mode changed.

js/vendor/fastclick.js

100644100755
File mode changed.

js/vendor/jquery.cookie.js

100644100755
File mode changed.

js/vendor/jquery.js

100644100755
File mode changed.

js/vendor/modernizr.js

100644100755
File mode changed.

js/vendor/placeholder.js

100644100755
File mode changed.

login.php

100644100755
File mode changed.

logout.php

100644100755
File mode changed.

orders-update.php

100644100755
File mode changed.

orders.php

100644100755
File mode changed.

products.php

100644100755
File mode changed.

register.php

100644100755
File mode changed.

robots.txt

100644100755
File mode changed.

success.php

100644100755
File mode changed.

update-cart.php

100644100755
File mode changed.

update.php

100644100755
File mode changed.

verify.php

100644100755
+3-6
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
<?php
22

3+
//if (session_status() !== PHP_SESSION_ACTIVE) {session_start();}
4+
if(session_id() == '' || !isset($_SESSION)){session_start();}
5+
36
include 'config.php';
47

58
$username = $_POST["username"];
@@ -17,9 +20,6 @@
1720
while($obj = $result->fetch_object()){
1821
if($obj->email === $username && $obj->password === $password) {
1922

20-
//if (session_status() !== PHP_SESSION_ACTIVE) {session_start();}
21-
if(session_id() == '' || !isset($_SESSION)){session_start();}
22-
2323
$_SESSION['username'] = $username;
2424
$_SESSION['type'] = $obj->type;
2525
$_SESSION['id'] = $obj->id;
@@ -28,9 +28,6 @@
2828
}
2929

3030
else {
31-
if(session_id() == '' || !isset($_SESSION)){session_start();}
32-
session_unset();
33-
session_destroy();
3431
header("location:index.php");
3532
}
3633
}

0 commit comments

Comments
 (0)