小编Tho*_*res的帖子

如何在ajax调用中使用wordpress函数

我想知道是否有办法在ajax调用中使用query_post()这样的函数?

假设我正在调用文件_inc/ajax.php

我想能够使用wordpress功能,但我不知道为什么.有人可以帮助我吗?

非常感谢 :)

ajax wordpress jquery function

11
推荐指数
1
解决办法
3万
查看次数

无法打开用户的ssh/authorized_keys

我知道这对你们中的一些人来说可能是微不足道的.

我不是linux专家,我正在尝试使用git.为此,我想尝试将我的公共SSH密钥添加到~/.ssh/authorized_keys我的用户git中.

但问题是,当我使用git用户使用putty登录到我的服务器时,我无法访问任何调用的文件~/.ssh/authorized_keys.

所以我试着用root做到这一点,也许这就是解决方案,但我认为authorized_keys每个用户都有一个.

我可以看到授权的密钥,但我不想把所有东西弄得一团糟,所以我想清楚这一点.有没有办法使用我的git用户帐户并修改ssh/authorized_keys

非常感谢!

git ssh authorized-keys

8
推荐指数
1
解决办法
1万
查看次数

Zsh 无法正确自动完成我的 ssh 命令

我对 ssh 自动完成有一些问题。我希望我的 zsh 在我的 .ssh/config 文件上自动完成,但直到现在它只对 /etc/hosts 文件执行此操作。我发现如何通过添加此配置不使用主机文件

zstyle ':completion:*:ssh:*' hosts off
Run Code Online (Sandbox Code Playgroud)

但是我无法成功让 zsh 查看 .ssh/config 文件

zstyle ':completion:*:ssh:*' config on
Run Code Online (Sandbox Code Playgroud)

这是我的 .zshrc 文件

    # If you come from bash you might have to change your $PATH.
    #export PATH=$HOME/bin:/usr/local/bin:/usr/local/sbin:~/Documents/workspace/flutter/bin:$PATH

    # Path to your oh-my-zsh installation.
    export ZSH=/Users/thoma/.oh-my-zsh

    # Set name of the theme to load. Optionally, if you set this to "random"
    # it'll load a random theme each time that oh-my-zsh is loaded.
    # See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes
    ZSH_THEME="agnoster"

    # …
Run Code Online (Sandbox Code Playgroud)

ssh zsh autocomplete

7
推荐指数
2
解决办法
7677
查看次数

检测水平鼠标滚轮

我想对三种情况进行区分:

e.preventDefault();
if(Mousewheel.direction = Left)
    base.goForward();
else if(Mousewheel.direction = Right)
    base.goBack();
else{   
    //Doing normal slide                            
Run Code Online (Sandbox Code Playgroud)

但我找不到任何指示鼠标滚轮是水平还是垂直的东西,插件鼠标滚轮的唯一返回,即delta和event.

如果有人知道如何在水平和垂直方向上进行区分,感谢您分享您的提示.

jquery

5
推荐指数
1
解决办法
3332
查看次数

Sharepoint Timer作业调试无法设置断点

我有一点问题.我正在尝试按照本教程添加计时器作业:http://dotnetfinder.wordpress.com/2010/07/24/creatingcustomsharepointtimerjob2010/

我到了启用计时器作业并且每五分钟启动一次的程度.问题是它没有执行所有的Execute方法.

    public override void Execute(Guid contentDbId)
    {

        // get a reference to the current site collection's content database

        SPWebApplication webApplication = this.Parent as SPWebApplication;

        SPContentDatabase contentDb = webApplication.ContentDatabases[contentDbId];

        // get a reference to the "ListTimerJob" list in the RootWeb of the first site collection in the content database

        SPList Listjob = contentDb.Sites[0].RootWeb.Lists["Liens"];

        // create a new list Item, set the Title to the current day/time, and update the item

        SPListItem newList = Listjob.Items.Add();

        //newList["URL"] = "http://"+DateTime.Now.ToString()+".fr"; …
Run Code Online (Sandbox Code Playgroud)

breakpoints timer-jobs sharepoint-2010

0
推荐指数
1
解决办法
4562
查看次数