Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#457 2009-04-02 00:17:50

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

Re: smd_gallery: super-flexible gallery generator

mlarino wrote:

array ( 0 => ‘\’?article_image\’‘,)

Aha! There’s the problem then. The ?article_image is not being converted to the list of images. It’s being passed literally to the query which is causing it to return nothing. In the ‘missing double quote’ version, the plugin cannot interpret your illegal id attribute so it just shrugs its shoulders and gives you all images instead.

What’s odd is that smd_lib should always strip off the leading ? or ! character. Thus, if you used ?squid and there was no TXP field called ‘squid’, it would use the literal word squid instead. It never leaves the ? behind.

The question is why. I doubt it’s the version of TXP because this is a rudimentary piece of code. It’s almost as if the contents of the id attribute are not being passed to smd_lib at all. One daft question: the quotes around your id attribute are ‘true’ quotes and not ‘curly’ quotes aren’t they? If your site is not in debugging mode, please put it in that mode and see if the plugin throws any other errors. I’m really stumped.

Last edited by Bloke (2009-04-02 00:18:55)


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

#458 2009-04-02 07:33:04

mlarino
Member
Registered: 2007-06-29
Posts: 367

Re: smd_gallery: super-flexible gallery generator

I am going to see what heppens in a new installation of textpattern without any of the other plugins, but I would prefer finding the problem in this one, there is a lot of work into this site already :(
Thats what I get in debugging mode:

Error de etiqueta <txp:smd_gallery 
       id="?article_image" form="gallery"
       collate="quote:{imagedef}:{alt}"/> ->  Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10  on line 66

textpattern/lib/txplib_misc.php(469) : eval()'d code:66 preg_match_all()
textpattern/lib/txplib_misc.php(574) : eval()'d code:198 smd_dolist()
textpattern/publish.php:970 smd_gallery()
processtags()
textpattern/publish.php:929 preg_replace_callback()
textpattern/lib/txplib_misc.php:1460 parse()
textpattern/publish.php:800 parse_form()
textpattern/publish.php:826 doarticle()
textpattern/publish.php:519 parsearticles()
textpattern/publish.php:970 article()

Error de etiqueta <txp:smd_gallery 
       id="?article_image" form="gallery"
       collate="quote:{imagedef}:{alt}"/> ->  Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10  on line 66

textpattern/lib/txplib_misc.php(469) : eval()'d code:66 preg_match_all()
textpattern/lib/txplib_misc.php(574) : eval()'d code:199 smd_dolist()
textpattern/publish.php:970 smd_gallery()
processtags()
textpattern/publish.php:929 preg_replace_callback()
textpattern/lib/txplib_misc.php:1460 parse()
textpattern/publish.php:800 parse_form()
textpattern/publish.php:826 doarticle()
textpattern/publish.php:519 parsearticles()
textpattern/publish.php:970 article()

Offline

#459 2009-04-02 08:32:42

mlarino
Member
Registered: 2007-06-29
Posts: 367

Re: smd_gallery: super-flexible gallery generator

Nothing,
New installation of Textpattern .8 and nothing works
no clue whats going on.

Tag error:  <txp:smd_gallery 
       id="?article_image" form="gallery"
       collate="quote:{imagedef}:{alt}"/> ->  Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10  on line 66
Tag error:  <txp:smd_gallery 
       id="?article_image" form="gallery"
       collate="quote:{imagedef}:{alt}"/> ->  Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10  on line 66

and I get this on the .6 installation

Error de etiqueta <txp:smd_gallery 
   id="?article_image" form="gallery"
   collate="quote:{imagedef}:{alt}"/> ->  Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10  on line 66

textpattern/lib/txplib_misc.php(469) : eval()'d code:66 preg_match_all()
textpattern/lib/txplib_misc.php(574) : eval()'d code:198 smd_dolist()
textpattern/publish.php:970 smd_gallery()
processtags()
textpattern/publish.php:929 preg_replace_callback()
textpattern/lib/txplib_misc.php:1460 parse()
textpattern/publish.php:800 parse_form()
textpattern/publish.php:826 doarticle()
textpattern/publish.php:519 parsearticles()
textpattern/publish.php:970 article()

Error de etiqueta <txp:smd_gallery 
   id="?article_image" form="gallery"
   collate="quote:{imagedef}:{alt}"/> ->  Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10  on line 66

textpattern/lib/txplib_misc.php(469) : eval()'d code:66 preg_match_all()
textpattern/lib/txplib_misc.php(574) : eval()'d code:199 smd_dolist()
textpattern/publish.php:970 smd_gallery()
processtags()
textpattern/publish.php:929 preg_replace_callback()
textpattern/lib/txplib_misc.php:1460 parse()
textpattern/publish.php:800 parse_form()
textpattern/publish.php:826 doarticle()
textpattern/publish.php:519 parsearticles()
textpattern/publish.php:970 article()

Last edited by mlarino (2009-04-02 11:40:00)

Offline

#460 2009-04-02 12:58:35

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

Re: smd_gallery: super-flexible gallery generator

mlarino wrote:

Warning: preg_match_all() [function.preg-match-all]: Compilation failed: PCRE does not support \L, \l, \N, \P, \p, \U, \u, or \X at offset 10 on line 66

There’s nothing I can do about that. If you’d had the site in debugging mode from the start you’d have seen this error right away!

It’s your server configuration that is the reason it is not working. See RedFox’s identical post with smd_slimbox and my temporary solution. Ask your host to upgrade the PCRE component in their PHP installation.


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

#461 2009-04-02 16:08:43

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

Re: smd_gallery: super-flexible gallery generator

I wrote:

There’s nothing I can do about that.

I lied. smd_lib v0.36 | compressed will now gracefully fall back to ASCII mode if your server does not support Unicode. Anyone using v0.35, please upgrade.


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

#462 2009-04-02 16:12:21

mlarino
Member
Registered: 2007-06-29
Posts: 367

Re: smd_gallery: super-flexible gallery generator

Thanks Bloke! that solved all my problems!

Offline

#463 2009-04-05 15:02:55

feiliao
New Member
Registered: 2004-08-06
Posts: 9
Website

Re: smd_gallery: super-flexible gallery generator

Hey Bloke, thanks for your awesome plugin. I’m using it and it’s been great! The only problem I had though, happened when I tried to add paging to the gallery. Like the instruction, I use “{navfirst} {navprev}{navearlier} {navthis} {navlater}{navnext} {navlast}” as the gallery_nav form. It showed as bulletin points:
  • First
  • «
  • 1
  • 2
  • »
  • Last
    instead of “First « 1 2 » Last”. I think it’s due to the default <li>. What should I do to change it? Thank you in advance for your time!

Offline

#464 2009-04-05 15:18:30

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

Re: smd_gallery: super-flexible gallery generator

feiliao wrote:

the gallery_nav form. It showed as bulletin points:

Yes it’s designed that way by default. The paging attribute uses <li> (which you can of course change using navwraptag and navbreak) but the easiest method for dealing with the bullets is to apply CSS to tame the list. Specifically something like this (untested):

.smd_gallery_nav {
   list-style: none;
   display: inline;
}

Does that get you going in the right direction?

Last edited by Bloke (2009-04-05 15:18:55)


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

#465 2009-04-06 01:18:32

feiliao
New Member
Registered: 2004-08-06
Posts: 9
Website

Re: smd_gallery: super-flexible gallery generator

Thanks Bloke! I didn’t aware that I could change navwraptag and navbreak (my bad, I did read the instruction but somehow it slipped out of my mind). So I changed them and applied some css to .smd_gallery_nav, and everything looks beautiful now. Thank you so much for answering my question and, most importantly, writing this plugin.

Offline

#466 2009-04-19 02:17:12

the1design.cn
New Member
From: CHINA
Registered: 2008-11-28
Posts: 5
Website

Re: smd_gallery: super-flexible gallery generator

how can i do display the smd gallery link to img`s article??

i can not find the way, help me

Offline

#467 2009-04-20 17:21:08

decoderltd
Member
From: London
Registered: 2006-06-20
Posts: 248
Website

Re: smd_gallery: super-flexible gallery generator

Hi all,

I’m trying to create a gallery by category page using smd_gallery and slimbox2 (uses jQuery). I’ve added the two js links to my header and used the following –

<txp:smd_gallery
     category="gallery" form="gallery_by_category" sublevel="all" sort="date desc"
     onchange="category_title"
     onchangewraptag="h4" />

My form is:

{onchange:category_title}
<a href="{url}" rel="lightbox-{category}" alt="{alt}" title="{title}">
{object}
</a>

Alas, it’d not playing ball and I’m struggling with the javascript. Does anybody have any idea where I’m going wrong?

Offline

#468 2009-04-20 17:30:56

maniqui
Member
From: Buenos Aires, Argentina
Registered: 2004-10-10
Posts: 3,070
Website

Re: smd_gallery: super-flexible gallery generator

Can you share a link, please?


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

Board footer

Powered by FluxBB