Show tags in post? Function not working

Here you go,

global $post;
$posttags = get_the_tags();
if ($posttags) 
            {
            foreach($posttags as $tag) {
            $tagu = $tag->name;
            echo $tagu
                }
            }

tech