Jump to content

Recommended Posts

Posted

Hi,

I'm a bit puzzled.

$page->template returns some unrelated template.

All other ID / Title / Name / Parents / ... work.

$pages->get(...)->template returns same false template.

Any idea what I'm missing here?

thanks!

ProcessWire 2.6.18 dev

Posted

May be silly to ask, but are you 100% sure you've selected the intended template for the page? And have you perhaps tried with the latest dev (2.6.19)?

(For the record, I am unable to repdroduce this.)

Posted

May be silly to ask, but are you 100% sure you've selected the intended template for the page? And have you perhaps tried with the latest dev (2.6.19)?

(For the record, I am unable to repdroduce this.)

Sure :)

Just figured out

$pages->get(1018)->template;

returns the wrong result only when viewed from this page (ID=1018), but returns the proper template when called from any other page.

Had a probably related issue recently with IDs.

Inclined to resetup the whole AMPPS since resetting / clearing caches the whole environment didnt help either .

I don't think it's an PW issue.

Posted

Hmm, that is strange. Technically, there would be no reason for that to occur, and can't reproduce it. I don't think it would be a server issue either, but what was the related issue regarding IDs?

Posted

You seem to have a $page->template = 'something' in your template.

omg. what a silly mistake. thanks for the hint. back to php nursery.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...