Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Options

Writing an Application

edited October 2011 in Vanilla 2.0 - 2.8
I'm following the "A Quick-Start Guide to Writing Applications in Vanilla" guide and got to the point of a "HomepageController" but some of the code is missing, so I guessed at:

<?php if (!defined('APPLICATION')) exit();

class HomepageController extends WelcomeController {
public function index() {
Render();
}
}

Sadly when I navigate to /welcome/homepage I get a "Page Not Found", am I doing something wrong or is it possible my application is not set up right?

Thanks for any help.
Tagged:

Best Answer

  • Options
    sahotataransahotataran Developer, Bay Area - CA ✭✭✭
    Answer ✓
    well then you will have to check through each and every step again
    and i think you first line should be if you are making an application 'welcome'

    class WelcomeController extends HomePageController {

    There was an error rendering this rich post.

Answers

  • Options
    sahotataransahotataran Developer, Bay Area - CA ✭✭✭
    if that is how you are adding it - it should go like this

    <?php if (!defined('APPLICATION')) exit(); ?> <br /> <?php class HomepageController extends WelcomeController { public function index() { Render(); } } ?>

    note -
    can not go as such in php

    There was an error rendering this rich post.

  • Options
    That's exactly how I have it, yet I get the Page Not Found, everything else is followed from the tutorial. I'm so confused!
  • Options
    sahotataransahotataran Developer, Bay Area - CA ✭✭✭

    There was an error rendering this rich post.

  • Options
    That is correct yes, appreciate the help by the way!
  • Options
    sahotataransahotataran Developer, Bay Area - CA ✭✭✭
    Answer ✓
    well then you will have to check through each and every step again
    and i think you first line should be if you are making an application 'welcome'

    class WelcomeController extends HomePageController {

    There was an error rendering this rich post.

  • Options
    I've managed to get the Controllers working and displaying my view file, but the view has no CSS attached to it. Is there an include I am missing?

    Thanks.
  • Options
    Sorted the above! Now looking in how to create my own Category on the Dashboard if anyone has any answers for that.
Sign In or Register to comment.