我希望这是一个有趣的问题..我想找到一个包含所有给定文件的目录..到目前为止我所做的如下
在unix中查找多个文件...
find . -type f \( -name "*cache" -o -name "*xml" -o -name "*html" \)
Run Code Online (Sandbox Code Playgroud)
参考:http : //alvinalexander.com/linux-unix/linux-find-multiple-filenames-patterns-command-example
仅查找包含给定文件的目录...
find . -type f -name '*.pdf' |sed 's#\(.*\)/.*#\1#' |sort -u
Run Code Online (Sandbox Code Playgroud)
参考:http : //www.unix.com/unix-for-dummies-questions-and-answers/107488-find-files-display-only-directory-list- contains-those-files.html
我怎样才能创建一个命令,它会给我一个包含所有给定文件的目录......(文件必须在给定的目录中,而不是在子目录中......并且列表中给出的所有文件必须存在)
想搜索 WordPress 主题目录
我希望你们都看过wordpress管理面板.我们在菜单末尾有选项可以折叠或展开菜单.
如果单击折叠,菜单将折叠并保存设置(我不知道在哪里),但如果再次登录,您将看到相同的折叠菜单..
他们在哪里存储这些数据??? 我想让管理员菜单默认显示为折叠,我该怎么做?
编辑:我认为文件wp-admin/js/common.js负责...你可以在这里查看文件http://phpcrossref.com/xref/wordpress/wp-admin/js/common.js.txt
我想我得到的代码对此负责,但我是js的新手.代码如下:
$('#collapse-menu').on('click.collapse-menu', function() {
var body = $( document.body ), respWidth, state;
// reset any compensation for submenus near the bottom of the screen
$('#adminmenu div.wp-submenu').css('margin-top', '');
if ( window.innerWidth ) {
// window.innerWidth is affected by zooming on phones
respWidth = Math.max( window.innerWidth, document.documentElement.clientWidth );
} else {
// IE < 9 doesn't support @media CSS rules
respWidth = 961;
}
if ( respWidth && respWidth < 960 ) {
if ( body.hasClass('auto-fold') …Run Code Online (Sandbox Code Playgroud)