share:function(id, idtype, sharewith, sharetype){
$.getJSON(OC.filePath('calendar', 'ajax/share', 'share.php'),{id:id, idtype:idtype, sharewith:sharewith, sharetype:sharetype}, function(data){
if(sharetype == 'public'){
- $('#public_token').val(OC.linkTo('calendar', 'share.php?t=' + data.message));
+ $('#public_token').val(window.location.protocol + '//' + location.host + OC.linkTo('calendar', 'share.php?t=' + data.message));
$('#public_token').css('display', 'block');
}
});
</ul>
<div id="public">
<input type="checkbox" id="publish" <?php echo ($public['share'])?'checked="checked"':'' ?>><label for="publish"><?php echo $l->t('make public'); ?></label><br>
- <input type="text" id="public_token" value="<?php echo OC_Helper::linkTo('calendar', 'share.php?t=' . $public['share'], null, true) ; ?>" onmouseover="$('#public_token').select();" style="<?php echo (!$public['share'])?'display:none':'' ?>">
+ <input type="text" id="public_token" value="<?php echo OC_Helper::linkToAbsolute('calendar', 'share.php?t=' . $public['share'], null, true) ; ?>" onmouseover="$('#public_token').select();" style="<?php echo (!$public['share'])?'display:none':'' ?>">
</div>
\ No newline at end of file