This is the community forum. For a developer response use the Client Area.
Follow us on Facebook, Twitter and YouTube!

Database Name showing
#1

Error reporting was turned on, no errors showing.

http://www.pritchardwebsites.com/new/latest-news.php
I just installed it and the database names shows both above the comment form and in the admin panel just above "dashboard".

I am using v2.3, just installed it on my local computer 2 days ago and all was perfect. But just now I installed it on my remote server.

Couldn't find a fix in the docs or on the forum.

Anyone have any ideas how to fix this?

Thanks,
Mike
Reply
#2

Hi Mike,

That's a strange one. I have an idea of what it might be. Can you open /comments/includes/db/connect.php and remove or comment out these two lines:

PHP Code:
<?php 
@$cmtx_db_orig = mysql_query("SELECT DATABASE();");
@
$cmtx_db_orig = mysql_result($cmtx_db_orig, 0);

Have you completed the interview?
Reply
#3

Also in that file, can you remove the @ symbol from these two lines:

PHP Code:
<?php 
@$cmtx_connection = mysql_connect ($cmtx_mysql_host, $cmtx_mysql_username, $cmtx_mysql_password);

PHP Code:
<?php 
@$cmtx_database = mysql_select_db ($cmtx_mysql_database);

Have you completed the interview?
Reply
#4

Hi Steven,
I got those changes done but the name still appears:
http://www.pritchardwebsites.com/new/latest-news.php

Got any other ideas?

Thanks,
Mike
Reply
#5

Maybe add some echo statements inside connect.php to try to determine where it's coming from.

For example, add ..

PHP Code:
<?php 
echo 'test';

.. somewhere inside it and see if it appears above or below the outputted database name and then move the echo statement around until you're sure exactly what part it's coming from.

Have you completed the interview?
Reply
#6

You, Steven, are a genius. That worked. Somehow the database name got copied to the beginning of the details.php file
I probably did it when I was editing that file.

Thanks so much. You Rock, a lot.

Mike
Reply


Possibly Related Threads…
Thread / Author Replies Views Last Post
Last Post by HGsunday
04-Jul-2018, 09:42 AM
Last Post by Steven
24-Jan-2016, 08:24 PM
Last Post by adb34
22-Sep-2015, 03:29 PM
Last Post by Tommiiee
20-Apr-2014, 07:57 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)