How to dial from a web page a local pbx ext without using the number var

I have read TAPI Click-To-Dial possible? - #24 by Drrehak
and that is for if a number is to be dialed as well as an ext but i just need the call the ext not a number how do i do this?

the TAPI Click-To-Dial possible? - #24 by Drrehak
page is locked so i cant ask on there?

please help.

FreePBX expects you to use numbers, but those numbers can map to miscellaneous applications.

It’s not clear whether the A side is your phone, or someone else’s. In the latter case, you probably don’t want the AddHeader. Also the way that code does AddHeader will only work for chan_sip, and should be retiring chan_sip, in favour of chan_pjsip. In addition, FreePBX is not limited to SIP extensions.

Also, under FreePBX, it is arguably better to use a local channel, on A the side, to use the FreePBX logic on that side. You should be able to use “*80” in the number, to get an an autoanswer, if calling yourself.

(It doesn’t make sense to dial a number on the A side, and do nothing on the B side, but the B side doesn’t have to be a trunk or extension.)

(If you want to reopen an old topic, you can flag it and ask for it to be reopened. However, in this case, I think that would be the wrong action.)

yer the rest api method dont work either i just want to be able to recive calls to 1 specific ext from any web page i setup php if that makes sense?

Can you please describe your scenario in more detail, as a call from a web page, to me, means that the web server makes a SIP call, or the browser makes a WebRTC call, both of which would be handled as normal incoming calls by FreePBX.

http://FREEPBX-IP/clicktocall/a.php

should then automattically call my pbx ext 2000 (no auto answer) when i pick up i can then communicate with the caller that is using a browser. understand? there is no outside line needed, just internet.

That’s not click and call as normally understood. Although I’ve never used WebRTC, I believe it is a WebRTC call from the browser. To Asterisk there is one incoming call leg and one outgoing one.

As far as I know it is not sensible and probably not possible to do a click to call scenario to a browser, but if you could the channel parameter in the originate, would be the address of the browser based WebRTC client, and the num parameter would be your extension 2000.

Although I haven’t validated it in detail, this topic seems to be about what you actually want to do:

Be warned that WebRTC is a moving target. You should make sure you have the latest versions at both ends (e.g. it would be unwise to try to continue to use chan_sip with it). You should be prepared to have to read up on protocol and do low level debugging.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.