Comparing Values


Posted on 16th Feb 2014 07:03 pm by admin

Hi
I'm reading data from a database and this seems to work OK.

Each system has an associated series of references..
Did you know?Explore Trending and Topic pages for more stories like this.

Code:

Code: $dn = "cn=System";
$filter="(objectclass=*)";
$values = array('cn','telephone','id','intref','dataref','sysref');
$sr=ldap_list($ds, $dn, $filter, $values);
$info = ldap_get_entries($ds, $sr);
for ($n=0; $n<$info['count']; $n++) {
$cn = $info[$n]['cn'][0];
$tele[$cn] = $info[$n]['telephone'][0];
$id[$cn] = $info[$n]['id'][0];
$intref[$cn] = $info[$n]['intref'][0];
$dataref[$cn] = $info[$n]['dataref'][0];
$sysref[$cn] = $info[$n]['sysref'][0];
}

foreach ($tele as $key => $value) {

echo $key . " - Phone: " . $value . " - ID: " . $id[$key] . " - intref: " . $intref[$key] . " - dataref: " . $dataref[$key]. " - sysref: " . $sysref[$key]. "
";

}
What I'm trying to do is
Code:

Code: if id = intref, or id = dataref or id = sysref
then display intref or dataref or sysref in bold.

Obviously I need to check to see if ID from any of the systems match any of the refs.

I think that makes sense !!
No comments posted yet

Your Answer:

Login to answer
67 Like 52 Dislike
Previous forums Next forums
Other forums

Simultaneous select/update/insert
Hi

How would I need to go about when 2 users update a single row simultaneous? And how would

BAPI BBP_INB_DELIVERY_CREATE - material number missing in delivery
Hi Experts,

I was able to successfully create an Inbound delivery with reference to a PO

Load Animated Image while cache is serve
I have a page that loads up using cache and took about 1 to 2 minutes before it loads to the page. <

PHP/Database issue
My friend is helping me make a database where you go to a certain webpage of my site and the page wi

ereg_replace issue
hi there people

i have this code happening with regards to my wamp server. is this something

building a function with multiple outputs
I want to build a function that has multiple outputs.

I know but am not to sure how I should

path to include folder
Hi everyone,

When I'm testing locally, I have to add the name of the site folder as part of t

get font info from a font file
hello,

Does anyone know how to get font info from a font file ... using php of course !
<

extract data
Code: <div class="post hentry uncustomized-post-template">

losing variables between php brackets
Hi

have got this code:
Code: $id=mysql_result($result,0,"itemid");
$title=mys

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash