I am New to this Form i am working on project to consume Java Webservice from PHP (front end). So i need to display an image sent from JWS (WSDL) mode in PHP. I have used diff methods in JWS to send the image viz as BLOB type or byte type. But unable to display it in PHP. It need to be decoded back to display which i am unable to do. Does PHP's current version has this capabilty or not??. Here is my code snippet of the soap Response genertated to be consumed in PHP.
Expand|Select|Wrap|Line Numbers
- stdClass Object
- (
- [return] => stdClass Object
- (
- [photo] => stdClass Object
- (
- [bytes] => Ю5N5MGIF89a ЯИ5Sх z jGIF89a !1џZZZcџkkksssџЅЅЅНRННЦЮЮЦЮЮЮжЅЮо{оо*чJячяџяJяRcяBџџcџџ1џBџџЮџЮџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџџ
- )
- [student_address] => 123-933-22, LA, Hyd ,India
- [student_history] => Completed M.Tech from [student_hobbies] => Eating, Chatting ,Sleeping etc ...
- [student_id] => 1
- )
- )
Expand|Select|Wrap|Line Numbers
- $wsdl = "http://localhost:8084/webserviceproj/WebServicesService?wsdl";
- $client = new soapclient($wsdl,array('trace' => 1));
- $res=$client->__soapCall('studDetails', array('parameters' => $params));
- $variables = get_object_vars($res);
- $keys = array_keys($variables);
- $abc= $variables[$keys[0]]->photo;
- $aa = $abc->bytes;