Account Options

  1. Sign in
The old Google Groups will be going away soon.
Switch to the new Google Groups.
Google Groups Home
« Groups Home
aText slot - Text wrapped in <p> - Why?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  12 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
luk4s  
View profile  
 More options Jul 5 2010, 4:07 pm
From: luk4s <lukas.schroe...@code-mitte.de>
Date: Mon, 5 Jul 2010 13:07:09 -0700 (PDT)
Local: Mon, Jul 5 2010 4:07 pm
Subject: aText slot - Text wrapped in <p> - Why?
G'night everyone

I put something like this in my template:

<h2><?php a_slot('headline', 'aText'); ?></h2>

Why does it end up as
<h2><p>the text i entered via editing</p></h2>

And the <p> tag is written to the database. An empty edit field? Ends
up as <p></p>.

How do I make aText be *real* plaintext?

As a workaround for now I tried this:
<h2><?php a_slot('headline', 'aText', array('allowed-tags' =>
'<pre>')) ?></h2>

to have <p> removed.

Didn't work.

Versions:
symfony -- via svn external from http://svn.symfony-project.com/branches/1.4
apostrophePlugin - branches/1.4 as well.

Thanks,
  -Lukas


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tom Boutell  
View profile  
 More options Jul 5 2010, 6:07 pm
From: Tom Boutell <t...@punkave.com>
Date: Mon, 5 Jul 2010 18:07:02 -0400
Local: Mon, Jul 5 2010 6:07 pm
Subject: Re: [apostrophe] aText slot - Text wrapped in <p> - Why?
The simple_format_text helper does that. I think it would make sense
for us to add options to strip it down and turn off things like
links-to-URLs and line breaks to paragraphs, especially when you're
not using the multiline option. A true plaintext slot ought to be
available. I suggest that you open a ticket on trac.apostrophenow.org.

--
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.com

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
luk4s  
View profile  
 More options Jul 6 2010, 12:05 am
From: luk4s <lukas.schroe...@code-mitte.de>
Date: Mon, 5 Jul 2010 21:05:20 -0700 (PDT)
Local: Tues, Jul 6 2010 12:05 am
Subject: Re: aText slot - Text wrapped in <p> - Why?
Yes, that would be nice. Ticket here:
http://trac.apostrophenow.org/ticket/471

...I really only need plain text - inside of an <hX> - so that it will
be Cufon'ed as a headline easily
as prepared in my layouts.

How-To-Question:
How to get the raw value of a slot rendered without
the _area -> _slot -> yadda yadda wrappings?

In components.class.php I could "see" my almost-plain text as
  $value["text"]

For the record: I also tried to simply create my own "justPlaintext"
type, but, oh
well: this is the <h2>....</h2> markup I ended up with.

        <h2><div id="a-area-7-headline" class="a-area a-area-
headline">
    <div id="a-slots-7-headline" class="a-slots">
        <div class="a-slot  justPlaintext " id="a-slot-7-headline-2">
        <div class="a-slot-content" id="a-slot-content-7-headline-2">
----

  This is a Plain TExt Slot!----
        </div>
        </div>
  </div>  </div> <!-- END SLOT -->
<script type="text/javascript" charset="utf-8">
        $(document).ready(function() {
        });
</script></h2>

Thanks,
  -Lukas

On 6 Jul., 00:07, Tom Boutell <t...@punkave.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Pete Sisson  
View profile  
 More options Jul 7 2010, 9:45 am
From: Pete Sisson <petes...@gmail.com>
Date: Wed, 7 Jul 2010 06:45:20 -0700 (PDT)
Local: Wed, Jul 7 2010 9:45 am
Subject: Re: aText slot - Text wrapped in <p> - Why?
Hey Tom

Could we set some kind of public target, so that if we get, say, 100
of these 'what on earth is all this markup and why on earth do we need
it' threads, then it will get changed? :))

It would just be helpful to know how much more pressure we need to
apply :)

Pete

On Jul 6, 5:05 am, luk4s <lukas.schroe...@code-mitte.de> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Alex Gilbert  
View profile   Translate to Translated (View Original)
 More options Jul 7 2010, 9:52 am
From: Alex Gilbert <a...@punkave.com>
Date: Wed, 7 Jul 2010 09:52:00 -0400
Subject: Re: [apostrophe] Re: aText slot - Text wrapped in <p> - Why?

Ha! I like it.

--
Alex Gilbert
P'unk Avenue
215-755-1330
a...@punkave.com

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Daniel Lohse  
View profile  
 More options Jul 7 2010, 10:51 am
From: Daniel Lohse <annismcken...@googlemail.com>
Date: Wed, 7 Jul 2010 16:51:40 +0200
Local: Wed, Jul 7 2010 10:51 am
Subject: Re: [apostrophe] Re: aText slot - Text wrapped in <p> - Why?

Count me in for the public demonstration on the streets in front of P'unk Ave's offices... :P

Cheers, Daniel

On 07.07.2010, at 15:52, Alex Gilbert wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Geoff DiMasi  
View profile  
 More options Jul 7 2010, 10:55 am
From: Geoff DiMasi <ge...@punkave.com>
Date: Wed, 7 Jul 2010 10:55:32 -0400
Local: Wed, Jul 7 2010 10:55 am
Subject: Re: [apostrophe] Re: aText slot - Text wrapped in <p> - Why?

That would be very cool.

If you need a room to stay at when you come down for the demonstration, let me know. We can put you up.

--
Geoff DiMasi
P'unk Avenue
215 755 1330
http://punkave.com

On Jul 7, 2010, at Jul 7,10:51 AM, Daniel Lohse wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Pete Sisson  
View profile   Translate to Translated (View Original)
 More options Jul 7 2010, 11:24 am
From: Pete Sisson <petes...@gmail.com>
Date: Wed, 7 Jul 2010 08:24:47 -0700 (PDT)
Local: Wed, Jul 7 2010 11:24 am
Subject: Re: aText slot - Text wrapped in <p> - Why?
Hehe

A stateside protest would be a bit expensive for any of us Euro's but
I'd settle for a totaliser ( http://www.bbc.co.uk/cbbc/bluepeter/img/c/getinvolved/appeal/totalise...
) on the front page of the googlegroup to keep track of how far away
we are from the target.

On Jul 7, 3:55 pm, Geoff DiMasi <ge...@punkave.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
luk4s  
View profile  
 More options Jul 9 2010, 7:35 am
From: luk4s <lukas.schroe...@code-mitte.de>
Date: Fri, 9 Jul 2010 04:35:48 -0700 (PDT)
Local: Fri, Jul 9 2010 7:35 am
Subject: Re: aText slot - Text wrapped in <p> - Why?
I'll start a CMS contest in the next days:

Steps necessary to get your really cool CMS to output really plain
text.

How much code is necessary to make your CMS output just plain text

to start:
years ago i wrote my own cms. you need two template:
page template and block template.

the pagetemplate would say:
{lukks_container name="content"}

the blocktemplate would say:
{lukks_text name="text1"}

e voila. the rendered page would contain no markup at all. no byte
even  as long as text1
was an empty slot ;-)

On 7 Jul., 17:24, Pete Sisson <petes...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Tom Boutell  
View profile  
 More options Jul 9 2010, 8:16 am
From: Tom Boutell <t...@punkave.com>
Date: Fri, 9 Jul 2010 08:16:27 -0400
Local: Fri, Jul 9 2010 8:16 am
Subject: Re: [apostrophe] Re: aText slot - Text wrapped in <p> - Why?
One quick way to do this with Apostrophe is to override the
_normalView.php template of the aText module at the project level and
call strip_tags there (leave the entities alone, just strip the tags).

Another approach is to use apostrophe:generate-slot-type and make a
new slot in which you can do exactly as you please.

--
Tom Boutell
P'unk Avenue
215 755 1330
punkave.com
window.punkave.com

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Abraham Block  
View profile  
 More options Jul 9 2010, 8:19 am
From: Abraham Block <atbl...@gmail.com>
Date: Fri, 9 Jul 2010 08:19:13 -0400
Local: Fri, Jul 9 2010 8:19 am
Subject: Re: [apostrophe] Re: aText slot - Text wrapped in <p> - Why?

Or you wind up just hardcoding the stinkin' text in the template because 90%
of the time, the client not only doesn't change it, but asks you to change
it.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Alex Gilbert  
View profile  
 More options Jul 9 2010, 9:49 am
From: Alex Gilbert <a...@punkave.com>
Date: Fri, 9 Jul 2010 09:49:38 -0400
Local: Fri, Jul 9 2010 9:49 am
Subject: Re: [apostrophe] Re: aText slot - Text wrapped in <p> - Why?

Good suggestions, Tom. Overriding aText/_normalView.php with strip_tags is
dead easy and could probably the stock response for this one until there is
a more elegant solution out of the box.

--
Alex Gilbert
P'unk Avenue
215-755-1330
a...@punkave.com

 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »