Nieuws:

Welkom, Gast. Alsjeblieft inloggen of registreren.
Heb je de activerings-mail niet ontvangen?

Auteur Topic: PHP4Flicks (PHP movie database)  (gelezen 1805 keer)

PHP4Flicks (PHP movie database)
« Gepost op: 2010/09/05, 22:22:10 »
Ik dacht aangezien dit helemaal niks met ubuntu te maken heeft dan zet ik hem wel in offtopic.

Ik heb lamp-server geinstalleerd + phpmyadmin. Ik heb database genaamd flicks aangemaakt en sql bestandje uitgevoerd waardoor er nu ook tabellen aangemaakt zijn. Ik heb gebruiksnaam gewijzigd en een md5 password aangemaakt maar nog steeds krijg index.php niet geopend ik wil namelijk dan inloggen en zo aan de gang gaan maar ik weet niet hoe ik login pagina voor mij krijg. Ik heb ook login.php geprobeerd te openen maar dan krijg ik links boven 2 vakjes en daar onder staat abort  log me in! 

http://php4flicks.sourceforge.net/

Wat doe ik fout??

Re: PHP4Flicks (PHP movie database)
« Reactie #1 Gepost op: 2010/09/07, 18:34:23 »
Mijn god programmeren dit?? Ik vraag niet om wat php-code maar het draaiend te krijgen -_-!..

Offline Rachid

  • Lid
    • rachidbm
    • Mijn blog
Re: PHP4Flicks (PHP movie database)
« Reactie #2 Gepost op: 2010/09/07, 18:55:16 »
Ik denk dat programmeren wel oke is... Dit topic is lastig om onder 1 noemer te stoppen vind ik :P

Anyhow, heb je elke stap gedaan van: http://php4flicks.sourceforge.net/README ?
Dus ook bijv. config.php aanpassen...
Ben je ook blij dat Ubuntu zo toegankelijk en gratis is, en wil je graag net als ik iets terugdoen, kijk dan eens rond bij mwanzo, dé poort naar het bijdragen aan Ubuntu en haar gemeenschap!

Re: PHP4Flicks (PHP movie database)
« Reactie #3 Gepost op: 2010/09/07, 20:24:27 »
Er zijn dus blijkbaar mensen die als ze "php" zien denken dat je gaat programmeren ... :rolleyes:
I use a Unix-based system, that means I'll get laid as often as I have to reboot.
LibSylph
SeySayux.net

Re: PHP4Flicks (PHP movie database)
« Reactie #4 Gepost op: 2010/09/07, 21:45:25 »
Er zijn dus blijkbaar mensen die als ze "php" zien denken dat je gaat programmeren ... :rolleyes:

Alles wat met programmeertalen en websites bouwen te maken heeft hoort onder Programmeren thuis op dit forum. In dit topic gaat het om een PHP-iets wat gebruikt wordt, en PHP is een programmeertaal. Valt dus op dit forum onder Programmeren.

Re: PHP4Flicks (PHP movie database)
« Reactie #5 Gepost op: 2010/09/08, 08:01:36 »
Alles wat met programmeertalen en websites bouwen te maken heeft hoort onder Programmeren thuis op dit forum. In dit topic gaat het om een PHP-iets wat gebruikt wordt, en PHP is een programmeertaal. Valt dus op dit forum onder Programmeren.
$ sudo apt-get install phpmyadmin
# Oh jee, ben ik nu aan het programmeren?
I use a Unix-based system, that means I'll get laid as often as I have to reboot.
LibSylph
SeySayux.net

Re: PHP4Flicks (PHP movie database)
« Reactie #6 Gepost op: 2010/09/08, 08:40:59 »
SeySayux: helemaal niet nodig om zo te reageren.
Dit is gewoon de beste plaats om dit topic te plaatsen, zelfs al gaat het niet 'echt' om programmeren.

Offline Rachid

  • Lid
    • rachidbm
    • Mijn blog
Re: PHP4Flicks (PHP movie database)
« Reactie #7 Gepost op: 2010/09/08, 10:18:19 »
Inderdaad, en of we php nou programmeren mogen noemen kunnen we dan ook nog over discussiëren. :P
Ben je ook blij dat Ubuntu zo toegankelijk en gratis is, en wil je graag net als ik iets terugdoen, kijk dan eens rond bij mwanzo, dé poort naar het bijdragen aan Ubuntu en haar gemeenschap!

Re: PHP4Flicks (PHP movie database)
« Reactie #8 Gepost op: 2010/09/08, 10:53:23 »
Ik denk dat programmeren wel oke is... Dit topic is lastig om onder 1 noemer te stoppen vind ik :P

Anyhow, heb je elke stap gedaan van: http://php4flicks.sourceforge.net/README ?
Dus ook bijv. config.php aanpassen...

Dit zijn de stappen die ik zowiso heb gedaan.

    * unzip/untar the received files to a web accessible directory (gedaan - Dus unzipped en rest van de mappen en bestanden massaal gekopieerd naar /var/www directory)

    * create the necessary mySQL tables using the file docs/db_defs.sql ( gedaan - phpmyadmin geinstalleerd, vervolgens via web (http://localhost/phpmyadmin) ingelogd en nieuwe database aangemaakt genaamd "flicks"  vervolgens db_defs.sql in tabblad SQL deze code vervolgens uitgevoerd. Nu heb ik allemaal tabellen in database "flicks")

    * edit the config.php file in the config-folder. the various options are described
   there.  (gedaan - config.php  met gedit geopend en vervolgens dingen gewijzigd die gewijzigd moesten worden dus ook md5 password gemaakt en mysql spul gewijzigd. bekijk hier onder de config file)
      especially, make sure to enter your user name and the md5-value of your
   password and change the db settings to the correct values.
      (see also the notes on user management below)
    * for the pdf export, you can either use:  (deze stap heb ik NIET UITGEVOERD is volgens mij NOG NIET nodig)
   - ezpdf (http://www.ros.co.nz/pdf/, free):
     set $cfg['pdfout'] to 'ezpdf'.
     you don't need to change anything else, since the required php classes are
     included in the download. there are some options you can edit, see the
     config file.
   - htmldoc (http://htmldoc.org, GPL license):
     set $cfg['pdfout'] to 'htmldoc'.
     c-based html->pdf converter, available for *nix and win.
     it is faster than ezpdf and the outputted pdf (currently?) looks much nicer.
     download the source and compile it; if you install it in a directory other then
     'print', also change the path information in the file print/index.php
     (it's easy to find where)
     you can remove the ezpdf class files and the 'fonts' folder if you don't need ezpdf.
   please read the respective documentation if you have questions or problems
   regarding the pdf generation.

--     * please note that magic_quotes must be switched off! (php.ini: magic_qoutes = off)
      otherwise you'll get SQL error messages. (deze zijn ook uit magic_quotes_gpc   Off   Off
magic_quotes_runtime   Off   Off
magic_quotes_sybase   Off   als ik phpinfo bestandje bekijk)
 
-------------
Wat ik trouwens ook nog gedaan heb is mij zelf eigenaar gemaakt van /var/www directory met chown omdat ik eerst constant sudo nodig had om te schrijven.

config.php
<?

/* 'main' configuration ******************************************************

** various options for the script                                           **

******************************************************************************/



$cfg['mysql_host'] = 'localhost';       // mysql host



$cfg['mysql_user'] = 'root';           // mysql user



$cfg['mysql_pass'] = '<pass weggehaald>';           // mysql password



$cfg['mysql_db'] = 'flicks';            // database name



$cfg['pagetitle'] = 'php4flicks';       // the browser window title



$cfg['nofflicks'] = 25;                 // # movies per page (main window)



    // default sort order; must NOT be empty! the max # of rows by which can be sorted is the size of this array.

    // ASC/DESC MUST be specified!

$cfg['defaultsort'] = array('name ASC','nr ASC','year DESC');



    // define any number of users here; users[i][md5pass] must contain the md5-encrypted password

$cfg['users'][0]['user'] = 'admin';

$cfg['users'][0]['md5pass'] = '<passweggehaald>';



$cfg['version'] = 'version 0.4';



$cfg['old_browsers'] = false;           // if set to true, javascript/DOM will not be used in the edit mode

                                        // for compatibility with older browser





/* imdb scripts configuration ************************************************

** configures fetching of data from imdb                                    **

******************************************************************************/



$cfg['actorLimit'] = 10;                // how many actors per movie?

$cfg['searchLimit'] = 25;               // max # of search results per catecory



$cfg['actSearchLimit'] = 25;            // max # of search results for people

// which categories to search for people:

$cfg['actCats'] = array('actors','actresses','directors','writers');

    // possible categories include: Actor, Actress, Cinemathographer, Composer, Director,

    // Writer, Editor, Producer, Stunts, and a whole lot of others

    // independent of $actCats and $actSearchLimit, all 'most popular' matches will always be shown



$cfg['cache'] = true;                   // whether or not to cache last search results



$cfg['http_cache_size'] = 0;

    // number of html-pages kept in session cache.

    // should be switched off in general, useful when testing app since it reduces traffic from imdb



$cfg['http_compress'] = true;

    // whether or not to use gzipped html.

    // set to false if you have problems fetching data from imdb (php versions <4.3.x)





/* media configuration ********************************************************

** languages, media, etc...                                                  **

******************************************************************************/



$cfg['cats'] = array(

    // an array to automatically choose category depending on medium. leave empty if not desired.

    // max length for category name is 10 chars.

    'dvd' => 'C',

    'vhs' => 'A',

    'svhs' => 'B',

    'divX/Xvid' => 'D',

    'vcd/Svcd' => 'E',

    'dvd-r' => 'C'

    );





/* print PDF configuration*****************************************************

** configures pdf output generation                                          **

******************************************************************************/



// pdf page size ('A4' | 'LETTER')

$cfg['pagesize'] = 'A4';



// choose html->pdf converter. at this time, allowed values are 'htmldoc' and 'ezpdf'.

// ezpdf is included in the distribution, htmldoc must be compiled

// however, htmldoc is faster and generates a somewhat nicer output

$cfg['pdfout'] = 'ezpdf';



// HTMLDOC options



$cfg['htmldoc_path'] = 'c:/programme/apache2/htdocs/movies/print';  // the data directory for htmldoc

$cfg['htmldoc_fname'] = 'movies.pdf';                               // name of pdf file outputted by htmldoc



// end HTMLDOC options



// EZPDF options



// Table Category Titles... <b>=bold, <i>=italic, <b><i>=bolditalic

// (this array determines what data will be shown)

$cfg['tablecat'] = array(

'nr' =>'<b>CAT#</b>',

'name' =>'<b>TITLE</b>',

'year' =>'<b>YEAR</b>',

'runtime' =>'<b>TIME</b>',

'ratio' =>'<b>RATIO</b>',

);



// Main Title of PDF document

$cfg['tabletitle'] = 'php4flicks';



// Put a link BACK on PDF printout(overcome redirect) 0=No 1=Yes

$cfg['backlink'] = 0;



// end EZPDF options





/* ****************************************************************************

** do not edit below this line                                               **

******************************************************************************/



// get available options for media, language, etc directly from mysql table definition.

// DO NOT CHANGE config below this line. to change options, directly edit mysql definitions.



mysql_connect($cfg['mysql_host'],$cfg['mysql_user'],$cfg['mysql_pass']) or die(mysql_error());

mysql_select_db($cfg['mysql_db']) or die(mysql_error());



set_magic_quotes_runtime(0); // get rid of that plague



// option columns must be of type set or enum

$options = array('medium','lang','format','ratio','sound','genre');



foreach($options as $o){

$result = mysql_query("describe movies $o") or die(mysql_error());

$row = mysql_fetch_array($result);

$type = $row['Type'];

preg_match_all("#\'([^,\']{1,})\'#",$type,$matches,PREG_PATTERN_ORDER);



$cfg[$o] = $matches[1];

    }

?>

Weten jullie misschien waar het probleem ligt??