PHP now working... or what?

Discussion in 'Installation/Configuration' started by Nejko, Jan 21, 2006.

  1. Nejko

    Nejko New Member

    If i create file for test with phpinfo(); everything is cool, it shows me all the data, but if i open any other php file on my server it doesn't work? What's the problem? :S
     
  2. themachine

    themachine ISPConfig Developer ISPConfig Developer

    what does the file look like that you are trying to open? Perhaps there is an error in the page. Note that anything in between "<?php" and "?>" will be parsed as PHP and therefore all syntax needs to be PHP complient... do you have an error log? Do you have error loggin enabled in '/etc/php.ini"?? That would be a good start to determine what the problem is.
     
  3. Nejko

    Nejko New Member

    Last edited: Jan 21, 2006
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Did you get any errors in your apache error log when you open the phpBB page in a browser?
     
  5. Nejko

    Nejko New Member

    Last edited: Jan 21, 2006
  6. till

    till Super Moderator Staff Member ISPConfig Developer

    Hmm, that is only a notice. this should not stop your script. If you enabled php safemode, please try to disable it.
     
  7. Nejko

    Nejko New Member

    ;
    ; Safe Mode
    ;
    safe_mode = Off

    i din't :(
     
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    If you use ISPConfig, you will have to disable safemode there, not in php.ini.
     
  9. Nejko

    Nejko New Member

    i'm not using it YET :) so what could be wrong? :S
     
    Last edited: Jan 21, 2006
  10. themachine

    themachine ISPConfig Developer ISPConfig Developer

    My unprofessional opinion would be this:

    This page you are trying to go to and getting a "blank page" is 'index.php'. However, are trying to go to 'domain.com/application/index.php' directly or just going to 'domain.com/application'? It is possible that you have not added 'index.php' to you list of DirectoryIndexes in your Apache Configuration... it looks something like:

    DirectoryIndex index.html index.htm index.php index.cgi index.pl


    This is found somewhere like:

    Debian: /etc/apache2/apache2.conf
    RedHat: /etc/httpd/conf/httpd.conf

    Or specifically in your VirtualHost's directive where ever that may be.


    Hope this might help... it is worth checking anyway.
     
  11. falko

    falko Super Moderator ISPConfig Developer

    What's in line 7 of /home/nejc/public_html/slike/index.php?

    You might have to use another value for error reporting in your php.ini. Have a look here: http://au3.php.net/manual/en/ref.errorfunc.php
    If you change your php.ini, don't forget to restart Apache afterwards.
     
  12. themachine

    themachine ISPConfig Developer ISPConfig Developer

    what do you have in your php.ini for the following setting?

    error_reporting = E_ALL & ~E_NOTICE


    You may need to change your setting to "E_ALL" to actually get better error message output.
     
  13. Nejko

    Nejko New Member

    i added index.php to directory indexes, but no effect :( also tried php.ini error reporting... nothning

    edit: authour of themicroblog told me same.. i should try error reporting, but nothing :(

    edit: my script for uptime works :S

    <?
    function linuxUptime() {
    $ut = strtok( exec( "cat /proc/uptime" ), "." );
    $days = sprintf( "%2d", ($ut/(3600*24)) );
    $hours = sprintf( "%2d", ( ($ut % (3600*24)) / 3600) );
    $min = sprintf( "%2d", ($ut % (3600*24) % 3600)/60 );
    $sec = sprintf( "%2d", ($ut % (3600*24) % 3600)%60 );
    return array( $days, $hours, $min, $sec );
    }
    $ut = linuxUptime();

    echo "Server že dela neprestano : $ut[0] dni, $ut[1] ur, $ut[2] minut";
    ?>

    http://nero-server.homelinux.org/server.php

    that's all too strange :S
     
    Last edited: Jan 21, 2006
  14. falko

    falko Super Moderator ISPConfig Developer

    Did you restart Apache?
     
  15. Nejko

    Nejko New Member

    sure... i did :(
    no one has no idea what's wrong? :?(

    An error has occurred during installation
    The PHP configuration on your server doesn't support the database type that you chose

    hmm, :(


    edit: can i give to someone of you experts shell or mybe webmin root acess? if it would help...
     
    Last edited: Jan 22, 2006
  16. falko

    falko Super Moderator ISPConfig Developer

    I guess your application uses a MySQL database. Is MySQL supported by your PHP installation? Do you see MySQL mentioned when you run a PHP script with phpinfo(); in it?
     
  17. Nejko

    Nejko New Member

  18. till

    till Super Moderator Staff Member ISPConfig Developer

    Have you thought about using one of the perfect setup guides together with ISPConfig to get a working webserver setup? Without a good linux knowledge it is not easy to setup a working server manually.
     
  19. Nejko

    Nejko New Member

    yes, i did everything like it said, but php just don't want mysql :S how can i reconfigure?
     
  20. till

    till Super Moderator Staff Member ISPConfig Developer

    Just install the php4-mysql package from your linux distribution and restart your webserver.
     

Share This Page