|
Post by kokopuffs on Mar 7, 2007 14:04:58 GMT -5
I have 2 questions:
I was messing around with my main templates and found that either I had deleted or simply lost the tag that would link to the aentry.. for extended text. I looked at the reference and couldn't find what I was looking for...
is there a specific tag for that or would I have to directly link to the archive page?
Second, is there a sytem to make a sort of "tag" archive type thing, where if someone looked up a keyword, like "reviews" it would bring up all entries tagged with "reviews"?
Thanks in advance ~koko
|
|
|
Post by Carlos Phelps on Mar 7, 2007 14:47:18 GMT -5
You are most likely looking for this tag {{entrymorebody}} You can find the list of tags in the manual, it is online at this link web.petefinnigan.com/gm_manual.html#8Coldstone and I have been talking about adding tags/labels and maybe tag clouds, but at this point it is not in GM 1.7.1 and won't be in release 1.7.2
|
|
|
Post by petefinnigan on Mar 8, 2007 12:44:00 GMT -5
Hi guys,
I also have on my wish list the need to be able to add "tags" to each post and then for the GM software to generate tag index pages and individual pages of entries that link to the tags. From my initial thought experiements on this, i feel it would not be trivial to implement as the solution would need to be able to rebuild the tag index and detail pages from the tag storage. would the tags be stored with the posts or in an individual store?
cheers
Pete
|
|
|
Post by Carlos Phelps on Mar 8, 2007 13:50:44 GMT -5
Pete,
Since any post may have more than one tag or label it is my believe the best thing would be for the tags to be stored in an individual file.
This way each tag could be linked to one or more posts and the mod would be a low impact on the existing database since it is already indexed.
For processing we could always load both files into a hash to speed up the sorting and output.
|
|
|
Post by petefinnigan on Mar 8, 2007 15:48:21 GMT -5
Hi Carlos,
Yes I agree that would be the best way to approach it. If a large number of tags existed though it may get slow. Having a central tags data file linking to posts would make it easier to rebuild all the tag pages.
cheers
Pete
|
|
|
Post by coldstone on Mar 8, 2007 16:18:26 GMT -5
I like the idea of keeping all data for an entry, in that entry. While I think a master file of tags to tag_id should exist (to facilitate renaming), I think tags can easily be stored in an entry file immediatly after the karma ip list (similar format too). There isn't any condition that would prevent a entry from having more than one tag if the tags are kept in the entry file. Some issues that I think would have to be addressed follows: - New admin screen to create/delete/modify tags (which would work off of gm-taglist.cgi)?
- New widget on add/edit entries to add/remove tags from post such as droplists with more button?
- New template variable {{entrytags}} which would give list of tags (seperated by commas? Template? Would tags be links and where would they link to?
- Would we need new gm variables like {{taglist}}, which seems like we would also need a taglist template then, to allow users control over taglist formatting.
- Would a tag page be created, similar to master archive, which stories listed for each tag, or would a 'tag' page (with all entries) be created in the archives? Templates would be needed for some/all of these ideas.
I think this feature would be pretty cool. However, it seems like it would be easy for everyone to be on a separate page. I think we could come up with some sort of very informal requirements document (very, very informal ) just to make sure we cover all bases and we are on same page.
|
|
|
Post by petefinnigan on Mar 8, 2007 16:35:48 GMT -5
Hi Coldstone,
I liked the idea of a seperate tag "database" because I would generate an index page for all tags created. This list of tags would be links in a similar fashion to the archive index page. The links would link to a seperate page for each tag. Then on each tag page a link would exist to each post that had the tag in it. I would probably like to see something like a feed reader page for the tag pages so that you get a title and a small taster of the text of the post. If the tags are stored with the posts it would be quite complex to parse each post and create / update the individual tag pages. It would be better and cleaner for updates if the tags are stored seperatly. i.e.
tag|1,167,109,75 anothr tag|1,3,8,9
...
what do you think?
cheers
Pete
|
|
|
Post by coldstone on Mar 9, 2007 12:48:45 GMT -5
I still side on keeping it all in one place.
I looked around at some other websites with tags and agree with your ideas. I was thinking we could do templates similar to what exists for the search page templates. We want a seperate 'tag' page, with 'tag entries' etc. The sites I looked at seemed to have a seperate page for each tag, but I was wondering if people want a main tag page, which having 'tag' sections (with anchor links). I suppose that could be a configuration.
If we follow the search templates, we give the user a lot of flexibility on how the entries for a tag are 'previewed' or displayed.
I think the complexity is the same whichever way we do it. We will always have to look up the entry in order to get title, synapsis, etc. for each tag. I really like the idea of being able to get an entry and being able to get the ->{info}, ->{karma}, and eventually, ->{tags}, but to do this with a central tag db, we will have to hit two files to load up an entry's information. I believe adding the tag information to the entry file will be easy since its handled by setEntry and getEntry. We don't have to update every entry when the feature is introduced, the getters and setters will handle it for us.
|
|
|
Post by petefinnigan on Mar 11, 2007 12:00:15 GMT -5
Hi Coldstone,
Thanks for your comments. I can see your point on keeping the tags with the entries. If a new tag is added then the update routine would simply find the existing tag page and append the entry to it. So in normal operation i think you are right, its better. In the case of a rebuild, then each entry would be parsed in turn and the tags would be added to the relevant page as needed. We would probably need to re-create tag entry pages on rebuild to prevent duplications.
I can see your point on the search style template but I think that looks cluttered. I would prefe to see
<page> {tag title}
{link to entry num} {entry title} {short extract from entry - 50 words - inc highlight the tag}
{repeat next entry}
</page>
BUT, you are right on one thing, if we just had the above it would not highlight the tag use in the page. So you are probably more right about the template layout. - or maybe we are both right and the owner of the blog should choose the style that they want.
cheers
Pete
|
|
|
Post by coldstone on Mar 12, 2007 11:53:05 GMT -5
Maybe because its Monday, but I am having trouble following I was just looking at the Search Templates as a model of stuff we need. I figure we would need a Taglist template, to display a list of tags. It would use {{tagname}} to insert the name of the tags. Links to the tag page would be done similar to how links are done for each entry. The tag page would use a template Tag Page Template, which could be done similar to how you demonstrated (with also using the {{tagname}} var), except it would have {{tagentrylist}} or some such name (similar to 'Search Results Page Template'). I was thinking the tag page would be a file in the archives directory following the pattern gm-{{tagname}}.cgi. Then finally, there would be a Tag Entry Item Template, that would be the entries with the tag that are listed in the {{tagentrylist}} ( similar to the 'Search Item Results Template'). One additional point to consider is, I was talking to a friend who uses WordPress and something he found very useful is 'sub-categories', and for WP they are only 1 level deep. So he has a 'movies' category with sub categories of 'action', 'sci-fi', etc. I think it wouldn't be much more difficult, it would just mean that on the Tag Page Template, that some sort of way to loop through all the sub-tags. I guess I have thought of 'tags' and 'categories' as synonymous, but should they be? Do people want 'sub-tags'? BUT, you are right on one thing, if we just had the above it would not highlight the tag use in the page. So you are probably more right about the template layout. - or maybe we are both right and the owner of the blog should choose the style that they want.
|
|
|
Post by Carlos Phelps on Mar 12, 2007 12:02:47 GMT -5
Coldstone, This is a good question. I will look around at some of the other bloging software/websites and see what they are doing. I'll give you my twisted views in a few days.
|
|
|
Post by petefinnigan on Mar 13, 2007 6:47:42 GMT -5
Hi Coldstone, Thanks for your input, sorry if i confused you I agree with most of what you suggest apart from the pages being dynamic - at least that is what i think you are suggesting. I dont totally disagree with the dyamic pages but would like the option to build static html pages as per the rest of GM, this is one reason I came to GM in the first place and stayed. For performance, security and also for SEO reasons. The second issue around categories is that I agree with having categories in GM, this was on my wish list. There was a hack on the old forum using mood/music as a category but we need to do this properly and have supporting template variables to list the categories on the index page and also templates to generate category index pages. I think tags and categories are seperate, categories can have sub-categories but sub tags dont make sense, tags are tags. I think we should look to implement categegories in GM soon. cheers Pete PS: maybe we need a very informal / brief RFC listing what we want to add to GM, a brief overview of the functionallity and a planned release version?
|
|
|
Post by coldstone on Mar 13, 2007 12:05:11 GMT -5
|
|