Autor Beitrag
Hafi
Hält's aus hier
Beiträge: 5



BeitragVerfasst: Fr 06.07.07 13:09 
Hallo Forum,

bin in den Anfängen des PHP-Lernens, hab 'nen Kollgen der Delphie kennt, also programmierten wir mit der Probierversion drauflos eine kleine DB-Abfrage in MySQL. Um das Warten auf die Kaufversion zu überbrücken, wollte ich das Script so weiterbearbeiten, bekomme aber folgende Fehlermeldung:

ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
--Application raised an exception class Exception with message 'The Input Filter PHP extension is not setup on this PHP installation, so the contents returned by Input is *not* filtered'--
Callstack #0 File: C:\wamp\www\WebKoordinatenabfrage\KoordAbfrage_RS19.php Line: 177 (in dieser Zeile sthet:       //Read from resource file
                                                                                                                     $Unit1->loadResource(__FILE__);

  |_Callstack #1 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 1247
    |_Callstack #2 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 1277
      |_Callstack #3 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 495
        |_Callstack #4 File:  Line: 
          |_Callstack #5 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 428
            |_Callstack #6 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 991
              |_Callstack #7 File: C:\wamp\www\WebKoordinatenabfrage\vcl\stdctrls.inc.php Line: 998
                |_Callstack #8 File: C:\wamp\www\WebKoordinatenabfrage\vcl\system.inc.php Line: 304


was heißt das?
kann mir jemand sagen, wo das Problem liegt?

Danke Hafi

Moderiert von user profile iconChristian S.: Code-Tags hinzugefügt
GTA-Place
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
EE-Regisseur
Beiträge: 5248
Erhaltene Danke: 2

WIN XP, IE 7, FF 2.0
Delphi 7, Lazarus
BeitragVerfasst: Fr 06.07.07 15:39 
Einmal kurz die Fehlermeldung bei Google eingegeben, schon wird die Antwort von CodeGear ausgeworfen:

support.codegear.com/article/36378 hat folgendes geschrieben:
1. That means you don't have setup the Input Filter PHP Extension in your system, if you don't need to get input filter, you can edit your system.inc.php, and search for "throw new Exception", around line 226 and remove safely that line. Alternatively, you can setup the Input Filter extension.

--------------------------------------------------------------------------------

2. If you are running PHP 5.2x then the PHP Input Filter is already built in, but the function filter_data was renamed to filter_var. A updated version of the system.inc.php class will be provided that supports both PHP 5.1x and PHP 5.2x will be available soon.

_________________
"Wer Ego-Shooter Killerspiele nennt, muss konsequenterweise jeden Horrorstreifen als Killerfilm bezeichnen." (Zeit.de)
Hafi Threadstarter
Hält's aus hier
Beiträge: 5



BeitragVerfasst: Mo 09.07.07 13:15 
Hallo, danke für den Hinweis. Die Googlevariante habe ich probiert: wenn ich die Zeile 226 in system.inc.php lösche bzw. auskommentiere, schalte ich die Fehlermeldung ab, meine Anfrage läuft trotzden nicht.

Gruß Hafi
Christian V.
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 311

Win Xp Prof
Turbo Delphi 2005
BeitragVerfasst: Mo 09.07.07 18:28 
Was steht denn in deiner Anfrage?

_________________
Hardware runs the world, software controls the hardware, code generates software - Have You already coded today?
Hafi Threadstarter
Hält's aus hier
Beiträge: 5



BeitragVerfasst: Di 10.07.07 10:00 
Anfrage? sorry, ich meine natürlich meine Abfrage, ein php-script, das Daten aus einer Mysql-Datenbank ausliest und ausgibt. Ich habe es mit der Delphi for PHP-Probierversion erstellt und wollte jetzt die Zeit, bis die Kaufsoftware da ist überbrücken. Noch ein bischen html herumstricken usw. Aber ich ärgere mich mit Fehlermeldungen herum und komme kein bischen voran.
Aktuelles Problem, wenn ich mein Script starte:

Zitat:
Warning: mysql_connect() [function.mysql-connect]: Unknown MySQL server host 'root' (11004) in C:\wamp\www\WebKoordinatenabfrage\vcl\adodb\drivers\adodb-mysql.inc.php on line 358


ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
Application raised an exception class EDatabaseError with message 'Cannot connect to database server'
Callstack #0 File: C:\wamp\www\WebKoordinatenabfrage\KoordAbfrage_RS19.php Line: 177
  |_Callstack #1 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 1247
    |_Callstack #2 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 1277
      |_Callstack #3 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 495
        |_Callstack #4 File:  Line: 
          |_Callstack #5 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 421
            |_Callstack #6 File: C:\wamp\www\WebKoordinatenabfrage\vcl\classes.inc.php Line: 865
              |_Callstack #7 File: C:\wamp\www\WebKoordinatenabfrage\vcl\db.inc.php Line: 235
                |_Callstack #8 File: C:\wamp\www\WebKoordinatenabfrage\vcl\system.inc.php Line: 190
                  |_Callstack #9 File: C:\wamp\www\WebKoordinatenabfrage\vcl\dbtables.inc.php Line: 124
                    |_Callstack #10 File: C:\wamp\www\WebKoordinatenabfrage\vcl\db.inc.php Line: 261
                      |_Callstack #11 File: C:\wamp\www\WebKoordinatenabfrage\vcl\dbtables.inc.php Line: 236


Bitte keinen Hinweis, dass ich in line 358 oder 177 oder irgendetwas schauen soll! Habe alles durchgeschaut, kapiere es nicht wirklich. Es gibt in Classes.inc.php den Hinweis auf das dazugehörige xml-file, dort habe ich Databasename, username und userpasswort eingetragen/herausgelöscht-es macht keinen Unterschied in der Fehlermeldung. Die mysql-connection will nicht funktionieren. Weiß jemand einen Rat?

Danke Hafi

Moderiert von user profile iconChristian S.: Code- und Quote-Tags hinzugefügt
Christian V.
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 311

Win Xp Prof
Turbo Delphi 2005
BeitragVerfasst: Mi 11.07.07 13:24 
Ich hatte auch Abfrage gemeint, aber das sit ja nicht so wichtig.

Nun, Zeig doch mal Linie 358. So wie's aussieht kannst du nur keine Verbindung zum Server aufbauen. Anscheinend hast du als Host 'root' angegeben.

_________________
Hardware runs the world, software controls the hardware, code generates software - Have You already coded today?
Hafi Threadstarter
Hält's aus hier
Beiträge: 5



BeitragVerfasst: Do 12.07.07 12:44 
Okay, ein Auszug aus der angesagten Datei:
Zitat:
Warning: mysql_connect() [function.mysql-connect]: Unknown MySQL server host 'root' (11004) in C:\wamp\www\WebKoordinatenabfrage\vcl\adodb\drivers\adodb-mysql.inc.php on line 358


ausblenden PHP-Code
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
       function _connect($argHostname, $argUsername, $argPassword, $argDatabasename)
        {
                if (!empty($this->port)) $argHostname .= ":".$this->port;
                
                if (ADODB_PHPVER >= 0x4300)
                        $this->_connectionID = mysql_connect($argHostname,$argUsername,$argPassword,
//*line 358:*//                                                                                     $this->forceNewConnect,$this->clientFlags);
                else if (ADODB_PHPVER >= 0x4200)
                        $this->_connectionID = mysql_connect($argHostname,$argUsername,$argPassword,
                                                                                                $this->forceNewConnect);
                else
                        $this->_connectionID = mysql_connect($argHostname,$argUsername,$argPassword);
        
                if ($this->_connectionID === falsereturn false;
                if ($argDatabasename) return $this->SelectDB($argDatabasename);
                return true;    
        }


Meinst Du mit "als Host 'root' angegeben" die Angaben, die im xml-File stehen? oder wo meinst Du.

Gruß Hafi

Moderiert von user profile iconChristian S.: C#-Tags als PHP-Tag-Ersatz hinzugefügt
Christian V.
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 311

Win Xp Prof
Turbo Delphi 2005
BeitragVerfasst: Do 12.07.07 13:42 
Was steht denn in dem XML file?

_________________
Hardware runs the world, software controls the hardware, code generates software - Have You already coded today?
Hafi Threadstarter
Hält's aus hier
Beiträge: 5



BeitragVerfasst: Do 12.07.07 14:05 
das xml-file wird von Delphi for PHP automatisch mitgeschrieben, darin stehen die Einstellungen für die Objectclasses, also meine Labels und Buttons.

alles so in dem Stil: (Auszug)

ausblenden XML-Daten
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
<object class="Database" name="KoordinatenDBRS19" >
        <property name="Left">933</property>
        <property name="Top">615</property>
    <property name="Connected">1</property>
    <property name="DatabaseName">KoordinatenDBRS19</property>
    <property name="Dictionary"></property>
    <property name="DriverName">mysql</property>
    <property name="Host"></property>
    <property name="Name">KoordinatenDBRS19</property>
    <property name="UserName"></property>
    <property name="UserPassword"></property>
    <property name="OnAfterConnect"></property>
    <property name="OnAfterDisconnect"></property>
    <property name="OnBeforeConnect"></property>
    <property name="OnBeforeDisconnect"></property>
  </object>


Moderiert von user profile iconChristian S.: XML-Tags hinzugefügt