- Posts: 15920
COMMUNITY FORUM
- Forum
- K2 Community Forum
- English K2 Community
- [SOLVED] Premium Content Items Invisible IF Not Logged In
[SOLVED] Premium Content Items Invisible IF Not Logged In
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
7 years 1 month ago #164666
by Krikor Boghossian
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Krikor Boghossian on topic Premium Content Items Invisible IF Not Logged In
Did you specify the full text in the item's editor?
If the full text is not specified (either with the read more button or by using two separate editors) the entire text is treated as the introtext.
If the full text is not specified (either with the read more button or by using two separate editors) the entire text is treated as the introtext.
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Chris Hogan
- Offline
- Premium Member
Less
More
- Posts: 80
7 years 1 month ago #164669
by Chris Hogan
Replied by Chris Hogan on topic Premium Content Items Invisible IF Not Logged In
Yes all my news items have intro text setup in the K2 editor with a 'read more' button separator...
I believe its more of an issue with the links on news stories 'images' and 'titles' (in a category view) which is bypassing the normal page layout (and login procedure)
Because before the K2/Joomla update, the modified item.php (we worked on) would send users that clicked on a stories 'image' or 'title' directly to the stories page, BUT only the 'intro text' would appear with a similar 'register to login' link - which which was setup in the revised item.php
I believe its more of an issue with the links on news stories 'images' and 'titles' (in a category view) which is bypassing the normal page layout (and login procedure)
Because before the K2/Joomla update, the modified item.php (we worked on) would send users that clicked on a stories 'image' or 'title' directly to the stories page, BUT only the 'intro text' would appear with a similar 'register to login' link - which which was setup in the revised item.php
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
- Posts: 15920
7 years 1 month ago #164697
by Krikor Boghossian
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Krikor Boghossian on topic Premium Content Items Invisible IF Not Logged In
Can you send me the entire item.php file through pastebin or github?
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Chris Hogan
- Offline
- Premium Member
Less
More
- Posts: 80
7 years 1 month ago #164715
by Chris Hogan
Replied by Chris Hogan on topic Premium Content Items Invisible IF Not Logged In
Hi there,
I've added to GitHub under the same subject title as this post:
gist.github.com/chrisvphogan/81a710f178c8cb075f75a0ff2c6f2769
Thanks!
I've added to GitHub under the same subject title as this post:
gist.github.com/chrisvphogan/81a710f178c8cb075f75a0ff2c6f2769
Thanks!
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
- Posts: 15920
7 years 1 month ago #164724
by Krikor Boghossian
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Krikor Boghossian on topic Premium Content Items Invisible IF Not Logged In
gist.github.com/chrisvphogan/81a710f178c8cb075f75a0ff2c6f2769#file-item-php-L228
The check will only be performed if a fulltext is present. Can you remind me the URL of your site?
The check will only be performed if a fulltext is present. Can you remind me the URL of your site?
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Chris Hogan
- Offline
- Premium Member
Less
More
- Posts: 80
7 years 1 month ago #164726
by Chris Hogan
Replied by Chris Hogan on topic Premium Content Items Invisible IF Not Logged In
Hi, the site url is www.ourdogsinternational.com
Please Log in or Create an account to join the conversation.
- Chris Hogan
- Offline
- Premium Member
Less
More
- Posts: 80
7 years 1 month ago #164831
by Chris Hogan
Replied by Chris Hogan on topic Premium Content Items Invisible IF Not Logged In
Hi there, did you manage to check out the site?
Please Log in or Create an account to join the conversation.
- Krikor Boghossian
- Offline
- Platinum Member
Less
More
- Posts: 15920
7 years 1 month ago #164891
by Krikor Boghossian
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Replied by Krikor Boghossian on topic Premium Content Items Invisible IF Not Logged In
Can you enable (temporarily) the ?template= query string?
JoomlaWorks Support Team
---
Please search the forum before posting a new topic :)
Please Log in or Create an account to join the conversation.
- Chris Hogan
- Offline
- Premium Member
Less
More
- Posts: 80
6 years 9 months ago - 6 years 9 months ago #166798
by Chris Hogan
Replied by Chris Hogan on topic Premium Content Items Invisible IF Not Logged In
Hi there,
I never actually managed to fix this issue; which was to get a guest to see the login message below IF THEY CLICK A ITEMS IMAGE OR THE TITLE OF THE ITEM.
Below is the code if you can have a look....as I'm not sure what the last post meant by " enable (temporarily) the ?template= query string? " But in the meantime could you tell me how to remove the link on a item image!
I never actually managed to fix this issue; which was to get a guest to see the login message below IF THEY CLICK A ITEMS IMAGE OR THE TITLE OF THE ITEM.
Below is the code if you can have a look....as I'm not sure what the last post meant by " enable (temporarily) the ?template= query string? " But in the meantime could you tell me how to remove the link on a item image!
<?php if($this->item->params->get('itemIntroText')): ?>
<!-- Item introtext -->
<div class="itemIntroText">
<?php echo $this->item->introtext; ?>
</div>
<?php endif; ?>
<?php
if($this->item->params->get('itemFullText')):
$user = JFactory::getUser();
if ($user->guest) {
echo '<a href="https://ourdogsinternational.com/index.php/join-now">You must login to see the content!</a>';
} else {
if(!empty($this->item->fulltext)): ?>
<!-- Item Full text -->
<div class="itemFullText">
<?php echo $this->item->fulltext; ?>
</div>
<?php else: ?>
<!-- Item text -->
<div class="itemFullText">
<?php echo $this->item->introtext; ?>
</div>
<?php endif; ?>
<?php } ?>
<?php endif; ?>
<div class="clr"></div>
Last edit: 6 years 9 months ago by Chris Hogan.
Please Log in or Create an account to join the conversation.
- Chris Hogan
- Offline
- Premium Member
Less
More
- Posts: 80
6 years 8 months ago #166846
by Chris Hogan
Replied by Chris Hogan on topic Premium Content Items Invisible IF Not Logged In
Any advice on how to remove the link on a item image is welcome please!
Please Log in or Create an account to join the conversation.
- Forum
- K2 Community Forum
- English K2 Community
- [SOLVED] Premium Content Items Invisible IF Not Logged In