Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#709 2010-08-24 13:52:16

THE BLUE DRAGON
Member
From: Israel
Registered: 2007-11-16
Posts: 637
Website

Re: glz_custom_fields

gerhard wrote:

Sorry mate, that’s a MySQL limitation, nothing I can do about it without having to rewrite the plugin…

Is there anything that I can do?
is this error only because I got too many “text” type inputs?
if for example I will create textareas instead of text-inputs and change them to look as text-input will it work?
or it’s doesn’t matter what type of field it is?

Does creating more custom fields with the same set-position will work?
(for example: creating 10 custom fields on the same position “custom_1_set”)

Last edited by THE BLUE DRAGON (2010-08-24 13:52:57)

Offline

#710 2010-08-27 19:25:32

ploinkr
Member
From: Montreal
Registered: 2007-12-06
Posts: 83

Re: glz_custom_fields

Hi Gerhard & all; I’m running into a problem which I’m not sure how to fix.
I created a textarea type custom field to add embedding code for Issuu documents, but it all shows up as text on the site, and not interpreting the code. I’m probably missing something but I’m afraid I’m gonna need some help(!) Thanks in advance,
Ben P.

Offline

#711 2010-08-27 19:29:29

photonomad
Member
Registered: 2005-09-10
Posts: 290
Website

Re: glz_custom_fields

ploinkr — you should be able to get it to work by putting — oops, I meant to say escape=”“ (instead of html=”“) in your txp:custom_field tag

like this:
<txp:custom_field name=“nameofyourtextareacustomfield” escape=”“ />

Last edited by photonomad (2010-08-27 19:33:50)

Offline

#712 2010-08-29 14:03:47

ploinkr
Member
From: Montreal
Registered: 2007-12-06
Posts: 83

Re: glz_custom_fields

photonomad, thanks a lot – that worked! I knew it had to do with “escaping” but really had no idea how/where to put that. Cheers! :-)

Offline

#713 2010-09-04 07:35:40

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

Re: glz_custom_fields

THE BLUE DRAGON wrote:

is this error only because I got too many “text” type inputs? or it’s doesn’t matter what type of field it is?

Nope, it doesn’t matter what type of fields they are. As soon as you create a new custom field, 2 things happen:

  1. A new entry gets added into txp_prefs with the custom set name and type
  2. A new column gets added to the textpattern table for that custom set, e.g. custom_1

Your problem is that you’ve hit the MySQL limitation for how many columns there can be in a table, 85.

Does creating more custom fields with the same set-position will work? (for example: creating 10 custom fields on the same position “custom_1_set”)

I’m not sure that I understand what you mean. A custom field is a custom set. For example, custom_1_set in the txp_prefs table refers to custom_1 in the textpattern table. It’s just a naming inconsistency IMO, but they are effectively the same thing.

Your only option would be to use less custom fields. What custom fields have you defined? I might offer suggestions on merging some of them.

photonomad wrote:

Hi Gerhard & all; I’m running into a problem which I’m not sure how to fix.

Stacey, thanks for helping ploinkr out, that was a quick and accurate reply ; ).

Offline

#714 2010-09-16 08:41:09

feragnoli
Member
From: the hague
Registered: 2005-02-10
Posts: 150

Re: glz_custom_fields

hello, I keep on having this problem when using custom scripts.
the server seems to issue this notification just before the custom fields in the write tab:

220 FTP on myserver.com ready 421 Login Timeout (60 seconds): closing control connection

help!


what was that again…?

Offline

#715 2010-09-16 09:26:06

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

Re: glz_custom_fields

feragnoli wrote:

220 FTP on myserver.com ready 421 Login Timeout (60 seconds): closing control connection

Where does FTP come into play in regards to the custom fields? PM or e-mail if you want me to check some code out ; ).

Offline

#716 2010-09-16 09:35:51

feragnoli
Member
From: the hague
Registered: 2005-02-10
Posts: 150

Re: glz_custom_fields

hello Gerhard,
I seem to have fixed the problem… not sure how it first came about though…
thank you for your reply!


what was that again…?

Offline

#717 2010-09-17 03:19:47

radneck
Plugin Author
Registered: 2005-07-03
Posts: 109

Re: glz_custom_fields

Just a quick FYI guys:

If you want to user glz_custom_fields with, for example, <txp:article_custom />’s attribute customfieldname you cannot use spaces in the custom field name. This is quite annoying when developing a site for a client, as you want the custom field to show up in the Write tab as My Custom Field and not My_Custom_Field. I think this feature is planned for a future release, but until then here’s a quick and dirty hack:

Edit the glz_custom_fields plugin and look for the following line:

"<label for=\"$custom_id\">{$custom_set['name']}</label><br />$custom_set_value", " class=\"$custom_class\""

and replace it with:

"<label for=\"$custom_id\">".str_replace('_', ' ', $custom_set['name'])."</label><br />$custom_set_value", " class=\"$custom_class\""

This will basically replace underscores in the field name with spaces when in the Write tab, but will still allow you to reference the proper name (with underscores intact) when playing around in templates and forms.

Hope this helps someone.

Offline

#718 2010-09-17 03:33:59

johnstephens
Plugin Author
From: Woodbridge, VA
Registered: 2008-06-01
Posts: 1,000
Website

Re: glz_custom_fields

There is also a very useful plugin that can be used alongside glz_cf for the same effect, and no hacks. I love it!

Offline

#719 2010-09-17 03:36:39

radneck
Plugin Author
Registered: 2005-07-03
Posts: 109

Re: glz_custom_fields

Yes I saw that, thought it was an great plugin – just like wet_babble but for custom fields. I just couldn’t get it to work though, I assumed it hadn’t been updated to work with the latest glz_cf. Also, I think it relies on JS (?).

Last edited by radneck (2010-09-17 03:37:28)

Offline

#720 2010-09-17 04:23:13

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,333
Website Mastodon

Re: glz_custom_fields

cain-mi wrote:

Also, I think it relies on JS (?).

NB: The whole admin side relies on JS.

Offline

Board footer

Powered by FluxBB