Jump to content

Recommended Posts

Posted (edited)

Username: ojedajvi, Server: Ricky, Main domain: ojedajvi.heliohost.org

 

Buenas quisiera que me ayudaran, estoy tratando de cofigurar mi BD con

heliohost pero pense que el nombre del host era mi propia pagina

http://ojedajvi.heliohost.org

 

quisiera saber el nombre de la conexion el cual tengo que colocar en mi

cadena de BD para MYSQL

 

Correo: ojedajvier1986@gmail.com

 

translate.google.com:

 

Good, I would like you to help me, I am trying to make my BD with

heliohost but I thought the host name was my own page

http://ojedajvi.heliohost.org

 

I would like to know the name of the connection which I have to place in my

BD string for MYSQL

Edited by Krydos
translated
Posted

bueno e colocado mi cadena de conexion de la siguiente manera:

 

<?php

$host_db = "localhost"; // Host de la BD

$usuario_db = "ojedajvi_javier"; // Usuario de la BD

$clave_db = "CLAVE"; // Contraseña de la BD

$nombre_db = "ojedajvi_alejandrotortoza"; // Nombre de la BD

 

//conectamos y seleccionamos db

mysql_connect($host_db, $usuario_db, $clave_db);

mysql_select_db($nombre_db);

?>

 

y me sigue apareciendo el mismo error, carga la pagina principal todo chevere pero al momento de llamar la otra pagina que es dondepongo mi login y usuario me lanza la siguein imagen:

 

https://ibb.co/kJBMWm

 

translate.google.com:

 

good and placed my connection string as follows:

 

<? php

$ host_db = "localhost"; // Host of the BD

$ user_db = "ojedajvi_javier"; // BD user

$ clave_db = "PASSWORD"; // Password of the BD

$ db_name = "ojedajvi_alejandrotortoza"; // Name of the BD

 

// connect and select db

mysql_connect ($ host_db, $ user_db, $ password_db);

mysql_select_db ($ db_name);

?>

 

and I still see the same error, load the main page all chevere but when calling the other page that is where I put my login and user launches the following image:[/size][/font]

 

https://ibb.co/kJBMWm

post-145017-0-02125700-1516284658_thumb.png

Posted (edited)

Buenas gracias por responder,

 

Asi mismo tengo mis directorios porque asi estuve leyendo en foros, veras con la siguiente imagen la configuracion de mis archivos y el error que me sale.

 

asi tengo mi directorio con los permisos y el siguiente error me sigue saliendo como sale en las imagenes adjuntas

 

translate.google.com:

 

Good thanks for answering, 

 

So I have my directories because I was reading in forums, you will see with the following image the configuration of my files and the error that I get. 

 

So I have my directory with the permissions and the following error keeps coming to me as it appears in the attached images

post-145017-0-80264500-1516303266_thumb.png

post-145017-0-21279400-1516303280_thumb.png

Edited by Krydos
translated
Posted (edited)

Perfecto muchas Gracias ya se soluciono eso Exito!!!!!

 

Puedes chequear si la conexion mysql es la adecuaca? ya que no me puedo conectar con la base de datos

 

se me indico que como host pusiera "localhost" no se si es lo correcto te dejo mi cadena de coxion de codigo

<?php
    $host_db = "localhost"; // Host de la BD
    $usuario_db = "ojedajvi_javier"; // Usuario de la BD
    $clave_db = "<removed>"; // Contraseña de la BD
    $nombre_db = "ojedajvi_alejandrotortoza"; // Nombre de la BD
    
    //conectamos y seleccionamos db
    mysql_connect($host_db, $usuario_db, $clave_db);
    mysql_select_db($nombre_db);
?>
translate.google.com:

 

Perfect thank you very much already solved that Success !!!!! 

 

Can you check if the mysql connection is appropriate? since I can not connect to the database 

 

I was told that as host put "localhost" I do not know if it is the right thing I leave my code coxion chain

Edited by Krydos
translated
Posted (edited)

este es el error que vota, es la misma conexion que uso para todo que la anexe en la imagen arriba.

 

el error es como si no llamara a mis BD a las tablas a la que llamo.

 <?php
    $host_db = "localhost"; // Host de la BD
    $usuario_db = "ojedajvi_javier"; // Usuario de la BD
    $clave_db = "<removed>"; // Contraseña de la BD
    $nombre_db = "ojedajvi_alejandrotortoza"; // Nombre de la BD
    
    //conectamos y seleccionamos db
    mysql_connect($host_db, $usuario_db, $clave_db);
    mysql_select_db($nombre_db);
?> 

post-145017-0-64330300-1516305203_thumb.png

Edited by Krydos
Posted

mysql_connect doesn't exist in php 7.1. It's been deprecated for years in php 5. You need to use an older version of php (like 5.6) or use mysqli instead. I recommend mysqli.

Posted (edited)

veras en vista de lo que me comentas apesar de ser obseloto funciona bien, pero hice una nueva construccion de cadena y sigue lo mismo, te dejo la nueva cadena con mysqli

<?php
$con = mysqli_connect("localhost","ojedajvi_javier","<removed>","ojedajvi_alejandrotortoza");

// Check connection
if (mysqli_connect_errno())
  {
  echo "Failed to connect to MySQL: " . mysqli_connect_error();
  }
?>
translate.google.com:

 

You will see in view of what you tell me in spite of being obsessed it works well, but I made a new chain construction and it follows the same, I leave you the new chain with mysqli

Edited by Krydos
translated
Posted

It does not work for me, it throws the same error, it modifies my connection string with mysqli_connect but it launches the same thing, I can not connect to the DB, it keeps on throwing me the same error

 

 

Fatal error: Uncaught Error: Call to undefined function mysql_connect() in /home/ojedajvi/public_html/admin/login/acceso_db.php:8 Stack trace: #0 {main} thrown in /home/ojedajvi/public_html/admin/login/acceso_db.php on line 8

Guest
This topic is now closed to further replies.
×
×
  • Create New...