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 / Public Forum / Main Forum / [RESOLVED] eliminating ads without pictures

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.

× OLD Forum post could be checked here : forum.joomprod.com

[RESOLVED] eliminating ads without pictures

More
11 years 6 months ago - 11 years 6 months ago #1327 by shihabhamsa
[RESOLVED] eliminating ads without pictures was created by shihabhamsa
Is there anyway we could eliminate the ads without pictures in it from latest ads module?

and

When we post a new ad, after the posting had been saved, the page redirects to all ads page, how shall we redirect the page to ads within that category and not all category.
Last edit: 11 years 6 months ago by tompap.
More
11 years 6 months ago - 11 years 6 months ago #1336 by Ads4ever
Hello,

Is there anyway we could eliminate the ads without pictures in it from latest ads module?



Yes, it's possible but you need to change the code, you can do that by the template override to not worry about updating the component if you want, so you need to place the template files :
ROOT_JOOMLA\modules\mod_adsmanager_ads\tmpl\horizontal.php
ROOT_JOOMLA\modules\mod_adsmanager_ads\tmpl\vertical.php

place them is a folder called "mod_adsmanager_ads"

and place the folder inside the html folder of your template folder
ROOT/templates/NAME_OF_YOUR_TEMPLATE/html

now you can change the two files to prevent the ads without images to be shown, so all you need to do is to add an if statement before the foreach loop:

	foreach($contents as $row) {
		if (isset($row->images[0])) {    // the added line
 
//don't forget to close the brackets before closing "foreach"
 

do the same for both files and it will show only the ads with images, and you are able to update AdsManager without loosing the modifications

Founder of ITechnoDev
Last edit: 11 years 6 months ago by Ads4ever.
More
11 years 6 months ago - 11 years 6 months ago #1357 by shihabhamsa
Replied by shihabhamsa on topic eliminating ads without pictures in Latest Ads mod
I somehow managed to edit the horizontal.php to not to show ads without pictures. But the concern is the number of ads being displayed.

I have set to display latest 5 ads in a row. then I have a condition set not to display ads without pictures. So if the latest 5 ads doesn't have pictures uploaded with it, My latest ads module will show no ads.
What I wanted is that My latest Ads module should show latest 5 ads which has pictures in it for which it may have to scroll down for the entire ads
Last edit: 11 years 6 months ago by shihabhamsa.
Moderators: perry
Time to create page: 0.146 seconds
Powered by Kunena Forum