Jump to content
Wiki Home
EPrints Home
Bazaar
Files
Main menu
Main menu
move to sidebar
hide
Navigation
Front Page
EPrints 3 Manual
EPrints Training Course
EPrints Glossary
Installing EPrints
How-to Configure EPrints
EPrints 3.2+ API
EPrints 3 Reference
EPrints Plugins
Wiki
All categories
Recent changes
Main Page
Help
EPrints Documentation
Search
Search
Appearance
Log in
Request account
Personal tools
Log in
Request account
Pages for logged out editors
learn more
Contributions
Talk
Editing
Archive:Https3
(section)
Archive
Discussion
British English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Internet Explorer 'Secure and non Secure items' === We're not done yet! Internet Explorer complains if non-secure (http) and secure (https) items are displayed on the same page. This happens when a full url, beginning http:// is embedded in a page that is https. If the securepath and url_path variables were the same, e.g. we were using http://repos1.FQDN/repos1 and https://eprints.FQDN/repos1 then we could simply make all urls relative, but because they are different, e.g http://repos1.FQDN/ and https://eprints.FQDN/repos1 we must handle the secure and non-secure cases separately. Edit /opt/eprints3/archives/repos1/cfg/lang/en/templates/secure.xml to use full https:// urls for included javascript and css and for the logo and .ico files. The head section should look something like this: <head> <title><epc:pin ref="title" textonly="yes"/> - <epc:phrase ref="archive_name"/></title> <script src="{$config{secure_url}}/javascript/auto.js" type="text/javascript"><!-- nope --></script> <style type="text/css" media="screen">@import url(<epc:print expr="$config{secure_url}"/>/style/secure_auto.css);</style> <style type="text/css" media="print">@import url(<epc:print expr="$config{secure_url}"/>/style/print.css);</style> <link rel="icon" href="{$config{secure_url}}/favicon.ico" type="image/x-icon"/> <link rel="shortcut icon" href="{$config{secure_url}}/favicon.ico" type="image/x-icon"/> <link rel="Top" href="{$config{frontpage}}"/> <link rel="Search" href="{$config{perl_url}}/search"/> <epc:pin ref="head"/> </head> <body bgcolor="#ffffff" text="#000000"> div class="ep_noprint"> <noscript><style type='text/css'>@import url(<epc:print expr="$config{secure_url}"/>/style/nojs.css);</style></noscript> </div> <epc:pin ref="pagetop"/> div class="ep_tm_header ep_noprint"> div class="ep_tm_logo"><a href="{$config{frontpage}}"><img alt="Logo" src="{$config{secure_url}}{$config{site_logo}}" /></a></div> also change the link to the EPrints logo in the footer: <a href="http://eprints.org/software/"><img src="{$config{secure_url}}/images/eprintslogo.gif" border="0"/></a> We now need to modify 'generate_static' to create the secure_auto.css file as well as auto.css. The relevant section should be modified like this: # do the magic auto.js and auto.css my $js = ""; my $css = ""; my $secure_css =""; my $fn; my $base_url = $session->get_repository->get_conf( "base_url" ); my $secure_url = $session->get_repository->get_conf( "secure_url" ); foreach my $target ( sort keys %{$map} ) { if( $target =~ m/(\/style\/auto\/.*\.css$)/ ) { $css .= "\@import url($base_url$1);\n"; $secure_css .= "\@import url($secure_url$1);\n"; } if( $target =~ m/(\/javascript\/auto\/.*\.js$)/ ) { $fn = $map->{$target}; open( JS, $fn ) || EPrints::abort( "Can't read $fn: $!" ); $js .= "\n\n\n/* From: $fn */\n\n"; $js .= join( "", <JS> ); close JS; } } $fn = "$base_target_dir/style/auto.css"; open( CSS, ">$fn" ) || EPrints::abort( "Can't write $fn: $!" ); $wrote_files->{$fn} = 1; print CSS $css; close CSS; $fn = "$base_target_dir/style/secure_auto.css"; open( CSS, ">$fn" ) || EPrints::abort( "Can't write $fn: $!" ); $wrote_files->{$fn} = 1; print CSS $secure_css; close CSS; Re-run generate_static repos1.
Summary:
Please note that all contributions to EPrints Documentation may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
EPrints Documentation:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)