Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Jan 2003
    Posts
    44
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Pass Value to db using javascript

    Hello,

    I am pretty new to javascript and come from an asp background. I was curious to know if you could pass a value to a database return the results all using javascript?

    If so could you possibly post some example code?

    Any help would be greatly appreciated!

    tsbarnes

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    frankfurt, german banana republic
    Posts
    1,848
    Thanks
    0
    Thanked 0 Times in 0 Posts
    If you mean client-side javascript, then the answer is no, directly it's not possible, since JavaScript in a client-side script can't open a database connection (to your server). You can send requests and even fetch whole pages with JS, and these pages could contain results of a DB query. But the real data retrieval would still be done by a server-side script.
    De gustibus non est disputandum.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •