Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
#25 2004-07-01 16:18:53
- pynchon
- New Member
- Registered: 2004-06-14
- Posts: 3
Re: Articles by Category
Matt, thanks for your quick reply! No, I don’t have my install in a subdirectory.
Had my server support working on this. They were helpful enough to try a test fresh install on their own and still couldn’t get it to work. Oh well, this sounded like just the thing I needed. But I guess I’ll have to wait for something else.
Offline
Re: Articles by Category
> bluearc21 wrote:
> Could Dean or someone post how to edit this plugin so it prints the new “URL-only title” links – and not the older article title method?
Dean – Anyway to update this plugin?
“If you build it, they will come.”
Offline
Re: Articles by Category
Okay, the following two changes to the Articles by Category plugin offered by Dean will print your content map with links to the new “url-only title” available in the advanced menu of article publishing.
1st change:
Original Plugin Query:
<code>
$rs = getRows(“select ID, Title, Section from textpattern […]
</code>
Plugin Query Mod:
<code>
$rs = getRows(“select ID, Title, url_title, Section from textpattern […]
</code>
2nd change:
Original Plugin code:
<code>
if (trim($Title)) {
$url = ($url_mode)
? tag($Title,‘a’,’ href=”’.$pfr.$Section.
‘/’.$ID.’/’.stripSpace($Title).’”’)
: tag($Title,‘a’,’ href=”’.$pfr.
‘index.php?id=’.$ID.’”’);
$thislist[] = tag($url,‘li’);
}
</code>
Mod Plugin code:
<code>
if (!($url_title)) {
trim($Title);
$url = ($url_mode)
? tag($Title,‘a’,’ href=”’.$pfr.$Section.
‘/’.$ID.’/’.stripSpace($Title).’”’)
: tag($Title,‘a’,’ href=”’.$pfr.
‘index.php?id=’.$ID.’”’);
$thislist[] = tag($url,‘li’);
}else {
trim($Title);
$url = ($url_mode)
? tag($Title,‘a’,’ href=”’.$pfr.$Section.
‘/’.$ID.’/’.$url_title.’”’)
: tag($Title,‘a’,’ href=”’.$pfr.
‘index.php?id=’.$ID.’”’);
$thislist[] = tag($url,‘li’);
}
</code>
“If you build it, they will come.”
Offline
Re: Articles by Category
I have the same problem as pychon I installed textpattern in a subdirectory though.
Offline
Re: Articles by Category
> Macindy wrote:
> Can somebody help me with a modification:
I don’t want that the plugin produces a list of ul and li tags. Simple puts the categorys in h5 tags and the article title in p tags.
It’s a list of things… why not use the list HTML tag then ? It has absolutely no disadvantages, and it’s developper’s friendly (aka semanticaly correct).
Offline
#30 2004-09-18 11:50:04
- animoller
- Member
- Registered: 2004-04-19
- Posts: 22
Re: Articles by Category
When I turn this plugin on (and any other plugin for that fact) I get this:
/var/www/animoller.com/htdocs/text/textpattern/publish.php on line 742
Warning: fopen(/tmp/pluginsaZfpOj): failed to open stream: Success in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 742
Warning: fwrite(): supplied argument is not a valid stream resource in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 743
Warning: fclose(): supplied argument is not a valid stream resource in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 744
Warning: plugins(): SAFE MODE Restriction in effect. The script whose uid is 10019 is not allowed to access /tmp/pluginsaZfpOj owned by uid 33 in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 745
Warning: plugins(/tmp/pluginsaZfpOj): failed to open stream: Success in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 745
Warning: plugins(): Failed opening ’/tmp/pluginsaZfpOj’ for inclusion (include_path=’.’) in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 745
Warning: unlink(): SAFE MODE Restriction in effect. The script whose uid is 10019 is not allowed to access /tmp/pluginsaZfpOj owned by uid 33 in /var/www/animoller.com/htdocs/text/textpattern/publish.php on line 746
Help?
Offline
Re: Articles by Category
Are you using version 1.19? This looks like an older version of Textpattern…
Who’s gonna textdrive you home tonight?
Offline
#32 2004-09-18 13:54:10
- animoller
- Member
- Registered: 2004-04-19
- Posts: 22
Re: Articles by Category
No, 1.18.
Offline
#33 2004-10-11 02:18:17
- odinsdream
- New Member
- Registered: 2004-10-05
- Posts: 2
Re: Articles by Category
Is there a way to make this thing aware of what page it’s on? I’d like to print out the entire list whenever the user is on the main page, but once they choose a category, I’d like for the list to only output the articles for that category. How can I pass this information to the script dynamically, for each page?
Offline
Re: Articles by Category
Is this plugin section aware? I’d love to use this type of thing as a categorized section list, or is there another way to do this?
charlie
Offline
Re: Articles by Category
There’s another one you might consider for that.
“If you build it, they will come.”
Offline