Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#25 2014-06-15 20:21:10

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: txp 4.4.1, too much code on page, save blanks template

The 300 is an estimate, it may be fewer, or more.

If I need to do it, I’ll handle it. I’m retired now and have more time to work on my sites.

Offline

#26 2015-02-05 21:24:41

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: txp 4.4.1, too much code on page, save blanks template

uli wrote #276293:

The attempt is in the right direction, just use forms (Admin > Presentation > Forms), not files, and integrate their contents with output_form tags like <txp:output_form form="your_js" /> into your page template.

I recently tried to put two of these on the same article, only one displays. I am using these forms to connect articles about one town, or one star ship, together. So it isn’t in the page template.

Is there a way to have two or more of these on one article ?

Thanks !

Offline

#27 2015-02-05 22:35:03

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,315

Re: txp 4.4.1, too much code on page, save blanks template

JimJoe wrote #288053:

Is there a way to have two or more of these on one article ?

Yes, no problem. Some things that might be wrong:

  • Same form name used twice in your article (duplicate output, too long to distinguish)
  • Same scripts in form 2 as in form 1 (again: duplicate output, too long to distinguish)
  • One form is empty
  • Scripts in form 2 inhibit execution of those in form 1 (or was it vice versa?)

There may be even more reasons …


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#28 2015-02-05 22:44:25

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: txp 4.4.1, too much code on page, save blanks template

No scripts. The forms had different names. Both contain only links to other articles.

One had about 15 links in it, the other has about 5 links in it.

Offline

#29 2015-02-05 23:34:59

jakob
Admin
From: Germany
Registered: 2005-01-20
Posts: 4,925
Website GitHub

Re: txp 4.4.1, too much code on page, save blanks template

You say you’re putting them in articles.

Check the source code of the page as it is output in the browser to see if it is actually being parsed. Sometimes textile will convert it into a string and not parse it as a tag, especially if you’ve not left enough space around the tag. Usually if you need to include tags in the body field, you need to do it like this:

(a blank line)
 <txp:output_form form="your-form-name" />
(another blank line)

And you need to start the line with a space in front of the opening <txp:…. That should prevent textile from converting it into a well-formed paragraph.

If you still have no luck, try starting the line with:

notextile.  <txp:output_form form="your-form-name" />

And, of course, check your syntax in your article, your forms and the page template. 9 times out of 10 I find I’ve forgotten to close some tag, or I have closed a container tag where I shouldn’t have…


TXP Builders – finely-crafted code, design and txp

Offline

#30 2015-02-05 23:42:18

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,315

Re: txp 4.4.1, too much code on page, save blanks template

uli wrote #288054:

There may be even more reasons …

  • The links’ code is correct? (Faulty code might not be displayed)
  • The forms are both saved and not empty?
  • You’ve copied and pasted their names to the tags in your article?
  • The type of your forms is “Miscellaneous” (safest type for your use)

4 times yes? Please post your txp:output_form tags. If in doubt about the links’ code please post them here.


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#31 2015-02-05 23:45:46

uli
Moderator
From: Cologne
Registered: 2006-08-15
Posts: 4,315

Re: txp 4.4.1, too much code on page, save blanks template

jakob wrote #288056:

And you need to start the line with a space in front of the opening <txp:….

I’ve not had space/notextile troubles with an output_form tag in an article, yet. Seems to save OK without.

Last edited by uli (2015-02-06 16:50:35)


In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links

Offline

#32 2015-02-06 00:24:56

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: txp 4.4.1, too much code on page, save blanks template

Ah, I made them Article. Miscellaneous makes both visible.

Offline

#33 2015-02-06 00:29:18

JimJoe
Member
From: United States
Registered: 2010-01-30
Posts: 573
Website

Re: txp 4.4.1, too much code on page, save blanks template

jakob wrote #288056:

You say you’re putting them in articles.

Check the source code of the page as it is output in the browser to see if it is actually being parsed. Sometimes textile will convert it into a string and not parse it as a tag, especially if you’ve not left enough space around the tag. Usually if you need to include tags in the body field, you need to do it like this:

(a blank line)...

And you need to start the line with a space in front of the opening <txp:…. That should prevent textile from converting it into a well-formed paragraph.

If you still have no luck, try starting the line with:

notextile. <txp:output_form form="your-form-name" />...

And, of course, check your syntax in your article, your forms and the page template. 9 times out of 10 I find I’ve forgotten to close some tag, or I have closed a container tag where I shouldn’t have…

No blank line above the first one on each article. A blank line separates each form in an article.

I made them forms in the articles so the site navigation menu at the top of all articles wouldn’t become cumbersome. This way I connect places in one town together, or a nearby adventure together.

Offline

Board footer

Powered by FluxBB