Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#25 2006-06-23 02:47:05

dinosauer
New Member
Registered: 2006-03-03
Posts: 2

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

does anyone know how to add the article’s title to the linktext? something like, ‘…continue reading My First Article’ ?

Offline

#26 2006-06-23 03:37:26

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

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

dinosauer wrote:

does anyone know how to add the article’s title to the linktext? something like, ‘…continue reading My First Article’ ?

I think you just want to omit the article title and then place a conventional <code> continue reading my nbsp&;<txp:permlink><txp:title /><txp:permlink></code> below your beginning tag inside your article form.
I think it is much more convenient to use a custom field for this so you can always enter some alternative candie teaser slogan in there.

This is how I use it for the main frontpage:
<code>
<txp:if_article_list>
<h2>♨&nbsp;<txp:permlink><txp:title /></txp:permlink></h2>
<txp:wet_article_thumb /><txp:kgr_safe_excerpt count=“35” mode=“words” linktext=”“ countexcerpt=“true” />
<txp:if_first_article><txp:chh_if_data><p class=“category”>New entry about&nbsp;༺<txp:category1 />༻&nbsp;</p></txp:chh_if_data>
<txp:else />
<txp:chh_if_data><p class=“category”>Archived entry about&nbsp;༺<txp:category1 />༻&nbsp;</p></txp:chh_if_data>
</txp:if_first_article>
<p class=“more”><txp:if_custom_field name=“reedmorevar”>
<txp:permlink><txp:custom_field name=“reedmorevar” />…….</txp:permlink></p>
<txp:else />
<txp:permlink>…more,more,..more…</txp:permlink></p>
</txp:if_custom_field>
<txp:else />
<txp:title /><txp:body />
</txp:if_article_list></code>

You can easily adapt this to your needs,

regards, marios

Last edited by marios (2006-06-23 03:38:33)


⌃ ⇧ < ⌃ ⇧ >

Offline

#27 2006-06-23 08:56:12

tkn
Member
From: New York
Registered: 2004-06-29
Posts: 39
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

Is there a way to get it to close off a blockquote tag if it is in the middle of one?

Offline

#28 2006-06-23 16:53:27

philipashlock
Member
From: Bellingham, Washington - USA
Registered: 2004-06-20
Posts: 58
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

@tkn

I’ve yet to figure out how to parse to check for unclosed tags, so for the time being, you’ll have to put something that nests paragraphs within the excerpt field. Any situation where this plugin might break a closing tag can use the excerpt field and it shouldn’t break the functionality of textpattern or this plugin, but obviously not as convenient. This issue is something still under investigation.

Also, my apologies to all for the broken link to the plugin – had an issue changing servers. All fixed now. Yes, it would be nice for textpattern.org to host the files.

Offline

#29 2006-07-01 19:14:40

valmeria
Member
From: France
Registered: 2005-10-22
Posts: 46

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

Hi All, I have a problem with this plug in.

I’m using it like that in my form

<code><div id=“une”>
<h3>A la une : <txp:title /></h3>
<txp:beginning length=“050” format=“insidelinktext=: Lire l’article” styleclass=“0” /></div></code>
.
but result is always much more than 50 characters or any value else I can put (even if I put 10 or 5 or 0 …).

I thought plug in was able to “cut” current paragraph to length indicated.

If my article (html) body is

<code><p>A l’occasion de la deuxi&egrave;me discussion du projet de loi DADVSI &agrave; l’Assembl&eacute;e Nationale en mars dernier, les d&eacute;put&eacute;s ont formalis&eacute; l’exigence de l’interop&eacute;rabilit&eacute; entre les diff&eacute;rents formats de fichiers num&eacute;riques et les diff&eacute;rents dispositifs de DRM pr&eacute;vus dans le texte. <p>Le paragraphe 7 prévoit notamment l’obligation de mettre à la disposition des divers intervenants de la filière les informations relatives aux différentes mesures techniques de protection, de manière à rendre possible l’utilisation d’un fichier acheté par exemple sur la boutique en ligne de VirginMega.fr sur le très convoité petit baladeur d’Apple, ou vice-versa. Le Sénat a introduit le création d’une Autorité de régulation, à même d’arbitrer entre les demandes d’ouverture de la part de Virgin par exemple, des Mesures Techniques de Protection – le jargon français pour DRM – d’Apple (au hasard) et la demande d’Apple dans cet exemple et des ayants-droits de conserver intacte l’efficacité de ces mesures de protection. La Commission Mixte Paritaire a maintenu ce dispositif dans son texte, voté ce matin par le Sénat, puis en début d’après-midi par l’Assemblée à sa suite.</p><p>Personne ne conteste la nécessité à terme de l’interopérabilité : mais était-il pour autant indispensable de légiférer et surtout aussi tôt?</p></code>
.
then I have the following result with the plug in :

A la une : DADVSI et l’obligation d’interopérabilité : Chantecler fera-t-il le soleil se lever? A l’occasion de la deuxième discussion du projet de loi DADVSI à l’Assemblée Nationale en mars dernier, les députés ont formalisé l’exigence de l’interopérabilité entre les différents formats de fichiers numériques et les différents dispositifs de DRM prévus dans le texte. Le paragraphe 7 prévoit notamment l’obligation de mettre à la disposition des divers intervenants de la filière les informations relatives aux différentes mesures techniques de protection, de manière à rendre possible l’utilisation d’un fichier acheté par exemple sur la boutique en ligne de VirginMega.fr sur le très convoité petit baladeur d’Apple, ou vice-versa. Le Sénat a introduit le création d’une Autorité de régulation, à même d’arbitrer entre les demandes d’ouverture de la part de Virgin par exemple, des Mesures Techniques de Protection – le jargon français pour DRM – d’Apple (au hasard) et la demande d’Apple dans cet exemple et des ayants-droits de conserver intacte l’efficacité de ces mesures de protection. La Commission Mixte Paritaire a maintenu ce dispositif dans son texte, voté ce matin par le Sénat, puis en début d’après-midi par l’Assemblée à sa suite. :: Lire l’article

As you can count, result is much more than 50 first characters of text …

Do I miss something ? Help please …

Offline

#30 2006-07-01 23:18:13

The-Exit
Member
From: Berlin
Registered: 2005-07-16
Posts: 175
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

hi

the help tells you:

length=”xxx” = The number of characters before the plugin generates the excerpt at the end of the current paragraph. Default is 350.

this means, the plugin will cut after the paragraph containing the 50th character.

if you want to cut at 50 you should use the kgr_safe_excerpt pluging.

Last edited by The-Exit (2006-07-01 23:18:43)

Offline

#31 2006-07-02 08:35:54

valmeria
Member
From: France
Registered: 2005-10-22
Posts: 46

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

Uh ! I had a doubt about that, thanks ! My english fault … I didn’t understood well help … I’ll see the other plug in.

<update>I checked this plug you said, great ! Thanks for information ;)</update>

Last edited by valmeria (2006-07-02 09:04:47)

Offline

#32 2006-07-02 09:53:02

Sencer
Archived Developer
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

The convention of using the author’s initials before the name of the plugin is not compatible with collaborative authorship, so in this case it will be dropped.

I hope nobody takes this personal, but that was not a good choice. The prefix is not to determine ownership of a person (which is merely a nice side-effect), but it is to make sure that function names do not clash between a) core-code and plugins and b) between different plugins and also to allow users to differentiate between core functionality and plugins. Using the authors initials was merely the easiest way to “hash” all the developers efficiently onto the set of three-letter prefixes.
A better choice in general when someone wishes not to use his name, is to make up a three letter prefix (with or without a meaning) and use that, q’s and x’s are little in use… ;)

Offline

#33 2006-07-08 13:20:13

Zanza
Plugin Author
Registered: 2005-08-18
Posts: 699
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

I’ve made some changes to this great plugin. The changes adds some functionality, so you may want them posted here or sent via email (in case let me know: who’s the mantainer dev?).

Changes explanation: I needed in one article form the capability of displaying the body beginning of the article even if there was an excerpt. Currently with the plugin it’s not possible. I added a ‘noexcerpt’ attribute. When set to 1, the excerpt is ignored, and the xxx chars of the body are showed.

I also added a customization tag for the read more link. Currently a span, I needed a p for styling commodity. Added a ‘moretag’ attribute that is used only when format is not inside.

The changes don’t affect present behavior, just expand it. So if you want to include them in the plugin let me know. Else, I could think of putting up a parallel version (but I’d rather not to do, already too many similar plugs…).

Bye

Z-

Offline

#34 2006-07-08 14:46:56

Dragan
Member
From: Novi Sad, Serbia
Registered: 2005-10-26
Posts: 100
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

Zanza, I’d appreciate it if you could send a copy of it to babicdragan a.t. gmail (c0m), thanx in front.

Offline

#35 2006-07-09 14:59:23

Zanza
Plugin Author
Registered: 2005-08-18
Posts: 699
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

I did, even if you seems to be on vacation. :)

Bye!

Z-

Offline

#36 2006-07-12 18:33:27

brian.zollinhofer
Member
From: Virginia
Registered: 2006-07-10
Posts: 24
Website

Re: [plugin] [ORPHAN] Beginning (update and merge of pfa_beginning + ede_beginning)

dinosauer: I haven’t used this yet, but perhaps something like this might work? I don’t know, just a guess…

<txp:beginning length=“500” linktext=“continue reading <txp:title />” styleclass=“morelink” />

again, just a guess. I don’t know if you can do <txp:stuff> inside other <txp:stuff>. :-)

Nevermind, I saw someone else already answered this. Now, how do I delete it? I hit delete, but there was no where to confirm that I wanted it deleted!

Last edited by brian.zollinhofer (2006-07-12 18:37:31)


Zollinhofer.com

“It is better to keep your mouth closed and let people think you are a fool than to open it and remove all doubt.”
- Mark Twain

Offline

Board footer

Powered by FluxBB