Yii::app()->baseUrl returns nothing

hi i have been using Yii::app()->baseUrl to check for url comparisons inside my main.php in the theme folder. the thing is, it doesn’t return anything now as it is live [uploaded in a live server] whereas it was working when i was working on my localhost.

can anybody tell me what’s wrong? i need to generate the Base Url of the site dynamically. thanks.