News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Topic First Image Rotator

Started by Diego Andrés, September 11, 2021, 09:26:44 AM

Previous topic - Next topic

Diego Andrés

Link to the mod




Topic First Image Rotator
Developed by Diego Andrés



Introduction
First Topic Image Rotator allows you to add a slider (carousel) to your forum with the latest first image of each topic from the selected boards.

Features
  • Enable on every page (default is index, boards and topic view)
  • Include inserted attachments in posts (SMF 2.1.x)
  • Select the boards included
  • Select if you only want to display images from the current board
  • Set a limit of images
    • Set height
    • Set width
  • Amount of images per slide
  • Amount of images to scroll
  • Center Mode
  • Autoplay
    • Speed

Localization
English
Spanish
Russian by Bugo


Changelog
GitHub


Credits
Slick Carousel: Thanks to kenwheeler. Licensed under MIT

SMF Tricks - Free & Premium Responsive Themes for SMF.

Antechinus


TwitchisMental

Awesome work on this mod. I could see this being used for a few different things.
My SMF Themes - Remixed Breadcrumb Tutorial
Need a Custom SMF Theme? Send me a message.

peter_mein

Hello
Don´t run. Find no images on my board.
2.1 rc4.
And now ?

Diego Andrés

You need to select the boards first in the settings.
Also having a glance in your forum, barely any images in the topics, so not very useful for your forum.

SMF Tricks - Free & Premium Responsive Themes for SMF.

peter_mein

I have selected the boards but nothing is doing.

Diego Andrés

Are you using it on that board linked in your profile?
What boards did you select?
Do these topics have images/attachments in the first post?

SMF Tricks - Free & Premium Responsive Themes for SMF.

peter_mein

Yes on this board.
I new install it now.
And now i selcet the board projekte und eigenbau.
I see the image from the thread entwicklerboard but
from the other thraed i see no the images.

Diego Andrés

For attachments it only works if the attachments are inserted (embedded) in the post, it's mentioned in the description.

Quote from: Diego Andrés on September 11, 2021, 09:26:44 AMInclude inserted attachments in posts (SMF 2.1.x)

If they just attached it without inserting then it won't work, the mod doesn't do that.

SMF Tricks - Free & Premium Responsive Themes for SMF.

peter_mein

Ok
I did not know that.
Is it possible you change it ?

Diego Andrés

#10
1.2.1 - 03 October 2021
Added v1.2 improvements to SMF 2.0.x version.

1.2 - 03 October 2021
Now using slick.min for faster loading time.
Added cache to improve performance.
Minor fixes.
Russian translation provided by Bugo.

1.1 - 02 October 2021
Check for permissions to see attachments if the attachments option is enabled (SMF 2.1).
Spanish translation.

Thanks to @Bugo for contributing with some fixes and russian translation

PS: SMF 2.0.x version (file) was not updated, might update later idk Added in v1.2.1



Quote from: peter_mein on September 11, 2021, 05:57:41 PMOk
I did not know that.
Is it possible you change it ?

No I don't think I'll do that, the mod is not designed for that purpose

SMF Tricks - Free & Premium Responsive Themes for SMF.

Diego Andrés

1.2.2 - 03 December 2021
Fixed missing alt attribute in images

SMF Tricks - Free & Premium Responsive Themes for SMF.

AlanDewey

Seems to be working ok,  did I miss something?

SMF 2.1.1  php 7.1.26

error log grows quickly with


 Guest
51.222.253.9
c5ec9522bc36712a6edc25b0f588cfcc
https://www.ccsforum.com/index.php?board=1.225
C:/inetpub/wwwroot/www.ccsforum.com/Sources/FirstTopicImage.php (Line 294)
Backtrace information

Type of error: Undefined
Error message Select
8: Undefined offset: 2



and

Type of error
Undefined_vars
Error message
8: Undefined offset: 2
File
C:/inetpub/wwwroot/www.ccsforum.com/Sources/FirstTopicImage.php
Line
294
URL of page causing the error
https://www.ccsforum.com/index.php?board=1.225
Backtrace information

    #0: smf_error_handler()
    Called from C:\inetpub\wwwroot\www.ccsforum.com\Sources\FirstTopicImage.php on line 294
    #1: loadImages()
    Called from C:\inetpub\wwwroot\www.ccsforum.com\Sources\FirstTopicImage.php on line 131
    #2: block()
    Called from C:\inetpub\wwwroot\www.ccsforum.com\Sources\Subs.php on line 5763
    #3: call_integration_hook()
    Called from C:\inetpub\wwwroot\www.ccsforum.com\Sources\Load.php on line 2640
    #4: loadTheme()
    Called from C:\inetpub\wwwroot\www.ccsforum.com\index.php on line 230
    #5: smf_main()
    Called from C:\inetpub\wwwroot\www.ccsforum.com\index.php on line 187

Causing lots of electrons to push each other around since 1985.

Diego Andrés

The mod has a known bug logged on GitHub, this one appears to be a different one so I'll try to have a look at the mod today

SMF Tricks - Free & Premium Responsive Themes for SMF.

AlanDewey

 :D   Glad to know it was not something I did wrong.   :laugh:
Causing lots of electrons to push each other around since 1985.

Diego Andrés

v1.3 might fix your problem @AlanDewey

1.3 - 21 February 2022
- Fixed cache bug displaying wrong images.
- Fixed trying to display empty images.

SMF Tricks - Free & Premium Responsive Themes for SMF.

AlanDewey

Installed.

No more errors in the error log  :D  ;D  :laugh:

Nice mod.  Thank you.
Causing lots of electrons to push each other around since 1985.

atanua

This is a very interesting mod. I installed it on a SMF 2.0.17 version but it gives me this error message

Fatal error: Access to undeclared static property: FirstTopicImage::$_img_pattern in Sources/FirstTopicImage.php on line 254

Kindred

What version of php are you using?
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

atanua


Diego Andrés

Need at least 7.0 I think.
Also your forum is outdated, 2.0.19 is the latest patch for 2.0.x

SMF Tricks - Free & Premium Responsive Themes for SMF.

atanua

Quote from: Diego Andrés on August 05, 2022, 03:22:03 PMNeed at least 7.0 I think.
Also your forum is outdated, 2.0.19 is the latest patch for 2.0.x

Thank you for letting me know. This is probably the reason then

Rgvill

Quote from: Diego Andrés on September 11, 2021, 05:51:40 PMFor attachments it only works if the attachments are inserted (embedded) in the post, it's mentioned in the description.

Quote from: Diego Andrés on September 11, 2021, 09:26:44 AMInclude inserted attachments in posts (SMF 2.1.x)

If they just attached it without inserting then it won't work, the mod doesn't do that.


This is what exactly I need! Do you know of any mod that automatically attach and insert an attachment?

Advertisement: