<?xml version="1.0" encoding="utf-8"?>

<snippet name = "替换字符" description = "用其他字符替换给定字符串中指定字符的所有匹配项。" preview="code" type="block">

<insertText location="beforeSelection">

<![CDATA[function replaceCharacters(conversionString,inChar,outChar)

{

  var convertedString = conversionString.split(inChar);

  convertedString = convertedString.join(outChar);

  return convertedString;

}]]>

</insertText>

<insertText location="afterSelection"><![CDATA[]]>

</insertText>

</snippet>

