次のWordpressのプラグインを書いている間は、プラグインのための私のPHPコードです:エラーなしなし実行
<html>
<head>
<title>Grid Demo</title>
<link rel="stylesheet" href="css/style.css" />
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/jquery-ui.min.js"></script>
<script src="js/fixtures.js"></script>
<script src="js/gridList.js"></script>
<script src="js/jquery.gridList.js"></script>
<script src="js/load.js"></script>
</head>
<?php
/*
Plugin Name: Testingplugin
Plugin URI: http://localhost
Description: Trying plugin for the first time.
Version: 1.0
Author: AIMS
Author URI: http://localhost
License: A "Slug" license name e.g. GPL2
*/
// Exampe is from the https://www.youtube.com/watch?v=GAwPa4fP90c
add_action('admin_menu', 'myfirstpluginactions');
function myfirstpluginactions(){
add_options_page('Title_of_the_plugin','name_of_submenu','manage_options', __FILE__,'display_menu_page');
}
function display_menu_page(){
?>
<body>
<div class="header">
<a href="#remove-row" class="button remove-row">-</a>
<a href="#add-row" class="button add-row">+</a>
<p>
<a class="github-button" href="https://github.com/hootsuite/grid" data-style="mega" data-count-href="/hootsuite/grid/stargazers" data-count-api="/repos/hootsuite/grid#stargazers_count" data-count-aria-label="# stargazers on GitHub" aria-label="Star hootsuite/grid on GitHub">GitHub</a>
</p>
</div>
<div class="grid-container">
<ul id="grid" class="grid">
<li class="position-highlight">
<div class="inner"></div>
</li>
</ul>
</div>
<script async defer id="github-bjs" src="https://buttons.github.io/buttons.js"></script>
<?php
}
私はプラグインを使用してドラッグ可能要素を表示するためのHootsuite Gridリポジトリを使用しています。 問題は出力を取得できず、エラーも発生していないことです。私の推測は、jsの包含に関する問題です。
私はすべてのjsを私のプラグインのjsフォルダに入れました。何が原因か、コードを改善するために何ができるかを教えてください。ここで
は、私は、画面に乗る出力されます。
そして、これは私が期待していたものです。
すべてのjsファイルが確実に含まれていますか? – ProEvilz
@ ProEvilz私はそれについて少し混乱しています。私は何かエラーを見ることができませんでした。つまり、すべてがうまくいくかもしれません。 –