vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=251)
-   -   Change column order in search results (Solved) (https://vborg.vbsupport.ru/showthread.php?t=295904)

Nerror 03-08-2013 01:43 PM

Change column order in search results (Solved)
 
I want to move the Forum part right after the Thread titel, instead of it being in the last column. Pic below shows in first row what I want, and i second row what it is per default:
https://vborg.vbsupport.ru/external/2013/03/46.png

Template change? If so, which and how? :)

Edit: Solved! see below.

Amaury 03-08-2013 01:53 PM

By Lynne:

Quote:

Originally Posted by Lynne
To find the template to modify, do this - vboptions > General Settings > Add Template Name in HTML Comments > set to Yes . Then go back to your page and view the source code and you will see the name of the template called around your part of the code. (Sometimes the template is the one mentioned at the very top of the page source.)


Nerror 03-08-2013 02:17 PM

Ah very nifty, thanks, so it looks like it's the search_threadbit template.

--------------- Added [DATE]1362759838[/DATE] at [TIME]1362759838[/TIME] ---------------

Hrm can't get the formatting right. If I just move this part up above the threadstats part:

Code:

                <div class="threadpostedin td alt">
                        <p>
                                {vb:rawphrase forum}:<br /><a href="{vb:link forum, {vb:raw thread}, null, 'forumid', 'forumtitle'}" title="{vb:raw thread.forumtitleclean}">{vb:raw thread.forumtitle}</a>
                        </p>
                       
                </div>

I end up with 2 rows with the Inline Mod check-box still attached to the end of the threadpostedin part and the other two in a row below. Is it the CSS I need to change as well then?

Edit: The search.css has the following in the threadbit section, but I am just not knowledgeable enough to see what and how to change it. :(
Code:

.threadbit {
        position: relative;
}

.threadbit .threadinfo, .threadbit .threadpostedin, .threadbit .threadstats, .threadbit .threadlastpost {
}

.threadbit .threadinfo {
        width: 45%;
        overflow:hidden;
}

.threadbit .threadinfo.forum {
        width: 100%;
}

.threadbit .deleted .threadinfo {
        width: 60%;
        overflow: hidden;
}

.threadbit .threadtitle {
        height: {vb:math {vb:stylevar big_fontSize}*{vb:stylevar line_height}};
        overflow: hidden;
}

.threadbit .searchdescription {
        height: {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}};
        overflow: hidden;
}

.threadbit .threadpostedin {
        max-width: 19.9%;
        width: 8888px; /* fix for 32497 , weird but working */
        font-size: {vb:stylevar mid_fontSize};
        padding: {vb:math {vb:math {vb:stylevar threadbit_iconsize.height}{vb:stylevar threadbit_iconsize.units} + {vb:stylevar padding} - {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}*2}}/2} 0;
        height: {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}*2};
}

.threadbit .threadpostedin p {
        display:block;
        float: {vb:stylevar left};
        margin-{vb:stylevar left}: 1em;
        clear: both;
        font-size: {vb:stylevar mid_fontSize};
        height: {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}*2};
        overflow: hidden;
}

.threadbit .threadstats {
        width:15%;
        padding-top: {vb:math {vb:math {vb:stylevar threadbit_iconsize.height}{vb:stylevar threadbit_iconsize.units} + {vb:stylevar padding} - {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}*2}}/2};
        word-wrap: break-word;
}
.threadbit .threadreplies {
        padding: {vb:math {vb:math {vb:stylevar threadbit_iconsize.height}{vb:stylevar threadbit_iconsize.units} + {vb:stylevar padding} - {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}}}/2} 0;
}

.threadbit .threadptstats, .threadbit .threadsgstats {
        padding: {vb:math {vb:math {vb:stylevar threadbit_iconsize.height}{vb:stylevar threadbit_iconsize.units} + {vb:stylevar padding} - {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}*3}}/2} 0;
}

.threadbit .threadstats li {
        margin-{vb:stylevar right}:20%;
}

.threadbit .threadlastpost, .threadbit .threaddeleted {
        width:20%;
        padding-{vb:stylevar left}:0;
        font-size:{vb:stylevar mid_fontSize};
}

.threadbit .threadlastpost dd {
        margin:0 20px 0 20px;
        height: {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}};
        overflow: hidden;
        white-space:nowrap;
}

.threadbit .threaddeleted {
        padding-top: {vb:math {vb:math {vb:stylevar threadbit_iconsize.height}{vb:stylevar threadbit_iconsize.units} + {vb:stylevar padding} - {vb:math {vb:stylevar mid_fontSize}*{vb:stylevar line_height}*2}}/2};
}

.threadbit .threaddeleted .deletedby, .threadbit .threaddeleted dl.stats.deletereason {
        margin-{vb:stylevar left}: 20px;
}

.threadbit .threadimod input {
        position: absolute;
        {vb:stylevar right}: 1em;
        top: 0;
}

--------------- Added [DATE]1362765265[/DATE] at [TIME]1362765265[/TIME] ---------------

--------------- Added [DATE]1362765359[/DATE] at [TIME]1362765359[/TIME] ---------------

Solved! It's good to have friends who know more about this stuff. :p

I moved the threadpostedin section as described above, and then all I had to do was to add the following to additional.css:
Code:

.threadbit .threadpostedin {
    float: left;
}
.threadbit.sgbit .threadpostedin {
    float: left;
}



All times are GMT. The time now is 09:13 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01076 seconds
  • Memory Usage 1,733KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete