forum.coppermine-gallery.net
Support => cpg1.5.x Support => cpg1.5 themes (visuals) => Topic started by: imgr8 on July 14, 2010, 02:52:05 am
-
I want to upgrade my gallery from CPG 1.4.26 to 1.5.6 and I was modifying the curve theme to match my current theme, but I cannot figure out how to fix these two things:
1. The number of pages of comments shows on the top of comments and at the bottom, which file do I modify to make it to display only at the bottom?
2. I changed the default icons that came with CPG with my own text ones (such as delete icon, comment approve, disapprove, edit etc.) but they look compressed as they are bigger in width than the current ones. Currently the function that fetches these icons is something like cpg_fetch_icon('delete'..) and it makes the size 18px, where do I modify that? I changed the navbar icons with no difficulty but these other icons are messing up the look.
Any help is appreciated :)
-
Please first post a link to your gallery. Not only is it required for all support requests, it's also helpful in your case to identify potential issues.
-
My gallery is still running on 1.4.14 as I wanted to have the theme in place before I upgraded, so I am running 1.5.6 on localhost on my computer. Here's the link to my current gallery http://www.ranbirkapoor.net/gallery/index.php I took some screencaps of the issues though:
1. The icons in comment section
1.4.14
http://i29.tinypic.com/2hqwinc.jpg
1.5.6
http://i25.tinypic.com/34q2ybl.jpg
The icons in the category manager (Admin controls)
1.4.14
http://i30.tinypic.com/2lp55h.jpg
1.5.6
http://i26.tinypic.com/fda5ah.jpg
The icons in the Navbar do not get compressed in 1.5.6 though
http://i31.tinypic.com/6ef0gm.jpg
2. The top page # section that I want to remove from the comments section
http://i25.tinypic.com/34q2ybl.jpg
-
Please don't hotlink images Board rules / Forum policies: Add Attachments (http://forum.coppermine-gallery.net/index.php/topic,55415.msg270617.html#msg270617)
I've attached them to my post.
We can't support outdated versions.
Upgrade immediately, You are vulnerable to attacks. http://coppermine-gallery.net/demo/cpg14x/docs/index.htm#upgrade
Until you have an upgraded site we can't really help you because you could be hacked at any moment and lose all your and our hard work.
It's hard to help with theme issues without a live site to view. If you use Firefox: firebug is a good program to use when editing themes.
Have a look at some of these Tools: http://documentation.coppermine-gallery.net/en/dev_tools.htm#dev_tools_web_development
-
oh sorry, how do I edit my post to remove the image links?? I do have firebug and I tried looking at the php code too but everything points to the function cpg_fetch_icon(..) and I can't dig that down any further. Anyways I will upgrade and come back for help :)
-
Alright I upgraded the gallery :)
-
Please create a test Non-Admin user as you require a log in.
-
Done!
-
Currently the function that fetches these icons is something like cpg_fetch_icon('delete'..) and it makes the size 18px, where do I modify that?
Inside that very function definition. Edit include/functions.inc.php, find function cpg_fetch_icon and edit as you see fit. You'd be surprised what you can find using your operating system's built-in search function btw.
-
I did try searching for it but it only showed me doc file for plugin hooks. Thanks, I will check there :)
-
Ok I fixed it by removing the width, height assignment from the function. Thanks a lot!
-
BTW how do I fix the comment thing? I found the code section that displays it in the function theme_html_comments but if I comment it out, then both the top and the bottom display table disappear.
-
Nevermind, figured that out too :)
-
Then post what you did for the benefit of others with similar issues - that's the point of a support forum.
-
Alright :) I don't know if this is the correct way to do it but it works.
In include/themes.inc.php , find the function theme_html_comments
Inside it on line 3824 there is a line of code //$html .= ($tabs = ob_get_clean());
comment it out and then scroll down to find html .= $tabs , its after the while-loop end on line 3928, replace it with $html .= ($tabs = ob_get_clean()); Thats it :)
-
Nope, that is not the correct way to do it. You should not edit include/themes.inc.php but instead copy that function from the sample theme.php into your custom theme.php and perform your edit there.
-
Ok, will copy the function and reverse the changes in the themes file :)