<p>Sorry you should be escaping with \\\ not ///. All vars from spandsp need to be escaped with this. The others you shouldn't have to do that.</p>
<p>-BDF</p>
<div class="gmail_quote">On May 6, 2012 7:37 PM, "Brian Foster" <<a href="mailto:bdfoster@endigotech.com">bdfoster@endigotech.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<p>Make sure you're escaping the variable with ///. This variable works in my setup. Admittedly I'm using api_hangup_hook and letting my script decipher whether or not the fax was successful or not. You can also use fax_document_transferred_pages. The difference between that and ...total_pages is that transferred pages shows how many pages made it and total_pages shows how many should have made it. </p>
<p>-BDF</p>
<div class="gmail_quote">On May 6, 2012 7:02 PM, "Darcy Primrose" <<a href="mailto:darcyp@voice2net.ca" target="_blank">darcyp@voice2net.ca</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<u></u>
<div bgcolor="#ffffff">
<div><font face="Arial">I did do that, however, if lists
fax_document_total_pages as NA, and when I try to pass that parameter, I get a
blank field. The dialplan below is not our production, it is merely a test
platfrom we use to allow us to ensure your data flow is correct.</font></div>
<div><font face="Arial"></font> </div>
<div><font face="Arial">Darcy</font></div>
<blockquote style="PADDING-RIGHT:0px;PADDING-LEFT:5px;MARGIN-LEFT:5px;BORDER-LEFT:#000000 2px solid;MARGIN-RIGHT:0px">
<div style="FONT:10pt arial">----- Original Message ----- </div>
<div style="BACKGROUND:#e4e4e4;FONT:10pt arial"><b>From:</b>
<a title="bdfoster@endigotech.com" href="mailto:bdfoster@endigotech.com" target="_blank">Brian
Foster</a> </div>
<div style="FONT:10pt arial"><b>To:</b> <a title="freeswitch-users@lists.freeswitch.org" href="mailto:freeswitch-users@lists.freeswitch.org" target="_blank">FreeSWITCH Users Help</a>
</div>
<div style="FONT:10pt arial"><b>Sent:</b> Sunday, May 06, 2012 1:39 PM</div>
<div style="FONT:10pt arial"><b>Subject:</b> Re: [Freeswitch-users]
execute_on_fax_success/failure</div>
<div><br></div>
<p>You news to pass fax_document_total_pages to your script. Please read the
spandsp page on the wiki (search spandsp). </p>
<p>Also by looking at your script you might be able to polish up your dialplan
so that its not so complicated.</p>
<div class="gmail_quote">On May 6, 2012 11:06 AM, "Darcy Primrose" <<a href="mailto:darcyp@voice2net.ca" target="_blank">darcyp@voice2net.ca</a>> wrote:<br type="attribution">
<blockquote class="gmail_quote" style="PADDING-LEFT:1ex;MARGIN:0px 0px 0px 0.8ex;BORDER-LEFT:#ccc 1px solid"><u></u>
<div bgcolor="#ffffff">
<div><font face="Arial">I am using excute_on_fax_success to call a script when
a fax is received, the script converts the fax to pdf and emails it,
Is there a way to pass the number of pages received, ie, a variable created
by spandsp. Everything works, but I do not seem to be able to pass the
variables.</font></div>
<div><font face="Arial"></font> </div>
<div><font face="Arial"> <condition field="destination_number"
expression="^1(\d{10})$|(\d{10})$"><br>
<action application="set"
data="faxtempdirectory=/faxfiles/${caller_id_number}"/> <br>
<action application="system" data="mkdir
${faxtempdirectory}"/> <br>
<action application="set"
data="faxDirection=outbound"/> <br>
<action application="set" data="<a href="mailto:emailAddress=$1$2@$%7Bfax2net_server%7D%22/" target="_blank">emailAddress=$1$2@${fax2net_server}"/</a>><br>
<action application="set"
data="faxFile=$1$2-${caller_id_number}-${strftime(%Y-%m-%d-%H-%M-%S)-Success}"/><br> <action
application="set" data="execute_on_fax_success=system
/./var/mail/sentfaxes/fax2mail.sh ${faxFile} <a href="mailto:$1$2@$%7Bfax2net_server" target="_blank">$1$2@${fax2net_server</a>} ${fax_security_code} ${fromRc}
fax2net_orig=${fax_email}= ${fax_transfer_rate}"/>
</font></div>
<div><font face="Arial"> <action
application="answer"/><br> <action
application="playback"
data="silence_stream://2000"/><br>
<action application="set"
data="fax_enable_t38_request=true"/><br>
<action application="set"
data="fax_enable_t38=true"/><br>
<action application="rxfax"
data="${faxFile}.tif"/><br>
<action
application="hangup"/><br> </condition>
<br></font></div>
<div><font face="Arial">Thanks</font></div>
<div><font face="Arial">Darcy
Primrose</font></div></div><br>_________________________________________________________________________<br>Professional
FreeSWITCH Consulting Services:<br><a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br><a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>FreeSWITCH-powered
IP PBX: The CudaTel Communication Server<br><a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br><br>Official FreeSWITCH
Sites<br><a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br><a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br><a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>FreeSWITCH-users mailing
list<br><a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br><a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div>
<p>
<hr>
<p></p>_________________________________________________________________________<br>Professional
FreeSWITCH Consulting
Services:<br><a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br><a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br><br>FreeSWITCH-powered
IP PBX: The CudaTel Communication
Server<br><a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br><br>Official FreeSWITCH
Sites<br><a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br><a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br><a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>FreeSWITCH-users
mailing
list<br><a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br><a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
</p></blockquote></div>
<br>_________________________________________________________________________<br>
Professional FreeSWITCH Consulting Services:<br>
<a href="mailto:consulting@freeswitch.org" target="_blank">consulting@freeswitch.org</a><br>
<a href="http://www.freeswitchsolutions.com" target="_blank">http://www.freeswitchsolutions.com</a><br>
<br>
FreeSWITCH-powered IP PBX: The CudaTel Communication Server<br>
<a href="http://www.cudatel.com" target="_blank">http://www.cudatel.com</a><br>
<br>
Official FreeSWITCH Sites<br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<a href="http://wiki.freeswitch.org" target="_blank">http://wiki.freeswitch.org</a><br>
<a href="http://www.cluecon.com" target="_blank">http://www.cluecon.com</a><br>
<br>
FreeSWITCH-users mailing list<br>
<a href="mailto:FreeSWITCH-users@lists.freeswitch.org" target="_blank">FreeSWITCH-users@lists.freeswitch.org</a><br>
<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a><br>
UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users" target="_blank">http://lists.freeswitch.org/mailman/options/freeswitch-users</a><br>
<a href="http://www.freeswitch.org" target="_blank">http://www.freeswitch.org</a><br>
<br></blockquote></div>
</blockquote></div>