lua scripts no longer use foreach, which is gone in lua 5.2

Instead we now use 'for'
"notionflux" manpage no longer refers to "ionflux"
fixed typo
attach_tagged() was changed to tagged_attach() in 2007. Using that