admin 管理员组文章数量: 1086019
I have a Oracle databse in backend, i want to create a login page in javascript, so can any one tell me how to create a connection between Javascript & Oracle Database.
I have a Oracle databse in backend, i want to create a login page in javascript, so can any one tell me how to create a connection between Javascript & Oracle Database.
Share Improve this question asked Jul 20, 2016 at 4:37 Sumit VermaSumit Verma 311 silver badge2 bronze badges 2- This question needs very descriptive answer. Not suitable Q at SO.. – Pramod S. Nikam Commented Jul 20, 2016 at 4:42
- please understand that your question need to be more specific. for instance you'll need middleware software, which can be virtually anything (java, python, C#, node, virtually anything). if possible, please specify more your toolchain, we already know your database and also know that you ant it for the web, please give use what additional programming language you're versed or want to learn soon. – Sombriks Commented Jul 20, 2016 at 4:54
4 Answers
Reset to default 2You will need to create a server side API that accesses your database and then call the API from your HTML5 app.
You cannot connect database with client side scripting you need to use server side scripting such as PHP, Ruby, Java, .Net for database connections
You can use node js at the server side which is a javascript, so that you can create a connection to Oracle Database. https://nodejs/en/
You can create a PHP server side app. this app access your database (for example MYSQL) and you can get run database queries by sending special mands via ajax to server app. Example Ajax Call:(Using jQuery)
$.ajax({
url:'myapp.php',
type:'POST',
context: $(this), //Refere to your correct element
data: {query:'my-example-query'}
dataType: 'json',
timeout: '800'
});
After that you create a server side PHP app like this:
<?php
if(isset($_POST['query'])){
//Execute query or another conditional if ..else
}
本文标签: How to connect Oracle Database using Javascript amp HTMLStack Overflow
版权声明:本文标题:How to connect Oracle Database using Javascript & HTML - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://roclinux.cn/p/1744088179a2531529.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论