Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-11-03 20:44:27

progre55
Member
Registered: 2006-05-02
Posts: 668

Custom Fields - More than 10

I need to expand the number of custom fields from 10 to 20. I have searched the forum and located Gerhard’s Hack that would seem to do the trick.

10-more-custom-fields-please

My issue is, where changing the .php files is very straight forward, and adding a row(s) to the textpattern table seems ok, I am uncertain regarding the pref table. Since I see no entries for the other custom fields in this table.

If anyone can give me insight I would greatly appreciate it. Also, if I am not consernced about language, do I need to follow the instructons on the language table.

any and all assistance is appreciated.

progre55

Last edited by progre55 (2006-11-03 20:45:47)

Offline

#2 2006-11-04 15:59:54

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: Custom Fields - More than 10

They’re named “custom_1_set”, etc.

Offline

#3 2006-11-04 19:07:17

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Custom Fields - More than 10

Mary:

Why don’t I see the entries in the pref table? for 4.04. Am I looking in the wrong place ….

My fields looks like this:

prefs_id int(11) No 0 name varchar(255) No val varchar(255) No type smallint(5) UNSIGNED No 2 event varchar(12) No publish html varchar(64) No text_input position smallint(5) UNSIGNED No 0 progre55

Offline

#4 2006-11-04 19:14:59

marios
Archived Plugin Author
Registered: 2005-03-12
Posts: 1,253

Re: Custom Fields - More than 10

Another possible option is to pack multiple values into each of the custom fields with

this

plugin.

regards

Last edited by marios (2006-11-04 19:26:10)


⌃ ⇧ < ⌃ ⇧ >

Offline

#5 2006-11-05 01:19:56

Mary
Sock Enthusiast
Registered: 2004-06-27
Posts: 6,236

Re: Custom Fields - More than 10

The custom fields are rows within the prefs table.

Offline

#6 2006-11-06 09:04:02

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: Custom Fields - More than 10

i’ll check out marios plugin link, nevertheless i’ve got to have unlimited custom fields with gerhard’s method in txp 4.0.4 – more info here


A hole turned upside down is a dome, when there’s also gravity.

Offline

#7 2006-11-06 13:38:29

progre55
Member
Registered: 2006-05-02
Posts: 668

Re: Custom Fields - More than 10

Mary/jayrope:

Thanks for the input. Mary. telling me they were rows did the trick. I am still working my way around with mySQL, . I got it to work using Gerhard’s tutorial.

Mario’s plug in (although cool) in my opinion is tough for a client to work with if they are not technicaly savy.

One additional question regarding the custom fields, is there a way to wrap the context of them. The issue I have is that I am pulling the data that is in them from an article form. Although I have the column widths set, it appears to disregard that and just runs the text out. This does not occur when I use the body tag, so I am assuming t has something to do with custom tags.

Most of the time I have “short data”, but in the case where it is not (ie a long email address or url) I am runnin into issues since the place I am putting this on the layout is not very wide.

Any and all assistance is appreciated.

Thanks.

Offline

#8 2006-11-06 14:19:30

jayrope
Plugin Author
From: Berlin
Registered: 2006-07-06
Posts: 687
Website Mastodon

Re: Custom Fields - More than 10

proge55,

use tables, divs, ul/li to wrap custom field data.
create a form, which displays the custom field data as wanted and use that as an alternative with the article tag in a page.
<txp:article form=“coolform” />

see example here
(most of the left side data there custom field information from a form)

Last edited by jayrope (2006-11-06 14:32:38)


A hole turned upside down is a dome, when there’s also gravity.

Offline

Board footer

Powered by FluxBB