Got most of the groups to work.

I think the only problem is that data is not being added correctly and
shows up as Null in the groups table in phpmyadmin.

It adds though and i got the functionality working. Wrote some AJAX
code methods and some stuff in index.php.

Let's look at this together.