TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,966
  • Latest: safir45
Stats
  • Total Posts: 195,989
  • Total Topics: 21,322
  • Online today: 1,078
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 422
  • Total: 422

nifty "collapse" feature on blocks that showed up recently

Started by iowamf, November 21, 2005, 09:09:09 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

iowamf

Wow - that's a great new feature.

I bet many are wishing you'd turn 0.8 loose ... that feature alone is killer.

Note, I have tried to remove all the buttons from the top and would like to put the right "upshrink" next to where you put that little collapse icon ... could you let us know how you put that collapse icon in the content bar?  I'd like to try and add the right upshrink button there.

Might have to nominate TinyPortal.NET for TP site of the month ... just kidding of course  ;)

[attachment deleted by admin]

crip


Nokonium

That really is neat,

But  :-\  you seem to have done something else at the same time, the left sidebar has had a trim.

[attachment deleted by admin]

bloc

Nokonium, I see it. Opera again.  ;) will correct that.

iowamf, its just the a image right-aligned placed first in the the containing div of each block. Currently the code look like (TPortalBlocks.template.php):

...
....
     }
     echo '<div', ($theme ? ' class="tborder"' : ''), ' style="margin-bottom: 5px;">
<a href="javascript: void(0);" onclick="toggle(\''.$block['id'].'\')"><img style="margin: 4px;" align="right" src="'.$settings['images_url'].'/collapse.gif" border="0" alt="" ></a>';

     if ($theme || $block['frame'] == 'title')
....
....

Nokonium


Maya

Okay I popped the code in np, and they showed up, no sweat... but it is almost like they aren't linked.. nothing happens ..no collapse

I hope I didn't miss something really dumb ???

(I love these though, it gives a personal flexability to the site...)

Skhilled

I tried it and got a javascript void(0) and no image, just a place holder... Tried putting the gif in almost every image dir I could think of...

snork13

they are not showing up because where you place the code the image request is from
.$settings['images_url'], but  $settings is not defined above ;)

ie

function TPortal_sidebar($side)
{
   global $context , $settings, $scripturl;

Skhilled

Ah, ok. Did that but still get the same error and errors on page. But now I do see them but not working.

Maya

Mine are there but aren't working either, i think its missing a code snippet is all..

This website is proudly hosted on Crocweb Cloud Website Hosting.