smarty value into php variable

Discussion in 'PHP' started by 3.5supersonic, Jun 22, 2010.

  1. #1
    Hi

    In my .tpl file i can access to a smarty variable {$value.name}. is it possible to assign into a php variable under like

    {php}

    $value = "{$value.name}";

    {/php}

    any help would be appreciate


    Thanks
     
    3.5supersonic, Jun 22, 2010 IP
  2. luckyjazzbo

    luckyjazzbo Member

    Messages:
    34
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    41
    #2
    check smarty compiled code: you can access it with $this->_tpl_vars['value']['name']
     
    luckyjazzbo, Jun 22, 2010 IP
  3. 3.5supersonic

    3.5supersonic Peon

    Messages:
    128
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Thanks luckyjazzbo, i tried that but it seems no value assign to php variable
     
    3.5supersonic, Jun 22, 2010 IP