Code:
{* smarty *}
{php}
echo "I'm in PHP";
{/php}
{* back to smarty *}
As for getting Smarty object variables you can easily see they are accessible with following template code:
Code:
{php}func_print_r($this->_tpl_vars);{/php}
http://cart-lab.blogspot.com/2005/03/convient-way-to-debug-template.html
..And if your not doing the php inside of a .tpl, simply use $Smarty instead of $this.