Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
Okay, thank you both! However, neither suggestion did what I need it to do. I've figured out that the server is not going to unencode anything so the XML needs to be sent in plain text, no encoding. This works:
my $finalXML = $self->getFinalXML(); my $POST_URL = $self->getProcessingURL(); print $finalXML, "\n"; use Net::SSLeay; my ($page, $response, %reply_headers) = Net::SSLeay::post_https( 'dev.xmlsite.com', 11800, '', Net::SSLeay::make_headers('Content-Type' => 'text/xml'), "CLRCMRC_XML=$finalXML" ); foreach my $key (keys %reply_headers) { print "$key: ", $reply_headers{$key}, "\n"; } print 'Response: ', $response, "\n"; print 'Page: ', $page, "\n";
...and it's nice because I've got my XML response in a separate variable out of gate: $page. I'd like to do the above using LWP, but I can't figure out how to send content unencoded, ie. plain text. I'm stumped.

dpatrick
- I think scsh is cool.
Open Sourceror, Perlmonk
http://perlmonk.org/~dpatrick

In reply to Re: Re: Can't Post XML to SSL Site by dpatrick
in thread Can't Post XML to SSL Site by dpatrick

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (2)
As of 2023-06-01 06:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?