Upgraded, Now Subpages don't work

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
LeeUmm
Forum Members
Forum Members
Posts: 37
Joined: Mon Jan 28, 2008 3:14 am

Upgraded, Now Subpages don't work

Post by LeeUmm »

I upgraded to the latest version 1.4.1 from 1.3.x, and things work for the most part. The only problem I now have is that none of my subpages work. Parent level pages render fine, but subpages throw out a php error at the top of the page:

Warning: preg_match() [function.preg-match]: Unknown modifier '\' in /home/user/public_html/index.php on line 129

I'm using the latest .htaccess file with pretty URLs.
baresi
Forum Members
Forum Members
Posts: 129
Joined: Fri Jul 27, 2007 4:15 pm

Re: Upgraded, Now Subpages don't work

Post by baresi »

Its possible that the line mentioned requires a / instead of \

Paste that line if you can.
LeeUmm
Forum Members
Forum Members
Posts: 37
Joined: Mon Jan 28, 2008 3:14 am

Re: Upgraded, Now Subpages don't work

Post by LeeUmm »

Hi,

You can take a look at both. I've included as attachments and removed passwords and such. View the config in an editor.

You can also view the site - mcgowangroupinc.com (can't link directly for stat purposes)

*Edit* Removed attachments
Last edited by LeeUmm on Thu Aug 21, 2008 2:56 pm, edited 1 time in total.
lb01
New Member
New Member
Posts: 6
Joined: Thu Aug 21, 2008 9:09 am

Re: Upgraded, Now Subpages don't work

Post by lb01 »

Hi,
Try this :
- Open index.php
- Go to line 129
- Replace :

Code: Select all

$matches = array();
		if (preg_match($route->regex, $page, $matches))
		{
  With :
 

Code: Select all

$matches = array();
		if($route->regex == '[fF]eu\/verify\/(?P<returnid>[0-9]+)\/(?P<uid>[0-9]+)\/(?P<code>.*?)$/') $route->regex = '#[fF]eu\/verify\/(?P<returnid>[0-9]+)\/(?P<uid>[0-9]+)\/(?P<code>.*?)$/#';
		if (preg_match($route->regex, $page, $matches))
		{
- Upload index.php

It was because the regex isn't delimited.

It work for me. ;)
alby

Re: Upgraded, Now Subpages don't work

Post by alby »

lb01 wrote: - Open index.php
............
maybe is better in modules/FrontEndUsers/FrontEndUsers.module.php
and add:

$this->RegisterRoute('/[fF]eu\/verify\/(?P[0-9]+)\/(?P[0-9]+)\/(?P.*..........

Alby
Nick Smart
Forum Members
Forum Members
Posts: 116
Joined: Mon Jul 28, 2008 4:48 pm
Location: Cambridge, UK

Re: Upgraded, Now Subpages don't work

Post by Nick Smart »

Thanks lb01 and alby,

I had the same problem.

Nick
lb01
New Member
New Member
Posts: 6
Joined: Thu Aug 21, 2008 9:09 am

Re: Upgraded, Now Subpages don't work

Post by lb01 »

Yes, it's better, thanks alby ;).
User avatar
blast2007
Power Poster
Power Poster
Posts: 508
Joined: Wed Aug 01, 2007 5:36 pm

Re: Upgraded, Now Subpages don't work

Post by blast2007 »

alby wrote: $this->RegisterRoute('/[fF]eu\/verify\/(?P[0-9]+)\/(?P[0-9]+)\/(?P.*..........
Thanks to alby care and devotion to duty  :o, he discovered a small bug in FEU 1.5.2.

As side effects you can see in your apache many and many error log entries (everytime a page is served) pointing to line 120 of /index.php :

Code: Select all

PHP Warning:  preg_match() [<a href='function.preg-match'>function.preg-match</a>]: Unknown modifier '\\' in /var/www/index.php on line 120, referer: ...
Are developers of module informed of this bug? Should we submit a new bug?

regards
blast
Last edited by blast2007 on Fri Aug 22, 2008 11:00 am, edited 1 time in total.
LeeUmm
Forum Members
Forum Members
Posts: 37
Joined: Mon Jan 28, 2008 3:14 am

Re: Upgraded, Now Subpages don't work

Post by LeeUmm »

Perfect, that did it.

That makes sense, I forgot I upgraded my modules as well and didn't notice the error until I had upgraded everything. Just assumed it was cause of the main CMS upgrade.
mike-r

Re: Upgraded, Now Subpages don't work

Post by mike-r »

thx a lot from me too.
sparquay
New Member
New Member
Posts: 7
Joined: Mon Sep 08, 2008 3:18 am

Re: Upgraded, Now Subpages don't work

Post by sparquay »

Add another grateful person to the list of those helped! Me.
User avatar
Lucaz
Forum Members
Forum Members
Posts: 66
Joined: Fri Dec 01, 2006 9:56 pm
Location: Netherlands

Re: Upgraded, Now Subpages don't work

Post by Lucaz »

lb01 wrote: $this->RegisterRoute('/[fF]eu\/verify\/(?P[0-9]+)\/(?P[0-9]+)\/(?P.*..........
Well I can't seem to edit this file since I can't CHMod it with Cute FTP or in my control panel of Plesk.
I can't overright the file or delete the whole module..
Nick Smart
Forum Members
Forum Members
Posts: 116
Joined: Mon Jul 28, 2008 4:48 pm
Location: Cambridge, UK

Re: Upgraded, Now Subpages don't work

Post by Nick Smart »

It's a permissions problem. It depends on the way the host is set up. I have a few sites like this.

Use the CMSMS File Manager. Give yourself access to the whole file system (its an option in the File Manager) and use that to upload the fixed file.

Nick
Post Reply

Return to “CMSMS Core”