I'm new to web development and I'm trying to create a website with a database that will store all the files in the archive with the ability to delete files and upload new ones to the database from my web page.
1)I used HTML, CSS, javascript to create the website
2)MySQL to create the database
and I also tried phpMyAdmin to create the database
but where will I go from there?
How will my website control and show the database?
According to your question, I assume that you don't have a backend for your website. You need to have a backend to access the database. You can use php as the backend to connect with the mySQL database.
PS: I can see that you have tagged the question with php. If you are using php and still you can't connect to the database, please share your code snippets.
Related
new web developer here,
I am creating a test website where I can input data and add it to my MongoDB database.
I have a JavaScript file that manages the connection with my MongoDB database (app.js), and I have another JavaScript file that manages the elements within my webpage. (script.js)
I am trying to make it so when I load the page where I input data, I can call the method which connects the database, and I can use that allows me to push form data to my MongoDB database.
The only thing I am struggling with is how I would detect that the webpage is loaded and run the method that opens my database.
I am also struggling to understand how to pass my 'db' variable into my script.js file to allow me to get data from my webpage.
Any help is appreciated, I am using WebStorm to create my website.
EDIT: And links to resources that solve a similar issue to mine (basically sending data to MongoDB from a webpage), would be very helpful! I think I am also using nodejs for my app.js file
I need to run my R-code through a website, with the user giving feature values from the website itself, which I have to use as new data for prediction in the R-code. How can I do it?
Have a form on the website which performs an HTML post to a REST api on your web server which will write the information to a database such as MySql, Postgres, MongoDB, or any other database of your choice. Then use a DBMS database management system (DBMS) such as MySQL Workbench, pgAdmin, or Robomongo to query the database and put the data into a csv file, and run your R-code on it. Then use the parameters from your machine-learning model on your server to serve content.
You can expose any R code as a REST API using packages such as plumber, OpenCPU or RestServ. Such an API can then be integrated into the website using Jacascript.
Okay so its like this. I am using Microsoft Visual Studios (Javascript/HTML/CSS coding) to create an app which retrieves and sends data into a MySQL database. I setup my MySQL database using MySQL workbench. I created a localhost and connected Visual Studios to the database. It shows the connection on the Server Explorer on the left side of the IDE.
And this is where I get stumped. I don't know how exactly to retrieve the data set inside that database. I've been taught to use Eclipse and phpMyAdmin using a php file to connect, retrieve and store data into the database.
However, I am not familiar with how Visual Studios do their data retrieval. How do I go about this guys?? Basically, I got an HTML file, a CSS file, a Javascript file, I got the MySQL database running and it says I have connection to it on Visual Studios.
The database name is EmployeeCred, and inside the database is a table called employeelogindata with columns of informations.
What should I do?
You'll need to create some sort of API for your JavaScript(frontend) to interact with. You could create a PHP API(backend) which would connect to the database and return JSON data for your frontend. You could then access this using the JavaScript fetch API
Actually, for those still wondering how, Visual Studios has a service for Cordova App which allows for a built-in backend service to the app. Simply go to the Overview panel and look up the backend service feature. Follow the steps and read through the Corodva Documentation available on the internet.
I've recently ported a simple database from Ms Access to SQLite, because I wanted an open source option. Now I'm facing the problem of developing a visual form for data entry in that database.
This related question (HTML/JS as interface to local SQLite database) pretty much summaries what I want to do: create an HTML/JavaScript frontend for data entry in a SQLite local database. In that thread, the user solved the issue by creating a local web server via Python script.
The question is: how do I connect my HTML file to that local web server? Is that via PHP or something similar? Please point me to the right research direction. Thank you!
Yes, you should use PHP or something similar, possibly Ruby on Rails or Django. The last two make life really easy and help abstract the database.
Hii,
I want to retrieve data from sql database and display dynamically in div using javascript can anyone please help me on this...
Thanks...
You can not do that using only javascript, as sql queries should be done using server-side technology.
First, you have to find out what kind of web hosting do you have or can afford:
Web Hosting. Usually allows you to use PHP and MySQL.
Virtual Private Server, Dedicated Server. Lets you install anything you want on the host. But, it's usually 5-10 time more expensive.
I suppose you will take simple PHP Web Hosting, as it is cheaper and more avialable.
Here you go with a detailed beginner manual on getting data from MySQL with PHP and providing it to your page: http://www.freewebmasterhelp.com/tutorials/phpmysql
Generally, I can't give you more information than this, as it will same as writing a book on using PHP and MySQL. So I suppose you read that link I gave you, and open separate questions if you have some other specific questions.
If, by any means, you do not want PHP, then you should search for relative documentation.