Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

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

#481 2008-06-04 20:22:38

the_ghost
Plugin Author
From: Minsk, The Republic of Belarus
Registered: 2007-07-26
Posts: 907
Website

Re: smd_slimbox

May be you have some programm which cuts advert? Or something like this?


Providing help in hacking ATM! Come to courses and don’t forget to bring us notebook and hammer! What for notebook? What a kind of hacker you are without notebok?

Offline

#482 2008-06-04 22:09:17

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

Re: smd_slimbox

Sheru wrote:

I need one image in a row and its caption(image description) along image side.

Since you say it’s working, I guess you just need to apply some markup and CSS to move the caption to the side. The best thing to do is probably to surround each “cell” (i.e. a thumbnail and its caption) with a tag of a particular class and tell the plugin to output the caption. So your tag might be:

<div class="gallery">
<txp:smd_slimbox category="?blah-blah" wraptag="div" cellclass="thumb" thumbtext="?caption" />
</div>

Then you can use this CSS to float the image left and its caption right:

.gallery {
  width:400px; // Or however wide one thumb + some caption text is
}
.thumb { // The thumbnail
  float:left;
}
.thumb span { // The caption
  float:right;
  clear:right;
}

It’s not tested, but something along those lines should give you a starting point to get the layout you require. I hope!

EDITED to fix the category equals sign as Sheru spotted

Last edited by Bloke (2008-06-05 05:58:39)


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

Online

#483 2008-06-04 22:30:11

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

Re: smd_slimbox

MattE wrote:

textpattern is removing my Mootools and Slimbox embeds from the output.

Totally odd. Never seen that before. It looks as if your first (default) stylesheet is getting swallowed as well? Are things like jQuery showing up in the source on the admin side or is this just a client-side problem?

Aside from what the_ghost suggested about some third party thing (ZoneAlarm or equivalent?) stripping out content I’m stumped. Anyone else?


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

Online

#484 2008-06-05 04:35:45

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Greetings, I am trying to display one image in a row and its caption but can’t make so. If you know, help me.

Thanks.
Sheru

Offline

#485 2008-06-05 04:39:08

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Greetings, Thank you Stef for your response and kind help. I will now try to implement what you have suggested. I will com in touch.

Once again thank you so much for your time.
Sheru

Offline

#486 2008-06-05 05:40:21

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Greetings from Sheru, Thank so much Stef for your help. It’s working in a way that I wished to display. Still, I having a problem.

Stef Wrote:
<div class=“gallery”>
<txp:smd_slimbox category”?Mac-Screen-Shoots” wraptag=“div” cellclass=“thumb” thumbtext=”?caption” />

This displays all categories images. I need to display only of Mac-Screen-Shoots image in this category.

Image Scenario is:

I have parents=Screenshoots, Alogwith I have got two categories of Images which are given below.

a.) PC Screen Shots
b.) Mac Screen Shots

I wish to display image only by cateogry wise.
Could you please help me on this?

Thank a lot
Sheru

Offline

#487 2008-06-05 05:56:49

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

Re: smd_slimbox

Sheru wrote:

<txp:smd_slimbox category”?Mac-Screen-Shoots” wraptag=“div” cellclass=“thumb” thumbtext=”?caption” />

Try this:

<txp:smd_slimbox category="Mac-Screen-Shoots" wraptag="div" cellclass="thumb" thumbtext="?caption" />

You don’t need the question mark unless you are pulling the value from an article (e.g. custom) field. Your code was missing an = sign (because my example did, sorry!) and would try and search the current article for a custom field named Mac-Screen-Shoots.

If that doesn’t work, and you are using TXP 4.0.5 or above, try using lower-case for the name of your category (though this is a long shot, as I think it only affects custom fields).

Hope one of those fixes it for you.

Last edited by Bloke (2008-06-05 05:57:30)


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

Online

#488 2008-06-05 06:17:35

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Greetings, As I am using smd_slimbox first time, I have learnt much from you. Thank you a lot from bottom of my heart for your precious time and great help. It perfectly Worked for me.

One more time to say, you have done great job creating smd plugin and it’s amazing and wonderful. Hope Txp comunity flourish like this.

Thank you from Sheru
Sheru

Offline

#489 2008-06-05 12:40:46

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Greetings, Dear Stef, Thanks a lot for your kind help. Once again I want your help in CSS. As I have little idea on CSS, Caption is shown on the bottom of image but aligned to right. I trying to take the caption at the top but aligned to right with little space between image and caption.

For Example

Image1 caption1

Image2 caption2

I tried to play on the css that you had suggested for caption

.thumb span { // The caption float:right; clear:right;
}

But no success. Could you please help me?
Thank you so much.
Sheru

Last edited by Sheru (2008-06-05 12:42:44)

Offline

#490 2008-06-05 13:28:26

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

Re: smd_slimbox

Sheru wrote:

I trying to take the caption at the top but aligned to right with little space between image and caption.

Try using thumbtext="above:?caption" which will put the caption first in the page flow. Then, when you float it right it should stay towards the top of the image (in theory, though I haven’t tried it!)

Add some margin: or padding: to the span element to push it away from the thumbnail, for example:

.thumb span {
  float: right;
  clear: right;
  margin-left: 2em;
}

btw, if you would like to learn CSS, a gentle introduction to the concepts and its usage can be found in the htmldog tutorial

Last edited by Bloke (2008-06-05 13:30:37)


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

Online

#491 2008-06-06 05:44:54

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Warm Greetings! Dear Stef, Thank you a lot for your kind help. Thanks for the CSS and htmldog tutorial. Those are great for me.

With the CSS that you suggested displays the text above the Image. If caption is shorter in length then image align to left and caption on the top right towards to image. This is OK. But problem is When caption is larger, in such time image is seen around middle because some text comes left side down the bottom that pushes the image to near middle or disorder.

But as I add margin-right and margin-left

.gallery {
  width:520px; // Or however wide one thumb + some caption text is
}
.thumb { // The thumbnail
  float:left;
  padding: 0 0 35px 0;
}
.thumb span { // The caption
  float:right;
  clear:right;
  margin-right: 30em; // When I add this, image align left and whole caption on above the image.
  margin-left: 15em;  // When I add this, Only first row of the captions shifts from left(If caption is longer) but rest of captions don't have this effect and goes to left( meaning caption start from starting of the left.)
 }

I am trying much to display. But still no success..
Sorry for bothering you..

Thank you from bottom of my heart.
Sheru

Last edited by Sheru (2008-06-06 05:54:28)

Offline

#492 2008-06-06 06:10:50

Sheru
Member
From: Kathmandu, Nepal
Registered: 2007-05-09
Posts: 96

Re: smd_slimbox

Warm Greetings From Sheru, Dear Stef, Once Again thank you so much for your great help and precious time. Can’t forget it. I think with your help, problem seems solved. It’s your great help that made possible.

.thumb span { // The caption
  float:right;
  clear:right;
  margin-left: 15em;  
  position: absolute; // This line helped to fix above problem.
 }

Once Again thank you for everything, I will come in touch with you.
Sheru

Offline

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

Board footer

Powered by FluxBB