How to get the theme url in the phtml file? there has a global function for it?
If you're looking for a replacement of
$this->getSkinUrl() from Magento 1 then the equivalent in Magento 2 is the following:
What do you mean by theme url? What aspect of the theme? E.g skin, template, base URL etc.
If you want the skin URL then Raphael's answer is correct, if you want the template URL it is:
To get the base url: