Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package utils;
- import com.mysql.jdbc.Connection;
- import java.sql.DriverManager;
- public class ConnectionUtil {
- Connection conn = null;
- public static Connection conDB(){
- try {
- Class.forName("com.mysql.jdbc.Driver");
- Connection con = (Connection) DriverManager.getConnection("jdbc:mysql://remotemysql.com/zMtDLBiD3t", "zMtDLBiD3t", "OakNNO5iy3");
- return con;
- } catch (Exception ex) {
- return null;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement