In this post we have explained about how to create a RESTful API with HapiJS and NodeJS and MYSQL. Many web applications they provide API to access their data via RESTful. This process is called as web services. We have implemented RESTFUL API using NodeJS with MYSQL Database using Hapi JS web services.
In this article we have explained about PHP Login and Registration System with PDO script. PDO connection is always secure and flexible support for all databases. PDO has an ease of code implementation. We were implement a sample PHP login and sign up system with PDO.
In this post we have explained about how to create multiple database connection in codeigniter. Please do the following changes in your files.
Change the below following things in your config.php
$active_group = 'default'; $active_record = TRUE;
We had published after long time back article about SQL injection. First of all explain what is sql injection.To avoid the unwanted peoples are access your database without your knowledge i.e hacking.When the system (website) to ask the input from users in that time we won’t directly pass the input to the database we must validate the inputs.
Following things are to prevent the user input :
If you got the input from users, you have to validate using regular expressions for example.
Guys you are trying to insert data from one of your existing table to another existing table or same table in mysql you can use SQL Insert into Select Query. The following query will explain
INSERT INTO users (user_id,username,email,password) SELECT user_id,username,email,password FROM users;
You can add where clause too,
INSERT INTO users (user_id,username,email,password) SELECT user_id,username,email,password FROM users Where user_id <= 5;