-
AuthorPosts
-
michaelsteip Friend
michaelsteip
- Join date:
- November 2012
- Posts:
- 16
- Downloads:
- 0
- Uploads:
- 5
- Thanks:
- 4
- Thanked:
- 1 times in 1 posts
November 20, 2012 at 9:00 am #182413Hello,
I am trying to get a custom Link on JA Side News on my website http://www.steip.at/testenvironment/test/final_draft/. I don’t want the Link to go to the article, I want it to go to an external Website.How do I do this?
Thanks,
MichaelLuna Garden ModeratorLuna Garden
- Join date:
- July 2011
- Posts:
- 2617
- Downloads:
- 80
- Uploads:
- 96
- Thanks:
- 78
- Thanked:
- 453 times in 425 posts
November 21, 2012 at 4:03 am #473723Hi,
To change the link of each item of JA Side News Module, there is a way in doing so. However, by doing this, every item article only redirect to one external link.
please go to:
templatesja_mixmazhtmlmod_jasidenewsdefault.php
Find these lines:
<div class="ja-slidenews-item">
<?php if( $showimage ): ?>
<?php echo $helper->renderImage ($item, $params, $descMaxChars, $iwidth, $iheight ); ?>
<?php endif; ?><div class="ja-item-content">
<?php if (isset($item->date)) : ?>
<span class="ja-createdate"><?php echo JHTML::_('date', $item->date, JText::_('DATE_FORMAT_LC4')); ?></span>
<?php endif; ?><h4 class="item-title">
<a class="ja-title" href="<?php echo $item->link; ?>"><?php echo $helper->trimString( $item->title, $titleMaxChars );?></a>
</h4><?php if ($descMaxChars!=0) : ?>
<p class="item-desc"><?php echo $helper->trimString( strip_tags($item->introtext), $descMaxChars); ?></p>
<?php endif;?><?php if( $showMoredetail ) : ?>
<a class="readon" href="<?php echo $item->link; ?>"> <?php echo JTEXT::_("MORE_DETAIL"); ?></a>
<?php endif;?></div>
Replace red text with your custom link
dpchap015 Frienddpchap015
- Join date:
- September 2011
- Posts:
- 300
- Downloads:
- 75
- Uploads:
- 57
- Thanks:
- 1
- Thanked:
- 24 times in 1 posts
January 8, 2013 at 9:51 am #478898Hi, i have a similar issue. I am using Mero template.
Please see the image attached.
I wish to redirect in the following way.10) No redirection
11) Redirect to external link1.
12) Redirect to external link2.How do i do this. As the post says this will redirect all the articles to the same External URL if i follow @luna Garden.
January 8, 2013 at 10:55 am #478910Hi,
I have also a problem with JA Sidenews. When I push the more detail link, the text will appear under de module and not in a new window. How can I fix this…I just want to open my new article in a new window and not under my items. Please can you help me…
dpchap015 Frienddpchap015
- Join date:
- September 2011
- Posts:
- 300
- Downloads:
- 75
- Uploads:
- 57
- Thanks:
- 1
- Thanked:
- 24 times in 1 posts
January 8, 2013 at 11:24 am #478916Is this possible.
in the code editing suggested by @luna Garden
[PHP]<h4 class=”item-title”>
<a class=”ja-title” href=”<?php echo $item->link; ?>”><?php echo $helper->trimString( $item->title, $titleMaxChars );?></a>
</h4><?php if ($descMaxChars!=0) : ?>
<p class=”item-desc”><?php echo $helper->trimString( strip_tags($item->introtext), $descMaxChars); ?></p>
<?php endif;?><?php if( $showMoredetail ) : ?>
<a class=”readon” href=”<?php echo $item->link; ?>”> <?php echo JTEXT::_(“MORE_DETAIL”); ?></a>
<?php endif;?>[/PHP]if i replace the code [PHP]<?php echo $item->link; ?>[/PHP] with a if statement and make it look somewhat like this=>
if(article_id=1)
redirect=”#”
else
if(article_id=2)
redirect=”external link1″
else
if(article_id=3)
redirect=”external link2″
else
redirect=”<?php echo $item->link; ?>”will this resolve my issue.?
dpchap015 Frienddpchap015
- Join date:
- September 2011
- Posts:
- 300
- Downloads:
- 75
- Uploads:
- 57
- Thanks:
- 1
- Thanked:
- 24 times in 1 posts
January 8, 2013 at 11:27 am #478917<em>@stormid 354072 wrote:</em><blockquote>Hi,
I have also a problem with JA Sidenews. When I push the more detail link, the text will appear under de module and not in a new window. How can I fix this…I just want to open my new article in a new window and not under my items. Please can you help me…
</blockquote>You can try changing this a little more
<blockquote>Hi,
To change the link of each item of JA Side News Module, there is a way in doing so. However, by doing this, every item article only redirect to one external link.
please go to:
Code:
templatesja_mixmazhtmlmod_jasidenewsdefault.php
Find these lines:
Code:
<div class=”ja-slidenews-item”><?php if( $showimage ): ?>
<?php echo $helper->renderImage ($item, $params, $descMaxChars, $iwidth, $iheight ); ?>
<?php endif; ?><div class=”ja-item-content”>
<?php if (isset($item->date)) : ?>
<span class=”ja-createdate”><?php echo JHTML::_(‘date’, $item->date, JText::_(‘DATE_FORMAT_LC4’)); ?></span>
<?php endif; ?><h4 class=”item-title”>
<a class=”ja-title” href=”<?php echo $item->link; ?>”><?php echo $helper->trimString( $item->title, $titleMaxChars );?></a>
</h4><?php if ($descMaxChars!=0) : ?>
<p class=”item-desc”><?php echo $helper->trimString( strip_tags($item->introtext), $descMaxChars); ?></p>
<?php endif;?><?php if( $showMoredetail ) : ?>
<a class=”readon” href=”<?php echo $item->link; ?>”> <?php echo JTEXT::_(“MORE_DETAIL”); ?></a>
<?php endif;?></div>
Replace red text with your custom link</blockquote>Try changing this line
<a class="ja-title" href="<?php echo $item->link; ?>">
to
<a target="_new" class="ja-title" href="<?php echo $item->link; ?>">
January 8, 2013 at 11:44 am #478923No it doesn’t work…
When I look at the demo site from JA_University the module works fine, but in my site it doesn’t…I don’t now why. I also use this module in anouther template (Mendozite) and I have the same problem there. Maybe I didn’t configure it right?
Ninja Lead ModeratorNinja Lead
- Join date:
- November 2014
- Posts:
- 16064
- Downloads:
- 310
- Uploads:
- 2864
- Thanks:
- 341
- Thanked:
- 3854 times in 3563 posts
January 9, 2013 at 11:12 am #479074<em>@stormid 354072 wrote:</em><blockquote>Hi,
I have also a problem with JA Sidenews. When I push the more detail link, the text will appear under de module and not in a new window. How can I fix this…I just want to open my new article in a new window and not under my items. Please can you help me…
</blockquote>
I would need to take a closer look at your site. I tried to access this link on your attachment file but no success: cbkontwlkkel.tmp.remote.nl, please send me url on your siteMarch 27, 2013 at 9:51 pm #488047Hi,
I have the same problem as stormid. With JA Sidenews on Mixmaz template. Clicking the title the article appears under the whole module on the home page but not in a new layout with only the final article.
Could you help me?
Thank you.Ninja Lead ModeratorNinja Lead
- Join date:
- November 2014
- Posts:
- 16064
- Downloads:
- 310
- Uploads:
- 2864
- Thanks:
- 341
- Thanked:
- 3854 times in 3563 posts
March 28, 2013 at 8:43 am #488126<em>@evacm 366515 wrote:</em><blockquote>Hi,
I have the same problem as stormid. With JA Sidenews on Mixmaz template. Clicking the title the article appears under the whole module on the home page but not in a new layout with only the final article.
Could you help me?
Thank you.</blockquote>You can try this way
In Joomla, if you want to view article individually, that article must be assigned to a menu item.
Pls create a new menu item (or use an existing one) and assign article (or category that article belongs to) to this new menu item and also make sure that you don’t assign any module to this menu item.
Let me know if it helps.
1 user says Thank You to Ninja Lead for this useful post
March 28, 2013 at 12:26 pm #488165That was it.
Thank you Ninja Lead.December 22, 2013 at 11:29 am #516160<em>@Ninja Lead 366599 wrote:</em><blockquote>You can try this way
In Joomla, if you want to view article individually, that article must be assigned to a menu item.
Pls create a new menu item (or use an existing one) and assign article (or category that article belongs to) to this new menu item and also make sure that you don’t assign any module to this menu item.
Let me know if it helps.</blockquote>
Is there any way to link to an internal URL or a a category-overview?
I want to use the look of mero-homepage-grid to link to 3 main-categories (K2) of main menu.
See rudimentary screenshotThis means, I cannot use Luna Gardens solution because I don’t want any Sidenews-content to be linked to one URL.
http://www.joomlart.com/forums/topic/ja-side-news-redirect-to-custom-link/I would also not fear of messing around in code, because this would be a one-time-work.
Or is it possible to use another module and just the look of JA Sidenews?
I am not a pro, but I guess no!?thx for any help in advance.
Luna Garden ModeratorLuna Garden
- Join date:
- July 2011
- Posts:
- 2617
- Downloads:
- 80
- Uploads:
- 96
- Thanks:
- 78
- Thanked:
- 453 times in 425 posts
December 23, 2013 at 11:02 am #516277Hello,
You can try this:
1. Go to file:
modulesmod_jasidenewshelper.php
find this line:
$item->link = urldecode(JRoute::_(K2HelperRoute::getItemRoute($item->id . ':' . urlencode($item->alias), $item->catid . ':' . urlencode($item->categoryalias))));
then change to:
$item->link = urldecode(JRoute::_(K2HelperRoute::getCategoryRoute($item->catid . ':' . urlencode($item->categoryalias))));
$item->title = $item->categoryname;
and find these lines:
$item->link = JRoute::_(ContentHelperRoute::getArticleRoute($item->slug, $item->catslug));
change to:
$item->link = urldecode(JRoute::_(K2HelperRoute::getCategoryRoute($item->catid . ':' . urlencode($item->categoryalias))));
$item->title = $item->categoryname;
Those change will take affect to JA Sidenew on your site.
2. go to file:templatesja_merohtmlmod_jasidenewssidenews_content.php
Remove this line:
<?php echo $helper->trimString( strip_tags($item->introtext), $descMaxChars); ?>
Remember to back up your file before processing
December 24, 2013 at 5:33 pm #516432thanks your answer!
I’ll give it a try!AuthorPostsViewing 14 posts - 1 through 14 (of 14 total)This topic contains 14 replies, has 7 voices, and was last updated by humerf 10 years, 10 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Jump to forum