Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dolibarr
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
756de27a
Commit
756de27a
authored
10 years ago
by
Laurent Destailleur
Browse files
Options
Downloads
Patches
Plain Diff
Fix syntax error
parent
684686e0
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
htdocs/asterisk/cidlookup.php
+9
-11
9 additions, 11 deletions
htdocs/asterisk/cidlookup.php
with
9 additions
and
11 deletions
htdocs/asterisk/cidlookup.php
+
9
−
11
View file @
756de27a
...
@@ -17,27 +17,25 @@
...
@@ -17,27 +17,25 @@
/**
/**
* \file htdocs/asterisk/cidlookup.php
* \file htdocs/asterisk/cidlookup.php
* \brief Script to search companies names based on incoming calls
* \brief Script to search companies names based on incoming calls
, from caller phone number
* \remarks To use this script, your Asterisk must be compiled with CURL,
* \remarks To use this script, your Asterisk must be compiled with CURL,
* and your dialplan must be something like this:
* and your dialplan must be something like this:
*
*
* exten => s,1,Set(CALLERID(name)=${CURL(http://IP-DOLIBARR:80/asterisk/cidlookup.php?phone=${CALLERID(num)})})
* exten => s,1,Set(CALLERID(name)=${CURL(http://IP-DOLIBARR:80/asterisk/cidlookup.php?phone=${CALLERID(num)})})
*
*
* Change IP-DOLIBARR to the IP address of your dolibarr
* Change IP-DOLIBARR to the IP address of your dolibarr server
* server
*
*/
*/
include
'../master.inc.php'
;
include
'../master.inc.php'
;
$phone
=
GETPOST
(
'phone'
);
$phone
=
GETPOST
(
'phone'
);
$notfound
=
"Not found"
;
$notfound
=
$langs
->
trans
(
"Unknown"
);
$error
=
"Error"
// Security check
// Security check
if
(
empty
(
$conf
->
clicktodial
->
enabled
))
{
if
(
empty
(
$conf
->
clicktodial
->
enabled
))
print
"Error: Module Click to dial not active
\n
"
;
{
print
"Error: Module Click to dial is not enabled.
\n
"
;
exit
;
exit
;
}
}
...
@@ -73,7 +71,7 @@ if ($resql)
...
@@ -73,7 +71,7 @@ if ($resql)
else
else
{
{
dol_print_error
(
$db
,
'Error'
);
dol_print_error
(
$db
,
'Error'
);
$found
=
$e
rror
;
$found
=
'E
rror
'
;
}
}
echo
$found
;
echo
$found
;
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment