problems with converting wordpress 2011 theme to coppermine problems with converting wordpress 2011 theme to coppermine
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

problems with converting wordpress 2011 theme to coppermine

Started by trevorpenfold, August 07, 2012, 01:18:00 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

trevorpenfold

Hi,

I'm re-designing my website and decided to use wordpress to power it, using the twentyeleven theme. I also want to integrate coppermine as a stand alone stock library within the site, so want it to have the same look and feel/skin and the same 2 column 'liquid' layout. I've read all the docs. on creating a custom theme, creating one to match your overall site layout and the tutorial re: converting a w/p theme to Coppermine + searched the forums for help and advice too .... but am still stuck!

I managed to re-create the 'Holy Grail' layout as per the docs as a learning exercise, but have spent the last week trying different options but just can't do the 2011 theme. So far I've created my custom theme and loaded it with the original w/p style + my new custom style.css as per the tutorial by Gizmo + new template and theme files (though I've REALLY struggled with how the theme file works, as it didn't work with the Classic one, so have added all the bits I think I need...?). You can see it here http://trevorpenfold.com/stock_library/index.php?cat=2 but as it's in the development stage there's no content yet, just category and album egs. You can see an eg of the standard 2011 wordpress theme here trevorpenfold.com/main_site/ for information. As you can see hardly any of it is working out and I'm completely stuck as to what to try next!

Many thanks - in anticipation - Trev



I'd be really grateful of any support for this

Jeff Bailey

Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Hi Jeff,

Thanks for your reply. I have looked at 2010 but really want a liquid layout, also 2011 is more recent and presumably more code compliant/up to date with coding etc.

I've attached a copy of my custom files here FYI - though have had to change them all to text files to allow upload, so  not sure if they'll be very user-friendly now??

Cheers.

Jeff Bailey

You could have uploaded them as a zip but the txt extenstion is what we ask for when uploading individual files so thats fine. I'll take a look and see what can be done. Do you have a link for the wordpress version so I can see what it should look like?
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

Jeff Bailey

Also could you upload a zip of any images or js used in the theme.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Hi Jeff,

Here's a link to the blog on our site which is currently using the standard 2011 w/p theme http://trevorpenfold.com/blog/ and is the basic look I'm after (with a left-hand sidebar).

I've attached all the images in a zip ( they're the images from the Classic cpg theme as a base + the images from the w/p 2011 theme) + put the whole theme in a zip together and uploaded too, in case that's easier.

Cheers.

Jeff Bailey

I can't access your site right now becuase my corporate proxy is blocking it. Do you have a link for the theme itself.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Hi Jeff,

Thanks for taking a look at it - I've uploaded the w/p 2011 theme in it's original zip file and here's the link to it in w/p http://wordpress.org/extend/themes/twentyeleven. Also another link to the 2011 theme on our site http://trevorpenfold.com/newsletter/ if that helps...

Cheers.

Jeff Bailey

This is all I had time for tonight. Feel free to continue work on it. If you do upload it here. If you don't I'll continue tomorrow.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Thanks Jeff,

I've tried it out and it works HEAPS better! I've had a look through the files and see that it's similar to the 2010 cpg theme files, but I don't understand how you managed to get the liquid layout to work - but it works well. I've tried to move the sidebar to the left of the main content using div:'left-sidebar #secondary' which seems to have moved the admin menu but not the system menu above it - though this changes sides depending on what page your on and I don't seem to be able to change this! Also the album list still 'escapes' the content to the right. I've uploaded it again - but only my very minor change in a/a.

Cheers.

trevorpenfold

Hi again Jeff,

I've had another look at the functionality of different themes and I guess the w/p 2011 is really like the layout of the Greenflower cpg theme BUT with a liquid layout. I've read that this theme has been updated (as it was done in ?2006 I think originally) and is due for release any moment - but not sure if it'll have the more adaptable liquid layout yet.

Cheers,

Jeff Bailey

I'm not sure what you mean by liquid layout.

All I did was take the curve theme, replaced all the css, changed some div ids and structure in template.html and made a couple of edits to theme.php in the sysmenu function.

There is still a lot of extra code and obviously some structure issues that I can look though tomorrow .

I didn't realize you wanted the secondary column on the left I was just going with the default but I'll change that tomorrow .

I find it's easiest to create custom themes using curve as it has a great dropdown menu that can easily be edited. I have no experience with the greenflower theme, if you think it is a better approach go ahead and use that as the template instead for your custom theme.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

lurkalot

Quote from: Jeff Bailey on August 07, 2012, 06:13:14 AM

I'm not sure what you mean by liquid layout.


Just guessing, maybe trevorpenfold wants to use % rather than a fixed width so it adapts to different sized screens etc.
Running SMF 2.1.4  / Tinyportal 3.0.1, bridged with Coppermine 1.6.25, plus cpmfetch 2.0.0

Jeff Bailey

That's probably correct. He says that it already has the "liquid layout" but I zoomed in and out and not much changed so I thought I'd ask.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Hi Jeff,

The liquid layout I'm aiming for is like in the Coppermine docs 'Creating a theme that matches your overall site layout' (see http://documentation.coppermine-gallery.net/en/theme_create_matching_page_tutorial.htm ) with 'In Search of the Holy grail' by Matthew Levine as the eg, BUT with a max width so can have a background colour/graphic too.

Also my aim is for my whole site to achieve this, as per Stu Nicholls 'CSS Flexible Layout' design (see it here http://www.cssplay.co.uk/layouts/flexible-equal-height.html ) so that when you re-size your browser window the whole layout resizes too - whereas the Greenflower Coppermine one is a fixed width layout - so that the whole site resizes depending on the users device.

Hope that clarifies things and thanks for taking the time to look at it.

Cheers.

Jeff Bailey

Update:
Changed to left column.
Changed some text styles.
One album per row.
Random header image.
Some minor things.

Still a work in progress, just taking a break and letting you see the progress.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Hi Jeff,

It looks nearly there!! The only difference between this one and the w/p 2011 in how the liquid layout responds to downsizing now, is that when it gets really narrow the w/p css drops the left sidebar to below the main content (which is OK I guess), whereas the cpg 2011 version ends up with the main content overlaying the left-hand sidebar, so both become slightly unreadable. To be honest, I don't think people who want to search a stock-library will be doing it on a very narrow device anyway, so I don't think it's a problem for me - just a difference between them.

The one thing I've changed is the positioning of the 'custom footer' token to try and get the w/p 2011 footer to display. It displayed fine when I did it like this in my original tpp_custom theme (about the only thing that did...) but I can't seem to get it to work here and can't see why.

So I've uploaded it again here FYI.

cheers.

Jeff Bailey

Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford

trevorpenfold

Hi Jeff,

I guess it's not actually a custom footer as such -just the normal footer at the bottom of the 2011 w/p style, as per the zip upload the other day - so I think I've misused/misunderstood that term. All i did was to change the 'Powered by Wordpress' link to the 'Credits' token so it showed 'Powered by Coppermine' instead.

Cheers.

Jeff Bailey

The theme already has a credit to Coppermine.

I'm not sure what you're tring to add or change?
Do you want to add a credit to wordpress?

When I finish I usually update the credits function in theme.php and will add it it.
Thinking is the hardest work there is, which is probably the reason why so few engage in it. - Henry Ford