Advertisement:

Author Topic: Categories with image  (Read 20557 times)

s51

  • Sr. Member
  • ****
  • Posts: 309
Re: Categories with image
« Reply #30 on: April 06, 2013, 07:30:40 pm »
.
Hi Friends  @shamal  @n4sa  @tomshaft  @luca


0.)
I have (yet) no other experience than modern theme (and slightly twitter) so modern it is:
- -

1.)
There is another way also (view quicker) and better in e.g. testers like http://gtmetrix.com/
But as you can see here on my private test site, - clickhttp://www.10venner.dk
it only goes for one language pages (or else you must make the png,s multi-lingual)
The following works in IE 6-7-8-9 (I have _not_ tested in IE10)
- -

2.)
First set up x2 new sub dir,s under theme modern:
\server\yourdomain\oc-content\themes\modern\yourextra\maincategoryicons\*.*
Now produce a number of png files (as the number of your main categorys) ,
* And name them with _EXCACT_ same names & characters as you have given through your Admin - in main categories.
* IMPORTANT NOTE: No intervals between characters - and absolutely no ,funny, characters - only pure alphabet characters.
* I dont use gif or jpg ect. = because you can save png in lossyless compression, and through this you have no loss of speed.
- -

3.)
Now remember to take a safe copy of your working main.php - before you begin to experiment OKAY  ;D

* 1
) FIND THIS
?>
  <?php while ( osc_has_categories() ) { ?>
     <div class="category">

* 3) REMOVE all lines Between here *

* 2) FIND THIS
<h1><strong><span>(<?php echo osc_category_total_items(); ?>)</span></strong></h1>
  <?php if ( osc_count_subcategories() > 0 ) { ?>
   <ul>
- -

4.)
And then insert this piece of code where you took the original code out = IMPORTANT remember to rename sub dir,s and set you own png: width and height.

<!-- YourOwnInsertCodeNameDate -->
<a href="<?php echo osc_search_category_url();?>"><img src="<?php echo osc_current_web_theme_url('yourextra/maincategoryicons/') . osc_category_name() .'.png' ?>" width="140px" height="60px" alt="" title=""/></a>
<!-- YourOwnInsertCodeNameDate -->



Best Regards.: / s51

.

shamal

  • Newbie
  • *
  • Posts: 40
Re: Categories with image
« Reply #31 on: April 15, 2013, 02:53:34 pm »
Hi s51,
Thank you, you're a genius, I have taken your steps and it worked thank you.
TopTopTopTopTopTopTopTopTopTop

s51

  • Sr. Member
  • ****
  • Posts: 309
Re: Categories with image
« Reply #32 on: April 15, 2013, 05:57:14 pm »
.
Hi Tom ...

1.)
The only reason I did tis supplementary topic was primarily two things:
To avoid all \..\..\ references (OSClaas very often chokes in those)
and because on a home c:/server ../../../ it always work,
but very rarely on OnLine servers ..\..\
- -

2.)
Because I tested them on my Iphone and found out that category pictures must be relatively large,
if they at the same, time should function as links, if us with sausage fingers should enjoy it. - Ha,,ha,,ha,,
Therefore I cut a little more, and differently - to get a different result (as 100% W3C komaptibelt)
- -

Best Regards:/ s51

PS:
I,m as you know old school and also like on front page to see how many listnings there is in a category.
Tom ...
This is _only_ a friendly advice - make your png transparent and slightly larger, and directly click bar.
and the use of under_score is ,,religion,, - I use it consistently never in referral paths, etc.
.

shamal

  • Newbie
  • *
  • Posts: 40
Re: Categories with image
« Reply #33 on: April 16, 2013, 01:45:32 pm »
Best s51,
I discover that the crabs appear when I upload them locally, but when I put them on the server does not work. Times upload via ftp gives an error (Failed to convert command to 8 bit charset).
Do you have a solution.
gladly

s51

  • Sr. Member
  • ****
  • Posts: 309
Re: Categories with image
« Reply #34 on: April 16, 2013, 04:05:33 pm »
.

Hi shamal ...


1.)
The error (Failed to convert command to 8 bit charset) is not directly related OSClass
It is (unfortunately) a common error, and often in conjunction with FTP upload with
filenames made in one format,  containment non non-english characters to servers
who many times is set up in a mix, between local language and English language.
(or the other way arround - there goes ,crap, in the transport/translation)
- -

2.)
Last time I run into this problem, was FTP uploading to a server with Greenlandic language and characters,
the solutin was to upload the files in a closed ZIP , - and unpack the ,problem-files, directly on the server,
or you can try anoter FTP programme, because some are known to cause problems with 8 bit transfer,
in / or to / with UTF-8 characterset from locals who e.g. use national characterset.
- -

3.)
Make a local search in the country you live in, for the problem - or ask your server provider, - for a solution.
Hope this could ..guide.. you in the right direction, ? - Unfortunately it is all I can help you with. :-(
Let me know how, - and when, - you have solved this problem. (so others could be helped in the future)
- -

Best Regards.:/ s51

.

achrafkrissi

  • Newbie
  • *
  • Posts: 2
Re: Categories with image
« Reply #35 on: April 24, 2013, 01:28:48 am »
I Need  Help  >Please  Brother .
I Set all and finaly  i had  icon next to categories name
The  Prolem now .  is that i have a website  with 4  languages  so the icons  appears Only in  1  language   ( english )
but  they don3t appear  in 3 other languages
my web is  www.petitmaroc.com
thanks  for  advance

shamal

  • Newbie
  • *
  • Posts: 40
Re: Categories with image
« Reply #36 on: April 24, 2013, 07:03:09 pm »
I have done what s51 posted, and it works perfectly. here is my site:

www.desty2.com

thank you s51.

Shamal

Nandaak

  • Jr. Member
  • **
  • Posts: 52
Re: Categories with image
« Reply #37 on: May 15, 2013, 08:08:47 am »
Hi Raj,

I recently installed your Bcute plugin and followed things as suggested by you. I have dones changes in the main.php and style.css in the Modern Themes folder and have also uploaded the images in the Images folder of themes. But after all this, I still do not find images for the Categories. Please help me.

My site is www.onlads.com.

Regards,
NandaaK

ugogo.info

  • Sr. Member
  • ****
  • Posts: 369
  • I just let my mind wander, and it didn’t come back
Re: Categories with image
« Reply #38 on: June 21, 2013, 10:26:48 am »
Hi Nandaak

Hi Luca

Did you try what Jesse suggested on Message No 17?

Cheers
Caz

diveshlalit

  • Guest
Re: Categories with image
« Reply #39 on: September 05, 2013, 04:12:09 pm »
not working on my site

Roman

  • Newbie
  • *
  • Posts: 5
Re: Categories with image
« Reply #40 on: October 27, 2013, 05:56:43 pm »
Hello!
Help please.
I'm doing a site that supports all popular languages ​​including Russian, for users with different languages. with Russian and there was a problem. Translates it well, probably, but registration of images from CSS is lost. The site of the English version have pictures of categories, but if the English version of the string to my css rules is as follows:
Code: [Select]
<a class = "category for-sale "href =" http://my.domen/index.php?page=search&sCategory=1 "> For sale </ a>The same thing but in the Russian version
Code: [Select]
<a class = "category% d0% 9f% d1% 80% d0% be% d0% b4% d0% b0% d0% b6% d0% b0 "href =" http://my.domen/index.php?page=search&sCategory=1 "> Продажа </ a>
I understand that you need only create a rule in the CSS for this here "% d0% 9f% d1% 80% d0% be% d0% b4% d0% b0% d0% b6% d0% b0" but CSS does not work with such symbols ... What to do?

plesk

  • Full Member
  • ***
  • Posts: 188
Re: Categories with image
« Reply #41 on: October 27, 2013, 07:58:16 pm »
hello


S'il vous plaît ajouter un nouveau lien version osclass 3.2.1 merci

Ramesh

  • Jr. Member
  • **
  • Posts: 61
Re: Categories with image
« Reply #42 on: October 27, 2013, 08:11:36 pm »
if any help needed for osclass .
you can contact me .
skype : Ramesh Chouhan VIT

plesk

  • Full Member
  • ***
  • Posts: 188
Re: Categories with image
« Reply #43 on: October 28, 2013, 04:34:45 pm »
hello,

I used the themes France and I would add the same categories I have added anything like code? thank you

suresh1983

  • Jr. Member
  • **
  • Posts: 96
Re: Categories with image
« Reply #44 on: February 19, 2014, 05:59:07 pm »
Hi,

Please let me know from where I download this theme which is mentioned in the first post