Jump to content
Fórum Script Brasil
  • 0

Array


shelter
 Share

Question

Boa galera,
Então estou tendo muita dificuldade pegar os dados de array, segue:
Tenho este codigo:
include "phpAMI.php";
$ami=new phpAMI("admin","admin");
$login=$ami->login();
if($login["Response"]=="Success"){
        print_r($ami->queueStatus ());
    $ami->logoff();
}


Recebo o seguinte:
Array ( [Response] => Success [Message] => Queue status will follow

  • => Array ( [default] => Array ( [Event] => QueueParams [Queue] => default [Max] => 0 [Strategy] => ringall [Calls] => 0 [Holdtime] => 0 [TalkTime] => 0 [Completed] => 0 [Abandoned] => 0 [ServiceLevel] => 0 [ServicelevelPerf] => 0.0 [Weight] => 0 [mNumber] => 0 ) [5000] => Array ( [Event] => QueueParams [Queue] => 5000 [Max] => 0 [Strategy] => ringall [Calls] => 0 [Holdtime] => 0 [TalkTime] => 0 [Completed] => 0 [Abandoned] => 0 [ServiceLevel] => 60 [ServicelevelPerf] => 0.0 [Weight] => 0 [mNumber] => 2 [members] => Array ( [Agent/0001] => Array ( [Event] => QueueMember [Queue] => 5000 [Name] => Agent/0001 [Location] => Agent/0001 [StateInterface] => Agent/0001 [Membership] => static [Penalty] => 0 [CallsTaken] => 0 [LastCall] => 0 [Status] => 1 [Paused] => 0 ) [Agent/0002] => Array ( [Event] => QueueMember [Queue] => 5000 [Name] => Agent/0002 [Location] => Agent/0002 [StateInterface] => Agent/0002 [Membership] => static [Penalty] => 0 [CallsTaken] => 0 [LastCall] => 0 [Status] => 5 [Paused] => 0 ) ) ) [5001] => Array ( [Event] => QueueParams [Queue] => 5001 [Max] => 0 [Strategy] => ringall [Calls] => 0 [Holdtime] => 0 [TalkTime] => 0 [Completed] => 0 [Abandoned] => 0 [ServiceLevel] => 60 [ServicelevelPerf] => 0.0 [Weight] => 0 [mNumber] => 2 [members] => Array ( [Agent/0003] => Array ( [Event] => QueueMember [Queue] => 5001 [Name] => Agent/0003 [Location] => Agent/0003 [StateInterface] => Agent/0003 [Membership] => static [Penalty] => 0 [CallsTaken] => 0 [LastCall] => 0 [Status] => 5 [Paused] => 0 ) [Agent/0004] => Array ( [Event] => QueueMember [Queue] => 5001 [Name] => Agent/0004 [Location] => Agent/0004 [StateInterface] => Agent/0004 [Membership] => static [Penalty] => 0 [CallsTaken] => 0 [LastCall] => 0 [Status] => 5 [Paused] => 0 ) ) ) ) [nQueues] => 3 ) 

Gostaria de ler assim:
ex.:

Response: Success
Message: Queue status will follow

Event: QueueParams
Queue: queue1
Max: 0
Strategy: ringall
Calls: 0
Holdtime: 0
TalkTime: 16
Completed: 3
Abandoned: 2
ServiceLevel: 0
ServicelevelPerf: 33.3
Weight: 0

Event: QueueMember
Queue: queue1
Name: Agent/1001
Location: Agent/1001
Membership: static
Penalty: 0
CallsTaken: 3
LastCall: 1330136746
Status: 5
Paused: 0

Event: QueueParams
Queue: queue2
Max: 0
Strategy: ringall
Calls: 0
Holdtime: 0
TalkTime: 0
Completed: 0
Abandoned: 0
ServiceLevel: 0
ServicelevelPerf: 0.0
Weight: 0

Event: QueueMember
Queue: queue2
Name: Agent/1001
Location: Agent/1001
Membership: static
Penalty: 0
CallsTaken: 0
LastCall: 0
Status: 5
Paused: 0

alguém poderia me ajudar?

Agradeço desde já aos amigos,
grato.
 

Link to comment
Share on other sites

0 answers to this question

Recommended Posts

There have been no answers to this question yet

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



  • Forum Statistics

    • Total Topics
      149.6k
    • Total Posts
      646.2k
×
×
  • Create New...