Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
MediaDBPythonScripte
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
8
Issues
8
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
BA_SI-Projekt
MediaDBPythonScripte
Commits
7c34c490
Commit
7c34c490
authored
Jan 26, 2016
by
Nico Schallehn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test
parent
ece916e0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
4 deletions
+20
-4
media.class.php
media.class.php
+20
-4
No files found.
media.class.php
View file @
7c34c490
...
...
@@ -4,6 +4,8 @@ class Media {
private
$configfile
;
private
$config
;
private
$PfadzumEinlesen
;
private
$PfadzumAusgeben
;
private
$HDDID
;
public
function
__construct
(
$configfile
)
{
$this
->
Console
=
new
Console
();
$this
->
configfile
=
$configfile
;
...
...
@@ -83,14 +85,28 @@ class Media {
echo
"In welchen Verzeichnis liegen die einzulesenden Dateien? ( nur Enter = "
.
$this
->
config
[
"ReadFromDir"
]
.
")"
.
PHP_EOL
;
$Pfad
=
trim
(
fgets
(
STDIN
));
$PfadzumEinlesen
=
(
strlen
(
$Pfad
)
>
0
?
$Pfad
:
$this
->
config
[
"ReadFromDir"
]);
if
(
!
is_dir
(
$PfadzumEinlesen
)){
return
$this
->
Console
->
error
(
"Pfad exisitiert nicht!"
)
.
PHP_EOL
;
$this
->
PfadzumEinlesen
=
(
strlen
(
$Pfad
)
>
0
?
$Pfad
:
$this
->
config
[
"ReadFromDir"
]);
if
(
!
is_dir
(
$this
->
PfadzumEinlesen
)){
return
$this
->
Console
->
error
(
"Pfad Eingabe exisitiert nicht!"
)
.
PHP_EOL
;
}
else
{
echo
"Verzeichnis "
.
$this
->
PfadzumEinlesen
.
" wird für Eingabe verwendet"
.
PHP_EOL
;
}
echo
"In welchen Verzeichnis liegen die einzulesenden Dateien? ( nur Enter = 1)"
.
PHP_EOL
;
$hddid
=
trim
(
fgets
(
STDIN
));
$this
->
HDDID
=
(
strlen
(
$hddid
)
>
0
?
$hddid
:
1
);
$this
->
PfadzumAusgeben
=
$this
->
config
[
"HDD"
][
$hddid
][
"HDDdir"
];
if
(
!
is_dir
(
$this
->
PfadzumAusgeben
)){
return
$this
->
Console
->
error
(
"Pfad für Ausgabe exisitiert nicht!"
)
.
PHP_EOL
;
}
else
{
echo
"Verzeichnis "
.
$this
->
PfadzumAusgeben
.
" wird für Ausgabe verwendet"
.
PHP_EOL
;
}
echo
PHP_EOL
;
return
0
;
//return
;
}
...
...
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