fix problem with document without folder
fix export
add links