Ask not what osTicket community can do for you - ask what you can do for osTicket community

Go Back   osTicket Forums > osTicket 1.6.x > Mods and Customizations

Reply
 
Thread Tools Search this Thread Display Modes
  #31  
Old 08-09-2010, 12:58 PM
AzNWiLL5o4 AzNWiLL5o4 is offline
Junior Member
 
Join Date: May 2010
Posts: 4
Default

Does anyone know how to make this MOD go one step further? Like add Username lookup into the equation? Thanks!
Reply With Quote
  #32  
Old 08-12-2010, 04:52 PM
ddd ddd is offline
Junior Member
 
Join Date: Aug 2010
Posts: 1
Default

Quote:
Originally Posted by Burnout View Post
Mhh, I made every changes like in the tutorial above and i get following error message:

"Ajax error: 500"

Any ideas?
I can tell you what solved it for me. First off confirm that you have properly enabled ldap in PHP which would be shown in phpinfo(); output. Once that is complete the Ajax error should go away.

After that if you don't receive any drop-down lists when typing in e-mail/name you are searching the root of your AD then in userfind.php replace:
Code:
//       STOP EDIT
with:
Code:
//       STOP EDIT 
ldap_set_option($ds, LDAP_OPT_REFERRALS, 0);
ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3);
That will help avoid any delays or timeouts you might receive when searching the root of the AD, which is how I was using it.
Reply With Quote
  #33  
Old 08-17-2010, 10:42 AM
martinglover martinglover is offline
Junior Member
 
Join Date: Aug 2010
Posts: 6
Default

JoseLuis post worked a treat first time for me. Many thanks to all involved.
Reply With Quote
  #34  
Old 08-18-2010, 08:48 PM
kyle4812 kyle4812 is offline
Junior Member
 
Join Date: Oct 2009
Posts: 9
Default

Quote:
Originally Posted by schnarchnase View Post
First of all I would say that this Mod is great and works perfectly.

Is there a way to supplement the modification so that even the phone number is read from the AD and placed in the appropriate field.

Has anyone worked out how to pull the phone numbers yet ?
This would be a handy option, but i can't quite get it working just yet.
Reply With Quote
  #35  
Old 09-28-2010, 10:29 AM
CSimpson CSimpson is offline
Junior Member
 
Join Date: Sep 2010
Posts: 6
Default

On the new ticket page, when I begin typing a first name, I get the following in Firefox:

Error: invalid regular expression flag v
Source File: http://apps.staffordgroup.com/itsupp...ggest_2.1.3.js
Line: 287, Column: 120
Source Code:
<b>Warning</b>: ldap_search() [<a href='function.ldap-search'>function.ldap-search</a>]: Search: No such object in <b>/var/www/itsupport/upload/scp/userfind.php</b> on line <b>37</b><br />

Last edited by CSimpson; 09-28-2010 at 10:54 AM.
Reply With Quote
  #36  
Old 10-02-2010, 10:22 PM
pyther pyther is offline
Junior Member
 
Join Date: Sep 2010
Posts: 4
Default

I needed to lookup users in two different OUs

So here are the changes I made...
I hope this can help someone!
PHP Code:
--- userfind.php.original    2010-10-02 22:15:23.000000000 -0400
+++ userfind.php    2010-10-02 22:20:22.000000000 -0400
@@ -4,13 +4,13 @@
 
 
//       START EDIT
 //Replace this with the DN of the base OU you want to search
-$search_user_dn "OU=Users,DC=domain,DC=local"
+
$search_user_dn = array("OU=Staff,DC=ndcls,DC=local","OU=Faculty,DC=ndcls,DC=local"); 
 
//       STOP EDIT
 
 
$inforequired = array("displayName","mail");
@@ -
33,+33,@@ else
                 
$curName.='*';
                 
$filter="(&(displayName=$curName)(objectCategory=person))";
         }
-        
$user_result ldap_search($ds,$search_user_dn,$filter,$inforequired);
-        
$user_info ldap_get_entries($ds,$user_result);
+        
$user_result = array(ldap_search($ds,$search_user_dn[0],$filter,$inforequired), ldap_search($ds,$search_user_dn[1],$filter,$inforequired));
+        
$user_info array_merge(ldap_get_entries($ds,$user_result[0]),ldap_get_entries($ds,$user_result[1]));
+        
asort($user_info);
         
header("Content-Type: application/json");
                 echo
"{\"results\": [";
                 
$arr=Array(); 
Reply With Quote
  #37  
Old 11-17-2010, 06:18 PM
ozkr ozkr is offline
Member
 
Join Date: Feb 2009
Location: Lima-Perú
Posts: 151
Default

Has anyone worked out how to pull the phone numbers, title or any other field yet ?
help!

forget it it works!

what i want now is a list of the fields in active directory

i found the active directory schema and there i can find what i want!

thanks!

Last edited by ozkr; 11-18-2010 at 10:43 AM.
Reply With Quote
  #38  
Old 11-24-2010, 12:20 PM
xirnibor xirnibor is offline
Junior Member
 
Join Date: Nov 2010
Posts: 25
Default

i have gone thru the steps, but i dont see the drop down list in Name reflecting the AD change.? please advise




Last edited by xirnibor; 11-24-2010 at 12:53 PM.
Reply With Quote
  #39  
Old 03-03-2011, 09:33 AM
ozkr ozkr is offline
Member
 
Join Date: Feb 2009
Location: Lima-Perú
Posts: 151
Default

is there a way i can exclude the inactives users (AD) from the search?
Reply With Quote
  #40  
Old 03-16-2011, 03:19 PM
cloudpointoh cloudpointoh is offline
Member
 
Join Date: Mar 2011
Posts: 46
Default

Is there a way for when the users get the drop down list with the suggested names that they can use the arrow keys instead of their mouse? That's been a question of just about everyone who has been using it...
Reply With Quote


Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:06 PM.