Advertisement:

Author Topic: Custom View of Attachments  (Read 25453 times)

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,523
  • Gender: Male
    • dragomano on GitHub
    • @dragomano on Twitter
    • Russian translations for SMF mods
Re: Custom View of Attachments
« Reply #40 on: January 04, 2013, 04:10:19 AM »
Do you want only the small spaces between attachments? Just open Subs-CustomView.php, find
Code: [Select]
<table width="90%">and remove width attribute.

Offline Arvacon

  • Semi-Newbie
  • *
  • Posts: 98
  • Gender: Male
    • ToolMachines.gr
Re: Custom View of Attachments
« Reply #41 on: January 04, 2013, 05:48:43 AM »
Actually I want my attachment pictures to look like at this forum's post http://www.cnchobby.gr/forum/default.aspx?g=posts&m=20208#post20208 .
Try to zoom-in, zoom-out and you will understand what I mean.
I did the change that you said at the code, but that is not exactly what I need.
If you can't open the above link, tell me to take some screen shots for you.

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,523
  • Gender: Male
    • dragomano on GitHub
    • @dragomano on Twitter
    • Russian translations for SMF mods
Re: Custom View of Attachments
« Reply #42 on: January 04, 2013, 06:37:03 AM »
Try this file, at your own risk :)

Offline Arvacon

  • Semi-Newbie
  • *
  • Posts: 98
  • Gender: Male
    • ToolMachines.gr
Re: Custom View of Attachments
« Reply #43 on: January 04, 2013, 07:03:10 AM »
Friend I don't know how to thank you!
At my local installation it workes like charm!  :D

Thank you very much  :)
I will test it at my live forum too and if there is any problem, I will inform you.

Grettings from Greece!
Kostas

Offline Arvacon

  • Semi-Newbie
  • *
  • Posts: 98
  • Gender: Male
    • ToolMachines.gr
Re: Custom View of Attachments
« Reply #44 on: January 04, 2013, 02:36:53 PM »
Hi Bugo.
I noticed that when you have 1024x768 resolution, it keeps have an uncompleted space at the right side, when it could be filled with pictures too.
That happens at the other resolutions too, but it seems vividly at the above resolution, as the pictures follow two vertical series instead of 3.
Is there any way to correct this too? 

Offline Arvacon

  • Semi-Newbie
  • *
  • Posts: 98
  • Gender: Male
    • ToolMachines.gr
Re: Custom View of Attachments
« Reply #45 on: January 04, 2013, 03:18:37 PM »
Finally I found a problem  :(
The appearance of the posts doesn't looks correct now. This had happen again when I first installed your mod, but after I installed the new hooks, everything was fine.
What do I need to change to fix this and the above post's problem too?

« Last Edit: January 04, 2013, 07:39:08 PM by Arvacon »

Offline Hristo

  • Jr. Member
  • **
  • Posts: 319
  • Gender: Male
Re: Custom View of Attachments
« Reply #46 on: January 04, 2013, 05:03:28 PM »
...when it could be filled with pictures too.
....
Is there any way to correct this too?
No, there is no enough space for another image. I have no access to your forum, but I'm sure this can be fixed with some small css tweaks. Just use your browser's dev tool to check the left and right attached images margin, then apply it in your theme's index.css.


Offline Arvacon

  • Semi-Newbie
  • *
  • Posts: 98
  • Gender: Male
    • ToolMachines.gr
Re: Custom View of Attachments
« Reply #47 on: January 04, 2013, 07:06:19 PM »
I think there is space for another image, it just need to be closer to each other as it happens when you have the default Subs-CustomView.php file and you choose "Max attachments per line" = 3
(as at the bellow photo).

Edit: I forgot to mention that I found also that the text at posts, when it has a lot of letters, it seems as at the photo, with a bar under them too, but I don't know if this is because of this mod or any other mod.
Just in case this is easy to be fixed or this mod cause it, if you have any solution for this too, I would appreciate if you could help about this too.
  Finally this is not an issue of this mod, it is just happening when you have lot of letters in a row, without meaning. When you have words and documents, everything works fine, as they mention here http://www.simplemachines.org/community/index.php?topic=488069.0

Edit2: I found that when I have the new Subs-CustomView.php file installed at my forum, except from the problems at the template's appearance, the quick edit function's save button doesn't respond. If I replace this file with the default one, the template and the quick edit are fine. Maybe these info help u more.
« Last Edit: January 05, 2013, 12:51:05 AM by Arvacon »

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,523
  • Gender: Male
    • dragomano on GitHub
    • @dragomano on Twitter
    • Russian translations for SMF mods
Re: Custom View of Attachments
« Reply #48 on: January 05, 2013, 04:14:47 AM »
Test new version, please.

Offline Arvacon

  • Semi-Newbie
  • *
  • Posts: 98
  • Gender: Male
    • ToolMachines.gr
Re: Custom View of Attachments
« Reply #49 on: January 05, 2013, 06:25:40 AM »
I tried it just now and it seems the template problem solved.
Also the pictures now can auto aligned.
I just see a small problem when you have different size pictures at the same post, as it seems at the screen shots bellow. Actually that is not so big problem, but it would be nice if you could correct it too (by the way, if you have same size pictures, everything looks in line as at "same size" photos bellow).
Thank you for your time, I really appreciate it.

Edit: I made some corrections at the picture's names.
« Last Edit: January 05, 2013, 04:07:38 PM by Arvacon »

Offline Calaad

  • Semi-Newbie
  • *
  • Posts: 12
Re: Custom View of Attachments
« Reply #50 on: February 28, 2013, 12:08:43 PM »
Hello,

I just add this mod to my forum. Last version of forum, last version of mod.

When i select "in the line" with or without filename, attachments just disappear. They're back when i select "In column". I install new hook without any change.

I've custom theme, could it be the source of the problem ?

Thank by advance and for the work done !

Calaad.

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,523
  • Gender: Male
    • dragomano on GitHub
    • @dragomano on Twitter
    • Russian translations for SMF mods
Re: Custom View of Attachments
« Reply #51 on: February 28, 2013, 01:12:41 PM »
What theme are you using? SMF version?

Offline Calaad

  • Semi-Newbie
  • *
  • Posts: 12
Re: Custom View of Attachments
« Reply #52 on: March 01, 2013, 03:57:31 AM »
Hello,

I'm using an homemade theme, based on curved. My SMF version is 2.0.4.

If it can help, i join a screenshot of my installed extension.
« Last Edit: March 01, 2013, 04:55:11 AM by Calaad »

Offline Bugo

  • SMF Friend
  • SMF Hero
  • *
  • Posts: 1,523
  • Gender: Male
    • dragomano on GitHub
    • @dragomano on Twitter
    • Russian translations for SMF mods
Re: Custom View of Attachments
« Reply #53 on: March 01, 2013, 05:20:14 AM »
Try New Hooks 0.3, and select "Install in Other Themes" (homemade) on install.

Offline Calaad

  • Semi-Newbie
  • *
  • Posts: 12
Re: Custom View of Attachments
« Reply #54 on: March 01, 2013, 05:28:13 AM »
It works !

Thanks a lot Bugo ! :)

Offline madvex

  • Newbie
  • *
  • Posts: 5
Re: Custom View of Attachments
« Reply #55 on: September 29, 2013, 12:32:27 PM »
Try New Hooks 0.3, and select "Install in Other Themes" (homemade) on install.

In SMF 2.0.5 the New Hooks 0.3 file is a must.

As others reported, I also had the horizontal setting causing all attachments to disappear.  The New Hooks file install rectified those issues.
Some manual tweaks for padding in the CSS it works great!

Excellent mod! Thanks!

PS: The manual CSS tweak I performed for the padding is as follows:
In your current theme CSS folder, edit "index.css" as follows:

Find:
Code: [Select]
.attachments div {
padding: 0 0.5em;
}

Replace with:
Code: [Select]
.attachments div {
  padding: 2em 1em;
}

I'd recommend using firebug and play with the settings before making the actual edit so you can see the effects in real-time.
Or, you can comment out the old lines if you want to easily revert.
« Last Edit: September 29, 2013, 01:24:06 PM by madvex »