PHP How to export image from large object Postgresql -
i have postgresql database stores images in large objects application (i can't change type, avoid use bytea type store images). trying export images database image files in web server through pg_lo_export() php function doesn't work.
is there solution problem?
i have searched answer on google before posting found no solution.
thanks in advance.
regards.
[edit] there php code:
pg_query($con, "begin"); $oid = pg_lo_import($con, $_files['userfile']['tmp_name'][$i]); pg_query($con, "commit"); if(!is_dir("images/colaboration")) mkdir("images/colaboration"); pg_query($con, "begin"); pg_lo_export($con, $oid, "images/colaboration/eiffel.jpg"); pg_query($con, "commit"); echo "<image src='images/colaboration/eiffel.jpg' />";"
with code image never creates getting 404 html error.
Comments
Post a Comment