【发布时间】:2014-10-19 17:16:15
【问题描述】:
我最近尝试调整为 sublime text 3 而不是我过去几年用于 web 开发的 netbeans,我真的很喜欢 netbeans IDE 中的功能,尤其是相当于 sublime sn-ps 的代码模板,不幸的是我无法像在 netbeans 代码模板中那样从上次赋值中找到变量。
这是我在 netbeans 中使用的代码模板
error_reporting(E_ALL);
ini_set('display_errors', '1');
echo '<pre style="background: black;color: white; font-size:16px; font-wheight:bold; direction:ltr!important;text-align: left;">';
print_r(${VARIABLE variableFromPreviousAssignment default="$variable"});
echo '</pre>';
die();
这是我在 sublime text 3 中使用的 sn-p
<snippet>
<content><![CDATA[
error_reporting(E_ALL);
ini_set('display_errors', '1');
echo '<pre>';
echo print_r(${1:*});
echo '</pre>';
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>dbg</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.php</scope>
<description>dbug snippet</description>
</snippet>
简而言之,我正在寻找的是在 netbeans 中崇高的等价物
(${VARIABLE variableFromPreviousAssignment default="$variable"}
【问题讨论】:
标签: php netbeans sublimetext code-snippets