1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-04 02:09:22 +02:00
Oinktube/plugin/CustomizeUser/getMyAccount.php
DanieL 90e0facdcf Banner in channels clickable link
add the Website URL field on the profile and use it as a link for the channel banner
Add more info on the database regarding video publishing and notifications
2022-11-09 11:10:23 -03:00

41 lines
No EOL
1.3 KiB
PHP

<?php
if (User::canUpload()) {
?>
<div class="form-group">
<label class="col-md-4 control-label">
<?php echo __("Website"); ?>
</label>
<div class="col-md-8 inputGroupContainer">
<div class="input-group">
<span class="input-group-addon"><i class="fas fa-globe"></i></span>
<input id="userWebsite" placeholder="<?php echo __("Website"); ?>" class="form-control" type="url" value="<?php echo User::getWebsite(); ?>">
</div>
</div>
</div>
<script>
$(document).ready(function () {
$('#userWebsite').change(function (e) {
saveUserSite();
});
});
function saveUserSite() {
var userWebsite = $('#userWebsite').val();
if(empty(userWebsite) || validURL(userWebsite)){
modal.showPleaseWait();
$.ajax({
url: webSiteRootURL + 'plugin/CustomizeUser/getMyAccount.save.json.php',
data: {userWebsite: userWebsite},
type: 'post',
success: function (response) {
avideoResponse(response);
modal.hidePleaseWait();
}
});
}
}
</script>
<?php
}
?>