Unpublished first page gives 404 Not found

A place to report and discuss bugs - please mention CMSimple-version, server, platform and browser version
Post Reply
cmb
Posts: 13333
Joined: Tue Jun 21, 2011 11:04 am
Location: Mü-Sa, RLP, DE
Contact:

Unpublished first page gives 404 Not found

Post by cmb » Thu Jun 12, 2014 9:19 pm

Hello Community,

I just noticed, that CMSimple_XH gives a "404 Not found" when the installation is requested directly (i.e. without specifying a page), but the first page is unpublished. IMO this is a bug, or at least an ugly limitation, that has not been in classic CMSimple.

I suggest that we try to fix that for XH 1.6.3. It should be sufficient to modify multiple (IIRC there are 3) occurrences of the $s fix:

Code: Select all

// fix $s
if ($s == -1 && !$f && $o == '' && $su == '') {
    $s = 0;
    $hs = 0;
}
where 0 could be replaced by XH_firstPage() or something like that.

To cater for respective page_params settings, the core would have to check for a plugin setting, what I don't really like, but it has already been done for li(). We may consider to fully integrate page_params into the core for XH 1.7.

Christoph
Christoph M. Becker – Plugins for CMSimple_XH

cmb
Posts: 13333
Joined: Tue Jun 21, 2011 11:04 am
Location: Mü-Sa, RLP, DE
Contact:

Re: Unpublished first page gives 404 Not found

Post by cmb » Sun Aug 24, 2014 10:01 pm

cmb wrote:where 0 could be replaced by XH_firstPage() or something like that.
That didn't work, because #cmsimple remove# is already replaced in rfc(). Thus I have introduced another global variable: $_XH_firstPublishedPage (r1360). :cry:
Christoph M. Becker – Plugins for CMSimple_XH

Post Reply