Good morning to the entire forum... (excuse my English )
I have a question, if someone with knowledge can help me, I want to change the view of the username to the custom name written in the "custom2" like the example shown in the images.
Can someone guide me if this can be done...??
Thank you very much for your help.
change the view of the username
change the view of the username
- Attachments
-
- 1login.png (9.22 KiB) Viewed 497 times
-
- login4.png (39.76 KiB) Viewed 497 times
-
- login2.png (8.63 KiB) Viewed 497 times
Luis Ramirez R.
Re: change the view of the username
Hi,
you can add the following code to the hooks/footer-extras.php
you can add the following code to the hooks/footer-extras.php
Code: Select all
<?php
$mi=getMemberInfo();
?>
<script>
$j('nav .navbar-link').text('<?php echo $mi['custom'][1]; ?>');
</script>
Any help offered comes with the best of intentions. Use it at your own risk. In any case, please make a backup of your existing environment before applying any changes.
Re: change the view of the username
Thank you very much pböttcher, for the help, I made a correction and it worked as I wanted... Thank you.
Code: Select all
<?php $mi=getMemberInfo(); ?>
<script>
$j('nav .profile-menu-text').text('<?php echo $mi['custom'][1]; ?>');
</script>
Luis Ramirez R.
Re: change the view of the username
Hello...
(excuse my English)
I want to clarify that in order to achieve the result of the query
I made and that was answered by the user pböttcher, the code:
was placed in /hooks/header-extras.php and it worked.
Thanks for the collaboration.
(excuse my English)
I want to clarify that in order to achieve the result of the query
I made and that was answered by the user pböttcher, the code:
Code: Select all
<?php $mi=getMemberInfo(); ?>
<script>
$j('nav .profile-menu-text').text('<?php echo $mi['custom'][1]; ?>');
</script>
Thanks for the collaboration.
Luis Ramirez R.
Re: change the view of the username
Nice work
Thanks a lot
Thanks a lot