我试图在我的应用程序中加载jquery砖石脚本,但它不起作用。
调试时,我看到以下错误:
Failed to load resource: the server responded with a http://localhost:3000/app/assets/javascripts/jquery.masonry.min.js status of 404 (Not Found)
如果我试图通过链接直接从浏览器访问脚本,就会得到以下错误:
No route matches [GET] "/Users/fkhalid2008/loand/app/assets/javascripts/jqu
我试图将砖石应用于这批代码:
<?php
//If There Are No Posts In The DB
if(condition) : ?>
<p> There Are Currently No Posts On This Site.</p>
<?php
//If There Are Posts In The DB - Loop Through All The Posts
else : ?>
<div id="masonry-grid">
我正在使用以砖石格式排列博客帖子。这对于最初显示在页面上的帖子很有效,但当我通过AJAX加载新帖子时-当分页链接被点击时-帖子只是被添加到容器中,而不是‘重新打包’或以砖石格式重新排列。
我正在使用WordPress并使用我自己的AJAX调用,请参见以下代码:
// For jQuery noConflict
(function($) {
$(document).ready(function() {
// Find out the page number
var pageNumber;
$('.custom-pagina