cancel
Showing results for 
Search instead for 
Did you mean: 

critical issue regarding file to website interface

Former Member
0 Kudos

hi all,

I am working on one scenario in which sender is an File. and receiver is an HTML page(actually it is a website) which responds according on the input data.

when i visited that site I came to know that there are three fields. as follows...

username:  
Password:
File:                        Browse

              POST

Actually file name contains the contents of the file feilds which varies for every transaction.

When i manually put username password and location of the file(using Browse tab) in the website page, I got the response file.

But when I put just file name I am unable to click POST tab.

My problem is:--

Is this thing is possible using XI.

I tried using HTTP and put all three inputs in the header fields of receiver HTTP channel.

But i didn't get the response.

Can anybody tell me any other solution. Since it is critical requirment for me. so Plzz respond ASAP.

Solution will be awarded

Thanks

Jaideep jain

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

thanks

former_member192295
Active Contributor
0 Kudos

Hi,

Ask to Website developer or maintenance people they will confirm how site accepting request from out side. In HTTP receiver adapter have option keep attachment, this option will keep total content as attachment. and send it to destination.

According to my requirement my target URL taken instruction one by one, so i am passing first uid & pwd in one instruction after that i will pass complete content of file as attachment. So target URL accepting complete file as attachment and uploading data into their data base directly.

Former Member
0 Kudos

hi Ranjan

I got urs approch.. Thanks for that.

My requirment is to keep user name , password and File name as content in payload

and the complete file as attachment. and send the data at once

if u select keep attachment, whole data(user name , password, File name and File content ) will get attached which doesn't meet my requirment.

Plzz put some light on that.

Thanks

Jaideep

former_member192295
Active Contributor
0 Kudos

Hi,

I think first we need to check web page functionality whether it is taken instruction one by one or some thing else. If this is one by one first send user id & paswd after that send file as attachment. It will work. I have done one of my requirement like that. Meanwhile one thing should remember XI HTTP adapter can't sent complete physical file, it will send only content of file only.

Former Member
0 Kudos

Thanks Ranjan for urs valuable response.

As u told

it is taken instruction one by one or some thing else. If this is one by one first send user id & paswd after that send file as attachment.

How can we check weather it is taking one by one. What do u mean by sending file as attachment in HTTP. As we don't have WSDL and can't go with SOAP.

As u told u have done same scenario.

Can u plzz share that how did u solve it.

Thanks

Jaideep Baid

former_member200962
Active Contributor
0 Kudos

Hi,

you said that the target system is a website...so can i say that it is a WebService exposed by some XYZ system...if yes then why dont you opt for the receiver SOAP channel....the use of SOAP channel is in such cases only (source: http://help.sap.com/saphelp_nw04/helpdata/en/29/5bd93f130f9215e10000000a155106/frameset.htm )

Also if you have any doubt regarding what kind of adapter to use please refer this discussion:

Adding one more link:

Regarding the target url, u need to use the one which you can see after you hit the Post button.

In the receiver SOAP channel, under the Target URL option u can find the User Authentication details...enter the user details who is authorised to post/upload the document.

Regards,

Abhishek.

sunil_singh13
Active Contributor
0 Kudos

Hi Jaideep,

Yes it is possible using XI,

First of all as File adapter is not synchronous so you have to use either BPM or Modules(Request ResponseBean and ResponseOneWayBean) to get the Response file from service.

You can read the file name through adapter (In Mapping or In Adapter Module) As it contains the inforamtion need to be sent to Web servcice.

Else You can pass this information in file also and do the corresponding mapping before sending it to Web service.

Thanks

Sunil Singh

Former Member
0 Kudos

Thanks Sunil for urs quick response.

I m comfortable with sender side, I m facing problem at receiver side as my Website is not exposed to any webservice.

So i am getting that which adapter i should use.

Is there any other solution.

thanks

Jaideep Jain

Former Member
0 Kudos

You need to use the HTTP Receiver adapter. Check the param names from the website that are used for (username, password and file). Use the same param name and values from the Sender File Adapter. URL Address :

http://<hostname:port>/<path>;

For path: Check the value when you click on POST. Where the data is begin posted. Use that value in your path.

If you need the response, then you need to use what is said in earlier post.

Former Member
0 Kudos

Thanks Anand for urs valuable response.

I somewhat got urs approch.

Check the param names from the website that are used for (username, password and file). Use the same param name and values from the Sender File Adapter

here my queries are:--

File field takes the location of the file(which contains the data for which i need details). how can we achieve it.

where to put the param(username, password and file) in receiver communication channel.?

what data type should i use. Can I use these param(username, password and file) as receiver data type.?

Please respond for these queries..

Thanks

Jaideep Jain

Edited by: Jaideep Baid on Nov 24, 2008 6:31 AM

former_member194786
Active Contributor
0 Kudos

Hi Jaideep,

In the Http receiver adapter you will provide the user name and password. It will be provided under the section Authentication Data. Also you need to provide the Target Host (your website url), Service Number and Path as explained earlier by others. Regarding the file path, you can use the logic in the mapping and provide that field as input.

Hope it helps.

Regards,

Sanjeev.