[SOLVED] New param

News Show Pro GK5 - flexible, responsive and easily extendable free Joomla module support forum.
Rate this topic: Evaluations: 0, 0.00 on the average.Evaluations: 0, 0.00 on the average.Evaluations: 0, 0.00 on the average.Evaluations: 0, 0.00 on the average.Evaluations: 0, 0.00 on the average.Evaluations: 0, 0.00 on the average.
GK User
Thu Feb 18, 2016 7:05 pm
HI,

I've setup a subtitle for K2 and it shows correctly in category view and item view changing k2 template with: <?php echo $this->item->params->get('itemSubtitle'); ?> and changing item.xml file in k2 admin folder.

Now I want to add this param to NSP but I can't find the way to add it.

Any clue?

Thx!!
User avatar
Senior Boarder

GK User
Mon Feb 22, 2016 8:50 pm
Hello,

Unfortunately NSP GK5 supports only Extra Fields as an additional fields of K2 items, and the Extra Fields are supported only with the custom Article Formats in NSP GK5 module.
User avatar
Moderator

GK User
Tue Feb 23, 2016 9:13 am
Hi & thank you, but can you tell me how NSP gets itemTitle var from param so I can try to reproduce it with the subtitle?
User avatar
Senior Boarder

GK User
Tue Feb 23, 2016 9:45 am
I am not sure how K2 will store your newly added param - please check it in your database through phpMyAdmin.

The NSP GK5 module outputs the content using this file: https://github.com/GavickPro/News-Show- ... 2/view.php

And the data from DB are retrieved in this file: https://github.com/GavickPro/News-Show- ... /model.php
User avatar
Moderator

GK User
Tue Feb 23, 2016 10:35 am
I've set the new param adding these lines to item.xml:

Code: Select all
<param name="itemSubtitle" type="text" default="" size="20" label="itemSubtitle" description="Subtitle" />
<field name="itemSubtitle" type="text" default="" size="4" label="Subtitulo" description=""/>


I've check the BD with phpMyAdmin and the data is save under param tag "itemSubtitle".

Also review both files you said but can't find for example any word like "itemTitle" so i can duplicate with "itemSubitle" :(
User avatar
Senior Boarder

GK User
Tue Feb 23, 2016 1:39 pm
You cannot find itemTitle, because it is read from the title field in DB. This value is used in the header function at the view.php file. In fact adding this kind of changes is a custom work beyond of our technical support. If you are not feeling comfortable with making this kind of changes, please contact with guys from http://tidycustoms.net/ for help.
User avatar
Moderator


cron