• Welcome to PHPVIBE Forums. Please log in.

[ Video Sharing CMS v4 ] how to add register login in sidebar and player page

Started by tesladisk,

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

tesladiskTopic starter

hi i want to ask how to add the register login in the right or left sidebar and above related videos in the video player page or in a pop up window but i want it if is possible to have all the register login options not hide behind the visitor button and also when someone is logged in to see all options available not hide behind the avatar and name
thanks
  •  

PHPVibe A.

Hi, the code is in
com/com_login.php and com/com_register.php

tesladiskTopic starter

ok i find the code should i get everything from this 2 files and paste it to the place i want i know only very few about code
  •  

tesladiskTopic starter

ok i manage to do it like this but need to properly formated right now it looks really bad i placed to the right sidebar also how can be replaced after a user logged in with the user menu thanks
<a href="http://vapers-tube.com/login/" title="Login"><i class="icon-user"></i><span>User &amp; pass</span></a>
<a href="http://vapers-tube.com/index.php?action=login&amp;type=facebook" title="Facebook login"><i class="icon-facebook-sign"></i><span>Facebook</span></a>
<a href="http://vapers-tube.com/index.php?action=login&amp;type=google" title="Google login"><i class="icon-google-plus-sign"></i><span>Google</span></a>
<a href="http://vapers-tube.com/login/&amp;do=forgot" title="Forgot password"><i class="icon-envelope"></i><span>Recover</span></a>
<a href="http://vapers-tube.com/register/" class="login-more"><i class="icon-double-angle-right"></i><span>Classic registration</span>  </a>
  •  

PHPVibe A.

You can use the is_user() check
if(is_user()) {

//code for menu 

} else {

//code for login/register
}

tesladiskTopic starter

alex i am total noob something i do very wrong i have made this but nothing happen i see both menu and login register in right sidebar along with the code menu does not change what i do wrong
if(is_user()) {

//<li><a href="http://vapers-tube.com/me"><i class="icon-check"></i> My Media</a></li>
<li><a href="http://vapers-tube.com/me&amp;sk=likes"><i class="icon-thumbs-up"></i> Likes</a></li>
<li><a href="http://vapers-tube.com/buzz" title="Notifications"><i class="icon-bell"></i>Notifications</a></li>
<li><a href="http://vapers-tube.com/me&amp;sk=new-playlist"><i class="icon-plus"></i> New Playlist</a></li>
<li><a href="http://vapers-tube.com/me&amp;sk=playlists"><i class="icon-edit"></i> Playlists</a></li>
<li><a href="http://vapers-tube.com/index.php?action=logout"><i class="icon-off"></i>Logout</a></li>
<li><a href="http://vapers-tube.com/profile/vapers-tube/1/"><i class="icon-cog"></i>My Profile</a></li>

} else {

//<li><a href="http://vapers-tube.com/login/" title="Login"><i class="icon-user"></i><span>User &amp; pass</span></a></li>
<li><a href="http://vapers-tube.com/index.php?action=login&amp;type=facebook" title="Facebook login"><i class="icon-facebook-sign"></i><span>Facebook</span></a></li>
<li><a href="http://vapers-tube.com/index.php?action=login&amp;type=google" title="Google login"><i class="icon-google-plus-sign"></i><span>Google</span></a></li>
<li><a href="http://vapers-tube.com/login/&amp;do=forgot" title="Forgot password"><i class="icon-envelope"></i><span>Recover</span></a></li>
<li><a href="http://vapers-tube.com/register/" class="login-more"><i class="icon-double-angle-right"></i><span>Classic registration</span>  </a></li>

}
  •  

PHPVibe A.

Show me the actual code in there, what I see here is very wrong indeed.

tesladiskTopic starter

i told you alex total noob lol
this is the actual code i paste above please can you guide me to do it right thanks
  •  

PHPVibe A.

You can't do that like that...

At least do this:
if(is_user()) { ?>

//<li><a href="http://vapers-tube.com/me"><i class="icon-check"></i> My Media</a></li>
<li><a href="http://vapers-tube.com/me&amp;sk=likes"><i class="icon-thumbs-up"></i> Likes</a></li>
<li><a href="http://vapers-tube.com/buzz" title="Notifications"><i class="icon-bell"></i>Notifications</a></li>
<li><a href="http://vapers-tube.com/me&amp;sk=new-playlist"><i class="icon-plus"></i> New Playlist</a></li>
<li><a href="http://vapers-tube.com/me&amp;sk=playlists"><i class="icon-edit"></i> Playlists</a></li>
<li><a href="http://vapers-tube.com/index.php?action=logout"><i class="icon-off"></i>Logout</a></li>
<li><a href="http://vapers-tube.com/profile/vapers-tube/1/"><i class="icon-cog"></i>My Profile</a></li>

<?php } else { ?>

//<li><a href="http://vapers-tube.com/login/" title="Login"><i class="icon-user"></i><span>User &amp; pass</span></a></li>
<li><a href="http://vapers-tube.com/index.php?action=login&amp;type=facebook" title="Facebook login"><i class="icon-facebook-sign"></i><span>Facebook</span></a></li>
<li><a href="http://vapers-tube.com/index.php?action=login&amp;type=google" title="Google login"><i class="icon-google-plus-sign"></i><span>Google</span></a></li>
<li><a href="http://vapers-tube.com/login/&amp;do=forgot" title="Forgot password"><i class="icon-envelope"></i><span>Recover</span></a></li>
<li><a href="http://vapers-tube.com/register/" class="login-more"><i class="icon-double-angle-right"></i><span>Classic registration</span>  </a></li>

<?php }


Expecting the start to already have an <?php opening...this is why i've asked for the full code...hard to come up with 100% idea when you don't see all

tesladiskTopic starter

Thanks alex i did make it like you show me and start with <?php  but the right sidebar disappear when i add it anyway i know you have already to much work to do with others and solve problems when you have the time please look at me again
the only reason i try to have a login register and user menu on the sidebar is because i get to much mails and complains from people who do not understand how to register and they cant find where to click but even with just bad looking links in the sidebar i get more registrations than before
  •  

PHPVibe A.


Similar topics (7)