Noncommutative aspects of open/closed strings via foliations