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
1196aa57
Commit
1196aa57
authored
Feb 20, 2016
by
Nico Schallehn
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test
parent
1ee7c373
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
media.class.php
media.class.php
+3
-3
No files found.
media.class.php
View file @
1196aa57
...
@@ -291,7 +291,7 @@ class Media {
...
@@ -291,7 +291,7 @@ class Media {
//echo " fail2!".PHP_EOL;
//echo " fail2!".PHP_EOL;
echo
$this
->
Console
->
error
(
"keine summary gefunden für imdbID "
.
$imdbID
.
"!"
)
.
PHP_EOL
;
echo
$this
->
Console
->
error
(
"keine summary gefunden für imdbID "
.
$imdbID
.
"!"
)
.
PHP_EOL
;
}
}
$tmdbURL
=
"https://api.themoviedb.org/3/movie/"
.
$tmdb
[
"movie_results"
][
0
][
"id"
]
.
"?api_key="
.
$t
mdbKey
.
"&language=de&append_to_response=trailers"
;
$tmdbURL
=
"https://api.themoviedb.org/3/movie/"
.
$tmdb
[
"movie_results"
][
0
][
"id"
]
.
"?api_key="
.
$t
his
->
config
[
"ApiKeys"
][
'Tmdb_Key'
]
.
"&language=de&append_to_response=trailers"
;
$tmdbData1
=
$this
->
jsonCacheDecoder
(
$tmdbURL
);
$tmdbData1
=
$this
->
jsonCacheDecoder
(
$tmdbURL
);
if
(
isset
(
$tmdbData1
[
"trailers"
][
"youtube"
][
0
][
"source"
])){
if
(
isset
(
$tmdbData1
[
"trailers"
][
"youtube"
][
0
][
"source"
])){
//TODO youtube Key auf 11 Zeichen prüfen!!
//TODO youtube Key auf 11 Zeichen prüfen!!
...
@@ -303,7 +303,7 @@ class Media {
...
@@ -303,7 +303,7 @@ class Media {
}
}
}
else
{
}
else
{
$tmdbURL2
=
"https://api.themoviedb.org/3/movie/"
.
$tmdb
[
"movie_results"
][
0
][
"id"
]
.
"?api_key="
.
$t
mdbKey
.
"&language=en&append_to_response=trailers"
;
$tmdbURL2
=
"https://api.themoviedb.org/3/movie/"
.
$tmdb
[
"movie_results"
][
0
][
"id"
]
.
"?api_key="
.
$t
his
->
config
[
"ApiKeys"
][
'Tmdb_Key'
]
.
"&language=en&append_to_response=trailers"
;
$tmdbData2
=
$this
->
jsonCacheDecoder
(
$tmdbURL2
);
$tmdbData2
=
$this
->
jsonCacheDecoder
(
$tmdbURL2
);
if
(
isset
(
$tmdbData2
[
"trailers"
][
"youtube"
][
0
][
"source"
])){
if
(
isset
(
$tmdbData2
[
"trailers"
][
"youtube"
][
0
][
"source"
])){
$youtubeEN
=
str_replace
(
"&hd=1"
,
""
,
$tmdbData1
[
"trailers"
][
"youtube"
][
0
][
"source"
]);
$youtubeEN
=
str_replace
(
"&hd=1"
,
""
,
$tmdbData1
[
"trailers"
][
"youtube"
][
0
][
"source"
]);
...
@@ -314,7 +314,7 @@ class Media {
...
@@ -314,7 +314,7 @@ class Media {
}
}
}
}
else
{
else
{
echo
$this
->
Console
->
error
(
"kein Trailer gefunden für imdbID "
.
$
Film
[
"imdbID"
]
.
"!"
)
.
PHP_EOL
;
echo
$this
->
Console
->
error
(
"kein Trailer gefunden für imdbID "
.
$
imdbID
.
"!"
)
.
PHP_EOL
;
}
}
}
}
}
else
{
}
else
{
...
...
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