<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:#954F72;
text-decoration:underline;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
{page:WordSection1;}
--></style>
</head>
<body lang="FR" link="blue" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal">Hello freeswitch users, </p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I’m discovering freeswitch, and I want to understand how to extract and use the variable « sip_h_Diversion » in the Dialplan.
</p>
<p class="MsoNormal">I know this question has been asked more times in the mailing-list but I didn’t understand the issue of the diverse topic who evocate this variable.
</p>
<p class="MsoNormal">Also I read the information on the wiki but I wasn’t able to know what I have to do in my case.</p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">In my Dialplan , I tried to put :</p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><condition break="on-true" expression="^(?:<sip:)?0(\d{9})((?:@.+)?)$" field="${sip_h_Diversion}"></p>
<p class="MsoNormal"> <action application="set" data="sip_h_Diversion=<sip:$1$2"/></p>
<p class="MsoNormal"></condition></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">to apply a modification on the Diversion Header, but this condition is unrecognized.</p>
<p class="MsoNormal">I hope someone could explain me, if I have to extract this variable before to use it and how to simply do it ?
</p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks,</p>
<p class="MsoNormal">Bests Regards, <br>
Alexis Devin</p>
</div>
</body>
</html>