DwZone Forum DwZone Forum
Welcome to the DwZone-it Forum
 
  FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups  
    RegisterRegister -->   LoginLogin  
Query Manager and Recordset Wizard  
DwZone Forum Index -> Query Manager and Recordset Wizard
.
Moderators: Administrators 
Hint: For improved responsiveness, use Internet Explorer 4 (or above) with Javascript enabled, choose 'Dynamic' from the View dropdown and hit 'Set Options' to save your changes.
New Topic Search for
 View     Per page     Messages Since 
Messages 1 to 10 of 41 (Total: 41) First |  Prev |  Next |  Last  
 Subject Author Date  
   mysqliInsert not working with Tinymce  
View this persons public profile  MartinDocherty   3:48 10 Apr 2020  
   Extensions not loaded  
View this persons public profile  Valter   8:01 16 Jul 2018  
   Re: Extensions not loaded  
View this persons public profile  Gianluigi   10:05 16 Jul 2018  
   Any Plans to add a Dynamic Checkbox?  
View this persons public profile  Jim   21:32 13 Jul 2018  
   Nested Repeat Region  
View this persons public profile  Jim   8:30 1 Jul 2018  
   Re: Nested Repeat Region  
View this persons public profile  Gianluigi   8:35 1 Jul 2018  
    Error when using Professionnal query  
View this persons public profile  Laurent   4:13 25 May 2018  
 
Hi Gian Luigi,
using your extension since a long time, I just bought "professionnal query" because I use now PHP/MySQL on a hosting with PHP7 and I needed to use the MySQLi PHP extension.

Seems to works in DW. I could create a MySQLi connection with a distant MySQL database, with an OK test.
I could create a recordset and I could see all the entries of the recordset. This means that the connection is OK from My DW and the distant Database.

But when I put all the files on the server, I get this error :
"Fatal error: Uncaught Error: Call to undefined function mysql_select_db() in /home/laudag/immobilier-dubourg/affichettes/affichette-A4-paysage.php:39 Stack trace: #0 {main} thrown in /home/laudag/immobilier-dubourg/affichettes/affichette-A4-paysage.php on line 39".

*Here is the connection script from the file Testaffichette.php (hostname was the server IP and an other test with localhost which worked from my DW and a distant evaluation server configuration) :
<?php
# FileName="Connection_php_mysql.htm"
# Type="MYSQLi"
# HTTP="true"
$hostname_Testaffichette = "Xxxx";
$database_Testaffichette = "Xxxxxx";
$username_Testaffichette = "Xxxxx";
$password_Testaffichette = "Xxxxxx";
$Testaffichette = new mysqli($hostname_Testaffichette, $username_Testaffichette, $password_Testaffichette, "");
if ($Testaffichette->connect_errno) {
echo "Failed to connect to MySQL: (" . $Testaffichette->connect_errno . ") " . $Testaffichette->connect_error;
exit();
}
?>

* Here is the recordset script with the line 39 in bold (mysql_select_db($database_Testaffichette, $Testaffichette);), which seems to correspond at a a line with connection to the database :
<?php require_once('Connections/Testaffichette.php'); ?>
<?php
if (!function_exists("GetSQLValueString")) {
function GetSQLValueString($theValue, $theType, $theDefinedValue = "", $theNotDefinedValue = "")
{
if (PHP_VERSION < 6) {
$theValue = get_magic_quotes_gpc() ? stripslashes($theValue) : $theValue;
}

$theValue = function_exists("mysql_real_escape_string") ? mysql_real_escape_string($theValue) : mysql_escape_string($theValue);

switch ($theType) {
case "text":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "long":
case "int":
$theValue = ($theValue != "") ? intval($theValue) : "NULL";
break;
case "double":
$theValue = ($theValue != "") ? doubleval($theValue) : "NULL";
break;
case "date":
$theValue = ($theValue != "") ? "'" . $theValue . "'" : "NULL";
break;
case "defined":
$theValue = ($theValue != "") ? $theDefinedValue : $theNotDefinedValue;
break;
}
return $theValue;
}
}

mysql_select_db($database_Testaffichette, $Testaffichette);
$query_annonces = "SELECT * FROM id83_posts ORDER BY ID DESC";
$annonces = mysql_query($query_annonces, $Testaffichette) or die(mysql_error());
$row_annonces = mysql_fetch_assoc($annonces);
$totalRows_annonces = mysql_num_rows($annonces);
?>

What could be the problem ? Is it a bug in your extension ou a problem of compatibility with my hosting (O2Switch) ?
Thanks for answering

Laurent DAGANY (France)

 
Reply to this current thread  View this persons public profile  Send Private Message
   How to use "Criteria" to select specific records  
View this persons public profile  JarrellHill   8:01 4 May 2018  
   Re: How to use "Criteria" to select specific records  
View this persons public profile  Gianluigi   9:49 4 May 2018  
   Re: How to use "Criteria" to select specific records  
View this persons public profile  JarrellHill   12:21 4 May 2018  
Last Visit: Friday 19 Apr, 2024 1:39 am First |  Prev |  Next |  Last  
 Login
Username:  Password:    
Read Message Read Message   Unread message Unread message
Read message [popular] Read message [popular]   Unread message [popular] Unread message [popular]
Read message [locked] Read message [locked]   Unread message [locked] Unread message [locked]
All times are GMT-2

Jump to: