Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

  1. Index
  2. » Plugin support
  3. » smd_slimbox

#661 2010-11-08 10:05:31

jacobm
New Member
From: Bristol, UK
Registered: 2010-11-07
Posts: 5

Re: smd_slimbox

Hi,

I’m working on an artist’s gallery page at http://www.sarahlederman.com/gallery/. I’ve managed to divide the pictures into categories.

How do I get the first category, “Recent-work”, to open automatically when somebody clicks on the /gallery page? Or do I have to link directly to http://www.sarahlederman.com/Gallery/?c=Recent-Work? It would be good if there was a neater solution.

My code is currently <txp:category_list parent="Gallery" type="image" exclude="Gallery" sort="ID desc" section="Gallery" wraptag="ul" break="li" />

Appreciate any help,
Jacob

Last edited by jacobm (2010-11-08 10:06:32)

Offline

#662 2010-11-08 10:26:09

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,456
Website GitHub

Re: smd_slimbox

jacobm wrote:

How do I get the first category, “Recent-work”, to open automatically when somebody clicks on the /gallery page?

Couple of ways I can think of:

1) Use an .htaccess rule so that anyone hitting the raw /Gallery link is redirected to /Gallery/?c=Recent-Work
2) (untested) On TXP 4.3.0 use <txp:if_category type="image"><txp:else /><txp:smd_slimbox category="Recent-Work" ... /></txp:if_category>

As long as you have a form defined for your gallery layout you won’t be repeating much code with the second idea.

There’s no real neat way of doing it that I can think of, but someone else may have some cunning ideas.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#663 2010-11-08 13:13:24

jacobm
New Member
From: Bristol, UK
Registered: 2010-11-07
Posts: 5

Re: smd_slimbox

Thanks for that – I tried your second option even though I am still on Textpattern 4.0.5 (bit scared to update it) and it worked a treat! Not sure why it worked on the older version of Textpattern, but it does, so thank you!

Offline

#664 2010-11-08 13:27:25

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,456
Website GitHub

Re: smd_slimbox

jacobm wrote:

Not sure why it worked on the older version of Textpattern, but it does, so thank you!

If you’re on an ancient TXP then you can get away with removing the type="image" since that was introduced in 4.3.0. I suspect if you put the site in testing mode you’ll get a warning (or maybe not: can’t remember if 4.0.5 issues attribute warnings or not).

If you’re concerned about upgrading, I suggest using something like XAMPP. Set up the environment, copy your current live database and TXP files to it, get it all working on the local environment and then perform the local upgrade. After that, stick the local site in Testing mode and you should see how much fallout there is (tags not working, things to alter due to attribute name changes, etc) and work through them. Once you’re happy it all works locally, you can export that database, perform the upgrade for real and upload the new DB.

4.0.8 as a minimum is recommended for tags-in-tags support because you can do so much more with it. But I’d of course recommend the most recent release :-)

Last edited by Bloke (2010-11-08 13:29:14)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#665 2010-11-08 22:52:34

jacobm
New Member
From: Bristol, UK
Registered: 2010-11-07
Posts: 5

Re: smd_slimbox

Thanks Bloke, I appreciate your time.

I did consider using XAMPP, and have done so in the past, but to be honest am pretty much happy with the site as it is now, and don’t want to make extra work for myself! (Web development is not really my thing (I’m a musician!), just doing a favour for a friend really- want to get back to my guitar! I’m planning on creating my a website for myself sometime soon though, so this info will come in handy when the time comes.)

Thanks again,
Jacob

Offline

#666 2010-11-08 23:01:49

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,456
Website GitHub

Re: smd_slimbox

jacobm wrote:

Web development is not really my thing (I’m a musician!)

Ah, join the club :-) Except I suck at guitar; synths are my weapon of choice. Especially the analog-sounding squelchy ones.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#667 2010-11-08 23:10:42

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: smd_slimbox

Bloke wrote:

4.0.8 as a minimum is recommended for tags-in-tags support

Cough ;) not trying to be smart, honest ;)

Offline

#668 2010-11-08 23:18:05

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,456
Website GitHub

Re: smd_slimbox

Els

Yeah, you’re right that technically 4.0.7 was the official start of tags-in-tags. I just tend to skip over it, since the conditional bugs and fixes to section_list and category_list rendered the version obsolete within a couple of months. But 4.0.7 or higher will certainly do the trick if you can put up with the weird behaviour.

Last edited by Bloke (2010-11-08 23:18:42)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#669 2010-11-08 23:25:39

els
Moderator
From: The Netherlands
Registered: 2004-06-06
Posts: 7,458

Re: smd_slimbox

Oh, wish I had thought of a wise reply like that back then (instead of doh!) ;)

Offline

#670 2010-12-18 03:53:41

wchung
Member
Registered: 2009-04-23
Posts: 29

Re: smd_slimbox

I just upgraded to Textpattern v. 4.3.0. Everything else seems to work fine but the smd_slimbox plugin. It displays the thumbnails, but when I click on an image, it just shows the large image without the expanding routine with the navigation links. Is there some way to get this to work with the new version?
Thanks!

Offline

#671 2010-12-18 13:08:27

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,456
Website GitHub

Re: smd_slimbox

wchung wrote:

It displays the thumbnails

Then smd_slimbox is probably doing its job correctly; that’s as far as the plugin goes. From there, jQuery / javascript takes over to display the large image and navigation.

Take a look at the lightbox package you’re using (slimbox2 ?) and check you’re using the most recent version that is compatible with the version of jQuery that is installed (1.4.3? 1.4.4?). Textpattern 4.3.0 ships with a new version of jQuery so check it’s working OK with the version of lightbox you are using.

Also, if you have Firebug, check the Net pane and see if there are any scripts that aren’t loading, or check the Console to see if there are any javascript errors that you need to fix. Unless I can see a link to the site I’m afraid I can’t advise any further.


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#672 2011-01-22 22:19:59

johnpeat
New Member
Registered: 2011-01-22
Posts: 5

Re: smd_slimbox

I think I’ve found a bug/oversight in the way ?id works with smd_slimbox.

Take this example

<txp:smd_slimbox imageid=“3,4” thumbsize=“200,” groupname=”?id” />

In that case, ?id is resolved as the imageid and not the articleid – which means there’s no way to group those images into a gallery just for that article.

I think using ?id for both article and image ids is daft – surely they should be different to avoid this sort of cockup?

Offline

  1. Index
  2. » Plugin support
  3. » smd_slimbox

Board footer

Powered by FluxBB