Tag cloud from keywords - Page 4 Tag cloud from keywords - Page 4
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Tag cloud from keywords

Started by Aditya Mooley, December 20, 2005, 07:55:12 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

tinorebel

Hy everyone! ;D

I was wondering if there is a way to display only keywords that have for example 5 photos referring.

My problem is I have hundred of keywords and displaying all slows down quite a bit the page.

Would it be possible to limit clickable keywords only to the ones that refeer to -for example - 5 photos??? ???

Thanks to anyone who can give me a clue .... :-\
Live long and prosper!
www.tripodart.net

Aditya Mooley

Quote from: andyleery on June 13, 2007, 10:57:02 AM
Ok but why are my links looking als the same? There are no clowds, they look just the same.
IMO, there is some problem of spaces which causes this. If if edit your keywords properly it should work. This is what others who have used this have reported. I personally never had this problem on my setup.
--- "Its Nice 2 BE Important but its more Important 2 Be NICE" ---
Follow Coppermine on Twitter

Aditya Mooley

Quote
Would it be possible to limit clickable keywords only to the ones that refeer to -for example - 5 photos???

Download the attached file from first post of this thread.
Find:

if ($keywords_array[$i]) {     // Eliminates Null Keywords


and replace it with

if ($keywords_array[$i] && $keyword_count[$keywords_array[$i]] >= 5) {     // Eliminates Null Keywords


Haven't tried out but should work.
--- "Its Nice 2 BE Important but its more Important 2 Be NICE" ---
Follow Coppermine on Twitter

tinorebel

Thanks a lot Aditya! ;D
looks like is a good solution!

I¡ll try it this afternoon and let you know if works properlly.

p.s. I have a problem when i try to keyword manage:
database responds:
Quote
Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 1311027 bytes) in /mounted-storage/home31b/sub001/sc204/www/website/gal/keywordmgr.php on line 83

Can someone help me ? ???
what happened? yesterday it was working fine...
shurely I have many keywords but alsaw a lot of free space on server, I dont understand.

www.tripodart.net this is the site. :-\

any suggestion is welcome.
Live long and prosper!
www.tripodart.net

tinorebel

Hy! ;D
I just tryed the modification limiting to 5 referring photos for keyword, as suggested by Aditya and worked fine.

I tryed to use a bigger lower limit to reduce number of keywords to only the ones referring to 10 photos- worked fine but....
resulted all keywords same (big) size.

Supose I have to change the first line:

    $em = ($keyword_count[$keywords_array[$i]] < 6) ? 12 : (12 + (int)(($keyword_count[$keywords_array[$i]] - 5) / 5)) * 2;

    if ($em > 24) {

      $span = 'font-size: 24px; font-weight: bold;';

    } else {

      $span = "font-size: {$em}px;";


But have no idea of which numbers should I change. Can someone give me a little help?

Still unable to reach keyword manager.

Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 262927 bytes) in /mounted-storage/home31b/sub001/sc204/www/website/gal/keywordmgr.php on line 83

Maby the problem is in the database?

Thanks a lot! ;)


Live long and prosper!
www.tripodart.net

olti

Is there anyway to show the tags on anycontent.php ?

dellwo

Ok...I fixed the duplicates using Solution #1 in Reply #16.
But I cannot get different sizes. I tried editing and finally just deleted all keywords and just
added one keyword to each picture. Still no change in size.

I see several posts where you mention an "original" search.inc.php.
Were we supposed to change something in that file. I can't find where you say to do that.

Help!
Thanks, Joe
Link --> http://www.dellwo.com/copper/search.php

dellwo

Alright...I fixed it!  I had to undo the duplicates fix from Repy #16 and do the reverse.

I Changed:
        if (!in_array(strtolower($word),$keywords_array)) {
          $keywords_array[] = $word;
To:
        if (!in_array($word,$keywords_array)) {
          $keywords_array[] = $word;

Also, the original script only did the Cloud tags in 2 sizes.
I played with the equation to get more increments.

I hope this helps others.
Thanks, Joe

naufragus

hi there,

great mod! everything works all fine! I thought about including the tag cloud into my sidebar (like the link in post66 shows http://www.dellwo.com/copper/search.php), but as I see they did not really include the keyword.inc.php but rather found a way around it. It seems as you cant include the keyword.inc.php into the template.html anyway. I am not at all a pro and would be very glad to get some help with implementing my tag cloud into the cpg sidebar of the template.html if possible!

thank you very much guys

Pascal

alanpalan

great mod. just one think - how can I display the tags on main page of my coppermine gallery? thanks for answer!

dellwo

See post #48 above.

Joe [Gallery]

Quote from: alanpalan on October 10, 2007, 03:33:07 PM
great mod. just one think - how can I display the tags on main page of my coppermine gallery? thanks for answer!

alanpalan

Thanks but it doesnt work.
Nothing displays. I looked in that file anycontent.php where is written this: "this file file gets included in the index.php if you set the option in admin can be used to display any content from any program".
Where can I set this option in admin? I dont see it anywhere :(

dellwo

Add "anycontent/" to "The content of the main page" in your config.

alanpalan

Great. It works. Thanks. And last question - what if i want to move it to some more visible place (for example somewhere on the top, right under the categories? :)

dellwo

It goes wherever you place it in the config.
So put it after "catlist".
--Joe

Quote from: alanpalan on October 11, 2007, 02:42:29 AM
Great. It works. Thanks. And last question - what if i want to move it to some more visible place (for example somewhere on the top, right under the categories? :)

Joachim Müller

@alanpalan: your questions are not related to this mod, but general coppermine questions. Read up the documentation that comes with it. If you then still have questions, ask them in a thread of your own on the support board.

DaBe

hello

I use coppermine 1.4.14 . and I want use the tag cloud mod here.

how I must make this?

which files I must download? Can everyone upload the actualy files now, pls?

I thx you!


(sry for my english)

Aditya Mooley

A file is attached to the first post in this topic. Just FYI, this mod is not yet tested with 1.4.14
--- "Its Nice 2 BE Important but its more Important 2 Be NICE" ---
Follow Coppermine on Twitter

DaBe

yes but i want display keywords larger when they has more searchresult.

but my coppermine display two searchresult like one searchresult

=(

can me everyone help?


(Sry engslish)

DaBe

and how can I display the cloud in anycontent?


include keywords.inc or what?