Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Add a block to show top searches the way tagadelic shows tags. The more a phrase is searched for, the bigger it shows.
Comments
Comment #1
ShaunPatrick CreditAttribution: ShaunPatrick commentedsweet!
Comment #2
ShaunPatrick CreditAttribution: ShaunPatrick commentedWhere can i find the break that its putting after every word?
Comment #3
z.stolar CreditAttribution: z.stolar commentedwhich break are you referring to?
Comment #4
tjodolv CreditAttribution: tjodolv commentedI could not find this feature in RC3. Not sure if you already have it working in a dev version, but I made a preprocess function for my theme to do this, based on code from the Tagadelic module.
Here is my preprocess function, in case you want to take a look at the implementation.
Comment #5
carok CreditAttribution: carok commentedtjodolv, could you please give me an example of using the code above?
Which file should this function be placed in and can you please give me an example of how and where this will be called from?
I thought it was a case of replacing the "theme_top_searches_block" code with what you have above but that is not changing how the block is displayed, I'm pretty new to Drupal so any help is very much appreciated.
Thanks!!!
Comment #6
tjodolv CreditAttribution: tjodolv commentedThis function is a template preprocess function, and those functions should be placed in the
template.php
file of the current theme you are using. If you are using Garland, go to the/themes/garland/template.php
file and add this at the end. If you are using a custom theme, the file should be at/sites/all/themes/YOURTHEMENAME/template.php
.edit:
You should never replace any code in a module (and especially not in Drupal core). This is one of the reasons we have the PHPTemplate theme engine, to do these kinds of "rewrites" to change the look and feel of the site. If you need a module's functionality changed, you either need a different or additional module, or a patch with the additional functionality should be submitted to the module in question.
Comment #7
Balbo CreditAttribution: Balbo commented+1
Comment #8
Grayside CreditAttribution: Grayside commentedJust discovered this module and am wandering the issue queue to learn it's status.
Rather than creating a special template file, it makes more sense to me to expose the top searches data to Views. At that point, you can take advantage of all the display mechanisms and module integrations that Views has to offer, including Views Cloud and Tagadelic Views.
Comment #9
aalireza CreditAttribution: aalireza commentedhow can do this for drupal 7?
Comment #10
Phinkalily CreditAttribution: Phinkalily commentedI also want to have this feature for top searches. I also hope that top searches will have different display styles such as clouds and other.
Comment #11
Yet Another User CreditAttribution: Yet Another User commented#10, I want the same for my website. Can anyone help?
Comment #12
Acertijo CreditAttribution: Acertijo commented+1