MyBB Community Forums

Full Version: Save paths & Names files into SQL
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Well, I would like save in SQL, the path and name of images in SQL, I dont know exactly, if this can cause some problem caching

Doing the "SELECT" in the table indicated and the WHILE will save the paths and name of files into a ARRAY

Something as this:

$result = mysql_query ("SELECT * FROM images ORDER BY ID");
while($row = mysql_fetch_array($result))
{
$images[]=$row[path];
}
I'm not gettings you right.
i mean we can't use select to add things to the database, we only use it to retrieve things.
INSERT is used to add things.

umm do u mean you want to retrieve from a table and add them to another?

regards
zaher1988 Wrote:I'm not gettings you right.
i mean we can't use select to add things to the database, we only use it to retrieve things.
INSERT is used to add things.

umm do u mean you want to retrieve from a table and add them to another?

regards

I know that, Sorry by my bad english, for this reazon you not undertood me, but many thanks

Anyway I solved this issue