Template lightbox affecting image links in posts.
-
Hey guys, the theme that I am currently using makes use of lightbox for image links on the frontpage. However, it is proving to be a problem for image links in individual pages and also news posts. There is an option to totally disable this feature but unfortunately it would mean that it will not work for the frontpage either.
Currently, the only way that I can remove lightbox from image links within the pages and posts is by removing the “wp-image” tag from the CSS class of the image – This is an example:
Before editing (text that needs to be deleted to disable lightbox is bolded):
<a title="Link to another site" href="http://testing.com"><img class="alignnone size-fullwp-image-2535" alt="Test Image" src="http://site.com.bn/wp-content/uploads/2013/06/testimage.png" width="700" height="300" /></a></p>After editing:
<a title="Link to another site" href="http://testing.com"><img class="alignnone size-full">" alt="Test Image" src="http://site.com.bn/wp-content/uploads/2013/06/testimage.png" width="700" height="300" /></a></p>Some of our news posters are finding it confusing just to look at HTML so I was wondering if there was a better way to fix this.
Any help is greatly appreciated, thanks in advance guys.
The topic ‘Template lightbox affecting image links in posts.’ is closed to new replies.