vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=194)
-   -   Major Additions - Links and Downloads Manager (https://vborg.vbsupport.ru/showthread.php?t=119041)

AndrewD 01-30-2007 03:31 PM

Quote:

Originally Posted by Ophelia (Post 1170346)
I double checked and this isn't an issue w/ 2.2.6, which we have installed on the main site...

I'm wondering though if maybe I did something wrong in the configuration of vBulletin though... can anyone else confirm that it's doing this in 2.2.7? When I go into vB's options to set time and set it to ET, it reads -4 instead of -5, even though I picked -5. Maybe that is the issue and it's all my side :( I don't want to send you on a wild goose chase!

I've confirmed the problem - I changed some code to consistently (??!!??) use the user's time zone, but have clearly messed something up. I'll try to post a fix as soon as posisble - it's very easy to go back to the old behaviour, but I would prefer to find an approach that gives the user the option of seeing dates/times on the server and on a local basis.

AndrewD 01-30-2007 03:36 PM

Quote:

Originally Posted by Deathspank (Post 1170417)
Andrew, I still haven't heard a response from you about my question... is there any way we can choose permissions for categories rather than the entire LDM manager and forum permissions? Like, say in one category, I have a bunch of WMV videos that people can stream in the jukebox and save, and in another category they can only stream the WMV files in the jukebox, not save them. I've noted that you could do this with usergroups, but I need it to be done with categories.

The relevant permissions can be set on a per-category basis. Go to 'Edit Catgeory' then the 'User Permissions' tab, and give/take can_play_musicbox and can_save_musicbox, etc

Renada 01-30-2007 05:55 PM

Hi Andrew,

Thank you so much for this mod, it's incredible. :)

Could you tell me if its possible, and if so how I do it, to set this as a "read only" mod instead of a download?

For example, if someone clicks on a text file could it "open" as opposed to them downloading it?

Thanks for your help.

Regards,
Renada

Edit: Unfortunately for some reason the code to stop right clicking also prevents me from editing any settings - i.e. I couldn't change the above setting from 600 to something else. Any ideas?

AndrewD 01-30-2007 07:26 PM

Quote:

Originally Posted by Renada (Post 1170723)
Hi Andrew,

Thank you so much for this mod, it's incredible. :)

Could you tell me if its possible, and if so how I do it, to set this as a "read only" mod instead of a download?

For example, if someone clicks on a text file could it "open" as opposed to them downloading it?

Thanks for your help.

Regards,
Renada

If you set the mimetype information (VB/admin/attachments) for text files to "Content-type: text/plain", then a simple left click on an entry which is a text file opens automatically in the browser window. This works correctly, as far as I can tell, with IE, Firefox and Opera.

However, the user can still force a "save as" using right click with the mouse, or by doing a "view source" and then save. You can disable the 'right click' menu by adding a bit of javascript to the page.

For example, if you edit clientscript/ldm_global.js and add these lines to the end:

Code:

document.oncontextmenu = function(){return false}
if(document.layers) {
    window.captureEvents(Event.MOUSEDOWN);
    window.onmousedown = function(e){
        if(e.target==document)return false;
    }
}
else {
    document.onmousedown = function(){return false}
}

then I think you'll disable the right click menu throughout LDM.

AndrewD 01-30-2007 07:29 PM

Quote:

Originally Posted by Ophelia (Post 1170346)
I double checked and this isn't an issue w/ 2.2.6, which we have installed on the main site...

I'm wondering though if maybe I did something wrong in the configuration of vBulletin though... can anyone else confirm that it's doing this in 2.2.7? When I go into vB's options to set time and set it to ET, it reads -4 instead of -5, even though I picked -5. Maybe that is the issue and it's all my side :( I don't want to send you on a wild goose chase!

Ophelia, I think I've got a fix which always correctly presents the user with times in their own time zone. I can let you have this, or I can let you have the old (server times) behaviour back.

Am going on vacation tomorrow for a couple of weeks - not sure if I'll have an internet connection or not (or even if I should be working on this on holiday...).

If you can let me know by the morning, I'll post the code.

COBRAws 01-31-2007 03:10 AM

Some bug reporting for 2.2.7 b1


in template links_admin;
Report #01: Apply CSS to this button.
Find:
Code:

        $vbphrase[ll_admin_expire]
        <input type="hidden" name="action" value="massedit" />
        <input type="submit" name="expire" value="$vbphrase[ll_go]" />

Replace with:
Code:

        $vbphrase[ll_admin_expire]
        <input type="hidden" name="action" value="massedit" />
        <input type="submit" class="bginput" name="expire" value="$vbphrase[ll_go]" />


Report #02: Add a space after each Usage stats. At the moment it will only show "0 Visits 0bytes". This fix will show "0 Visits 0 bytes"
Find:
Code:

        <td class="alt2" align="center"><span class="smallfont"><if

condition="$totusage['fileshit']">$totusage[fileshit]<else />0</if> $vbphrase[ll_band_files]

$vbphrase[ll_band_usage_24]</span></td>
        <td class="alt2" align="center"><span class="smallfont"><if condition="$totusage['byteshit']">$totusage[byteshit]<else />0</if>$vbphrase[ll_bytes]

$vbphrase[ll_band_usage_24]</span></td>

Replace With:
Code:

        <td class="alt2" align="center"><span class="smallfont"><if condition="$totusage['fileshit']">$totusage[fileshit] <else />0 </if> $vbphrase[ll_band_files] $vbphrase[ll_band_usage_24]</span></td>
        <td class="alt2" align="center"><span class="smallfont"><if condition="$totusage['byteshit']">$totusage[byteshit] <else />0 </if>$vbphrase[ll_bytes] $vbphrase[ll_band_usage_24]</span></td>

ITs not much, but hope it helps. Keep up the good work!

obmob 01-31-2007 03:22 AM

Have a nice vacation Andrew!!! :D

AndrewD 01-31-2007 04:37 AM

Quote:

Originally Posted by COBRAws (Post 1171052)
Some bug reporting for 2.2.7 b1


in template links_admin;
Report #01: Apply CSS to this button.
Find:
Code:

        $vbphrase[ll_admin_expire]
        <input type="hidden" name="action" value="massedit" />
        <input type="submit" name="expire" value="$vbphrase[ll_go]" />

Replace with:
Code:

        $vbphrase[ll_admin_expire]
        <input type="hidden" name="action" value="massedit" />
        <input type="submit" class="bginput" name="expire" value="$vbphrase[ll_go]" />


Report #02: Add a space after each Usage stats. At the moment it will only show "0 Visits 0bytes". This fix will show "0 Visits 0 bytes"
Find:
Code:

        <td class="alt2" align="center"><span class="smallfont"><if

condition="$totusage['fileshit']">$totusage[fileshit]<else />0</if> $vbphrase[ll_band_files]

$vbphrase[ll_band_usage_24]</span></td>
        <td class="alt2" align="center"><span class="smallfont"><if condition="$totusage['byteshit']">$totusage[byteshit]<else />0</if>$vbphrase[ll_bytes]

$vbphrase[ll_band_usage_24]</span></td>

Replace With:
Code:

        <td class="alt2" align="center"><span class="smallfont"><if condition="$totusage['fileshit']">$totusage[fileshit] <else />0 </if> $vbphrase[ll_band_files] $vbphrase[ll_band_usage_24]</span></td>
        <td class="alt2" align="center"><span class="smallfont"><if condition="$totusage['byteshit']">$totusage[byteshit] <else />0 </if>$vbphrase[ll_bytes] $vbphrase[ll_band_usage_24]</span></td>

ITs not much, but hope it helps. Keep up the good work!


Thanks - appreciated.

The underlying thing I have to fix is the code I use to turn number like 123456 into 123K, etc, so that the spacing continues to look right in that situation, i.e. whether or not the space comes before the K or before the bytes. It's one of those tiny but annoying things that I had not dealt with.

berayiwu5 01-31-2007 05:08 AM

Quote:

Originally Posted by AndrewD (Post 1170789)
Am going on vacation tomorrow for a couple of weeks - not sure if I'll have an internet connection or not (or even if I should be working on this on holiday...).

Well deserved. Enjoy your vacation! I'll ask you about integrating a user profile for easy access to photos (the user has uploaded) when you come back.

AndrewD 01-31-2007 05:47 AM

Just to avoid wasting your time...

The most irritating/significant bug in the 2.2.7 code is that users living in a different timezone from your board will see inconsistent information on the add and edit entry forms. As of 2.2.7, the date/time that the user enters is given in her local timezone and correctly entered into the database according to the board's timezone. But when the user edits the entry, they will see the server time, not the time they had entered. Irritating, but not a killer. Fix is written, but I wait for Ophelia's views on how to proceed.

Ophelia - I've sent you the fixed code by email.


All times are GMT. The time now is 09:15 AM.

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.03498 seconds
  • Memory Usage 1,767KB
  • 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
  • (9)bbcode_code_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (6)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