Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#16 2004-11-07 02:12:24

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

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Hi Rob (whilshire),
It’s been a while since I’ve poked around my textpattern installation, so I can’t quite figure this out, but the way my archives are set up doesn’t quite work with the way links are generated for articles with this plugin.

My archives are created so that the URL looks like : www.domainname.com/section/10/name-of-article

This plugin however doesn’t expect there to be the article name as part of the URL. If you know if there is an easy way to modify the plugin please let me konw, but in the mean time I’ll just poke around myself. If I figure it out I’ll submit my modification.

Thank you so much for this plugin, it’s really wonderful. Let’s all work together to make it even better. If I find the time, I plan to add the ability to show an archive of authors.

Offline

#17 2004-11-07 05:52:30

wilshire
Plugin Author
From: Akron, Ohio
Registered: 2004-08-27
Posts: 656
Website

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Philip – As far as I know there’s no reason the article links that the plugin generates wouldn’t work. Have you tried to use the plugin and seen a problem?

“If I find the time, I plan to add the ability to show an archive of authors.”

Are you just looking to show the articles grouped by author as well?

Offline

#18 2004-11-07 06:12:19

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

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Here is the page where I’m trying to use your plugin:

URL was removed

So yes, I have used the plugin and seen the problem. It seems that the plugin assumes that the URL structure doesn’t include the last part with the hyphenated title. In other plugins I see a function called something like doPermlink() to create the proper URL, would it make sense to use something like that for the URL’s in this case?

I would like to be able to show articles grouped by author, but first I’d like to get your plugin to work with its current functionality. I have a little bit of experience creating plugins, I put together the pfa_beginning plugin but I’ve yet to fully understand how to modify your plugin to achieve everything I’d like it to.

Any help in getting this working would be much appreciated.

Thanks,
phil

Last edited by philipashlock (2004-11-07 11:05:04)

Offline

#19 2004-11-07 06:21:06

wilshire
Plugin Author
From: Akron, Ohio
Registered: 2004-08-27
Posts: 656
Website

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Phil – When I try to view an article with the URL http://auraluna.philitopia.com/archives/7/locked-out-of-pennycandy I still only see the archive listing.

Are you able to see the article at that URL?

Offline

#20 2004-11-07 06:33:29

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

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Strange. I put your plugin into a form that separates the archives page into if_individual_article and if_article_list and that made your URL’s seem to work on my site, but it also seems to generate the result of the plugin five times. Do you know why this might be and why I now have to possible URLs for any article – one with the hyphenated title and one without. Thanks

Offline

#21 2004-11-07 06:44:29

wilshire
Plugin Author
From: Akron, Ohio
Registered: 2004-08-27
Posts: 656
Website

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Hmm…looks like its outputting the archive once for each article. I’ve never tried using the plugin on a form, just a page. I also post my articles in one section and display the archive in another but the plugin still generates the link to the correct section.

Try adding this line to the plugin somewhere and see if it helps but I’m not sure it will make a difference.
<code>
$GLOBALS[‘is_article_list’] = true;
</code>

Last edited by wilshire (2004-11-07 06:48:27)

Offline

#22 2004-11-07 06:46:34

proph3t
Member
Registered: 2004-09-26
Posts: 31

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Does your category list allow more than two categories, as i have about 4 that need to be included. This feature would be awesome!

Offline

#23 2004-11-07 06:49:05

wilshire
Plugin Author
From: Akron, Ohio
Registered: 2004-08-27
Posts: 656
Website

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Yes, as many as you’d like to include.

Offline

#24 2004-11-07 07:00:54

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

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Ok, now that I understand what’s going on, I’ve created a separate section to use for your plugin. I don’t think that it’s possible to use your plugin for the archives page of a particular section because it will cause the problem that I was having. In order to separate a listing of articles for a section from a particular article in that section you must use a form that will separate the display between

<code>
<txp:if_individual_article> and <txp:if_article_list>
</code>

It would be really nice to be able to use this plugin from within a form so as to be able to use sections to display a list of the articles within that section. Currently this is not possible.

Thanks for the plugin though. It’s wonderful. Also thanks for helping me figure this out, I now have a better understanding of why I was getting the results of your plugin on the pages for the individual article.

Last edited by philipashlock (2004-11-07 07:01:56)

Offline

#25 2004-11-07 07:09:19

proph3t
Member
Registered: 2004-09-26
Posts: 31

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Doesnt seem to inlude all of the categories i listed, check it out here:

http://www.holdem-strategy.net

It only shows the first one (holdem intro)..

Last edited by proph3t (2004-11-07 07:11:05)

Offline

#26 2004-11-07 07:20:52

proph3t
Member
Registered: 2004-09-26
Posts: 31

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Fixed it, cant have spaces after the commas.. silly me

EDIT: Is there a way for this to display the full article URL instead of the short version?

www.site.com/article/10/the-article

instead of:

www.site.com/article/10

Last edited by proph3t (2004-11-07 07:48:23)

Offline

#27 2004-11-07 10:55:25

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

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Ok, I’ve found a solution.

If you would like to use this plugin to display an archive of the articles for one particular section and have the list generated at the URL for this section, but also be able to properly display the specific articles in the section, this is what you need to do:

On the page that you have defined to be used for your section, place the following code:

<code>
<txp:if_article_list> <txp:rss_suparchive section=“SECTIONNAME” dateformat=“F Y” showsection=“1” showcats=“1” showsubdate=“1” class=“aa” addbreak=“1” limit=“1000” />
</txp:if_article_list>

<txp:if_individual_article> <txp:article />
</txp:if_individual_article>

</code>

&nbsp;
&nbsp;
&nbsp;

You may want to replace
<code>
<txp:article />
</code>
with something like:
<code>
<txp:article form=“Archives” limit=“1000” />
</code>

If you display your archived articles differently than how they’re shown on the frontpage.

You can obviously edit the attributes for the rss_archive plugin to fit your needs. For that matter, you can alter anything to fit your needs, this is just to provide an example. Enjoy.

Last edited by philipashlock (2004-11-07 11:12:08)

Offline

#28 2004-11-07 22:33:48

Andrew
Plugin Author
Registered: 2004-02-23
Posts: 730

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Killer plugin. Just a note, the URLs are not using the title or url_title in /clean/ mode. Might tweak it so that URLs appear as http://domain.foo/archive/id#/url-title/.

ex:
<code>$title = ($url_title) ? $url_title : stripSpace($title);</code>

You’d probably have to also alter your query to request the url_title as well, as now it’s not currently querying for it. I’m also checking out your query & you could probably simplify it a bit by using Dean’s prefab db accessing funcs in txplib_db.php.

ex:
<code>$res = getRows($query); </code> (pushes results thru mysql_fetch_array so you’ll have access to keys – making your code read easier)

Either way though, bravo. This plugin kicks all sorts of ass.

Last edited by compooter (2004-11-07 23:13:55)

Offline

#29 2004-11-07 22:43:37

proph3t
Member
Registered: 2004-09-26
Posts: 31

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Yeah compooter, I would like to have this too. Great work on the plugin though, its on my site now.

Offline

#30 2004-11-07 23:08:14

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

Re: [plugin] [ORPHAN] rss_suparchive - article archive list

Wilshire,

I have a simple improvement to your plugin. This will allow the browsing of a particular category to change the display of the plugin output (but only if a category isn’t specified in the plugin)

Here are the code changes:
<code>
global $path_from_root, $siteurl, $c;
extract($atts);

$section = isset($section) ? $section : “article”;
$category = isset($category) ? doSlash($category) : $c ;
</code>

This is just an excerpt from the top of the plugin. It adds the current category ($c) to the global variables needed and then uses that variable as the “else” condition for the specification of the category attribute.

This is a huge advantage for me because I am using your plugin to display the article list of the articles for a particular section. I also have my site set up to allow you to browse specific categories, but without this modification that does not work with your plugin.

I hope you implement this, it will offer a great benefit for people using your plugin as a section article list and shouldn’t affect any other uses of the plugin.

You can see an example of my usage at:

Auraluna.org

note: the category links are on the right side menu

Last edited by philipashlock (2004-11-07 23:11:48)

Offline

Board footer

Powered by FluxBB