Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

Commit

Permalink
Fix minisite_session parameter management
Browse files Browse the repository at this point in the history
  • Loading branch information
cdujeu committed Jun 14, 2014
1 parent 5a01be8 commit 706eddc
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion core/src/plugins/access.fs/fsActions.xml
Expand Up @@ -142,7 +142,7 @@
}else{
var regex = new RegExp('.*?[&\\?]' + 'minisite_session' + '=(.*?)&.*');
val = window.ajxpServerAccessPath.replace(regex, "$1");
minisite_session = ( val == window.ajxpServerAccessPath ? false : val );
var minisite_session = ( val == window.ajxpServerAccessPath ? false : val );
$('download_form').action = window.ajxpServerAccessPath;
$('download_form').secure_token.value = Connexion.SECURE_TOKEN;
Expand Down
Expand Up @@ -75,7 +75,7 @@ public function switchAction($action, $httpVars, $fileVars)
$jsCode = "
var regex = new RegExp('.*?[&\\?]' + 'minisite_session' + '=(.*?)&.*');
val = window.ajxpServerAccessPath.replace(regex, \"\$1\");
minisite_session = ( val == window.ajxpServerAccessPath ? false : val );
var minisite_session = ( val == window.ajxpServerAccessPath ? false : val );
$('download_form').action = window.ajxpServerAccessPath;
$('download_form').secure_token.value = window.Connexion.SECURE_TOKEN;
Expand Down
2 changes: 1 addition & 1 deletion core/src/plugins/action.powerfs/manifest.xml
Expand Up @@ -84,7 +84,7 @@
}else{
var regex = new RegExp('.*?[&\\?]' + 'minisite_session' + '=(.*?)&.*');
val = window.ajxpServerAccessPath.replace(regex, "$1");
minisite_session = ( val == window.ajxpServerAccessPath ? false : val );
var minisite_session = ( val == window.ajxpServerAccessPath ? false : val );
$('download_form').action = window.ajxpServerAccessPath;
$('download_form').secure_token.value = Connexion.SECURE_TOKEN;
Expand Down
4 changes: 2 additions & 2 deletions core/src/plugins/editor.browser/class.BrowserOpener.js
Expand Up @@ -37,8 +37,8 @@ Class.create("BrowserOpener", AbstractEditor, {
url = $$("base")[0].getAttribute("href");
if(url.substr(-1) == '/') url = url.substr(0, url.length - 1);
}
var nonSecureAccessPath = ajxpServerAccessPath.substring(0, ajxpServerAccessPath.lastIndexOf('?'));
var open_file_url = url + "/" + nonSecureAccessPath + "?get_action=open_file&repository_id=" + repo + "&file=" + encodeURIComponent(node.getPath());
//var nonSecureAccessPath = window.ajxpServerAccessPath.substring(0, window.ajxpServerAccessPath.lastIndexOf('?'));
var open_file_url = url + "/" + window.ajxpServerAccessPath + "&get_action=open_file&repository_id=" + repo + "&file=" + encodeURIComponent(node.getPath());

if(this.editorOptions.context.__className == 'Modal'){
var myRef = window.open(open_file_url);
Expand Down

0 comments on commit 706eddc

Please sign in to comment.