• <tfoot id='kSMOv'></tfoot>
    • <bdo id='kSMOv'></bdo><ul id='kSMOv'></ul>

      <small id='kSMOv'></small><noframes id='kSMOv'>

      <i id='kSMOv'><tr id='kSMOv'><dt id='kSMOv'><q id='kSMOv'><span id='kSMOv'><b id='kSMOv'><form id='kSMOv'><ins id='kSMOv'></ins><ul id='kSMOv'></ul><sub id='kSMOv'></sub></form><legend id='kSMOv'></legend><bdo id='kSMOv'><pre id='kSMOv'><center id='kSMOv'></center></pre></bdo></b><th id='kSMOv'></th></span></q></dt></tr></i><div id='kSMOv'><tfoot id='kSMOv'></tfoot><dl id='kSMOv'><fieldset id='kSMOv'></fieldset></dl></div>

      1. <legend id='kSMOv'><style id='kSMOv'><dir id='kSMOv'><q id='kSMOv'></q></dir></style></legend>

        在没有 node.js 的 javascript 服务器端连接到 MySQL

        Connect to MySQL in javascript server side without node.js(在没有 node.js 的 javascript 服务器端连接到 MySQL)
      2. <tfoot id='JB0kD'></tfoot>
          <bdo id='JB0kD'></bdo><ul id='JB0kD'></ul>

              <i id='JB0kD'><tr id='JB0kD'><dt id='JB0kD'><q id='JB0kD'><span id='JB0kD'><b id='JB0kD'><form id='JB0kD'><ins id='JB0kD'></ins><ul id='JB0kD'></ul><sub id='JB0kD'></sub></form><legend id='JB0kD'></legend><bdo id='JB0kD'><pre id='JB0kD'><center id='JB0kD'></center></pre></bdo></b><th id='JB0kD'></th></span></q></dt></tr></i><div id='JB0kD'><tfoot id='JB0kD'></tfoot><dl id='JB0kD'><fieldset id='JB0kD'></fieldset></dl></div>
              <legend id='JB0kD'><style id='JB0kD'><dir id='JB0kD'><q id='JB0kD'></q></dir></style></legend>

                <small id='JB0kD'></small><noframes id='JB0kD'>

                  <tbody id='JB0kD'></tbody>

                1. 本文介绍了在没有 node.js 的 javascript 服务器端连接到 MySQL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我有一个 javascript 应用程序在像 nginxeclipse 本地服务器 这样的服务器上运行,我想知道是否可以将它与 mysql 服务器数据库连接.

                  I have a javascript application running with server like nginx or eclipse local server, and i would like to know if it is possible to connect it with mysql server database.

                  我知道它们是 nodejs 应用程序的很多 npm 包,但我不想使用 node js,因为如果我这样做,我有实现具有所有依赖项的 nodejs 应用程序的所有结构,我不太了解这项技术.

                  I know that they are a lot of npm packages for nodejs application, but i don't want to use node js because if i'll do that i have to implement all structure of nodejs application with all dependencies and i don't know very well this technology to do that.

                  谢谢.

                  推荐答案

                  没有办法直接从浏览器中运行的 JavaScript 连接到远程数据库服务器……如果有的话,可能会涉及一个巨大的安全漏洞,因为任何人有权访问客户端可以获取您的凭据并在服务器上运行他们喜欢的任何 SQL.您不太可能使您的数据库 GRANTS 足够细以供公众使用.

                  There is no way to connect to a remote database server directly from JavaScript running in a browser… and if there was it would probably involve a huge security hole since anyone with access to the client could take your credentials and run any SQL they like on the server. It is unlikely you could make your database GRANTS fine-grained enough for public consumption.

                  如果你想让你的客户端 JS 与你的数据库服务器交互,那么你需要为它编写一个 web 服务.您可以在 Node.JS 或您喜欢的任何其他服务器端环境中执行此操作.

                  If you want your client side JS to interact with your database server then you need to write a webservice for it. You can do that in Node.JS or any other server side environment you like.

                  如果您使用的是 Node.JS,那么您可能希望 Nginx 代理请求.

                  If you are using Node.JS then you will probably want Nginx to proxy the requests.

                  Nginx 支持 FastCGI 所以你可以写任何支持 FastCGI 的语言,例如 Perl 或 PHP.

                  Nginx supports FastCGI so you could write in any language that supports FastCGI such as Perl or PHP.

                  这篇关于在没有 node.js 的 javascript 服务器端连接到 MySQL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  ibtmp1是非压缩的innodb临时表的独立表空间,通过innodb_temp_data_file_path参数指定文件的路径,文件名和大小,默认配置为ibtmp1:12M:autoextend,也就是说在文件系统磁盘足够的情况下,这个文件大小是可以无限增长的。 为了避免ibtmp1文件无止境的暴涨导致
                  What does SQL clause quot;GROUP BY 1quot; mean?(SQL 子句“GROUP BY 1是什么意思?意思是?)
                  MySQL groupwise MAX() returns unexpected results(MySQL groupwise MAX() 返回意外结果)
                  MySQL SELECT most frequent by group(MySQL SELECT 按组最频繁)
                  Why Mysql#39;s Group By and Oracle#39;s Group by behaviours are different(为什么 Mysql 的 Group By 和 Oracle 的 Group by 行为不同)
                  MySQL GROUP BY DateTime +/- 3 seconds(MySQL GROUP BY DateTime +/- 3 秒)

                  <small id='UPXYJ'></small><noframes id='UPXYJ'>

                  • <bdo id='UPXYJ'></bdo><ul id='UPXYJ'></ul>
                        <legend id='UPXYJ'><style id='UPXYJ'><dir id='UPXYJ'><q id='UPXYJ'></q></dir></style></legend>
                          <tbody id='UPXYJ'></tbody>
                          <tfoot id='UPXYJ'></tfoot>
                            <i id='UPXYJ'><tr id='UPXYJ'><dt id='UPXYJ'><q id='UPXYJ'><span id='UPXYJ'><b id='UPXYJ'><form id='UPXYJ'><ins id='UPXYJ'></ins><ul id='UPXYJ'></ul><sub id='UPXYJ'></sub></form><legend id='UPXYJ'></legend><bdo id='UPXYJ'><pre id='UPXYJ'><center id='UPXYJ'></center></pre></bdo></b><th id='UPXYJ'></th></span></q></dt></tr></i><div id='UPXYJ'><tfoot id='UPXYJ'></tfoot><dl id='UPXYJ'><fieldset id='UPXYJ'></fieldset></dl></div>