By soupp on
I think this nice Chameleon theme (and it's marvin css which I love) really misses "mission" box for a front page. Can somebody tell me how to implement it? I spent half a day but no result. Lack of programming skils.
Thanks
I think this nice Chameleon theme (and it's marvin css which I love) really misses "mission" box for a front page. Can somebody tell me how to implement it? I spent half a day but no result. Lack of programming skils.
Thanks
Comments
maybe you could try this...
hello,
try coding follow xtemplate lines. I think it could work:
- in chameleon.theme:
at chameleon_settings hook add just before return $output :
at chameleon_page hook add just after < id=\"main\" >;
that's enough in chameleon.theme
Now take your chameleon.css in the marvin chameleon directory and add you stylesheet to mission. As an example:
Good look. If you want contact me ( orzenil.jr at intertexto.net ) and I'll send a patch with these modifications
Orzenil
It works!
Thank you for guidelines. It works perfectly. But still strange why xtemplate and your example do not use mission from main admin/config but their own code.
And I think div's/class around $output .= ... $mission have been striped by drupal. So I added them.
Thanks again
PS How to post unstriped code if forums?
File feature request
Maybe file a feature request?
Chameleon mission statement in 4.5?
The suggestion worked perfectly with 4.4.2 but doesn't seem applicable now themes have been reworked. Can anybody suggest how to do it now? (I know next to nothing about php.)
Thanks for any help!
You can use my template
I modified the chameleon template to show the mission statment on the front page only. I also use just the style.css rather than both the common.css and style.css for simplicity. You can see the result here http://www.hivemindz.com/site . If you want the files I'll upload them somewhere. I also commented the PHP as much as possible to make it easier to find things on the theme page.
---------------------------
info for Drupal installation
__________________________
Carl McDade
Information Technology Consult
Team Macromedia
www.heroforhire.net
Oopp double post. Better make it right...uhhh
Is there a hack site somewhere or should I contribute here?.
---------------------------
info for Drupal installation
__________________________
Carl McDade
Information Technology Consult
Team Macromedia
www.heroforhire.net
Up to you
Most people seem to put shortish snippets of code (inserts to modules or whatever) in their posts here and longer pieces of code in posts on their own sites, to which they then link from here. Anyway, I'd like to see how you did it, however it's convenient for you to make it available.
(By the way, under Firefox 1.0PR running on Win98SE there's a formatting problem with your mission statement. The image seems to push the text off to the right, so not all of it appears on screen.)
I zipped on the server
http://www.hivemindz.com/site/themes/chameleon/chameleon.zip
I design in Firefox PR 1.0 on Xp. Nothing seems out of place. What resolution are you using?
---------------------------
info for Drupal installation
__________________________
Carl McDade
Information Technology Consult
Team Macromedia
www.heroforhire.net
Thanks!
Worked like a charm. Thanks!
To boil down what I got from your files:
1. In chameleon.theme, in the array of toggles at the beginning, I stuck in "'toggle_mission'," .
2. Right before "if ($title = drupal_get_title()) {" I stuck in:
if ($_GET['q']=="node"){
if ($mission = theme_get_setting('mission')) {
$output .= "<div id=\"mission-statement\">".$mission."</div>";
$output .= "<div id=\"main-content\">";
}
}
3. Then I added what worked for me for "mission-statement" in style.css.
On the browser point, I'm using 800x600.
first, those periods before
first, those periods before and after $mission, um, they didn't work for me. otherwise it works. thanks for the info.
on my theme/engine i'm developing from chameleon i used spaced css tags, eg- 'story entry', 'page entry', 'event entry'. so when i did the mission statement i used 'mission entry' so it appears at the top of the content area and it has a style it defaults to if none is specifically created for the 'mission' part of 'mission entry'. just a nice shorthand for css.
Adding the mission for 4.7
Just in case anyone like me finds this thread looking to add the mission statement to chameleon on 4.7, here's how I just did it:
Line 9:
add 'toggle_mission' to the list of features.
Line 77:
Then add something to the stylesheet for the 'site-mission' class.
Mission Statement in Chameleon in 5.X
I could not get my site mission statememt to appear in 5.X either. As an experiment, I added:
right before the:
that ends the:
header div in the chameleon.theme file.
After making this change, my Mission Statement shows up in the header section!