Just finished my theme, where to now?

Permalink
Hello fellow Concrete bros.

I'm new in this area of Web deveplopment, and CMS is complety new to me. So i'm quite the newbie.

I just finished making a theme so that it did work. Now i'm wondering. How do i add "Sub-pages" to my site so that they actually link somewhere, and how to make my signout signin work. It just transfers me to a blank page?

Stenkilde
 
mhawke replied on at Permalink Reply
mhawke
Welcome to concrete5.

A few questions first. When you say "I just finished making a theme so it did work", do you mean it worked within your concrete5 environment or just 'works' as a static html page when you open it in a browser?

Did you base your theme off an existing concrete5 theme or did you build it from scratch?

Perhaps an introductory video might help explain how things work:

http://youtu.be/F2C9cqEff3k
Stenkilde replied on at Permalink Reply
Stenkilde
Thank you sir..

I made the HTML5 page, my self and made it into a Concrete5 environment. With editable areas etc. Loader elements and such.

But i had a problem with my nav, so i had to make it into an "HTML block" and not an auto nav, is that recommended or?
SuperNova replied on at Permalink Reply
SuperNova
more questions...

- do you have editable areas in your template?
- normal ones, a globalArea for the navigation or a hardcoded navigation?
- do have 'Loader::element('header_required');' (editbar) integrated?
- your template is uploaded and activated (dashboard)?

it is not so clear, if this is just a technical problem.
Stenkilde replied on at Permalink Reply
Stenkilde
Yes to all your questions.

I have editable areas, i have Loader elements, both for header and footer.
Stenkilde replied on at Permalink Reply
Stenkilde
Though, i did have a slight problem with the nav, and decided to "hardcode" it with a html block.
mhawke replied on at Permalink Reply
mhawke
Personally, an AutoNav is 90% of the reason I use a content management system. Many add-ons rely on a working AutoNav. If you hard-code your nav, you will spend a great deal working on the nav portion of your website rather than the content. What specific problems were you having with the autonav? It sounds like this might be the reason you asked 'what do I do now' in the first place.
SuperNova replied on at Permalink Reply
SuperNova
I agree with mhawke. I think if you figure out to use the autonav properly you will be glad later on. Otherwise you lose the dynamic functions. So can you descripe the problem with the autonav?

Actually 'hardcoding' means to put the functionality of a modul directly in the template.

F.e. autonav as mainmenu:
<nav>
<?php 
$autonav = BlockType::getByHandle('autonav'); 
$autonav->controller->orderBy = 'display_asc'; 
$autonav->controller->displayPages = 'top'; 
$autonav->render('templates/header_menu'); 
?>
</nav>


PHP code is not working in a HTML-block.
HTML-navs in HTML-Blocks have to be modified on every page (active, new pages..)
Stenkilde replied on at Permalink Reply
Stenkilde
Sorry for the late answer Nova. But yes you are right. Thats why i'm asking.

My problem is, my nav looks like this at the moment


[code]<nav>
<h1 class="logo"><a href="index.php">gamers <span>nation</span></a></h1>
<a href="index.php">Home</a>
<a href="index.php/events">Events</a>
<a href="index.php/signup">Signup</a>
<a href="index.php/archive">Archive</a>
<a href="index.php/about">About</a>
</nav>[code]

But i have no idea at all how to make it work together with Concrete5. I have worked alot on trying to make a custom template for it, but again. My knowledge php is not that good.

I really appreciate the help guys!
mhawke replied on at Permalink Best Answer Reply
mhawke
The 'autonav' code block that SuperNova posted will automatically build your nav for you. That's why it's called autonav.

An automatic nav should appear if you open your page template file where you have your <nav> code and replace it with SuperNova's example code like this:

<nav>
<h1 class="logo"><a href="index.php">gamers <span>nation</span></a></h1>
<?php 
$autonav = BlockType::getByHandle('autonav'); 
$autonav->controller->orderBy = 'display_asc'; 
$autonav->controller->displayPages = 'top'; 
$autonav->render('templates/header_menu'); 
?>
</nav>


Of course it will take some tweaking but try this and then ask us about how to tweak it. Don't give up on one of the most important pieces of the C5 puzzle. Autonav will save you countless hours so it's worth the effort to get it working.

Can you attach the page your are working on (the one with the hard-coded nav) for us to have a look at. In order to attach it to these forums you will need to change the .php at the end of the file name to .txt .
Stenkilde replied on at Permalink Reply
Stenkilde
I thank you so much!

I got it all rolling now, now after tweaking my auto nav with the code you provided my menu is working like it should! Thanks!

Now i'm back to building again, thanks for leading me on the right track!

Have a nice day sir!
mhawke replied on at Permalink Reply
mhawke
Excellent news!

Be sure to have a look at the answers given above and mark the one you feel is the 'Best Answer'. That way anyone who has the same problem can find the most fruitful way forward.