Keyword

[Problem] K2 component / item list in item error

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
12 years 6 hours ago - 12 years 2 hours ago #114081 by Patrick
Hello

I have a problem with a component K2 once to display the list of articles / news on the site.

I made ​​TOP MENU to link to a specific article in K2 named "News" and in that article, this component is displayed.

www.bikebydgoszcz.pl/aktualnosci

When I enter that in any sample article

www.bikebydgoszcz.pl/aktualnosci/test-artykul-k2

As you can see above the article (headline of the article) you can see a list of articles / news

How do I turn it off to in the articles do not show it?


At the below given link. K2 component is added to an article in Joomla, not in the component K2. It's okey.

www.bikebydgoszcz.pl/team

the difference is that he changed the URL (/ somponent/k2 /)

www.bikebydgoszcz.pl/component/k2/test-artykul-k2

Attachment not found




Best regards and im waiting for quick replay.

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114082 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
The module with the Id 97 renders on top of your item. This has to do with your template.

You need to alter your template's index.php and exclude the position in which the module renders from items.

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114083 by Patrick
Hi.

Thank you for your answer. Could you explain little bit more how can i solve it ?
Should i paste here index.php my template ?

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114084 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
I don't think that would do it.

You might have to alter a couple of files depending on your template.

You need some variables (look if they are already defined in your template)
Log in  or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114085 by Patrick
Where, which file. I cant find...

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114086 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error

You need to alter your template's index.php and exclude the position in which the module renders from items.


You can find which module position to hide from the backend. Just see in which position this module is rendered.

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114087 by Patrick
Hi

I have user2 position in my template
wklej.org/id/1063825/

I don't know where type your code... Could you help me, navigate where ?

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114088 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
Insert the variables $option and $view at line 29 approx. and before the closing ?> tag.

Then go to the module position you want (user 2 in this case) and change
Log in  or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114089 by Patrick
Hello

Still the same ...

www.bikebydgoszcz.pl/aktualnosci/test-artykul-k2
In article i can see items list on top


wklej.org/id/1064052/

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114090 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error

Insert the variables $option and $view at line 29 approx. and before the closing ?> tag.


Seems you forgot that part.

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114091 by Patrick
When i added at line 29 and 30
Parse error: syntax error, unexpected '$view' (T_VARIABLE) in /home/rufik/public_html/bikebydgoszcz.pl/public_html/templates/joomspirit_76/index.php on line 30


Could you prepare for me complete code becasue i don't know where i should add it...

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114092 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
I think I didn't make my self clear about this.

$option = JRequest::getCmd('option');
$view = JRequest::getCmd('view');

(See the first code snippet I posted.) Insert them before JHtml::_('behavior.framework', true);
?>

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114093 by Patrick
Hi

I see progress :)

www.bikebydgoszcz.pl/aktualnosci/kolejny-testowy-artykulik-aktualnosci

Now top items list gone inside article. Great.

BUT now when i want to see all articles on my website

www.bikebydgoszcz.pl/aktualnosci

I see nothing (this is placed ass K2 single article when i placed K2 component)

How to fix it, how to show items list ?

Below is my index.php from template

wklej.org/id/1064477/

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114094 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
Yes I see...

This code will exclude the module from ALL items, even if they belong directly to a menu item.

I have an easier solution for this one.

Create a new module position above or right after user-2 called aktualnosci-header or something like that will help you remember the position.

Publish a module there ONLY in your homepage or where you need it to be. If you have correctly setup your menus you will not see the module anywhere else.

This way you have two module positions, one specific (aktualnosci-header) and one more generic (user-2) which will never render inside K2 items.

PS. here is the snippet as well.
Log in  or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114095 by Patrick
Hi

Just by th way. Do you have skype ?

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago - 11 years 11 months ago #114096 by Patrick
mine is: rufi1986

Im trying to do ... hmm

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago #114097 by Patrick
Krikor Boghossian could you tell me step by step how to prepare that module

Because i created new module called "aktualnosci-heade" in position aktualnosci-header

www.bikebydgoszcz.pl/index.php?tp=1&template=joomspirit_76

And whats next ? It is ok ?

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114098 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
Sorry I just saw your post,

Unfortunately we do not offer Skype support.

I can see the position. I think you got it. You now need to publish a module only in the menu items you wish for it to appear.

Please Log in or Create an account to join the conversation.

  • Patrick
  • Patrick's Avatar Topic Author
  • Offline
  • New Member
More
11 years 11 months ago - 11 years 11 months ago #114099 by Patrick
Im able to give access to my website, lets talk about 10 min i think i need 10 min and problem will be solved so speak to me via skype :)


Attachment not found



Attachment not found



Attachment not found



And resoult is
www.bikebydgoszcz.pl/aktualnosci

Hmm i dont know maybe i made somewhere mistake...
Attachments:

Please Log in or Create an account to join the conversation.

  • Krikor Boghossian
  • Krikor Boghossian's Avatar
  • Offline
  • Platinum Member
More
11 years 11 months ago #114100 by Krikor Boghossian
Replied by Krikor Boghossian on topic Re: [Problem] K2 component / item list in item error
Patrick you certainly have a point here but I cannot post my personal Skype account on this forum for obvious reasons.

PS. I ve met a lot of Poles but my Polish is very bad to say at least, so be lenient if I got something wrong.

For what I can make of your screenshots you published a menu module on your user3 module position which had a fixed width. All these widths are produced from custom variables on your template. Notice $user3_width.

I am sure the template developer will be able to provide you with a better solution since he is the one who developed the template. Be sure to show him this thread and he will know exactly how to help you.

Please Log in or Create an account to join the conversation.