Bugzilla – Attachment 13023 Details for
Bug 8952
Add http:// to url in social media links on opac-detail
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 8952 - Add http:// to url in social media links on opac-detail
Bug-8952---Add-http-to-url-in-social-media-links-o.patch (text/plain), 3.33 KB, created by
Owen Leonard
on 2012-10-24 16:39:24 UTC
(
hide
)
Description:
Bug 8952 - Add http:// to url in social media links on opac-detail
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2012-10-24 16:39:24 UTC
Size:
3.33 KB
patch
obsolete
>From 7c2f579740b865859f501e0c56cd4a847bc6b968 Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Wed, 24 Oct 2012 12:30:33 -0400 >Subject: [PATCH] Bug 8952 - Add http:// to url in social media links on > opac-detail >Content-Type: text/plain; charset="utf-8" > >This patch adds a variable to the template, "protocol" based on >whether "using_https" is set. The appropriate protocol is >inserted before social media links. > >To test, confirm that OPACBaseURL is set and lacks "http(s)://" >Social media links should include correct URLs. > >A follow-up patch could copy use of this [% protocol %] variable >in other parts of this template which duplicate large chunks of >HTML based on [% using_https %]. >--- > koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt | 14 +++++++++----- > 1 file changed, 9 insertions(+), 5 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt >index 3ecdc27..22b2367 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt >@@ -1,5 +1,9 @@ > [% USE KohaDates %] >- >+[% IF ( using_https ) %] >+ [% SET protocol = "https://" %] >+[% ELSE %] >+ [% SET protocol = "http://" %] >+[% END %] > [% INCLUDE 'doc-head-open.inc' %][% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog › Details for: [% title |html %][% FOREACH subtitl IN subtitle %], [% subtitl.subfield |html %][% END %] > [% INCLUDE 'doc-head-close.inc' %] > <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script> >@@ -1214,11 +1218,11 @@ YAHOO.util.Event.onContentReady("furtherm", function () { > [% IF ( SocialNetworks ) %] > <div id="social_networks"> > <span>Share</span> >- <div><a id="facebook" href="http://www.facebook.com/sharer.php?u=[% current_url |url %]&t=[% title |url %]" title="Share on Facebook">Facebook</a></div> >+ <div><a id="facebook" href="http://www.facebook.com/sharer.php?u=[% protocol %][% current_url |url %]&t=[% title |url %]" title="Share on Facebook">Facebook</a></div> > <div><a id="twitter" href="http://twitter.com/share" title="Share on Twitter">Twitter</a></div> >- <div><a id="linkedin" href="http://www.linkedin.com/shareArticle?mini=true&url=[% current_url |url %]&title=[% title |url %]" title="Share on LinkedIn">LinkedIn</a></div> >- <div><a id="delicious" href="http://www.delicious.com/save?url=[% current_url |url %]&title=[% title |url %]" title="Share on Delicious">Delicious</a></div> >- <div><a id="email" href="mailto:?subject=[% title %]&body=[% title %] ([% current_url |url %])" title="Share by email">Email</a></div> >+ <div><a id="linkedin" href="http://www.linkedin.com/shareArticle?mini=true&url=[% protocol %][% current_url |url %]&title=[% title |url %]" title="Share on LinkedIn">LinkedIn</a></div> >+ <div><a id="delicious" href="http://www.delicious.com/save?url=[% protocol %][% current_url |url %]&title=[% title |url %]" title="Share on Delicious">Delicious</a></div> >+ <div><a id="email" href="mailto:?subject=[% title %]&body=[% title %] ([% protocol %][% current_url |url %])" title="Share by email">Email</a></div> > <div><g:plusone size="small"></g:plusone></div> > </div> > [% END %] >-- >1.7.9.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 8952
:
13023
|
13033
|
13034
|
14291
|
14292
|
14614
|
16019
|
16020
|
18327
|
18328
|
18353
|
18369
|
21359
|
21360
|
21361