Login or create new account.

By registering on joomprod.com, you will have immediate access to all our free products and to the public side of our support forum.

Enjoy our subscriptions.

Each of our subscriptions allow you to enjoy the private side of the support forum and all the update of our products for a period ranging from 3 months to 1 year.

Payment And immediate download.

After subscribing to one of our subscription, the products are immediately downloadable.

Login

Or Register
Accueil / forum / Support / AdsManager Support / [RESOLVE] How to hide image & description preview

Support Availability Because we must sleep sometimes

Working days: Monday to Friday.
Reply time: Depending on the complexity of your support issue it's usually between a few hours to 48 hours.

Support is only guaranteed to paid subscribers

AdsManager - End of life

It is with great regrets that we have chosen to end the developpement of Adsmanager and its other associated components.

AdsManager is born 10 years ago and, as of today, the number of new subscriptions and downloads have fallen and we cannot maintain the component anymore.

All active subscribers will be able to continue enjoying support until the end of their subscription.

The components will be free and no support will be provided anymore for the other users.

×

Notice

The forum is in read only mode.

[RESOLVE] How to hide image & description preview

More
10 years 6 months ago #19952 by loic
Hello,

Usually, the image is not displayed if it is the default one.

Best regards.
The following user(s) said Thank You: adarr
More
10 years 6 months ago #19990 by hadia9683
Replied by hadia9683 on topic How to hide image and description preiview
Sorry i did not get you.

I applied this code, images still showing in ads manager list.
The following user(s) said Thank You: adarr
More
10 years 6 months ago #20013 by loic
Hello,

If you delete the category image in the backend and save the category, the image is still displayed ?

Best regards.
The following user(s) said Thank You: adarr
More
10 years 6 months ago #20107 by hadia9683
Replied by hadia9683 on topic How to hide image and description preiview
its not shwoing the category image, its showing the uploaded image with the ad.

I think might be i was not able to explain it correctly

Issue is, I have a categrory jobs . I want when user open ads of jobs in adsmanger list, only title of the ad with other details should be shown. No image preview should be shown in adsmanger list.
The following user(s) said Thank You: adarr
More
10 years 6 months ago #20113 by loic
Hello,

Ok, if I understand correctly, You just need to hide the ads images in the list for chosen categories.

You need to do some custom code for that. In 'templates/adsclarity/html/com_adsmanager/list/default_list.php' or default_grid.php (depending on the one you are using)

The images are displayed by this line :
if (isset($content->images[0])) {
                                                        <div class="row">
                                    <div class="col-md-12 adsListGridImage">
                                        <div class="adsListGridImageBg">
                                            <?php
								   				if (isset($content->images[0])) {
                                                        echo "<a href='".$linkTarget."'><img class='fad-image img-responsive' name='ad-image".$content->id."' src='".JURI_IMAGES_FOLDER."/".$content->images[0]->thumbnail."' alt=\"".htmlspecialchars($content->ad_headline)."\" /></a>";
								                } else if ($this->conf->nb_images > 0) {
                                                        echo "<a href='".$linkTarget."'><img class='fad-image img-responsive' src='".ADSMANAGER_NOPIC_IMG."' alt='nopic' /></a>";
								                }
                                                ?>
                                            <?php if (isset($content->ad_price)) {?>    
                                            <div class="col-md-4 adsListGridPrice">                                     
                                            <?php echo $this->field->showFieldValue($content,$this->fields['ad_price']);  ?>
                                            </div>
                                            <?php } ?>
                                        </div>
                                    </div>
                                </div>

To hide the images, you can do something like that:
<?php
if(!($content->catid == 12 || $content->catid == 13 || $content->catid == 14)) {
    //The code that display the images
}
?>

Add one condition for each categories that don"t need to display the images.

For the description, you just have to change te number in those lines :
$content->ad_text = strip_tags(str_replace ('<br />'," ",$content->ad_text));
                                                    $af_text = JString::substr($content->ad_text, 0, 100);
                                                    if (strlen($content->ad_text)>100) {
                                                        $af_text .= "[...]";
                                                    }
                                                    echo $af_text;

The 100 means that 100 characters will be shown before adding [...].

Best regards.
The following user(s) said Thank You: adarr
More
10 years 6 months ago #20115 by hadia9683
Replied by hadia9683 on topic How to hide image and description preiview
yes you got correctly. Just one confustion.

Hide image code, should i add in start of the display images code? as condition.?
The following user(s) said Thank You: adarr
Time to create page: 0.089 seconds
Powered by Kunena Forum