Permalink
Browse files

Fix to make it work with sub uri's (e.g. deploy redmine under /redmine)

  • Loading branch information...
1 parent 2195da8 commit 5da5337fa6da1c0fa8c677ae3e0bc6a2a005a77e @paulcollinsiii paulcollinsiii committed Apr 26, 2011
Showing with 16 additions and 9 deletions.
  1. +7 −0 app/helpers/account_helper.rb
  2. +9 −9 app/views/account/_view_account_login_bottom.html.erb
  3. 0 assets/{ → javascripts}/openid-selector/README.txt
  4. 0 assets/{ → javascripts}/openid-selector/compile-closure.sh
  5. 0 assets/{ → javascripts}/openid-selector/css/openid-shadow.css
  6. 0 assets/{ → javascripts}/openid-selector/css/openid.css
  7. 0 assets/{ → javascripts}/openid-selector/demo-closure-compiled.html
  8. 0 assets/{ → javascripts}/openid-selector/demo-closure.html
  9. 0 assets/{ → javascripts}/openid-selector/demo-mootools.html
  10. 0 assets/{ → javascripts}/openid-selector/demo-prototype.html
  11. 0 assets/{ → javascripts}/openid-selector/demo-ru.html
  12. 0 assets/{ → javascripts}/openid-selector/demo-uk.html
  13. 0 assets/{ → javascripts}/openid-selector/demo.html
  14. 0 assets/{ → javascripts}/openid-selector/generate-sprite.js
  15. 0 assets/{ → javascripts}/openid-selector/generate-sprite.rb
  16. 0 assets/{ → javascripts}/openid-selector/generate-sprite.sh
  17. BIN assets/{ → javascripts}/openid-selector/images.large/aol.gif
  18. BIN assets/{ → javascripts}/openid-selector/images.large/facebook.gif
  19. BIN assets/{ → javascripts}/openid-selector/images.large/google.gif
  20. BIN assets/{ → javascripts}/openid-selector/images.large/mailru.gif
  21. BIN assets/{ → javascripts}/openid-selector/images.large/myopenid.gif
  22. BIN assets/{ → javascripts}/openid-selector/images.large/openid.gif
  23. BIN assets/{ → javascripts}/openid-selector/images.large/rambler.gif
  24. BIN assets/{ → javascripts}/openid-selector/images.large/verisign.gif
  25. BIN assets/{ → javascripts}/openid-selector/images.large/vkontakte.gif
  26. BIN assets/{ → javascripts}/openid-selector/images.large/yahoo.gif
  27. BIN assets/{ → javascripts}/openid-selector/images.large/yandex.gif
  28. BIN assets/{ → javascripts}/openid-selector/images.small/aol.ico
  29. BIN assets/{ → javascripts}/openid-selector/images.small/aol.ico.gif
  30. BIN assets/{ → javascripts}/openid-selector/images.small/aol.ico.png
  31. BIN assets/{ → javascripts}/openid-selector/images.small/blogger.ico
  32. BIN assets/{ → javascripts}/openid-selector/images.small/blogger.ico.gif
  33. BIN assets/{ → javascripts}/openid-selector/images.small/blogger.ico.png
  34. BIN assets/{ → javascripts}/openid-selector/images.small/claimid.ico
  35. BIN assets/{ → javascripts}/openid-selector/images.small/claimid.ico.gif
  36. BIN assets/{ → javascripts}/openid-selector/images.small/claimid.ico.png
  37. BIN assets/{ → javascripts}/openid-selector/images.small/clickpass.ico
  38. BIN assets/{ → javascripts}/openid-selector/images.small/clickpass.ico.gif
  39. BIN assets/{ → javascripts}/openid-selector/images.small/clickpass.ico.png
  40. BIN assets/{ → javascripts}/openid-selector/images.small/facebook.ico
  41. BIN assets/{ → javascripts}/openid-selector/images.small/facebook.ico.gif
  42. BIN assets/{ → javascripts}/openid-selector/images.small/facebook.ico.png
  43. BIN assets/{ → javascripts}/openid-selector/images.small/flickr.ico
  44. BIN assets/{ → javascripts}/openid-selector/images.small/flickr.ico.gif
  45. BIN assets/{ → javascripts}/openid-selector/images.small/flickr.ico.png
  46. BIN assets/{ → javascripts}/openid-selector/images.small/google.ico
  47. BIN assets/{ → javascripts}/openid-selector/images.small/google.ico.gif
  48. BIN assets/{ → javascripts}/openid-selector/images.small/google.ico.png
  49. BIN assets/{ → javascripts}/openid-selector/images.small/google_profile.ico
  50. BIN assets/{ → javascripts}/openid-selector/images.small/google_profile.ico.gif
  51. BIN assets/{ → javascripts}/openid-selector/images.small/google_profile.ico.png
  52. BIN assets/{ → javascripts}/openid-selector/images.small/launchpad.ico
  53. BIN assets/{ → javascripts}/openid-selector/images.small/launchpad.ico.gif
  54. BIN assets/{ → javascripts}/openid-selector/images.small/launchpad.ico.png
  55. BIN assets/{ → javascripts}/openid-selector/images.small/linkedin.ico
  56. BIN assets/{ → javascripts}/openid-selector/images.small/linkedin.ico.gif
  57. BIN assets/{ → javascripts}/openid-selector/images.small/linkedin.ico.png
  58. BIN assets/{ → javascripts}/openid-selector/images.small/livejournal.ico
  59. BIN assets/{ → javascripts}/openid-selector/images.small/livejournal.ico.gif
  60. BIN assets/{ → javascripts}/openid-selector/images.small/livejournal.ico.png
  61. BIN assets/{ → javascripts}/openid-selector/images.small/mailru.ico
  62. BIN assets/{ → javascripts}/openid-selector/images.small/mailru.ico.gif
  63. BIN assets/{ → javascripts}/openid-selector/images.small/mailru.ico.png
  64. BIN assets/{ → javascripts}/openid-selector/images.small/myopenid.ico
  65. BIN assets/{ → javascripts}/openid-selector/images.small/myopenid.ico.gif
  66. BIN assets/{ → javascripts}/openid-selector/images.small/myopenid.ico.png
  67. BIN assets/{ → javascripts}/openid-selector/images.small/openid.ico
  68. BIN assets/{ → javascripts}/openid-selector/images.small/openid.ico.gif
  69. BIN assets/{ → javascripts}/openid-selector/images.small/openid.ico.png
  70. BIN assets/{ → javascripts}/openid-selector/images.small/rambler.ico
  71. BIN assets/{ → javascripts}/openid-selector/images.small/rambler.ico.gif
  72. BIN assets/{ → javascripts}/openid-selector/images.small/rambler.ico.png
  73. BIN assets/{ → javascripts}/openid-selector/images.small/technorati.ico
  74. BIN assets/{ → javascripts}/openid-selector/images.small/technorati.ico.gif
  75. BIN assets/{ → javascripts}/openid-selector/images.small/technorati.ico.png
  76. BIN assets/{ → javascripts}/openid-selector/images.small/twitter.ico
  77. BIN assets/{ → javascripts}/openid-selector/images.small/twitter.ico.gif
  78. BIN assets/{ → javascripts}/openid-selector/images.small/twitter.ico.png
  79. BIN assets/{ → javascripts}/openid-selector/images.small/verisign.ico
  80. BIN assets/{ → javascripts}/openid-selector/images.small/verisign.ico.gif
  81. BIN assets/{ → javascripts}/openid-selector/images.small/verisign.ico.png
  82. BIN assets/{ → javascripts}/openid-selector/images.small/vidoop.ico
  83. BIN assets/{ → javascripts}/openid-selector/images.small/vidoop.ico.gif
  84. BIN assets/{ → javascripts}/openid-selector/images.small/vidoop.ico.png
  85. BIN assets/{ → javascripts}/openid-selector/images.small/vkontakte.ico
  86. BIN assets/{ → javascripts}/openid-selector/images.small/vkontakte.ico.gif
  87. BIN assets/{ → javascripts}/openid-selector/images.small/vkontakte.ico.png
  88. BIN assets/{ → javascripts}/openid-selector/images.small/winliveid.ico
  89. BIN assets/{ → javascripts}/openid-selector/images.small/winliveid.ico.gif
  90. BIN assets/{ → javascripts}/openid-selector/images.small/winliveid.ico.png
  91. BIN assets/{ → javascripts}/openid-selector/images.small/wordpress.ico
  92. BIN assets/{ → javascripts}/openid-selector/images.small/wordpress.ico.gif
  93. BIN assets/{ → javascripts}/openid-selector/images.small/wordpress.ico.png
  94. BIN assets/{ → javascripts}/openid-selector/images.small/yahoo.ico
  95. BIN assets/{ → javascripts}/openid-selector/images.small/yahoo.ico.gif
  96. BIN assets/{ → javascripts}/openid-selector/images.small/yahoo.ico.png
  97. BIN assets/{ → javascripts}/openid-selector/images.small/yandex.ico
  98. BIN assets/{ → javascripts}/openid-selector/images.small/yandex.ico.gif
  99. BIN assets/{ → javascripts}/openid-selector/images.small/yandex.ico.png
  100. BIN assets/{ → javascripts}/openid-selector/images/openid-inputicon.gif
  101. BIN assets/{ → javascripts}/openid-selector/images/openid-providers-en.png
  102. BIN assets/{ → javascripts}/openid-selector/images/openid-providers-ru.png
  103. 0 assets/{ → javascripts}/openid-selector/js/externs.js
  104. 0 assets/{ → javascripts}/openid-selector/js/jquery-1.2.6.min.js
  105. 0 assets/{ → javascripts}/openid-selector/js/mootools-core.js
  106. 0 assets/{ → javascripts}/openid-selector/js/mootools-more.js
  107. 0 assets/{ → javascripts}/openid-selector/js/openid-closure.js
  108. 0 assets/{ → javascripts}/openid-selector/js/openid-de.js
  109. 0 assets/{ → javascripts}/openid-selector/js/openid-en.js
  110. 0 assets/{ → javascripts}/openid-selector/js/openid-jp.js
  111. 0 assets/{ → javascripts}/openid-selector/js/openid-jquery.js
  112. 0 assets/{ → javascripts}/openid-selector/js/openid-mootools.js
  113. 0 assets/{ → javascripts}/openid-selector/js/openid-prototype.js
  114. 0 assets/{ → javascripts}/openid-selector/js/openid-ru.js
  115. 0 assets/{ → javascripts}/openid-selector/js/openid-uk.js
  116. 0 assets/{ → javascripts}/openid-selector/js/openid-vi.js
  117. 0 assets/{ → javascripts}/openid-selector/js/prototype.js
  118. 0 assets/{ → javascripts}/openid-selector/remcomments.sed
@@ -0,0 +1,7 @@
+module AccountHelper
+
+ def relative_root
+ "#{Redmine::Utils.relative_url_root}/"
+ end
+
+end
@@ -1,13 +1,13 @@
<% content_for :header_tags do %>
- <link type="text/css" rel="stylesheet" href="/plugin_assets/redmine_openid_selector/stylesheets/openid.css" />
- <script type="text/javascript" src="/plugin_assets/redmine_openid_selector/javascripts/openid.js"></script>
- <script type="text/javascript" src="/plugin_assets/redmine_openid_selector/openid-selector/js/openid-en.js"></script>
- <script type="text/javascript">
- document.observe('dom:loaded', function() {
- openid.img_path = '/plugin_assets/redmine_openid_selector/openid-selector/images/';
- openid.init('openid_url');
- });
- </script>
+ <%= stylesheet_link_tag 'openid', :plugin => 'redmine-openid-selector' %>
+ <%= javascript_include_tag 'openid', :plugin => 'redmine-openid-selector' %>
+ <%= javascript_include_tag 'openid-selector/js/openid-en', :plugin => 'redmine-openid-selector' %>
+ <script type="text/javascript">
+ document.observe('dom:loaded', function() {
+ openid.img_path = "<%= relative_root %>/plugin_assets/redmine-openid-selector/openid-selector/images/";
+ openid.init('openid_url');
+ });
+ </script>
<% end %>
<br />

0 comments on commit 5da5337

Please sign in to comment.