“NOTICE AUTH” notifications when connecting to IRC server
문제
As a learning exercise, I'm writing a Python program to connect to a channel on an IRC network, so I can output messages in the channel to stdout. I'm using asynchat and manually sending the protocol messages, rather than using something like Twisted or existing bot code from the net - again, it's a more useful learning experience that way.
I can send JOIN and USER commands quite happily, and can PING/PONG away as required. However, I've noticed when opening a socket to port 6667, I'll receive some messages:
NOTICE AUTH :*** Looking up your hostname...
NOTICE AUTH :*** Checking ident
NOTICE AUTH :*** Found your hostname
NOTICE AUTH :*** No identd (auth) response
even if I've not yet sent the JOIN/USER commands.
So, is this opening sequence of notifications specified anywhere? As far as I can see, the RFC doesn't specify for anything in particular to happen before the client sends the JOIN command, and I wasn't sure whether to wait for receipt of these notices before sending the JOIN command, and if so how do I detect that I've received all of the notices?
해결책
아래의 설명 된 바와 같이 클라이언트 측에서 소개 콘텐츠 을 생성함으로써 얻을 수 있습니다.
단계
1) 조사 편집 편집 페이지 에 CEWP 추가
2) 다음 내용을 CEWP 에 삽입하십시오.
.
<h2 id="questionSummary">Please specify your development skills</h2>
<script type="text/javascript">
function getParameterByName(name) {
name = name.replace(/[\[]/, "\\[").replace(/[\]]/, "\\]");
var regex = new RegExp("[\\?&]" + name + "=([^&#]*)"),
results = regex.exec(location.search);
return results == null ? "" : decodeURIComponent(results[1].replace(/\+/g, " "));
}
(function(){
var questionSummary = $("#questionSummary");
var fieldName = getParameterByName('FirstField');
switch(fieldName){
case "Skills":
questionSummary.append("Please specify your development skills");
break;
}
})();
</script>
키 포인트 :
-
조사 양식의 페이지 탐색 중에 쿼리 문자열 매개 변수
FirstField
가 추가됩니다 -
함수
getParameterByName
가 쿼리 문자열을 검색하는 데 사용됩니다. 매개 변수, 우리의 경우FirstField
결과
참고 : 지정된 예제는 SharePoint 2013이지만 동일한 예제입니다. SharePoint 2007 에 접근 방식이 적용될 수 있습니다.