providesAsset not working

Permalink
Hi,

I'm trying to convert an html theme to concrete5. I'm providing jquery as part of my theme and this is my page_theme.php:
<?php
namespace Application\Theme\Core;
use Concrete\Core\Area\Layout\Preset\Provider\ThemeProviderInterface;
class PageTheme extends \Concrete\Core\Page\Theme\Theme 
{ 
    public function registerAssets()
    {
        $this->providesAsset('javascript', 'jquery');
        $this->providesAsset('css', 'bootstrap/*');
        $this->requireAsset('javascript', 'bootstrap/*');
    }
}

For some reason when I view source on the site, I can see that concrete5 is still loading its own jquery file:
<script type="text/javascript" src="/core/concrete5/concrete/js/jquery.js"></script>

This is causing bugs when trying to edit content which makes the site unusable at the moment. What am I doing wrong?

 
hutman replied on at Permalink Reply
hutman
What is the directory structure to this file, I think you have the namespace wrong.
jyanay76 replied on at Permalink Reply
Thanks for the reply,

This is the directory where page_theme.php is located:
/var/www/core/concrete5/application/themes/Core/
hutman replied on at Permalink Best Answer Reply
hutman
I'm not sure if this would affect things or not, but "Core" is somewhat of a reserved word, I would not recommend making that the name of your theme.

Also, the theme directory should be lowercase, so it should be application/theme/core/page_theme.php

Your code is correct though if that's what your directory structure looks like.
jyanay76 replied on at Permalink Reply
Thanks for pointing me in the right direction! It wasn't loading my page_theme.php because the directory name was capitalized.