简体   繁体   English

Wordpress-下一个和上一个链接不再起作用

[英]Wordpress - Next and Previous Links No Longer Working

On my page I am using the next and previous post link functions and they were working fine but I have just noticed that they are broken and not clickable anymore. 在我的页面上,我正在使用下一个和上一个帖子链接功能,它们工作正常,但我刚刚注意到它们已损坏且不再可单击。

previous_post_link('%link','<img id="prev" src="images/prev.png" alt="previous" />', FALSE, '');

next_post_link('%link','<img id="next" src="images/next.png" alt="next" />', FALSE, '');

The source on the page seems fine and unchanged, just that the images themselves are no longer clickable: 页面上的源看起来很好并且没有变化,只是图像本身不再可单击:

<a href="?p=117" rel="prev"><img id="prev" src="images/prev.png" alt="previous"></a>
<a href="?p=121" rel="next"><img id="next" src="images/next.png" alt="next"></a>

Does anyone have any ideas? 有人有什么想法吗?

The only odd thing is that I am using relative positioning on the images to move them to where I want them to be so when I inspect the element, the a tag appears miles away from where the actual images are but I am sure this was the case before aswell. 唯一奇怪的是,我使用的图像相对定位将其移动到哪里我想他们是这样,当我检查元素的a标记出现与实际图像地方有几英里远,但我相信这是事前也是如此。

Your HTML code is fine, so the problem should be your CSS. 您的HTML代码很好,所以问题应该出在CSS上。 Try removing the relative positioning to see if they become clickable, can't help you more with just this much code. 尝试删除相对位置,看看它们是否可点击,仅用这么多的代码就无法为您提供更多帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM