PK's MovieDB Release.V3.0 (Dynamic PHP View)

If you made a template for printing or HTML export, you can offer it to the others here. You can also ask here for help about these templates
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

looks fine how you have done it in that example page. was there something more u wanted to do with them?
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

kazgor wrote:
Thermal Ions wrote:110mb is ok, except that the 50 simultaneous ftp connections gets very annoying at times. :(

I've ended up just saving a little sql script to run each time after uploading that updates the picturename field in the database to point to a copy of the default_cover.jpg I placed into the antexport directory

Code: Select all

update <tablename> set picturename = 'default_cover.jpg' where picturename ='';
Cheers.......Thermal
Thermal's Movie db / TV Series db
Neat.. i'll have to make use of that one :)

i've done some tweaking to the template.. :)

http://brunesmedia.110mb.com/moviedb3/index.php

Click on a film, i've added the IMDB Trivia
On the site above you have the imdb on the right side and the other stuff on the left.
Can you tell how to do that?

Updat:
Ihave found it...

Can you tell me how to add the go to a,b,c,e, enc. on the right side?
In the old versie it was there but now it's gone.

Second question is...
On the box year i have some titels by other but wy is that. The movie's have a year in the field but are not showed by the wright year.

Thirt queastion...
When i sears for thriller, it's only sears in the description and not in the Categorie field
What must i change that it will sears in everything in the site...
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

Hi JP.

for your questions.

1.

the jumpto Artist letter, ie A B C D box is gone, the way V3 is written i dont think it is easy to bring it back. Besides you can enable the side panels and they have much better filters options compared to just the ABCD.. box.

2.

check your mdb_config.. look at the YEAR side panels, you will see something like

$this->config['panels'][5]['dbfield'] = "YEAR";
$this->config['panels'][5]['display'] = TRUE;
$this->config['panels'][5]['minimum'] = 4;

the Minimum value is how many films (minimum) have to be found for it to appear in the list.. if say year 2003 only had 2 films then it will be added to the OTHERS field.

Set it to 1 if you want all the years to be listed. same goes for the other panels.

3.

Im pretty sure it does search the category field. in the MDB_Config again, you have the following which are which fields will be searched.

$this->config['search']['fields'] = array("MEDIA", "MEDIATYPE", "SOURCE", "ORIGINALTITLE",
"TRANSLATEDTITLE", "DIRECTOR", "PRODUCER", "COUNTRY", "CATEGORY", "YEAR", "ACTORS",
"DESCRIPTION", "COMMENTS", "VIDEOFORMAT", "VIDEOBITRATE", "AUDIOFORMAT", "AUDIOBITRATE",
"RESOLUTION", "FRAMERATE", "LANGUAGES");



ps.. im hoping to post my mod some time soon, rather than people try to hack in all the code thats been posted recently. :)
Thermal Ions
Posts: 58
Joined: 2006-12-08 18:19:18
Location: The Land Down Under

Post by Thermal Ions »

kazgor wrote:ps.. im hoping to post my mod some time soon, rather than people try to hack in all the code thats been posted recently. :)
HeHeHe.....Then I can have the fun of ripping out the changes to hack into mine :hihi:

I've hacked so much of mine now, It's going to be really fun remembering all the changes to incorporate into v3.04 :(

Cheers ..... Thermal
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

Thermal Ions wrote:
kazgor wrote:ps.. im hoping to post my mod some time soon, rather than people try to hack in all the code thats been posted recently. :)
HeHeHe.....Then I can have the fun of ripping out the changes to hack into mine :hihi:

I've hacked so much of mine now, It's going to be really fun remembering all the changes to incorporate into v3.04 :(

Cheers ..... Thermal
yeah i know what u mean.. it looks like 3.04 will be the last version in the 3series.. just wish it got released. It fixes some bugs that i can't figure out.

I've almost finished the Comments/Trivia/Awards/Ratings code, think how the trivia looks like.. now the others look the same too.

came up with nicer hack.. the IMDB script orders the fields in the above order.. so what u do is read backwards through the comments field.

First find Ratings (will be the last one) now cut it from where it starts to the end of comments. now remove it from the main Comments field.

Now awards will be at the bottom.. so again u find the start of Awards and just cut to end of the comments.

Keep doing that and you have cleanly cut out each category in the comments field... plus it means even if there no Awards say it will still work.

pretty neat. :)

im off to bed.. but heres a little screen grab of what i've done so far.

Image
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

The sears is ok now.

Can you tell me what i must do so that it's read the sql file to the database.
When i copy the sql file to the webspace nothing hapenings.
Thermal Ions
Posts: 58
Joined: 2006-12-08 18:19:18
Location: The Land Down Under

Post by Thermal Ions »

Looks good Kazgor :) That LIFO process is very snazzy too.

@JP
You need to import the sql file into your mysql database on your server. Are you running your server locally or hosting it somewhere on the web? How you go about it will depend upon what sql admin program / script you are using.
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

Yes i now that i must import it in the database but in the readme file they tell abouth NOTE: A new *experimental* option is available in Version3.0 of this script that can auto import your movie database if a .sql file is found within your configured 'ant_export_dir'.
I placed it there but nothing happens.
Thermal Ions
Posts: 58
Joined: 2006-12-08 18:19:18
Location: The Land Down Under

Post by Thermal Ions »

The autoimport function works for me on my local webserver, however it fails for me on 110mb.com - something to do with the server's (virtual) directory structures I guess.

The only other thing I can suggest is that you check the setting for it in the mdb_config.inc file

Code: Select all

$this->config['options']['auto_import']         = TRUE;
Cheers ..... Thermal
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

i can get it to work on 110mb, but i have to give the directory full permissions first. once the import is done i put it back to the default permissions
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

I get the message...

set sql_mode=''

Invalid Query: Unknown system variable 'sql_mode'

This happends when i upload the sql file and than refresh the site.
After that the sql file is renamed to bak
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

I have now a new problem.
When i click on a movie the new window doesn't open.
Even when i upload the files again it insn't work anynore.
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

have you exported all the fields... the NUM field is essential.. perhaps its not there anymore?
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

J.P. wrote:I get the message...

set sql_mode=''

Invalid Query: Unknown system variable 'sql_mode'

This happends when i upload the sql file and than refresh the site.
After that the sql file is renamed to bak
a bit of googling and it sounds like your version of MYSQL does not support that system variable.. apparently its from version 4.1 and upwards.

You could always try removing that line out in MDB3.PHP


$query = "set sql_mode=''";
$this->db->query($query);[/b]
Last edited by kazgor on 2007-04-11 18:18:35, edited 2 times in total.
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

The num field was the problem.
The import error still exist.
I can't find $query = "set sql_mode=''";
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

J.P. wrote:The num field was the problem.
The import error still exist.
I can't find $query = "set sql_mode=''";
look for this function and then work yourway down the code.

_auto_import_ant_export()
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

Ok thank i found it.
I have removed
$query = "set sql_mode=''";
$this->db->query($query);
and change the permissions of the map antexport and now it's works.

A new question, sorry...

when i put a new movie without a picture i get a picture with a red cros and not the picture default_cover.jpg.
What must i change so that when i have no pictire with a movie i get the default_cover.jpg.
Last edited by J.P. on 2007-04-11 19:30:04, edited 1 time in total.
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

J.P. wrote: A new question, sorry...

when i put a new movie without a picture i get a picture with a red cros and not the picture default_cover.jpg.
What must i change so that when i have no pictire with a movie i get the default_cover.jpg.
hehe... Themal solved this one on page 7 ;)

viewtopic.php?p=22512#22512
(actually you quoted that very post at the top of page 9 lol :)

Glad you got the autoupdate working.. does make things quicker :)
J.P.
Posts: 64
Joined: 2006-09-20 09:55:52

Post by J.P. »

But were must i put...
update <tablename> set picturename = 'default_cover.jpg' where picturename ='';
When i put it on the sql on the database i get a error.
kazgor
Posts: 175
Joined: 2006-05-08 13:13:52
Contact:

Post by kazgor »

J.P. wrote:But were must i put...
update <tablename> set picturename = 'default_cover.jpg' where picturename ='';
When i put it on the sql on the database i get a error.
You should have some sort of MYSQL control panel which you can do queries in. ie PHPmyAdmin.

or (not tried it) you can stick that command to the bottom of the SQL file you've exported. (just fill out the Tablename)
Post Reply