- printf '[div .comment #comment_%s [h3 . %s, %s:][div . %s]]' \
- "$cuid" "$(UNSTRING "$username" |HTML)" "$(date -d "@${time%%,*}")" \
- "$(UNSTRING "$text" |markdown)"
+ printf '[div .comment #comment_%s [h3 . %s:]' "$cuid" "$(UNSTRING "$username" |HTML)"
+ printf '[span .time [label posted] %s]' "$(date -d "@${time%,*}")"
+ [ "${time}" != "${time%,*}" ] \
+ && printf '[span .update [label updated] %s]' "$(date -d "@${time#*,}")"
+ [ "$edit" = "$cuid" ] \
+ && printf '[span .error You cannot edit this comment]'
+ [ "$sid" = "$SESSION_ID" ] \
+ && printf '[a .edit href="?editcomment=%s#comment_%s" edit]' "$cuid" "$cuid"
+ printf '[div . %s]]' "$(UNSTRING "$text" |markdown)"