• Welcome to the Chevereto user community!

    Here users from all over the world gather around to learn the latest about Chevereto and contribute with ideas to improve the software.

    Please keep in mind:

    • 😌 This community is user driven. Be polite with other users.
    • 👉 Is required to purchase a Chevereto license to participate in this community (doesn't apply to Pre-sales).
    • 💸 Purchase a Pro Subscription to get access to active software support and faster ticket response times.

Thumbnail BBCode on top of the multi-codes drop-down list (default)

dotch

Chevereto Member
How can I get the "Thumbnail BBCode" on top of the multi-codes drop-down list (so it becomes sort of default)?

This is the one which almost all users use.

I tried to edit the content\system\js\peafowl.php but after that the multicodes stopped working.

Anyone?
 
Yes, very possible. Simply editr the uploaded.php file and put the code that you wanted in top, just switch with the default one.
 
Thanks, I already did that. It works: as soon as I drop down the list. Thumbnail BBCode is on top of the list. But if I upload multiple images, "Short URL" is on top and in the box. Is it possible to change this too?
 
Sure. I'm on 2.5.3 BTW. I've disabled some of the links, because I only want Thumb+BBCode, Thumb+HTML and Short Link (+Tiny URL)

Code:
<?php if(!defined('access') or !access) die('This file cannot be directly accessed.'); ?>
<?php include_theme_header(); ?>
    <div id="content">
 
        <?php if(is_multiupload_result()) : ?>
        <h2><?php show_lang_txt("txt_just_uploaded"); ?> <?php show_images_count(); ?> <?php show_lang_txt("txt_images"); ?></h2>
       
        <div id="multi-codes">
            <select>
                <!--
                <option value="direct-links"><?php show_lang_txt("txt_multicodes_directlink"); ?></option>
                <option value="html-codes"><?php show_lang_txt("txt_multicodes_html"); ?></option>
                <option value="bb-codes"><?php show_lang_txt("txt_multicodes_bbcode"); ?></option>
                -->
                <option value="thumb-bb-codes"><?php show_lang_txt("txt_multicodes_thumbs_bbcode"); ?></option>
                <option value="html-thumb-codes"><?php show_lang_txt("txt_multicodes_thumbs_html"); ?></option>
                <option value="short-urls-internal" selected="selected"><?php show_lang_txt("txt_show_directly_shorturl"); ?></option>
                <?php if(has_images_shorturls_service()) : ?><option value="short-urls-service"><?php show_tinyurl_service(); ?></option><?php endif; ?>
            </select>
            <textarea id="short-urls-internal" readonly="readonly" style="display: block;"><?php show_images_shorturls('\n'); ?></textarea>
            <textarea id="direct-links" readonly="readonly"><?php show_images_urls('\n'); ?></textarea>
            <?php if(has_images_shorturls_service()) : ?><textarea id="short-urls-service" readonly="readonly"><?php show_images_shorturls_service('\n'); ?></textarea><?php endif; ?>
            <textarea id="html-codes" readonly="readonly"><?php show_images_html('<img src="%IMAGE_URL%" alt="%IMAGE_FILENAME%" border="0" />', ' '); ?></textarea>
            <textarea id="bb-codes" readonly="readonly"><?php show_images_bbcode('[img]%IMAGE_URL%[/img]', ' '); ?></textarea>
            <textarea id="html-thumb-codes" readonly="readonly"><?php show_images_thumbs_linked_html('viewer', 'blank', '<img src="%IMAGE_THUMB_URL%" alt="%IMAGE_FILENAME%" border="0" />', ' '); ?></textarea>
            <textarea id="thumb-bb-codes" readonly="readonly"><?php show_images_thumbs_linked_bbcode('viewer', 'blank', '[img]%IMAGE_THUMB_URL%[/img]', ' '); ?></textarea>
        </div>
       
        <div id="uploaded">
            <div id="uploaded_list" visible-rows="2">
                <?php show_images_thumbs_raw_html('<a rel="%IMAGE_ID%" href="%IMAGE_VIEWER%"><img src="%IMAGE_THUMB_URL%" /></a>'); ?>
            </div>
        </div>
         
        <?php endif; ?>
       
        <?php while(have_images()) : the_image(); ?>
        <div id="uploaded_image-<?php show_image_id(); ?>" class="uploaded_image" <?php if(!is_first_loop()) : ?> style="display: none;"<?php endif; ?>>
       
            <h2 class="viewing"> <a href="<?php show_image_shorturl(); ?>" target="_blank"><?php show_image_filename(); ?></a> (<?php show_image_size(); ?> - <?php show_image_dimentions(); ?>)<span class="loading-image"></span></h2>
           
            <div class="view-full-image"><a href="<?php show_image_shorturl(); ?>" target="_blank"><img src="<?php show_image_url(); ?>" alt="<?php show_image_filename(); ?>" width="<?php show_image_width(); ?>" height="<?php show_image_height(); ?>" class="full_image" /></a></div>
           
            <div class="image_tools">
           
                <div class="image-tools-section socialize">
                   
                    <div class="input-item">
                     
                        <ul class="input-element">
                            <?php show_social_links('<li>', get_image_viewer(), get_image_url()); ?>             
                        </ul>
                    </div>
                </div>             
               
                <div class="image-tools-section thumb_plus_link">
                    <div class="input-item"><label for="bb-code-thumb-<?php show_image_id(); ?>"><?php show_lang_txt('txt_thumb_plus_link_bbcode'); ?></label> <input type="text" id="bb-code-thumb-<?php show_image_id(); ?>" value="<?php show_image_thumb_linked_bbcode('viewer'); ?>" /></div>
                    <div class="input-item"><label for="html-code-<?php show_image_id(); ?>"><?php show_lang_txt('txt_thumb_plus_link_html'); ?></label> <input type="text" id="html-code-<?php show_image_id(); ?>" value="<?php show_image_thumb_linked_html('viewer'); ?>" /></div>
                              </div>
               
                <?php if(is_config_short_url() && is_user_preference_short_url()) : ?>
                    <div class="input-item"><label for="short-url-service-<?php show_image_id(); ?>"><a id="short-url-service-link" href="<?php //show_short_url('service'); ?>"><?php show_tinyurl_service(); ?></a></label> <input type="text" id="short-url-service-<?php show_image_id(); ?>" value="<?php show_image_shorturl_service(); ?>" /></div>
                    <?php endif; ?>
               
                <div class="image-tools-section delete_link">
                   
                    <div class="input-item"><label for="delete-link-input-<?php show_image_id(); ?>"><a id="delete-link" href="<?php show_image_delete_url(); ?>">Delete link</a></label>  <input type="text" id="delete-link-input-<?php show_image_id(); ?>" value="<?php show_image_delete_url(); ?>" /></div>
                </div>
               
            </div>
           
        </div>
        <?php endwhile; ?>
       
    </div>
<?php include_theme_footer(); ?>
 
Change this:
HTML:
<option value="thumb-bb-codes"><?php show_lang_txt("txt_multicodes_thumbs_bbcode"); ?></option>

To this:
HTML:
<option value="thumb-bb-codes" selected="selected"><?php show_lang_txt("txt_multicodes_thumbs_bbcode"); ?></option>

Then change this:
HTML:
<option value="short-urls-internal" selected="selected"><?php show_lang_txt("txt_show_directly_shorturl"); ?></option>

To this:
HTML:
<option value="short-urls-internal"><?php show_lang_txt("txt_show_directly_shorturl"); ?></option>

The final code looks like this:
HTML:
<?php if(!defined('access') or !access) die('This file cannot be directly accessed.'); ?>
<?php include_theme_header(); ?>
    <div id="content">
 
        <?php if(is_multiupload_result()) : ?>
        <h2><?php show_lang_txt("txt_just_uploaded"); ?> <?php show_images_count(); ?> <?php show_lang_txt("txt_images"); ?></h2>
       
        <div id="multi-codes">
            <select>
                <!--
                <option value="direct-links"><?php show_lang_txt("txt_multicodes_directlink"); ?></option>
                <option value="html-codes"><?php show_lang_txt("txt_multicodes_html"); ?></option>
                <option value="bb-codes"><?php show_lang_txt("txt_multicodes_bbcode"); ?></option>
                -->
                <option value="thumb-bb-codes"><?php show_lang_txt("txt_multicodes_thumbs_bbcode"); ?></option>
                <option value="html-thumb-codes" selected="selected"><?php show_lang_txt("txt_multicodes_thumbs_html"); ?></option>
                <option value="short-urls-internal"><?php show_lang_txt("txt_show_directly_shorturl"); ?></option>
                <?php if(has_images_shorturls_service()) : ?><option value="short-urls-service"><?php show_tinyurl_service(); ?></option><?php endif; ?>
            </select>
            <textarea id="short-urls-internal" readonly="readonly" style="display: block;"><?php show_images_shorturls('\n'); ?></textarea>
            <textarea id="direct-links" readonly="readonly"><?php show_images_urls('\n'); ?></textarea>
            <?php if(has_images_shorturls_service()) : ?><textarea id="short-urls-service" readonly="readonly"><?php show_images_shorturls_service('\n'); ?></textarea><?php endif; ?>
            <textarea id="html-codes" readonly="readonly"><?php show_images_html('<img src="%IMAGE_URL%" alt="%IMAGE_FILENAME%" border="0" />', ' '); ?></textarea>
            <textarea id="bb-codes" readonly="readonly"><?php show_images_bbcode('[img]%IMAGE_URL%[/img]', ' '); ?></textarea>
            <textarea id="html-thumb-codes" readonly="readonly"><?php show_images_thumbs_linked_html('viewer', 'blank', '<img src="%IMAGE_THUMB_URL%" alt="%IMAGE_FILENAME%" border="0" />', ' '); ?></textarea>
            <textarea id="thumb-bb-codes" readonly="readonly"><?php show_images_thumbs_linked_bbcode('viewer', 'blank', '[img]%IMAGE_THUMB_URL%[/img]', ' '); ?></textarea>
        </div>
       
        <div id="uploaded">
            <div id="uploaded_list" visible-rows="2">
                <?php show_images_thumbs_raw_html('<a rel="%IMAGE_ID%" href="%IMAGE_VIEWER%"><img src="%IMAGE_THUMB_URL%" /></a>'); ?>
            </div>
        </div>
         
        <?php endif; ?>
       
        <?php while(have_images()) : the_image(); ?>
        <div id="uploaded_image-<?php show_image_id(); ?>" class="uploaded_image" <?php if(!is_first_loop()) : ?> style="display: none;"<?php endif; ?>>
       
            <h2 class="viewing"> <a href="<?php show_image_shorturl(); ?>" target="_blank"><?php show_image_filename(); ?></a> (<?php show_image_size(); ?> - <?php show_image_dimentions(); ?>)<span class="loading-image"></span></h2>
           
            <div class="view-full-image"><a href="<?php show_image_shorturl(); ?>" target="_blank"><img src="<?php show_image_url(); ?>" alt="<?php show_image_filename(); ?>" width="<?php show_image_width(); ?>" height="<?php show_image_height(); ?>" class="full_image" /></a></div>
           
            <div class="image_tools">
           
                <div class="image-tools-section socialize">
                   
                    <div class="input-item">
                     
                        <ul class="input-element">
                            <?php show_social_links('<li>', get_image_viewer(), get_image_url()); ?>             
                        </ul>
                    </div>
                </div>             
               
                <div class="image-tools-section thumb_plus_link">
                    <div class="input-item"><label for="bb-code-thumb-<?php show_image_id(); ?>"><?php show_lang_txt('txt_thumb_plus_link_bbcode'); ?></label> <input type="text" id="bb-code-thumb-<?php show_image_id(); ?>" value="<?php show_image_thumb_linked_bbcode('viewer'); ?>" /></div>
                    <div class="input-item"><label for="html-code-<?php show_image_id(); ?>"><?php show_lang_txt('txt_thumb_plus_link_html'); ?></label> <input type="text" id="html-code-<?php show_image_id(); ?>" value="<?php show_image_thumb_linked_html('viewer'); ?>" /></div>
                              </div>
               
                <?php if(is_config_short_url() && is_user_preference_short_url()) : ?>
                    <div class="input-item"><label for="short-url-service-<?php show_image_id(); ?>"><a id="short-url-service-link" href="<?php //show_short_url('service'); ?>"><?php show_tinyurl_service(); ?></a></label> <input type="text" id="short-url-service-<?php show_image_id(); ?>" value="<?php show_image_shorturl_service(); ?>" /></div>
                    <?php endif; ?>
               
                <div class="image-tools-section delete_link">
                   
                    <div class="input-item"><label for="delete-link-input-<?php show_image_id(); ?>"><a id="delete-link" href="<?php show_image_delete_url(); ?>">Delete link</a></label>  <input type="text" id="delete-link-input-<?php show_image_id(); ?>" value="<?php show_image_delete_url(); ?>" /></div>
                </div>
               
            </div>
           
        </div>
        <?php endwhile; ?>
       
    </div>
<?php include_theme_footer(); ?>
 
Hmm, now the Thumb-BBCode is indeed on top on the list after uploading multiple images, but in the box are still the Short URL-links.

Any idea?
 
Back
Top