I took a look at documentation in PHP mapscript but did not find a way to create the .dbf file.<br>Do mapserver classes has support for generating attribute .dbf file?<br>If not any sugestion for an ready to use tool that I can use?<br>
For database export one option I found  was to call pgsql2shp with a prepared query but must have exec function enabled to do this.<br><br>