网页与 C# 程序上的/触发事件通信?

发布于 2024-11-29 07:51:21 字数 220 浏览 2 评论 0原文

我计划创建一个 C# 程序(具体来说是一个 IRC 机器人)。我需要它能够接收来自网页的请求和/或受网页控制。我计划购买一个 VPS,用来托管我的网站和这个机器人。

例如,假设我在 ajax 页面上有一个按钮。如果用户单击该按钮,它是否可以使用 php 触发 ac# 事件,并且可能携带一些参数(例如同一页面上表单中的文本)?

我是这个编程领域的新手,可能不会使用一些正确的术语,请随时纠正我。

I'm planning on creating a C# program (an IRC bot, to be specific). I need it to be able to receive requests from and/or be controlled by a web page. I plan on getting a VPS, that I will host my website and this bot on.

For example, suppose I have a button on an ajax page. If a user clicks that button, could it trigger a c# event using php, and perhaps carry some arguments (like text in a form on that same page)?

I am new to this field of programming and may not use some correct terminology, and feel free to correct me.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

青春有你 2024-12-06 07:51:21

听起来您想使用 TcpClientSystem.Net.Sockets.TcpClient

Sounds like you want to be using TcpClient. System.Net.Sockets.TcpClient

○愚か者の日 2024-12-06 07:51:21

繁荣宝贝! IRC 机器人代码是 he'ya:
IRC Bot 代码

虽然周日有一百种方法制作一个响应http请求的程序,去做一个关于Asp.Net的教程。无论是通过网页执行命令还是显示界面,这都将是您迈向简单新技术的良好一步:

http://www.asp.net/mvc

特别是,请完成该网页上的免费 PluralSight 培训。你不会后悔的。

Boom baby! IRC bot code is he'ya:
IRC Bot code

And while there are a hundred ways to sunday to make a program that responds to http requests, go do a tutorial on Asp.Net. Whether it's taking a command through a web page or showing an interface, this will be a nice step into an easy new technology for you:

http://www.asp.net/mvc

In particular, go through the free PluralSight training on that web page. You will not regret it.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文