Jump to content
  • [Beta4] OutOfRangeException in ACP when using 'Page Editor' (wizard)


    Hello,

    I get an OutOfRangeException in ACP when using 'Page Editor' (wizard).

    The OutOfRangeException is not the issue (!!) - I have a RawHTML widget and included "{{$record = $record_class::load(4);}}" when record number 4 does not exist -- so I know what I did and it's all my fault.

    The issue is the way the ACP handles the error. I know what I need/want to do -- I want to go back in and edit the RawHTML widget to include a valid record number but I cannot do that because the ACP displays the OutOfRangeException where the RawHTML widget should be and I cannot do anything at that point - I cannot delete the widget and start again and I cannot edit the widget contents.

    What should happen is that the widget should catch the error and display it but should allow the widget to be deleted and/or edited to fix the problem.

    On this particular occasion, I'm not that worried about how I'll work around the problem. I know what I did and can easily create a record to resolve the issue (or can zap the widget in the database or whatever) -- I am more concerned about the way the ACP is behaving and the fact that it does not handle this scenario in a way to make it easy for other administrators to dig their way out of the hole.

    Thanks.

    John

     

    OutOfRangeException:  (0)
    #0 /home/bn2468/public_html/applications/cms/sources/Databases/Databases.php(294): IPS\Patterns\ActiveRecord::load()
    #1 /home/bn2468/public_html/system/Theme/Theme.php(3678) : eval()'d code(9): IPS\cms\Databases::load()
    #2 /home/bn2468/public_html/applications/cms/widgets/Codemirror.php(140): IPS\Theme\content_widget_39e47d()
    #3 /home/bn2468/public_html/system/Widget/Widget.php(1291): IPS\cms\widgets\Codemirror->render()
    #4 /home/bn2468/public_html/system/Widget/Widget.php(1391): IPS\Widget->_render()
    #5 /home/bn2468/public_html/system/Widget/Area.php(914): IPS\Widget->__toString()
    #6 /home/bn2468/public_html/system/Theme/Theme.php(3678) : eval()'d code(186): IPS\Widget\Area->getWidgetContent()
    #7 /home/bn2468/public_html/system/Theme/Dev/Template.php(151): IPS\Theme\theme_core_front_global_widgetArea()
    #8 /home/bn2468/public_html/system/Widget/Area.php(273): IPS\Theme\Dev\Template->__call()
    #9 /home/bn2468/public_html/system/Theme/Theme.php(3678) : eval()'d code(115): IPS\Widget\Area->__toString()
    #10 /home/bn2468/public_html/system/Theme/Dev/Template.php(151): IPS\Theme\theme_core_front_global_widgetArea()
    #11 /home/bn2468/public_html/system/Widget/Area.php(273): IPS\Theme\Dev\Template->__call()
    #12 /home/bn2468/public_html/applications/cms/sources/Pages/Page.php(2177): IPS\Widget\Area->__toString()
    #13 /home/bn2468/public_html/applications/cms/sources/Pages/Page.php(2071): IPS\cms\Pages\Page->getPageContent()
    #14 /home/bn2468/public_html/applications/cms/modules/front/pages/page.php(122): IPS\cms\Pages\Page->output()
    #15 /home/bn2468/public_html/applications/cms/modules/front/pages/page.php(49): IPS\cms\modules\front\pages\page->view()
    #16 /home/bn2468/public_html/system/Dispatcher/Controller.php(139): IPS\cms\modules\front\pages\page->manage()
    #17 /home/bn2468/public_html/system/Dispatcher/Dispatcher.php(169): IPS\Dispatcher\Controller->execute()
    #18 /home/bn2468/public_html/index.php(16): IPS\Dispatcher->run()
    #19 {main}


    User Feedback

    Recommended Comments

    There are no comments to display.


×
×
  • Create New...