Hello,
I apologize if this questions has been raised in the past, but I'm getting quite frustrated, not being able to find it in any cmsms nor smarty documentation. Perhaps I'm searching for it incorrectly.
What I'm talking about is links. It was quite an accomplishment, I felt, to finally figure out how that it was global content blocks where I could put all of my sidebars and widgets. It was a step in the right direction when I discovered that I should click that little green icon which would unlock the menu templates, and which upon clicking on 'default,' I could use with the {menu} command to keep track of and organize my links. At first I was struck with how effortless it was.
But then I got stuck. Woefully stuck. I'm considering starting drinking again: I've already been sober for twelve hours.
The questions are such:
The link that corresponds to the page that I'm currently on (for example, the "Home" link, when you first arrive at index.html); how can I change its background color so that it stands out from the other links?
Second, related to the first: How do I make one certain link in the menu a different color? For example, the "Donate" page always green, in contrast to blue for all the others? You know, for money.
Third, getting a little more complex - how do I configure the options, the commands, of a mailing list mailer? One that looks, perhaps, like this?:
<form method="post" action="http://scripts.dreamhost.com/add_list.cgi">
<input type="hidden" name="list" value="mailer" />
<input type="hidden" name="domain" value="fullerdomehome.org" />
<input type="hidden" name="url" value="http://fullerdomehome.org/mailer-subscribed.html" />
<input type="hidden" name="unsuburl" value="http://fullerdomehome.org/mailer-unsubscribed.html" />
<input type="hidden" name="alreadyonurl" value="http://fullerdomehome.org/mailer-already.html" />
<input type="hidden" name="notonurl" value="http://NotOnURL" />
<input type="hidden" name="invalidurl" value="http://InvalidURL" />
<input type="hidden" name="emailconfirmurl" value="http://fullerdomehome.org/mailer-confirm.html" />
<input type="hidden" name="emailit" value="1" />
<p class="mar-bot-5">Name: <br /><input name="name" />
<p class="mar-bot-5">E-mail: <br /> <input name="email" />
<p class="mar-bot-5"><input type="submit" name="submit" value="Join Our Mailing List" /> <input type="submit" name="unsub" value="Unsubscribe" /></p>
This is a server-side mailer, and it works great. The problem here is that when someone clicks 'subscribe,' the mailer wants to send them to an appropriate page (emailconfirmurl to tell you an email confirmation has been sent, alreadyonurl to tell you that you're already on the list, and so on). However, these non-cms link away from the site that is being run under cmsms.
The address of the cms page is fullerdomehome.org/cms, but the pre-cms site at fullerdomehome.org still exists in its prior incarnation. If I left the code as it is, I would just be linking to a page that sort of resembles the page you were just on, before you clicked to subscribe to mailing list, with everything now looking barren and out of date. You have no idea how to get back, as every link that once looked the same is now taken you to more barren and out-of-date pages. You click back half a dozen times, but the bad taste lingers in your mouth.
One final question: how do I provide a link to an external site within the menu? The only links it seems to provide are the ones that correspond to my pages.
I apologize for the laundry list, but perhaps four of you have found my query entertaining, and can easily provide an answer. Thanks a million, and happy camping.
Links!
Re: Links!
OK, crazy. The background color fixed itself (how, I have no idea...), and I wrote up a workaround for the mailer issue. I developed an HTML page and accompanying stylesheet pretty much identical to the CMS page, but residing outside of the CMS framework, with just one link back to the .php homepage, like so: http://fullerdomehome.org/mailer-confir ... blo&code=3
So the questions that remain are:
How do I change the color of individual links? Before transferring the site to the CMS framework, I simply used class="green" on one certain link. Also, is it possible to include an external link within the menu? Also, related to the previous question, is it possible to have active pages that are not in the menu?
Thanks!
So the questions that remain are:
How do I change the color of individual links? Before transferring the site to the CMS framework, I simply used class="green" on one certain link. Also, is it possible to include an external link within the menu? Also, related to the previous question, is it possible to have active pages that are not in the menu?
Thanks!
Re: Links!
Uhh, sorry guys. The current menu link in the menu did NOT fix itself. I was merely looking at the link that I'm hovering over and, in a state of confusion, though that that's what I was after. What I was after was the link of the page I am currently on being a different color. In its pre-CMS incarnation I used class="current." Sorry.
Re: Links!
I'll step up to help a fellow Carbondale resident here..
{if $node->parent == true or $node->current == true}
..
<li class="active"><a class="active" href="{$node->url}"><span>{$node->menutext}</span></a>
Then in your CSS you can style that "active" class.
1) Maybe <li class=$node->menutext><a class="active" href="{$node->url}"><span>{$node->menutext}</span></a>
...and then add classes for each..
Maybe set the class to $node->index might be a little safer but reorganizing the ordering of your pages might break that.
I'll jump to your last question here..
When you create a new page under "Content Type" (very first option) You can select Redirecting Link.
Once you do that the rest should be obvious.
In your menu template: you are looking for this:The link that corresponds to the page that I'm currently on (for example, the "Home" link, when you first arrive at index.html); how can I change its background color so that it stands out from the other links?
{if $node->parent == true or $node->current == true}
..
<li class="active"><a class="active" href="{$node->url}"><span>{$node->menutext}</span></a>
Then in your CSS you can style that "active" class.
Couple ways to do that...Second, related to the first: How do I make one certain link in the menu a different color? For example, the "Donate" page always green, in contrast to blue for all the others? You know, for money.
1) Maybe <li class=$node->menutext><a class="active" href="{$node->url}"><span>{$node->menutext}</span></a>
...and then add classes for each..
Maybe set the class to $node->index might be a little safer but reorganizing the ordering of your pages might break that.
I'll jump to your last question here..
When you create a new page under "Content Type" (very first option) You can select Redirecting Link.
Once you do that the rest should be obvious.
Re: Links!
To target each LI/a with a class you can change the menu template, go to menu manager hit import link, then in it you can add in the class= part {$node->alias} which will give each page it's own class to use for styling...
In most all of them there is a class for the active page, some are menuparentactive, look at the page source to see what's what...
I would use the Formbuilder module to handle all forms as it is a module of CMSMS and has many wonderful features, and no need to try and pull some other page into CMSMS...
In most all of them there is a class for the active page, some are menuparentactive, look at the page source to see what's what...
I would use the Formbuilder module to handle all forms as it is a module of CMSMS and has many wonderful features, and no need to try and pull some other page into CMSMS...
Re: Links!
Milehigh, thank you very much.
Dr. CSS, thank you as well. You guys helped me figure this stuff out. Although, I have to admit, I tried every which way but just couldn't get the li/a stying in the menu.
This thread was very helpful for that, though: http://forum.cmsmadesimple.org/viewtopi ... 20&t=56259
Dr. CSS, thank you as well. You guys helped me figure this stuff out. Although, I have to admit, I tried every which way but just couldn't get the li/a stying in the menu.
This thread was very helpful for that, though: http://forum.cmsmadesimple.org/viewtopi ... 20&t=56259