Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2013-07-15 09:47:02

tayfighter
Member
Registered: 2013-07-15
Posts: 23

Transferring a site and getting errors

Hi

Can anyone help.

I’m trying to port a site over to new hosting.
Have followed the instructions on the the site, but am getting this error message.

Fatal error: Cannot redeclare getCustomFields() (previously declared in /home/sites/mydomain/public_html/textpattern/lib/txplib_misc.php:2185) in /home/sites/mydomain/public_html/textpattern/publish.php on line 1155

Can anyone help?

Thanks

T

Offline

#2 2013-07-15 11:45:51

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,529
Website GitHub Twitter

Re: Transferring a site and getting errors

Hi

Can you explaine how you made the transfert step by step to see what could happened?

Offline

#3 2013-07-15 12:32:15

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,304

Re: Transferring a site and getting errors

Are you trying to migrate and update in one go? Please also post a diagnostics report.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#4 2013-07-15 13:45:10

etc
Developer
Registered: 2010-11-11
Posts: 5,053
Website GitHub

Re: Transferring a site and getting errors

It looks like textpattern/publish.php and textpattern/lib/txplib_misc.php files come from different versions, please check.

Offline

#5 2013-07-15 14:02:11

tayfighter
Member
Registered: 2013-07-15
Posts: 23

Re: Transferring a site and getting errors

Hi

I’m just trying to migrate at the moment.
Not sure how I create a diagnostic report?

1) First I exported the sql database.
2) I copied all the files from the server over to the new hosting
3) I set up a new sql database, I had to set up a new user name and password
4) On the server I edited the config.php file in the textpattern folder to the following

<?php
$txpcfg[‘db’] = ‘My Database Name’;
$txpcfg[‘user’] = ‘My Database Username’;
$txpcfg[‘pass’] = ‘My Database Password’;
$txpcfg[‘host’] = ‘My Database Location’;
$txpcfg[‘table_prefix’] = ‘’;
$txpcfg[‘txpath’] = ‘My Domain/textpattern’;
$txpcfg[‘dbcharset’] = ‘utf8’;
?>

Thanks

Offline

#6 2013-07-15 14:28:56

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,529
Website GitHub Twitter

Re: Transferring a site and getting errors

Hi can you access txp admin?

Offline

#7 2013-07-15 15:04:15

tayfighter
Member
Registered: 2013-07-15
Posts: 23

Re: Transferring a site and getting errors

HI

I deleted all the files and uploaded them again on the server to remove any issues with there being different versions.
Now i get the following error, when trying to access the site -

Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in /home/sites/My Domain/public_html/textpattern/lib/txplib_misc.php on line 177 Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in /home/sites/My Domain/public_html/textpattern/lib/txplib_misc.php on line 177

Unknown section

When trying to access the admin, i get this error message

Warning: Table ‘DatabaseName.textpattern’ doesn’t exist describe `textpattern` in /home/sites/My Domain/public_html/textpattern/lib/txplib_db.php on line 82 Warning: Table ‘DatabaseName.txp_page’ doesn’t exist select user_html from txp_page where name=‘error_503’ in /home/sites/My Domain/public_html/textpattern/lib/txplib_db.php on line 82 Warning: Table ‘DatabaseName.txp_page’ doesn’t exist select user_html from txp_page where name=‘error_default’ in /home/sites/My Domain/public_html/textpattern/lib/txplib_db.php on line 82

DB-Connect was succesful, but the textpattern-table was not found.

Sorry, not used text pattern before and thanks for all the questions so far.

T

Offline

#8 2013-07-15 15:12:24

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,304

Re: Transferring a site and getting errors

Just guessing, tayfighter: You didn’t mention that you re-imported the database, i.e. there’ll be no plugins installed at the moment. Also, judging from the line numbers, the core code seems hacked to a certain degree.
Most traces here in the forum re getCustomFields() lead to the period your TXP version seems to stem from (4.0.7/8) in relation with glz_custom_fields, a plugin. The conclusion I draw is: Import the old DB and the errors will vanish, the glz plugin comes with the database import.

Edit: In the meantime my assumption re DB import have come true, like you’ve just posted.

Diagnostics can be found in the TXP Admin: Administration > Diagnostics. But importing the database before will be useful.

Last edited by uli (2013-07-15 15:15:31)


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#9 2013-07-15 15:27:10

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,529
Website GitHub Twitter

Re: Transferring a site and getting errors

Hi

Can you check your db to see if textpattern table exist?

Offline

#10 2013-07-15 16:04:33

tayfighter
Member
Registered: 2013-07-15
Posts: 23

Re: Transferring a site and getting errors

Uli

I have tried to re import the DB, but still have the same problem.

Dragondz

I dont think there is a textpattern table

I just exported the previous database and imported it.
Not sure what i’m missing.

T

Offline

#11 2013-07-15 21:19:31

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,304

Re: Transferring a site and getting errors

Please, post your diagnostics.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#12 2013-07-16 08:57:49

Dragondz
Moderator
From: Algérie
Registered: 2005-06-12
Posts: 1,529
Website GitHub Twitter

Re: Transferring a site and getting errors

tayfighter a écrit:

Dragondz
I dont think there is a textpattern table
I just exported the previous database and imported it.
Not sure what i’m missing.
T

Hi there is a textpattern table if you havent one then your backup is not good!

Offline

Board footer

Powered by FluxBB