Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2018-11-11 23:05:09

detail
Member
From: geez, I seem to be in NZ
Registered: 2010-07-13
Posts: 176
Website

Upgrade 4.5.7? > 4.7.1

Yesterday I had some weird things happening. One of my sites was down with Chrome, but strangely OK in Safari.

Edit: it is http://www.tramping.net.nz/

This morning it was all good again in both.

I guess I should have taken some screenshots.

Thought I’d better upgrade to 4.7.1.

I’ve been putting off the upgrade because, well, I always seem to have issues.

I had some time this morning so tried to upgrade.

Weird things have once again happened.

The site sort of worked on both Chrome and Safari, except I never went through the setup stage.

The site was up but I couldn’t see anything on the Admin side.

There was the yellow Hive menu up top, but nothing at all beneath.

When I installed txp I think I removed the Setup folder. It never ran.

This has left me with getting this message when I access ____/textpattern/setup/index.php:

This is at the first step: 1 Set database details

It looks like Textpattern is already installed. If you want to make a clean install, please remove config.php from your /home/content/39/6300239/html/tramping/textpattern/ directory and try again.

I’ve tried that but it has an alternative message that says I’m already connected to the database and that I need to create a new prefix.

 It appears the tables in detail already exist. If you wish to continue setup, either delete the existing tables, or choose a different table prefix.

!!

??

The whole site is obviously down at the moment.

Except that anyone can follow the links and see the error message above!!

config.php is missing or corrupt. To install Textpattern, visit textpattern/setup/

I guess I need to do something to get the setup sorted from the start.

PS. Slightly flustered? Sure thing.

Last edited by detail (2018-11-12 00:33:37)

Offline

#2 2018-11-12 00:17:05

detail
Member
From: geez, I seem to be in NZ
Registered: 2010-07-13
Posts: 176
Website

Re: Upgrade 4.5.7? > 4.7.1

Warning
: include_once(/home/content/39/6300239/html/tramping/textpattern/include/txp_auth.php): failed to open stream: No such file or directory in
/home/content/39/6300239/html/tramping/textpattern/setup/index.php
on line
58

Warning
: include_once(): Failed opening '/home/content/39/6300239/html/tramping/textpattern/include/txp_auth.php' for inclusion (include_path='.:/usr/local/php5_6/lib/php') in
/home/content/39/6300239/html/tramping/textpattern/setup/index.php
on line
58

Warning
: Cannot modify header information - headers already sent by (output started at /home/content/39/6300239/html/tramping/textpattern/setup/index.php:58) in
/home/content/39/6300239/html/tramping/textpattern/setup/index.php
on line
63

Set database details Add config file Populate database Go!
Checking database connection
Connected

 It appears the tables in detail already exist. If you wish to continue setup, either delete the existing tables, or choose a different table prefix.

downloaded and reinstalled the txp folder.

It’s a similar issue when attempting to login, except with those 3 warnings.

Now slightly different messages when just accessing /textpattern/setup/.

Warning: include_once(/home/content/39/6300239/html/tramping/textpattern/vendors/Textpattern/Loader.php): failed to open stream: No such file or directory in /home/content/39/6300239/html/tramping/textpattern/setup/index.php on line 40

Warning: include_once(): Failed opening '/home/content/39/6300239/html/tramping/textpattern/vendors/Textpattern/Loader.php' for inclusion (include_path='.:/usr/local/php5_6/lib/php') in /home/content/39/6300239/html/tramping/textpattern/setup/index.php on line 40

Fatal error: Class 'Textpattern\Loader' not found in /home/content/39/6300239/html/tramping/textpattern/setup/index.php on line 42

Last edited by detail (2018-11-12 00:30:40)

Offline

#3 2018-11-12 06:06:42

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,578
Website

Re: Upgrade 4.5.7? > 4.7.1

I can see the site just fine from here in Europe, so it looks like you got it sorted?

Just to recap, though: if you’re upgrading a site from an earlier version, you do not need to go through the setup procedure again, in fact you risk overwriting your database, which is it why when you tried to do that it warns you that the tables already exist and won’t proceed.

I can’t explain the other error messages, except that perhaps not all files were successfully uploaded because the errors point to missing files that should be there. In your first post, it sounds like you could have overwritten config.php and need to restore that file from your previous backup.


TXP Builders – finely-crafted code, design and txp

Offline

#4 2018-11-12 07:09:18

detail
Member
From: geez, I seem to be in NZ
Registered: 2010-07-13
Posts: 176
Website

Re: Upgrade 4.5.7? > 4.7.1

Thanks Jakob

Seems the main issue was the txpath in the config.php.

$txpcfg['txpath'] = '/home/content/d/e/t/detail/html/tramping/';

The above is working in 4.7.1.

In 4.5.7 my working config.php was in fact:

$txpcfg['txpath'] = '/home/content/d/e/t/detail/html/tramping/textpattern';

I recognised that as an issue when upgrading another website to 4.7.1 a few months ago.

Seemed that Safari could cope with either path, but Chrome didn’t like the extra /textpattern.

But there are some weird other issues.

1. One is that a sticky under the headings is not working on my main page.

<txp:article id=“39” />

That used to work yesterday.

2. I have a separate page for some sections and the menu has dropped out.

3. On another section, a whole bundle, everything under the top image, text and menu has gone.

I guess 4.7.1 is more sensitive to correct coding than 4.5.7.

+++

Or. Somehow I think I was supposed to run an upgrade script. I have never done this because I foolishly removed it from the original installation.

Only afterwards slipped it back in. I think this may be my problem, ie, how to run the upgrade script.

Or is it something else.

(I only get into this on the rare times I upgrade txp. I’m basically a content creator, rather than programmer, if that ain’t entirely obvious!)

Last edited by detail (2018-11-12 07:34:00)

Offline

#5 2018-11-12 08:56:21

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,578
Website

Re: Upgrade 4.5.7? > 4.7.1

detail wrote #315169:

Seems the main issue was the txpath in the config.php.

$txpcfg['txpath'] = '/home/content/d/e/t/detail/html/tramping/';... The above is working in 4.7.1. In 4.5.7 my working config.php was in fact: $txpcfg['txpath'] = '/home/content/d/e/t/detail/html/tramping/textpattern';...

That seems strange. I think every site I have has /textpattern at the end of txpath.

Seemed that Safari could cope with either path, but Chrome didn’t like the extra /textpattern.

Also strange: that should all happen at the server level, so the browser should have nothing to do with it. What does your Admin › Diagnostics say?

I guess 4.7.1 is more sensitive to correct coding than 4.5.7.

That’s true!

One is that a sticky under the headings is not working on my main page: <txp:article id="39" />

If it’s a sticky article, try:

<txp:article id="39" status="sticky" />

2. I have a separate page for some sections and the menu has dropped out.
3. On another section, a whole bundle, everything under the top image, text and menu has gone.

Can you isolate the relevant page/form templates and show us the code and the page it belongs to. Maybe we can help discover where the problem lies.

Somehow I think I was supposed to run an upgrade script. I have never done this because I foolishly removed it from the original installation.

No actually, everything should have been okay. The /setup directory is really only needed for the first-time installation and then never again. The /update directory contains the update script split into version steps depending on which version you’re coming from, and that’s not deleted. It runs automatically when it detects a version change. Sometimes if you get some funny output, it helps to clear the cache and all textpattern cookies, then login afresh.

When updating, you should only need to keep your /textpattern/config.php file, your /images, /files and any other specific assets folders you may have like your own css, ui logos, favicon or google webmaster infos etc. (perhaps also .htaccess if you’ve done anything custom in that file) and replace everything else in the base directory and /textpattern directory with a fresh download of the most recent version of textpattern.

There have been some update hiccups with certain server constellations mentioned in other threads here, and Oleg has a possible fix for that that will likely be in the next release. Should you need it again soon, try replacing /textpattern/update/_to_4.6.0.php with this file.


TXP Builders – finely-crafted code, design and txp

Offline

#6 2018-11-12 10:02:01

detail
Member
From: geez, I seem to be in NZ
Registered: 2010-07-13
Posts: 176
Website

Re: Upgrade 4.5.7? > 4.7.1

Jakob. Thanks for this.

Sometimes you go around in circles.

Here’s some good news.

1. My front page is up again in full. I needed to change to:

<txp:article_custom id="39" status="sticky" /> 

It used to work with just article, not article_custom.

2. <txp:article> does work elsewhere, when in <if-article-list>.

3. Emptying my cache helped with getting Chrome and Safari looking the same. That’s a beginner’s error!!

4. My config file is definitely with the /textpattern removed, and is working correctly. It shows /html/tramping/textpattern in the diagnostics.

$txpcfg['txpath'] = '/home/content/d/e/t/detail/html/tramping/'

On the other hand, I do still have a problem with the missing menu on a couple of sections that have different pages. Will work through that. That isn’t a killer at the moment. Not like having most of the front page missing!

Now almost 11 pm so will look tomorrow. Thanks again for your help.

Offline

#7 2018-11-12 10:09:20

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,250
Website GitHub

Re: Upgrade 4.5.7? > 4.7.1

detail wrote #315172:

I needed to change to: <txp:article_custom id="39" status="sticky" />...

Yes, 4.7 is a lot tighter. You can no longer use id in <txp:article /> calls because articles get their ID from the URL context. The fact you could specify an id in previous versions was sort of a bug. If you want to grab specific articles “out of context” you must now use <txp:article_custom />.

My config file is definitely with the /textpattern removed, and is working correctly. It shows /html/tramping/textpattern in the diagnostics.

jakob is right, it should definitely be with the trailing /textpattern. The reason your site still “works” is because we have an auto-detect mechanism that checks that value in config.php and makes an educated guess what it should be, then rewrites it in the database if it think it’s wrong. That’s why you see the “corrected” value in Diagnostics.

You should fix it at the file level though, or other things might go sideways.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#8 2018-11-12 15:15:14

towndock
Member
From: Oriental, NC USA
Registered: 2007-04-06
Posts: 329
Website

Re: Upgrade 4.5.7? > 4.7.1

Now that you site is working – what a brilliant subject for a web site. Tramping. Love it.

Offline

#9 2018-11-12 16:03:16

bici
Member
From: vancouver
Registered: 2004-02-24
Posts: 2,071
Website Mastodon

Re: Upgrade 4.5.7? > 4.7.1

the site is not loading for me – using Safari / Chrome

EDIT: seems to be a lack of css files

Last edited by bici (2018-11-12 16:03:57)


…. texted postive

Offline

#10 2018-11-12 19:37:40

gaekwad
Server grease monkey
From: People's Republic of Cornwall
Registered: 2005-11-19
Posts: 4,134
GitHub

Re: Upgrade 4.5.7? > 4.7.1

detail wrote #315172:

3. Emptying my cache helped with getting Chrome and Safari looking the same. That’s a beginner’s error!!

My pro tip for any Textpattern upgrade (aside from the old chestnut of make backups): use Tor browser. It has aggressive anti-caching measures, so simply restarting it gives you a blank, cache-less canvas.

Offline

#11 2018-11-12 21:37:03

detail
Member
From: geez, I seem to be in NZ
Registered: 2010-07-13
Posts: 176
Website

Re: Upgrade 4.5.7? > 4.7.1

Bloke wrote #315173:

Yes, 4.7 is a lot tighter. You can no longer use id in <txp:article /> calls because articles get their ID from the URL context. The fact you could specify an id in previous versions was sort of a bug. If you want to grab specific articles “out of context” you must now use <txp:article_custom />.

That explains it. Thanks Stef.

jakob is right, it should definitely be with the trailing /textpattern. The reason your site still “works” is because we have an auto-detect mechanism that checks that value in config.php and makes an educated guess what it should be, then rewrites it in the database if it think it’s wrong. That’s why you see the “corrected” value in Diagnostics.

Ditto. Will experiment at a low visiting time.

Hey, thanks for all the work you guys put in to a). do these updates, and b). explain things to uneducated dolts . . .

Now just have to convert to https. Not looking forward to that.

Offline

#12 2018-11-12 21:49:24

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,578
Website

Re: Upgrade 4.5.7? > 4.7.1

Now just have to convert to https. Not looking forward to that.

That’s not so bad. You asked us before here.

And if you need a hand with auto search-replacing in your DB, you can also ask one of us.


TXP Builders – finely-crafted code, design and txp

Offline

Board footer

Powered by FluxBB