mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-04 02:09:22 +02:00

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
41 lines
No EOL
1.3 KiB
PHP
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
|
|
}
|
|
?>
|