Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#85 2005-04-28 16:41:35
- alexandra
- Member
- From: Cologne, Germany
- Registered: 2004-04-02
- Posts: 1,370
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
> spchampion wrote:
>Actually, I got in (I start at Cornell in the fall)
Congrats Stanton. Hope everything works out fine for you at Cornell!
Offline
#86 2005-04-28 16:59:33
- spchampion
- Archived Plugin Author
- Registered: 2004-06-10
- Posts: 62
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
> alexandra wrote:
> Congrats Stanton. Hope everything works out fine for you at Cornell!
Thanks! I’m really excited about it!
Offline
#87 2005-04-29 00:20:15
- marios
- Archived Plugin Author
- Registered: 2005-03-12
- Posts: 1,253
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
spchampion,
thanks,for your reply and congratulations allso for cornell.
Well it seems,I have been silly or brain lazy or something.Since I only have semantic template changes, I do actually not need just to use one page template for all sections.I can use a range of templates(All the heavy stuff ,like png files CSS and so on doesn’t change anywhay,I mean the layout)
Just get’s fetched from browser cache and finito (In my case).
So I have been reverting back to rdt_dynamenus for now, it will allso allow me to hide certain sections on page templates, and I can still combine all that conditional stuff that I like,may be even with your plugin.
I haven’t had a look into yours yet because I couldn’t find any practical examples,how you form the tags.
(You see, I am still a newbee with textpattern ).
So for now it seems my problem is temporary solved.(Well,until something stop’s working, I guess).
I’m on revision 328 right now and it seems to run good.
Had a look at your site allso, reading some interesting stuff there about php and security,
regards, marios
(I will keep your plugin on my test install and try that one later once I’m through the hard stuff)
Last edited by marios (2005-04-29 00:22:04)
⌃ ⇧ < ⎋ ⌃ ⇧ >
Offline
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
I get for every undefined variable an error message: Error 8 Undefined variable: group in spc_section_alias(), /usr/local/apache2/htdocs/textpattern/lib/txplib_misc.php(351) : eval()’d code line 28
If I change the plugin code, i.e.: <code> if(!$group || ($group == “”)) { $group = “default”; }
</code> into <code>
if(!isset($group) || ($group == “”)) </code> the error disappears.Is it me, txp 1.0rc3 or my php 4.3.11 configuration, that the original code doesn’t work?
Offline
#89 2005-07-11 05:28:17
- spchampion
- Archived Plugin Author
- Registered: 2004-06-10
- Posts: 62
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
> tranquillo wrote:
> Is it me, txp 1.0rc3 or my php 4.3.11 configuration, that the original code doesn’t work?
Well… Using isset is definitely semantically cleaner (I’m a C person — can you tell? :> ). However, that plugin has worked for almost 10 months now for a lot of people.
I will say this: I’m running a patched version of PHP 4.3.10, so there could be a problem that was introduced with 4.3.11.
Can anyone else add anything?
BTW, somehow, the code you referenced above got eaten. There should be two equal signs in one of those if() clauses.
Offline
#90 2005-08-25 14:30:55
- spchampion
- Archived Plugin Author
- Registered: 2004-06-10
- Posts: 62
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
What the heck happened to all my examples? I am so out of the loop these days, so I have no idea what’s going on around here… Grad school does that, I guess. Can someone give me a quick howto on making my examples return to the page? I’m sure it’s some combination of pre and code, but it looks like textile is stripping out the example XHTML tags…
Offline
#91 2005-08-25 14:46:24
- spchampion
- Archived Plugin Author
- Registered: 2004-06-10
- Posts: 62
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
Well it looks like “pre” stopped working. Great… I’ve changed all of my posts so that all of the examples are wrapped in code /code, but I have no idea if that’s right or wrong here. If something doesn’t look right, let me know.
Offline
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
I know this is probably not possible, but still…
I have a large list of sections, shown with spc_section_alias_iterate. What I need is to NOT show some of the sections in that list.
At first I thought to create a new section_prefix form that includes only the sections I want to list. But I don’t know how to make the _iterate to use this new section_prefix form… Any advice appreciated!
Offline
#93 2006-10-18 13:03:07
- spchampion
- Archived Plugin Author
- Registered: 2004-06-10
- Posts: 62
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
In the section information, set inactive=“1”. With this set, iterate will simply ignore the section entirely.
Offline
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
Thanks, that worked.
But I have another case now. Similar list of sections and some of them have to appear in the navigation, others – not. But all of them have to show Name and Description in the appropriate sections, so I cannot ignore them.
What I did is set group=“1” to the ones I need in the navigation, then iterate only group=“1”. And that worked just fine. Here’s the problem. I have spc_section_alias_article_link with group=1 in the header of the site, to show a link to the section the current article is in. But this link does not show in sections, that are not in the 1 group…
Offline
#95 2006-10-19 14:29:32
- spchampion
- Archived Plugin Author
- Registered: 2004-06-10
- Posts: 62
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
You can add more than one group in a list with the group= statement. So you can do group=“1,2” or something like that. The plugin will look through every group in the list for the section you want.
Offline
Re: [plugin] [ORPHAN] spc_section_alias - Section renaming and management plugin.
Yah, that’s what I tried at first, but I couldn’t get it working, so I kinda worked my way around the problem with some if_sections. Of course, it’s never that easy, as now it seems ob1_title does not work with your plugin anymore :) I went and hacked support for it (using the code from 1.4 in 2.x with some rewriting), but I cannot pass group parameter to ob1_title…
Anyway, it’s never easy with TXP and I’m kinda used to this – constant tinkering in the source needed…
Thanks for your help.
Offline