Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#301 2009-04-22 16:49:02

azw
Member
Registered: 2007-01-29
Posts: 279

Re: glz_custom_fields

That’s a good question about blank select options. I’ve seen in other instances that they don’t validate with W3C’s validator. What’s a good way around that problem?

Offline

#302 2009-04-22 17:04:16

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

Re: glz_custom_fields

What I am doing right now is changing this part of the code in the plugin

return "<select id=\"".glz_idify($id)."\" name=\"$name\" class=\"list\"$multi>".
      ($blank_first ? "<option value=\"\">CUSTOME_SET_NAME</option>" : '').
      ( $out ? join('', $out) : '').
      "</select>";

CUSTOME_SET_NAME needs to be replaced wich a PHP code that places there the name of the Custome field there.
But I dont know anything about PHP, it took me 1 hour to figure this out, but dont know where to go from here.

Offline

#303 2009-04-23 03:37:12

azw
Member
Registered: 2007-01-29
Posts: 279

Re: glz_custom_fields

What happens if you put: custom_set_name in the place of: CUSTOME_SET_NAME ?

I haven’t studied the plugin much and I don’t have the new plugin yet, so it may be a different variable.

Offline

#304 2009-04-23 07:13:06

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

Re: glz_custom_fields

doesnt work, it just prints custom_set_name as the first option.

Offline

#305 2009-04-23 21:16:02

thermofunk
New Member
From: Argentina
Registered: 2009-03-12
Posts: 9
Website

Re: glz_custom_fields

Hi Gerhard,

How can I link to a search result?
It is not necessary to show the url in the browser every time I make a search, I just need to know the correct sintaxis to create the link…

By the way, I’m having problems with rss_admin_show_adv_opts and your version of TXP. Since I installed this version I also see the following message in the bottom of the Write Tab:

Warning: array_map() [function.array-map]: Argument #2 should be an array in /var/www/vhosts/neuquentur.gov.ar/httpdocs/textpattern/lib/txplib_misc.php(570) : eval()’d code on line 576

Many thanks, Martín.

Offline

#306 2009-04-24 02:49:47

azw
Member
Registered: 2007-01-29
Posts: 279

Re: glz_custom_fields

mlarino wrote:

doesnt work, it just prints custom_set_name as the first option.

Did you use the “$” with $custom_set_name?

It’s possible that the variable doesn’t mean anything in that section of the code (scope issue), but it looks like Gerhard has changed a lot in his plugin, so my looking at the old code is probably not going to help.

Offline

#307 2009-04-24 09:03:12

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

Re: glz_custom_fields

Great news here!

Offline

#308 2009-04-24 11:58:11

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

Re: glz_custom_fields

That is great news indeed! I’m going through a spike currently, will come back to the plugin as time permits. Will also reply to all your questions guys! Thanks!

Offline

#309 2009-04-25 13:58:11

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

Re: glz_custom_fields

With this great news + new improvements in admin interface … and of course Gerhard plugin, is it possible to get
  • new custom fields > 256 chars (text/textarea) ?
  • custom fields below the body or excerpt fields (not in the left sidebar) ?

Offline

#310 2009-04-25 21:38:56

midmood
Member
From: Rome, Italy
Registered: 2007-07-20
Posts: 68
Website

Re: glz_custom_fields

Hi everyone,
in the admin > Extensions tab I have about five or six couple of line of error like the following:

Notice: Undefined index: custom_set in /web/htdocs/www.leparole.net/home/violetab/textpattern/lib/txplib_misc.php(580) : eval()’d code on line 810

Notice: Undefined index: custom_set in /web/htdocs/www.leparole.net/home/violetab/textpattern/lib/txplib_misc.php(580) : eval()’d code on line 812

Whatever custom field I set is not showing in the write tab

can you help me?

Offline

#311 2009-04-25 23:08:49

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

Re: glz_custom_fields

Does someone have any idea how dinamically filtering drop down lists can be achived using custom fields?

Like, when I have a search with 3 different dropdown lists, I select something from the first list, and would like the second to only show whats abailable for the first option i selected. etc…

thanks!

Last edited by mlarino (2009-04-25 23:10:37)

Offline

#312 2009-04-26 12:52:40

grundgesetz
Plugin Author
From: Germany
Registered: 2009-04-17
Posts: 24

Re: glz_custom_fields

jpdupont wrote:

With this great news + new improvements in admin interface … and of course Gerhard plugin, is it possible to get

  • new custom fields > 256 chars (text/textarea) ?
  • custom fields below the body or excerpt fields (not in the left sidebar) ?

That´s what I´ve been missing with Textpattern: a completely adjustable Write-Tab, similar to ExpressionEngine where “content” and “excerpt” in fact ARE custom fields and could be removed at will. Therefore the term “content” is completely definable by the developer. That is what makes EE ingenious. I would really love that in txp.

Offline

#313 2009-04-26 12:56:21

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

Re: glz_custom_fields

grundgesetz wrote:

Therefore the term “content” is completely definable by the developer.

See xPattern :-)


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

#314 2009-04-26 17:22:35

mrdale
Member
From: Walla Walla
Registered: 2004-11-19
Posts: 2,215
Website

Re: glz_custom_fields

grundgesetz wrote:

Therefore the term “content” is completely definable by the developer.

What a fantastic Idea ;) Maybe it’s time has come.

Offline

#315 2009-04-26 17:32:40

azw
Member
Registered: 2007-01-29
Posts: 279

Re: glz_custom_fields

We’re sliding OT, but… I’ll second or third the separation of definition of content from the basic CMS code. It would add a lot of flexibility, but it would take a lot of work for the TXP crew to implement that.

I’m working on a plugin that allows the site owner to enter a simple list of data (6 data fields, three of them select menus) It was based on the code for the list of links in txp_link.php, but has more features. I didn’t want to add this list of items to the articles table because I’d never be able to find my articles among the 1000+ list entries. It’d be great if TXP were to allow us to define what content is, and to have different definitions for different sections, with content storage in different tables.

Offline

Board footer

Powered by FluxBB