How to change/edit the Lightbox settings (a.k.a prettyPhoto)?
-
Hello,
I am trying to find the best way to edit the settings for prettyPhoto/lightbox in an ‘update safe’ manner. One thing I am trying to do is change the background of the div container from white to black.
I’ve found that if I edit the core css directly in “plugins\woocommerce\assets\css\prettyPhoto.css”:
div.pp_woocommerce .pp_content_container { background: #fff;
then I can successfully change the background. However when WC gets an update I assume this css file will be overwritten and any changes will be lost. So I tried to duplicate the css file and add it to my theme folder (theme\woocommerce\assets\css\prettyPhoto.css) and then made the same change but it did not have any effect. I was hoping that the ‘template override’ technique would work here.Then I found out that prettyPhoto has theme settings that can be edited from within the .js file itself so I proceeded to edit \plugins\woocommerce\assets\js\prettyPhoto\jquery.prettyPhoto.js and from there i changed
theme: 'pp_default',
totheme: 'dark_rounded',
but this had no effect either.I also couldnt find anywhere in the WC settings to edit the settings of prettyPhoto so I assume most of this should be done by hand, which is no problem, as long as I know how :).
If anyone can show me how to properly change the prettyPhoto theme and/or edit the prettyPhoto css in a way thats update-safe, it would be very much appreciated.
Best.
- The topic ‘How to change/edit the Lightbox settings (a.k.a prettyPhoto)?’ is closed to new replies.