XerxX Posted May 23, 2020 Report Share Posted May 23, 2020 Hi all, TNG 12.3 How can I keep the footer when sitever=mobile in template 15? I want to keep it at least on the index page. TIA /Erik Quote Link to comment Share on other sites More sharing options...
Newfloridian Posted May 23, 2020 Report Share Posted May 23, 2020 Hi Erik I'm not sure whether this would answer your needs. I absolutely and utterly detest mobile mode in all its versions. Using template 4 it destroys the header and the left hand navigation column. Actually though it seems to leave the footer alone. I don't cater for mobile mobile in my writings but I am aware that it is there. Anyway after requests from several of my readers, I was able to offer an option which only appears in mobile mode - and that is to switch the view back to standard mode. (I have always found that, if you really have to, the standard view is acceptable if the mobile phone is held in landscape orientation.) This is a modification of a device which Ron Krzy uses on his own site (he has it appearing in both the header and the footer). I place it in the footer only as an include statement so that it will appear on every page. On a mobile device in mobile mode it displays a "switch to standard" button and in standard mode it displays a "switch to mobile" button. Nothing displays on a PC, laptop or tablet. Cheers Alan switch.php Quote Link to comment Share on other sites More sharing options...
XerxX Posted May 23, 2020 Author Report Share Posted May 23, 2020 Hi Alan, Thanks for the suggestion. I agree with you for the index pages. But for the rest, I find it very good (maybe the "Mobile..." mods are also responsible ) So I designed a totally responsive index page that looks the same for mobile mode or not, at different screen widths. Except that the footer disappears and as it contains some info I want to communicate I want to keep it. But I can't find out how or where. This is what the footer looks like on a wider screen (made to fit here): This is on a narrow one - that I want but is gone: Oooh! A misspelling... Not good. Regards, Erik Quote Link to comment Share on other sites More sharing options...
Ken Roy Posted May 23, 2020 Report Share Posted May 23, 2020 Erik, You might be able to set the $flags['nomobile'] = true; before line 67 in the template 15 footer before the tng_footer function call. Note that I have not played with this flag option. Quote Link to comment Share on other sites More sharing options...
XerxX Posted May 23, 2020 Author Report Share Posted May 23, 2020 Hi Ken, Thanks for the suggestion! I put it here: $flags['basicfooter'] = true; $flags['nomobile'] = true; echo tng_footer($flags); ...but it didn't work: No footer I'm afraid: (Yes; I cleared the cache ) Have a nice weekend! Erik Quote Link to comment Share on other sites More sharing options...
bhemph Posted May 23, 2020 Report Share Posted May 23, 2020 Erik, Check out genlib line 233. Brent Quote Link to comment Share on other sites More sharing options...
XerxX Posted May 23, 2020 Author Report Share Posted May 23, 2020 Thanks Brent, it worked - almost I inserted the include() and deleted the original mobile part, because I thought it was the same as below... just an include. Right? Wrong! It looped making a quadrillion footers before it stopped So; in footer.php I had to remove these two: $flags['basicfooter'] = false; echo tng_footer($flags); Keeping either one ended the same way. I'll make Darrins std-credits appear one way or another. Have a nice weekend! Erik Quote Link to comment Share on other sites More sharing options...
tngrlkrz Posted May 23, 2020 Report Share Posted May 23, 2020 7 hours ago, Newfloridian said: This is a modification of a device which Ron Krzy uses on his own site (he has it appearing in both the header and the footer). Actually the full name is Ron Krzmarzick, ...Krzy likely from an email handle. If anyone has interest in the 'switch mobile/standard' on all pages, top and/or bottom, message me. To see effect, just click to my website in the signature below. Quote Link to comment Share on other sites More sharing options...
Newfloridian Posted May 23, 2020 Report Share Posted May 23, 2020 My profound apologies, Ron. Must have been the very early morning and a week long fight with my ISP which was finally resolved in the early hours! Alan Quote Link to comment Share on other sites More sharing options...
XerxX Posted May 24, 2020 Author Report Share Posted May 24, 2020 Totally jumbled everything up! Disregard this post. Thanks <?php // $flags['basicfooter'] = true; // echo tng_footer($flags); include("stdsitecredit.php"); echo $sitecredit; ?> Quote Link to comment Share on other sites More sharing options...
tngrlkrz Posted May 25, 2020 Report Share Posted May 25, 2020 This is still patchwork, and likely there's a better way to do it, but this tested out OK on tng12.3. Erik, I think you wanted index/homepage only, however the attached mod will display a button for switch standard/mobile on any template, as well as the bottom text articles for template 15 in both modes on all pages. It's an unfinished mod, since in addition to installing the cfg fle, you must place footer2.php in folder template 15. It tested OK with the Mobile Site Enhancement mod installed. I don't use template 15 personally, so not sure all is OK with it. It seems to avoid the footer looping problem you experienced (and so did I). Ron footer2.php switch_button.cfg Quote Link to comment Share on other sites More sharing options...
cfj Posted May 25, 2020 Report Share Posted May 25, 2020 Hi Erik. Welcome back. I have made som changes in both genlib and stdsitecrredit, since I use WordPress, but if you don't, you can just copy the code from your template footer into stdstitecredit.php Hope that resolve the problem. Quote Link to comment Share on other sites More sharing options...
XerxX Posted May 25, 2020 Author Report Share Posted May 25, 2020 Hi guys, thanks for your replies. While I was editing the post I got locked out and couldn't connect until now. Crazy. So here's my solution: =============== Target: genlib.php %location:% echo tng_basicfooter($flags); if(!isset($flags['nomobile']) || !$flags['nomobile']) echo "</div>\n"; %end:% %replace:% /* echo tng_basicfooter($flags); if(!isset($flags['nomobile']) || !$flags['nomobile']) echo "</div>\n"; */ include( $templatepath . $customfooter ); %end:% =============== Target footer.php %location:% $flags['basicfooter'] = true; echo tng_footer($flags); %end:% %replace:% // $flags['basicfooter'] = true; // echo tng_footer($flags); include("stdsitecredit.php"); echo $sitecredit; %end:% ============ BTW: The middle column in the footer should also have a width of 33% - it seems unnecessary but it isn't when I look at it in Firefox... Thanks for your concern! Erik PS How do I edit the header to say "Solved"? I've done it once before but I see no option now..? Quote Link to comment Share on other sites More sharing options...
DelG Posted May 25, 2020 Report Share Posted May 25, 2020 for what is worth check my footer. i forget the details but adapted a premade mplate and all seems to work well for more than a year. hafd a stroke 23Apr and still in hospital so unlikely to be of further help. good luck. Quote Link to comment Share on other sites More sharing options...
tngrlkrz Posted May 26, 2020 Report Share Posted May 26, 2020 Del, 6 hours ago, DelG said: hafd a stroke 23Apr and still in hospital so unlikely to be of further help. good luck. Profound wishes for good health and a speedy recovery. Quote Link to comment Share on other sites More sharing options...
Rob Severijns Posted May 26, 2020 Report Share Posted May 26, 2020 DelG, Hope you have a full recovery or at least have the side effects limited to an absolute minimum. Wish you and your family all the best and hope to see you back soon. Rob Quote Link to comment Share on other sites More sharing options...
Chris Lloyd Posted May 26, 2020 Report Share Posted May 26, 2020 All the best DelG. Speedy recovery. Quote Link to comment Share on other sites More sharing options...
Ken Roy Posted May 27, 2020 Report Share Posted May 27, 2020 Speedy recovery, Del! Quote Link to comment Share on other sites More sharing options...
XerxX Posted May 27, 2020 Author Report Share Posted May 27, 2020 Del, Thanks for your reply. I solved it but couldn't post here for a day. And even worse: We decided to skip that footer totally - sorry to all for engaging you for nothing! I wish you a speedy and full recovery, Del. Best regards, Erik Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.