What's new
Xen Factory

Register today to become a member! Once signed in, you'll be able to start purchasing our products, ask questions, request support and suggest new ideas!

  • We are aware that a no permission error was shown when you tried to purchase in the last 2 days, this is now fixed.

Bug Not a bug bug

anil

New Member
Code:
Server error log

ErrorException: Template error: [E_USER_WARNING] Cannot call method getBreadcrumbs on a non-object (NULL) src/XF/Template/Templater.php:1268

Generated by: Unknown account Sep 21, 2024 at 8:47 AM

Stack trace

#0 [internal function]: XF\Template\Templater->handleTemplateError(512, '[E_USER_WARNING...', '/home/ljqmbq3g0...', 1268)
#1 src/XF/Template/Templater.php(1268): trigger_error('Cannot call met...', 512)
#2 internal_data/code_cache/templates/l1/s117/public/xfrm_resource_wrapper.php(11): XF\Template\Templater->method(NULL, 'getBreadcrumbs', Array)
#3 src/XF/Template/Templater.php(1792): XF\Template\Templater->{closure}(Object(XenGenTr\XGTOnekSistemi\XF\Template\Templater), Array, NULL)
#4 src/addons/MaZ/AUN/XF/Template/Templater.php(39): XF\Template\Templater->renderTemplate('xfrm_resource_w...', Array, false, NULL)
#5 src/XF/Template/Templater.php(1154): MaZ\AUN\XF\Template\Templater->renderTemplate('public:xfrm_res...', Array, false)
#6 src/XF/Template/Templater.php(1815): XF\Template\Templater->applyWrappedTemplate('









...')
#7 src/addons/MaZ/AUN/XF/Template/Templater.php(39): XF\Template\Templater->renderTemplate('xfrm_resource_v...', Array, true, NULL)
#8 src/XF/Template/Template.php(24): MaZ\AUN\XF\Template\Templater->renderTemplate('public:xfrm_res...', Array)
#9 src/XF/Mvc/Renderer/Html.php(50): XF\Template\Template->render()
#10 src/XF/Mvc/Dispatcher.php(471): XF\Mvc\Renderer\Html->renderView('XFRM:ResourceIt...', 'public:xfrm_res...', Array)
#11 src/XF/Mvc/Dispatcher.php(453): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#12 src/XF/Mvc/Dispatcher.php(412): XF\Mvc\Dispatcher->renderReply(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#13 src/XF/Mvc/Dispatcher.php(66): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
#14 src/XF/App.php(2826): XF\Mvc\Dispatcher->run()
#15 src/XF.php(806): XF\App->run()
#16 index.php(23): XF::runApp('XF\\Pub\\App')
#17 {main}

Request state

array(4) {
["url"] => string(70) "/resources/wro-navi-remix-bundle-triple-threat-001-003.411/?fromcat=28"
["referrer"] => string(65) "https://www.superchunes.com/resources/categories/mixed-albums.12/"
["_GET"] => array(1) {
["fromcat"] => string(2) "28"
}
["_POST"] => array(0) {
}
}



and


Code:
Server error log

    TypeError: Template public:xfrm_resource_wrapper error: XF\Template\Templater::breadcrumbs(): Argument #1 ($crumbs) must be of type array, string given, called in /home/ljqmbq3g0d23/public_html/internal_data/code_cache/templates/l1/s117/public/xfrm_resource_wrapper.php on line 11 src/XF/Template/Templater.php:1941

    Generated by: Unknown account Sep 21, 2024 at 8:47 AM

Stack trace

#0 internal_data/code_cache/templates/l1/s117/public/xfrm_resource_wrapper.php(11): XF\Template\Templater->breadcrumbs('')
#1 src/XF/Template/Templater.php(1792): XF\Template\Templater->{closure}(Object(XenGenTr\XGTOnekSistemi\XF\Template\Templater), Array, NULL)
#2 src/addons/MaZ/AUN/XF/Template/Templater.php(39): XF\Template\Templater->renderTemplate('xfrm_resource_w...', Array, false, NULL)
#3 src/XF/Template/Templater.php(1154): MaZ\AUN\XF\Template\Templater->renderTemplate('public:xfrm_res...', Array, false)
#4 src/XF/Template/Templater.php(1815): XF\Template\Templater->applyWrappedTemplate('





    
    
    
        
...')
#5 src/addons/MaZ/AUN/XF/Template/Templater.php(39): XF\Template\Templater->renderTemplate('xfrm_resource_v...', Array, true, NULL)
#6 src/XF/Template/Template.php(24): MaZ\AUN\XF\Template\Templater->renderTemplate('public:xfrm_res...', Array)
#7 src/XF/Mvc/Renderer/Html.php(50): XF\Template\Template->render()
#8 src/XF/Mvc/Dispatcher.php(471): XF\Mvc\Renderer\Html->renderView('XFRM:ResourceIt...', 'public:xfrm_res...', Array)
#9 src/XF/Mvc/Dispatcher.php(453): XF\Mvc\Dispatcher->renderView(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#10 src/XF/Mvc/Dispatcher.php(412): XF\Mvc\Dispatcher->renderReply(Object(XF\Mvc\Renderer\Html), Object(XF\Mvc\Reply\View))
#11 src/XF/Mvc/Dispatcher.php(66): XF\Mvc\Dispatcher->render(Object(XF\Mvc\Reply\View), 'html')
#12 src/XF/App.php(2826): XF\Mvc\Dispatcher->run()
#13 src/XF.php(806): XF\App->run()
#14 index.php(23): XF::runApp('XF\\Pub\\App')
#15 {main}

Request state

array(4) {
  ["url"] => string(70) "/resources/wro-navi-remix-bundle-triple-threat-001-003.411/?fromcat=28"
  ["referrer"] => string(65) "https://www.superchunes.com/resources/categories/mixed-albums.12/"
  ["_GET"] => array(1) {
    ["fromcat"] => string(2) "28"
  }
  ["_POST"] => array(0) {
  }
}
 

Clement

Freaky Coder
Staff member
I am a bit surprised by the error as it's in the resource view.

You told me that the error disappears once you disable the add-on ?

Clément
 

anil

New Member
I am a bit surprised by the error as it's in the resource view.

You told me that the error disappears once you disable the add-on ?

Clément
yes, that's correct. But to explain a little further, it has to do with ADS being placed in resources. I have HTML images as ads ( Above resources ) that redirects to certain resources, when I click on one of the image, it doesn't take me to the resource. That's when the server error occurs. Only started happening when I decided to use this add-on again. After I disabled your add-on, it continues to work as normal and redirects with no issues.


Screenshot 2024-09-26 at 2.32.59 PM.png
 

anil

New Member
No. The addon is causing the error to trigger when clicking the ads/images. A bug somewhere in your add-on, is causing links in resources section not to redirect. The images are linked to resources. If i click one of the images, its suppose to redirect me to a resource, but the addon is causing it not to redirect and triggers the server error you see there.
 

Clement

Freaky Coder
Staff member
The error does not popup for other resources inside the category ?

How are your ads shown there ?

If they are added to the xfrm_resource_list_macros with the exact same link syntax start:
<a href="{{ link('resources', $resource) }}" class="" data-tp-primary="on">

Then I won't be able to provide a fix.
You will need to either modify the way your ads are integrated or change the template modifications order of the things that adds the ads.
 

anil

New Member
The error does not popup for other resources inside the category ?

How are your ads shown there ?

If they are added to the xfrm_resource_list_macros with the exact same link syntax start:


Then I won't be able to provide a fix.
You will need to either modify the way your ads are integrated or change the template modifications order of the things that adds the ads.
Its entered the basic way. ACP>Setup>Advertising ......using the position " Resource overview - Above featured resource " . Using basic Html.

Screenshot 2024-09-27 at 11.02.30 AM.png
 

anil

New Member
Ah great, you changed the effective link ?
No, not necessarily, But I did notice that the URL that the resources were giving always ended in " ?fromcat=X "

Screenshot 2024-09-27 at 11.50.29 AM.png

But this only occurs when I'm clicking on my " premium " resources, I have about 8 premium resources. Which is why I put them up as ads.

So I said let me try removing "?fromcat=X" because they're all in 2 different categories " bundles & collections ", maybe that's why XFRM automatically generates "?fromcat=X" at the end?.

But anyways, its solved the issue for me and everything works fine now. But nevertheless, It was always working fine up until your add-on, so something in your add-on is causing it not to read that extra part correctly " ?fromcat=X ".

I'm not familiar with dev talk or technically inclined by any means but from what I've been exposed to on XF forums for a brief time, its seems to be a parsing issue when dealing with XFRM links generated because of different categories.


Also, thanks for taking the time for responding to the issues. I may have some work for you and I'll let you know when i'm ready.
 

anil

New Member
My add-on adds fromcat to the url yes but only in the resource list.

Sure let me know.
I agree. The only thing that seemed to be triggering it is when its being clicked via HTML, not XFRM itself.

but yeah, reguarding what I eventually want, I want my latest resources that I upload, to be shown on a new page in a grid style format, But only the images alone (my images are inserted via links)

see: https://xenforo.com/community/threads/my-ultimate-home-page-paid.218649/
 
Top