Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hub.io
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Peyton Tanzillo
hub.io
Commits
6f62a92b
Commit
6f62a92b
authored
6 years ago
by
Joey Ballentine
Browse files
Options
Downloads
Patches
Plain Diff
added some php stuff
parent
77639fce
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
connect-mysql.php
+16
-0
16 additions, 0 deletions
connect-mysql.php
index.html
+24
-1
24 additions, 1 deletion
index.html
with
40 additions
and
1 deletion
connect-mysql.php
0 → 100644
+
16
−
0
View file @
6f62a92b
<?php
DEFINE
(
'DB_USER'
,
'hci_hub_io'
);
DEFINE
(
'DB_PSWD'
,
'HThpytpXkvty5fV'
);
DEFINE
(
'DB_HOST'
,
'db4free.net:3306'
);
DEFINE
(
'DB_NAME'
,
'hci_hub_io'
);
$dbcon
=
mysqli_connect
(
DB_HOST
,
DB_USER
,
DB_PSWD
,
DB_NAME
);
if
(
!
$dbcon
)
{
die
(
'error connecting to database'
);
}
echo
'you have connected successfully'
;
?>
This diff is collapsed.
Click to expand it.
index.html
+
24
−
1
View file @
6f62a92b
...
...
@@ -54,5 +54,28 @@
</div>
</div>
</div>
<?php
include('connect-mysql.php')
$sqlget = "SELECT * FROM Services";
$sqldata = mysqli_query($dbcon, $sqlget) or die('error getting data');
echo "<table>";
echo "<tr><th>ID</th><th>Name</th></tr>"
while($row = mysqli_fetch_array($dbdata, MYSQLI_ASSOC)) {
echo "<tr><td>";
echo $row['service_id'];
echo "</td><td>";
echo $row['name']
echo "</td></tr>";
}
echo "</table>";
?>
</body>
</html>
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