Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Override for view.feed.php throws error #18

Open
vdrover opened this issue Sep 7, 2016 · 2 comments
Open

Override for view.feed.php throws error #18

vdrover opened this issue Sep 7, 2016 · 2 comments

Comments

@vdrover
Copy link

vdrover commented Sep 7, 2016

I am trying to override com_content/views/category/view.feed.php, but each time I do, i get an error. Here are the details:

  1. install Joomla 3.6.2 ,no sample content.
  2. Install MVC Override plugin and enable.
  3. Create an article in the Uncategorized category. Be sure to specify one of the stock joomla images as both intro image and fulltest image.
  4. Change the homepage menu item to a category blog.
  5. Create an MVC override in the template here (just use the original core file as the override): protostar/code/com_content/views/category/view.feed.php
  6. View the RSS feed of the homepage. It looks fine. /index.php?format=feed&type=rss
  7. Now just view the homepage (index.php) and you'll see an error:

Class 'JFeedItem' not found.

Depending on PHP version, u may see more details:

Fatal error: Class 'JFeedItem' not found in /Applications/MAMP/htdocs/overridetests/libraries/legacy/view/categoryfeed.php on line 103

@ghazal
Copy link
Owner

ghazal commented Sep 8, 2016

No solution found but I just compared :
/components/com_content/views/category/view.feed.php
and
/components/com_content/views/featured/view.feed.php

and there is actually no call to 'JFeedItem' class in:
category/view.feed.php

as there is in (line+-65):
featured/view.feed.php

// Load individual item creator class
$item           = new JFeedItem;
...

I guess you'll have to find a way around this.

@vdrover
Copy link
Author

vdrover commented Sep 18, 2016

I did some more investigating. I was working with RedComponents MVC plugin and posted the solution there: redCOMPONENT-COM/mvcOverride#17

A similar fix should work for this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants