Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

FOP2 Community Forum

  1. Home
  2. Support
  3. Wrong CallerID number to name conversion

Wrong CallerID number to name conversion

Scheduled Pinned Locked Moved Support
5 Posts 2 Posters 56 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • K
    K
    Kurgan
    wrote on last edited by
    #1

    I have FOP2 2.26 installed, and I have entered some data in the phonebook. Fop2 correctly shows (in the notification box that pops up when my phone rings) names for external callers when number is matched in the phonebook, but when an extension (number 34) calls me, the phonebook matches the number (34) to the last two digits of a phone book contact that has a number that ends in 34 (05164455334), and shows me the external contact name, which is clearly wrong.

    I think that the number matching should be done using at least 5 or 6 numbers, so that estension numbers do not match phonebook records that end in the same 2 numbers as the extension.

    Ideally the minimum lenght of a number to be matched should be configurable, with a sane default of 5 or 6 numbers.

    1 Reply Last reply
    0
    • N
      N
      nicolas
      wrote on last edited by
      #2

      What fop2 version are you using?

      1 Reply Last reply
      0
      • K
        K
        Kurgan
        wrote on last edited by
        #3

        2.26, the latest non-beta.

        1 Reply Last reply
        0
        • N
          N
          nicolas
          wrote on last edited by
          #4

          You will have to modify the file /var/www/html/fop2/checkdir.php, look for an if block after a mysql query:

          if($res) {
              if($db->num_rows()>0) {
                  $row = $db->fetch_assoc();
                  ...
                  ...
              }    
          }
          

          Add another if block before to exclude short clids, something like:

          if($largo<5) {
              if($res) { 
                  if($db->num_rows()>0) {
                      $row = $db->fetch_assoc();
                      ...
                      ...
                  }
              }
          }
          
          1 Reply Last reply
          0
          • K
            K
            Kurgan
            wrote on last edited by
            #5

            Thanks, I will modify the code.

            I suggest that you include this fix in the next version.

            1 Reply Last reply
            0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better 💗

            Register Login
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            Powered by NodeBB Contributors
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups