简体   繁体   中英

How do I send data to a website without writing anything in the URL?

I'm trying to make a login script in PHP, however a user will signup/login via a C# program.

For obvious reasons I don't want to use GET , but I don't want to make forms and use POST either.

How should I (securely) send data over?

This is only a proof of concept so there isn't any SSL on my website/etc, so there's no extra loops to jump through.

Just so nobody's confused:

Web-based login will be made in PHP, and data will be sent to the website via a program made in C#

You have to use GET or POST to submit your form data back to the PHP page. There is no way around that.

Once your PHP code has it on the backend you can do whatever you want to get it to the C# program.

Using a POST would eliminate items being added to the query string like GET does and of course doing it over HTTPS would make it more secure.

The only way to be secure is to use https: . You can look at client-side encryption, but that involves private/public keys - https will be easier.

Client side is HTML/JCSS/Javascript. If you want a user to enter ID annd password then you will have forms, and GET or POST is what you will use. Even if you wrap it up in AJAX, it will still be the same.

Go and think this through, and come back with a proper question. Telepathy isn't sufficiently reliable for your needs. Yet.

I'm not quite sure I understand correctly but what I understood was you want to send the login via a C# program. In that case check this question: HTTP request with post .

If however you want to send the data via the webpage, without having a form. You'd need to make the POST request via javascript.

Any of both methods require POST requests, even though you don't use forms.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM