<?php
$type = "Diploma Course";
echo str_replace(' Course', '', $type);
