CID Superfecta + FreePBX 2.9

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
Interesting. So if I understand you correctly, step 3 works fine for you and there is no <cr> in the browser displayed CNAM. If so that points to a bug in FreePBX CallerID module and not Superfecta. Anyone else have something to add?

Lorne

correct -- the cnam shows up properly on the web page using the debug option. Whether this points to an error in the FreePBX module or not, I have no idea. Seems to me that the problem would be in Callerid.php.
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
If you try the check I just posted and it works then I can have a fix out for this for all 2.9 clients in about 5 hours....
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
If you try the check I just posted and it works then I can have a fix out for this for all 2.9 clients in about 5 hours....
If you're referring to removing the >? at the end of functions.inc.php, I tried that and it didn't make a difference for me. But it was a good idea and worth trying. I did reload the config but I did not shutdown and restart asterisk. Did I need to do a restart?
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
take a look at this routine in callerid.php

it appears to strip out the control characters.

specifically, I'm wondering if the parms to preg_replace are specified correctly. (I'm not very knowledgeable about escape sequences.)

//remove unauthorized character in the caller id
if ($first_caller_id !='')
{
//$first_caller_id = _utf8_decode($first_caller_id);
$first_caller_id = strip_tags($first_caller_id );
$first_caller_id = trim ($first_caller_id);
if ($charsetIA5)
{
$first_caller_id = stripAccents($first_caller_id);
}
$first_caller_id = preg_replace ( "/[\";']/", "", $first_caller_id);
//limit caller id to the first 60 char
$first_caller_id = substr($first_caller_id,0,60);
}
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
then I have no idea how the cr/lf is getting into the results
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
Here's an idea.

Create a simple html page in the sources folder of superfecta.

Call it something like: "test.html" and inside it put some random number. Like "5550159" and no cr or lf

Then go and create a new callerid lookup source inside the caller id lookup and tell it to reference "test.html" and go and change your inbound routes to reference this new "source"

See what happens with the phones.

Let us know
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
could have left out the "localhost" on the host field in the config
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
Here's an idea.

Create a simple html page in the sources folder of superfecta.

Call it something like: "test.html" and inside it put some random number. Like "5550159" and no cr or lf

Then go and create a new callerid lookup source inside the caller id lookup and tell it to reference "test.html" and go and change your inbound routes to reference this new "source"

See what happens with the phones.

Let us know
I get the "DOCTYPE HTML" error whether I put in the userid/password or not, and whether or not it is a .txt file or .html file.

But I don't get the CR/LF, so maybe that narrows it down a little?
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
Unfortunately I still can't replicate this.

I even wiped my machine and installed from scratch and it still works just fine for me

Sorry guys :confused5:
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
I'm running PBX in a Flash on CentOS. I doubt if either of those make a difference, but that's more info for you.
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
I'm running the same.

Also I only have one source enabled. Just who called. Thats all Im checking it with.

I'm running PBX in a Flash on CentOS. I doubt if either of those make a difference, but that's more info for you.
 

rcoates

New Member
Joined
Apr 5, 2011
Messages
25
Reaction score
2
I'm running the same.

Also I only have one source enabled. Just who called. Thats all Im checking it with.
I have several sources enabled, but I don't think that is making a difference. I'm not sure, but the system may have been upgraded directly from FreePBX 2.7.x to 2.9.x, skipping 2.8 entirely. I don't know if that would make a difference.
 

cmccoy1234

New Member
Joined
Feb 19, 2010
Messages
1
Reaction score
0
I am showing the same problem as rcoates.

CR in the name result:

-- Executing [s@macro-user-callerid:26] Set("SIP/xxxxxxxxxx-08d24780", "CALLERID(name)=
Name") in new stack

FreePBX 2.9 and Asterisk 1.4
 

gladroger

New Member
Joined
Sep 17, 2009
Messages
13
Reaction score
0
PBX in a Flash: 1.7.5.5
FreePBX: 2.9.0rc1.1
Asterisk: 1.4.21.2
Centos
 

gladroger

New Member
Joined
Sep 17, 2009
Messages
13
Reaction score
0
So it works better if we upgrade Asterisk aswell to development?
 

wardmundy

Nerd Uno
Joined
Oct 12, 2007
Messages
19,201
Reaction score
5,219
Have any of you spoken with Andy Nagy to perhaps try to get a handle on what the problem is? FreePBX 2.9 isn't going to wither on the vine without CallerID Superfecta so it probably would be good to get in sync for the future benefit of all of us. :idea:
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
I saw that too and I did a bug lookup to see if any of the errors were there in the past but alas. Nothing

On another note if anyone has a broken server and they want to send me the login info to my email I can solo the project one-on-one and fix/kill the bug.

I'm just waiting for someone to offer the server.

I can even install my own trunks (bandwidth/freepbx provided trunks so they are secure). You won't have to pay a cent for me to test everything.

This is me OFFERING FREE support from one of the FreePBX Developers (hi that's me). Can't get much better than that.......:biggrin5:

I just realized that the FreePBX CID lookup module is currently at version 2.9.0.4 as reported in the FreePBX module administration page. I can't find a changelog anywhere to indicate what has happened in earlier 2.9.x versions. Everyone who is experiencing this problem please ensure you are using the latest version of the CallerID Lookup module

Lorne
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
Thanks to ustelephone I have a broken machine to test on. Hopefully I can figure something out.
 

tm1000

Schmoozecom INC/FreePBX
Joined
Dec 1, 2009
Messages
1,360
Reaction score
78
I have determined the issue.

This will sound a little weird at first so bare with me.

The problem file is this

Code:
admin/modules/hotelwakeup/functions.inc.php

When loading the bootstrap files for 2.9 it goes through and loads all of the functions files for each module. As a FreePBX developer I know why this is done, I just didn't know it was done during bootstrap.

The newline is at the bottom of the php file. If you are coding a PHP file that will be included it is not a good idea to put the ?> closing tag at the end. In this case there was a carriage return after that closing tag. Because it wasn't part of the code php interpreted this as html and spit it back out. Causing the issues.

Removing just the "?>" will fix the problem entirely.

Thanks again to ustelephone for his server.
 

Members online

Forum statistics

Threads
25,810
Messages
167,752
Members
19,240
Latest member
nikko
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Top