-
AuthorPosts
-
March 12, 2014 at 3:01 pm #195721
Hello!
I just managed to link the images in the newspro-modul on the frontpage on our website http://www.prost-magazin.at.
But if i go to a category, like this one the images are still not linked.Can anyone point me out where to change that? Please 🙂 I cant find it..
Thank you!
Pankaj Sharma ModeratorPankaj Sharma
- Join date:
- February 2015
- Posts:
- 24589
- Downloads:
- 144
- Uploads:
- 202
- Thanks:
- 127
- Thanked:
- 4196 times in 4019 posts
timtecsa Friendtimtecsa
- Join date:
- October 2009
- Posts:
- 1382
- Downloads:
- 86
- Uploads:
- 327
- Thanks:
- 197
- Thanked:
- 132 times in 34 posts
March 13, 2014 at 8:08 pm #526640http://www.joomlart.com/forums/topic/image-intro-article-with-link-url/#poststop
It worked for me 🙂
Pankaj Sharma ModeratorPankaj Sharma
- Join date:
- February 2015
- Posts:
- 24589
- Downloads:
- 144
- Uploads:
- 202
- Thanks:
- 127
- Thanked:
- 4196 times in 4019 posts
March 14, 2014 at 5:39 am #526676Glad you solved it 🙂
If you any problem you can post Here.Nazario A FriendNazario A
- Join date:
- April 2013
- Posts:
- 1183
- Downloads:
- 0
- Uploads:
- 406
- Thanks:
- 91
- Thanked:
- 284 times in 263 posts
March 14, 2014 at 7:54 am #526697By default, when you go to a category, it will show the article in this category, not in the News Pro module. This image was loaded from the article. If you want to click the image, it will go to the article that you can add the <a> tag in the article.
Add the code in red red as follows:
<blockquote><div><a href=”index.php/sport/sport-news/football/120-834956731″><img class=”caption” src=”images/stories/demo/sport/football-7.jpg” border=”0″ alt=”Sample image” title=”Sample image” align=”left” /></a></div></blockquote>Hope this helps.
March 14, 2014 at 11:51 am #526730Nazario, you are right, if i link the image in the article, it also links the image in the category.
But that would be a lot of work to do that manually for every article…
Does anyone have an idea how to integrate that automatically?Thanks timtecsa and pankajsharma21 – i tried the suggestions in the other thread, but nothing changed..
Nazario A FriendNazario A
- Join date:
- April 2013
- Posts:
- 1183
- Downloads:
- 0
- Uploads:
- 406
- Thanks:
- 91
- Thanked:
- 284 times in 263 posts
March 17, 2014 at 7:53 am #526899Hope this thread can help you: http://www.joomlart.com/forums/topic/image-intro-article-with-link-url/#post-524250
Pankaj Sharma ModeratorPankaj Sharma
- Join date:
- February 2015
- Posts:
- 24589
- Downloads:
- 144
- Uploads:
- 202
- Thanks:
- 127
- Thanked:
- 4196 times in 4019 posts
March 17, 2014 at 5:44 pm #527014@amedien I have fixed it directly on your site.
in templatesja_teline_iv_t3htmlcom_contentcatego ryblog_item.php
I replaced this code [PHP]<?php if (isset($images->image_intro) and !empty($images->image_intro)) : ?>
<?php $imgfloat = (empty($images->float_intro)) ? $params->get(‘float_intro’) : $images->float_intro; ?>
<div class=”pull-<?php echo htmlspecialchars($imgfloat); ?>”> <img
<?php if ($images->image_intro_caption):
echo ‘class=”caption”‘.’ title=”‘ .htmlspecialchars($images->image_intro_caption) .'”‘;
endif; ?>
src=”<?php echo htmlspecialchars($images->image_intro); ?>” alt=”<?php echo htmlspecialchars($images->image_intro_alt); ?>”/> </div>
<?php endif; ?>[/PHP]
Into
[PHP]<a href=”<?php echo JRoute::_(ContentHelperRoute::getArticleRoute($this->item->slug, $this->item->catid)); ?>”>
<?php if (isset($images->image_intro) and !empty($images->image_intro)) : ?>
<?php $imgfloat = (empty($images->float_intro)) ? $params->get(‘float_intro’) : $images->float_intro; ?>
<div class=”pull-<?php echo htmlspecialchars($imgfloat); ?>”> <img
<?php if ($images->image_intro_caption):
echo ‘class=”caption”‘.’ title=”‘ .htmlspecialchars($images->image_intro_caption) .'”‘;
endif; ?>
src=”<?php echo htmlspecialchars($images->image_intro); ?>” alt=”<?php echo htmlspecialchars($images->image_intro_alt); ?>”/> </div>
<?php else:
$regex = “/<img[^>]*>/”;
$image = ”;
if (preg_match_all($regex,$this->item->introtext, $matches)) {
$this->item->introtext = preg_replace ($regex, ”, $this->item->introtext);
$image = implode (“n”, $matches[0]);
}
?>
<?php if ($image): ?>
<div class=”pull-“><?php echo $image ?></div>
<?php endif; ?><?php endif; ?>
</a>[/PHP]1 user says Thank You to Pankaj Sharma for this useful post
March 18, 2014 at 7:05 am #527103superb! thank you so much pankajsharma21 – works like a charm! :):):)
AuthorPostsViewing 9 posts - 1 through 9 (of 9 total)This topic contains 9 replies, has 4 voices, and was last updated by amedien 10 years, 8 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Link images in category-overview.
Viewing 9 posts - 1 through 9 (of 9 total)