Support community for TTG plugins and products.
NOTICE
The Turning Gate's Community has moved to a new home, at https://discourse.theturninggate.net.
This forum is now closed, and exists here as a read-only archive.
You are not logged in.
A single-page galley representation would not expedite finding images within a viewer's interest. I like the idea of collections.
You still have the gallery view. When you click on an image, you go to the single-image view if this is what you have selected.
Thanks again, gentleman. I am grateful for your suggestions and assistance. I have to give all of this thought then fiddle around with it.
Yeah, the user experience is a bit different when using the single-page view as the gallery representation.
Hi John,
Dan, would you please point me in a direction to implement phplugins? I'd appreciate it. Thanks to you both.
Here are two little functions that you can add to your phplugins file. First is a helper that translates urls into real links. Then there is the single_bottom() function that shows some image infos on single image pages. This function is what you want to modify so it provides the link and infos to your Fine Art America image page. As shown, you can provide the url to your sales site using metadata, caption, or you could derive it from the image filename.
Yep, the urls trick works only here on single image pages.
// Parses texts and replaces text links with real URLs. Used to display them in single-page view.
function to_url($text) {
return preg_replace('@(http)?(s)?(://)?(([-\w]+\.)+([^\s]+)+[^,.\s])@', '<a href="http$2://$4">$1$2$3$4</a>', $text);
}
function single_bottom()
{
if ($this->hasPhoto()) {
echo '<p>';
echo '<strong>Image Infos:</strong><br/>';
echo 'Filename: '.$this->photo->getFilename().'<br/>';
echo 'Dimensions: '.$this->photo->getPhotoWidth().'w x '.$this->photo->getPhotoHeight().'h<br/>';
echo 'Title: '.$this->photo->getMetadata(Photo::$PHOTO_TITLE).'<br/>';
echo 'Caption: '.to_url($this->photo->getMetadata(Photo::$PHOTO_CAPTION)).'<br/>';
echo 'Metadata 1: '.to_url($this->photo->getMetadata("metadata_one")).'<br/>';
echo 'Metadata 2: '.to_url($this->photo->getMetadata("metadata_two")).'<br/>';
echo '</p>';
}
return true;
} Or you could use single image display and add your custom button/link using phplugins.
I think that the behavior is the same as for copy_xxx(), but just dedicated to the single image pages.
There are dedicated single_top and single_bottom functions for the single image pages.
It looks like the html got caught up in the Markdown/parsedown converter, which changed the angle brackets < and > to < and > for the html to show as symbols. Plus it made the quote marks slanted instead of straight. Anyway, here's the html that should work.
I think this is related to Textedit. Per default, it uses smart quotes, which can be disabled in the preferences menu. I don't know why you get the htmlcharacters for < and >, but this might be related.
I would suggest that you use an editor designed for code. I use TextMate, which is free. Other options are TextWrangler, Sublime Text, etc.
For Markdown, I use the MacDown.app. It has a nice preview which makes it much easier to write code and get it right. Once I like how it looks. I copy and paste it into the respective Backlight or Lr Publisher text field.
I tried setting the parameter to true just for fun, but saw no change (I did remember to clear the cache).
Did you clear the template cache as well (http://yoursite.com/backlight/designer/clear_cache/)?
The color of the labels is identical to the background... hence they are not visible.
Unfortunately, there is still an issue on your site:
Something went wrong
Unexpected error: Unknown: open_basedir restriction in effect. File(/home/gerarpj183/.php/php-mail.log) is not within the allowed path(s): (/home/gerarpj183/domains/gerardstaals.com/:/home/gerarpj183/domains/include/:/etc/pki/tls/certs:/tmp:/var/tmp:/usr/local/lib/php/:/usr/local/php55/lib/php/) in Unknown on line 0I think that's something for Ben to look at. I would send him your FTP access credentials.
I use PHP 7.3 on my test site without issues.
Since 7.3 doesn't work for you, select another version. And just to confirm that you use the latest version of all Backlight modules.
Many hosts are discontinuing PHP version 5.x. So a good bet would be to use a 7.x version. You can try the different versions you have available and see if one of them has the exif module enabled. Otherwise contact your hosts.
This is my php list:Installed PHP Modules:....
Exif is not listed. So either enable it yourself or contact your host.
I guess your host changed your php version and the new one doesn't have the exif module enabled.
These might be related: http://community.theturninggate.net/vie … 101#p58101
You can check if the exif module is installed when visiting http://mysite.com/backlight/admin/list_php_modules/
You have https configured, but you don't use a http to https redirect. This can be enabled in /backlight/admin > Privacy: Automatically Redirect Browsers To https
I can reproduce this. I think you will run into the same problem with the caption and title of images.
Can't think of a solution for this right now.
4) No, not as is. There may be a way to do this with phplugins. Or perhaps Pym can insert more than one iframe??
Here is an example where I added a custom slideshow on a gallery page: https://danielleu.com/shop/wood-panels/. This does work on any page, even if there is already a Backlight based slideshow.
More about what I did is over here: https://danielleu.com/blog/2016/07/addi … sed-pages/
Try to delete it from http://yoursite.com/backlight/publisher/
AFAIK, user_function() is called by Backlight to initialize phplugins.
Why do you want to call this function?
Just curious, what cool feature are you adding to your site?
Hi Rod,
hope you are well. Long story, thought I had the Answer, which was using: if ( $this->page_match("/")...
However, this worked on the Home page - and all the others too! Doh! So it wasn't the answer at all.
I found that if I just used - echo $_SERVER['REQUEST_URI']; it showed the url returned for the pages ie. /about/ and /contact/ for the about and contact pages. The home page returned / (backslash). However, using '/' or "/" as the match worked on all pages.
Now I'm back to trying over to find the right escapes to the 'if' statement. using '/contact' only targets the contact page etc. Just doesn't work on the home page.
Please, anyone chip in if you have any suggestions.
Hi Lofty,
Using my page_match function, '/contact' selects all pages that start with '/contact'. This means that with /gallery, all your gallery pages are selected at once. That's how I use it. Since all pages start with '/', you can't use this to select the home page.
To select just the home page you might want to use:
if ($_SERVER["REQUEST_URI"] == "/") {
echo "home page";
}Thanks Daniel,
Top man!
![]()
When I look at your site with the Facebook debugger, it reports:
Curl Error
Curl error: 35 (SSL_CONNECT_ERROR)
Loading your site in Chrome, first shows a https connection error before being finally loading it. I'm wondering if there is an issue how your site/host manages https which could explain the Fb error as well.