Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

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

#625 2009-04-15 15:29:29

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

Re: smd_slimbox

owenswain wrote:

Below please find both the directory tree… <snip>

Right, so you have your TXP install in a sub-directory. OK, that makes it easier to grasp. So I assume your Admin->Prefs setting for site url is onionboy.ca/blog? In which case you’re correct, though a minor amendment:

 <script type="text/javascript" src="<txp:site_url />textpatten/jquery.js"></script>
	<script type="text/javascript" src="<txp:site_url />textpattern/src/slimbox2.js"></script>
	<script type="text/javascript" src="<txp:site_url />textpattern/src/scripts/effects.js"></script>
	<txp:css format="link" />
	<link rel="stylesheet" href="<txp:site_url />textpattern/src/css/slimbox2.css" type="text/css" media="screen" />

(Note you don’t use the leading / if you are using <txp:site_url/> since it adds them for you, sorry for the bogus info, I didn’t realise you were using that tag).

The remaining errors are probably going to be because of some other tag that has been inadvertently mangled or because I’ve never tested slimbox in a subdirectory installation and it’s complaining. If you don’t mind me having a poke around in your admin panel, feel free to send me a site login and I’ll see if I can figure out what’s going on.

Not wanting to bail too soon but would there be any point in trying to begin from scratch

Probably not at this stage. The template is out of date so you’d have to go back and redo all the stuff you’ve done already. I’m sure it’s something simple I’ve overlooked (it always is!), I just can’t quite see what it is from this side of the Internet :-)


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

#626 2009-04-15 16:17:15

owenswain
Member
From: Canada
Registered: 2007-11-25
Posts: 27
Website

Re: smd_slimbox

Correct, Admin->Prefs setting for site url is onionboy.ca/blog

OK, I have made that minor amendment.

I am more than happy to have you poke around – very kind. I will email that info to you in a moment and stay out of there myself until I hear back from you. In the mean time I will returning to finishing up the painting(s) for my wife’s birthday, which is today so like usual I am going pear shaped under a self imposed deadline.

Offline

#627 2009-04-16 08:55:47

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

Re: smd_slimbox

owenswain

All fixed. Mail sent detailing what I did.

Last edited by Bloke (2009-04-16 08:56:00)


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

#628 2009-04-16 14:10:36

owenswain
Member
From: Canada
Registered: 2007-11-25
Posts: 27
Website

Re: smd_slimbox

Hi Stef, remarkable. Thanks. I mailed back.

Offline

#629 2009-04-17 02:55:03

owenswain
Member
From: Canada
Registered: 2007-11-25
Posts: 27
Website

Re: smd_slimbox

Hello Stef, thanks again for your help. It means a lot.

1. Sadly the slimbox is still not functioning. Clicking on an image leads to a pop up window only and not the snazzy slimbox display. I have no idea at all where to begin to look let alone what to look for. Your wizardry certainly solved the initial problems so here I am at your door again.

2. There is a problem now with comments as in I can’t leave one at all. I know I copied the Forms comment and comments_form correctly from those provided in the Palpable download files.

I am wondering if the problem is because the default TXP Template uses comments_display however my limited logic would suggest that if that form is not called for in the Palpable default Page it’s existence among the listed Forms would be moot (?)

For the record, the files provided are:

[comments]

<dl class="info">
<txp:if_different>
<dt>Date</dt>
<dd class ="date"><txp:comment_time format="%d %b %y" /></dd>
</txp:if_different>
<dt>Time</dt>
<dd class="time"><txp:comment_time format="%H:%M" /> <txp:comment_permlink>#</txp:comment_permlink></dd>
<dt>Author</dt>
<dd class="author"><txp:comment_name /></dd>
</dl>
<div class="body">
<txp:message />
</div>

[comment_form]

<li><txp:permlink><txp:title /></txp:permlink></li>

Thanks again.

Last edited by owenswain (2009-04-17 12:05:32)

Offline

#630 2009-04-17 03:11:16

owenswain
Member
From: Canada
Registered: 2007-11-25
Posts: 27
Website

Re: smd_slimbox

Stef,
P.S. to the comments issue:

before calling it a night I decided to just ignore the Palpable Forms for comments and comment_form and replaced them with the code from the default TXP Template files (which I keep backed up right in my TXP) and low and behold the comments worked. There is a glitch in the display where Forget get’s crammed over and muddled with Name and Email. If I could figure that out I think I’d just leave that part of this mess as is. Ideas?

Offline

#631 2009-04-17 22:46:58

owenswain
Member
From: Canada
Registered: 2007-11-25
Posts: 27
Website

Re: smd_slimbox

@ Stef,

happily I ferreted about some more and now have the slimbox working, or mostly. I am pretty happy with what I have deduced on my own but I am stumped now. It was a directory path/to.file issue. Slimbox loads now but is not displaying the images for; loading, close, next, previous. Here’s what I have done:

1. The correct image path/to/file are in place in the slimbox Style css in the TXP and all those images are now housed in my own TXP account.

2. The correct slimbox2.css path/to/file is in place in the Default Page in the tag for the style sheet (namely: <link rel="stylesheet" href="<txp:site_url />textpattern/src/css/slimbox2.css" type="text/css" media="screen" />) .

3. Said slimbox2.css looks like this

/* SLIMBOX */
#lbOverlay {
	position: fixed;
	z-index: 9999;
	left: 0;
top: 0;
	width: 100%;
	height: 100%;
	background-color: #000;
	cursor: pointer;
}
#lbCenter, #lbBottomContainer {
	position: absolute;
	z-index: 9999;
	overflow: 
hidden;
	background-color: #fff;
}
.lbLoading {
	background: #fff url(loading.gif) no-
repeat center;
}
#lbImage {
	position: absolute;
	left: 0;
	top: 0;
border: 10px solid #fff;
	background-repeat: no-repeat;
}
#lbPrevLink, #lbNextLink 
{
	display: block;
	position: absolute;
	top: 0;
	width: 50%;
	outline: none;
}
#lbPrevLink {
	left: 0;
}
#lbPrevLink:hover {
	background: transparent url
(prevlabel.gif) no-repeat 0 15%;
}
#lbNextLink {
	right: 0;
}
#lbNextLink:hover {
background: transparent url(nextlabel.gif) no-repeat 100% 15%;
}
#lbBottom {
	font-
family: Verdana, Arial, Geneva, Helvetica, sans-serif;
	font-size: 10px;
	color: 
#666;
	line-height: 1.4em;
	text-align: left;
	border: 10px solid #fff;
border-top-style: none;
}
#lbCloseLink {
	display: block;
	float: right;
	width: 66px;
height: 22px;
	background: transparent url(closelabel.gif) no-repeat center;
margin: 5px 0;
	outline: none;
}
#lbCaption, #lbNumber {
	margin-right: 71px;
}
#lbCaption 
{
	font-weight: bold;
}

Am I correct assuming that in the above code in each case where it reads url(whatever.gif) that the actual image url does not go in there but rather this coding reads the actual image url within the slimbox.css Style? If this is correct then I must still be missing something. Ideas?

As ever, thanks.

Offline

#632 2009-04-17 23:15:02

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

Re: smd_slimbox

owenswain

Sorry I didn’t get back to you about the slimbox not working the other day. I had a poke around but couldn’t find any obvious reason why it wasn’t working so I went away to think about it. Looks like you found it, good on ya.

Slimbox loads now but is not displaying the images for; loading, close, next, previous… in each case where it reads url(whatever.gif) <snip>

Yes if you’ve uploaded the close.gif, next.gif and so on to a directory that is different to the directory in which the slimbox2.css file resides, then you will have to alter every occurrence of url(imagefile.gif) to include the path/to//the/image. So one of them may end up being something like:

.lbLoading {
	background: #fff url(/images/loading.gif) no-repeat center;
}

if you had put the pictures in your TXP ‘images’ directory.

Last edited by Bloke (2009-04-17 23:20:27)


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

#633 2009-04-18 02:17:25

owenswain
Member
From: Canada
Registered: 2007-11-25
Posts: 27
Website

Re: smd_slimbox

Stef, bless you – you gave me the key.

I did have all my path/to/image/file correct in the Default Page and in slimbox2.css and all my individual image file names correctly matched, i.e. spelled the same in slimbox2.css and in the path/to/file/image in the Default page but here’s the key: For whatever reason slimbox prefers that the image files be located in the same directory as slimbox2.css

As soon as I moved the image files into the same directory as slimbox2.css everything related to slimbox display worked; perfectly.

So, between my novice sleuthing and your expert help (without which the other day all would be lost) it is solved.

AND, I am pretty much there as regards the comments.

NOW, in a different realm I need to find out why my About entry is not showing on the main page where it should; to the left of the sidebar. Sigh. :)

Again, you have been a huge help man and I thank you.

Offline

#634 2009-04-18 16:37:32

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,011
Website GitHub Mastodon Twitter

Re: smd_slimbox

I am starting to experiment with this plugin. Is there a way to use the smd_slimbox with article image?

something like <txp:smd_slimbox imageid='<txp:article_image >' /> … except this would not work as article image returns the whole xhtml img tag.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

#635 2009-04-18 16:52:27

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

Re: smd_slimbox

colak wrote:

Is there a way to use the smd_slimbox with article image?

Yes. If you have a list of image IDs in your article image field then this works:

<txp:smd_slimbox imageid="?article_image" />

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

#636 2009-04-19 08:57:03

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,011
Website GitHub Mastodon Twitter

Re: smd_slimbox

Thanks stef… experimenting:). I’m yet not sure if I should go with this plugin or your more versatile smd_gallery.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

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

Board footer

Powered by FluxBB