Category Menu Items

This is another general WordPress question that I see quite often: how can I create a menu item that displays a page of posts belonging to a particular category? For example, let’s say I have a site about animals, and I’ve created a category called Dogs and a category called Cats, and by clicking on a menu item labeled Dogs, I want to display a list of posts that have the Dogs category assigned to it.

Continue reading

Image Magnifying Glass

Wanted to try out the example code from here.

When you move the mouse over this image, the cursor will turn into a magnifying glass and enlarge the section of the image underneath:

 

Setting the Mouse Cursor

There are a number of standard cursors that are used depending upon where on the web page the mouse is located. The default cursor is the arrow, but if held over a hyperlink, the cursor usually turns into a pointing hand.

The cursor property allows you to use CSS to change the cursor image when the mouse is moved over a particular element. For example, if you hover your mouse over the block below, you’ll see that the cursor changes into a pizza slice:

Move the mouse over this box.

The CSS to change the cursor to an image looks like this:

.pizza {
   cursor: url(/wp-content/uploads/2020/03/42559-e1565325592349.png),auto;
}

The DIV with the red borders was assigned a class of pizza, so the rule comes into play when the mouse moves over it. You want to make sure that the image you’re using has dimensions of 32×32 to insure compatibility across all browsers.

If you want to make the image the default cursor for the page instead of just a certain element, then try using the body element as a selector:

body {
   cursor: url(/wp-content/uploads/2020/03/42559-e1565325592349.png),auto;
}

As an example, pick Whole Page from the options below to see how the cursor will change to a pizza slice for the whole page:


If you do change the default cursor for the entire page, then you may want to use an altered image for hyperlinks so your users know if they are positioned over one.

Vertical Marquee using jQuery

This is from the page How to Have the Marquee Effect without Using the Marquee Tag (with CSS, JavaScript and jQuery).

Message 1

Message 2

Message 3

Message 4

Message 5