• 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

close pref button

Simply trigger the open/close button. Something like change this:
Code:
                <div id="preferences-box">
                    <div><input type="checkbox" id="pref-shorturl" <?php if(isset($_COOKIE['doShort'])) echo 'checked="checked"'; ?> /> <label for="pref-shorturl"><?php show_lang_txt('txt_create_short_url'); ?> <?php show_tinyurl_service(); ?></label></div>
                </div>

For this:
Code:
                <div id="preferences-box">
                    <div><input type="checkbox" id="pref-shorturl" <?php if(isset($_COOKIE['doShort'])) echo 'checked="checked"'; ?> /> <label for="pref-shorturl"><?php show_lang_txt('txt_create_short_url'); ?> <?php show_tinyurl_service(); ?></label></div><span id="close-pref">Close pref.</span>
                </div>

Will add a node (<span id="close-pref">Close pref.</span>) that will used to trigger the button. You will need to tweak the CSS of that html element to suit your needs.

Now, you will need to add this javascript in the theme.js main closure:
Code:
$("span#close-pref").click(function() {
    $("a#preferences").click();
});

That function will trigger a click on the preferences switch when you click the close-pref button. Simple as that.
 
Back
Top