Hello all,

I had this PHP script running fine on a FC4 linux box (using localhost).
However when I transferred it over to a linux box running SME7.1 server,
the $_POST function works incorrectly. It writes Resource ID #3 to all fields that get posted in the Insert query (MYSQL).

If I do a command line post to MYSQL, everything is OK. That's why I think this is something to do with PHP $_POST.

Is this some sort of configuration issue?

As the saying goes; "what doesn't kill you , makes you stronger".

I have solved the problem.:idea:
It's not $_POST itself that was the problem which I discoved by having it echo the values.

The culpret was the at the very beginning where the stripslashes processing was done for the connect. the code should have read:

$data = stripslahes($data)

but the wrong varaible was there

$data = stripslashes($dbc)

which is the variable containing the resoure id return from connect.

What still baffles me, is the fact that it worked on the machine that was "serving to itself" by having the browser and server all on the same computer for development.

Only when this code was put on a "real world" server did the problem presented itself! :confused:

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.