Category Comments
cambler
Registered Users Posts: 277 Major grins
Okay, so I've taken the really slick javascript replacement code posted in another thread and used it so that my layout knows when it's on a category page.
That is, my front page shows the categories, and when you click on one, you see the galleries in that category - we all know how that works. What I did was sniff the "cheerphoto's [whatever] galleries" and replace it with some other text specific to my site (see http://cheerphoto.smugmug.com if you're curious).
My text essentially tells my customers that they can select a team to see pictures. What I'd REALLY like, though, would be to be able to have customizable text here on a PER CATEGORY basis. Each of my categories is a cheerleading competition. I'd much rather be able to have text, per category, with some information on that competition.
Possible?
That is, my front page shows the categories, and when you click on one, you see the galleries in that category - we all know how that works. What I did was sniff the "cheerphoto's [whatever] galleries" and replace it with some other text specific to my site (see http://cheerphoto.smugmug.com if you're curious).
My text essentially tells my customers that they can select a team to see pictures. What I'd REALLY like, though, would be to be able to have customizable text here on a PER CATEGORY basis. Each of my categories is a cheerleading competition. I'd much rather be able to have text, per category, with some information on that competition.
Possible?
Photography: http://www.AmblerPhoto.com
Cheerleading: http://www.CheerPhoto.com
Blog: http://cambler.livejournal.com
Cheerleading: http://www.CheerPhoto.com
Blog: http://cambler.livejournal.com
0
Comments
-w
I went to check you site and saw this on your main page:
Competition Galleriespage/friendsandfamily.mg?FFID=25630&Type=Family&add=1">family ? )
I'm using IE6+/XP SP2, all the latest updates.
HTH
Where did you see this? Front page, gallery, or...?
Cheerleading: http://www.CheerPhoto.com
Blog: http://cambler.livejournal.com
Sebastian
SmugMug Support Hero
I hacked it up pretty quickly, but had to do a fair bit of debugging to get working on both IE and Firefox, but must missed this. I actually found this problem yesterday, but didn't realise that someone was actually using the code.
However, with the modification of my code you removed some important information...the '<' are important and should be left in.
Try this code, it should work for you...
Cheers,
David
SmugMug API Developer
My Photos
Can you 'splain to me the meaning of the "<" in the regex? I confess that while I'm a 20-year veteran developer, regular expressions are something I've never really gotten into
Cheerleading: http://www.CheerPhoto.com
Blog: http://cambler.livejournal.com
<strong>cheerphoto's gallery categories</strong>
I do this to attempt to prevent what was happening on the front page.
This command [^\f\n\r\t\v]+ matches all characters including space, so with out the '<' on the end, it ended up matching something I didn't intend it to.
Regular expressions are awesomely powerful, but can be dangerous..and produce unexpected results at times, if not used carefully
Cheers,
David
SmugMug API Developer
My Photos