Archive for myfreeforum.org Before posting please check the "stickies" in the support forums.
Please ask questions in real English and not "txt". You will get a better response.
Please do not ask support questions via PMs.
 


       myfreeforum.org Forum Index -> What's new? Announcements!
myff admin

phpBB2: New gallery options

Thanks to "K" for pushing for these.

The gallery can now include an optional upload form. This is done with a few new options that are easier seen than explained. Note one of these options will turn off the gallery display so you can just show an upload form on its own.
K

Haha, no thank you.

For some reason I had to dive into the subsilver template code and copy the gallery code from there and post it into my regular gallery portal to make it work... or is that normal?
myff admin

It does strike me that all sorts of things could be done to improve the template cosmetics. Like having a show hide system for the upload.

As another aside once all forums are moved off slarti, they will all be running on a version of php that would allow for a file upload progress bar, and there will be the chance to change the internal system to work faster.

Both those things will require some more work of course.
myff admin

K wrote:
Haha, no thank you.

For some reason I had to dive into the subsilver template code and copy the gallery code from there and post it into my regular gallery portal to make it work... or is that normal?


If you have been using an edited gallery template, then it simply won't have the new features.

That is the trade off to allowing people to edit, this applies also to copies of portals since they automatically create a copy of the template which again won't get the updates.

No easy ways around that, but then that is a consequence of the myff approach to forums, we give the admin an awful lot of powerful features not found elsewhere, but with that power does come a need for more technical literacy than the other forums systems out there. You can like or dislike that approach, but it is our niche.
K

An issue I noticed is that when I change the thumb sizes settings, nothing changes. I tried several sizes, some extremely big and some extremely small, and nothing changed with the images themselves.

EDIT: Your approach is why I like your forums so much

Oh, and, I really like that "Is gallery shown" option. Nice touch!
myff admin

That is correct.

But you can use the size in the template if you want.

There is a macro {GALLERY_SIZE} that will translater to 'width="150" height="150"'

and for each image there are macros:

{gallery_row.gallery_col.THUMBNAIL} which contains an img tag without the details.

and

{gallery_row.gallery_col.THUMBNAIL_IMG} which simply has the image link, so you can do your own html like:

<img border="0" class="gallerythumbimage" src="{gallery_row.gallery_col.THUMBNAIL_IMG}" {GALLERY_SIZE} />

note that the stored thumbnail is a fixed size, these are just display options.
K

Ah ok, thanks!

One more thing I noticed is that when I take the gallery.tpl and create a mygallery.tpl out of it, it only shows the new upload section when you view mygallery.

I tried the same settings as gallery just to be sure, and it still does it, but gallery shows up fine.

Log in with the Test account, go to Profile at top, then Manage Gallery on the right to see what I mean. I dont think I can directly link that unless your signed in.


EDIT: and all my customized code is all "reset" to the new gallery code, so its not that
myff admin

Sorry the template was using the switch:

S_GALLERY_SHOWGALLERY

this gets copied to:

S_MYGALLERY_SHOWMYGALLERY

and hence does not work

I have altered the code and template, you can just edit the new template to :

S_MYGALLERY_SHOWIMAGES

and it should work.
K

So anywhere that says S_MYGALLERY_SHOWMYGALLERY, change to S_MYGALLERY_SHOWIMAGES?

No problem. Once again, I sincerely appreciate all the time you put into this.

Sorry for all the problems too.
myff admin

K wrote:
So anywhere that says S_MYGALLERY_SHOWMYGALLERY, change to S_MYGALLERY_SHOWIMAGES?

No problem. Once again, I sincerely appreciate all the time you put into this.

Sorry for all the problems too.


There should only be one place.


Basically copying a template just does a string substitution of GALLERY to MYGALLERY hence it is vital that the word GALLERY is avoided when naming switches  
K

Haha! We all make mistakes. At least it was something easy to fix.
K

OK, sorry, but i thought of one more thing, if feasable.

I know you have it showing normal and thumb link to use as you upload, but if a member can manage attachments/uploads, wouldnt they want to be able to see that link again incase they need it again. I know they can just reupload but that would be a pain in some cases.

Now, I tried this bit from what i took out of the new < script > portion you have at top and added it with the save and delete button to vanish if not in edit mode, but as i guessed it wouldnt work due to some internal coding:
Code:
<!-- BEGIN switch_mygallery_edit -->  
      <tr>
  
    <td class="row2"><span class="topictitle"><input type="submit" name="save" value="Save"></span>
     <span class="topictitle"><input type="submit" name="delete" value="Delete"></span></td>
  
    <td class="row2"><div align="right">
   To post on forum use:<textarea id="bbcode" onClick="SelectAll(\'bbcode\')" rows="1" cols="80">{S_MYGALLERY_BBCODE}</textarea><br/>
   To post thumbnail on forum use:<textarea id="bbcodet" onClick="SelectAll(\'bbcodet\')" rows="1" cols="80">{S_MYGALLERY_THUMBBBCODE}</textarea>
   </span></div></td>
      </tr>
    </form>
<!-- END switch_mygallery_edit -->


It shows up alright, as you can see if you log into Test again, but the area are blank.
myff admin

I have tweaked things, template will need copying again. You can just use delete on cms_mygallery.tpl in the editor to revert.
K

No actually, besides having to recopy regular gallery again, whatever you did worked just fine with the edits i had for mygallery

Alright... now im done with the questions. I promise... for now.  
myff admin

I guess that would have been the case as you basically made sensible assumptions about what macros to use.

I didn't do the work so as to make your choices work, but added the macros that I felt were consistent and obviously we came to the same result.
SRSeditor

Sorry to be a dummy but if I copy the gallery portal to a new one so I can create a user gallery how easy is it to edit it's template to move the upload part below the displayed pictures?
myff admin

Very easy.

The upload bit is:

Code:

<!-- IF S_GALLERY_SHOWUPLOAD -->

all the stuff between

<!-- ENDIF -->


So it can be moved to where you want.

Just take your time, print it out if need be, so you can see the structure.
SRSeditor

myff admin wrote:
Very easy.

The upload bit is:

Code:

<!-- IF S_GALLERY_SHOWUPLOAD -->

all the stuff between

<!-- ENDIF -->


So it can be moved to where you want.

Just take your time, print it out if need be, so you can see the structure.


Brill. Thanks

       myfreeforum.org Forum Index -> What's new? Announcements!
Page 1 of 1
Create your own free forum | Buy a domain to use with your forum