Page 1 of 1

findByContent is not working with php

PostPosted:Tue Oct 19, 2010 2:23 am
by sajeesh
I am trying to search files by content. But I am getting repository exception error.
Here is the code.
Code: Select all
<?php
  // Register WSDL
  $OKMAuth = new SoapClient('http://localhost:8080/OpenKM/OKMAuth?wsdl');
  $OKMSearch = new SoapClient('http://localhost:8080/OpenKM/OKMSearch?wsdl');

  // Login
  $token = $OKMAuth->login('user09','pass09');

$queryResultArrayResult = $OKMSearch->findByContent($token, 'test');
$queryResultArray = $queryResultArrayResult->value;
?>
I have no idea, where I am doing wrong.

Re: findByContent is not working with php

PostPosted:Tue Oct 19, 2010 8:51 am
by pavila
Which error is thrown and which version of OpenKM are you using?

Re: findByContent is not working with php

PostPosted:Tue Oct 19, 2010 1:00 pm
by sajeesh
I am using OpenKM version : 4.1
and I got this error
Code: Select all
Fatal error: Uncaught SoapFault exception: [env:Server] cd4b2eb4-e29b-44d6-9c1c-9ed4b671bdcf in E:\apache\htdocs\sajeesh\openkm\test1.php:11 
	Stack trace: #0 [internal function]: SoapClient->__call('findByContent', Array) 
	#1 E:\apache\htdocs\sajeesh\openkm\test1.php(11): SoapClient->findByContent('196700568473420...', 'test') 
	#2 {main} thrown in E:\apache\htdocs\sajeesh\openkm\test1.php on line 11

Re: findByContent is not working with php

PostPosted:Thu Oct 21, 2010 10:52 am
by pavila
Perhaps you should try with OpenKM 5.0 because this error is very unusual. Seems to be related to the repository backend.