Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CMPT370_Group_6
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
CMPT 370 Project
CMPT370_Group_6
Commits
c1cea5e4
Commit
c1cea5e4
authored
3 years ago
by
Brett Popowycz (bwp265)
Browse files
Options
Downloads
Patches
Plain Diff
removed all https
parent
86a15ecf
Branches
workingForBrett
Branches containing commit
No related tags found
1 merge request
!5
Removed https
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
server/server.js
+6
-6
6 additions, 6 deletions
server/server.js
src/components/Login.js
+1
-1
1 addition, 1 deletion
src/components/Login.js
src/components/Register.js
+1
-1
1 addition, 1 deletion
src/components/Register.js
with
8 additions
and
8 deletions
server/server.js
+
6
−
6
View file @
c1cea5e4
...
...
@@ -163,17 +163,17 @@ app.get('/', (req, res) => {
console
.
log
(
req
.
session
);
//res.redirect("http://localhost:3000/");
//res.send("Hey");
res
.
redirect
(
"
http
s
://localhost:3000
/register
"
);
res
.
redirect
(
"
http://localhost:3000
"
);
});
app
.
use
(
'
/
'
,
express
.
static
(
'
pages
'
));
//FIXME: HTTPS server giving Error code: SSL_ERROR_RX_RECORD_TOO_LONG on firefox
//Create the Http server
http
.
createServer
(
app
).
listen
(
PORT
,
HOST
);
//Create the identical https server
https
.
createServer
(
options
,
app
).
listen
(
443
,
HOST
);
//
//Create the Http server
//
http.createServer(app).listen(PORT, HOST);
//
//Create the identical https server
//
https.createServer(options, app).listen(443, HOST);
//
app.listen(PORT, HOST);
app
.
listen
(
PORT
,
HOST
);
console
.
log
(
'
up and running
'
);
\ No newline at end of file
This diff is collapsed.
Click to expand it.
src/components/Login.js
+
1
−
1
View file @
c1cea5e4
...
...
@@ -25,7 +25,7 @@ const handleSubmitClick = (e) => { //handle submit event.
body
:
JSON
.
stringify
({
username
:
e
.
target
.
ID
.
value
,
password
:
e
.
target
.
password
.
value
})
};
fetch
(
'
http
s
://localhost:443/login
'
,
requestOptions
)
fetch
(
'
http://localhost:443/login
'
,
requestOptions
)
.
then
((
response
)
=>
{
console
.
log
(
response
)
});
...
...
This diff is collapsed.
Click to expand it.
src/components/Register.js
+
1
−
1
View file @
c1cea5e4
...
...
@@ -28,7 +28,7 @@ const handleSubmitClick = (e) => { //handle submit event.
body
:
JSON
.
stringify
(
body
)
};
fetch
(
'
http
s
://localhost:443/register
'
,
requestOptions
)
fetch
(
'
http://localhost:443/register
'
,
requestOptions
)
.
then
((
result
)
=>
{
console
.
log
(
result
);
})
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment