1

soapclient 呼び出しに問題があります。soaprequest は次のようにする必要があります。

      <eng:Compose>
     <!--Optional:-->
     <EWSComposeRequest>
        <!--Optional:-->
        <driver>
           <!--Optional:-->
           <driver>base64</driver>
           <!--Optional:-->
           <fileName>INPUT</fileName>
        </driver>
         <engineOptions>   
            <name>FILEMAP</name>
            <value>DLFOUT.dlf,dummy.dlf</value>
         </engineOptions>
         <engineOptions>
            <name>FILEMAP</name>
            <value>PDFOUT.pdf,dummy.pdf</value>     
         </engineOptions>
         <engineOptions>
            <name>RUNMODE</name>
        <value>PRODUCTION</value>           
        </engineOptions>
        <!--Optional:-->
        <fileReturnRegEx>^.*.(dlf|pdf)$</fileReturnRegEx>
        <includeHeader>True</includeHeader>
        <includeMessageFile>True</includeMessageFile>
        <!--Optional:-->
        <pubFile>TestLive.pub</pubFile>
     </EWSComposeRequest>
  </eng:Compose>

私のsoap_paramは次のとおりです。

$soap_param = array("Compose"=> array("EWSComposeRequest" => 
        array( "driver" => array( "driver" => $post_Driver, 
        "fileName" => $post_FileName), 
        "engineOptions" => array( "name" => "KEY", "value" => $INI['encodedkey']),
        "engineOptions" => array( "name" => "RUNMODE", "value" => $INI['runmode']), 
        "fileReturnRegEx" => $post_FileReturnRegEx, "includeHeader" => $post_IncludeHeader,
        "includeMessageFile" => $post_IncludeMessage, "pubFile" => $post_PubFile)));

ただし、soapcall は機能しているように見えます....最後の engineOptions 要素だけを受け取ります。xsd によると、要素 engineOptions は複数回表示できます (0 から無制限)。ソープコール内で、この要素は上書きされているようです。インデックス: engineOptions は一意ではありません。

この問題に直面しているのは私だけだとは想像できません。この問題の (簡単な) 解決策があることを願っています。

4

1 に答える 1

0

András Szepesházi に特に感謝します。次の$soap_param定義:

$soap_param => array(
    'Compose' => array(
        'EWSComposeRequest' => array(
            'driver' => array( 
                'driver' => $post_Driver, 
                'fileName' => $post_FileName
            ),
            'engineOptions' => array(
                array(
                    'name' => 'KEY', 
                    'value' => $INI['encodedkey']
                ), 
                array(                     
                    'name' => 'RUNMODE', 
                    'value' => $INI['runmode']
                ), 
                array(
                    'name' => 'FILEMAP', 
                    'value' => "DLFOUT.dlf,dummy.dlf"
                ), 
                array(
                    'name' => 'FILEMAP',
                    'value' => "PDFOUT.pdf,dummy.pdf"
                ),
            ),
            'fileReturnRegEx' => $post_fileReturnPattern, 
            'includeHeader' => $post_IncludeHeader, 
            'includeMessageFile' => $post_IncludeMessage, 
            'pubFile' => $post_PubFile
        )
    )
);

次の SOAP リクエストを作成できます。

    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="urn:hpexstream-services/Engine">
    <SOAP-ENV:Header>
        <ns1:n>n</ns1:n>
    </SOAP-ENV:Header>
    <SOAP-ENV:Body>
        <ns1:Compose>
            <EWSComposeRequest>
                <driver>
                    <driver>base64</driver>
                    <fileName>INPUT</fileName>
                </driver>
                <engineOptions>
                    <name>KEY</name>
                    <value>base64</value>
                </engineOptions>
                <engineOptions>
                    <name>RUNMODE</name>
                    <value>PRODUCTION</value>
                </engineOptions>
                <engineOptions>
                    <name>FILEMAP</name>
                    <value>DLFOUT.dlf,dummy.dlf</value>
                </engineOptions>
                <engineOptions>
                    <name>FILEMAP</name>
                    <value>PDFOUT.pdf,dummy.pdf</value>
                </engineOptions>
                <includeHeader>true</includeHeader>
                <includeMessageFile>true</includeMessageFile>
                <pubFile>TestLive.pub</pubFile>
            </EWSComposeRequest>
        </ns1:Compose>
    </SOAP-ENV:Body>
</SOAP-ENV:Envelope>

それで問題は解決しました。

于 2013-05-07T13:35:41.060 に答える