En réponse à mbisping qui écrivit, en date du : 9/09/07 13:55, le
message suivant :
It's a datawarehouse web application.
The current url might contain parameters that should not become part
of the bookmark url (jsessionid).
And then ... ?
On reload if the session is not opened what could do thoses parameters ?
Moreover, we have a dojo dialog in which users can select which
additional parameters should become part of the url, so easiest way is
to create the url with javascript.
And where is the problem ?
<select onchange="
var url = '
http://mySite/myFolder/thisPage.htm?';
var k = this.options[this.selectedIndex];
document.getElementById('url').href= url + k.value + '=' +
encodeURI(k.text);">
<option value="choice1">Choice 1</option>
<option value="choice2">Choice 2</option>
<option value="choice3">Choice 3</option>
</select>
<a id="url" href="
http://mySite/myFolder/thisPage.htm">
click right to bookmark said:
Users classically expect bookmarks to open in the current page or tab.
Opening our pages in sidebar makes no sense in layout.
J'ai rien compris !
How do you do to open a page in the side-bar ?
What kind of Fx did you get ?
The sidebar Meikel is referring to is the normal firefox sidebar (like
where your history shows up).
One reason to do this is to give the user one easy cross browser
option for adding a bookmark.
I know 'control + d' works but many people are looking to have some
kind of call to action to get people to bookmark.
The "common" javascript that is used looks something like:
(HEY NOT MY SCRIPT, I KNOW IT SUCKS)
function bookmark(){
var title="Google";
var url="
http://www.google.com";
if(window.sidebar){
window.sidebar.addPanel(title,
url,"");
}else if( window.opera &&
window.print ){
var mbm =
document.createElement('a');
mbm.setAttribute('rel','sidebar');
mbm.setAttribute('href',url);
mbm.setAttribute('title',title);
mbm.click();
}else if(document.all){
window.external.AddFavorite( url, title);
}
}
It will properly create a bookmark in firefox, but when that bookmark
is clicked it opens in a sidebar, much like your history when you
'control + h.'
If you click the properties, you can uncheck a box that says "Load
this bookmark in sidebar", but it would be better if it opened in the
main view as a default.