Welcome to Fogfighters Hungary!
 
  Login or Register
.week  
Time
 
 
 
Languages
Select Interface Language:

 
Google Translation
Translation
 
Traffic Report
 
Where are you from?
 
Map Random
Objective
Snatch3
View Snatch3
June 1943: The Axis have a small but vital communication outpost, which controls the Blitzkrieg on all major frontlines. This outpost is equipped with the new radar technology and the Allies are planning an attack (codename:
Hits: 3
Total Maps: 85
 
Modules
· Home
· About Easter
· Büntetés kalkulátor
· Bible
· Biorythm
· Birds
· Black Gallery
· Cats
· Coppermine
· Dogs
· eCards
· ET Game manual
· ET Handbuch
· ET játékleírás
· ET Maps
· Fórumok
· FIFA World Cup 2006
· Fish
· Google Guide
· Googlemaps
· Hírküldés
· Help Desk
· Internet_TV
· Keresés
· Letöltések
· Members List
· Member_Map
· News
· Online Radios
· PHP-Nuke_HOWTO
· PHP-Nuke_Tools
· Private Messages
· Punkbuster
· Saját beállításaid
· Shout Box
· Statisztikák
· Szavazások
· Szerencsejáték
· Tagfelvétel
· Viccek
· Videó kollekció
· Web címek
· Web Development
 
MS-Analysis
Top-Ten Countries visiting Fogfighters Hungary

1 United States United States
2 China China
3 Viet nam Viet nam
4 Russian Federation Russian Federation
5 France France
6 Hungary Hungary
7 Canada Canada
8 Ukraine Ukraine
9 United Kingdom United Kingdom
10 Netherlands Netherlands
11 Germany Germany
12 Poland Poland
13 Italy Italy
14 Taiwan, Province of China Taiwan, Province of China
15 Seychelles Seychelles
16 Romania Romania
17 Indonesia Indonesia
18 Australia Australia
19 Thailand Thailand
20 Sweden Sweden
21 Brazil Brazil
22 India India
23 Japan Japan
24 South Africa South Africa
25 Lithuania Lithuania
26 Argentina Argentina
27 Spain Spain
28 Chile Chile
29 Luxembourg Luxembourg
30 Turkey Turkey
31 Moldova, Republic of Moldova, Republic of
32 Korea, Republic of Korea, Republic of
33 Venezuela Venezuela
34 Malaysia Malaysia
35 unknown unknown
36 Switzerland Switzerland
37 Singapore Singapore
38 Colombia Colombia
39 Hong Kong Hong Kong
40 Mexico Mexico
41 Belize Belize
42 Greece Greece
43 Mongolia Mongolia
44 Honduras Honduras
45 Estonia Estonia
46 Czech Republic Czech Republic
47 Latvia Latvia
48 Bangladesh Bangladesh
49 Bulgaria Bulgaria
50 Pakistan Pakistan

View MS-Analysis
 
Scrolling Links
Mods:































Community:




































Clans:






























































League:










Anticheat:












Other:

































 
Special days




World Sandwich Day


 
Képes Naptár
There is a problem right now with this block.
 
CPG Random Picture

Smoke

 
Latest Videos


Last added videos

Orvosnál

Orvosnál

Last added videos

Funny

Funny Mortar

Last added videos

Shy

Shy Rose - I Cry For You
 
Test scripts

3.9.1. Test scripts

Before you start the ambitious undertaking of debugging your PHP-Nuke installation, you should download and run some tools that may shorten the search path and save you some headaches:

  • test.php

  • ConnectTest.php and

  • analyze.php

3.9.1.1. test.php

test.php is a "quick'n dirty" script to help you find out if you could connect to the database and how your PHP configuration looks like. Put the following lines in a file, name it test.php, upload it in the same directory where you have your config.php and tell your browser to open it (see Warning: Invalid argument supplied for foreach()):

<?php 
include("config.php"); 
mysql_connect("$dbhost", "$dbuname", "$dbpass"); 
mysql_select_db("$dbname"); 
echo mysql_error(); 
phpinfo(); 
?> 

If everything is right, you will only see the PHP info. Otherwise, you will see a descriptive message of the error first (in the first line) and also the PHP info. You can use the output to determine various parameters of your PHP configuration, like version numbers, libraries, paths and variables. Whenever you ask yourself if you have feature X enabled, remember to run this small script and search its output for a string that describes the feature. You will most probably find the answer there. Conversely, if you don't find the answer in the output of test.php (i.e. the output of the phpinfo() function), you will probably not find it easily.

3.9.1.2. ConnectTest.php

The ConnectTest.php script from Humpa is a more elaborate test script that you can help with database connection problems. Download and save it with a .php ending (it comes with a .txt ending to prevent the web server from interpreting the PHP code in it). You should put the ConnectTest.php file in the PHP-Nuke root directory, i.e. in the same directory where also config.php is located. Then you just tell your browser to open it.

<?php
if($phpinfo=="phpinfo") {
        phpinfo();
        die();
}
require_once("config.php");
$dbcheck = mysql_connect("$dbhost", "$dbuname", "$dbpass");
if (!$dbcheck) {
        echo mysql_error();
        echo "<br><b>The Connection Test Script was unable to connect 
to the MySQL server!<br>One or more of these variables are wrong in 
your config.php:</b> <font color=purple><b>\$dbhost=\"<i>$dbhost</i>\",
\$dbuname=\"<i>$dbuname</i>\", and/or \$dbpass=\"*<i>hidden</i>*\"
</b></font><br>";
        echo "<br>Now, please don't say that you <u>are</u> using the 
correct values - say it to your mysql server, because that is who(what?) 
is stopping you. : )<br>";
        echo "Email your web host and ask them what to use for a mysql 
username and password.<br>";
        echo "PHP Manual, function: 
<a href=\"http://www.php.net/manual/en/function.mysql-connect.php\"
target=\"_blank\">mysql_connect</a><br>";
        echo "If you are the server, perhaps you just need to create 
a mysql user instead of using your root user.<br>";
        die("<br><a href=\"$_SERVER[PHP_SELF]?phpinfo=phpinfo\">
phpinfo</a>");
}else{
        echo "<a href=\"$_SERVER[PHP_SELF]?phpinfo=phpinfo\">
phpinfo</a><br><br>";
        echo "<font color=red><b>If everything looks good, but you 
still have problems, get the ";
        echo "<a href=\"http://nukecops.com/downloads-cat-7.htm\">
analyzer from NukeCops</a></b></font><br><br>";
        echo "<b>Connection Test Script connected to your MySQL server 
successfully!<br>";
        echo "<br>\$dbuname = \"$dbuname\";<br>\$dbtype = \"$dbtype\";
<br>\$prefix = \"$prefix\";<br>\$user_prefix = \"$user_prefix\";<br>";
        if (mysql_select_db($dbname)) {
                echo "<br>Connection to your database \"
<font color=purple>$dbname</font>\" was also successful.<br>";
                $result = mysql_list_tables($dbname);
        if (!$result) {
                print "DB Error, could not list tables\n";
                print 'MySQL Error: ' . mysql_error();
                die();
        }
        $i=0;
        $stufftoprint = "";
        while ($row = mysql_fetch_row($result)) {
                $tablename = $row[0];
                if($tablename == "".$prefix."_authors") {
                        $result4 = mysql_query("select aid from $tablename");
                        while(list($admin_name) = mysql_fetch_row($result4)) {
                                $admin_names .= "$admin_name, &nbsp;";
                        }
                }
                $result3 = mysql_query("select * from $tablename");
                        $numFields = mysql_num_fields($result3);
                        $numRows = mysql_num_rows($result3);
                        $rows = "rows";
                        $fields = "fields";
                        if($numFields == 1) {$fields = "field";}
                        if($numRows == 1) {$rows = "row";}
                $stufftoprint .= "Table: <font color=purple>$tablename
</font> &nbsp;($numFields $fields / $numRows $rows)\n<br>";
                $i++;
        }
        if($dbtype != "MySQL" AND eregi("mysql",$dbtype)) {
                echo "<br><font color=red><b>But, you need to set </b>
</font><font color=purple><b> \$dbtype = \"MySQL\"; </b></font>";
                echo "<font color=red><b> &nbsp;&nbsp; in your config.php!!!!!!!!</b></font><br>";
        }
        echo "<br>There are <font color=purple>$i tables</font> in your \"
<font color=purple>$dbname</font>\" database<br>";
        echo "(by default, there are 89 fields in phpnuke 6.5 and 76 fields 
in phpnuke 6.0)<br>";
        if($i<66) {
                echo "<br><font color=red><b>You don't seem to have all the 
tables installed.<br>Get the ";
                echo "<a href=\"http://www.nukeresources.com/modules.php?name=Downloads
&d_op=viewdownload&cid=79\">Web Installer</a> for your version of 
phpnuke</b></font><br>";
        }
        echo "<br>These are the admin names (aid) in your nuke_authors 
table: &nbsp;<font color=purple>$admin_names</font><br>";
        echo "<br>Now check this list of tables with your nuke.sql file:<br><br>$stufftoprint</b>";
        }else {
                if(mysql_query("CREATE DATABASE $dbname")) {
                        echo "<br>Your database \"$dbname\" did not exist, 
but this script just created it sucessfully<br>";
                        echo "Now, you need to get the appropriate 
<a href=\"http://www.nukeresources.com/modules.php?name=Downloads
&d_op=viewdownload&cid=79\">";
                        echo "Web Installer from nukeresources.com</a>";
                        die();
                }
                echo "<br>However, the \"$dbname\" database does not exist. 
If that is not the correct name, then put in the correct ";
                echo "name for<br><font color=purple>
\$dbname =\"$dbname\";</font>&nbsp;&nbsp; (in your config.php)
<br>If you have not created the database yet, then ";
                echo "create it. If you are not the server, then ask your 
web host to create it for you.<br>";
                echo "<br>Then, get the appropriate 
<a href=\"http://www.nukeresources.com/modules.php?name=Downloads
&d_op=viewdownload&cid=79\">";
                echo "Web Installer from nukeresources.com</a>";
        }
}
?>

3.9.1.3. analyze.php

The analyze.php script from Paul Laudanski (a.k.a. Zhen-Xjell) is the most elaborate from all the three script presented here. Rename the file to "analyze.php", transfer it to the same place that your config.php file is found and call it from your browser. For a preview of what it reports, run analyze.php for the nukecops site. The code has been successfully tested for Nuke versions 6.5B6, 6.5B5, 6.0, 5.6.

Figure 3-25. analyze.php: MySQL connection transcript.

analyze.php: MySQL connection transcript.



The script not only tests your MySQL database connection (see Figure 3-25), but also displays information on:

  • config.php settings

  • SMTP (mail server) settings

  • GD (graphics) library settings

  • Databases

  • Modules

  • Blocks

  • Notices

  • Ranks

  • Administrators and Moderators

  • php,ini settings

  • Security code

  • Recursive file listing along with resource permissions

Figure 3-26. analyze.php: MySQL security warning.

analyze.php: MySQL security warning.



It also checks for MySQL (see Figure 3-26) and PHP (see Figure 23-1) vulnerabilities and reports them to you if they need to be patched.


Help us make a better PHP-Nuke HOWTO!

Want to contribute to this HOWTO? Have a suggestion or a solution to a problem that was not treated here? Post your comments on my PHP-Nuke Forum!

Chris Karakas, Maintainer PHP-Nuke HOWTO

Send all questions and comments to:
Webmaster
All logos and trademarks in this site are property of their respective owner. The comments are property of their posters, all the rest Fogfighters Hungary © 2007 - 2022

You can syndicate our news using the file backend.php or ultramode.txt

PHP-Nuke Copyright © 2005 by Francisco Burzi. This is free software, and you may redistribute it under the GPL. PHP-Nuke comes with absolutely no warranty, for details, see the license.
Page Generation: 0.21 Seconds

:: subBlack phpbb2 style by spectre :: PHP-Nuke theme by www.nukemods.com ::