{"id":173,"date":"2004-12-10T00:32:33","date_gmt":"2004-12-09T23:32:33","guid":{"rendered":"http:\/\/frenchfragfactory.net\/ozh\/archives\/2004\/12\/10\/hacking-with-coppermine-keywords\/"},"modified":"2007-05-10T00:04:12","modified_gmt":"2007-05-09T22:04:12","slug":"hacking-with-coppermine-keywords","status":"publish","type":"post","link":"https:\/\/planetozh.com\/blog\/2004\/12\/hacking-with-coppermine-keywords\/","title":{"rendered":"Hacking with Coppermine Keywords"},"content":{"rendered":"<p>I have written a small hack to play more with a nice feature of <a href=\"http:\/\/coppermine.sourceforge.net\">Coppermine<\/a>, the gallery script I am <a href=\"\/gallery\/\">using here<\/a> : the keywords you give to each picture.<\/p>\n<p>The script adds, to the search page for example, a list of all keywords used, and the number of pictures for each (see my <a href=\"http:\/\/planetozh.com\/gallery\/search.php?lang=english\">search page<\/a>). I thought it made keywords very similar to the &quot;tag&quot; feature you have in Gmail or del.icio.us, if that makes sense to you.<br \/>\n<!--more--><\/p>\n<h2>The script<\/h2>\n<p>Get the hack here :<\/p>\n<ul>\n<li><a href=\"http:\/\/planetozh.com\/download\/coppermine-keywords.php\">coppermine keywords<\/a> (syntax highlighted format) <\/li>\n<li><a href=\"http:\/\/planetozh.com\/download\/coppermine-keywords.txt\">coppermine keywords<\/a> (raw text) <\/li>\n<\/ul>\n<p>Right click the .txt, Save as &quot;keywords.php&quot;, then drop it in your Coppermine directory, or copy paste the colorized version into a blank file (do not <em>wget<\/em> the .php, it&#39;s colorized html !)<\/p>\n<h2>Use it<\/h2>\n<p>I suggest you add the keywords list it to your search page. To do so, edit <em>search.php<\/em> with a raw text editor and add the following somewhere near the end, just before the line <strong>pagefooter();<\/strong> for example :<\/p>\n<div class=\"igsh-code-box\" id=\"ig-sh-1\"><pre class=\"language-php line-numbers\" data-no-optimize=\"1\" data-cfasync=\"false\"><code class=\"language-php\">include(&#039;keywords.php&#039;);<\/code><\/pre><\/div>\n<h2>And now ?<\/h2>\n<p>And now, tag&#39;em all !<\/p>\n","protected":false},"excerpt":{"rendered":"<p>A short hack for Coppermine<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[2,68,10],"class_list":["post-173","post","type-post","status-publish","format-standard","hentry","tag-code","tag-gallery","tag-php"],"_links":{"self":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts\/173","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/comments?post=173"}],"version-history":[{"count":0,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/posts\/173\/revisions"}],"wp:attachment":[{"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/media?parent=173"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/categories?post=173"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/planetozh.com\/blog\/wp-json\/wp\/v2\/tags?post=173"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}