Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2011-03-26 04:22:53

maruchan
Member
From: Ukiah, California
Registered: 2010-06-12
Posts: 595
Website

[request] Display forms below page templates

I checked to see if there were any plugins that did this, but didn’t see any.

My thought was that it would be handy to have this below page template textarea: A dropdown menu with form names in it. You click a form name, the form code shows up below that, and you can edit and save.

Right now I just keep forms open in a separate tab. Maybe I’ll change the <title> tag ordering so that “Forms” shows up first, rather than “Txp.” It just seems like it could be a faster workflow with some small feature like this.

Last edited by maruchan (2011-03-26 04:24:17)

Offline

#2 2011-03-26 05:09:58

hcgtv
Plugin Author
From: Key Largo, Florida
Registered: 2005-11-29
Posts: 2,722
Website

Re: [request] Display forms below page templates

Marc,

After working with Textpattern for awhile and creating my share of Templates, I’ve adapted to a certain flow.

My pages are set in stone, I spend all my time in forms. Here’s the page template from PHPXref.com:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>
<txp:output_form form="head" />
</head>

<body>
<div id="wrap">

<div id="header">
<txp:output_form form="header" />
</div>

<div id="content">
<txp:output_form form="content" />
</div>

<div id="sidebar">
<txp:output_form form="sidebar" />
</div>

<div id="footer">
<txp:output_form form="footer" />
</div>

</div>
</body>
</html>

As you can see, each div is broken out into a Form, the Page need not be touched. The template that I used for PHPXref is rather simple, it’s 1024px by Andreas Viklund.

Offline

#3 2011-03-26 05:29:09

maruchan
Member
From: Ukiah, California
Registered: 2010-06-12
Posts: 595
Website

Re: [request] Display forms below page templates

Good stuff, Bert! Do you use prefixes or some other way of keeping your forms organized?

Offline

#4 2011-03-26 14:22:24

hcgtv
Plugin Author
From: Key Largo, Florida
Registered: 2005-11-29
Posts: 2,722
Website

Re: [request] Display forms below page templates

maruchan wrote:

Good stuff, Bert! Do you use prefixes or some other way of keeping your forms organized?

The easiest way to keep forms organized, if it’s one install, one template, is to use the form types. Form types don’t do much of anything, in other words a form under article form type works the same way as a form under misc form type. At first I though that form types had a special meaning to the parser, but they don’t. With that in mind, you can customize your form types to whatever you’d like.

Now if you’re looking at using one install to have more than one template, even if you customize the form types, you’ll still have collisions with form names, ie. you can’t have a footer form under different form types.

Offline

#5 2011-03-26 16:01:03

maruchan
Member
From: Ukiah, California
Registered: 2010-06-12
Posts: 595
Website

Re: [request] Display forms below page templates

Thanks, Bert. I may add that to my growing list of core mods. It sounds like it mainly addresses form organization on the Forms tab, though. I’m thinking about pseudo-namespace stuff so that I can read my own code in the future. :-)

Offline

Board footer

Powered by FluxBB