Can't edit pages.
Permalink
can someone tell me why I can't edit any page?Here is the code from my default page.
code from page_theme
<?php
namespace Concrete\Theme\Concrete;
class PageTheme extends \application\themes\tr
{
public function registerAssets() {
$this->requireAsset('javascript', 'jquery');
$this->providesAsset('javascript', 'bootstrap/*');
$this->providesAsset('css', 'bootstrap/*');
$this->requireAsset('css', 'font-awesome');
}
protected $pThemeGridFrameworkHandle = 'bootstrap3';
}
<?php $view->inc('elements/header.php'); ?> <?php $a = new Area('Content'); if (($a->getTotalBlocksInArea($c) > 0) || ($c->isEditMode())) { ?> <div class="container-fluid"> <div class="row"> <div class="col-md-12 zero"> <?php $a->display($c); ?> </div> </div> <div class="row blue-box"> <?php $a->display($c); ?> </div> <header>
Viewing 15 lines of 42 lines. View entire code block.
code from page_theme
namespace Concrete\Theme\Concrete;
class PageTheme extends \application\themes\tr
{
public function registerAssets() {
$this->requireAsset('javascript', 'jquery');
$this->providesAsset('javascript', 'bootstrap/*');
$this->providesAsset('css', 'bootstrap/*');
$this->requireAsset('css', 'font-awesome');
}
protected $pThemeGridFrameworkHandle = 'bootstrap3';
}
Hi,
That made things worst. Now the icons on the tool bar and the edit areas disappear.
Here is the changed code.
That made things worst. Now the icons on the tool bar and the edit areas disappear.
Here is the changed code.
<?php $view->inc('elements/header.php'); ?> <?php $a = new Area('Content'); if (($a->getTotalBlocksInArea($c) > 0) || ($c->isEditMode())) { ?> <div class="container-fluid"> <div class="row"> <div class="col-md-12 zero"> <?$a = new Area('Slider'); $a->display($c); ?> </div> </div> <div class="row blue-box"> <?php $a = new Area('Blue'); $a->display($c); ?>
Viewing 15 lines of 82 lines. View entire code block.
Your example code has errors in it.
I recommend reading the documentation on theme building.
https://www.concrete5.org/documentation/developers/5.7/designing-for...
It would also be useful to look at how the default Elemental theme is constructed.
If you want to zip up your theme and attach it in a reply, I can look at it.
I recommend reading the documentation on theme building.
https://www.concrete5.org/documentation/developers/5.7/designing-for...
It would also be useful to look at how the default Elemental theme is constructed.
If you want to zip up your theme and attach it in a reply, I can look at it.
Hi, Thanks for the help. I have attached a zip with the files.
Here is what it suppose to be in the end;
http://1900tr.com/test/
Here is what it suppose to be in the end;
http://1900tr.com/test/
I have attached a working copy of your theme.
I commented the code that was causing the editing interface to break.
I commented the code that was causing the editing interface to break.
Thank for all the help. Looks like I was trying to put more then I should of into the default page. I should of gone back to doing it the 5.6 and below way and just added names for the areas.
I am now getting this error.
Call to a member function hasPageThemeGridFrameworkOffsetClasses()
I am now getting this error.
Call to a member function hasPageThemeGridFrameworkOffsetClasses()
What action preceded the error?
I am not sure what the exact nature of the error is, but there is an open bug tracker issue for it. I recommend voting on it.
https://www.concrete5.org/developers/bugs/5-7-5-2/haspagethemegridfr...
I am not sure what the exact nature of the error is, but there is an open bug tracker issue for it. I recommend voting on it.
https://www.concrete5.org/developers/bugs/5-7-5-2/haspagethemegridfr...
I tried that patch and the editor disappeared. Guess i will have to wait until the next version.
What is the name of your theme and where is it located?
The main problem I see is that you are attempting to display areas without creating them first.
When you create new Area objects, they need a name that is unique to each area.
Example: