vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Styles (https://vborg.vbsupport.ru/forumdisplay.php?f=247)
-   -   Forum Style - Lightweight Style for Small Screen Devices (cell phone, iphone, mobile, android) (https://vborg.vbsupport.ru/showthread.php?t=249277)

Hippy 03-20-2013 02:23 AM

Quote:

Originally Posted by Marco Aurelio (Post 2410795)
Hi dartho, thanks for your lightweight!

Please, help me! :D In vBulletin 4.2, this:

{vb:raw post.post_thanks_bit}

doesn't work! How can I fix?

search post thanks in this thread youll find the code for the whole mod to work..

K4GAP 03-20-2013 04:43 AM

Quote:

Originally Posted by Alan_SP (Post 2410870)
Well, I think that you should install it and see differences for yourself.

In my opinion, dartho's style is much better, I use it when I'm on mobile internet and don't need vB mobile style at all. But, it all comes down to your own tastes.

In most cases that is exactly what I do. But usually an alternative will have listed advantages i.e. does this or that work or look better than the original.

dartho 03-20-2013 04:52 AM

Quote:

Originally Posted by GaryT (Post 2411104)
In most cases that is exactly what I do. But usually an alternative will have listed advantages i.e. does this or that work or look better than the original.

There is no comparison as there was no vBulletin mobile style when I made this one. I'm not sure if vBulletin listed advantages / comparisons to this one when they release their alternative though :)

Marco Aurelio 03-20-2013 11:22 AM

Quote:

Originally Posted by Hippy (Post 2411093)
search post thanks in this thread youll find the code for the whole mod to work..

Sorry, but this:

Quote:

Originally Posted by dartho (Post 2305643)
Integrating Abe1's post thanks add-on into the lightweight style.

replace the following templates with the code provided (in the lightweight style only!!)
post_thanks_box
Code:

<if condition="$post_thanks_box"><div class="windowbg" id="post_thanks_box_$post[postid]">$post_thanks_box</div></if>
post_thanks_button
Code:

<a id="btn" href="post_thanks.php?{vb:raw session.sessionurl}do=post_thanks_add&amp;p={vb:raw post.postid}&amp;securitytoken={vb:raw bbuserinfo.securitytoken}" id="post_thanks_button_{vb:raw post.postid}"<vb:if condition="$vboptions[disable_ajax] != 2"> onclick="return post_thanks_give({vb:raw post.postid}, <vb:if condition="$vboptions[post_groan_integrate]">true<vb:else />false</vb:if>);"</vb:if> <vb:if condition="$display_thanks_image == 'none'">style="display:none"</vb:if> rel="nofollow" class="post_thanks_button">{vb:rawphrase post_thanks_thanks}</a>
post_thanks_postbit
Code:

<vb:if condition="$post['post_thanks_amount'] == 1">
                        {vb:rawphrase post_thanks_user_says, {vb:raw post.username}}
                <vb:else />
                        {vb:rawphrase post_thanks_users_say, {vb:raw post.post_thanks_amount_formatted}, {vb:raw post.username}}
                </vb:if>
{vb:raw post.post_thanks_bit}


Edit both the postbit & postbit_legacy templates as follows

Search for:
Code:

<vb:if condition="$post['editlink']"><a id="btn" href="{vb:raw post.editlink}">{vb:rawphrase edit}</a></vb:if>
Add the following immediately above:
Code:

{vb:raw template_hook.postbit_controls}
Then go to end of template and paste in:
Code:

{vb:raw template_hook.postbit_end}
and your done!

doesn't work after upgrade to vBulletin 4.2, because I don't see {vb:raw post.post_thanks_bit}. I write that code in template, but it doesn't appear on forum, so I don't know who thanked.

dartho 03-20-2013 02:29 PM

You haven't really given us enough info to help, but I would guess you need to redo the post bit template edits

Hippy 03-20-2013 10:50 PM

Quote:

Originally Posted by Marco Aurelio (Post 2411136)
Sorry, but this:



doesn't work after upgrade to vBulletin 4.2, because I don't see {vb:raw post.post_thanks_bit}. I write that code in template, but it doesn't appear on forum, so I don't know who thanked.

still works for me ..
check your work over

Filgga 03-25-2013 07:23 AM

Quote:

Originally Posted by dartho (Post 2411059)

There's no direct fix for this? I've some customizations made and re-installing the same to fix this minor bug seems to be painful

:confused:

BTW, have you managed to get vBSEO Like system compatible with it?

dartho 03-25-2013 10:46 PM

Sorry but I I don't have vbseo so can not look at this. But if it is just a matter of some hooks needing to be added to templates it would be trivial to do if you could find out which hooks are used by the vbseo hack.

You could export the style from your site, including your customisations, and re-install that as per the suggested 'fix' ?

Filgga 03-26-2013 08:23 AM

Quote:

Originally Posted by dartho (Post 2412290)
Sorry but I I don't have vbseo so can not look at this. But if it is just a matter of some hooks needing to be added to templates it would be trivial to do if you could find out which hooks are used by the vbseo hack.

Yeah, loud n clear ;)

Quote:

You could export the style from your site, including your customisations, and re-install that as per the suggested 'fix' ?
Yep, this fixes the problem but another problem rises:
1. If installed as a Standard skin, then the error is fixed!
2. If installed as a mobile skin, the same error comes

Problem: Using vB's default style assignment the theme doesn't appear to be selective under Settings > Options > Style & Language Settings (for mobile themes)

I bet, this' not your fault. vB team was supposed to allow any skin from standard to mobile can be selected to be assigned for mobile users. I see no point of forcing someone to categorize them (IMHO)

What's your suggestion?

dartho 03-27-2013 03:25 AM

vBulletin messed things up for this style when the seperated mobile and standard styles.

If you want to use VB detection and simply apply one style to advanced mobile devices, one style to basic mobile devices and a default style to everyone and allow people to select their own style (assuming they are already allowed to do this on your site) and still allow admin to pick any style they want, the following should do it.

Create a plugin on style_fetch with the following code being sure to enter in teh styleids you want for mobile, advanced mobile and default styles:

PHP Code:

//VB has already check and set cookies if the user can skip the style, so just read what they wrote
$vbulletin->input->clean_array_gpc('c', array(
    
COOKIE_PREFIX 'userstyleid'     => TYPE_INT,
    
COOKIE_PREFIX 'skipmobilestyle' => TYPE_BOOL,
));
$skip $vbulletin->GPC[COOKIE_PREFIX 'skipmobilestyle'];
//Admin can have any style they want, so check if they're an admin and have specificed a styleid
if ($vbulletin->userinfo['permissions']['adminpermissions'])
{
$vbulletin->input->clean_gpc('r''styleid'TYPE_INT);
$styleid $vbulletin->GPC['styleid'];
}
else if (
$skip)
//if the user is not an admin has chosen to skip the mobile style (if allowed) give them default
$styleid=$vbulletin->GPC[COOKIE_PREFIX 'userstyleid'];
else if (
$vbulletin->mobile_browser_advanced
$styleid=20;  //Advanced mobile style ID
else if ($vbulletin->mobile_browser)
$styleid=7;   //Basic mobile style ID
else 
$styleid=1;  //everyone else gets default style default style 



All times are GMT. The time now is 04:55 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.02698 seconds
  • Memory Usage 1,771KB
  • 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
  • (6)bbcode_code_printable
  • (1)bbcode_php_printable
  • (9)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (3)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete