Hello!
I try to override generic.php file, which is located inside of my template, in templates/my_template/html/com_k2/generic.php.
Output of both rating with
I try to override generic.php file, which is located inside of my template, in templates/my_template/html/com_k2/generic.php.
Output of both rating with
13 years 9 months ago #109481
Hi,
Do you mean your override file is not used or what you've added is not displayed ?
You generic.php file override is correctly placed, so the problem is not here.
Olivier
Do you mean your override file is not used or what you've added is not displayed ?
You generic.php file override is correctly placed, so the problem is not here.
Olivier
Topic Author
13 years 9 months ago #109482
Second - i include rating and extra fields into generic.php as described and get in the frontend nothing of rating and extra field values. Extrafields show is setted to on in the search settings of K2.
So i don't really know, is it possible at all without hack, at the user template level (through override) to show extrafields values in generic.php
So i don't really know, is it possible at all without hack, at the user template level (through override) to show extrafields values in generic.php
13 years 9 months ago #109483
Item rating and extrafields are not loaded for the generic view.
It you want to do this, you'll have to add the code that retrieves these information in your generic.php override. It's not MVC compliant but i think it's the only situation as K2 plugins are not implemented on generic view neither.
You can find the code for this on the models/item.php file in the prepareItem() function.
It you want to do this, you'll have to add the code that retrieves these information in your generic.php override. It's not MVC compliant but i think it's the only situation as K2 plugins are not implemented on generic view neither.
You can find the code for this on the models/item.php file in the prepareItem() function.
Topic Author
13 years 9 months ago #109484
Thanks! I was successful by including of tags into generic.php. But by including of rating and extra fields i fail. Would you please help me with?
Here is the code includign tags into generic.php for those who is looking for:) Add this to your generic.php at the place, where you want see your tags. They will appear like unordered list
Here is the code includign tags into generic.php for those who is looking for:) Add this to your generic.php at the place, where you want see your tags. They will appear like unordered list
Log in or create an account to reply.