How to make a Plain HTTP-Request
Hi folks,
is it posible to post somthing like this with cl_http_client.
POST /hapld/tos/kdwhapltos HTTP/1.1
Host: www.pld-certify.ups.com
Content-type: multipart/mixed; boundary=BOUNDARY
Content-length: 1038
--BOUNDARY
Content-type: application/x-www-form-urlencoded
Content-length: 140
AppVersion=1.0&AcceptUPSLicenseAgreement=Yes&ResponseType=application/x-ups-pld&VersionNumber=V4R1&UserId=xxx&Password=xxx
--BOUNDARY
Content-type: application/x-ups-binary
Content-length: 719
020082 2.0 2002101700000000000010500 000000001*AA0A1754 US 1234567002000001*BA1z1234560100002352 00001+0000000000000010 +0000000000000000LBS01PRE10
--BOUNDARY
Regards,
Max
Max,
I'm under same situation creating the multipart/mixed post, how can be handled with ABAP? I'm trying using mutipart() but I only get the message 'Internal Processing Error". I'll appreciate any help.
Similar Messages
-
Its urgent...How to implement functions in http request handler ?
Hello experts,
I have created http request handler class and also created service in SICF.
service and handler class are connected. please guide me how to implement info, get, create, delete functions in request handler.Hi,
It seems you go on your way of http basic programming where you need handle the request of info, get, etc. But here you have WDA framework, so you don't need do as the basic ways of http programming. SICF can handle the activated WDA applications, maybe you can call them SERVICES.
I suggest you go through WDA architecture, tutorials, ... and at last you can find a full demo 'LORD_MAINTAIN_COMP' by SE80. -
How does Flash send outgoing HTTP request to server?
Hello everyone,
I would like to know how Flash sends outgoing HTTP requests.
I would like to know when from the inside of a Flash SWF file
request for another SWF or FLV file is made; how the Flash sends
this request to server.
Thank you very much and have a great day,
KhoramdinHello everyone,
I would like to know how Flash sends outgoing HTTP requests.
I would like to know when from the inside of a Flash SWF file
request for another SWF or FLV file is made; how the Flash sends
this request to server.
Thank you very much and have a great day,
Khoramdin -
How to send PUT, DELETE HTTP request in HttpURLConnection ?
Hi all.
I want to know that is it possible to send PUT, DELETE request (practically) through java.net.httpURLConnection to http based URL. I have read so many articles describing that how to send GET, POST, TRACE, OPTIONS request but still not finding any sample code which successfully perform PUT and DELETE request. Can any one give idea regarding that?
ThanksHelp_Me_Solve wrote:
Hi all.
I want to know that is it possible to send PUT, DELETE request (practically) through java.net.httpURLConnection to http based URL. I have read so many articles describing that how to send GET, POST, TRACE, OPTIONS request but still not finding any sample code which successfully perform PUT and DELETE request. Can any one give idea regarding that?
ThanksIt's technically possible I am sure but 100% impractical because almost nobody uses an HTTP server for that purpose. I don't know what HTTP servers actually implement PUT and DELETE but you can be sure even in those that do the behaviour is off by default.
If you need to do PUT/DELETE sort of operations you should be using FTP. -
How to make an organization specific request
Hi All,
I am trying to build an application where, I need to send a organization specific shipping request to the third party application. i.e when I try to send a request the application should ask me from which organization request should be sent like (change organization functionality in Inventory responsibality). How can I impliment this. what all I need to consider. Any suggestion is really appreciated..
Thanks,
Kishan.If you want to use timer on server side scripts, you should use setInterval() global function. For more details check the following link:
http://help.adobe.com/en_US/adobemediaserver/ssaslr/WS5b3ccc516d4fbf351e63e3d11a11aff5ba-7 f01SSASLR.2.3.html#WS5b3ccc516d4fbf351e63e3d11a11afc95e-7ffaSSASLR.2.3 -
How to encapsulate RMI in Http request ?
Hello,
I have an java applet that uses java RMI technology to communicate with the server. I would like to modify this architecture a little. Is it possible to wrappe RMI invocation in http web request. If yes how to do that ? Did you have samples of code ?
Thanks a lot.RMI uses a specialised protocol which is more complex than it appears at first. It might be possible to perform RMI calls use a HTTP transport, but you would lose most of the value of using HTTP.
There are libraries which allow you to turn method calls into HTTP Web Service request, like RMI does, but no RMI is used. -
How to display response of http request as a web page in ABAP?
Hi all,
In ABAP, we can use class <b>cl_http_client</b> to send a http requst and then got the response data as a XSTRING variable. Usually, the response data is the html source of a web page. How to display this web page within dynpro?
I found we can use class <b>cl_gui_html_viewer</b> to display the web page of a URL or data in SAP web respository. Is there any way of using it to load response data in cl_http_client and display that web page?
Thanks a lot.Welcome to SDN.
1. use http_client->response->get_cdata( ).
to get the response data in string format instead of xstring format.
2. use FM CONVERT_STRING_TO_TABLE to covert the string to table of type W3HTML
3. use method
data: l_doc_url(255) type c.
call method html_control->load_data
exporting
type = 'text'
subtype = 'html'
importing
assigned_url = l_doc_url
changing
data_table = html_table.
call method html_control->show_data
exporting
url = l_doc_url.
to load the html content and show it in cl_gui_html_viewer
Regards
Raja -
How to make an organization specific request from Oracle Apps
Hi All,
I am trying to build an application where, I need to send a organization specific shipping request to the third party application. i.e when I try to send a request the application should ask me from which organization request should be sent like (change organization functionality in Inventory responsibality). How can I impliment this. what all I need to consider. Any suggestion is really appreciated..
Thanks,
Kishan.Thanks kglag, for trying to help,
As i posted in another forum the problem was in the free flex example which i used to add another state and by using SWFLoader to embed my swf file.
Now i was created my own flex app and add SWFLoader to embed my swf and voila - it works!
There is no cross-domain loads the loaded content is in the same domain.
So, again thanks! -
How to make setting for overlapping request-DTP
Hi,
I am creating a PC which is for monthly data and the cube in question is loaded twice as per the requirement in a month..
Now, i need to delete the same month data request when loading for the second time and rest all other previous month requests should not be touched...
For that, in the delete overlapping request variant i had selected ( in deletion selection ) only the option request date in current month...
and in the selection same or more comprehensive...
is it the rigjht selections to delete the requests of the same month? or is there any thing that i overlooked?Hi,
Please go through this article...
I have clearly explained the concept with a scenario.
http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/e0431c48-5ba4-2c10-eab6-fc91a5fc2719
Regards,
Rk. -
How to make a Loadvars sendAndLoad request from embedded swf in flex
I've developed a simple flex app with embedded swf. Basically swf use Loadvars to get data from particular database table. Ok, when I tested the flex app on localhost it is works fine and embedded swf make its sendAndLoad calls correctly.
But! When it is located on the web server swf not work correctly. I meant there is not returned values by sendAndLoad method.
Well, to make some points: questionContentLoadVars.img1 holds(return) the string from php call. This "img1" is an empty returned string only in Flex app placed in the web server otherwise it returns correct value from php call?
When gameplay22.swf is standallone works!
When gameplay22.swf is in HTML page works!
When gameplay22.swf is embedded in FLex and executed in LOCALHOST works!
But in the web server this embedded gameplay22.swf doesn`t works!
What is the problem with it?
//* here is flash(swf) part of gameplay22.swf file which is embedded in the Flex by SWFLOader(gameplay22.swf)
questionContentLoadVars = new LoadVars();
questionContentLoadVars.onLoad = function(success){
if (success){
slidingSvityk_mc.descripTA_mc.description_ta.text = questionContentLoadVars.theContent;
else
slidingSvityk_mc.description_ta.text = "err!";
function loadQuestionData(sectionID){
var tablename ='questionsgeo'; // database tablename
//sending variables to the PHP script
questionContentLoadVars.row = sectionID;
questionContentLoadVars.tablename = tablename;
questionContentLoadVars.id_ = "";
questionContentLoadVars.img1 = "";
questionContentLoadVars.sendAndLoad("getQuestionRec.php",questionContentLoadVars,"_POST") ;
function showLoadedGalleryImages():Void{
infphp.text = questionContentLoadVars.img1;
var img1Bulk:MovieClip = new MovieClip();
img1Bulk = imgGalleryContainer_mc.img1Bulck_mc.createEmptyMovieClip(img1Bulk, _root.getNextHighestDepth());
img1Bulk._x = 0;
img1Bulk._y = 0;
image_mcl.loadClip(questionContentLoadVars.img1, img1Bulk);
//* And here is Flex part of embedded SWFLOader(gameplay22.swf) component
<s:SWFLoader includeIn="user" width="1024" height="768" horizontalCenter="0" source="gameplay22.swf" verticalCenter="0"/>Thanks kglag, for trying to help,
As i posted in another forum the problem was in the free flex example which i used to add another state and by using SWFLoader to embed my swf file.
Now i was created my own flex app and add SWFLoader to embed my swf and voila - it works!
There is no cross-domain loads the loaded content is in the same domain.
So, again thanks! -
How to make a multiple request without waiting for a response in java ?
A more specific question:
how to make a multiple HTTP request without waiting for a HTTP response in java (using httpURLConnection)?
ThanksThanks for responding.
But i want to make further request to the same resource URL. I want to reuse the connection, don't want to create a new connection for each of individual request.
How can i do that using HttpURLConnection ?
Thanks. -
How to make hyperlinks in JTextField/JtextArea ??
My JTextField/JtextArea has got this Text.
String text = "Get information from http://www.hotmail.com, if you have problems go to http://www.google.com " ;
How to make hyperlinks for http://www.hotmail.com and http://www.google.com texts only???
And how to call those sites???Add a mouse listener, when the user double clicks - see if they've clicked on text that is a valid link.
The limitation of using textfield or textarea is that you get no styling. I dont know why you're refusing those suggestions, but you're just creating more work for yourself. -
How to make an HTTP request via SSL
Hi,
I´m using an instance of the class CL_HTTP_CLIENT to make an HTTP request to a https server. as long as it requires an SSL authentication, it returns an ICM_HTTP_SSL_ERROR error message.
How do I tell my program to ask for user´s certificate, and use it in the http request?
I´m supossed to have hundreds of users online running this application (it´s over SRM 5.0). How can I reach this?
Thanks you very much.
Federico.Hello Frederico,
>1. By creating a new client, you mean go to "Environment->SSL Client Identitites" in STRUST, right? >Can I use a previously existing one?
I meant to create a new client SSL PSE. By default in a new Netweaver abap system, you have 3 of them : ANONYM, DFAULT and WSSE.
If you need more of them, you can create them with the menu "Go to-->Environment->SSL Client Identitites".
>2. I need this PSE client to have several 'identitites', I mean, to include several certificates from all my >users. Is it possible? If it´s not; how should I do so?
It seems that you want a different certificate per user. These client certificates in STRUST are designes to identify a SAP abap system, not human users. If you have 1000 users, you will not create 1000 certificates in STRUST !
Usually, you use only 2 entries here, one for anonymous HTTPS access and one authenticated HTTPS access. It is unusual to have several different identities for the same abap server. But it might be possible : for exemple, one identity on the intranet and an other one on the Internet.
>3. When I had my new PSE client, and my HTTP RFC destination of type 'G' configured to use that >PSE client, and when in abap I instantiate my http client (using CREATE_BY_DESTINATION method, >from CL_HTTP_CLIENT class): How does SAP knows which certificate to use? Because there will be >several users (hundreds) running this code to retrieve their specific data from a third party server.
>How does SAP knows whom certificate must use?
The certificate used will be the one defined in the HTTP destination.
You still seem to make the confusion between server client certificates and users client certificates.
a users client certificate is stored in the user's PC (or smartcard) and is used for HTTPS connections from the user's browser to the SSL server, not for an HTTPS connection from the ABAP server to another server.
Regards,
Olivier -
How to make a http request from a pl/sql procedure(URGENT)
I need to make a http request from a pl/sql procedure, can any one tell me which built-in package and which procedure/function we serve my need?
Thanks in advance.
Ram Prasad.You should use UTL_HTTP package, but before it install the JVM into DB
-
How best to make a transaction span multiple HTTP requests?
Hi, all. What is the best way to implement a transaction that spans multiple
HTTP requests? Many J2EE applications must solve this problem, but I can't
any guidelines for an implementation.
Consider an application that implements a multi-step wizard. Each step
gathers data from the user; step one gets the user's name, and step two gets
his dog's name. When the user completes the wizard, the application saves
the user & dog in two entity beans. Conceptually, the application treats
this wizard like a single, long-running transaction. The transaction begins
when the user launches the wizard. Submitting the JSP for step one adds the
Boy bean to the transaction, and submitting step two adds the Dog bean.
Finishing the wizard commits the transaction. Exiting the wizard or timing
out causes the transaction to rollback.
Although the wizard looks like a transaction, the entire sequence of user
interactions can't be captured in a single JTA UserTransaction. A
UserTransaction must be associated with a single thread, but each wizard
step is handled asynchronously by its own execution thread. It's impossible
to funnel the conversation through one thread that can demarcate the
transaction. (This would be a pretty dumb solution for other reasons, but I
don't want to get lost in details.)
I think the standard way to solve this problem is to store conversation
state in a stateful session bean (or the http session) and create / update
both entity beans in a transactional EJB method after the wizard completes.
Unfortunately, this solution prevents me from leveraging a lot of great
transaction management features provided by the app server. For example, I
can't use optimistic concurrency to make sure that the dog object hasn't
changed in the database between the start and end of the wizard. Also, I'm
forced to keep track of changes to the dog object in the conversation state,
then replicate these changes to an entity bean at the end of the wizard.
Keeping track of state in a stateful bean is pretty straightforward, but it
seems like there must be an existing solution that leverages the appserver's
concurrency and state management features. Am I missing something? Is there
code, a pattern, or an article that describes the best way to implement a
multi-step process that looks transactional? I suppose WLI does what I want,
but that feels like killing a roach with a SCUD missle. Thanks for any
advice.
DaveDave Smith wrote:
Without a transaction, will the app server manage the version column
automatically, assuming of course that <concurrency-strategy> is
"Optimistic" and <verify-columns> is set to "Version"? Of course, I'll have
to expose the version as a cmp-field, which is fine with me.Yes
>
Do you know offhand, so that I don't have to get off my lazy ass and write a
test, whether the CMP service will create the version column when it
generates db tables? (I realize it's not good to let WLS generate the tables
in a production system.)No, I don't think it does.
>
I assume from your answer that I'm on my own for implementing stuff like and
transaction inheritance and tracking object modifications? Well, we'll give you a bit of help on the object modifications. The
usual pattern is when you're pushing the JavaBean back to the CMP you
call all the setXXX methods on the CMP bean. Our CMP container will
check if the value you are setting is the same as read from the db. If
so, it will not update that column.
-- Rob
If so, no big
deal. I was just hoping somebody would say, "Oh, you want the Jakarta
SuperBeans project" or something.
Thanks,
Dave
"Rob Woollen" <[email protected]> wrote in message
news:[email protected]...
I'd recommend that you include a separate version or timestamp column in
your db schema.
Then do something like this:
Client Server
1) First HTTP Request
2) Read current Dog and Boy Entity Beans
(if any) and copy their values into a JavaBean.
You want to include the version
column(s) in the JavaBean(s) along with the data values.
You probably also want to store the JavaBeans in
your HTTP Session.
3) Client proceeds through wizard interacting with JavaBeans
4) Finish with Wizard, copy JavaBean values (including
version columns) to CMP 2.0 Entity Beans.
The version column will give you the optimistic concurrency protection
that you desire without opening a JTA transaction to span user input.
-- Rob
Dave Smith wrote:
Hi, all. What is the best way to implement a transaction that spans
multiple
HTTP requests? Many J2EE applications must solve this problem, but Ican't
any guidelines for an implementation.
Consider an application that implements a multi-step wizard. Each step
gathers data from the user; step one gets the user's name, and step twogets
his dog's name. When the user completes the wizard, the applicationsaves
the user & dog in two entity beans. Conceptually, the application treats
this wizard like a single, long-running transaction. The transactionbegins
when the user launches the wizard. Submitting the JSP for step one addsthe
Boy bean to the transaction, and submitting step two adds the Dog bean.
Finishing the wizard commits the transaction. Exiting the wizard ortiming
out causes the transaction to rollback.
Although the wizard looks like a transaction, the entire sequence ofuser
interactions can't be captured in a single JTA UserTransaction. A
UserTransaction must be associated with a single thread, but each wizard
step is handled asynchronously by its own execution thread. It'simpossible
to funnel the conversation through one thread that can demarcate the
transaction. (This would be a pretty dumb solution for other reasons,but I
don't want to get lost in details.)
I think the standard way to solve this problem is to store conversation
state in a stateful session bean (or the http session) and create /update
both entity beans in a transactional EJB method after the wizardcompletes.
Unfortunately, this solution prevents me from leveraging a lot of great
transaction management features provided by the app server. For example,I
can't use optimistic concurrency to make sure that the dog object hasn't
changed in the database between the start and end of the wizard. Also,I'm
forced to keep track of changes to the dog object in the conversationstate,
then replicate these changes to an entity bean at the end of the wizard.
Keeping track of state in a stateful bean is pretty straightforward, butit
seems like there must be an existing solution that leverages theappserver's
concurrency and state management features. Am I missing something? Isthere
code, a pattern, or an article that describes the best way to implementa
multi-step process that looks transactional? I suppose WLI does what Iwant,
but that feels like killing a roach with a SCUD missle. Thanks for any
advice.
Dave
Maybe you are looking for
-
Unicode error:a line of internal table and a data object are not mutually c
Hi Friends, This is the issue in upgradation from 4.6c to ECC6.0 I have an internal table itab which has include structure say 'xyz' . In xyz there is a field of type int4 as third field. I have a field as l_line which is a string. data : beg
-
Cant add hyperlinks in the new version
I have no way to add extrneal hyperlinks to any of my text or images... what happened
-
How can I download Photoshop Elements 7?
I bought Photoshop Elements 7 several years ago and I have lost the disk but, I still have the case with the Product Key on it. I gave away the computer that had the program on it. I am wondering if there is a way that I can download Elements 7 onto
-
What tables are there behind the trees.
If a tree is set up with a node that has a set of accounts... what set of tables can I query to find that info?
-
I am following the instructions for removing and reinstalling itunes because I had a "msvcr80.dll missing from your computer" error. I have uninstalled itunes and apple software update but the next one in order "apple mobile device support" will not