• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space
  • Chevereto Support CLST

    Support response

    Support checklist

    • Got a Something went wrong message? Read this guide and provide the actual error. Do not skip this.
    • Confirm that the server meets the System Requirements
    • Check for any available Hotfix - your issue could be already reported/fixed
    • Read documentation - It will be required to Debug and understand Errors for a faster support response

Conditions signups

Micka

Chevereto Member
Hello.

Here are my code :
Code:
    <?php
        if(!get_logged_user() and CHV\get_chv_setting('enable_signups')) {
    ?>
    <div id="home-join" class="c20 center-box text-align-center">
        <h1><?php _se('Inscrivez-vous dès maintenant !'); ?></h1>
        <p><?php _se('Gérez votre contenu, créez des albums privés, personnalisez votre profil et bien plus.'); ?></p>
        <div class="home-buttons"><a href="<?php echo G\get_base_url('signup'); ?>" class="btn btn-big blue"><?php _se('Create account'); ?></a></div>
    </div>
    <?php
        } else {
    ?>
    <div id="home-join" class="c20 center-box text-align-center">
        <h1>Bonjour <?php echo CHV\Login::getUser()["name"]; ?> !</h1>
        <p>Vous pouvez gérer vos photos et accéder à votre profil.</p>
        <div class="home-buttons"><a href="<?php echo CHV\Login::getUser()["url"]; ?>" class="btn btn-big blue">Mon profil</a> <?php if(is_admin()) { ?><a href="<?php echo G\get_base_url("dashboard"); ?>" class="btn btn-big green">Tableau de bord</a><?php } ?></div>
    </div>
    <?php
        }
    ?>

If : if the signups are enabled and we are not connected, we can see the signup box
Else : if you are connected, we don't see the signup box but the account box only.

Problem : the fonction "enable_signups" was recently added...
So, when I disable signups, we don't see the signup box but the account box appears when we are not connected.

Thanks for help.
I hope I was enough understanding (I'm french and I didn't often speak english.)
 
I don't understand. This is a problem of Chevereto or your custom code?
 
I have modified the main page, so I think the problem come from my own custom code and I need help. 🙁
 
You only need to make the conditions more clear. You will have to test this in localhost ot something whit simple things like if(cond) echo 'something';
 
Back
Top