Re: Help with CSS Rollover Links

2009-06-16 Thread Andreas Derksen

Lol, please quote the parts where i was ugly to him. I just gave him an 
advice AND helped him with his problem! I was constructive, not like you.
Please don't bother me..thx

greets
Andreas

red mcgee schrieb:
> Re: Andreas:
>
> that's a foul way to respond to someone.
> please don't browse the forums looking for others to belittle.
> the users here are merely looking for support - not criticism.
> how ugly of you...
>
>
> On Jun 12, 12:21 pm, Andreas  wrote:
>   
>> Hi,
>> well i think you first need to learn the basics. e.g.: html + css before
>> proceeding to php (cake not to mention).
>> besides, its called "hover", not "rollover".
>> But anyway, to help you with that problem (maybe i missunderstood it
>> ...), this is how you make a button wich changes the image when the
>> mouse is over it:
>>
>> Viewcode:
>> link('Home', "blog/index/", array('id' => 'homebtn')); ?>
>> link('Best Postings', "blog/bestof/", array('id' =>
>> 'best')); ?>
>>
>> CSS:
>> a#homebtn { background: transparent url(path/to/button/img.png) 0 0
>> no-repeat); float: left; }
>> a#homebtn:hover { background: transparent url(path/to/hover/img.png) 0 0
>> no-repeat; float: left; }
>>
>> hope that helps.
>>
>> greets
>> Andreas
>>
>> DbZeroOne schrieb:
>>
>> 
>>> Ok, good advice from both of you. This is what my code looks like now:
>>>   
>>> >> echo $html->link('',array('controller'=>'blog','action' =>
>>> 'index'),array('ID' => 'homebtn','alt' => 'Home'));
>>> echo $html->link('',array('controller'=>'blog','action' =>
>>> 'bestof'),array('ID' => 'best',  ,'alt' => 'Best Postings'));
>>> ?>
>>>   
>>> This should be one button to the right of the other.There will be 5
>>> total in a horizontal menu.
>>>   
>>> The problem now is that only one button will work at a time (link and
>>> rollover). Either one will work when they're alone, but together, only
>>> the first one will work (whichever one is first). I've tried
>>> everything I can think of, but either nothing changes or the whole
>>> page blanks out.
>>>   
>>> Thank you for your input.
>>>   
>
> >
>   

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Help with CSS Rollover Links

2009-06-15 Thread red mcgee

Re: Andreas:

that's a foul way to respond to someone.
please don't browse the forums looking for others to belittle.
the users here are merely looking for support - not criticism.
how ugly of you...


On Jun 12, 12:21 pm, Andreas  wrote:
> Hi,
> well i think you first need to learn the basics. e.g.: html + css before
> proceeding to php (cake not to mention).
> besides, its called "hover", not "rollover".
> But anyway, to help you with that problem (maybe i missunderstood it
> ...), this is how you make a button wich changes the image when the
> mouse is over it:
>
> Viewcode:
> link('Home', "blog/index/", array('id' => 'homebtn')); ?>
> link('Best Postings', "blog/bestof/", array('id' =>
> 'best')); ?>
>
> CSS:
> a#homebtn { background: transparent url(path/to/button/img.png) 0 0
> no-repeat); float: left; }
> a#homebtn:hover { background: transparent url(path/to/hover/img.png) 0 0
> no-repeat; float: left; }
>
> hope that helps.
>
> greets
> Andreas
>
> DbZeroOne schrieb:
>
> > Ok, good advice from both of you. This is what my code looks like now:
>
> >  > echo $html->link('',array('controller'=>'blog','action' =>
> > 'index'),array('ID' => 'homebtn','alt' => 'Home'));
> > echo $html->link('',array('controller'=>'blog','action' =>
> > 'bestof'),array('ID' => 'best',  ,'alt' => 'Best Postings'));
> > ?>
>
> > This should be one button to the right of the other.There will be 5
> > total in a horizontal menu.
>
> > The problem now is that only one button will work at a time (link and
> > rollover). Either one will work when they're alone, but together, only
> > the first one will work (whichever one is first). I've tried
> > everything I can think of, but either nothing changes or the whole
> > page blanks out.
>
> > Thank you for your input.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Help with CSS Rollover Links

2009-06-12 Thread Andreas

Hi,
well i think you first need to learn the basics. e.g.: html + css before 
proceeding to php (cake not to mention). 
besides, its called "hover", not "rollover".
But anyway, to help you with that problem (maybe i missunderstood it 
...), this is how you make a button wich changes the image when the 
mouse is over it:

Viewcode:
link('Home', "blog/index/", array('id' => 'homebtn')); ?>
link('Best Postings', "blog/bestof/", array('id' => 
'best')); ?>

CSS:
a#homebtn { background: transparent url(path/to/button/img.png) 0 0 
no-repeat); float: left; }
a#homebtn:hover { background: transparent url(path/to/hover/img.png) 0 0 
no-repeat; float: left; }

hope that helps.

greets
Andreas

DbZeroOne schrieb:
> Ok, good advice from both of you. This is what my code looks like now:
>
>  echo $html->link('',array('controller'=>'blog','action' =>
> 'index'),array('ID' => 'homebtn','alt' => 'Home'));
> echo $html->link('',array('controller'=>'blog','action' =>
> 'bestof'),array('ID' => 'best',  ,'alt' => 'Best Postings'));
> ?>
>
> This should be one button to the right of the other.There will be 5
> total in a horizontal menu.
>
> The problem now is that only one button will work at a time (link and
> rollover). Either one will work when they're alone, but together, only
> the first one will work (whichever one is first). I've tried
> everything I can think of, but either nothing changes or the whole
> page blanks out.
>
> Thank you for your input.
>
>
> >
>   

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Help with CSS Rollover Links

2009-06-12 Thread brian

On Fri, Jun 12, 2009 at 12:16 PM, DbZeroOne wrote:
>
> Ok, good advice from both of you. This is what my code looks like now:
>
>  echo $html->link('',array('controller'=>'blog','action' =>
> 'index'),array('ID' => 'homebtn','alt' => 'Home'));
> echo $html->link('',array('controller'=>'blog','action' =>
> 'bestof'),array('ID' => 'best',  ,'alt' => 'Best Postings'));
> ?>

You have an extra comma after "'ID' => 'best'".

> This should be one button to the right of the other.There will be 5
> total in a horizontal menu.
>
> The problem now is that only one button will work at a time (link and
> rollover). Either one will work when they're alone, but together, only
> the first one will work (whichever one is first). I've tried
> everything I can think of, but either nothing changes or the whole
> page blanks out.

Could be a javascript or CSS issue.

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Help with CSS Rollover Links

2009-06-12 Thread DbZeroOne

Ok, good advice from both of you. This is what my code looks like now:

link('',array('controller'=>'blog','action' =>
'index'),array('ID' => 'homebtn','alt' => 'Home'));
echo $html->link('',array('controller'=>'blog','action' =>
'bestof'),array('ID' => 'best',  ,'alt' => 'Best Postings'));
?>

This should be one button to the right of the other.There will be 5
total in a horizontal menu.

The problem now is that only one button will work at a time (link and
rollover). Either one will work when they're alone, but together, only
the first one will work (whichever one is first). I've tried
everything I can think of, but either nothing changes or the whole
page blanks out.

Thank you for your input.


--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Help with CSS Rollover Links

2009-06-11 Thread thatsgreat2345

Probably has an image, set as a background or something with on
rollover changes background image or whatever. To OP, this is not the
best option as if your viewer has images disabled, or they are using
screen readers and you have no alt text, and no text for the link,
they are kind of SOL. So you should probably change it so your site is
more accessible.

On Jun 11, 10:22 am, brian  wrote:
> echo $html->link(
>         '',
>         array(
>                 'controller'=>'blog',
>                 'action' => 'index'
>         ),
>         array(
>                 'class' => 'homebtn'
>         )
> );
>
> But it looks to me like you should have an id="homebtn" (presumably,
> there's only one on the page) with a class for the more general style
> rules.
>
> And why don't you have any text in the link?That's not very accessible.
>
> On Thu, Jun 11, 2009 at 12:58 PM, DbZeroOne wrote:
>
> > First, I'm just starting to learn Cake, so my question may seem a
> > little idiotic...
>
> > I'm trying to add some rollover buttons to a page in a CakePHP
> > application that I inherited from a previous developer.
>
> > I prefer to do CSS rollovers vs. Javascript. So far the layout is
> > working very well, but I'm having a tough time figuring out how to
> > make a graphical button with a link using the CSS rollover method (1
> > background image that changes position on hover). If this were HTML,
> > my code would look like this:
>
> > 
>
> > That CSS class 'homebtn' would handle the image, size, float, hover,
> > etc. and the HREF part tells it where to link to. Easy enough.
>
> > In Cake, my code looks like this...
>
> >  > echo $html->link($html->style("homebtn"), array('controller'=>'blog',
> > 'action' => 'index'));
> > ?>
>
> > My best guess is that the code above is saying: "make an HTML link of
> > the CSS class 'homebtn' and process clicks through the controller
> > named 'blog'.
>
> > The problem is that the image/rollover part doesn't work and I can't
> > find any info on how to make it work. The CSS class doesn't seem to be
> > getting pulled in. All that shows is a text link that says 'homebtn',
> > which does link correctly, by the way.
>
> > I'm using CakePHP 1.2 and the class 'homebtn' is in my style.css
> > stylesheet which is properly linked into the head of default.ctp.
>
> > Suggestions?
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---



Re: Help with CSS Rollover Links

2009-06-11 Thread brian

echo $html->link(
'',
array(
'controller'=>'blog',
'action' => 'index'
),
array(
'class' => 'homebtn'
)
);

But it looks to me like you should have an id="homebtn" (presumably,
there's only one on the page) with a class for the more general style
rules.

And why don't you have any text in the link?That's not very accessible.

On Thu, Jun 11, 2009 at 12:58 PM, DbZeroOne wrote:
>
> First, I'm just starting to learn Cake, so my question may seem a
> little idiotic...
>
>
>
> I'm trying to add some rollover buttons to a page in a CakePHP
> application that I inherited from a previous developer.
>
> I prefer to do CSS rollovers vs. Javascript. So far the layout is
> working very well, but I'm having a tough time figuring out how to
> make a graphical button with a link using the CSS rollover method (1
> background image that changes position on hover). If this were HTML,
> my code would look like this:
>
> 
>
> That CSS class 'homebtn' would handle the image, size, float, hover,
> etc. and the HREF part tells it where to link to. Easy enough.
>
> In Cake, my code looks like this...
>
>  echo $html->link($html->style("homebtn"), array('controller'=>'blog',
> 'action' => 'index'));
> ?>
>
> My best guess is that the code above is saying: "make an HTML link of
> the CSS class 'homebtn' and process clicks through the controller
> named 'blog'.
>
> The problem is that the image/rollover part doesn't work and I can't
> find any info on how to make it work. The CSS class doesn't seem to be
> getting pulled in. All that shows is a text link that says 'homebtn',
> which does link correctly, by the way.
>
> I'm using CakePHP 1.2 and the class 'homebtn' is in my style.css
> stylesheet which is properly linked into the head of default.ctp.
>
> Suggestions?
>
> >
>

--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~--~~~~--~~--~--~---