mirror of
https://github.com/Floriansylvain/projet_programmation_web.git
synced 2026-10-18 20:44:11 +02:00
π Moved class and scripts.
This commit is contained in:
1 parent
2d2ff696c2
commit
228d25c279
4 files changed
+3
-4
No files matched your search
@@ -10,10 +10,9 @@ class dump {
|
|||||||
$this->pdo = $pdo;
|
$this->pdo = $pdo;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public function sendThese() {
|
public function sendThese() {
|
||||||
$sql = 'SELECT * FROM theses';
|
$sql = 'SELECT * FROM theses';
|
||||||
$req = $pdo->query($sql);
|
$req = $this->pdo->query($sql);
|
||||||
while($row = $req->fetch()) {
|
while($row = $req->fetch()) {
|
||||||
echo "<p>" . $row['author'] . " | " . $row['title'] . "</p>";
|
echo "<p>" . $row['author'] . " | " . $row['title'] . "</p>";
|
||||||
}
|
}
|
||||||
File renamed without changes.
@@ -1,10 +1,10 @@
|
|||||||
<?php
|
<?php
|
||||||
$pdo = new PDO('mysql:host=localhost;dbname=projet_prog_web', 'root', 'root');
|
$pdo = new PDO('mysql:host=localhost;dbname=projet_prog_web', 'root', 'root');
|
||||||
|
|
||||||
// dump_abes_thesesfr.csv
|
|
||||||
|
|
||||||
$row = 1;
|
$row = 1;
|
||||||
if (($handle = fopen("dump_abes_thesesfr.csv", "r")) !== FALSE) {
|
if (($handle = fopen("scripts/dump_abes_thesesfr.csv", "r")) !== FALSE) {
|
||||||
while (($data = fgetcsv($handle, 10000, ";")) !== FALSE) {
|
while (($data = fgetcsv($handle, 10000, ";")) !== FALSE) {
|
||||||
$num = count($data);
|
$num = count($data);
|
||||||
echo "<p>---------------- " . $row . " -----------------<br /></p>\n";
|
echo "<p>---------------- " . $row . " -----------------<br /></p>\n";
|
||||||
|
|||||||
File renamed without changes.
|
500 Internal Server Error
An error occurred: An error occurred Gitea Version: 28.1.0 |