Please login or register.

Login with username, password and session length
Advanced search  

News:

You need/want an older version of sNews ? Download an older/unsupported version here.

Author Topic: A better look for archive  (Read 2652 times)

Sven

  • ULTIMATE member
  • ******
  • Karma: 88
  • Posts: 2029
  • Chasing MY bugs!
    • hiseo.fr - rédacteur Web
A better look for archive
« on: August 15, 2009, 04:28:28 PM »

Howdee dudes?

To have a prettier and more readable HTML sitemap I've found thru Smashing Magazine this page (Sitemap Styler: Style your Sitemaps with CSS and Javascript).
This example (Javascript must be turned on) is pretty nice and, maybe I'm wrong, some snoozers will enjoy it as well.

First, I think it would be lighter to have the 2 needed CSS and JS files only called in head when the HTML sitemap is asked.

No problemo for that:
in function title:
Code: [Select]
case "sitemap":
echo '
<link rel="stylesheet" href="sitemapstyler/sitemapstyler.css" type="text/css" />
<script type="text/javascript" src="sitemapstyler/sitemapstyler.js"></script>';

The problemo is in the native function sitemap(): multiple UL are used (for pages, articles, cats and sub-cats) and the sitemapstyler script requires only 1 <ul id="sitemap">.

If someone interested by such improvment and has an idea to fix that problemo, wellcome!

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • “I'm a self-made man and worships my creator.”
    • p-ahlqvist.com
Re: A better look for archive
« Reply #1 on: August 15, 2009, 05:25:17 PM »

Mhm... would be a nice thingy... But wouldn't it work using the expanding thingy function in snews ?
Logged
"It's only dead fish that goes with the flow... "
Updated

Fred K

  • Still trying to learn stuff
  • ULTIMATE member
  • ******
  • Karma: 130
  • Posts: 2728
    • Personal
Re: A better look for archive
« Reply #2 on: August 15, 2009, 05:34:50 PM »

Good idea but SMs solution isn't the best imho -- for one thing their examples don't work in Safari 4/Mac, so there they loose me... ;)
I'm using a quickie jQuery solution in combination with the (sort of) standard sNews sitemap, because I'm usually using a bunch of other jQuery tricks, so Pat's statement seems to hold water (e.g using the standard toggler or one of the toggler mods presented not too long ago should work). My solution can currently be seen in this footer. ;) (note: server seems to be a bit slow lately, at least it is for me.)
Logged

Keyrocks

  • Doug
  • ULTIMATE member
  • ******
  • Karma: 449
  • Posts: 6019
  • Semantically Challenged
    • snews.ca
Re: A better look for archive
« Reply #3 on: August 15, 2009, 05:38:34 PM »

Howdee dudes?

This example (Javascript must be turned on) is pretty nice and, maybe I'm wrong, some snoozers will enjoy it as well.  If someone interested by such improvment and has an idea to fix that problemo, wellcome!

Sven... have a look at This Sitemap Page on one of my more recent (ongoing) projects. It uses folder and page icons but it essentially does the same thing as your example... and using the standard functions already in sNews 1.6. Click through the folder icons to see what I mean.
Logged
Do it now... later may not come.
-------------------------------------------------------------------------------------------------
sNews 1.6 MESU | sNews 1.6 MEMU

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • “I'm a self-made man and worships my creator.”
    • p-ahlqvist.com
Re: A better look for archive
« Reply #4 on: August 15, 2009, 05:49:42 PM »

JQuery was my first "go to get", but as I havn't really seen an example of that yet (until Fred's) I held my tounge... I have JS turned off/banned at work, BUT JQuery solutions work... go figure..

Is you Callendar thingy just toggle function ?
Logged
"It's only dead fish that goes with the flow... "
Updated

Keyrocks

  • Doug
  • ULTIMATE member
  • ******
  • Karma: 449
  • Posts: 6019
  • Semantically Challenged
    • snews.ca
Re: A better look for archive
« Reply #5 on: August 15, 2009, 06:01:35 PM »

Is you Callendar thingy just toggle function ?

Yes, I think I'm using a second toggle function, re-naming the original one, so it runs separately... though I'd have to check again to be sure.
Logged
Do it now... later may not come.
-------------------------------------------------------------------------------------------------
sNews 1.6 MESU | sNews 1.6 MEMU

Sven

  • ULTIMATE member
  • ******
  • Karma: 88
  • Posts: 2029
  • Chasing MY bugs!
    • hiseo.fr - rédacteur Web
Re: A better look for archive
« Reply #6 on: August 16, 2009, 09:40:56 AM »

Thanks Dude for you answer.

I finally managed it with a 5ko script used in this page . Its an advanced version of the previous script.
It works in my browsers (Chrome, IE 8, Opera 9, FF 3.5).

Need to style it now but you can have a demo on my playground private blog.


Hum... problemos with some browsers... need another solution.
Doug did you publish your sitemap Mod?
« Last Edit: August 17, 2009, 12:12:56 PM by Sven »
Logged