News Flash:
New Version of ShopClass theme 1.4.0 is Released on 13 JUNE 2018, Please upgrade your installation.

Grid View

Use this forum if you need help installing and/or setting up your instance of Tuffclassified theme. This is not the place for customization requests.
Locked
thedon
Senior
Posts: 159
Joined: Sun May 26, 2013 2:00 pm
Has thanked: 3 times
Been thanked: 2 times

Grid View

Post by thedon » Mon May 05, 2014 7:04 pm

How can i make index page Grid view not optional but permanent.like this one

http://www.adverts.ie/

jodu38
Starter
Posts: 22
Joined: Fri Apr 25, 2014 8:31 pm
Been thanked: 1 time

Re: Grid View

Post by jodu38 » Mon May 05, 2014 8:08 pm

Hi,

you change the layout on ad-loop.php (can be applied to the other loop files).

With Bootstrap 3, it's now easier to do:
- if you want 3 items per line, change the first line "<div class="adbox_ads col-md-12">" to "<div class="adbox_ads col-md-4">".

Bootstrap is based on a 12 columns layout, so play with different multiples of 12 to find the good one.

To recap:
For 1 item (default) : <div class="adbox_ads col-md-12">
For 2 items : <div class="adbox_ads col-md-6">
For 3 items : <div class="adbox_ads col-md-4">
For 4 items : <div class="adbox_ads col-md-3">

This is only for the "item boxes", but for the internal layout of each item box, it's the same way to do.

OR

just look at ad-loop-gallery.php :D

Now you are good to go, hope it helps :-)
Last edited by jodu38 on Tue May 06, 2014 8:31 pm, edited 1 time in total.

thedon
Senior
Posts: 159
Joined: Sun May 26, 2013 2:00 pm
Has thanked: 3 times
Been thanked: 2 times

Re: Grid View

Post by thedon » Tue May 06, 2014 3:15 am

Ok this is my ad-loop.php how do i change it to look like this please http://www.adverts.ie/


<div class="adbox_ads col-md-12">
<div class=" row adbox_box <?php echo (osc_item_is_premium()?" panel-primary":"panel-default") ; ?> panel">
<div class="panel-heading">
<h3 class="panel-title"><a href="<?php echo osc_item_url() ; ?>"><?php echo osc_highlight(osc_item_title(), 70) ; ?></a></h3>
</div>
<div class="panel-body">
<div class="adbox_photo col-md-3 col-sm-4">
<?php if( osc_images_enabled_at_items() ) { ?>
<?php if( osc_count_item_resources() ) { ?>
<span class="badge photobadge"><i class="fa fa-camera fa-fw"></i><?php echo osc_count_item_resources(); ?></span></a>
<a href="<?php echo osc_item_url() ; ?>" class="img-zoom" data-rel="<?php echo osc_resource_url(); ?>">
<img class="img-thumbnail" src="<?php echo osc_resource_thumbnail_url() ; ?>" alt="<?php echo osc_item_title() ; ?>"/></a>
<?php } else { ?>
<a href="<?php echo osc_item_url() ; ?>">
<img class="img-thumbnail" src="<?php if ((file_exists( tfc_path() . "categorypics/". osc_item_parent_category_id() . ".png"))) { echo osc_current_web_theme_url() ."categorypics/". osc_item_parent_category_id().".png"; } else {echo osc_current_web_theme_url()."images/no_photo.gif";}?>" alt="No image available" />
</a>
<?php }
}?>
</div>
<div class="adbox_detail col-md-9 col-sm-8">
<div class="row text-primary">
<strong><i class="fa fa-list fa-fw"></i><a href="<?php echo tf_osc_item_category_url(osc_item_category_id()) ; ?>"><?php echo osc_item_category() ; ?></a></strong>
| <strong><i class="fa fa-calendar fa-fw"></i><?php echo osc_format_date(osc_item_pub_date()); ?></strong>
<?php if (osc_item_city() || osc_item_region()) { ?>
| <strong><i class="fa fa-map-marker fa-fw"></i>
<?php echo osc_item_city();
echo '('.osc_item_region().')'; ?>
</strong>
<?php } ?>
| <strong>
<?php if( osc_price_enabled_at_items() ) { ?><i class="fa fa-shopping-cart fa-fw"></i><?php _e("Price", 'tuffclassified'); ?>: <?php echo osc_item_formated_price() ; ?><?php }?>
</strong>

<hr>
</div>
<p class="adbox_desc row"><?php echo osc_highlight( strip_tags( osc_item_description()) ,250) ; ?></p>
<?php if($adminoptions==true) { ?>
<hr>
<div class="row">
<a class="btn btn-primary btn-xs" href="<?php echo osc_item_url(); ?>"><i class="fa fa-eye"></i><?php _e('View item', 'tuffclassified'); ?></a>
<a class="btn btn-warning btn-xs" href="<?php echo osc_item_edit_url(); ?>"><i class="fa fa-pencil"></i><?php _e('Edit', 'tuffclassified'); ?></a>
<a class="btn btn-danger btn-xs" onclick="javascript:return confirm('<?php echo osc_esc_js(__('This action can not be undone. Are you sure you want to continue?', 'tuffclassified')); ?>')" href="<?php echo osc_item_delete_url();?>" ><i class="fa fa-trash-o"></i><?php _e('Delete', 'tuffclassified'); ?></a>
<?php if(osc_item_is_inactive()) {?>
<a class="btn btn-success btn-xs" href="<?php echo osc_item_activate_url();?>" ><i class="fa fa-check-circle"></i><?php _e('Activate', 'tuffclassified'); ?></a>
<?php } ?>
<hr>
<?php tfc_push_to_top_button(); ?>

</div>
<?php } ?>
</div>
</div>
<?php if (osc_item_is_premium()) {?><div class="panel-footer text-center text-warning"><strong><?php _e("Premium Listing", 'tuffclassified'); ?></strong></div><?php }?>
</div>
</div>

jodu38
Starter
Posts: 22
Joined: Fri Apr 25, 2014 8:31 pm
Been thanked: 1 time

Re: Grid View

Post by jodu38 » Tue May 06, 2014 6:29 pm

did you even read ? :shock:

the first line <div class="adbox_ads col-md-12"> you have to change the number after "md-" and follow what i've posted or if you want something cleaner and already made, look at the ad-loop-gallery.php file to find inspiration.

User avatar
tuffadmin
Site Admin
Posts: 1236
Joined: Tue Jan 29, 2013 7:31 pm
Has thanked: 33 times
Been thanked: 111 times

Re: Grid View

Post by tuffadmin » Fri May 09, 2014 5:44 am

In current version I have added an option to choose default view in theme settings.
No support for unnecessary PM, use forum for support queries.
Please give us good review if you bought our theme from Osclass Market

thedon
Senior
Posts: 159
Joined: Sun May 26, 2013 2:00 pm
Has thanked: 3 times
Been thanked: 2 times

Re: Grid View

Post by thedon » Sat Feb 21, 2015 2:54 pm

i changed it to (20) but it made no difference

<div class="adbox_ads col-md-20">
http://rareoulirishstuff.com/
http://www.adverts.ie/

see the difference

User avatar
tuffadmin
Site Admin
Posts: 1236
Joined: Tue Jan 29, 2013 7:31 pm
Has thanked: 33 times
Been thanked: 111 times

Re: Grid View

Post by tuffadmin » Tue Feb 24, 2015 7:59 am

thedon wrote:i changed it to (20) but it made no difference

<div class="adbox_ads col-md-20">
http://rareoulirishstuff.com/
http://www.adverts.ie/

see the difference
Why are you making changes in file when you can set it through theme dashboard?
No support for unnecessary PM, use forum for support queries.
Please give us good review if you bought our theme from Osclass Market

thedon
Senior
Posts: 159
Joined: Sun May 26, 2013 2:00 pm
Has thanked: 3 times
Been thanked: 2 times

Re: Grid View

Post by thedon » Wed Feb 25, 2015 1:55 am

Can you just do a code so it looks like this site in the boxes please,i mean without having me to do about 10 posts to ask the same question??

I want it to look like their (Recent adverts)

http://www.adverts.ie/

User avatar
tuffadmin
Site Admin
Posts: 1236
Joined: Tue Jan 29, 2013 7:31 pm
Has thanked: 33 times
Been thanked: 111 times

Re: Grid View

Post by tuffadmin » Sun Mar 01, 2015 1:17 am

Sorry not possible
No support for unnecessary PM, use forum for support queries.
Please give us good review if you bought our theme from Osclass Market

Locked