Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Michael R Lundquist
zipAPI
Commits
7c7bab4e
Commit
7c7bab4e
authored
Nov 13, 2018
by
michael lundquist
Browse files
Trying to fix file paths.
parent
050d5d4c
Changes
2
Hide whitespace changes
Inline
Side-by-side
SQLlogin.php
View file @
7c7bab4e
...
...
@@ -9,31 +9,6 @@ to describe in green geeks:
table> select a table> structure
checked tables:
employee
change pw to a 64 byte hash
https://stackoverflow.com/questions/14722305/what-kind-of-datatype-should-one-use-to-store-hashes
use sha2_512 for PW hashes
https://stackoverflow.com/questions/1966154/sha-512-library-for-php
jobs
market
schedule is the same, but add some fields to it
EMP_ID here is the admin
shift
chttp://php.net/manual/en/function.mktime.php
mktime gets a timestamp for a time
to add to schedule:
-delete accounts that never set the password through the email
add a cron job to delete fake user accounts:
https://code.tutsplus.com/tutorials/managing-cron-jobs-with-php--net-19428
this page connects to the SQL server. It includes
the username and password, which are private.
...
...
@@ -41,7 +16,7 @@ Hence, it won't be put on the public web server.
http://wiki.hashphp.org/PDO_Tutorial_for_MySQL_Developers
*/
include_once
(
dirname
(
__FILE__
)
.
"
..
/configNuts.php"
);
include_once
(
dirname
(
__FILE__
)
.
"/configNuts.php"
);
function
SQLlogin
(){
$server
=
"localhost"
;
...
...
@@ -51,13 +26,13 @@ function SQLlogin(){
if
(
strstr
(
PHP_ROOT
,
"nuts"
)
===
FALSE
){
//greengeeks credentials
$server
=
"m
ynutrients123
.com"
;
$server
=
"m
ikeroservices
.com"
;
$username
=
"sellmysh"
;
$password
=
"j8C4Rrh5f9"
;
}
$con
=
new
mysqli
(
$server
,
$username
,
$password
);
$con
->
select_db
(
"sellmysh_
nuts
"
);
//TRUE on success, FALSE on fail
$con
->
select_db
(
"sellmysh_
zip
"
);
//TRUE on success, FALSE on fail
return
$con
;
}
...
...
queryPrep.php
View file @
7c7bab4e
...
...
@@ -12,7 +12,7 @@ splat operator (...) :
call RESULT->FREE() on the result
*/
include_once
(
dirname
(
__FILE__
)
.
"/SQLlogin.php"
);
include_once
(
dirname
(
__FILE__
)
.
"
..
/exceptions.php"
);
include_once
(
dirname
(
__FILE__
)
.
"/exceptions.php"
);
function
resultQuery
(
$queryString
,
$paramArr
,
$paramTypes
=
NULL
){
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment