Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#736 2010-11-15 22:22:59

vurt
Member
Registered: 2010-10-22
Posts: 50

Re: glz_custom_fields

Glad I could help!

Offline

#737 2010-11-29 16:51:21

brunodario
Member
From: Belo Horizonte, Brasil
Registered: 2007-09-19
Posts: 75

Re: glz_custom_fields

Is there a way to control the output? Say, if i want to output each marked value of a radio custom field inside a <li> tag?

Example: I have custom fields with color names (white, brown, yellow) and the output it´s white | brown | yellow. I´d like it to be <li>white</li> <li>brown</li> <li>yellow</li>

Offline

#738 2010-11-29 17:02:56

wornout
Member
From: Italy
Registered: 2009-01-20
Posts: 256
Website

Re: glz_custom_fields

You can use smd_each or rah_repeat for your purposes!

Offline

#739 2010-11-29 17:47:43

brunodario
Member
From: Belo Horizonte, Brasil
Registered: 2007-09-19
Posts: 75

Re: glz_custom_fields

wornout,

Great regexp plugins!

<txp:rah_repeat wraptag="ul" break="li" value='<txp:custom_field name="colors"/>' delimiter="|"> Cor <txp:rah_repeat_value />. </txp:rah_repeat>

Did the trick. Thx!

Offline

#740 2010-12-02 13:56:30

babyben
Member
Registered: 2007-06-03
Posts: 39

Re: glz_custom_fields

Edit: D’oh. Asked a question, and should have read the Textbook first. Answer was staring me in the face!

Last edited by babyben (2010-12-02 14:11:26)

Offline

#741 2010-12-31 15:53:53

phuture303
Member
Registered: 2008-09-14
Posts: 127

Re: glz_custom_fields

Hello there,

just a simple question (I’m testing possibilities on a fresh install :-)

I’m using glz_custom_fields and the delivered script “my_images.php”. My customfield #2 (named “custom2”) shows the name of all images in a dropdown as it should, everything’s all right till here.

<txp:custom_field name="custom2" />

placed as a tag in an article publishes the id of the selected image (“2” in my case). Okay.

<txp:image id="2" />

shows the right image as it should (“txp_slug105x45.gif”). Normal. And fine :-)

But in combination:

<txp:image id='<txp:custom_field name="custom2" />' />

doesn’t work. Am I doing something stupidly wrong? Thanks for help :-)

Have a nice 2011!
David

UPDATE

Problem solved for myself:

notextile. <txp:image id='<txp:custom_field name="custom2" />' />

It seems that textile doesn’t like the phrase. But why’s that?

Last edited by phuture303 (2010-12-31 15:55:24)

Offline

#742 2010-12-31 16:16:04

alanfluff
Member
From: Ottawa, Canada
Registered: 2008-09-15
Posts: 222
Website

Re: glz_custom_fields

Hi David,

It seems that textile doesn’t like the phrase. But why’s that?

I’m not sure why in this case this was necessary, but I think as a general rule-of-thumb it’s a good idea not to have (or allow) Textile to parse TXP code. When you do, you are relying on Textile being clever enough to work out when to ignore and when to parse, so regardless of how clever Textile is at that, it’s safer to simply not have it parse TXP code.

As noted, I may be wrong or partially wrong here, apologies if so and anyone who know’s different, please shout out so I can learn too :) Thanks!

Cheers, -Alan


At LAST I’ve cheerfully donated to the core devs at #TXP. I only wish I were able to give more. Thanks to the devs and ALL fellow TXPers. -A

Offline

#743 2011-01-13 10:56:18

jpdupont
Member
Registered: 2004-10-01
Posts: 752

Re: glz_custom_fields

Is it possible to store pure html tags in a textarea custom field ??? How ? I want to paste a flash video script code in a textarea custom field…

Offline

#744 2011-01-13 10:59:45

alanfluff
Member
From: Ottawa, Canada
Registered: 2008-09-15
Posts: 222
Website

Re: glz_custom_fields

Hi jpdupont,

I’ve not tried it, I think it would be possible, you may need to use the escape attribute.

Luck, cheers, -Alan


At LAST I’ve cheerfully donated to the core devs at #TXP. I only wish I were able to give more. Thanks to the devs and ALL fellow TXPers. -A

Offline

#745 2011-01-13 11:54:22

jpdupont
Member
Registered: 2004-10-01
Posts: 752

Re: glz_custom_fields

Thanks Allan, but don’t work …

The last part of these article come from a textarea custom field where I paste the code you see…

Last edited by jpdupont (2011-01-13 11:55:16)

Offline

#746 2011-01-13 12:01:27

redbot
Plugin Author
Registered: 2006-02-14
Posts: 1,410

Re: glz_custom_fields

Hi jpdupont,
just to be sure are you using escape=""?

Offline

#747 2011-01-13 12:15:53

jpdupont
Member
Registered: 2004-10-01
Posts: 752

Re: glz_custom_fields

ok ok ! escape ="" do the job … I forgot to read (again) the doc … !

Thanks redbot and alan !

Jean-Pol

Offline

#748 2011-01-25 17:00:02

jpdupont
Member
Registered: 2004-10-01
Posts: 752

Re: glz_custom_fields

On 2 similar sites, with similar admin interface, with 2 identical glz_custom_fields, I have this display problem :

  • On first (old) site : after the label before the input field I have a <br/>
  • On second (just created) site : no <br/>

Where is the problem ?

I use the same last glz_custom_fields release v1.2.4, on the 2 sites.

The 2 custom fields are on the 2 sites 2 text input fields.

Last edited by jpdupont (2011-01-25 17:07:27)

Offline

#749 2011-01-25 22:29:34

gerhard
Plugin Author
From: London, UK
Registered: 2005-06-29
Posts: 409
Website

Re: glz_custom_fields

Wow, I couldn’t believe how many messages have been posted since I last visited! I’m very glad that you are helping one another, TXP’s great community stands up to its reputation – yet again!

@jpdupont the official v1.2.4 does have <br /> tags after labels

Everyone else, I am getting close to taking glz_custom_fields for one serious ride. Following all your replies to my survey from a few months back, I’ve come to a decision regarding the plugin’s future:

  • Will rely on JS mostly, it’s the only way to build something this complex in an elegant manner. Without real objects, a proper MVC framework and a much improved db structure, the next version of this plugin would not be possible. Thick client, slim back-end, exactly like the big boys do it ; ).
  • Will continue to be donation only, there will be a separate web application to track your various installs, will also inform you when there’s a new update right in TXP. Everyone that has donated so far will have access to the new version for free.
  • No more delimiter business or overloading of the textpattern table, each custom field will store its values in a separate table.

A few more shortcomings will be addressed, but the above are the main points.

I will also send an e-mail to all glz_custom_fields patrons. Lengthier replies should be done by e-mail please, it’s difficult to keep track of things on this thread.

Looking forward to the best year for TXP yet!

Last edited by gerhard (2011-01-25 22:29:52)

Offline

#750 2011-01-25 22:34:51

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 12,424
Website GitHub

Re: glz_custom_fields

gerhard wrote:

Without real objects, a proper MVC framework and a much improved db structure, the next version of this plugin would not be possible.

cough cough


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

Hire Txp Builders – finely-crafted code, design and Txp

Offline

Board footer

Powered by FluxBB