Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

  1. Index
  2. » Archives
  3. » displaying code

#1 2006-02-16 11:23:26

nottosay
New Member
Registered: 2004-12-21
Posts: 5

displaying code

I’m in the process of moving servers. I’ve got the db and code transferred ok, the config has been changed and the front page is displaying correctly… however when I navigate to one of the subfolders it writes the code to screen rather than running it. I’ve spoken to the hosts about this and they say “textpattern/config.php is attempting to run, but I have no idea what the server requirements are for your script.”

Can anyone help out?

you can view the site at:

http://82.110.105.20/nottosay.co.uk/

and the problem at

http://82.110.105.20/nottosay.co.uk/blog

- the styles aren’t displaying as they’re referencing /.

Thanks for any help,

Ema

Offline

#2 2006-02-16 12:31:24

zem
Developer Emeritus
From: Melbourne, Australia
Registered: 2004-04-08
Posts: 2,579

Re: displaying code

The problem is with .htaccess. The solution is probably host specific. Some pointers here.

It looks like you’re using a very old version of Textpattern, which probably means a different .htaccess file. You’ll need help from your host.


Alex

Offline

#3 2006-02-16 14:16:43

nottosay
New Member
Registered: 2004-12-21
Posts: 5

Re: displaying code

I looked at the link you suggested, it says the problem is with .htaccess not supporting mod_rewrite.

I’ve checked with the host company and they do support mod_rewrite so this isn’t the problem. I will try to upgrade textpattern, although last time I tried everything went horribly wrong :)

Thanks for your help.

Emma

Offline

#4 2006-02-16 22:49:47

zem
Developer Emeritus
From: Melbourne, Australia
Registered: 2004-04-08
Posts: 2,579

Re: displaying code

Merely having mod_rewrite installed doesn’t mean everything will work correctly. Also, like I said, you probably have an old version of .htaccess, which is different.

This part of the FAQ is true: “The simplest solution is to use “messy” URLs instead (see textpattern > admin > preferences > permanent link mode).”


Alex

Offline

#5 2006-02-21 16:54:06

nottosay
New Member
Registered: 2004-12-21
Posts: 5

Re: displaying code

I’ve updated textpattern to the latest version and I’m still getting the same problem.

It looks like the code isn’t being run – although the support desk assure me it is. Is there anything else you can suggest? I don’t want to use “messy” URL’s as it will be easier to find a different software than re-write the rest of the site, which is what I’d need to do.

Thanks,

Emma

Offline

#6 2006-02-21 18:56:50

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: displaying code

> “It looks like the code isn’t being run – although the support desk assure me it is.”

Simple test: <?php echo 'PHP was successfully run'; ?>

Put that in a new text file, save it to have a .php extension (say “test.php”), and try and run it.

Offline

#7 2006-02-21 21:39:57

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: displaying code

That looks like an old section placeholder file. Didn’t those need a force-type directive to work? You shouldn’t need those at all anymore.


Shoving is the answer – pusher robot

Offline

#8 2006-02-22 11:26:31

nottosay
New Member
Registered: 2004-12-21
Posts: 5

Re: displaying code

It looks like I’m getting somewhere!

I had a very old version of textpattern which I’ve now upgraded to the latest (I’m expecting a host of troubles later because of this ;) ). I then deleted all the placeholder thingys – thanks hakjoon.

My site is now displaying sort of as I would expect, however the textpattern admin isn’t happy. It’s displaying the message:

“config.php is not ok or not found. If you would like to install, go to [/subdir]/textpattern/setup/ “

I’ve run setup again (which I’ve removed for now) to regenerate config.php and it’s still coming up with the message.

Edit to add I tried this – doesn’t work [Do I need to regenerate all the tables? This will delete all my old data wont it?]

The config file looks like this:

<?php
$txpcfg[‘db’] = ‘web20_nottosay_1’;
$txpcfg[‘user’] = ‘web20_nottosay_1’;
$txpcfg[‘pass’] = ‘******’;
$txpcfg[‘host’] = ‘localhost’;
$txpcfg[‘table_prefix’] = ‘’;
$txpcfg[‘txpath’] = ‘/home/sites/nottosay.co.uk/public_html/textpattern’;
$txpcfg[‘dbcharset’] = ‘utf8’;
?>

- with the password where the stars are of course!

Last edited by nottosay (2006-02-22 11:42:03)

Offline

#9 2006-02-22 14:47:58

nottosay
New Member
Registered: 2004-12-21
Posts: 5

Re: displaying code

Aha, I’ve fixed it… I’m not sure how but it’s all working.

Thanks everyone for your help!

Offline

  1. Index
  2. » Archives
  3. » displaying code

Board footer

Powered by FluxBB