?
Solved

php to vb.net or c#

Posted on 2013-01-16
5
Medium Priority
?
656 Views
Last Modified: 2013-01-17
Hello Experts

I am trying to call an API and download some data, I have a PHP example which I am trying to follow and implement the same in VB.Net
I have come across with the following statements in PHP which I am unable to figure out the equivalent in .net
$ch=curl_init();
 curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, 0);
 curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 0);

Please can someone advise what it is in .net term?

Thanks
N
0
Comment
Question by:newbie27
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 27

Accepted Solution

by:
Lukasz Chmielewski earned 668 total points
ID: 38782854
0
 
LVL 42

Expert Comment

by:sedgwick
ID: 38782917
what is the purpose of this lines?
instead of trying to convert the code to .net please explain what is it to be gained?
0
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 38782920
I'd suggest the WebClient class. It should handle SSL for you.
0
 
LVL 42

Assisted Solution

by:sedgwick
sedgwick earned 668 total points
ID: 38782929
basically what those 2 constants means is enable dummy certificate when connection to SSL base remote server in order to get no errors.
The error occurs due to lack of having up to date bundle of CA root certificates.
0
 
LVL 6

Assisted Solution

by:charlie324
charlie324 earned 664 total points
ID: 38782950
Hi,
These are simply curl statements that say that there is no need for SSL security certificate in the post.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Calculating holidays and working days is a function that is often needed yet it is not one found within the Framework. This article presents one approach to building a working-day calculator for use in .NET.
This article discusses how to implement server side field validation and display customized error messages to the client.
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question