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.
Brilllant blog post Daniel!
Thank you for putting it together for us. I am sure that will help greatly.
Cheers
Martin
Hi Daniel,
Thanks for helping out.
It is the results page that is the issue - I would like to see a results page with no mention of galleries.... just simply a message "your search returned 10 photos..." or "your search returned 0 photos" - as per Nico's site.
Any ideas on this?
Cheers,
Martin
Ok, thanks Ben. Looking forward to the update / new release.
Any idea how to action a search feature now (as per Nico's site https://phototheque.nicolaslogerot.com ) perhaps through PHPluins?
I am struggling with coming up with anything that works.
Cheers
Chumby
Hi Rod, Yes - all up to date.
If I change the text, the new text will save all ok. It's just if I leave the input box blank (ie so there is no reference to albums at all), the message will default back to the text that was in there before my save.
Is that what you are seeing?
Cheers
Chumby
Hi Rod,
Yes I change every message to do with albums to blank, go to the botom of the screen, hit save entires. The I go back into Manage Language, scroll down to Publisher and the original album messages are still there, ie - Pulisher Search Albums Title = Albums, and No Albums Message = No albums matched your search criteria.
Is this what happens for you?
Thanks
Chumby.
Hi Rod,
As far as I can tell there is an ID Search element. I found the below before the form when I inspect the page
<div id="search" class="fancybox-content" style="display: inline-block;">
The form code is at:
<div id="search" class="fancybox-content" style="display: inline-block;">
<form action="/backlight/search/" method="GET">
<input type="text" id="q" name="q" value="" placeholder="Enter search, then press Return...">
<button class="fa_pseudo" type="submit"><span>Search</span></button>
</form>
<button type="button" data-fancybox-close="" class="fancybox-button fancybox-close-small" title="Close"><svg xmlns="http://www.w3.org/2000/svg" version="1" viewBox="0 0 24 24"><path d="M13 12l5-5-1-1-5 5-5-5-1 1 5 5-5 5 1 1 5-5 5 5 1-1z"></path></svg></button></div>
So used "search" as the reference. Do no think what I am doing is right though as album messages still appear..
I have changed the messages in languages to blank for albums, but no matter what Ido - refresh or clear, a message about albums always appears.. Have tried other browsers as well with still no luck.
Appreciate your help as always.
Cheers
Chumby
OK, thanks for letting me know of that tool, Rod. I will paste the javascript code in there and see if I can make a better go of it.
Cheers,
Chumby
Hi,
After reading through the posts and help, ahave come up with the code below - unfortunatley still not working. The if wasn't working outside the function, Rod.
Any ideas on what I am still doing wrong on http://www.tasmanianphotos.com to simply get a "no photos found" type message to appear, without any reference to albums.
Appreciate the help as always.
Cheers
Chumby
function main_top() {
if (strtolower($this->slug) == 'search')
echo '
<script>
(function(){
if(document.getElementById("search")!=undefined){
if(document.getElementById("search").innerHTML.indexOf("criteria")>-1){
document.getElementById("search").innerHTML="<p><cite>No photos matched your search criteria</cite></p>";
} else {
document.getElementById("search").style.display="none";
}
})();
</script>
';
} // END
Hi Rod,
No good - tried another browswer, but the album entries that I had deleted were back.
Will have a look at the tips/code you mention. Hopefully I can work this out.
Appreciate the help.
Cheers
Chumby
Thanks Rod and Ben,
Yes I am just using one album set/album - trying to build up a stock photo library much like Nico's at; https://phototheque.nicolaslogerot.com/
For the search I would like a user to just be presented with a message (number) on how many photos were found as well as actully displaying the thumnail photos found. No mention of albums etc. is wanted. The ability to have some feedback text in on the search result page would be good also if nothing found. ie "No images were found, try using a different search term".
Does that all make sense? When I change the messages for albums in Settings > Languages > Manage Language - the message just comes back in on same, so that method is not working for me.
Thank you very much.
Cheers
Chumby
Thanks for the Help again, Rod.
So I started with a fresh Backlight 2 install and followed the first link to get a my-phplugins.php working.
I have read theough the second and third links from Dan, and have entered the code below in my-phplugins page - but its not working (ie a search just presents the normal not found output). Have I missed a step in the code? My site is at - www.tasmanianphotos.com
function ttg_block_bottom( $style, $path ) {
if (strtolower($this->slug) == 'search') {
echo '
<script>
(function(){
if(document.getElementById("content")!=undefined){
if(document.getElementById("content").innerHTML.indexOf("criteria")>-1){
document.getElementById("content").innerHTML="<p><cite>No photos matched your search criteria</cite></p>";
} else {
document.getElementById("content").style.display="none";
}
}
})();
</script>
';
}
} // END
Hi all,
I am trying to modify my search similar to the below site built in CE4.
The code that was used in the PHPlugins file is below. Anyone know what I need to do to get this working in Baklight 2? The orignal thread is at:
http://community.theturninggate.net/vie … hp?id=4747
function ttg_block_bottom( $style, $path ) {
if (G_PATH == 'SEARCH') {
echo '
<script>
(function(){
if(document.getElementById("content")!=undefined){
if(document.getElementById("content").innerHTML.indexOf("criteria")>-1){
document.getElementById("content").innerHTML="<p><cite>No photos matched your search criteria</cite></p>";
} else {
document.getElementById("content").style.display="none";
}
}
})();
</script>
';
}
} // END
Couldn't fix it Rod - so have reinstalled Backlight and menu's working as they should now.
Thanks for the help.
Cheers,
Chumby
Yes tried both those now (as well as using a different browser) and still the galleries and blog items are listed in the menu.
Any other ideas? This has me stumped.
Cheers,
Martin
Ok Rod. Will try both when in front of my computer.
Cheers,
Chumby
Yep, in fact it is also the only menu in the system now .Cheers and thanks,
Hi there,
I am working on a site - tasmanianphotos.com
Trying to get rid of the menu items - blog & galleries. (just wish to run the one gallery from the home page).
Have set up a new menu set without blog and galleries in it - but these items are still appearing.
Is there something I am doing wrong here?
Cheers
Chumby
Cheers Rod... will check it out.
Ok, thanks - that makes sense Daniel.
I will clean up the htaccess file then and then try to embed the album on the front page.
Do you know off hand the method for doing that? Is there a setting in "Edit-Top-Level_Gallery" or somewhere else?
Cheers
Chumby
Hi Daniel,
Will need to look closer to answer your question - I'm still very new at this.
I am trying to get a "stock images" page together similar to Nico's at:
https://phototheque.nicolaslogerot.com
Would there be a reason not do the redirect now it's working
Cheers,
Chumby
Hi Rod,
Not sure which is best - but was just following Nico's lead here.
Funny the code above wasn't working/redirecting with Chrome but is with IE.
I managed to find the code below that seems to work on both Chrome and IE so I will use that.
Thank you for you help again.
RewriteCond %{HTTP_HOST} !^(www\.tasmanianphotos\.com)?$
RewriteRule ^(.*)$ http://www.tasmanianphotos.com/$1 [R=301]
RewriteCond %{REQUEST_URI} !/galleries/tasmania/
RewriteRule ^(.*)$ /galleries/tasmania/$1 [L]
Ok, thanks Rod.
I'll keep looking to see what I can find which is affordable in Australia.
Cheers
Chumby
Hi all,
Has anyone managed to get an album appearing on their homepage as per the instructions from Nico above?
My .htaccess file looks as below, but the redirection is not working:
<IfModule mod_headers.c>
<FilesMatch "\.(eot|font.css|otf|ttc|ttf|woff)$">
Header set Access-Control-Allow-Origin "*"
</FilesMatch>
</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine On
#RewriteCond %{REQUEST_URI}::$1 ^(.*?/)(.*)::\2$
#RewriteRule ^(.*)$ - [E=BASE:%1]
##RewriteRule ^(.*)$ - [E=BASE:]
RewriteBase /
RewriteCond $0#%{REQUEST_URI} ([^#]*)#(.*)\1$
RewriteRule ^.*$ - [E=BASE:%2]
RewriteRule ^(.*)$ - [E=QS:mod_rewrite=on]
RewriteRule ^([^\/.]*)-single.php$ %{ENV:BASE}single.php?%{ENV:QS}&id=$1 [QSA,L]
RewriteRule ^([^\/.]*).css$ %{ENV:BASE}index.php?%{ENV:QS}&extension=css&name=$1 [QSA,L]
RewriteRule ^([^\/.]*).js$ %{ENV:BASE}index.php?%{ENV:QS}&extension=js&name=$1 [QSA,L]
RewriteRule ^([^\/.]*).gif$ %{ENV:BASE}index.php?%{ENV:QS}&extension=gif&name=$1 [QSA,L]
RewriteRule ^([^\/.]*).png$ %{ENV:BASE}index.php?%{ENV:QS}&extension=png&name=$1 [QSA,L]
RewriteRule ^([^\/.]*).jpg$ %{ENV:BASE}index.php?%{ENV:QS}&extension=jpg&name=$1 [QSA,L]
#RewriteCond %{QUERY_STRING} !mod_rewrite=on
#RewriteRule ^index.php$ %{ENV:BASE}index.php?%{ENV:QS} [QSA,L]
RewriteCond %{QUERY_STRING} !mod_rewrite=on
RewriteRule ^mobile.php$ %{ENV:BASE}mobile.php?%{ENV:QS} [QSA,L]
RewriteCond %{QUERY_STRING} !mod_rewrite=on
RewriteRule ^(.*)download.php %{ENV:BASE}download.php?%{ENV:QS} [QSA,L]
#RewriteRule ^/?$ index.php [QSA,L]
RewriteRule ^$ %{ENV:BASE}index.php?%{ENV:QS} [QSA,L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ %{ENV:BASE}index.php?%{ENV:QS}&page=$1 [QSA,L]
RewriteCond %{HTTP_HOST} ^tasmanianphotos.com$ [NC]
RewriteCond %{REQUEST_URI} ^/$
RewriteRule ^(.*)$ /galleries/tasmania/ [L]
</IfModule>
Thanks very much, Rod.
I have read that in more detail now and looks like uploading to my serer the Hi-Res version on demand may be the way the only way to go.
Was also hoping to integrate some printing-on-demand products (canvas, posters etc) into the cart by using a drop-shipping service. I have just looked at fotomoto (the interface looks exellent), but the shipping costs out to Australia are very high.
Do you know any way to integrate digital downloads for Backlight 2 with a drop shipping / printing service in Australia?
Very much appreciate your help.
Cheers,
Chumby
Hi all,
Happy New Year!
Just wondering if anyone has enabled or worked out a way for images to be automatically emailed/downloaded after a purchase through CART and payment approved in PayPal?
If not what are people using to get larger files to clients?
Cheers
Chumby