Discover Habbo's history
Treat yourself with a Secret Santa gift.... of a random Wiki page for you to start exploring Habbo's history!
Happy holidays!
Celebrate with us at Habbox on the hotel, on our Forum and right here!
Join Habbox!
One of us! One of us! Click here to see the roles you could take as part of the Habbox community!


Page 1 of 2 12 LastLast
Results 1 to 10 of 14
  1. #1
    Join Date
    Nov 2006
    Posts
    7,395
    Tokens
    2,222

    Latest Awards:

    Default WHMCS Client login help!

    I have a client login form for whmcs, but when the client logs in, I want that form to disappear and display the clients name etc like "Welcome Danny". Anybody know how?
    Hi

  2. #2
    Join Date
    Feb 2013
    Posts
    2,534
    Tokens
    13,046

    Latest Awards:

    Default

    Hello,
    The client homepage will be here:
    /WHMCS/templates/[YOUR THEME]/clienthomepage.tpl.

    Really easy to edit

    PM me if you need anything else. I've spent too much time coding for WHMCS...

  3. #3
    Join Date
    Nov 2006
    Posts
    7,395
    Tokens
    2,222

    Latest Awards:

    Default

    I'm not sure if we are talking about the same thing, but I appreciate your response. I have the following code:

    <form method="post" action="##">
    <input type="hidden" name="token" value="##" />
    <section id="call-to-action">

    <div class="row">

    <div class="nine columns">
    <h4>Email Address: <input type="text" name="username" size="20" /> Password: <input type="password" name="password" size="20" /><br />
    </h4></div>

    <div class="three columns">

    <input type="submit" value="Login" />

    Basically, once that user logs in, I would like that div to then hide the login form and display text such as "Welcome $clientid" or whatever the string is for whmcs.
    Hi

  4. #4
    Join Date
    Mar 2011
    Posts
    333
    Tokens
    863

    Default

    HTML Code:
    <?php if( empty( $_SESSION['uid'] ) ) { ?><form method="post" action="##">
    <input type="hidden" name="token" value="##" />
    <section id="call-to-action">
    
    <div class="row">
    
    <div class="nine columns">
    <h4>Email Address: <input type="text" name="username" size="20" /> Password: <input type="password" name="password" size="20" /><br />
    </h4></div>
    
    <div class="three columns">
    
    <input type="submit" value="Login" />
    <?php }
    else { 
      echo "Welcome back!"
    { ?>
    Untested.

  5. #5
    Join Date
    Nov 2006
    Posts
    7,395
    Tokens
    2,222

    Latest Awards:

    Default

    Quote Originally Posted by HarrySX View Post
    HTML Code:
    <?php if( empty( $_SESSION['uid'] ) ) { ?><form method="post" action="##">
    <input type="hidden" name="token" value="##" />
    <section id="call-to-action">
    
    <div class="row">
    
    <div class="nine columns">
    <h4>Email Address: <input type="text" name="username" size="20" /> Password: <input type="password" name="password" size="20" /><br />
    </h4></div>
    
    <div class="three columns">
    
    <input type="submit" value="Login" />
    <?php }
    else { 
      echo "Welcome back!"
    { ?>
    Untested.
    Will test it shortly, much appreciated.

    ---------- Post added 06-04-2013 at 07:15 PM ----------

    @HarrySX - doesn't appear to work. The whole login form is hidden when logged in or out.
    Hi

  6. #6
    Join Date
    Nov 2006
    Posts
    7,395
    Tokens
    2,222

    Latest Awards:

    Default

    Thought I would share this as I just came across this thread again;

    {if $loggedin}

    <div></div>

    {else}

    <form>
    </form>

    {/if}
    Hi

  7. #7
    Join Date
    Mar 2011
    Posts
    333
    Tokens
    863

    Default

    Quote Originally Posted by Cixso View Post
    Thought I would share this as I just came across this thread again;

    {if $loggedin}

    <div></div>

    {else}

    <form>
    </form>

    {/if}
    ah, that requires including WHMCS' core files. I thought you wanted to do this outside of the WHMCS install location.

  8. #8
    Join Date
    Nov 2006
    Posts
    7,395
    Tokens
    2,222

    Latest Awards:

    Default

    Quote Originally Posted by HarrySX View Post
    ah, that requires including WHMCS' core files. I thought you wanted to do this outside of the WHMCS install location.
    I do, but I also need this code for inside the installation.
    Hi

  9. #9
    Join Date
    Mar 2011
    Posts
    333
    Tokens
    863

    Default

    Quote Originally Posted by Cixso View Post
    I do, but I also need this code for inside the installation.
    ok, the code I provided will work as long as WHMCS is installed on the same domain, it checks for an active WHMCS cookie session. I'm not sure why it didn't work for you but I see @Kieran; is viewing this thread so maybe he can help.

  10. #10
    Join Date
    Nov 2006
    Posts
    7,395
    Tokens
    2,222

    Latest Awards:

    Default

    I haven't gave it another go since my first responce, I'll have another shot at it shortly.

    Thanks for your help
    Hi

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •