drd43058 2016-01-21 16:21
浏览 59
已采纳

Smarty和AngularJS

I am trying to implement the angularjs on a project that was used Smarty (PHP Template Engine).

The first problem I found was the problem in the template rendering, due to angularjs tag use braces ({) and the smarty variables.

I managed to solve this first problem by following this article: http://www.smarty.net/forums/viewtopic.php?p=87895&sid=937f958d431612d078f0f42324e09c59

Now the page is being rendered, but angularjs is not working.

If anyone has any tips and be able to help me, I'm grateful.

enter image description here

Sincerely, Renan Porto.

  • 写回答

2条回答 默认 最新

  • drt3751 2016-01-21 16:27
    关注

    You can change start and end interpolation symbol using interpolateProvider service.

    you can change {{var}} to [[var]] or any symbols.

    angular.module('app', [])
     .config(function($interpolateProvider){
        $interpolateProvider.startSymbol('[[').endSymbol(']]');
     });
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥20 有关区间dp的问题求解
  • ¥15 多电路系统共用电源的串扰问题
  • ¥15 slam rangenet++配置
  • ¥15 有没有研究水声通信方面的帮我改俩matlab代码
  • ¥15 对于相关问题的求解与代码
  • ¥15 ubuntu子系统密码忘记
  • ¥15 信号傅里叶变换在matlab上遇到的小问题请求帮助
  • ¥15 保护模式-系统加载-段寄存器
  • ¥15 电脑桌面设定一个区域禁止鼠标操作
  • ¥15 求NPF226060磁芯的详细资料