Jump to content
Skippy le Grand Gourou

Website without homepage

Recommended Posts

Hi,

First thanks for PW, I tested it against 4 other supposedly well-written CMS (namely Bolt, Concrete5, Croogo & PyroCMS) and it was by far the fastest and the lightest of all (I'll post details later), which was important for me.  Furthermore for the moment everything seems straightforward and/or described in the forums (this is my first real CMS experience).

Well, everything but one thing. :)  Actually I guess it has already been addressed somewhere but I can't figure how to search for it.

I'm trying to make a website without an homepage (or, for search's sake, with no homepage).  That is, I would like such a flat hierarchy :

- A [homepage]
  - A1
  - A2
  - …
- B
  - B1
  - B2
  - …
- …

I can see two ways to do that, but neither work : either by hiding the homepage (unfortunately it doesn't hide, probably a bug ?) or by having several homepages (unfortunately it seems it's not possible to create new pages at the root).

Any idea ?

Share this post


Link to post
Share on other sites

How about a 301 with $session->redirect? Wouldn't that do the trick?

  • Like 3

Share this post


Link to post
Share on other sites

er ... if you were doing this by straight html, no cms, how would you do it?

Surely you would still end up with a single landing page? index.html, probably.

In your layout above, if A is reached by mywebsite.com, how is B reached? Would that not be mywebsite.com/B.html?

In which case, as far as the visitor is concerned, B appears like a child of A, even though they are actually in the same folder.

How is that different from how PW is normally?

  • Like 1

Share this post


Link to post
Share on other sites

<?php

// home template

$session->redirect($pages->get('/')->children->first->url);

// or even easier because it is already the "homepage"

$session->redirect($page->children->first->url);

?>

  • Like 4

Share this post


Link to post
Share on other sites

@joss : It's just that my explanation is bad — though in your example, I don't consider B as a child of A.  My issue is that I want A to list its children and B to list its own children, but A & B being on the same level in the menu.  Of course I could do it with templates but I thought it would be quite messy for such a simple thing.

A redirect should do the trick indeed, how could I not think about that.  Thanks !

  • Like 1

Share this post


Link to post
Share on other sites

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...