Jump to:

5514 Posts in 1733 Topics by 1219 members

Customising the CMS

SilverStripe Forums » Customising the CMS » Problem with following Tutorial 2

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1166 Views
  • mango
    Avatar
    Community Member
    26 Posts

    Problem with following Tutorial 2 Link to this post

    Ok, I've added both the ArticlePage.php and ArticleHolder.php files in mysite/code/ as per the tutorial, when I did the db/build/?flush=1 as per the tutorial, I got the following on my browser:

    ==========================================
    Warning: scandir(C:/xampplite/htdocs/SilverStripe/AM-CCSM) [function.scandir]: failed to open dir: No error in C:\xampplite\htdocs\SilverStripe\sapphire\core\ManifestBuilder.php on line 295

    Warning: scandir() [function.scandir]: (errno 0): No error in C:\xampplite\htdocs\SilverStripe\sapphire\core\ManifestBuilder.php on line 295
    [Notice] Undefined variable: _SESSION
    GET /SilverStripe/db/build/?flush=1

    Line 120 in C:\xampplite\htdocs\SilverStripe\sapphire\core\control\Director.php

    Source

    111          @file_get_contents('php://input')
    112       );
    113       
    114       // @todo find better way to extract HTTP headers
    115       if(isset($_SERVER['HTTP_ACCEPT'])) $req->addHeader("Accept", $_SERVER['HTTP_ACCEPT']);
    116       if(isset($_SERVER['CONTENT_TYPE'])) $req->addHeader("Content-Type", $_SERVER['CONTENT_TYPE']);
    117       if(isset($_SERVER['HTTP_REFERER'])) $req->addHeader("Referer", $_SERVER['HTTP_REFERER']);
    118
    119       // Load the session into the controller
    120       $session = new Session($_SESSION);
    121       $result = Director::handleRequest($req, $session);
    122       $session->inst_save();
    123
    124       // Return code for a redirection request
    125       if(is_string($result) && substr($result,0,9) == 'redirect:') {
    126          $response = new HTTPResponse();

    Trace

    * Director::direct(/db/build/)
    Line 115 of main.php
    ==========================================

    Can anyone please tell me what am I doing wrong here? Thanks.

  • Aram
    Avatar
    Community Member
    598 Posts

    Re: Problem with following Tutorial 2 Link to this post

    Hi Mango

    As of SS 2.3 the database build URL is www.yoursite.com/dev/build

    Not sure if that is the problem, but it's a start

  • mango
    Avatar
    Community Member
    26 Posts

    Re: Problem with following Tutorial 2 Link to this post

    Fixed: the global variable $project in mysite/_config.php was wrongly set, my stupid mistake ;-)

    1166 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.