diff --git a/LICENSE.txt b/LICENSE.txt new file mode 100644 index 000000000..9aba762af --- /dev/null +++ b/LICENSE.txt @@ -0,0 +1,208 @@ +소프트웨어 제품은 저작권법 및 국제저작권 협약을 비롯하여, 기타 지적재산권법 및 협약의 보호를 받습니다. + +프로그램 명칭 : 그누보드4S (GNUBoard 4 Second Edition) + +저작자 : (주)에스아이알소프트 http://sir.co.kr + +라이센스 (License) + +번역문 아래에 원문이 있습니다. + +주의 ) +1. 번역문과 원문의 내용상 차이가 있는 경우 원문의 내용을 우선으로 따릅니다. +2. 법적인 분쟁이 발생한 경우 저작자의 회사 소재지를 관할하는 관할법원에서 분쟁을 해결합니다. +3. 이 라이센스 파일 및 내용은 저작자를 제외한 어느 누구도 추가, 수정, 삭제할 수 없습니다. + +----- GPL 번역문 -------------------------------------------------------- + +GNU 일반 공중 사용 허가서 +2판, 1991년 6월 + +Copyright (C) 1989, 1991 Free Software Foundation, Inc. +59 Temple Place - Suite 330, Boston, MA 02111-1307, USA +누구든지 본 사용 허가서를 있는 그대로 복제하고 배포할 수 +있습니다. 그러나 본문에 대한 수정은 허용되지 않습니다. + + + + +전 문 +소프트웨어에 적용되는 대부분의 사용 허가서(license)들은 소프트웨어에 대한 수정과 공유의 자유를 제한하려는 것을 그 목적으로 합니다. 그러나 GNU 일반 공중 사용 허가서(이하, ``GPL''이라고 칭합니다.)는 자유 소프트웨어에 대한 수정과 공유의 자유를 모든 사용자들에게 보장하기 위해서 성립된 것입니다. 자유 소프트웨어 재단이 제공하는 대부분의 소프트웨어들은 GPL에 의해서 관리되고 있으며, 몇몇 소프트웨어에는 별도의 사용 허가서인 GNU 라이브러리 일반 공중 사용 허가서(GNU Library General Public License)를 대신 적용하기도 합니다. 자유 소프트웨어란, 이를 사용하려고 하는 모든 사람에 대해서 동일한 자유와 권리가 함께 양도되는 소프트웨어를 말하며 프로그램 저작자의 의지에 따라 어떠한 종류의 프로그램에도 GPL을 적용할 수 있습니다. 따라서 여러분이 만든 프로그램에도 GPL을 적용할 수 있습니다. + +자유 소프트웨어를 언급할 때 사용되는 ``자유''라는 단어는 무료(無料)를 의미하는 금전적인 측면의 자유가 아니라 구속되지 않는다는 관점에서의 자유를 의미하며, GPL은 자유 소프트웨어를 이용한 복제와 개작, 배포와 수익 사업 등의 가능한 모든 형태의 자유를 실질적으로 보장하고 있습니다. 여기에는 원시 코드(source code)의 전부 또는 일부를 원용해서 개선된 프로그램을 만들거나 새로운 프로그램을 창작할 수 있는 자유가 포함되며, 자신에게 양도된 이러한 자유와 권리를 보다 명확하게 인식할 수 있도록 하기 위한 규정도 포함되어 있습니다. + +GPL은 GPL 안에 소프트웨어를 양도받을 사용자의 권리를 제한하는 조항과 단서를 별항으로 추가시키지 못하게 함으로써 사용자들의 자유와 권리를 실제적으로 보장하고 있습니다. 자유 소프트웨어의 개작과 배포에 관계하고 있는 사람들은 이러한 무조건적인 권리 양도 규정을 준수해야만 합니다. + +예를 들어 GPL 프로그램을 배포할 경우에는 프로그램의 유료 판매나 무료 배포에 관계없이 자신이 해당 프로그램에 대해서 가질 수 있었던 모든 권리를, 프로그램을 받게될 사람에게 그대로 양도해 주어야 합니다. 이 경우, 프로그램의 원시 코드를 함께 제공하거나 원시 코드를 구할 수 있는 방법을 확실히 알려주어야 하고 이러한 모든 사항들을 사용자들이 분명히 알 수 있도록 명시해야 합니다. + +자유 소프트웨어 재단은 다음과 같은 두 가지 단계를 통해서 사용자들을 권리를 보호합니다. (1) 소프트웨어에 저작권을 설정합니다. (2) 저작권의 양도에 관한 실정법에 의해서 유효한 법률적 효력을 갖는 GPL을 통해 소프트웨어를 복제하거나 개작 및 배포할 수 있는 권리를 사용자들에게 부여합니다. + +자유 소프트웨어를 사용하는 사람들은 반복적인 재배포 과정을 통해 소프트웨어 자체에 수정과 변형이 일어날 수도 있으며, 이는 최초의 저작자가 만든 소프트웨어가 갖고 있는 문제가 아닐 수 있다는 개연성을 인식하고 있어야 합니다. 우리는 개작과 재배포 과정에서 다른 사람에 의해 발생된 문제로 인해 프로그램 원저작자들의 신망이 훼손되는 것을 원하지 않습니다. GPL에 자유 소프트웨어에 대한 어떠한 형태의 보증도 규정하지 않는 이유는 이러한 점들이 고려되었기 때문이며, 이는 프로그램 원저작자와 자유 소프트웨어 재단의 자유로운 활동을 보장하는 현실적인 수단이기도 합니다. + +특허 제도는 자유 소프트웨어의 발전을 위협하는 요소일 수밖에 없습니다. 자유 프로그램을 재배포하는 사람들이 개별적으로 특허를 취득하게 되면, 결과적으로 그 프로그램이 독점 소프트웨어가 될 가능성이 있습니다. 자유 소프트웨어 재단은 이러한 문제에 대처하기 위해서 어떠한 특허에 대해서도 그 사용 권리를 모든 사람들(이하, ``공중(公衆)''이라고 칭합니다.)에게 자유롭게 허용하는 경우에 한해서만 자유 소프트웨어와 함께 사용할 수 있다는 것을 명확히 밝히고 있습니다. + +복제(copying)와 개작(modification) 및 배포(distribution)에 관련된 구체적인 조건과 규정은 다음과 같습니다. + + +복제와 개작 및 배포에 관한 조건과 규정 + +제 0 조. 본 허가서는 GNU 일반 공중 사용 허가서의 규정에 따라 배포될 수 있다는 사항이 저작권자에 의해서 명시된 모든 컴퓨터 프로그램 저작물에 대해서 동일하게 적용됩니다. 컴퓨터 프로그램 저작물(이하, ``프로그램''이라고 칭합니다.)이란 특정한 결과를 얻기 위해서 컴퓨터 등의 정보 처리 능력을 가진 장치(이하, ``컴퓨터''라고 칭합니다.) 내에서 직접 또는 간접으로 사용되는 일련의 지시 및 명령으로 표현된 창작물을 의미하고, ``2차적 프로그램''이란 전술한 프로그램 자신 또는 저작권법의 규정에 따라 프로그램의 전부 또는 상당 부분을 원용하거나 다른 언어로의 번역을 포함할 수 있는 개작 과정을 통해서 창작된 새로운 프로그램과 이와 관련된 저작물을 의미합니다. (이후로 다른 언어로의 번역은 별다른 제한없이 개작의 범위에 포함되는 것으로 간주합니다.) ``피양도자''란 GPL의 규정에 따라 프로그램을 양도받은 사람을 의미하고, ``원(原)프로그램''이란 프로그램을 개작하거나 2차적 프로그램을 만들기 위해서 사용된 최초의 프로그램을 의미합니다. + +본 허가서는 프로그램에 대한 복제와 개작 그리고 배포 행위에 대해서만 적용됩니다. 따라서 프로그램을 실행시키는 행위에 대한 제한은 없습니다. 프로그램의 결과물(output)에는, 그것이 프로그램을 실행시켜서 생성된 것인지 아닌지의 여부에 상관없이 결과물의 내용이 원프로그램으로부터 파생된 2차적 프로그램을 구성했을 때에 한해서 본 허가서의 규정들이 적용됩니다. 2차적 프로그램의 구성 여부는 2차적 프로그램 안에서의 원프로그램의 역할을 토대로 판단합니다. + +제 1 조. 적절한 저작권 표시와 프로그램에 대한 보증이 제공되지 않는다는 사실을 각각의 복제물에 명시하는 한, 피양도자는 프로그램의 원시 코드를 자신이 양도받은 상태 그대로 어떠한 매체를 통해서도 복제하고 배포할 수 있습니다. 복제와 배포가 이루어 질 때는 본 허가서와 프로그램에 대한 보증이 제공되지 않는다는 사실에 대해서 언급되었던 모든 내용을 그대로 유지시켜야 하며, 영문판 GPL을 함께 제공해야 합니다. + +배포자는 복제물을 물리적으로 인도하는데 소요된 비용을 청구할 수 있으며, 선택 사항으로 독자적인 유료 보증을 설정할 수 있습니다. + +제 2 조. 피양도자는 자신이 양도받은 프로그램의 전부나 일부를 개작할 수 있으며, 이를 통해서 2차적 프로그램을 창작할 수 있습니다. 개작된 프로그램이나 창작된 2차적 프로그램은 다음의 사항들을 모두 만족시키는 조건에 한해서, 제1조의 규정에 따라 또다시 복제되고 배포될 수 있습니다. + +제 1 항. 파일을 개작할 때는 파일을 개작한 사실과 그 날짜를 파일 안에 명시해야 합니다. + +제 2 항. 배포하거나 공표하려는 저작물의 전부 또는 일부가 양도받은 프로그램으로부터 파생된 것이라면, 저작물 전체에 대한 사용 권리를 본 허가서의 규정에 따라 공중에게 무상으로 허용해야 합니다. + +제 3 항. 개작된 프로그램의 일반적인 실행 형태가 대화형 구조로 명령어를 읽어 들이는 방식을 취하고 있을 경우에는, 적절한 저작권 표시와 프로그램에 대한 보증이 제공되지 않는다는 사실, (별도의 보증을 설정한 경우라면 해당 내용) 그리고 양도받은 프로그램을 본 규정에 따라 재배포할 수 있다는 사실과 GPL 사본을 참고할 수 있는 방법이 함께 포함된 문구가 프로그램이 대화형 구조로 평이하게 실행된 직후에 화면 또는 지면으로 출력되도록 작성되어야 합니다. (예외 규정: 양도받은 프로그램이 대화형 구조를 갖추고 있다 하더라도 통상적인 실행 환경에서 전술한 사항들이 출력되지 않는 형태였을 경우에는 이를 개작한 프로그램 또한 관련 사항들을 출력시키지 않아도 무방합니다.) + +위의 조항들은 개작된 프로그램 전체에 적용됩니다. 만약, 개작된 프로그램에 포함된 특정 부분이 원프로그램으로부터 파생된 것이 아닌 별도의 독립 저작물로 인정될 만한 상당한 이유가 있을 경우에는 해당 저작물의 개별적인 배포에는 본 허가서의 규정들이 적용되지 않습니다. 그러나 이러한 저작물이 2차적 프로그램의 일부로서 함께 배포된다면 개별적인 저작권과 배포 기준에 상관없이 저작물 모두에 본 허가서가 적용되어야 하며, 전체 저작물에 대한 사용 권리는 공중에게 무상으로 양도됩니다. + +이러한 규정은 개별적인 저작물에 대한 저작자의 권리를 침해하거나 인정하지 않으려는 것이 아니라, 원프로그램으로부터 파생된 2차적 프로그램이나 수집 저작물의 배포를 일관적으로 규제할 수 있는 권리를 행사하기 위한 것입니다. + +원프로그램이나 원프로그램으로부터 파생된 2차적 프로그램을 이들로부터 파생되지 않은 다른 저작물과 함께 단순히 저장하거나 배포할 목적으로 동일한 매체에 모아 놓은 집합물의 경우에는, 원프로그램으로부터 파생되지 않은 다른 저작물에는 본 허가서의 규정들이 적용되지 않습니다. + +제 3 조. 피양도자는 다음 중 하나의 항목을 만족시키는 조건에 한해서 제1조와 제2조의 규정에 따라 프로그램(또는 제2조에서 언급된 2차적 프로그램)을 목적 코드(object code)나 실행물(executable form)의 형태로 복제하고 배포할 수 있습니다. + +제 1 항. 목적 코드나 실행물에 상응하는 컴퓨터가 인식할 수 있는 완전한 원시 코드를 함께 제공해야 합니다. 원시 코드는 제1조와 제2조의 규정에 따라 배포될 수 있어야 하며, 소프트웨어의 교환을 위해서 일반적으로 사용되는 매체를 통해 제공되어야 합니다. + +제 2 항. 배포에 필요한 최소한의 비용만을 받고 목적 코드나 실행물에 상응하는 완전한 원시 코드를 배포하겠다는, 최소한 3년간 유효한 약정서를 함께 제공해야 합니다. 이 약정서는 약정서를 갖고 있는 어떠한 사람에 대해서도 유효해야 합니다. 원시 코드는 컴퓨터가 인식할 수 있는 형태여야 하고 제1조와 제2조의 규정에 따라 배포될 수 있어야 하며, 소프트웨어의 교환을 위해서 일반적으로 사용되는 매체를 통해 제공되어야 합니다. + +제 3 항. 목적 코드나 실행물에 상응하는 원시 코드를 배포하겠다는 약정에 대해서 자신이 양도받은 정보를 함께 제공해야 합니다. (제3항은 위의 제2항에 따라 원시 코드를 배포하겠다는 약정을 프로그램의 목적 코드나 실행물과 함께 제공 받았고, 동시에 비상업적인 배포를 하고자 할 경우에 한해서만 허용됩니다.) + +저작물에 대한 원시 코드란 해당 저작물을 개작하기에 적절한 형식을 의미합니다. 실행물에 대한 완전한 원시 코드란 실행물에 포함된 모든 모듈들의 원시 코드와 이와 관련된 인터페이스 정의 파일 모두, 그리고 실행물의 컴파일과 설치를 제어하는데 사용된 스크립트 전부를 의미합니다. 그러나 특별한 예외의 하나로서, 실행물이 실행될 운영체제의 주요 부분(컴파일러나 커널 등)과 함께 (원시 코드나 바이너리의 형태로) 일반적으로 배포되는 구성 요소들은 이러한 구성 요소 자체가 실행물에 수반되지 않는 한 원시 코드의 배포 대상에서 제외되어도 무방합니다. + +목적 코드나 실행물을 지정한 장소로부터 복제해 갈 수 있게 하는 방식으로 배포할 경우, 동일한 장소로부터 원시 코드를 복제할 수 있는 동등한 접근 방법을 제공한다면 이는 원시 코드를 목적 코드와 함께 복제되도록 설정하지 않았다고 하더라도 원시 코드를 배포하는 것으로 간주됩니다. + +제 4 조. 본 허가서에 의해 명시적으로 이루어 지지 않는 한 프로그램에 대한 복제와 개작 및 하위 허가권 설정과 배포가 성립될 수 없습니다. 이와 관련된 어떠한 행위도 무효이며 본 허가서가 보장한 권리는 자동으로 소멸됩니다. 그러나 본 허가서의 규정에 따라 프로그램의 복제물이나 권리를 양도받았던 제3자는 본 허가서의 규정들을 준수하는 한, 배포자의 권리 소멸에 관계없이 사용상의 권리를 계속해서 유지할 수 있습니다. + +제 5 조. 본 허가서는 서명이나 날인이 수반되는 형식을 갖고 있지 않기 때문에 피양도자가 본 허가서의 내용을 반드시 받아들여야 할 필요는 없습니다. 그러나 프로그램이나 프로그램에 기반한 2차적 프로그램에 대한 개작 및 배포를 허용하는 것은 본 허가서에 의해서만 가능합니다. 만약 본 허가서에 동의하지 않을 경우에는 이러한 행위들이 법률적으로 금지됩니다. 따라서 프로그램(또는 프로그램에 기반한 2차적 프로그램)을 개작하거나 배포하는 행위는 이에 따른 본 허가서의 내용에 동의한다는 것을 의미하며, 복제와 개작 및 배포에 관한 본 허가서의 조건과 규정들을 모두 받아들이겠다는 의미로 간주됩니다. + +제 6 조. 피양도자에 의해서 프로그램(또는 프로그램에 기반한 2차적 프로그램)이 반복적으로 재배포될 경우, 각 단계에서의 피양도자는 본 허가서의 규정에 따른 프로그램의 복제와 개작 및 배포에 대한 권리를 최초의 양도자로부터 양도받은 것으로 자동적으로 간주됩니다. 프로그램(또는 프로그램에 기반한 2차적 프로그램)을 배포할 때는 피양도자의 권리의 행사를 제한할 수 있는 어떠한 사항도 추가할 수 없습니다. 그러나 피양도자에게, 재배포가 일어날 시점에서의 제3의 피양도자에게 본 허가서를 준수하도록 강제할 책임은 부과되지 않습니다. + +제 7 조. 법원의 판결이나 특허권 침해에 대한 주장 또는 특허 문제에 국한되지 않은 그밖의 이유들로 인해서 본 허가서의 규정에 배치되는 사항이 발생한다 하더라도 그러한 사항이 선행하거나 본 허가서의 조건과 규정들이 면제되는 것은 아닙니다. 따라서 법원의 명령이나 합의 등에 의해서 본 허가서에 위배되는 사항들이 발생한 상황이라도 양측 모두를 만족시킬 수 없다면 프로그램은 배포될 수 없습니다. 예를 들면, 특정한 특허 관련 허가가 프로그램의 복제물을 직접 또는 간접적인 방법으로 양도받은 임의의 제3자에게 해당 프로그램을 무상으로 재배포할 수 있게 허용하지 않는다면, 그러한 허가와 본 사용 허가를 동시에 만족시키면서 프로그램을 배포할 수 있는 방법은 없습니다. + +본 조항은 특정한 상황에서 본 조항의 일부가 유효하지 않거나 적용될 수 없을 경우에도 본 조항의 나머지 부분들을 적용하기 위한 의도로 만들어 졌습니다. 따라서 그 이외의 상황에서는 본 조항을 전체적으로 적용하면 됩니다. + +본 조항의 목적은 특허나 저작권 침해 등의 행위를 조장하거나 해당 권리를 인정하지 않으려는 것이 아니라, GPL을 통해서 구현되어 있는 자유 소프트웨어의 배포 체계를 통합적으로 보호하기 위한 것입니다. 많은 사람들이 배포 체계에 대한 신뢰있는 지원을 계속해 줌으로써 소프트웨어의 다양한 분야에 많은 공헌을 해 주었습니다. 소프트웨어를 어떠한 배포 체계로 배포할 것인가를 결정하는 것은 전적으로 저작자와 기증자들의 의지에 달려있는 것이지, 일반 사용자들이 강요할 수 있는 문제는 아닙니다. + +본 조항은 본 허가서의 다른 조항들에서 무엇이 중요하게 고려되어야 하는 지를 명확하게 설명하기 위한 목적으로 만들어진 것입니다. + +제 8 조. 특허나 저작권이 설정된 인터페이스로 인해서 특정 국가에서 프로그램의 배포와 사용이 함께 또는 개별적으로 제한되어 있는 경우, 본 사용 허가서를 프로그램에 적용한 최초의 저작권자는 문제가 발생하지 않는 국가에 한해서 프로그램을 배포한다는 배포상의 지역적 제한 조건을 명시적으로 설정할 수 있으며, 이러한 사항은 본 허가서의 일부로 간주됩니다. + +제 9 조. 자유 소프트웨어 재단은 때때로 본 사용 허가서의 개정판이나 신판을 공표할 수 있습니다. 새롭게 공표될 판은 당면한 문제나 현안을 처리하기 위해서 세부적인 내용에 차이가 발생할 수 있지만, 그 근본 정신에는 변함이 없을 것입니다. + +각각의 판들은 판번호를 사용해서 구별됩니다. 특정한 판번호와 그 이후 판을 따른다는 사항이 명시된 프로그램에는 해당 판이나 그 이후에 발행된 어떠한 판을 선택해서 적용해도 무방하고, 판번호를 명시하고 있지 않은 경우에는 자유 소프트웨어 재단이 공표한 어떠한 판번호의 판을 적용해도 무방합니다. + +제 10 조. 프로그램의 일부를 본 허가서와 배포 기준이 다른 자유 프로그램과 함께 결합하고자 할 경우에는 해당 프로그램의 저작자로부터 서면 승인을 받아야 합니다. 자유 소프트웨어 재단이 저작권을 갖고 있는 소프트웨어의 경우에는 자유 소프트웨어 재단의 승인을 얻어야 합니다. 우리는 이러한 요청을 수락하기 위해서 때때로 예외 기준을 만들기도 합니다. 자유 소프트웨어 재단은 일반적으로 자유 소프트웨어의 2차적 저작물들을 모두 자유로운 상태로 유지시키려는 목적과 소프트웨어의 공유와 재활용을 증진시키려는 두가지 목적을 기준으로 승인 여부를 결정할 것입니다. + +보증의 결여 (제11조, 제12조) + +제 11 조. 본 허가서를 따르는 프로그램은 무상으로 양도되기 때문에 관련 법률이 허용하는 한도 내에서 어떠한 형태의 보증도 제공되지 않습니다. 프로그램의 저작권자와 배포자가 공동 또는 개별적으로 별도의 보증을 서면으로 제공할 때를 제외하면, 특정한 목적에 대한 프로그램의 적합성이나 상업성 여부에 대한 보증을 포함한 어떠한 형태의 보증도 명시적이나 묵시적으로 설정되지 않은 ``있는 그대로의'' 상태로 이 프로그램을 배포합니다. 프로그램과 프로그램의 실행에 따라 발생할 수 있는 모든 위험은 피양도자에게 인수되며 이에 따른 보수 및 복구를 위한 제반 경비 또한 피양도자가 모두 부담해야 합니다. + +제 12 조. 저작권자나 배포자가 프로그램의 손상 가능성을 사전에 알고 있었다 하더라도 발생된 손실이 관련 법규에 의해 보호되고 있거나 이에 대한 별도의 서면 보증이 설정된 경우가 아니라면, 저작권자나 프로그램을 원래의 상태 또는 개작한 상태로 제공한 배포자는 프로그램의 사용이나 비작동으로 인해 발생된 손실이나 프로그램 자체의 손실에 대해 책임지지 않습니다. 이러한 면책 조건은 사용자나 제3자가 프로그램을 조작함으로써 발생된 손실이나 다른 소프트웨어와 프로그램을 함께 동작시키는 것으로 인해서 발생된 데이터의 상실 및 부정확한 산출 결과에만 국한되는 것이 아닙니다. 발생된 손실의 일반성이나 특수성 뿐 아니라 원인의 우발성 및 필연성도 전혀 고려되지 않습니다. + +복제와 개작 및 배포에 관한 조건과 규정의 끝. + + + +----- GPL 원문 -------------------------------------------------------- + +GNU GENERAL PUBLIC LICENSE +Version 2, June 1991 + +Copyright (C) 1989, 1991 Free Software Foundation, Inc. +59 Temple Place - Suite 330, Boston, MA 02111-1307, USA + +Everyone is permitted to copy and distribute verbatim copies +of this license document, but changing it is not allowed. + +Preamble +The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too. + +When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. + +To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. + +For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. + +We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. + +Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. + +Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. + +The precise terms and conditions for copying, distribution and modification follow. + +TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION +0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. + +1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. + +You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. + +2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: + + +a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. + +b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. + +c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) +These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. + +3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: + +a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, + +b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, + +c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) +The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. + +If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. + +4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. + +5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. + +6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. + +7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. + +This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. + +8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. + +9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. + +10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. + +NO WARRANTY + +11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + +12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. + + +END OF TERMS AND CONDITIONS + +----- 끝 -------------------------------------------------------- diff --git a/README.md b/README.md index e69de29bb..80e41eabd 100644 --- a/README.md +++ b/README.md @@ -0,0 +1,2 @@ + +YoungCart4 Standard \ No newline at end of file diff --git a/_common.php b/_common.php index ff0c5a3e7..aa6efdf8b 100644 --- a/_common.php +++ b/_common.php @@ -1,4 +1,3 @@ +include_once('./common.php'); +?> \ No newline at end of file diff --git a/_head.php b/_head.php index a3adcd264..0566ac74d 100644 --- a/_head.php +++ b/_head.php @@ -1,4 +1,5 @@ \ No newline at end of file diff --git a/_tail.php b/_tail.php index ecb08437a..a2e7bf983 100644 --- a/_tail.php +++ b/_tail.php @@ -1,4 +1,5 @@ \ No newline at end of file diff --git a/adm/_common.php b/adm/_common.php index 1f7dc8ed3..a10ebb275 100644 --- a/adm/_common.php +++ b/adm/_common.php @@ -1,5 +1,5 @@ +define('G4_IS_ADMIN', true); +include_once ('../common.php'); +include_once(G4_ADMIN_PATH.'/admin.lib.php'); +?> \ No newline at end of file diff --git a/adm/admin.head.php b/adm/admin.head.php index 91e8ea1a3..48f03513b 100644 --- a/adm/admin.head.php +++ b/adm/admin.head.php @@ -1,78 +1,42 @@ "; - $str .= print_menu2($key, $no); - $str .= "
\n"; + $str = print_menu2($key, $no); return $str; } - function print_menu2($key, $no) { global $menu, $auth_menu, $is_admin, $auth, $g4; - $str = ""; + $str .= ""; return $str; } ?> - - - - - - - - - - - --- - - - - - - - - - - - - - - - -
/'>/img/logo.gif' border=0> - $value) - { - $href1 = $href2 = ""; - if ($menu["menu{$key}"][0][2]) - { - $href1 = ""; - $href2 = ""; +
/'>/img/home.gif' border=0>/logout.php'>/img/logout.gif' border=0> - /img/navi_icon.gif' align=absmiddle> -  /'>Admin > - "; - echo $menu["menu{$tmp_menu}"][0][1]; - echo " > "; - } - else - echo $menu["menu{$tmp_menu}"][0][1]." > "; - } - ?> - :   
- - "; - echo print_menu2("menu{$tmp_menu}", 2); - ?> -

-
+ $gnb_str .= ""; + echo $gnb_str; + ?> + + +
+

님 현재위치

+
+ + + + +
+ + + +
+
+ + + +
+

diff --git a/adm/admin.js b/adm/admin.js index 7e1671082..5f3999fd9 100644 --- a/adm/admin.js +++ b/adm/admin.js @@ -44,3 +44,15 @@ function btn_check(f, act) f.submit(); } + +function is_checked(elements_name) +{ + var checked = false; + var chk = document.getElementsByName(elements_name); + for (var i=0; i\n"; + for ($i=0; $i\n"; + for ($i=0; $i 1) { - $sql = " update $g4[member_table] - set mb_jumin = '', - mb_password = '', - mb_level = '1', - mb_email = '', - mb_homepage = '', - mb_password_q = '', - mb_password_a = '', - mb_tel = '', - mb_hp = '', - mb_zip1 = '', - mb_zip2 = '', - mb_addr1 = '', - mb_addr2 = '', - mb_birth = '', - mb_sex = '', - mb_signature = '', - mb_memo = '".date("Ymd",$g4['server_time'])." 삭제함\n\n$mb[mb_memo]', - mb_leave_date = '".date("Ymd",$g4['server_time'])."' - where mb_id = '$mb_id' "; - //echo $sql; exit; - sql_query($sql); - } - - /* - // 회원 자료 삭제 - sql_query(" delete from $g4[member_table] where mb_id = '$mb_id' "); - - // 삭제된 자료를 또 삭제하면 완전 삭제함 - if ($mb[mb_nick] != '[삭제됨]') - { - // 다른 사람이 이 회원아이디를 사용하지 못하도록 아이디만 생성해 놓습니다. - // 게시판에서 회원아이디는 삭제하지 않기 때문입니다. - sql_query(" insert into $g4[member_table] set mb_id = '$mb_id', mb_name='$mb[mb_name]', mb_nick='[삭제됨]', mb_ip='$mb[mb_ip]', mb_datetime = '$g4[time_ymdhis]' "); - } - - // 포인트 테이블에서 삭제 - sql_query(" delete from $g4[point_table] where mb_id = '$mb_id' "); - - // 그룹접근가능 삭제 - sql_query(" delete from $g4[group_member_table] where mb_id = '$mb_id' "); - - // 쪽지 삭제 - sql_query(" delete from $g4[memo_table] where me_recv_mb_id = '$mb_id' or me_send_mb_id = '$mb_id' "); - - // 스크랩 삭제 - sql_query(" delete from $g4[scrap_table] where mb_id = '$mb_id' "); - - // 관리권한 삭제 - sql_query(" delete from $g4[auth_table] where mb_id = '$mb_id' "); - - // 그룹관리자인 경우 그룹관리자를 공백으로 - sql_query(" update $g4[group_table] set gr_admin = '' where gr_admin = '$mb_id' "); - - // 게시판관리자인 경우 게시판관리자를 공백으로 - sql_query(" update $g4[board_table] set bo_admin = '' where bo_admin = '$mb_id' "); - - // 아이콘 삭제 - @unlink("$g4[path]/data/member/".substr($mb_id,0,2)."/$mb_id.gif"); - */ + $sql = " update {$g4['member_table']} set mb_jumin = '', mb_password = '', mb_level = 1, mb_email = '', mb_homepage = '', mb_password_q = '', mb_password_a = '', mb_tel = '', mb_hp = '', mb_zip1 = '', mb_zip2 = '', mb_addr1 = '', mb_addr2 = '', mb_birth = '', mb_sex = '', mb_signature = '', mb_memo = '".date('Ymd', G4_SERVER_TIME)." 삭제함\n{$mb['mb_memo']}', mb_leave_date = '".date('Ymd', G4_SERVER_TIME)."' where mb_id = '{$mb_id}' "; + sql_query($sql); } // 회원권한을 SELECT 형식으로 얻음 -function get_member_level_select($name, $start_id=0, $end_id=10, $selected='', $event='') +function get_member_level_select($name, $start_id=0, $end_id=10, $selected="", $event="") { global $g4; - $str = ""; + $str .= ''; return $str; } @@ -150,50 +117,35 @@ function auth_check($auth, $attr) { global $is_admin; - if ($is_admin == "super") return; + if ($is_admin == 'super') return; if (!trim($auth)) - alert("이 메뉴에는 접근 권한이 없습니다.\\n\\n접근 권한은 최고관리자만 부여할 수 있습니다."); + alert('이 메뉴에는 접근 권한이 없습니다.\\n\\n접근 권한은 최고관리자만 부여할 수 있습니다.'); $attr = strtolower($attr); if (!strstr($auth, $attr)) { - if ($attr == "r") - alert("읽을 권한이 없습니다."); - else if ($attr == "w") - alert("입력, 추가, 생성, 수정 권한이 없습니다."); - else if ($attr == "d") - alert("삭제 권한이 없습니다."); - else - alert("속성이 잘못 되었습니다."); + if ($attr == 'r') + alert('읽을 권한이 없습니다.'); + else if ($attr == 'w') + alert('입력, 추가, 생성, 수정 권한이 없습니다.'); + else if ($attr == 'd') + alert('삭제 권한이 없습니다.'); + else + alert('속성이 잘못 되었습니다.'); } } -// 텍스트에리어 늘리기, 줄이기 -function textarea_size($fld) -{ - global $g4; - - $size = 10; - $s = "
"; - $s .= " "; - $s .= ""; - $s .= "  
"; - return $s; -} - - // 작업아이콘 출력 -function icon($act, $link="", $target="_parent") +function icon($act, $link='', $target='_parent') { global $g4; - $img = array("입력"=>"insert", "추가"=>"insert", "생성"=>"insert", "수정"=>"modify", "삭제"=>"delete", "이동"=>"move", "그룹"=>"move", "보기"=>"view", "미리보기"=>"view", "복사"=>"copy"); - $icon = ""; + $img = array('입력'=>'insert', '추가'=>'insert', '생성'=>'insert', '수정'=>'modify', '삭제'=>'delete', '이동'=>'move', '그룹'=>'move', '보기'=>'view', '미리보기'=>'view', '복사'=>'copy'); + $icon = ''; if ($link) - //$s = "$icon"; - $s = "$icon"; + $s = ''.$icon.''; else $s = $icon; return $s; @@ -202,70 +154,51 @@ function icon($act, $link="", $target="_parent") // rm -rf 옵션 : exec(), system() 함수를 사용할 수 없는 서버 또는 win32용 대체 // www.php.net 참고 : pal at degerstrom dot com -function rm_rf($file) +function rm_rf($file) { if (file_exists($file)) { @chmod($file,0777); if (is_dir($file)) { - $handle = opendir($file); + $handle = opendir($file); while($filename = readdir($handle)) { - if ($filename != "." && $filename != "..") - rm_rf("$file/$filename"); + if ($filename != '.' && $filename != '..') + rm_rf($file.'/'.$filename); } closedir($handle); rmdir($file); - } else + } else unlink($file); } } -function help($help="", $left=0, $top=0) +// 입력 폼 안내문 +function help($help="") { global $g4; - static $idx = 0; - $idx++; - - $help = preg_replace("/\n/", "
", $help); - - $str = ""; - $str .= ""; + $str = ''.str_replace("\n", "
", $help).'
'; return $str; } -function subtitle($title, $more="") -{ - global $g4; - - $s = "
$title       
"; - if ($more) - $s .= ""; - $s .= "
\n"; - - return $s; -} - // 출력순서 -function order_select($fld, $sel="") +function order_select($fld, $sel='') { - $s = "'; for ($i=1; $i<=100; $i++) { - $s .= "
/img/top.gif' border=0> 


+ + + + + + + - + + + + \ No newline at end of file diff --git a/adm/auth_list.php b/adm/auth_list.php index 991e5d278..698a22c92 100644 --- a/adm/auth_list.php +++ b/adm/auth_list.php @@ -1,20 +1,20 @@ 처음"; +$listall = ''; +if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 : 지운아빠 2012-10-31 + $listall = '전체목록'; -$g4[title] = "관리권한설정"; -include_once("./admin.head.php"); +$g4['title'] = "관리권한설정"; +include_once('./admin.head.php'); $colspan = 5; ?> - - - - - - - - - + + +
+ 관리권한 검색 + + + 설정된 관리권한 건 + + + + +
-
- (건수 : ) - - - -
-
- - - - - - +
+

설정된 관리권한 내역

+

권한 r은 읽기권한, w는 쓰기권한, d는 삭제권한입니다.

- ------ - - - - - - - - - + + + + + + +
회원아이디별명메뉴권한
+ + + + + + + + + + + + + + + + + + + - - - - - - - - "; -} + if ($i==0) + echo ''; + ?> + +
회원아이디별명메뉴권한
+ + + + + + +
$row[mb_id]$mb_nick  [$row[au_menu]] {$auth_menu[$row[au_menu]]}$row[au_auth]
자료가 없습니다.
-if ($i==0) - echo "자료가 없습니다."; +
+ +
-echo ""; -echo ""; + -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&page="); -echo ""; -echo ""; -echo "
"; -echo ""; -echo "$pagelist
\n"; + document.fsearch.sfl.value = "'.$sfl.'";'."\n"; -if ($stx) - echo "\n"; + if (strstr($sfl, 'mb_id')) + $mb_id = $stx; + else + $mb_id = ''; + ?> + +
+ +
+ + + + + + + +
+

관리권한 추가

+

다음 양식에서 회원에게 관리권한을 부여하실 수 있습니다.

+ + + + + + + + + + + + + + + + + + + + +
+ + +
+ +
권한지정 + + + + + + +
+ +
+ XSS 혹은 CSRF 방지 +

관리자 권한을 탈취당하는 경우를 대비하여 패스워드를 다시 한번 확인합니다.

+ + +
+ +
+ +
+
-if (strstr($sfl, "mb_id")) - $mb_id = $stx; -else - $mb_id = ""; -?>
- - - -

- -

- - - - - - - - ------ - - - - - - - - - - - - - - - - +
+

게시판 권한 설정

+ -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
회원아이디접근가능메뉴권한관리자패스워드입력
- - - --- - - - - - - - - - - - - - - - - - - - - - - - - -
원본 테이블
복사할 TABLE 영문자, 숫자, _ 만 가능 (공백없이)
게시판 제목
복사 유형 - 구조만 - 구조와 데이터 -
-   - -
+ + + + + + + + + + + + + + + + + + + + + +
원본 테이블명
영문자, 숫자, _ 만 가능 (공백없이)
복사 유형 + + + + +
+ + +
+ + +
- + diff --git a/adm/board_copy_update.php b/adm/board_copy_update.php index a19b2a7dc..b153dba7d 100644 --- a/adm/board_copy_update.php +++ b/adm/board_copy_update.php @@ -1,209 +1,195 @@ read()) - { - if ($entry == "." || $entry == "..") continue; - - /* - @copy("$g4[path]/data/file/$bo_table/$entry", "$g4[path]/data/file/$target_table/$entry"); - @chmod("$g4[path]/data/file/$target_table/$entry", 0707); - - $copy_file++; - */ +if ($copy_case == 'schema_data_both') { + $d = dir(G4_DATA_PATH.'/file/'.$bo_table); + while ($entry = $d->read()) { + if ($entry == '.' || $entry == '..') continue; // 김선용 201007 : - if(is_dir("$g4[path]/data/file/$bo_table/$entry")){ - $dd = dir("$g4[path]/data/file/$bo_table/$entry"); - @mkdir("$g4[path]/data/file/$target_table/$entry", 0707); - @chmod("$g4[path]/data/file/$target_table/$entry", 0707); + if(is_dir(G4_DATA_PATH.'/file/'.$bo_table.'/'.$entry)){ + $dd = dir(G4_DATA_PATH.'/file/'.$bo_table.'/'.$entry); + @mkdir(G4_DATA_PATH.'/file/'.$target_table.'/'.$entry, 0707); + @chmod(G4_DATA_PATH.'/file/'.$target_table.'/'.$entry, 0707); while ($entry2 = $dd->read()) { - if ($entry2 == "." || $entry2 == "..") continue; - @copy("$g4[path]/data/file/$bo_table/$entry/$entry2", "$g4[path]/data/file/$target_table/$entry/$entry2"); - @chmod("$g4[path]/data/file/$target_table/$entry/$entry2", 0707); + if ($entry2 == '.' || $entry2 == '..') continue; + @copy(G4_DATA_PATH.'/file/'.$bo_table.'/'.$entry.'/'.$entry2, G4_DATA_PATH.'/file/'.$target_table.'/'.$entry.'/'.$entry2); + @chmod(G4_DATA_PATH.'/file/'.$target_table.'/'.$entry.'/'.$entry2, 0707); $copy_file++; } $dd->close(); } else { - @copy("$g4[path]/data/file/$bo_table/$entry", "$g4[path]/data/file/$target_table/$entry"); - @chmod("$g4[path]/data/file/$target_table/$entry", 0707); + @copy(G4_DATA_PATH.'/file/'.$bo_table.'/'.$entry, G4_DATA_PATH.'/file/'.$target_table.'/'.$entry); + @chmod(G4_DATA_PATH.'/file/'.$target_table.'/'.$entry, 0707); $copy_file++; } } $d->close(); // 글복사 - $sql = " insert into $g4[write_prefix]$target_table select * from $g4[write_prefix]$bo_table "; + $sql = " insert into {$g4['write_prefix']}$target_table select * from {$g4['write_prefix']}$bo_table "; sql_query($sql); // 게시글수 저장 - $sql = " select bo_count_write, bo_count_comment from $g4[board_table] where bo_table = '$bo_table' "; + $sql = " select bo_count_write, bo_count_comment from {$g4['board_table']} where bo_table = '$bo_table' "; $row = sql_fetch($sql); - $sql = " update $g4[board_table] set bo_count_write = '$row[bo_count_write]', bo_count_comment = '$row[bo_count_comment]' where bo_table = '$target_table' "; + $sql = " update {$g4['board_table']} set bo_count_write = '{$row['bo_count_write']}', bo_count_comment = '{$row['bo_count_comment']}' where bo_table = '$target_table' "; sql_query($sql); - // 05.05.24 - // 파일테이블 복사 - //$sql = " insert into $g4[board_file_table] select '$target_table', wr_id, bf_no, bf_source, bf_file, bf_download, bf_content from $g4[board_file_table] where bo_table = '$bo_table' "; - //sql_query($sql); - // 4.00.01 // 위의 코드는 같은 테이블명을 사용하였다는 오류가 발생함. (희한하네 ㅡㅡ;) - $sql = " select * from $g4[board_file_table] where bo_table = '$bo_table' "; + $sql = " select * from {$g4['board_file_table']} where bo_table = '$bo_table' "; $result = sql_query($sql); - for ($i=0; $row=sql_fetch_array($result); $i++) + for ($i=0; $row=sql_fetch_array($result); $i++) $file_copy[$i] = $row; -} +} -if (count($file_copy)) -{ - for ($i=0; $i"; -echo ""; +delete_cache_latest($bo_table); +delete_cache_latest($target_table); -goto_url("./board_copy.php?bo_table=$bo_table&$qstr"); -?> +echo ""; + +alert("복사에 성공 했습니다.", './board_copy.php?bo_table='.$bo_table.'&'.$qstr); +?> \ No newline at end of file diff --git a/adm/board_delete.inc.php b/adm/board_delete.inc.php index ba292b77b..d1803212b 100644 --- a/adm/board_delete.inc.php +++ b/adm/board_delete.inc.php @@ -1,31 +1,36 @@ \ No newline at end of file diff --git a/adm/board_delete.php b/adm/board_delete.php index feead3f5a..6ead47183 100644 --- a/adm/board_delete.php +++ b/adm/board_delete.php @@ -1,28 +1,28 @@ diff --git a/adm/board_form.php b/adm/board_form.php index f532d8dac..292bb7ad4 100644 --- a/adm/board_form.php +++ b/adm/board_form.php @@ -1,595 +1,1109 @@ 필수'; - if ($is_admin == "group") { - if ($member[mb_id] != $group[gr_admin]) - alert("그룹이 틀립니다."); + $board['bo_count_delete'] = 1; + $board['bo_count_modify'] = 1; + $board['bo_read_point'] = $config['cf_read_point']; + $board['bo_write_point'] = $config['cf_write_point']; + $board['bo_comment_point'] = $config['cf_comment_point']; + $board['bo_download_point'] = $config['cf_download_point']; + + $board['bo_gallery_cols'] = 4; + $board['bo_gallery_width'] = 200; + $board['bo_gallery_height'] = 150; + $board['bo_mobile_gallery_cols'] = 2; + $board['bo_mobile_gallery_width'] = 160; + $board['bo_mobile_gallery_height'] = 120; + $board['bo_table_width'] = 100; + $board['bo_page_rows'] = $config['cf_page_rows']; + $board['bo_subject_len'] = 60; + $board['bo_new'] = 24; + $board['bo_hot'] = 100; + $board['bo_image_width'] = 600; + $board['bo_upload_count'] = 2; + $board['bo_upload_size'] = 1048576; + $board['bo_reply_order'] = 1; + $board['bo_use_search'] = 1; + $board['bo_skin'] = 'basic'; + $board['bo_mobile_skin'] = 'basic'; + $board['gr_id'] = $gr_id; + $board['bo_use_secret'] = 0; + $board['bo_include_head'] = '_head.php'; + $board['bo_include_tail'] = '_tail.php'; + $board['bo_show_menu'] = true; + +} else if ($w == 'u') { + + $html_title .= ' 수정'; + + if (!$board['bo_table']) + alert('존재하지 않은 게시판 입니다.'); + + if ($is_admin == 'group') { + if ($member['mb_id'] != $group['gr_admin']) + alert('그룹이 틀립니다.'); } - $bo_table_attr = "readonly style='background-color:#dddddd'"; + $bo_table_attr = 'readonly'; + } -if ($is_admin != "super") { - $group = get_group($board[gr_id]); - $is_admin = is_admin($member[mb_id]); +if ($is_admin != 'super') { + $group = get_group($board['gr_id']); + $is_admin = is_admin($member['mb_id']); } -$g4[title] = $html_title; -include_once ("./admin.head.php"); +$g4['title'] = $html_title; +include_once ('./admin.head.php'); + +$pg_anchor = ""; ?> - - - +
+ + + + + + - - - - - - - - - ---- - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
+

게시판 기본 설정

+ - -
- - - - - +
TABLE itemname='TABLE' value=''> - "; - ?> -
그룹 - - 동일그룹게시판목록
게시판 제목 - -
상단 이미지 - - $board[bo_image_head] 삭제"; - ?> -
하단 이미지 - - $board[bo_image_tail] 삭제"; - ?> -
카운트 조정 - 카운트를 조정합니다. - (현재 원글수 : , 현재 코멘트수 : ) - -
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ > + + 영문자, 숫자, _ 만 가능 (공백없이 20자 이내) + + 게시판 바로가기 + 목록으로 + +
+ + +
+ +
+ + + + + + + +
+ + + > + + + + + + +
+ + +
+ -
- - - 게시판 관리자
목록보기 권한 - - -
글읽기 권한
글쓰기 권한
글답변 권한
코멘트쓰기 권한
링크 권한
업로드 권한
다운로드 권한
HTML 쓰기 권한
트랙백쓰기 권한 - - -
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + +
+ + + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ - - - - 원글 수정 불가 - 코멘트 개 이상 달리면 수정불가 - - - - 원글 삭제 불가 - 코멘트 개 이상 달리면 삭제불가 - - - - - 포인트 설정 - 환경설정에 입력된 포인트로 설정 - - - - 글읽기 포인트 - - - - - 글쓰기 포인트 - - - - - 코멘트쓰기 포인트 - - - - - 다운로드 포인트 - - +
+

게시판 기능 설정

+ - - - - 분류 - - >사용 - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ 댓글 개 이상 달리면 수정불가 + + + + + +
+ 댓글 개 이상 달리면 삭제불가 + + + + + +
+ >사용 (글쓴이 클릭시 나오는 레이어 메뉴) + + + + + +
+ + + + + + + +
+ + id="bo_use_dhtml_editor"> + 사용 + + + + + +
+ + id="bo_use_rss_view"> + 사용 + + + + + +
+ id="bo_use_good"> + 사용 + + + + + +
+ > + 사용 + + + + + +
+ > + 사용 + + + -
글쓴이 사이드뷰>사용 (글쓴이 클릭시 나오는 레이어 메뉴)
파일 설명 사용>사용
코멘트 새창 사용>사용 (코멘트수 클릭시 새창으로 보임)
비밀글 사용 - -   - -
DHTML 에디터 사용 - >사용 -   -
RSS 보이기 사용 - >사용 -   -
추천 사용>사용
비추천 사용>사용
이름(실명) 사용>사용
서명보이기 사용>사용
IP 보이기 사용>사용
트랙백 사용>사용 (트랙백쓰기 권한 보다 우선함)
목록에서 내용 사용>사용 (사용시 속도 느려짐)
전체목록보이기 사용>사용
메일발송 사용>사용
+ > + 사용 + + + + + +
+ > + 사용 + + + + + +
+ > + 사용 (사용시 속도 느려질 수 있습니다.) + + + + + +
+ > + 사용 + + + + + +
+ > + 사용 + + + + + +
+ + + + + + + +
+ + 업로드 파일 한개당 bytes 이하 + + + + + +
+ >사용 + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ > + 사용 + + + + + +
+ + > + 사용 + + + + + +
+ + + + + + + +
+
- - - - 스킨 디렉토리 - - - - - - - 가로 이미지수 - - - - - - 게시판 테이블 폭 - 100 이하는 % - - - - 페이지당 목록 수 - - - - - 제목 길이 - 목록에서의 제목 글자수. 잘리는 글은 … 로 표시 - - - - new 이미지 - 글 입력후 new 이미지를 출력하는 시간 - - - - hot 이미지 - 조회수가 설정값 이상이면 hot 이미지 출력 - - - - 이미지 폭 크기 - 픽셀 (게시판에서 출력되는 이미지의 폭 크기) - - - - 답변 달기 - - - - - +
+

게시판 디자인/양식

+ - - - - 사용금지 태그 - - script|iframe)\n\nHTML 사용시 금지할 태그를 입력하는곳 입니다.", -50)?> - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + + +
+ + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + 픽셀 + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + +
+ + + + + + + +
+
- - - 리스트 정렬 필드 - - - - - - +
+

게시판 포인트 설정

+ - - - - 최소 글수 제한 - - (글 입력시 최소 글자수를 설정. 0을 입력하면 검사하지 않음) - - - - 최대 글수 제한 - - (글 입력시 최대 글자수를 설정. 0을 입력하면 검사하지 않음) - - - - 최소 코멘트수 제한 - - (코멘트 입력시 최소 글자수, 최대 글자수를 설정. 0을 입력하면 검사하지 않음) - - - - 최대 코멘트수 제한 - - (코멘트 입력시 최소 글자수, 최대 글자수를 설정. 0을 입력하면 검사하지 않음) - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+ + + + + + +
+
- - - - 파일 업로드 갯수 - 게시물 한건당 업로드 할 수 있는 파일의 최대 개수 (0 이면 제한 없음) - - - - - 파일 업로드 용량 - 업로드 파일 한개당 bytes 이하 (최대 이하) - +
+

게시판 여분필드 설정

+ - - - - 상단 파일 경로 - - - - - 하단 파일 경로 - - + + + + + + + + + + + + + + + +
여분필드 + + + + + + + + + +
+
- - - - 상단 내용 - - - - - - 하단 내용 - - - +
+ XSS 혹은 CSRF 방지 +

관리자 권한을 탈취당하는 경우를 대비하여 패스워드를 다시 한번 확인합니다.

+ + +
- - - - 글쓰기 기본 내용 - - +
+ + 목록 + 게시판복사 +
- - - - 전체 검색 사용 - >사용 - - - - 전체 검색 순서 - 숫자가 낮은 게시판 부터 검색 - - - - - - value=1> - - - - - - - - - - - - - - - 관리자 패스워드 - - - - - - - - - -

-   -   - - diff --git a/adm/board_form_update.php b/adm/board_form_update.php index 358587798..c2e4bb93f 100644 --- a/adm/board_form_update.php +++ b/adm/board_form_update.php @@ -1,225 +1,207 @@ diff --git a/adm/board_list.php b/adm/board_list.php index ad905e554..9abe90d01 100644 --- a/adm/board_list.php +++ b/adm/board_list.php @@ -1,22 +1,15 @@ 처음"; +$listall = ''; +if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 + $listall = '전체목록'; -$g4[title] = "게시판관리"; -include_once("./admin.head.php"); +$g4['title'] = '게시판관리'; +include_once('./admin.head.php'); -$colspan = 13; +$colspan = 15; ?> - - - - - - - - - -
(게시판수 : 개) - - -
- -

- - - - - - - ------------ - - - - - - - - - - - - - - - - - - 10) - $option = substr($arr[$k], 0, 18) . "…"; - - $skin_options .= ""; -} - -for ($i=0; $row=sql_fetch_array($result); $i++) { - $s_upd = ""; - $s_del = ""; - if ($is_admin == "super") { - //$s_del = ""; - $s_del = ""; - } - $s_copy = ""; - - /* - // 스킨디렉토리 - $skin_options = ""; - $arr = get_skin_dir("board"); - for ($k=0; $k 10) - $option = substr($arr[$k], 0, 18) . "…"; - - $skin_options .= ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - - if ($is_admin == "super") - echo ""; - else - echo ""; - - echo ""; - echo "\n"; - echo ""; -} - -if ($i == 0) - echo ""; - -echo ""; -echo "
TABLE제목읽기
포인트
쓰기
포인트
코멘트
포인트
다운
포인트
검색
사용
검색
순서
그룹스킨
$row[bo_table]$s_upd $s_del $s_copy
".get_group_select("gr_id[$i]", $row[gr_id])."$row[gr_subject]
자료가 없습니다.
"; - -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&page="); -echo ""; -echo ""; -echo "
"; -echo " "; - -if ($is_admin == "super") - echo ""; - -echo "$pagelist
\n"; - -if ($stx) - echo ""; -?> + +
+ 게시판 검색 + + + 생성된 게시판수 개 + + + + +
- +
+

생성된 게시판 목록

+

여러개의 게시판 설정을 한번에 바꾸실 때는 게시판 체크기능을 이용하세요.

+ + + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + 수정'; + $one_copy = '복사'; + ?> + + + + + + + + + + + + + + + + + + + '; + ?> + +
그룹TABLE스킨모바일
스킨
제목읽기P포인트쓰기P포인트댓글P포인트다운P포인트검색
사용
메뉴
보임
출력
순서
접속기기관리
+ + + + + + + + + + + + + + + title="선택시 검색사용"> title="선택시 메뉴보이기"> + +
자료가 없습니다.
+ +
+ + + + 게시판추가 + +
+ +
+
+ + -
- - - - - - - -
- diff --git a/adm/board_list_update.php b/adm/board_list_update.php index 75319cd2c..d6115ecc2 100644 --- a/adm/board_list_update.php +++ b/adm/board_list_update.php @@ -1,42 +1,72 @@ diff --git a/adm/boardgroup_delete.php b/adm/boardgroup_delete.php index dc2edb50a..c6b2073dd 100644 --- a/adm/boardgroup_delete.php +++ b/adm/boardgroup_delete.php @@ -1,35 +1,35 @@ diff --git a/adm/boardgroup_form.php b/adm/boardgroup_form.php index ca4f1f714..c17ef01aa 100644 --- a/adm/boardgroup_form.php +++ b/adm/boardgroup_form.php @@ -1,112 +1,149 @@ 필수'; + $gr['gr_use_access'] = 0; + $html_title .= ' 생성'; +} else if ($w == 'u') { + $gr_id_attr = 'readonly'; + $gr = sql_fetch(" select * from {$g4['group_table']} where gr_id = '$gr_id' "); + $html_title .= ' 수정'; +} else - alert("제대로 된 값이 넘어오지 않았습니다."); + alert('제대로 된 값이 넘어오지 않았습니다.'); -$g4[title] = $html_title; -include_once("./admin.head.php"); +if (!isset($group['gr_device'])) { + sql_query(" ALTER TABLE `{$g4['group_table']}` ADD `gr_device` ENUM('both','pc','mobile') NOT NULL DEFAULT 'both' AFTER `gr_subject` ", false); +} + +if (!isset($group['gr_show_menu'])) { + sql_query(" ALTER TABLE `{$g4['group_table']}` ADD `gr_show_menu` TINYINT NOT NULL DEFAULT '0' AFTER `gr_use_access`, ADD `gr_order` INT NOT NULL DEFAULT '0' AFTER `gr_show_menu` ", false); +} + +$g4['title'] = $html_title; +include_once('./admin.head.php'); ?> -
- - - - - - - - ----- - - - - - - - - - - - - - - - - - - - - - - - +
+

+ 게시판을 생성하시려면 1개 이상의 게시판그룹이 필요합니다.
+ 게시판그룹을 이용하시면 더 효과적으로 게시판을 관리할 수 있습니다. +

+ + + + + + + - -
- - - - - - +
그룹 ID alphanumericunderline itemname='그룹 아이디' value=''> 영문자, 숫자, _ 만 가능 (공백없이)
그룹 제목 - - "; - ?> -
그룹 관리자 - "; - else - echo "$gr[gr_admin]"; - ?>
접근회원사용 - >사용 - -
접근회원수 - $row1[cnt]"; - ?> -
value='' title='여분필드 설정값'> value='' title='여분필드 설정값'>
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ 게시판그룹 바로가기'; + ?> +
+ + 게시판생성'; + ?> +
+ + +
+ '; + else + echo ''.$gr['gr_admin']; + ?> +
+ + > + 사용 +
접근회원수 + '.$row1['cnt'].''; + ?> +
+ + > + 사용 +
회원여분필드 + + + + +
- - +
+ + 목록 +
-

-   - -

+ + - diff --git a/adm/boardgroup_form_update.php b/adm/boardgroup_form_update.php index 5533c1a2e..8a96cd71f 100644 --- a/adm/boardgroup_form_update.php +++ b/adm/boardgroup_form_update.php @@ -1,66 +1,73 @@ diff --git a/adm/boardgroup_list.php b/adm/boardgroup_list.php index cc48d6ffa..f6d66b5e3 100644 --- a/adm/boardgroup_list.php +++ b/adm/boardgroup_list.php @@ -1,192 +1,205 @@ 처음"; +$listall = ''; +if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 + $listall = '처음'; -$g4[title] = "게시판그룹설정"; -include_once("./admin.head.php"); +$g4['title'] = '게시판그룹설정'; +include_once('./admin.head.php'); $colspan = 8; ?> - - - - - - - - + +
+ 그룹 검색 + + + 생성된 그룹수 개 + + + + +
-
(그룹수 : 개) - - -
-
- - - - - - - --------- - - - - - - - - - - - +
+

게시판그룹 목록

+

+ 접근사용 옵션을 설정하시면 관리자가 지정한 회원만 해당 그룹에 접근할 수 있습니다.
+ 접근사용 옵션은 해당 그룹에 속한 모든 게시판에 적용됩니다. +

+ + + + + + + + + + + + + +
그룹아이디제목그룹관리자게시판접근사용접근회원수"; } ?>
+ + + + + + + + + + + + + + + + + 수정'; + ?> + + + + + + + + + + + + + + + + '; + ?> +
그룹아이디제목그룹관리자게시판
갯수
접근
사용
접근
회원수
메뉴
보임
출력
순서
접속기기관리
+ + + + + + + + + + + value="1" id="gr_use_access_" title="선택 시 접근회원 사용"> value="1" id="gr_show_menu_" title="선택 시 메뉴보이기"> + + + +
자료가 없습니다.
+ + +
+ + "; - $s_del = ""; - if ($is_admin == "super") { - //$s_del = ""; - $s_del = ""; - } - - $list = $i%2; - echo ""; - echo ""; - echo ""; - echo "$row[gr_id]"; - echo ""; - - if ($is_admin == "super") - //echo "".get_member_id_select("gr_admin[$i]", 9, $row[gr_admin]).""; - echo ""; - else - echo "$row[gr_admin]"; - - echo "$row2[cnt]"; - echo ""; - echo "$row1[cnt]"; - echo "$s_upd $s_del"; - echo "\n"; -} - -if ($i == 0) - echo "자료가 없습니다."; - -echo ""; -echo ""; - -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&page="); -echo ""; -echo ""; -echo "
"; -echo ""; -//echo " "; -echo "$pagelist
\n"; - -if ($stx) - echo ""; +$pagelist = get_paging(G4_IS_MOBILE ? $config['cf_mobile_pages'] : $config['cf_write_pages'], $page, $total_page, $_SERVER['PHP_SELF'].'?'.$qstr.'&page='); +echo $pagelist; ?> - -
- - - - - - - -
- diff --git a/adm/boardgroup_list_update.php b/adm/boardgroup_list_update.php index c4188a15e..483f6b8a3 100644 --- a/adm/boardgroup_list_update.php +++ b/adm/boardgroup_list_update.php @@ -1,27 +1,47 @@ diff --git a/adm/boardgroupmember_form.php b/adm/boardgroupmember_form.php index ede17da9c..a732212d2 100644 --- a/adm/boardgroupmember_form.php +++ b/adm/boardgroupmember_form.php @@ -1,107 +1,116 @@ - - - - -
* $mb[mb_id] ($mb[mb_name] / $mb[mb_nick]) 님이 접근가능한 그룹 목록"; ?>
- - ----- - - - - - - - -"; - $s_del = ""; +
+

아이디 , 이름 , 별명 님이 접근가능한 그룹 목록

+
+ + + + + + + + +
그룹아이디그룹처리일시삭제
+ + + + + + + + + + + 삭제'; + ?> + + + + + + + + - - - - - "; -} + if ($i == 0) { + echo ''; + } + ?> + +
그룹아이디그룹처리일시삭제
$row[gr_id]$row[gr_subject]$row[gm_datetime]$s_del
접근가능한 그룹이 없습니다.
-if ($i == 0) { - echo "접근가능한 그룹이 없습니다."; -} -?> - - +
+ +
+ + -

-

- - - --- - - - -
그룹 - + +
+ 님 접근가능그룹 추가 + + -   - -
+ + +

게시판 그룹이 존재하지 않는다면 게시판그룹생성하기

+
- - - -
- - - - - - - - -
- diff --git a/adm/boardgroupmember_list.php b/adm/boardgroupmember_list.php index a25547a26..49dc44c29 100644 --- a/adm/boardgroupmember_list.php +++ b/adm/boardgroupmember_list.php @@ -1,23 +1,23 @@ - - - - - - - - - + + +
+ (아이디 )에서 검색 + + + + +
-
* [$gr[gr_id]] $gr[gr_subject]' 그룹의 접근가능한 회원 목록"; ?> - - -
- -------- - - - - - - - - - - +
+

그룹에 접근가능한 회원 목록 (그룹아이디:)

+
+ + + + + + + + +
회원아이디이름별명최종접속처리일시그룹삭제
+ + + + + + + + + + + + + '.$row2['cnt'].''; -$row2[cnt]"; + //$s_del = '삭제'; - //$s_del = ""; - $s_del = ""; + $mb_nick = get_sideview($row['mb_id'], $row['mb_nick'], $row['mb_email'], $row['mb_homepage']); + ?> + + + + + + + + + + '; + } + ?> + +
그룹회원아이디이름별명최종접속처리일시
자료가 없습니다.
- $list = $i%2; - echo " - - $row[mb_id] - $row[mb_name] - $mb_nick - ".substr($row[mb_today_login],2,8)." - $row[gm_datetime] - $group - $s_del - "; -} +
+ +
+ + -if ($i == 0) -{ - echo "자료가 없습니다."; -} - -echo ""; -echo ""; - -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&gr_id=$gr_id&page="); -if ($pagelist) - echo "
$pagelist
\n"; - -if ($stx) - echo "\n"; -?> + -
- - - - - - - - -
- diff --git a/adm/boardgroupmember_update.php b/adm/boardgroupmember_update.php index 6d936fc9b..4e1afb85c 100644 --- a/adm/boardgroupmember_update.php +++ b/adm/boardgroupmember_update.php @@ -1,62 +1,70 @@ diff --git a/adm/cache_file_delete.php b/adm/cache_file_delete.php new file mode 100644 index 000000000..854923d4c --- /dev/null +++ b/adm/cache_file_delete.php @@ -0,0 +1,52 @@ + + +
+

+ 완료 메세지가 나오기 전에 프로그램의 실행을 중지하지 마십시오. +

+ 최신글 캐시디렉토리를 열지못했습니다.

"; + } + + $cnt=0; + echo "\n"; + //echo "\n"; + echo "

최신글 캐시파일 {$cnt}건 삭제가 완료됐습니다.
프로그램의 실행을 끝마치셔도 좋습니다.

\n"; + ?> +
+ + \ No newline at end of file diff --git a/adm/config_form.php b/adm/config_form.php index 7adb3f5f6..65effaf80 100644 --- a/adm/config_form.php +++ b/adm/config_form.php @@ -1,425 +1,684 @@ +
  • 기본환경
  • +
  • 게시판기본
  • +
  • 회원가입
  • +
  • 기본메일환경
  • +
  • 글작성메일
  • +
  • 가입메일
  • +
  • 투표메일
  • +
  • 여분필드
  • +"; ?> -
    - + + - ----- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +
    +

    홈페이지 기본환경 설정

    + + +
    홈페이지 제목 - - 최고관리자
    포인트 사용> 사용
    로그인시 포인트 점 - 쪽지보낼시 차감 포인트 점 - 0으로 입력하시면 쪽지보낼시 포인트를 차감하지 않습니다.")?>
    이름(별명) 표시 자리만 표시 -
    별명 수정수정한 후 일 동안 바꿀 수 없음정보공개 수정수정한 후 일 동안 바꿀 수 없음
    최근게시물 삭제 일 - 쪽지 삭제 일 -
    접속자로그 삭제 일 - 인기검색어 삭제 일 -
    현재 접속자 분 - 한페이지당 라인수 라인 -
    최근게시물 스킨 - - 최근게시물 라인수 라인 -
    검색 스킨 - -
    접속자 스킨 - -
    복사, 이동시 로그> 남김 -
    접근가능 IP
    입력된 IP의 컴퓨터만 접근할 수 있음.
    123.123.+ 도 입력 가능. (엔터로 구분)
    접근차단 IP
    입력된 IP의 컴퓨터는 접근할 수 없음.
    123.123.+ 도 입력 가능. (엔터로 구분)
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    + + +
    + + +
    + + +
    + + +
    > 사용
    + + 점 + + + 점 +
    + + 자리만 표시 +
    수정하면 일 동안 바꿀 수 없음수정하면 일 동안 바꿀 수 없음
    + + 일 + + + 일 +
    + + 일 + + + 일 +
    + + 분 +
    + + 라인 + + + 라인 +
    페이지씩 표시 페이지씩 표시
    + + + +
    + + + +
    + + + +
    + + > 남김 +
    + 123.123.+ 도 입력 가능. (엔터로 구분)')?> + + + 123.123.+ 도 입력 가능. (엔터로 구분)')?> + +
    + + +
    +

    게시판 기본 설정

    + +

    각 게시판 관리에서 개별적으로 설정 가능합니다.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    초 지난후 가능 + + +
    건 단위로 검색
    + + +
    + + +
    + + +
    + + +
    +
    + +
    +

    회원가입 설정

    + +

    회원가입 시 사용할 스킨과 입력 받을 정보 등을 설정할 수 있습니다.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    + + + +
    홈페이지 입력 + > + > + 주소 입력 + > + > +
    전화번호 입력 + > + > + 핸드폰 입력 + > + > +
    서명 입력 + > + > + 자기소개 입력 + > + > +
    > 사용
    일 후 자동 삭제
    + + + 이상
    바이트 이하회원아이콘 사이즈 + + + + + 픽셀 이하 +
    > 사용
    + + + + + +
    +
    + +
    +

    기본 메일환경 설정

    + + + + + + + + + + + + + + + + + + + + +
    + + > 사용 +
    + + > 사용 +
    + + > 회원만 사용 +
    +
    + +
    +

    게시판 글 작성 시 메일 설정

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    + + > 사용 +
    + + > 사용 +
    + + > 사용 +
    + + > 사용 +
    + + > 사용 +
    +
    + +
    +

    회원가입 시 메일 설정

    + + + + + + + + + + + + + + + + + +
    + + > 사용 +
    + + > 사용 +
    +
    - - - - - - 글읽기 포인트 - 점 - 글쓰기 포인트 - 점 - - - 코멘트쓰기 포인트 - 점 - 다운로드 포인트 - 점 - - - LINK TARGET - - - 검색 단위 - 건 단위로 검색 - - - 검색 배경 색상 - - 검색 글자 색상 - - - - 새로운 글쓰기 - 초 지난후 가능 - 페이지 표시 수 - 페이지씩 표시 - - - 이미지 업로드 확장자 - - - - - 플래쉬 업로드 확장자 - - - - - 동영상 업로드 확장자 - - - - - 단어 필터링 - - - - - +
    +

    투표 기타의견 작성시 메일 설정

    + + + + + + + + + + + + +
    + + > 사용 +
    +
    - - - - - - 회원 스킨 - - - - - - 홈페이지 입력 - - > 보이기 - > 필수입력 - - 주소 입력 - - > 보이기 - > 필수입력 - - - - 전화번호 입력 - - > 보이기 - > 필수입력 - - 핸드폰 입력 - - > 보이기 - > 필수입력 - - - - 서명 입력 - - > 보이기 - > 필수입력 - - 자기소개 입력 - - > 보이기 - > 필수입력 - - - - 회원가입시 권한 - - 회원가입시 포인트 - 점 - - - - 회원탈퇴후 삭제일 - 일 후 자동 삭제 - - - 회원아이콘 사용 - - - - - - 아이콘 업로드 권한 - 이상 - - - 회원아이콘 용량 - 바이트 이하 - 회원아이콘 사이즈 - 폭 픽셀 , 높이 픽셀 이하 - - - 추천인제도 사용 - > 사용 - 추천인 포인트 - 점 - - - 아이디,별명 금지단어 - - - 입력 금지 메일 - -
    - - - 회원가입약관 - - - - 개인정보취급방침 - - - - +
    +

    여분필드 기본 설정

    + +

    각 게시판 관리에서 개별적으로 설정 가능합니다.

    + + + + + + + + + + + + + +
    여분필드 + + + + +
    +
    - - - - - - 메일발송 사용 - > 사용 (체크하지 않으면 메일발송을 아예 사용하지 않습니다. 메일 테스트도 불가합니다.) - - - 메일인증 사용 - > 사용 - - - - 폼메일 사용 여부 - > 회원만 사용 - - - - 게시판 글 작성시 - - - 최고관리자 메일발송 - > 사용 (최고관리자에게 메일을 발송합니다.) - - - 그룹관리자 메일발송 - > 사용 (그룹관리자에게 메일을 발송합니다.) - - - 게시판관리자 메일발송 - > 사용 (게시판관리자에게 메일을 발송합니다.) - - - 원글 메일발송 - > 사용 (게시자님께 메일을 발송합니다.) - - - 코멘트 메일발송 - > 사용 (원글에 코멘트가 올라오는 경우 코멘트 쓴 모든 분들께 메일을 발송합니다.) - - - 회원 가입시 - - - 최고관리자 메일발송 - > 사용 (최고관리자에게 메일을 발송합니다.) - - - 회원님께 메일발송 - > 사용 (회원가입한 회원님께 메일을 발송합니다.) - - - 투표 기타의견 작성시 - - - 최고관리자 메일발송 - > 사용 (최고관리자에게 메일을 발송합니다.) - - - +
    + XSS 혹은 CSRF 방지 +

    관리자 권한을 탈취당하는 경우를 대비하여 패스워드를 다시 한번 확인합니다.

    + + +
    +
    + +
    - - - - - - - - value='' title='여분필드 설정값'> - - value='' title='여분필드 설정값'> - - - - - - - - - - - - - - - 관리자 패스워드 - - - - - - - - - - -

    -

    - diff --git a/adm/config_form_update.php b/adm/config_form_update.php index 1ee7f7fed..68ffda47f 100644 --- a/adm/config_form_update.php +++ b/adm/config_form_update.php @@ -1,123 +1,134 @@ \ No newline at end of file diff --git a/adm/img/hd_bg.jpg b/adm/img/hd_bg.jpg new file mode 100644 index 000000000..345d89cc5 Binary files /dev/null and b/adm/img/hd_bg.jpg differ diff --git a/adm/img/logo.jpg b/adm/img/logo.jpg new file mode 100644 index 000000000..d822183d2 Binary files /dev/null and b/adm/img/logo.jpg differ diff --git a/adm/img/qnb_board.jpg b/adm/img/qnb_board.jpg new file mode 100644 index 000000000..617c89152 Binary files /dev/null and b/adm/img/qnb_board.jpg differ diff --git a/adm/img/qnb_log.jpg b/adm/img/qnb_log.jpg new file mode 100644 index 000000000..aa6f915e8 Binary files /dev/null and b/adm/img/qnb_log.jpg differ diff --git a/adm/img/qnb_mb.jpg b/adm/img/qnb_mb.jpg new file mode 100644 index 000000000..75e2ed3cc Binary files /dev/null and b/adm/img/qnb_mb.jpg differ diff --git a/adm/img/snb_home.jpg b/adm/img/snb_home.jpg new file mode 100644 index 000000000..5cbbfd010 Binary files /dev/null and b/adm/img/snb_home.jpg differ diff --git a/adm/img/snb_logout.jpg b/adm/img/snb_logout.jpg new file mode 100644 index 000000000..428052e45 Binary files /dev/null and b/adm/img/snb_logout.jpg differ diff --git a/adm/img/snb_modify.jpg b/adm/img/snb_modify.jpg new file mode 100644 index 000000000..8deb73deb Binary files /dev/null and b/adm/img/snb_modify.jpg differ diff --git a/adm/index.php b/adm/index.php index 6403accf5..f98f5c00d 100644 --- a/adm/index.php +++ b/adm/index.php @@ -1,377 +1,307 @@ '' - $sql_order "; +$sql = " select count(*) as cnt {$sql_common} {$sql_search} and mb_leave_date <> '' {$sql_order} "; $row = sql_fetch($sql); $leave_count = $row['cnt']; // 차단회원수 -$sql = " select count(*) as cnt - $sql_common - $sql_search - and mb_intercept_date <> '' - $sql_order "; +$sql = " select count(*) as cnt {$sql_common} {$sql_search} and mb_intercept_date <> '' {$sql_order} "; $row = sql_fetch($sql); $intercept_count = $row['cnt']; -$sql = " select * - $sql_common - $sql_search - $sql_order - limit $new_member_rows "; +$sql = " select * {$sql_common} {$sql_search} {$sql_order} limit {$new_member_rows} "; $result = sql_query($sql); $colspan = 12; ?> - +
    +

    신규가입회원 건 목록

    +

    총회원수 명 중 차단 명, 탈퇴 :

    - - - - - -
    (총회원수 : , 차단 : , 탈퇴 : )
    - - - - - - - ------------ - - - - - - - - - - - - - - -$row2[cnt]"; - - if ($is_admin == 'group') +
    회원아이디이름별명권한포인트최종접속수신공개인증차단그룹
    + + + + + + + + + + + + + + + + "; - $s_del = ""; - } - $s_grp = ""; + // 접근가능한 그룹수 + $sql2 = " select count(*) as cnt from {$g4['group_member_table']} where mb_id = '{$row['mb_id']}' "; + $row2 = sql_fetch($sql2); + $group = ""; + if ($row2['cnt']) + $group = ''.$row2['cnt'].''; - $leave_date = $row['mb_leave_date'] ? $row['mb_leave_date'] : date("Ymd", $g4['server_time']); - $intercept_date = $row['mb_intercept_date'] ? $row['mb_intercept_date'] : date("Ymd", $g4['server_time']); + if ($is_admin == 'group') + { + $s_mod = ''; + $s_del = ''; + } + else + { + $s_mod = '수정'; + $s_del = '삭제'; + } + $s_grp = '그룹'; - $mb_nick = get_sideview($row['mb_id'], $row['mb_nick'], $row['mb_email'], $row['mb_homepage']); + $leave_date = $row['mb_leave_date'] ? $row['mb_leave_date'] : date("Ymd", G4_SERVER_TIME); + $intercept_date = $row['mb_intercept_date'] ? $row['mb_intercept_date'] : date("Ymd", G4_SERVER_TIME); - $mb_id = $row['mb_id']; - if ($row['mb_leave_date']) - $mb_id = "$mb_id"; - else if ($row['mb_intercept_date']) - $mb_id = "$mb_id"; + $mb_nick = get_sideview($row['mb_id'], $row['mb_nick'], $row['mb_email'], $row['mb_homepage']); - $list = $i%2; - echo " - - - - - - - - - - - - - - "; -} + $mb_id = $row['mb_id']; + if ($row['mb_leave_date']) + $mb_id = $mb_id; + else if ($row['mb_intercept_date']) + $mb_id = $mb_id; -if ($i == 0) - echo ""; - -echo ""; -echo "
    회원아이디이름별명권한포인트수신공개인증차단그룹
     $mb_id$row[mb_name]$mb_nick$row[mb_level]".number_format($row['mb_point'])." ".substr($row['mb_today_login'],2,8)."".($row['mb_mailling']?'√':' ')."".($row['mb_open']?'√':' ')."".(preg_match('/[1-9]/', $row['mb_email_certify'])?'√':' ')."".($row['mb_intercept_date']?'√':' ')."$group
    자료가 없습니다.
    "; -?> + ?> + + + +
    + + + + + + + + + 자료가 없습니다.'; + ?> + + + +
    a.wr_parent "; } $sql_order = " order by a.bn_id desc "; -$sql = " select count(*) as cnt $sql_common "; +$sql = " select count(*) as cnt {$sql_common} "; $row = sql_fetch($sql); $total_count = $row['cnt']; $colspan = 5; ?> -

    - +
    +

    최근게시물

    +

    사이트 전체게시물 중 최근게시물 건 목록

    - - - - - - ------ - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - - - - "; -} - -if ($i == 0) - echo ""; - -echo ""; -echo "
    그룹게시판제목이름일시
    그룹게시판제목이름일시
    ".cut_str($row['gr_subject'],10)."".cut_str($row['bo_subject'],20)." {$comment}".conv_subject($row2['wr_subject'], 100)."$name$datetime
    자료가 없습니다.
    "; -?> - + if ($i == 0) + echo '자료가 없습니다.'; + ?> + + + +
    -

    - +
    +

    최근 포인트 발생내역

    +

    전체 건 중 건 목록

    - - - - - -
    - (건수 : ) - - -
    - - - - - - - -------- - - - - - - - - - - - + + + + + + + + + + + + + '; + $link2 = ''; + } + ?> + + + + + + + + + + + + "; - $link2 = ""; - } - - $list = $i%2; - echo " - - - - - - - - - - - "; -} - -if ($i == 0) - echo ""; - -echo ""; -echo "
    회원아이디이름별명일시포인트 내용포인트포인트합
    회원아이디이름별명일시포인트 내용포인트포인트합
    $row[mb_id]$row2[mb_name]$mb_nick$row[po_datetime] {$link1}$row[po_content]{$link2}".number_format($row['po_point'])." ".number_format($row2['mb_point'])." 
    자료가 없습니다.
    "; -?> - + if ($i == 0) + echo '자료가 없습니다.'; + ?> + + + +
    diff --git a/adm/mail_delete.php b/adm/mail_delete.php new file mode 100644 index 000000000..cc8ce6b30 --- /dev/null +++ b/adm/mail_delete.php @@ -0,0 +1,24 @@ + \ No newline at end of file diff --git a/adm/mail_form.php b/adm/mail_form.php index ef73b7ad8..8d8ca80d4 100644 --- a/adm/mail_form.php +++ b/adm/mail_form.php @@ -1,82 +1,80 @@ - - -
    - - - - --- - - - - - - - - - - - - -
    메일 제목
    메일 내용 - - -
    {이름} , {별명} , {회원아이디} , {이메일} , {생일} -
    위와 같이 HTML 코드에 삽입하면 해당 내용에 맞게 변환하여 메일 발송합니다. -
    - -

    - -

    - - - - - - + + +
    +

    메일 내용에 {이름} , {별명} , {회원아이디} , {이메일} 처럼 내용에 삽입하면 해당 내용에 맞게 변환하여 메일을 발송합니다.

    + +
    + + + + + + + + + + + + + + + + + + +
    + +
    + +
    +
    +
    + + + + diff --git a/adm/mail_list.php b/adm/mail_list.php index 5bc0ce0a0..f748818a3 100644 --- a/adm/mail_list.php +++ b/adm/mail_list.php @@ -1,99 +1,103 @@ - - - - - - -
      건수 :  
    +
    +

    등록된 메일내용 목록

    +

    + 테스트는 등록된 최고관리자의 이메일로 테스트 메일을 발송합니다.
    + 현재 등록된 메일은 총 건입니다. +

    + - - - - - - - - - - - + +
    ID제목작성일시테스트보내기
    + + + + + + + + + + + + + 삭제'; + $s_vie = '미리보기'; -"; - $s_vie = icon("보기", "./mail_preview.php?ma_id=$row[ma_id]", "_blank"); + $num = number_format($total_count - ($page - 1) * $config['cf_page_rows'] - $i); + ?> - $num = number_format($total_count - ($page - 1) * $config[cf_page_rows] - $i); + + + + + + + + + - $list = $i%2; - echo " - - - - - - - - "; -} + "; + ?> + +
    번호제목작성일시테스트보내기미리보기
    + + 테스트보내기
    $num$row[ma_subject]$row[ma_time]테스트보내기$s_mod $s_del $s_vie
    자료가 없습니다.
    -if (!$i) - echo "자료가 없습니다."; -?> - - +
    + +
    + +
    -
    - - - - - - - -
    - \ No newline at end of file diff --git a/adm/mail_preview.php b/adm/mail_preview.php index 1abc8e63d..c56de9546 100644 --- a/adm/mail_preview.php +++ b/adm/mail_preview.php @@ -1,16 +1,34 @@

    ▶ 더 이상 정보 수신을 원치 않으시면 [수신거부] 해 주십시오.

    "; +$subject = $se['ma_subject']; +$content = $se['ma_content'] . "

    ▶ 더 이상 정보 수신을 원치 않으시면 [수신거부] 해 주십시오.

    "; +?> -echo "$subject"; -echo "
    "; -echo $content; -?> \ No newline at end of file + + + + +그누보드 메일발송 테스트 + + + + +

    + +

    + +

    + +

    + 주의! 이 화면에 보여지는 디자인은 실제 내용이 발송되었을 때 디자인과 다를 수 있습니다. +

    + + + \ No newline at end of file diff --git a/adm/mail_select_form.php b/adm/mail_select_form.php index a3869dc25..a750129af 100644 --- a/adm/mail_select_form.php +++ b/adm/mail_select_form.php @@ -1,192 +1,121 @@ - '' "; -$row = sql_fetch($sql); -$finish_cnt = $row[cnt]; - -$last_option = explode("||", $ma[ma_last_option]); -for ($i=0; $i - - - - - - - - -
    전체회원수 : 명 , 탈퇴대기회원수 : 명 , 정상회원수 :
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    회원 ID - > 전체 - > 구간 -
    - 에서 - 까지 - - -
    생일 - 부터 - 까지 (예 : 5월5일 인 경우, 0505 와 같이 입력 , 둘다 입력해야함)
    E-mail에 단어 포함 (예 : @sir.co.kr)
    성별 - - -
    지역 - - -
    메일링 - - -
    권한 - 에서 - 까지 - - -
    게시판그룹회원 - - -
    - -

    -   - - -

    - - - + '' "; +$row = sql_fetch($sql); +$finish_cnt = $row['cnt']; + +$last_option = explode('||', $ma['ma_last_option']); +for ($i=0; $i + +
    +

    메일발송대상 선택

    +

    + 전체회원 명 , 탈퇴대기회원 명, 정상회원 명 중 메일 발송 대상 선택 +

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + +
    회원 ID + > + > + 에서 + 까지 +
    + + +
    + +
    + 에서 + 까지 +
    + +
    + +
    + + 목록 +
    +
    +
    + + diff --git a/adm/mail_select_list.php b/adm/mail_select_list.php index b2b04faf8..985a72c78 100644 --- a/adm/mail_select_list.php +++ b/adm/mail_select_list.php @@ -1,60 +1,44 @@ -
    +
    +

    조건에 따라 선택된 메일발송 대상자 목록입니다.

    -

    +

    + + + + + + + + + + + + + + + + + + + + + + + + + + +
    번호회원아이디이름별명생일E-mail
    +
    -
    선택된 회원수 :
    - - - - - - - -
    - - -
    +
    + + 뒤로 +
    -

    -   - -

    - - - diff --git a/adm/mail_select_update.php b/adm/mail_select_update.php index 4466daadc..f35dad71e 100644 --- a/adm/mail_select_update.php +++ b/adm/mail_select_update.php @@ -1,17 +1,17 @@ ";

    ▶ 더 이상 정보 수신을 원치 않으시면 [수신거부] 해 주십시오.

    "; + $content = $content . "

    ▶ 더 이상 정보 수신을 원치 않으시면 [수신거부] 해 주십시오.

    "; - /* - ob_start(); - include "$mail_skin/mail.skin.php"; - $content = ob_get_contents(); - ob_end_clean(); - */ - - //mailer($default[de_subject], $default[de_admin_email], $email, $subject, $content, 1); - mailer($config[cf_title], $member[mb_email], $email, $subject, $content, 1); + mailer($config['cf_title'], $from_email, $email, $subject, $content, 1); echo "\n"; //echo "+"; @@ -82,7 +75,7 @@ for ($i=0; $i document.all.cont.innerHTML += '
    '; document.body.scrollTop += 1000; \n"; } diff --git a/adm/mail_test.php b/adm/mail_test.php index f61a4c4ae..feb4208b8 100644 --- a/adm/mail_test.php +++ b/adm/mail_test.php @@ -1,41 +1,39 @@

    ▶ 더 이상 정보 수신을 원치 않으시면 [수신거부] 해 주십시오.

    "; +$content = $content . '

    더 이상 정보 수신을 원치 않으시면 [수신거부] 해 주십시오.

    '; -mailer($config[cf_title], $member[mb_email], $member[mb_email], $subject, $content, 1); +mailer($config['cf_title'], $member['mb_email'], $member['mb_email'], $subject, $content, 1); -alert("$member[mb_nick]($member[mb_email])님께 테스트 메일을 발송하였습니다.\\n\\n확인하여 주십시오."); +alert($member['mb_nick'].'('.$member['mb_email'].')님께 테스트 메일을 발송하였습니다. 확인하여 주십시오.'); ?> diff --git a/adm/mail_update.php b/adm/mail_update.php index 1efa03a32..f7af623e9 100644 --- a/adm/mail_update.php +++ b/adm/mail_update.php @@ -1,39 +1,39 @@ diff --git a/adm/member_form.php b/adm/member_form.php index 817d9b60c..5c38d498f 100644 --- a/adm/member_form.php +++ b/adm/member_form.php @@ -1,262 +1,298 @@ 필수'; - $mb[mb_mailling] = 1; - $mb[mb_open] = 1; - $mb[mb_level] = $config[cf_register_level]; - $html_title = "등록"; + $mb['mb_mailling'] = 1; + $mb['mb_open'] = 1; + $mb['mb_level'] = $config['cf_register_level']; + $html_title = '추가'; } -else if ($w == "u") +else if ($w == 'u') { $mb = get_member($mb_id); - if (!$mb[mb_id]) - alert("존재하지 않는 회원자료입니다."); + if (!$mb['mb_id']) + alert('존재하지 않는 회원자료입니다.'); - if ($is_admin != 'super' && $mb[mb_level] >= $member[mb_level]) - alert("자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다."); + if ($is_admin != 'super' && $mb['mb_level'] >= $member['mb_level']) + alert('자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다.'); - $required_mb_id = "readonly style='background-color:#dddddd;'"; - $required_mb_password = ""; - $html_title = "수정"; + $required_mb_id = 'readonly'; + $required_mb_password = ''; + $html_title = '수정'; - $mb[mb_email] = get_text($mb[mb_email]); - $mb[mb_homepage] = get_text($mb[mb_homepage]); - $mb[mb_password_q] = get_text($mb[mb_password_q]); - $mb[mb_password_a] = get_text($mb[mb_password_a]); - $mb[mb_birth] = get_text($mb[mb_birth]); - $mb[mb_tel] = get_text($mb[mb_tel]); - $mb[mb_hp] = get_text($mb[mb_hp]); - $mb[mb_addr1] = get_text($mb[mb_addr1]); - $mb[mb_addr2] = get_text($mb[mb_addr2]); - $mb[mb_signature] = get_text($mb[mb_signature]); - $mb[mb_recommend] = get_text($mb[mb_recommend]); - $mb[mb_profile] = get_text($mb[mb_profile]); - $mb[mb_1] = get_text($mb[mb_1]); - $mb[mb_2] = get_text($mb[mb_2]); - $mb[mb_3] = get_text($mb[mb_3]); - $mb[mb_4] = get_text($mb[mb_4]); - $mb[mb_5] = get_text($mb[mb_5]); - $mb[mb_6] = get_text($mb[mb_6]); - $mb[mb_7] = get_text($mb[mb_7]); - $mb[mb_8] = get_text($mb[mb_8]); - $mb[mb_9] = get_text($mb[mb_9]); - $mb[mb_10] = get_text($mb[mb_10]); -} -else - alert("제대로 된 값이 넘어오지 않았습니다."); + $mb['mb_email'] = get_text($mb['mb_email']); + $mb['mb_homepage'] = get_text($mb['mb_homepage']); + $mb['mb_password_q'] = get_text($mb['mb_password_q']); + $mb['mb_password_a'] = get_text($mb['mb_password_a']); + $mb['mb_birth'] = get_text($mb['mb_birth']); + $mb['mb_tel'] = get_text($mb['mb_tel']); + $mb['mb_hp'] = get_text($mb['mb_hp']); + $mb['mb_addr1'] = get_text($mb['mb_addr1']); + $mb['mb_addr2'] = get_text($mb['mb_addr2']); + $mb['mb_signature'] = get_text($mb['mb_signature']); + $mb['mb_recommend'] = get_text($mb['mb_recommend']); + $mb['mb_profile'] = get_text($mb['mb_profile']); + $mb['mb_1'] = get_text($mb['mb_1']); + $mb['mb_2'] = get_text($mb['mb_2']); + $mb['mb_3'] = get_text($mb['mb_3']); + $mb['mb_4'] = get_text($mb['mb_4']); + $mb['mb_5'] = get_text($mb['mb_5']); + $mb['mb_6'] = get_text($mb['mb_6']); + $mb['mb_7'] = get_text($mb['mb_7']); + $mb['mb_8'] = get_text($mb['mb_8']); + $mb['mb_9'] = get_text($mb['mb_9']); + $mb['mb_10'] = get_text($mb['mb_10']); +} +else + alert('제대로 된 값이 넘어오지 않았습니다.'); -if ($mb[mb_mailling]) $mailling_checked = "checked"; // 메일 수신 -if ($mb[mb_sms]) $sms_checked = "checked"; // SMS 수신 -if ($mb[mb_open]) $open_checked = "checked"; // 정보 공개 +$mailling_no_checked = ''; +$sms_no_checked = ''; +$open_no_checked = ''; +if ($mb['mb_mailling'] == 1) { + $mailling_checked = 'checked="checked"'; //메일수신 +} else { + $mailing_checked = ''; + $mailling_no_checked = 'checked="checked"'; +} -$g4[title] = "회원정보 " . $html_title; -include_once("./admin.head.php"); +if ($mb['mb_sms']) { + $sms_checked = 'checked="checked"'; // SMS 수신 +} else { + $sms_checked = ''; + $sms_no_checked = 'checked="checked"'; +} + +if ($mb['mb_open']) { + $open_checked = 'checked="checked"'; // 정보 공개 +} else { + $open_checked = ''; + $open_no_checked = 'checked="checked"'; +} + +if(!isset($mb['mb_adult'])) { + sql_query(" ALTER TABLE `{$g4['member_table']}` + ADD `mb_adult` ENUM('Y', 'N') NOT NULL DEFAULT 'N' AFTER `mb_birth`, + ADD `mb_hp_certify` DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `mb_lost_certify` ", FALSE); +} + +if ($mb['mb_intercept_date']) $g4['title'] = "차단된 "; +else $g4['title'] .= ""; +$g4['title'] .= '회원 '.$html_title; +include_once('./admin.head.php'); ?> - - - - - - - - - ----- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + - - - - - - - - - - - - - - - - - +
    +
    아이디 - itemname='아이디' value=''> - 접근가능그룹보기 - 패스워드 itemname='암호'>
    이름(실명)별명
    회원 권한포인트
    E-mail홈페이지
    전화번호핸드폰번호
    주소 - - - - -
    -
    상세주소 입력
    회원아이콘 -
    이미지 크기는 x으로 해주세요. - "; - echo " 삭제"; - } - ?> -
    생년월일남녀 - -
    메일 수신> 정보 메일을 받음SMS 수신> 문자메세지를 받음
    정보 공개> 타인에게 자신의 정보를 공개
    서명자기 소개
    메모
    회원가입일최근접속일
    IP인증일시 - 수동인증"; } ?>
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    + class="frm_input " size="15" maxlength="20" > + 접근가능그룹보기 + class="frm_input " size="15" maxlength="20">
    포인트
    + - + + 우편번호 검색
    +
    + 상세주소 입력 +
    + 넓이 '.$config['cf_member_icon_width'].'픽셀 높이 '.$config['cf_member_icon_height'].'픽셀로 해주세요.')?> + + '; + echo '삭제'; + } + ?> +
    메일 수신 + > + + > + + + > + + > + +
    + > + + > + +
    회원가입일최근접속일
    IP
    인증일시 + + + + + + + + +
    추천인
    탈퇴일자접근차단일자 오늘
    여분 필드 여분 필드
    - -
    - 관리자 패스워드 - - - -
    - -

    -   -   - - -   + + + 추천인 + + + + + 탈퇴일자 + + + " title="탈퇴일을 오늘로 지정" onclick="if (this.form.mb_leave_date.value==this.form.mb_leave_date.defaultValue) { this.form.mb_leave_date.value=this.value; } else { this.form.mb_leave_date.value=this.form.mb_leave_date.defaultValue; }"> 오늘 + + 접근차단일자 + + + " title="접근차단일을 오늘로 지정" onclick="if (this.form.mb_intercept_date.value==this.form.mb_intercept_date.defaultValue) { this.form.mb_intercept_date.value=this.value; } else { this.form.mb_intercept_date.value=this.form.mb_intercept_date.defaultValue; }"> 오늘 + + + + + + + + + + + + + + + +

    + XSS 혹은 CSRF 방지 +

    관리자 권한을 탈취 당하는 경우를 대비하여 관리자의 패스워드를 다시 한번 확인합니다.

    + + +
    + +
    + + 목록 +
    - diff --git a/adm/member_form_update.php b/adm/member_form_update.php index dbfd1e3b3..9b3d5c9b4 100644 --- a/adm/member_form_update.php +++ b/adm/member_form_update.php @@ -1,103 +1,124 @@ '$mb_id' "; - if ($mb[mb_nick] == $mb_nick) - alert("이미 존재하는 별명입니다.\\n\\nID : $mb[mb_id]\\n\\n이름 : $mb[mb_name]\\n\\n별명 : $mb[mb_nick]\\n\\n메일 : $mb[mb_email]"); - - if ($mb[mb_email] == $mb_email) - alert("이미 존재하는 E-mail 입니다.\\n\\nID : $mb[mb_id]\\n\\n이름 : $mb[mb_name]\\n\\n별명 : $mb[mb_nick]\\n\\n메일 : $mb[mb_email]"); - - sql_query(" insert into $g4[member_table] set mb_id = '$mb_id', mb_password = '".sql_password($mb_password)."', mb_datetime = '$g4[time_ymdhis]', mb_ip = '$_SERVER[REMOTE_ADDR]', mb_email_certify = '$g4[time_ymdhis]', $sql_common "); + $row = sql_fetch($sql); + if($row['cnt']) + alert('다른 회원이 사용 중인 핸드폰번호입니다.'); } -else if ($w == "u") + +$sql_common = " mb_name = '{$_POST['mb_name']}', + mb_nick = '{$_POST['mb_nick']}', + mb_email = '{$_POST['mb_email']}', + mb_homepage = '{$_POST['mb_homepage']}', + mb_tel = '{$_POST['mb_tel']}', + mb_hp = '$mb_hp', + mb_zip1 = '{$_POST['mb_zip1']}', + mb_zip2 = '{$_POST['mb_zip2']}', + mb_addr1 = '{$_POST['mb_addr1']}', + mb_addr2 = '{$_POST['mb_addr2']}', + mb_birth = '{$_POST['mb_birth']}', + mb_sex = '{$_POST['mb_sex']}', + mb_signature = '{$_POST['mb_signature']}', + mb_leave_date = '{$_POST['mb_leave_date']}', + mb_intercept_date='{$_POST['mb_intercept_date']}', + mb_memo = '{$_POST['mb_memo']}', + mb_mailling = '{$_POST['mb_mailling']}', + mb_sms = '{$_POST['mb_sms']}', + mb_open = '{$_POST['mb_open']}', + mb_profile = '{$_POST['mb_profile']}', + mb_level = '{$_POST['mb_level']}', + mb_1 = '{$_POST['mb_1']}', + mb_2 = '{$_POST['mb_2']}', + mb_3 = '{$_POST['mb_3']}', + mb_4 = '{$_POST['mb_4']}', + mb_5 = '{$_POST['mb_5']}', + mb_6 = '{$_POST['mb_6']}', + mb_7 = '{$_POST['mb_7']}', + mb_8 = '{$_POST['mb_8']}', + mb_9 = '{$_POST['mb_9']}', + mb_10 = '{$_POST['mb_10']}' "; + +if ($w == '') { $mb = get_member($mb_id); - if (!$mb[mb_id]) - alert("존재하지 않는 회원자료입니다."); + if ($mb['mb_id']) + alert('이미 존재하는 회원입니다.\\nID : '.$mb['mb_id'].'\\n이름 : '.$mb['mb_name'].'\\n별명 : '.$mb['mb_nick'].'\\n메일 : '.$mb['mb_email']); - if ($is_admin != "super" && $mb[mb_level] >= $member[mb_level]) - alert("자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다."); + if ($mb['mb_nick'] == $mb_nick) + alert('이미 존재하는 별명입니다.\\nID : '.$mb['mb_id'].'\\n이름 : '.$mb['mb_name'].'\\n별명 : '.$mb['mb_nick'].'\\n메일 : '.$mb['mb_email']); - if ($_POST[mb_id] == $member[mb_id] && $_POST[mb_level] != $mb[mb_level]) - alert("$mb[mb_id] : 로그인 중인 관리자 레벨은 수정 할 수 없습니다."); + if ($mb['mb_email'] == $mb_email) + alert('이미 존재하는 E-mail 입니다.\\nID : '.$mb['mb_id'].'\\n이름 : '.$mb['mb_name'].'\\n별명 : '.$mb['mb_nick'].'\\n메일 : '.$mb['mb_email']); + + sql_query(" insert into {$g4['member_table']} set mb_id = '{$mb_id}', mb_password = '".sql_password($mb_password)."', mb_datetime = '".G4_TIME_YMDHIS."', mb_ip = '{$_SERVER['REMOTE_ADDR']}', mb_email_certify = '".G4_TIME_YMDHIS."', {$sql_common} "); +} +else if ($w == 'u') +{ + $mb = get_member($mb_id); + if (!$mb['mb_id']) + alert('존재하지 않는 회원자료입니다.'); + + if ($is_admin != 'super' && $mb['mb_level'] >= $member['mb_level']) + alert('자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다.'); + + if ($_POST['mb_id'] == $member['mb_id'] && $_POST['mb_level'] != $mb['mb_level']) + alert($mb['mb_id'].' : 로그인 중인 관리자 레벨은 수정 할 수 없습니다.'); $mb_dir = substr($mb_id,0,2); // 회원 아이콘 삭제 if ($del_mb_icon) - @unlink("$g4[path]/data/member/$mb_dir/$mb_id.gif"); + @unlink(G4_DATA_PATH.'/member/'.$mb_dir.'/'.$mb_id.'.gif'); // 아이콘 업로드 - if (is_uploaded_file($_FILES[mb_icon][tmp_name])) { - if (!preg_match("/(\.gif)$/i", $_FILES[mb_icon][name])) { - alert($_FILES[mb_icon][name] . '은(는) gif 파일이 아닙니다.'); + if (is_uploaded_file($_FILES['mb_icon']['tmp_name'])) { + if (!preg_match("/(\.gif)$/i", $_FILES['mb_icon']['name'])) { + alert($_FILES['mb_icon']['name'] . '은(는) gif 파일이 아닙니다.'); } - if (preg_match("/(\.gif)$/i", $_FILES[mb_icon][name])) { - @mkdir("$g4[path]/data/member/$mb_dir", 0707); - @chmod("$g4[path]/data/member/$mb_dir", 0707); + if (preg_match("/(\.gif)$/i", $_FILES['mb_icon']['name'])) { + @mkdir(G4_DATA_PATH.'/member/'.$mb_dir, 0707); + @chmod(G4_DATA_PATH.'/member/'.$mb_dir, 0707); - $dest_path = "$g4[path]/data/member/$mb_dir/$mb_id.gif"; + $dest_path = G4_DATA_PATH.'/member/'.$mb_dir.'/'.$mb_id.'.gif'; - move_uploaded_file($_FILES[mb_icon][tmp_name], $dest_path); + move_uploaded_file($_FILES['mb_icon']['tmp_name'], $dest_path); chmod($dest_path, 0606); if (file_exists($dest_path)) { $size = getimagesize($dest_path); // 아이콘의 폭 또는 높이가 설정값 보다 크다면 이미 업로드 된 아이콘 삭제 - if ($size[0] > $config[cf_member_icon_width] || $size[1] > $config[cf_member_icon_height]) { + if ($size[0] > $config['cf_member_icon_width'] || $size[1] > $config['cf_member_icon_height']) { @unlink($dest_path); } } @@ -110,19 +131,19 @@ else if ($w == "u") $sql_password = ""; if ($passive_certify) - $sql_certify = " , mb_email_certify = '$g4[time_ymdhis]' "; + $sql_certify = " , mb_email_certify = '".G4_TIME_YMDHIS."' "; else $sql_certify = ""; - $sql = " update $g4[member_table] - set $sql_common - $sql_password - $sql_certify - where mb_id = '$mb_id' "; + $sql = " update {$g4['member_table']} + set {$sql_common} + {$sql_password} + {$sql_certify} + where mb_id = '{$mb_id}' "; sql_query($sql); } else - alert("제대로 된 값이 넘어오지 않았습니다."); + alert('제대로 된 값이 넘어오지 않았습니다.'); -goto_url("./member_form.php?$qstr&w=u&mb_id=$mb_id", false); +goto_url('./member_form.php?'.$qstr.'&w=u&mb_id='.$mb_id, false); ?> \ No newline at end of file diff --git a/adm/member_list.php b/adm/member_list.php index f436df451..6dac453aa 100644 --- a/adm/member_list.php +++ b/adm/member_list.php @@ -1,263 +1,242 @@ = '$stx') "; + case 'mb_point' : + $sql_search .= " ({$sfl} >= '{$stx}') "; break; - case "mb_level" : - $sql_search .= " ($sfl = '$stx') "; + case 'mb_level' : + $sql_search .= " ({$sfl} = '{$stx}') "; break; - case "mb_tel" : - case "mb_hp" : - $sql_search .= " ($sfl like '%$stx') "; + case 'mb_tel' : + case 'mb_hp' : + $sql_search .= " ({$sfl} like '%{$stx}') "; break; default : - $sql_search .= " ($sfl like '$stx%') "; + $sql_search .= " ({$sfl} like '{$stx}%') "; break; } $sql_search .= " ) "; } -//if ($is_admin == 'group') $sql_search .= " and mb_level = '$member[mb_level]' "; -if ($is_admin != 'super') - $sql_search .= " and mb_level <= '$member[mb_level]' "; +if ($is_admin != 'super') + $sql_search .= " and mb_level <= '{$member['mb_level']}' "; if (!$sst) { $sst = "mb_datetime"; $sod = "desc"; } -$sql_order = " order by $sst $sod "; +$sql_order = " order by {$sst} {$sod} "; -$sql = " select count(*) as cnt - $sql_common - $sql_search - $sql_order "; +$sql = " select count(*) as cnt {$sql_common} {$sql_search} {$sql_order} "; $row = sql_fetch($sql); -$total_count = $row[cnt]; +$total_count = $row['cnt']; -$rows = $config[cf_page_rows]; +$rows = $config['cf_page_rows']; $total_page = ceil($total_count / $rows); // 전체 페이지 계산 if (!$page) $page = 1; // 페이지가 없으면 첫 페이지 (1 페이지) $from_record = ($page - 1) * $rows; // 시작 열을 구함 // 탈퇴회원수 -$sql = " select count(*) as cnt - $sql_common - $sql_search - and mb_leave_date <> '' - $sql_order "; +$sql = " select count(*) as cnt {$sql_common} {$sql_search} and mb_leave_date <> '' {$sql_order} "; $row = sql_fetch($sql); -$leave_count = $row[cnt]; +$leave_count = $row['cnt']; // 차단회원수 -$sql = " select count(*) as cnt - $sql_common - $sql_search - and mb_intercept_date <> '' - $sql_order "; +$sql = " select count(*) as cnt {$sql_common} {$sql_search} and mb_intercept_date <> '' {$sql_order} "; $row = sql_fetch($sql); -$intercept_count = $row[cnt]; +$intercept_count = $row['cnt']; -$listall = "처음"; +$listall = ""; +if (isset($sfl) || isset($stx)) // 검색일 때만 처음 버튼을 보여줌 + $listall = '전체목록'; -$g4[title] = "회원관리"; -include_once("./admin.head.php"); +$g4['title'] = '회원관리'; +include_once('./admin.head.php'); -$sql = " select * - $sql_common - $sql_search - $sql_order - limit $from_record, $rows "; +$sql = " select * {$sql_common} {$sql_search} {$sql_order} limit {$from_record}, {$rows} "; $result = sql_query($sql); $colspan = 15; ?> - - - - - - - - - + +
    + 회원검색 + + + 총회원수 명 중, + 차단 명, + 탈퇴 명 + + + + +
    -
    - (총회원수 : , - 차단 : , - 탈퇴 : ) - - - -
    -
    - - - - - - +
    +

    회원 목록

    +

    회원자료 삭제 시 다른 회원이 기존 회원아이디를 사용하지 못하도록 회원아이디, 이름, 별명은 삭제하지 않고 영구 보관합니다.

    - -------------- - - - - - - - - - - - - - - - - - -$row2[cnt]"; + + + - if ($is_admin == 'group') - { - $s_mod = ""; - $s_del = ""; - } - else - { - $s_mod = ""; - //$s_del = ""; - $s_del = ""; + + + + + + + +
    회원아이디이름별명권한포인트최종접속수신공개인증차단그룹
    + + + + + + + + + + + + + + + + + + + '.$row2['cnt'].''; + + if ($is_admin == 'group') + { + $s_mod = ''; + $s_del = ''; + } + else + { + $s_mod = '수정'; + //$s_del = '삭제'; + } + $s_grp = '그룹'; + + $leave_date = $row['mb_leave_date'] ? $row['mb_leave_date'] : date('Ymd', G4_SERVER_TIME); + $intercept_date = $row['mb_intercept_date'] ? $row['mb_intercept_date'] : date('Ymd', G4_SERVER_TIME); + + $mb_nick = get_sideview($row['mb_id'], $row['mb_nick'], $row['mb_email'], $row['mb_homepage']); + + $mb_id = $row['mb_id']; + $leave_msg = ''; + $intercept_msg = ''; + $intercept_title = ''; + if ($row['mb_leave_date']) { + $mb_id = $mb_id; + $leave_msg = '
    탈퇴함'; + } + else if ($row['mb_intercept_date']) { + $mb_id = $mb_id; + $intercept_msg = '
    차단됨'; + $intercept_title = '차단해제'; + } + if ($intercept_title == '') + $intercept_title = '차단하기'; + ?> + + + + + + + + + + + + + + + + + + "; + if ($i == 0) + echo ""; + ?> +
    회원아이디별명이름권한 포인트최종접속수신공개인증차단그룹관리
    + + + + + +
    Yes':'No';?>Yes':'No';?>Yes':'No';?> + + value="" id="mb_intercept_date_" title=""> + +
    자료가 없습니다.
    - $leave_date = $row[mb_leave_date] ? $row[mb_leave_date] : date("Ymd", $g4[server_time]); - $intercept_date = $row[mb_intercept_date] ? $row[mb_intercept_date] : date("Ymd", $g4[server_time]); +
    + + + 회원추가 +
    - $mb_nick = get_sideview($row[mb_id], $row[mb_nick], $row[mb_email], $row[mb_homepage]); + +
    - $mb_id = $row[mb_id]; - if ($row[mb_leave_date]) - $mb_id = "$mb_id"; - else if ($row[mb_intercept_date]) - $mb_id = "$mb_id"; - - $list = $i%2; - echo " - - - -  $mb_id - $row[mb_name] - $mb_nick - ".get_member_level_select("mb_level[$i]", 1, $member[mb_level], $row[mb_level])." - ".number_format($row[mb_point])."  - ".substr($row[mb_today_login],2,8)." - ".($row[mb_mailling]?'√':' ')." - ".($row[mb_open]?'√':' ')." - - ".(preg_match('/[1-9]/', $row[mb_email_certify])?'√':' ')." - - $group - $s_mod $s_del $s_grp - "; -} - -if ($i == 0) - echo "자료가 없습니다."; - -echo ""; -echo ""; - -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "?$qstr&page="); -echo ""; -echo ""; -echo "
    "; -echo " "; -echo ""; -echo "$pagelist
    \n"; - -if ($stx) - echo "\n"; -?> - - -* 회원자료 삭제시 다른 회원이 기존 회원아이디를 사용하지 못하도록 회원아이디, 이름, 별명은 삭제하지 않고 영구 보관합니다. + -
    - - - - - - - -
    - diff --git a/adm/member_list_update.php b/adm/member_list_update.php index adafd044c..38fa9a048 100644 --- a/adm/member_list_update.php +++ b/adm/member_list_update.php @@ -1,37 +1,66 @@ = $member[mb_level]) { - $msg .= "$mb[mb_id] : 자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다.\\n"; - } else if ($member[mb_id] == $mb[mb_id]) { - $msg .= "$mb[mb_id] : 로그인 중인 관리자는 수정 할 수 없습니다.\\n"; - } else { - $sql = " update $g4[member_table] - set mb_level = '{$_POST['mb_level'][$k]}', - mb_intercept_date = '{$_POST['mb_intercept_date'][$k]}' - where mb_id = '{$_POST['mb_id'][$k]}' "; - sql_query($sql); + $mb = get_member($_POST['mb_id'][$k]); + + if (!$mb['mb_id']) { + $msg .= $mb['mb_id'].' : 회원자료가 존재하지 않습니다.\\n'; + } else if ($is_admin != 'super' && $mb['mb_level'] >= $member['mb_level']) { + $msg .= $mb['mb_id'].' : 자신보다 권한이 높거나 같은 회원은 수정할 수 없습니다.\\n'; + } else if ($member['mb_id'] == $mb['mb_id']) { + $msg .= $mb['mb_id'].' : 로그인 중인 관리자는 수정 할 수 없습니다.\\n'; + } else { + $sql = " update {$g4['member_table']} + set mb_level = '{$_POST['mb_level'][$k]}', + mb_intercept_date = '{$_POST['mb_intercept_date'][$k]}' + where mb_id = '{$_POST['mb_id'][$k]}' "; + sql_query($sql); + } + } + +} else if ($_POST['act_button'] == "선택삭제") { + + for ($i=0; $i= $member['mb_level']) { + $msg .= $mb['mb_id'].' : 자신보다 권한이 높거나 같은 회원은 삭제할 수 없습니다.\\n'; + } else { + // 회원자료 삭제 + member_delete($mb['mb_id']); + } } } if ($msg) - echo ""; + //echo ''; + alert($msg); -goto_url("./member_list.php?$qstr"); +goto_url('./member_list.php?'.$qstr); ?> diff --git a/adm/phpinfo.php b/adm/phpinfo.php index 6aef555ca..741a9a34e 100644 --- a/adm/phpinfo.php +++ b/adm/phpinfo.php @@ -1,10 +1,10 @@ \ No newline at end of file diff --git a/adm/point_clear.php b/adm/point_clear.php index 2d2623e1d..3006816d2 100644 --- a/adm/point_clear.php +++ b/adm/point_clear.php @@ -1,58 +1,58 @@ "; -include_once("./admin.tail.php"); +$g4['title'] = '포인트 정리'; +include_once('./admin.head.php'); +echo ''; +include_once('./admin.tail.php'); flush(); -echo "\n"; +echo ''."\n"; flush(); $max_count = 50; // 테이블 락을 걸고 -$sql = " LOCK TABLES $g4[member_table] WRITE, $g4[point_table] WRITE "; +$sql = " LOCK TABLES {$g4['member_table']} WRITE, {$g4['point_table']} WRITE "; sql_query($sql); $sql = " select mb_id, count(po_point) as cnt - from $g4[point_table] - group by mb_id - having cnt > {$max_count}+1 - order by cnt "; + from {$g4['point_table']} + group by mb_id + having cnt > {$max_count}+1 + order by cnt "; $result = sql_query($sql); -for ($i=0; $row=sql_fetch_array($result); $i++) +for ($i=0; $row=sql_fetch_array($result); $i++) { $count = 0; $total = 0; $sql2 = " select po_id, po_point - from $g4[point_table] - where mb_id = '$row[mb_id]' - order by po_id desc - limit $max_count, $row[cnt] "; + from {$g4['point_table']} + where mb_id = '{$row['mb_id']}' + order by po_id desc + limit {$max_count}, {$row['cnt']} "; $result2 = sql_query($sql2); for ($k=0; $row2=sql_fetch_array($result2); $k++) { $count++; - $total += $row2[po_point]; + $total += $row2['po_point']; - sql_query(" delete from $g4[point_table] where po_id = '$row2[po_id]' "); + sql_query(" delete from {$g4['point_table']} where po_id = '{$row2['po_id']}' "); } - insert_point($row[mb_id], $total, "포인트 {$count}건 정리", "@clear", $row[mb_id], $g4[time_ymd]."-".uniqid("")); + insert_point($row['mb_id'], $total, '포인트 {$count}건 정리', '@clear', $row['mb_id'], G4_TIME_YMD."-".uniqid("")); - $str = $row[mb_id]."님 포인트 내역 ".number_format($count)."건 ".number_format($total)."점 정리
    "; - echo "\n"; + $str = $row['mb_id']."님 포인트 내역 ".number_format($count)."건 ".number_format($total)."점 정리
    "; + echo ''."\n"; flush(); } @@ -60,5 +60,5 @@ for ($i=0; $row=sql_fetch_array($result); $i++) $sql = " UNLOCK TABLES "; sql_query($sql); -echo "\n"; +echo ''."\n"; ?> diff --git a/adm/point_list.php b/adm/point_list.php index 7b614afa5..4781ee3fb 100644 --- a/adm/point_list.php +++ b/adm/point_list.php @@ -1,22 +1,22 @@ 처음"; +$listall = ''; +if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 + $listall = '전체목록'; -if ($sfl == "mb_id" && $stx) - $mb = get_member($stx); +$mb = array(); +if ($sfl == 'mb_id' && $stx) + $mb = get_member(isset($stx)); -$g4[title] = "포인트관리"; -include_once ("./admin.head.php"); +$g4['title'] = '포인트관리'; +include_once ('./admin.head.php'); $colspan = 8; ?> - - - - - - - - - + + + + + + -
    - (건수 : ) - +
    + 포인트 내역 검색 + + + 전체 건 + - -
    - - -
    -
    - - - - - - +
    +

    포인트 내역

    - --------- - - - - - - - - - - - - + + + + + + + +
    회원아이디이름별명일시포인트 내용포인트포인트합
    + + + + + + + + + + + + + + '; + $link2 = ''; + } + ?> + + + + + + + + + + + + + '; + ?> + +
    회원아이디이름별명일시포인트 내용포인트포인트합
    + + + +
    자료가 없습니다.
    - $link1 = $link2 = ""; - if (!preg_match("/^\@/", $row[po_rel_table]) && $row[po_rel_table]) - { - $link1 = ""; - $link2 = ""; - } +
    + +
    - $list = $i%2; - echo " - - - - - $row[mb_id] - $row2[mb_name] - $mb_nick - $row[po_datetime] -  {$link1}$row[po_content]{$link2} - ".number_format($row[po_point])."  - ".number_format($row2[mb_point])."  - "; -} + +
    -if ($i == 0) - echo "자료가 없습니다."; + -echo ""; -echo ""; +
    +

    개별회원 포인트 증감 설정

    -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&page="); -echo ""; -echo ""; -echo "
    "; -echo ""; -echo "$pagelist
    \n"; +
    + + + + + + -if ($stx) - echo "\n"; + + + + + + + + + + + + + + + + + + + +
    -if (strstr($sfl, "mb_id")) - $mb_id = $stx; -else - $mb_id = ""; -?> -
    +
    + XSS 혹은 CSRF 방지 +

    관리자 권한을 탈취당하는 경우를 대비하여 패스워드를 다시 한번 확인합니다.

    + + +
    - +
    + +
    - -

    -

    - - - - - - - ------ - - - - - - - - - - - - - - - - - -
    회원아이디포인트 내용포인트관리자패스워드입력
    + - +
    diff --git a/adm/point_list_delete.php b/adm/point_list_delete.php index f2f43ab5a..7a3ac663e 100644 --- a/adm/point_list_delete.php +++ b/adm/point_list_delete.php @@ -1,28 +1,32 @@ diff --git a/adm/point_update.php b/adm/point_update.php index bf41d4d85..7f9c844dd 100644 --- a/adm/point_update.php +++ b/adm/point_update.php @@ -1,28 +1,28 @@ $mb[mb_point])) - alert("포인트를 깎는 경우 현재 포인트보다 작으면 안됩니다.", "./point_list.php?$qstr"); +if (($po_point < 0) && ($po_point * (-1) > $mb['mb_point'])) + alert('포인트를 깎는 경우 현재 포인트보다 작으면 안됩니다.', './point_list.php?'.$qstr); -insert_point($mb_id, $po_point, $po_content, '@passive', $mb_id, $member[mb_id]."-".uniqid("")); +insert_point($mb_id, $po_point, $po_content, '@passive', $mb_id, $member['mb_id']."-".uniqid("")); -goto_url("./point_list.php?$qstr"); +goto_url('./point_list.php?'.$qstr); ?> diff --git a/adm/poll_delete.php b/adm/poll_delete.php new file mode 100644 index 000000000..1252e4329 --- /dev/null +++ b/adm/poll_delete.php @@ -0,0 +1,27 @@ + \ No newline at end of file diff --git a/adm/poll_form.php b/adm/poll_form.php index 54f9fca3c..0642bf178 100644 --- a/adm/poll_form.php +++ b/adm/poll_form.php @@ -1,121 +1,110 @@ -
    - - - - - - - - - ----- - - - - - - - - - - - - - - +
    + + + + + + + + + +
    투표 제목
    항목{$i}투표수
    + + + + -HEREDOC; -} -?> - - - - + 필수'; + } - - - - + $po_poll = get_text($po['po_poll'.$i]); + ?> - - - - + + + + + - - - - - + + + + + + + + + + + + - - - - + + + + + + + + + + + + + + + +
    기타의견
    투표권한이상 투표할 수 있음
    포인트 점 (투표한 회원에게 부여함)
    + class="frm_input " maxlength="125"> + + +
    투표시작일
    + + +
    + + 이상 투표할 수 있음 +
    + + 점 +
    투표참가 IP
    - - 투표참가 회원 - - - - - - - - -

    -   - -

    - - +
    + + 목록 +
    + + diff --git a/adm/poll_form_update.php b/adm/poll_form_update.php index e65752703..22f1b54e9 100644 --- a/adm/poll_form_update.php +++ b/adm/poll_form_update.php @@ -1,70 +1,70 @@ diff --git a/adm/poll_list.php b/adm/poll_list.php index 3b5a89603..b828c347a 100644 --- a/adm/poll_list.php +++ b/adm/poll_list.php @@ -1,19 +1,19 @@ 처음"; +$listall = ''; +if ($sfl || $stx) // 검색렬일 때만 처음 버튼을 보여줌 + $listall = '전체목록'; -$g4[title] = "투표관리"; -include_once("./admin.head.php"); +$g4['title'] = '투표관리'; +include_once('./admin.head.php'); $colspan = 6; ?> - - - - - - + +
    + 투표검색 + + + 투표수 : 개 + + + + +
    -
    (투표수 : 개) - - -
    - ------- - - - - - - - - - - +

    투표목록

    - $s_mod = ""; - //$s_del = ""; - $s_del = ""; + - $list = $i%2; - echo " - - - - - - - - "; + + + + + + + +
    번호제목투표권한투표수기타의견
    $row[po_id] ".cut_str(get_text($row[po_subject]),70)."$row[po_level]$row2[sum_po_cnt]$po_etc$s_mod $s_del
    + + + + + + + + + + + + + 수정'; + //$s_del = '삭제'; + ?> -if ($i==0) - echo ""; + + + + + + + + + -echo ""; -echo "
    번호제목투표권한투표수기타의견관리
    자료가 없습니다.
    + +
    "; + $pagelist\n"; + if ($i==0) + echo '자료가 없습니다.'; + ?> + + -if ($stx) - echo "\n"; -?> +
    + +
    + + - + -
    - - - - - - - - -
    - \ No newline at end of file diff --git a/adm/popular_list.php b/adm/popular_list.php index 1d473e53a..1ff5ebac1 100644 --- a/adm/popular_list.php +++ b/adm/popular_list.php @@ -1,33 +1,32 @@ 처음"; +if (isset($stx)) + $listall = '전체목록'; -$g4[title] = "인기검색어관리"; -include_once("./admin.head.php"); +$g4['title'] = '인기검색어관리'; +include_once('./admin.head.php'); $colspan = 4; ?> - - - - - - - - -
    (건수 : 개) - - -
    - -
    - - - - - - - ----- - - - - - - - -"; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo "\n"; -} - -if ($i == 0) - echo ""; - -echo ""; -echo "
    검색어등록일등록IP
      $word$row[pp_date]$row[pp_ip]
    자료가 없습니다.
    "; - -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&page="); -echo ""; -echo ""; -echo "
    "; - -if ($is_admin == "super") - echo ""; - -echo "$pagelist
    \n"; - -if ($stx) - echo ""; -?> + +
    + 인기검색어 검색 + + + 건수 : 개 + + + + +
    +
    +

    인기검색어 목록

    + +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + '; + ?> + +
    검색어등록일등록IP
    + +  
    자료가 없습니다.
    + + +
    + +
    + + +
    +
    + + + + + diff --git a/adm/popular_rank.php b/adm/popular_rank.php index 32dad51d4..245e75ce2 100644 --- a/adm/popular_rank.php +++ b/adm/popular_rank.php @@ -1,178 +1,103 @@ '' and pp_date between '$fr_date' and '$to_date' "; +$sql_common = " from {$g4['popular_table']} a "; +$sql_search = " where trim(pp_word) <> '' and pp_date between '{$fr_date}' and '{$to_date}' "; $sql_group = " group by pp_word "; $sql_order = " order by cnt desc "; -$sql = " select pp_word - $sql_common - $sql_search - $sql_group "; +$sql = " select pp_word {$sql_common} {$sql_search} {$sql_group} "; $result = sql_query($sql); $total_count = mysql_num_rows($result); -$rows = $config[cf_page_rows]; +$rows = $config['cf_page_rows']; $total_page = ceil($total_count / $rows); // 전체 페이지 계산 -if ($page == "") { $page = 1; } // 페이지가 없으면 첫 페이지 (1 페이지) +if ($page == '') { $page = 1; } // 페이지가 없으면 첫 페이지 (1 페이지) $from_record = ($page - 1) * $rows; // 시작 열을 구함 -$sql = " select pp_word, count(*) as cnt - $sql_common - $sql_search - $sql_group - $sql_order - limit $from_record, $rows "; +$sql = " select pp_word, count(*) as cnt {$sql_common} {$sql_search} {$sql_group} {$sql_order} limit {$from_record}, {$rows} "; $result = sql_query($sql); -$listall = "처음"; +$listall = ''; +if (!empty($_GET['fr_date']) || !empty($_GET['to_date'])) + $listall = '전체목록'; -$g4[title] = "인기검색어순위"; -include_once("./admin.head.php"); +$g4['title'] = '인기검색어순위'; +include_once('./admin.head.php'); $colspan = 3; ?> - - - - - - - - - - - - - - - -
    (건수 : 개) - 기간 : - - - - -
    - -
    - - - - - - - ---- - - - - - - -"; - echo ""; - echo ""; - echo ""; - echo ""; - echo ""; - echo "\n"; -} - -if ($i == 0) - echo ""; - -echo ""; -echo "
    검색어검색회수순위
      $word$row[cnt]$rank
    자료가 없습니다.
    "; - -$pagelist = get_paging($config[cf_write_pages], $page, $total_page, "$_SERVER[PHP_SELF]?$qstr&page="); -echo ""; -echo ""; -echo "
    "; - -if ($is_admin == "super") - echo ""; - -echo "$pagelist
    \n"; - -if ($stx) - echo ""; -?> + +
    + 인기검색어 검색 + + + 건수 개 + + + 부터 + 까지 + +
    +
    +

    인기검색어 순위 및 내역

    +
    + + + + + + + + + + + + + + + + + + + + + + + + '; + ?> + +
    순위검색어검색회수
    자료가 없습니다.
    + +
    +
    + + + diff --git a/adm/sendmail_test.php b/adm/sendmail_test.php index 5d93064a3..39492c2a8 100644 --- a/adm/sendmail_test.php +++ b/adm/sendmail_test.php @@ -1,51 +1,66 @@ [메일검사] 내용

    이 내용이 제대로 보인다면 보내는 메일 서버에는 이상이 없는것입니다.

    ".date("Y-m-d H:i:s")."

    이 메일 주소로는 회신되지 않습니다.", 1); + mailer($from_name, $from_email, trim($email[$i]), '[메일검사] 제목', '[메일검사] 내용

    이 내용이 제대로 보인다면 보내는 메일 서버에는 이상이 없는것입니다.

    '.date("Y-m-d H:i:s").'

    이 메일 주소로는 회신되지 않습니다.', 1); - echo << - alert("{$mail} (으)로 메일을 발송 하였습니다.\\n\\n해당 주소로 메일이 왔는지 확인하여 주십시오.\\n\\n메일이 오지 않는다면 프로그램의 오류가 아닌 메일 서버(sendmail)의 오류일 가능성이 있습니다.\\n\\n이런 경우에는 웹 서버관리자에게 문의하여 주십시오."); - -HEREDOC; + echo '

    '; + echo '

    결과메세지

    '; + echo '

    '; + echo '다음 '.count($email).'개의 메일 주소로 테스트 메일 발송이 완료되었습니다.'; + echo '

    '; + echo '
      '; + for ($i=0;$i'.$email[$i].''; + } + echo '
    '; + echo '

    '; + echo '해당 주소로 테스트 메일이 도착했는지 확인해 주십시오.
    '; + echo '만약, 테스트 메일이 오지 않는다면 더 다양한 계정의 메일 주소로 메일을 보내 보십시오.
    '; + echo '그래도 메일이 하나도 도착하지 않는다면 메일 서버(sendmail server)의 오류일 가능성이 높으니, 웹 서버관리자에게 문의하여 주십시오.
    '; + echo '

    '; + echo '
    '; } - -$token = get_token(); ?> - -

    - -

    - -

    고객님들께서 메일이 오지 않는다고 하면 사용하는 메뉴입니다. -

    입력한 메일주소로 테스트 메일을 발송합니다. -

    만약 [메일검사] 라는 내용으로 메일이 도착하지 않는다면 보내는 메일서버와 받는 메일 서버중 문제가 발생했을 가능성이 있습니다. -

    메일을 보냈는데도 도착하지 않는다면 다른 여러곳으로도 메일을 발송하여 주십시오. -

    여러곳으로 메일을 발송하시려면 , 로 메일을 구분하십시오. -

    받는 메일주소 : - -

    +
    +

    테스트 메일 발송

    +

    + 메일서버가 정상적으로 동작 중인지 확인할 수 있습니다.
    + 아래 입력칸에 테스트 메일을 발송하실 메일 주소를 입력하시면, [메일검사] 라는 제목으로 테스트 메일을 발송합니다.
    + 여러 곳으로 테스트 메일을 발송하시려면 , 로 메일을 구분하십시오. +

    +
    +
    + 테스트메일 발송 + + + +
    +
    +

    + 만약 [메일검사] 라는 내용으로 테스트 메일이 도착하지 않는다면 보내는 메일서버 혹은 받는 메일서버 중 문제가 발생했을 가능성이 있습니다.
    + 따라서 보다 정확한 테스트를 원하신다면 여러 곳으로 테스트 메일을 발송하시기 바랍니다.
    +

    +
    diff --git a/adm/session_file_delete.php b/adm/session_file_delete.php new file mode 100644 index 000000000..e77e6d14f --- /dev/null +++ b/adm/session_file_delete.php @@ -0,0 +1,62 @@ + + +
    +

    + 완료 메세지가 나오기 전에 프로그램의 실행을 중지하지 마십시오. +

    + + 세션 디렉토리를 열지못했습니다.

    "; + } else { + $list_tag_st = "
      \n
    • 완료됨
    • \n"; + $list_tag_end = "
    \n"; + } + + $cnt=0; + echo $list_tag_st; + while($file=readdir($dir)) { + + if (!strstr($file,'sess_')) continue; + if (strpos($file,'sess_')!=0) continue; + + $session_file = G4_DATA_PATH.'/session/'.$file; + + if (!$atime=@fileatime($session_file)) { + continue; + } + if (time() > $atime + (3600 * 6)) { // 지난시간을 초로 계산해서 적어주시면 됩니다. default : 6시간전 + $cnt++; + $return = unlink($session_file); + //echo "\n"; + echo "
  • {$session_file}
  • \n"; + + flush(); + + if ($cnt%10==0) + //echo "\n"; + echo "\n"; + } + } + echo $list_tag_end; + //echo "\n"; + echo "

    세션데이터 {$cnt}건 삭제 완료.
    프로그램의 실행을 끝마치셔도 좋습니다.

    \n"; +?> +
    + + diff --git a/adm/sql_write.sql b/adm/sql_write.sql index 3f29efcfd..63e86974e 100644 --- a/adm/sql_write.sql +++ b/adm/sql_write.sql @@ -1,81 +1,42 @@ -## 마이에스큐엘 dump 10.13 Distrib 5.1.66, for redhat-linux-gnu (i386) -## -## Host: 1.226.84.20 Database: yc4kcp -## ###################################################### -## Server version 5.0.96-log - - - - - - - - - - - - -## -## Not dumping tablespaces as no INFORMATION_SCHEMA.FILES table on this server -## - -## -## Table structure for table `__TABLE_NAME__` -## - - - -CREATE TABLE `__TABLE_NAME__` ( - `wr_id` int(11) NOT NULL auto_increment, - `wr_num` int(11) NOT NULL default '0', - `wr_reply` varchar(10) NOT NULL, - `wr_parent` int(11) NOT NULL default '0', - `wr_is_comment` tinyint(4) NOT NULL default '0', - `wr_comment` int(11) NOT NULL default '0', - `wr_comment_reply` varchar(5) NOT NULL, - `ca_name` varchar(255) NOT NULL, - `wr_option` set('html1','html2','secret','mail') NOT NULL, - `wr_subject` varchar(255) NOT NULL, - `wr_content` text NOT NULL, - `wr_link1` text NOT NULL, - `wr_link2` text NOT NULL, - `wr_link1_hit` int(11) NOT NULL default '0', - `wr_link2_hit` int(11) NOT NULL default '0', - `wr_trackback` varchar(255) NOT NULL, - `wr_hit` int(11) NOT NULL default '0', - `wr_good` int(11) NOT NULL default '0', - `wr_nogood` int(11) NOT NULL default '0', - `mb_id` varchar(255) NOT NULL, - `wr_password` varchar(255) NOT NULL, - `wr_name` varchar(255) NOT NULL, - `wr_email` varchar(255) NOT NULL, - `wr_homepage` varchar(255) NOT NULL, - `wr_datetime` datetime NOT NULL default '0000-00-00 00:00:00', - `wr_last` varchar(19) NOT NULL, - `wr_ip` varchar(255) NOT NULL, - `wr_1` varchar(255) NOT NULL, - `wr_2` varchar(255) NOT NULL, - `wr_3` varchar(255) NOT NULL, - `wr_4` varchar(255) NOT NULL, - `wr_5` varchar(255) NOT NULL, - `wr_6` varchar(255) NOT NULL, - `wr_7` varchar(255) NOT NULL, - `wr_8` varchar(255) NOT NULL, - `wr_9` varchar(255) NOT NULL, - `wr_10` varchar(255) NOT NULL, - PRIMARY KEY (`wr_id`), - KEY `wr_num_reply_parent` (`wr_num`,`wr_reply`,`wr_parent`), - KEY `wr_is_comment` (`wr_is_comment`,`wr_id`) -) DEFAULT CHARSET=utf8; - - - - - - - - - - - -## Dump completed on 2013-02-26 16:04:46 +CREATE TABLE `__TABLE_NAME__` ( + `wr_id` int(11) NOT NULL auto_increment, + `wr_num` int(11) NOT NULL default '0', + `wr_reply` varchar(10) NOT NULL default '', + `wr_parent` int(11) NOT NULL default '0', + `wr_is_comment` tinyint(4) NOT NULL default '0', + `wr_comment` int(11) NOT NULL default '0', + `wr_comment_reply` varchar(5) NOT NULL default '', + `ca_name` varchar(255) NOT NULL default '', + `wr_option` set('html1','html2','secret','mail') NOT NULL default '', + `wr_subject` varchar(255) NOT NULL default '', + `wr_content` text NOT NULL, + `wr_link1` text NOT NULL, + `wr_link2` text NOT NULL, + `wr_link1_hit` int(11) NOT NULL default '0', + `wr_link2_hit` int(11) NOT NULL default '0', + `wr_trackback` varchar(255) NOT NULL default '', + `wr_hit` int(11) NOT NULL default '0', + `wr_good` int(11) NOT NULL default '0', + `wr_nogood` int(11) NOT NULL default '0', + `mb_id` varchar(255) NOT NULL default '', + `wr_password` varchar(255) NOT NULL default '', + `wr_name` varchar(255) NOT NULL default '', + `wr_email` varchar(255) NOT NULL default '', + `wr_homepage` varchar(255) NOT NULL default '', + `wr_datetime` datetime NOT NULL default '0000-00-00 00:00:00', + `wr_last` varchar(19) NOT NULL default '', + `wr_ip` varchar(255) NOT NULL default '', + `wr_1` varchar(255) NOT NULL default '', + `wr_2` varchar(255) NOT NULL default '', + `wr_3` varchar(255) NOT NULL default '', + `wr_4` varchar(255) NOT NULL default '', + `wr_5` varchar(255) NOT NULL default '', + `wr_6` varchar(255) NOT NULL default '', + `wr_7` varchar(255) NOT NULL default '', + `wr_8` varchar(255) NOT NULL default '', + `wr_9` varchar(255) NOT NULL default '', + `wr_10` varchar(255) NOT NULL default '', + PRIMARY KEY (`wr_id`), + KEY `wr_num_reply_parent` (`wr_num`,`wr_reply`,`wr_parent`), + KEY `wr_is_comment` (`wr_is_comment`,`wr_id`) +) ENGINE=MyISAM DEFAULT CHARSET=utf8; \ No newline at end of file diff --git a/adm/visit.sub.php b/adm/visit.sub.php index bcce44585..6a14daffb 100644 --- a/adm/visit.sub.php +++ b/adm/visit.sub.php @@ -1,39 +1,37 @@ - - - - - - -
    - 기간 : - - - - -   - - - - - - - - - -
    + - + + + + \ No newline at end of file diff --git a/bbs/alert_close.php b/bbs/alert_close.php new file mode 100644 index 000000000..b5eb0d9d7 --- /dev/null +++ b/bbs/alert_close.php @@ -0,0 +1,61 @@ +", $msg); + +if($error) { + $header2 = "다음 항목에 오류가 있습니다."; + $msg3 = "새창을 닫으시고 이전 작업을 다시 시도해 주세요."; +} else { + $header2 = "다음 내용을 확인해 주세요."; + $msg3 = "새창을 닫으신 후 서비스를 이용해 주세요."; +} +?> + + + + + + \ No newline at end of file diff --git a/bbs/board.php b/bbs/board.php index 9bebffafc..9098c359c 100644 --- a/bbs/board.php +++ b/bbs/board.php @@ -1,115 +1,88 @@ 1) { - if ($member[mb_point] + $board[bo_read_point] < 0) - alert("보유하신 포인트(".number_format($member[mb_point]).")가 없거나 모자라서 글읽기(".number_format($board[bo_read_point]).")가 불가합니다.\\n\\n포인트를 모으신 후 다시 글읽기 해 주십시오."); - - insert_point($member[mb_id], $board[bo_read_point], "$board[bo_subject] $wr_id 글읽기", $bo_table, $wr_id, '읽기'); - } - */ // 글읽기 포인트가 설정되어 있다면 - if ($board[bo_read_point] && $member[mb_point] + $board[bo_read_point] < 0) - alert("보유하신 포인트(".number_format($member[mb_point]).")가 없거나 모자라서 글읽기(".number_format($board[bo_read_point]).")가 불가합니다.\\n\\n포인트를 모으신 후 다시 글읽기 해 주십시오."); + if ($board['bo_read_point'] && $member['mb_point'] + $board['bo_read_point'] < 0) + alert('보유하신 포인트('.number_format($member['mb_point']).')가 없거나 모자라서 글읽기('.number_format($board['bo_read_point']).')가 불가합니다.\\n\\n포인트를 모으신 후 다시 글읽기 해 주십시오.'); - insert_point($member[mb_id], $board[bo_read_point], "$board[bo_subject] $wr_id 글읽기", $bo_table, $wr_id, '읽기'); + insert_point($member['mb_id'], $board['bo_read_point'], "{$board['bo_subject']} {$wr_id} 글읽기", $bo_table, $wr_id, '읽기'); } set_session($ss_name, TRUE); } - $g4[title] = "$group[gr_subject] > $board[bo_subject] > " . strip_tags(conv_subject($write[wr_subject], 255)); -} -else -{ - if ($member[mb_level] < $board[bo_list_level]) - { - if ($member[mb_id]) - alert("목록을 볼 권한이 없습니다.", $g4[path]); + $g4['title'] = strip_tags(conv_subject($write['wr_subject'], 255)); +} else { + if ($member['mb_level'] < $board['bo_list_level']) { + if ($member['mb_id']) + alert('목록을 볼 권한이 없습니다.', G4_URL); else - alert("목록을 볼 권한이 없습니다.\\n\\n회원이시라면 로그인 후 이용해 보십시오.", "./login.php?wr_id=$wr_id{$qstr}&url=".urlencode("board.php?bo_table=$bo_table&wr_id=$wr_id")); + alert('목록을 볼 권한이 없습니다.\\n\\n회원이시라면 로그인 후 이용해 보십시오.', './login.php?wr_id='.$wr_id.$qstr.'&url='.urlencode(G4_BBS_URL.'/board.php?bo_table='.$bo_table.'&wr_id='.$wr_id)); } - if (!$page) $page = 1; + if (!isset($page) || (isset($page) && $page == 0)) $page = 1; - $g4[title] = "$group[gr_subject] > $board[bo_subject] $page 페이지"; + $g4['title'] = $board['bo_subject']; } -include_once("$g4[path]/head.sub.php"); +include_once(G4_PATH.'/head.sub.php'); -$width = $board[bo_table_width]; +$width = $board['bo_table_width']; if ($width <= 100) $width .= '%'; // IP보이기 사용 여부 $ip = ""; -$is_ip_view = $board[bo_use_ip_view]; +$is_ip_view = $board['bo_use_ip_view']; if ($is_admin) { $is_ip_view = true; - $ip = $write[wr_ip]; -} else // 관리자가 아니라면 IP 주소를 감춘후 보여줍니다. - $ip = preg_replace("/([0-9]+).([0-9]+).([0-9]+).([0-9]+)/", "\\1.♡.\\3.\\4", $write[wr_ip]); + if (array_key_exists('wr_ip', $write)) { + $ip = $write['wr_ip']; + } +} else { + // 관리자가 아니라면 IP 주소를 감춘후 보여줍니다. + if (isset($write['wr_ip'])) { + $ip = preg_replace("/([0-9]+).([0-9]+).([0-9]+).([0-9]+)/", "\\1.♡.\\3.\\4", $write['wr_ip']); + } +} // 분류 사용 $is_category = false; -$category_name = ""; -if ($board[bo_use_category]) { +$category_name = ''; +if ($board['bo_use_category']) { $is_category = true; - $category_name = $write[ca_name]; // 분류명 + if (array_key_exists('ca_name', $write)) { + $category_name = $write['ca_name']; // 분류명 + } } // 추천 사용 $is_good = false; -if ($board[bo_use_good]) +if ($board['bo_use_good']) $is_good = true; // 비추천 사용 $is_nogood = false; -if ($board[bo_use_nogood]) +if ($board['bo_use_nogood']) $is_nogood = true; $admin_href = ""; // 최고관리자 또는 그룹관리자라면 -if ($member[mb_id] && ($is_admin == 'super' || $group[gr_admin] == $member[mb_id])) - $admin_href = "$g4[admin_path]/board_form.php?w=u&bo_table=$bo_table"; +if ($member['mb_id'] && ($is_admin == 'super' || $group['gr_admin'] == $member['mb_id'])) + $admin_href = G4_ADMIN_URL.'/board_form.php?w=u&bo_table='.$bo_table; -if (!($board[bo_use_comment] && $cwin)) - include_once("./board_head.php"); +include_once('./board_head.php'); -echo "\n"; - -if (!($board[bo_use_comment] && $cwin)) { - // 게시물 아이디가 있다면 게시물 보기를 INCLUDE - if ($wr_id) - include_once("./view.php"); - - // 전체목록보이기 사용이 "예" 또는 wr_id 값이 없다면 목록을 보임 - //if ($board[bo_use_list_view] || empty($wr_id)) - if ($member[mb_level] >= $board[bo_list_level] && $board[bo_use_list_view] || empty($wr_id)) - include_once ("./list.php"); - - include_once("./board_tail.php"); +// 게시물 아이디가 있다면 게시물 보기를 INCLUDE +if (isset($wr_id) && $wr_id) { + include_once('./view.php'); } -else - include_once("./view_comment.php"); -echo "\n\n"; +// 전체목록보이기 사용이 "예" 또는 wr_id 값이 없다면 목록을 보임 +//if ($board['bo_use_list_view'] || empty($wr_id)) +if ($member['mb_level'] >= $board['bo_list_level'] && $board['bo_use_list_view'] || empty($wr_id)) + include_once ('./list.php'); -include_once("$g4[path]/tail.sub.php"); +include_once('./board_tail.php'); + +echo "\n\n"; + +include_once(G4_PATH.'/tail.sub.php'); ?> diff --git a/bbs/board_head.php b/bbs/board_head.php index 1b63c439d..7a33de9b0 100644 --- a/bbs/board_head.php +++ b/bbs/board_head.php @@ -1,15 +1,21 @@ "; +if ($board['bo_image_head']) { + echo ''; +} // 게시판 관리의 상단 내용 -if ($board[bo_content_head]) - echo stripslashes($board[bo_content_head]); +if (G4_IS_MOBILE) { + // 모바일의 경우 설정을 따르지 않는다. + include_once('./_head.php'); +} else if ($board['bo_content_head']) { + echo stripslashes($board['bo_content_head']); +} ?> \ No newline at end of file diff --git a/bbs/board_list_update.php b/bbs/board_list_update.php new file mode 100644 index 000000000..a43924024 --- /dev/null +++ b/bbs/board_list_update.php @@ -0,0 +1,21 @@ + \ No newline at end of file diff --git a/bbs/board_tail.php b/bbs/board_tail.php index 892daaef4..58b326b6a 100644 --- a/bbs/board_tail.php +++ b/bbs/board_tail.php @@ -1,15 +1,21 @@ "; +if ($board['bo_image_tail']) { + echo ''; +} // 게시판 관리의 하단 파일 경로 -if ($board[bo_include_tail]) - @include ($board[bo_include_tail]); +if (G4_IS_MOBILE) { + // 모바일의 경우 설정을 따르지 않는다. + include_once('./_tail.php'); +} else if ($board['bo_include_tail']) { + @include ($board['bo_include_tail']); +} ?> \ No newline at end of file diff --git a/bbs/calendar.php b/bbs/calendar.php deleted file mode 100644 index d5f8793d0..000000000 --- a/bbs/calendar.php +++ /dev/null @@ -1,141 +0,0 @@ -31, 28, 31, 30 , 31, 30, 31, 31, 30 ,31 ,30, 31); -// 윤년 계산 부분이다. 4년에 한번꼴로 2월이 28일이 아닌 29일이 있다. -if( $yyyy%4 == 0 && $yyyy%100 != 0 || $yyyy%400 == 0 ) - $endday[2] = 29; // 조건에 적합할 경우 28을 29로 변경 - -// 해당월의 1일 -$mktime = mktime(0,0,0,$mm,1,$yyyy); -$dt = getdate(strtotime(date("Y-m-1", $mktime))); - -$dt[wday] = $spacer; - -// 해당월의 마지막 날짜, -//$last_day = date("t", $mktime); -$last_day = $endday[$mm]; - -$yyyy_before = $yyyy; -$mm_before = $mm - 1; -if ($mm_before < 1) -{ - $yyyy_before--; - $mm_before = 12; -} - -$yyyy_after = $yyyy; -$mm_after = $mm + 1; -if ($mm_after > 12) -{ - $yyyy_after++; - $mm_after = 1; -} - -$fr_yyyy = $yyyy - 80; -$to_yyyy = $yyyy + 80; - -$yyyy_before_href = "$_SERVER[PHP_SELF]?yyyy=".($yyyy-1)."&mm={$mm}&cur_date={$cur_date}&fld={$fld}&delimiter={$delimiter}"; -$yyyy_after_href = "$_SERVER[PHP_SELF]?yyyy=".($yyyy+1)."&mm={$mm}&cur_date={$cur_date}&fld={$fld}&delimiter={$delimiter}"; - -$mm_after_href = "$_SERVER[PHP_SELF]?yyyy={$yyyy_after}&mm={$mm_after}&cur_date={$cur_date}&fld={$fld}&delimiter={$delimiter}"; -$mm_before_href = "$_SERVER[PHP_SELF]?yyyy={$yyyy_before}&mm={$mm_before}&cur_date={$cur_date}&fld={$fld}&delimiter={$delimiter}"; - -$yyyy_select = ""; - -$mm_select = ""; - -$member_skin_path = "$g4[path]/skin/member/$config[cf_member_skin]"; -include_once("$member_skin_path/calendar.skin.php"); -?> - - - - diff --git a/bbs/calendar/2005.txt b/bbs/calendar/2005.txt deleted file mode 100644 index 62c5a058a..000000000 --- a/bbs/calendar/2005.txt +++ /dev/null @@ -1,21 +0,0 @@ -04-28|그누보드4 정식버전 출시일 -08-07|입추 -08-14|말복 -08-15|광복절|* -09-07|사회복지의 날, 백로 -09-17|추석연휴|* -09-18|추석|* -09-19|추석연휴|* -09-23|추분 -10-03|개천절|* -10-01|국군의날 -10-08|한로 -10-09|한글날|* -10-23|상강 -11-03|학생의날 -11-07|입동 -11-22|소설 -12-07|대설 -12-10|세계 인권선언 기념일 -12-22|동지 -12-25|성탄절|* \ No newline at end of file diff --git a/bbs/calendar/2006.txt b/bbs/calendar/2006.txt deleted file mode 100644 index 3c2de6af1..000000000 --- a/bbs/calendar/2006.txt +++ /dev/null @@ -1,67 +0,0 @@ -01-01|신정|* -01-05|소한 -01-20|대한 -01-28|설 연휴|* -01-29|설날|* -01-30|설 연휴|* -03-01|삼일절|* -03-03|납세자의날 -03-06|경칩 -03-21|춘분 -03-22|물의 날 -03-23|기상의날 -04-05|식목일,청명 -04-06|한식 -04-07|보건의날 -04-19|4.19혁명 기념일 -04-20|곡우,장애인의날 -04-21|과학의 날 -04-22|정보통신의날 -04-25|법의날 -04-28|충무공탄신일 -05-01|근로자의날 -05-05|어린이날, 석가탄신일|* -05-06|입하 -05-08|어버이날 -05-15|스승의날, 성년의날 -05-18|5.18 민주화운동 기념일 -05-21|소만 -05-31|단오 -06-06|현충일,망종 -06-21|하지 -06-25|6.25사변일 -07-07|소서 -07-17|제헌절|* -07-20|초복 -07-23|대서 -07-30|중복 -07-31|칠석 -08-08|입추 -08-09|말복 -08-15|광복절|* -08-23|처서 -09-07|사회복지의 날, 백로 -09-18|철도의날 -09-23|추분 -10-01|국군의날 -10-03|개천절|* -10-05|추석연휴|* -10-06|추석|* -10-07|추석연휴|* -10-08|한로 -10-09|한글날 -10-20|문화의날 -10-23|상강 -10-24|국제연합일 -10-31|저축의날 -11-03|학생의날 -11-07|입동 -11-09|소방의날 -11-11|농업인의날 -11-17|순국선열의날 -11-22|소설 -11-30|무역의날 -12-07|대설 -12-10|세계 인권선언 기념일 -12-22|동지 -12-25|성탄절|* \ No newline at end of file diff --git a/bbs/ckeditor/CHANGES.md b/bbs/ckeditor/CHANGES.md new file mode 100644 index 000000000..98ecdf4e1 --- /dev/null +++ b/bbs/ckeditor/CHANGES.md @@ -0,0 +1,12 @@ +CKEditor 4 Changelog +==================== + +## CKEditor 4.0 + +The first stable release of the new CKEditor 4 code line. + +The CKEditor JavaScript API has been kept compatible with CKEditor 4, whenever +possible. The list of relevant changes can be found in the [API Changes page of +the CKEditor 4 documentation][1]. + +[1]: http://docs.ckeditor.com/#!/guide/dev_api_changes "API Changes"" diff --git a/bbs/ckeditor/LICENSE.md b/bbs/ckeditor/LICENSE.md new file mode 100644 index 000000000..2a69d60fd --- /dev/null +++ b/bbs/ckeditor/LICENSE.md @@ -0,0 +1,1264 @@ +Software License Agreement +========================== + +CKEditor - The text editor for Internet - http://ckeditor.com +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. + +Licensed under the terms of any of the following licenses at your +choice: + + - GNU General Public License Version 2 or later (the "GPL") + http://www.gnu.org/licenses/gpl.html + (See Appendix A) + + - GNU Lesser General Public License Version 2.1 or later (the "LGPL") + http://www.gnu.org/licenses/lgpl.html + (See Appendix B) + + - Mozilla Public License Version 1.1 or later (the "MPL") + http://www.mozilla.org/MPL/MPL-1.1.html + (See Appendix C) + +You are not required to, but if you want to explicitly declare the +license you have chosen to be bound to when using, reproducing, +modifying and distributing this software, just include a text file +titled "legal.txt" in your version of this software, indicating your +license choice. In any case, your choice will not restrict any +recipient of your version of this software to use, reproduce, modify +and distribute this software under any of the above licenses. + +Sources of Intellectual Property Included in CKEditor +----------------------------------------------------- + +Where not otherwise indicated, all CKEditor content is authored by +CKSource engineers and consists of CKSource-owned intellectual +property. In some specific instances, CKEditor will incorporate work +done by developers outside of CKSource with their express permission. + +Trademarks +---------- + +CKEditor is a trademark of CKSource - Frederico Knabben. All other brand +and product names are trademarks, registered trademarks or service +marks of their respective holders. + +--- + +Appendix A: The GPL License +--------------------------- + +GNU GENERAL PUBLIC LICENSE +Version 2, June 1991 + + Copyright (C) 1989, 1991 Free Software Foundation, Inc., + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software-to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Lesser General Public License instead.) You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. + + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. + + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + +GNU GENERAL PUBLIC LICENSE +TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + +NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + +END OF TERMS AND CONDITIONS + + +Appendix B: The LGPL License +---------------------------- + +GNU LESSER GENERAL PUBLIC LICENSE +Version 2.1, February 1999 + + Copyright (C) 1991, 1999 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + +[This is the first released version of the Lesser GPL. It also counts + as the successor of the GNU Library Public License, version 2, hence + the version number 2.1.] + +Preamble + + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +Licenses are intended to guarantee your freedom to share and change +free software-to make sure the software is free for all its users. + + This license, the Lesser General Public License, applies to some +specially designated software packages-typically libraries-of the +Free Software Foundation and other authors who decide to use it. You +can use it too, but we suggest you first think carefully about whether +this license or the ordinary General Public License is the better +strategy to use in any particular case, based on the explanations below. + + When we speak of free software, we are referring to freedom of use, +not price. Our General Public Licenses are designed to make sure that +you have the freedom to distribute copies of free software (and charge +for this service if you wish); that you receive source code or can get +it if you want it; that you can change the software and use pieces of +it in new free programs; and that you are informed that you can do +these things. + + To protect your rights, we need to make restrictions that forbid +distributors to deny you these rights or to ask you to surrender these +rights. These restrictions translate to certain responsibilities for +you if you distribute copies of the library or if you modify it. + + For example, if you distribute copies of the library, whether gratis +or for a fee, you must give the recipients all the rights that we gave +you. You must make sure that they, too, receive or can get the source +code. If you link other code with the library, you must provide +complete object files to the recipients, so that they can relink them +with the library after making changes to the library and recompiling +it. And you must show them these terms so they know their rights. + + We protect your rights with a two-step method: (1) we copyright the +library, and (2) we offer you this license, which gives you legal +permission to copy, distribute and/or modify the library. + + To protect each distributor, we want to make it very clear that +there is no warranty for the free library. Also, if the library is +modified by someone else and passed on, the recipients should know +that what they have is not the original version, so that the original +author's reputation will not be affected by problems that might be +introduced by others. + + Finally, software patents pose a constant threat to the existence of +any free program. We wish to make sure that a company cannot +effectively restrict the users of a free program by obtaining a +restrictive license from a patent holder. Therefore, we insist that +any patent license obtained for a version of the library must be +consistent with the full freedom of use specified in this license. + + Most GNU software, including some libraries, is covered by the +ordinary GNU General Public License. This license, the GNU Lesser +General Public License, applies to certain designated libraries, and +is quite different from the ordinary General Public License. We use +this license for certain libraries in order to permit linking those +libraries into non-free programs. + + When a program is linked with a library, whether statically or using +a shared library, the combination of the two is legally speaking a +combined work, a derivative of the original library. The ordinary +General Public License therefore permits such linking only if the +entire combination fits its criteria of freedom. The Lesser General +Public License permits more lax criteria for linking other code with +the library. + + We call this license the "Lesser" General Public License because it +does Less to protect the user's freedom than the ordinary General +Public License. It also provides other free software developers Less +of an advantage over competing non-free programs. These disadvantages +are the reason we use the ordinary General Public License for many +libraries. However, the Lesser license provides advantages in certain +special circumstances. + + For example, on rare occasions, there may be a special need to +encourage the widest possible use of a certain library, so that it becomes +a de-facto standard. To achieve this, non-free programs must be +allowed to use the library. A more frequent case is that a free +library does the same job as widely used non-free libraries. In this +case, there is little to gain by limiting the free library to free +software only, so we use the Lesser General Public License. + + In other cases, permission to use a particular library in non-free +programs enables a greater number of people to use a large body of +free software. For example, permission to use the GNU C Library in +non-free programs enables many more people to use the whole GNU +operating system, as well as its variant, the GNU/Linux operating +system. + + Although the Lesser General Public License is Less protective of the +users' freedom, it does ensure that the user of a program that is +linked with the Library has the freedom and the wherewithal to run +that program using a modified version of the Library. + + The precise terms and conditions for copying, distribution and +modification follow. Pay close attention to the difference between a +"work based on the library" and a "work that uses the library". The +former contains code derived from the library, whereas the latter must +be combined with the library in order to run. + +GNU LESSER GENERAL PUBLIC LICENSE +TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License Agreement applies to any software library or other +program which contains a notice placed by the copyright holder or +other authorized party saying it may be distributed under the terms of +this Lesser General Public License (also called "this License"). +Each licensee is addressed as "you". + + A "library" means a collection of software functions and/or data +prepared so as to be conveniently linked with application programs +(which use some of those functions and data) to form executables. + + The "Library", below, refers to any such software library or work +which has been distributed under these terms. A "work based on the +Library" means either the Library or any derivative work under +copyright law: that is to say, a work containing the Library or a +portion of it, either verbatim or with modifications and/or translated +straightforwardly into another language. (Hereinafter, translation is +included without limitation in the term "modification".) + + "Source code" for a work means the preferred form of the work for +making modifications to it. For a library, complete source code means +all the source code for all modules it contains, plus any associated +interface definition files, plus the scripts used to control compilation +and installation of the library. + + Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running a program using the Library is not restricted, and output from +such a program is covered only if its contents constitute a work based +on the Library (independent of the use of the Library in a tool for +writing it). Whether that is true depends on what the Library does +and what the program that uses the Library does. + + 1. You may copy and distribute verbatim copies of the Library's +complete source code as you receive it, in any medium, provided that +you conspicuously and appropriately publish on each copy an +appropriate copyright notice and disclaimer of warranty; keep intact +all the notices that refer to this License and to the absence of any +warranty; and distribute a copy of this License along with the +Library. + + You may charge a fee for the physical act of transferring a copy, +and you may at your option offer warranty protection in exchange for a +fee. + + 2. You may modify your copy or copies of the Library or any portion +of it, thus forming a work based on the Library, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) The modified work must itself be a software library. + + b) You must cause the files modified to carry prominent notices + stating that you changed the files and the date of any change. + + c) You must cause the whole of the work to be licensed at no + charge to all third parties under the terms of this License. + + d) If a facility in the modified Library refers to a function or a + table of data to be supplied by an application program that uses + the facility, other than as an argument passed when the facility + is invoked, then you must make a good faith effort to ensure that, + in the event an application does not supply such function or + table, the facility still operates, and performs whatever part of + its purpose remains meaningful. + + (For example, a function in a library to compute square roots has + a purpose that is entirely well-defined independent of the + application. Therefore, Subsection 2d requires that any + application-supplied function or table used by this function must + be optional: if the application does not supply it, the square + root function must still compute square roots.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Library, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Library, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote +it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Library. + +In addition, mere aggregation of another work not based on the Library +with the Library (or with a work based on the Library) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may opt to apply the terms of the ordinary GNU General Public +License instead of this License to a given copy of the Library. To do +this, you must alter all the notices that refer to this License, so +that they refer to the ordinary GNU General Public License, version 2, +instead of to this License. (If a newer version than version 2 of the +ordinary GNU General Public License has appeared, then you can specify +that version instead if you wish.) Do not make any other change in +these notices. + + Once this change is made in a given copy, it is irreversible for +that copy, so the ordinary GNU General Public License applies to all +subsequent copies and derivative works made from that copy. + + This option is useful when you wish to copy part of the code of +the Library into a program that is not a library. + + 4. You may copy and distribute the Library (or a portion or +derivative of it, under Section 2) in object code or executable form +under the terms of Sections 1 and 2 above provided that you accompany +it with the complete corresponding machine-readable source code, which +must be distributed under the terms of Sections 1 and 2 above on a +medium customarily used for software interchange. + + If distribution of object code is made by offering access to copy +from a designated place, then offering equivalent access to copy the +source code from the same place satisfies the requirement to +distribute the source code, even though third parties are not +compelled to copy the source along with the object code. + + 5. A program that contains no derivative of any portion of the +Library, but is designed to work with the Library by being compiled or +linked with it, is called a "work that uses the Library". Such a +work, in isolation, is not a derivative work of the Library, and +therefore falls outside the scope of this License. + + However, linking a "work that uses the Library" with the Library +creates an executable that is a derivative of the Library (because it +contains portions of the Library), rather than a "work that uses the +library". The executable is therefore covered by this License. +Section 6 states terms for distribution of such executables. + + When a "work that uses the Library" uses material from a header file +that is part of the Library, the object code for the work may be a +derivative work of the Library even though the source code is not. +Whether this is true is especially significant if the work can be +linked without the Library, or if the work is itself a library. The +threshold for this to be true is not precisely defined by law. + + If such an object file uses only numerical parameters, data +structure layouts and accessors, and small macros and small inline +functions (ten lines or less in length), then the use of the object +file is unrestricted, regardless of whether it is legally a derivative +work. (Executables containing this object code plus portions of the +Library will still fall under Section 6.) + + Otherwise, if the work is a derivative of the Library, you may +distribute the object code for the work under the terms of Section 6. +Any executables containing that work also fall under Section 6, +whether or not they are linked directly with the Library itself. + + 6. As an exception to the Sections above, you may also combine or +link a "work that uses the Library" with the Library to produce a +work containing portions of the Library, and distribute that work +under terms of your choice, provided that the terms permit +modification of the work for the customer's own use and reverse +engineering for debugging such modifications. + + You must give prominent notice with each copy of the work that the +Library is used in it and that the Library and its use are covered by +this License. You must supply a copy of this License. If the work +during execution displays copyright notices, you must include the +copyright notice for the Library among them, as well as a reference +directing the user to the copy of this License. Also, you must do one +of these things: + + a) Accompany the work with the complete corresponding + machine-readable source code for the Library including whatever + changes were used in the work (which must be distributed under + Sections 1 and 2 above); and, if the work is an executable linked + with the Library, with the complete machine-readable "work that + uses the Library", as object code and/or source code, so that the + user can modify the Library and then relink to produce a modified + executable containing the modified Library. (It is understood + that the user who changes the contents of definitions files in the + Library will not necessarily be able to recompile the application + to use the modified definitions.) + + b) Use a suitable shared library mechanism for linking with the + Library. A suitable mechanism is one that (1) uses at run time a + copy of the library already present on the user's computer system, + rather than copying library functions into the executable, and (2) + will operate properly with a modified version of the library, if + the user installs one, as long as the modified version is + interface-compatible with the version that the work was made with. + + c) Accompany the work with a written offer, valid for at + least three years, to give the same user the materials + specified in Subsection 6a, above, for a charge no more + than the cost of performing this distribution. + + d) If distribution of the work is made by offering access to copy + from a designated place, offer equivalent access to copy the above + specified materials from the same place. + + e) Verify that the user has already received a copy of these + materials or that you have already sent this user a copy. + + For an executable, the required form of the "work that uses the +Library" must include any data and utility programs needed for +reproducing the executable from it. However, as a special exception, +the materials to be distributed need not include anything that is +normally distributed (in either source or binary form) with the major +components (compiler, kernel, and so on) of the operating system on +which the executable runs, unless that component itself accompanies +the executable. + + It may happen that this requirement contradicts the license +restrictions of other proprietary libraries that do not normally +accompany the operating system. Such a contradiction means you cannot +use both them and the Library together in an executable that you +distribute. + + 7. You may place library facilities that are a work based on the +Library side-by-side in a single library together with other library +facilities not covered by this License, and distribute such a combined +library, provided that the separate distribution of the work based on +the Library and of the other library facilities is otherwise +permitted, and provided that you do these two things: + + a) Accompany the combined library with a copy of the same work + based on the Library, uncombined with any other library + facilities. This must be distributed under the terms of the + Sections above. + + b) Give prominent notice with the combined library of the fact + that part of it is a work based on the Library, and explaining + where to find the accompanying uncombined form of the same work. + + 8. You may not copy, modify, sublicense, link with, or distribute +the Library except as expressly provided under this License. Any +attempt otherwise to copy, modify, sublicense, link with, or +distribute the Library is void, and will automatically terminate your +rights under this License. However, parties who have received copies, +or rights, from you under this License will not have their licenses +terminated so long as such parties remain in full compliance. + + 9. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Library or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Library (or any work based on the +Library), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Library or works based on it. + + 10. Each time you redistribute the Library (or any work based on the +Library), the recipient automatically receives a license from the +original licensor to copy, distribute, link with or modify the Library +subject to these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties with +this License. + + 11. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Library at all. For example, if a patent +license would not permit royalty-free redistribution of the Library by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Library. + +If any portion of this section is held invalid or unenforceable under any +particular circumstance, the balance of the section is intended to apply, +and the section as a whole is intended to apply in other circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 12. If the distribution and/or use of the Library is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Library under this License may add +an explicit geographical distribution limitation excluding those countries, +so that distribution is permitted only in or among countries not thus +excluded. In such case, this License incorporates the limitation as if +written in the body of this License. + + 13. The Free Software Foundation may publish revised and/or new +versions of the Lesser General Public License from time to time. +Such new versions will be similar in spirit to the present version, +but may differ in detail to address new problems or concerns. + +Each version is given a distinguishing version number. If the Library +specifies a version number of this License which applies to it and +"any later version", you have the option of following the terms and +conditions either of that version or of any later version published by +the Free Software Foundation. If the Library does not specify a +license version number, you may choose any version ever published by +the Free Software Foundation. + + 14. If you wish to incorporate parts of the Library into other free +programs whose distribution conditions are incompatible with these, +write to the author to ask for permission. For software which is +copyrighted by the Free Software Foundation, write to the Free +Software Foundation; we sometimes make exceptions for this. Our +decision will be guided by the two goals of preserving the free status +of all derivatives of our free software and of promoting the sharing +and reuse of software generally. + +NO WARRANTY + + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES. + +END OF TERMS AND CONDITIONS + + +Appendix C: The MPL License +--------------------------- + +MOZILLA PUBLIC LICENSE +Version 1.1 + +1. Definitions. + + 1.0.1. "Commercial Use" means distribution or otherwise making the + Covered Code available to a third party. + + 1.1. "Contributor" means each entity that creates or contributes to + the creation of Modifications. + + 1.2. "Contributor Version" means the combination of the Original + Code, prior Modifications used by a Contributor, and the Modifications + made by that particular Contributor. + + 1.3. "Covered Code" means the Original Code or Modifications or the + combination of the Original Code and Modifications, in each case + including portions thereof. + + 1.4. "Electronic Distribution Mechanism" means a mechanism generally + accepted in the software development community for the electronic + transfer of data. + + 1.5. "Executable" means Covered Code in any form other than Source + Code. + + 1.6. "Initial Developer" means the individual or entity identified + as the Initial Developer in the Source Code notice required by Exhibit + A. + + 1.7. "Larger Work" means a work which combines Covered Code or + portions thereof with code not governed by the terms of this License. + + 1.8. "License" means this document. + + 1.8.1. "Licensable" means having the right to grant, to the maximum + extent possible, whether at the time of the initial grant or + subsequently acquired, any and all of the rights conveyed herein. + + 1.9. "Modifications" means any addition to or deletion from the + substance or structure of either the Original Code or any previous + Modifications. When Covered Code is released as a series of files, a + Modification is: + A. Any addition to or deletion from the contents of a file + containing Original Code or previous Modifications. + + B. Any new file that contains any part of the Original Code or + previous Modifications. + + 1.10. "Original Code" means Source Code of computer software code + which is described in the Source Code notice required by Exhibit A as + Original Code, and which, at the time of its release under this + License is not already Covered Code governed by this License. + + 1.10.1. "Patent Claims" means any patent claim(s), now owned or + hereafter acquired, including without limitation, method, process, + and apparatus claims, in any patent Licensable by grantor. + + 1.11. "Source Code" means the preferred form of the Covered Code for + making modifications to it, including all modules it contains, plus + any associated interface definition files, scripts used to control + compilation and installation of an Executable, or source code + differential comparisons against either the Original Code or another + well known, available Covered Code of the Contributor's choice. The + Source Code can be in a compressed or archival form, provided the + appropriate decompression or de-archiving software is widely available + for no charge. + + 1.12. "You" (or "Your") means an individual or a legal entity + exercising rights under, and complying with all of the terms of, this + License or a future version of this License issued under Section 6.1. + For legal entities, "You" includes any entity which controls, is + controlled by, or is under common control with You. For purposes of + this definition, "control" means (a) the power, direct or indirect, + to cause the direction or management of such entity, whether by + contract or otherwise, or (b) ownership of more than fifty percent + (50%) of the outstanding shares or beneficial ownership of such + entity. + +2. Source Code License. + + 2.1. The Initial Developer Grant. + The Initial Developer hereby grants You a world-wide, royalty-free, + non-exclusive license, subject to third party intellectual property + claims: + (a) under intellectual property rights (other than patent or + trademark) Licensable by Initial Developer to use, reproduce, + modify, display, perform, sublicense and distribute the Original + Code (or portions thereof) with or without Modifications, and/or + as part of a Larger Work; and + + (b) under Patents Claims infringed by the making, using or + selling of Original Code, to make, have made, use, practice, + sell, and offer for sale, and/or otherwise dispose of the + Original Code (or portions thereof). + + (c) the licenses granted in this Section 2.1(a) and (b) are + effective on the date Initial Developer first distributes + Original Code under the terms of this License. + + (d) Notwithstanding Section 2.1(b) above, no patent license is + granted: 1) for code that You delete from the Original Code; 2) + separate from the Original Code; or 3) for infringements caused + by: i) the modification of the Original Code or ii) the + combination of the Original Code with other software or devices. + + 2.2. Contributor Grant. + Subject to third party intellectual property claims, each Contributor + hereby grants You a world-wide, royalty-free, non-exclusive license + + (a) under intellectual property rights (other than patent or + trademark) Licensable by Contributor, to use, reproduce, modify, + display, perform, sublicense and distribute the Modifications + created by such Contributor (or portions thereof) either on an + unmodified basis, with other Modifications, as Covered Code + and/or as part of a Larger Work; and + + (b) under Patent Claims infringed by the making, using, or + selling of Modifications made by that Contributor either alone + and/or in combination with its Contributor Version (or portions + of such combination), to make, use, sell, offer for sale, have + made, and/or otherwise dispose of: 1) Modifications made by that + Contributor (or portions thereof); and 2) the combination of + Modifications made by that Contributor with its Contributor + Version (or portions of such combination). + + (c) the licenses granted in Sections 2.2(a) and 2.2(b) are + effective on the date Contributor first makes Commercial Use of + the Covered Code. + + (d) Notwithstanding Section 2.2(b) above, no patent license is + granted: 1) for any code that Contributor has deleted from the + Contributor Version; 2) separate from the Contributor Version; + 3) for infringements caused by: i) third party modifications of + Contributor Version or ii) the combination of Modifications made + by that Contributor with other software (except as part of the + Contributor Version) or other devices; or 4) under Patent Claims + infringed by Covered Code in the absence of Modifications made by + that Contributor. + +3. Distribution Obligations. + + 3.1. Application of License. + The Modifications which You create or to which You contribute are + governed by the terms of this License, including without limitation + Section 2.2. The Source Code version of Covered Code may be + distributed only under the terms of this License or a future version + of this License released under Section 6.1, and You must include a + copy of this License with every copy of the Source Code You + distribute. You may not offer or impose any terms on any Source Code + version that alters or restricts the applicable version of this + License or the recipients' rights hereunder. However, You may include + an additional document offering the additional rights described in + Section 3.5. + + 3.2. Availability of Source Code. + Any Modification which You create or to which You contribute must be + made available in Source Code form under the terms of this License + either on the same media as an Executable version or via an accepted + Electronic Distribution Mechanism to anyone to whom you made an + Executable version available; and if made available via Electronic + Distribution Mechanism, must remain available for at least twelve (12) + months after the date it initially became available, or at least six + (6) months after a subsequent version of that particular Modification + has been made available to such recipients. You are responsible for + ensuring that the Source Code version remains available even if the + Electronic Distribution Mechanism is maintained by a third party. + + 3.3. Description of Modifications. + You must cause all Covered Code to which You contribute to contain a + file documenting the changes You made to create that Covered Code and + the date of any change. You must include a prominent statement that + the Modification is derived, directly or indirectly, from Original + Code provided by the Initial Developer and including the name of the + Initial Developer in (a) the Source Code, and (b) in any notice in an + Executable version or related documentation in which You describe the + origin or ownership of the Covered Code. + + 3.4. Intellectual Property Matters + (a) Third Party Claims. + If Contributor has knowledge that a license under a third party's + intellectual property rights is required to exercise the rights + granted by such Contributor under Sections 2.1 or 2.2, + Contributor must include a text file with the Source Code + distribution titled "LEGAL" which describes the claim and the + party making the claim in sufficient detail that a recipient will + know whom to contact. If Contributor obtains such knowledge after + the Modification is made available as described in Section 3.2, + Contributor shall promptly modify the LEGAL file in all copies + Contributor makes available thereafter and shall take other steps + (such as notifying appropriate mailing lists or newsgroups) + reasonably calculated to inform those who received the Covered + Code that new knowledge has been obtained. + + (b) Contributor APIs. + If Contributor's Modifications include an application programming + interface and Contributor has knowledge of patent licenses which + are reasonably necessary to implement that API, Contributor must + also include this information in the LEGAL file. + + (c) Representations. + Contributor represents that, except as disclosed pursuant to + Section 3.4(a) above, Contributor believes that Contributor's + Modifications are Contributor's original creation(s) and/or + Contributor has sufficient rights to grant the rights conveyed by + this License. + + 3.5. Required Notices. + You must duplicate the notice in Exhibit A in each file of the Source + Code. If it is not possible to put such notice in a particular Source + Code file due to its structure, then You must include such notice in a + location (such as a relevant directory) where a user would be likely + to look for such a notice. If You created one or more Modification(s) + You may add your name as a Contributor to the notice described in + Exhibit A. You must also duplicate this License in any documentation + for the Source Code where You describe recipients' rights or ownership + rights relating to Covered Code. You may choose to offer, and to + charge a fee for, warranty, support, indemnity or liability + obligations to one or more recipients of Covered Code. However, You + may do so only on Your own behalf, and not on behalf of the Initial + Developer or any Contributor. You must make it absolutely clear than + any such warranty, support, indemnity or liability obligation is + offered by You alone, and You hereby agree to indemnify the Initial + Developer and every Contributor for any liability incurred by the + Initial Developer or such Contributor as a result of warranty, + support, indemnity or liability terms You offer. + + 3.6. Distribution of Executable Versions. + You may distribute Covered Code in Executable form only if the + requirements of Section 3.1-3.5 have been met for that Covered Code, + and if You include a notice stating that the Source Code version of + the Covered Code is available under the terms of this License, + including a description of how and where You have fulfilled the + obligations of Section 3.2. The notice must be conspicuously included + in any notice in an Executable version, related documentation or + collateral in which You describe recipients' rights relating to the + Covered Code. You may distribute the Executable version of Covered + Code or ownership rights under a license of Your choice, which may + contain terms different from this License, provided that You are in + compliance with the terms of this License and that the license for the + Executable version does not attempt to limit or alter the recipient's + rights in the Source Code version from the rights set forth in this + License. If You distribute the Executable version under a different + license You must make it absolutely clear that any terms which differ + from this License are offered by You alone, not by the Initial + Developer or any Contributor. You hereby agree to indemnify the + Initial Developer and every Contributor for any liability incurred by + the Initial Developer or such Contributor as a result of any such + terms You offer. + + 3.7. Larger Works. + You may create a Larger Work by combining Covered Code with other code + not governed by the terms of this License and distribute the Larger + Work as a single product. In such a case, You must make sure the + requirements of this License are fulfilled for the Covered Code. + +4. Inability to Comply Due to Statute or Regulation. + + If it is impossible for You to comply with any of the terms of this + License with respect to some or all of the Covered Code due to + statute, judicial order, or regulation then You must: (a) comply with + the terms of this License to the maximum extent possible; and (b) + describe the limitations and the code they affect. Such description + must be included in the LEGAL file described in Section 3.4 and must + be included with all distributions of the Source Code. Except to the + extent prohibited by statute or regulation, such description must be + sufficiently detailed for a recipient of ordinary skill to be able to + understand it. + +5. Application of this License. + + This License applies to code to which the Initial Developer has + attached the notice in Exhibit A and to related Covered Code. + +6. Versions of the License. + + 6.1. New Versions. + Netscape Communications Corporation ("Netscape") may publish revised + and/or new versions of the License from time to time. Each version + will be given a distinguishing version number. + + 6.2. Effect of New Versions. + Once Covered Code has been published under a particular version of the + License, You may always continue to use it under the terms of that + version. You may also choose to use such Covered Code under the terms + of any subsequent version of the License published by Netscape. No one + other than Netscape has the right to modify the terms applicable to + Covered Code created under this License. + + 6.3. Derivative Works. + If You create or use a modified version of this License (which you may + only do in order to apply it to code which is not already Covered Code + governed by this License), You must (a) rename Your license so that + the phrases "Mozilla", "MOZILLAPL", "MOZPL", "Netscape", + "MPL", "NPL" or any confusingly similar phrase do not appear in your + license (except to note that your license differs from this License) + and (b) otherwise make it clear that Your version of the license + contains terms which differ from the Mozilla Public License and + Netscape Public License. (Filling in the name of the Initial + Developer, Original Code or Contributor in the notice described in + Exhibit A shall not of themselves be deemed to be modifications of + this License.) + +7. DISCLAIMER OF WARRANTY. + + COVERED CODE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" BASIS, + WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, + WITHOUT LIMITATION, WARRANTIES THAT THE COVERED CODE IS FREE OF + DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. + THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED CODE + IS WITH YOU. SHOULD ANY COVERED CODE PROVE DEFECTIVE IN ANY RESPECT, + YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE + COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER + OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF + ANY COVERED CODE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. + +8. TERMINATION. + + 8.1. This License and the rights granted hereunder will terminate + automatically if You fail to comply with terms herein and fail to cure + such breach within 30 days of becoming aware of the breach. All + sublicenses to the Covered Code which are properly granted shall + survive any termination of this License. Provisions which, by their + nature, must remain in effect beyond the termination of this License + shall survive. + + 8.2. If You initiate litigation by asserting a patent infringement + claim (excluding declatory judgment actions) against Initial Developer + or a Contributor (the Initial Developer or Contributor against whom + You file such action is referred to as "Participant") alleging that: + + (a) such Participant's Contributor Version directly or indirectly + infringes any patent, then any and all rights granted by such + Participant to You under Sections 2.1 and/or 2.2 of this License + shall, upon 60 days notice from Participant terminate prospectively, + unless if within 60 days after receipt of notice You either: (i) + agree in writing to pay Participant a mutually agreeable reasonable + royalty for Your past and future use of Modifications made by such + Participant, or (ii) withdraw Your litigation claim with respect to + the Contributor Version against such Participant. If within 60 days + of notice, a reasonable royalty and payment arrangement are not + mutually agreed upon in writing by the parties or the litigation claim + is not withdrawn, the rights granted by Participant to You under + Sections 2.1 and/or 2.2 automatically terminate at the expiration of + the 60 day notice period specified above. + + (b) any software, hardware, or device, other than such Participant's + Contributor Version, directly or indirectly infringes any patent, then + any rights granted to You by such Participant under Sections 2.1(b) + and 2.2(b) are revoked effective as of the date You first made, used, + sold, distributed, or had made, Modifications made by that + Participant. + + 8.3. If You assert a patent infringement claim against Participant + alleging that such Participant's Contributor Version directly or + indirectly infringes any patent where such claim is resolved (such as + by license or settlement) prior to the initiation of patent + infringement litigation, then the reasonable value of the licenses + granted by such Participant under Sections 2.1 or 2.2 shall be taken + into account in determining the amount or value of any payment or + license. + + 8.4. In the event of termination under Sections 8.1 or 8.2 above, + all end user license agreements (excluding distributors and resellers) + which have been validly granted by You or any distributor hereunder + prior to termination shall survive termination. + +9. LIMITATION OF LIABILITY. + + UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT + (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL + DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED CODE, + OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR + ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY + CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS OF GOODWILL, + WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER + COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN + INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF + LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY + RESULTING FROM SUCH PARTY'S NEGLIGENCE TO THE EXTENT APPLICABLE LAW + PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE + EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO + THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. + +10. U.S. GOVERNMENT END USERS. + + The Covered Code is a "commercial item," as that term is defined in + 48 C.F.R. 2.101 (Oct. 1995), consisting of "commercial computer + software" and "commercial computer software documentation," as such + terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48 + C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995), + all U.S. Government End Users acquire Covered Code with only those + rights set forth herein. + +11. MISCELLANEOUS. + + This License represents the complete agreement concerning subject + matter hereof. If any provision of this License is held to be + unenforceable, such provision shall be reformed only to the extent + necessary to make it enforceable. This License shall be governed by + California law provisions (except to the extent applicable law, if + any, provides otherwise), excluding its conflict-of-law provisions. + With respect to disputes in which at least one party is a citizen of, + or an entity chartered or registered to do business in the United + States of America, any litigation relating to this License shall be + subject to the jurisdiction of the Federal Courts of the Northern + District of California, with venue lying in Santa Clara County, + California, with the losing party responsible for costs, including + without limitation, court costs and reasonable attorneys' fees and + expenses. The application of the United Nations Convention on + Contracts for the International Sale of Goods is expressly excluded. + Any law or regulation which provides that the language of a contract + shall be construed against the drafter shall not apply to this + License. + +12. RESPONSIBILITY FOR CLAIMS. + + As between Initial Developer and the Contributors, each party is + responsible for claims and damages arising, directly or indirectly, + out of its utilization of rights under this License and You agree to + work with Initial Developer and Contributors to distribute such + responsibility on an equitable basis. Nothing herein is intended or + shall be deemed to constitute any admission of liability. + +13. MULTIPLE-LICENSED CODE. + + Initial Developer may designate portions of the Covered Code as + "Multiple-Licensed". "Multiple-Licensed" means that the Initial + Developer permits you to utilize portions of the Covered Code under + Your choice of the NPL or the alternative licenses, if any, specified + by the Initial Developer in the file described in Exhibit A. + +EXHIBIT A -Mozilla Public License. + + ``The contents of this file are subject to the Mozilla Public License + Version 1.1 (the "License"); you may not use this file except in + compliance with the License. You may obtain a copy of the License at + http://www.mozilla.org/MPL/ + + Software distributed under the License is distributed on an "AS IS" + basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the + License for the specific language governing rights and limitations + under the License. + + The Original Code is ______________________________________. + + The Initial Developer of the Original Code is ________________________. + Portions created by ______________________ are Copyright (C) ______ + _______________________. All Rights Reserved. + + Contributor(s): ______________________________________. + + Alternatively, the contents of this file may be used under the terms + of the _____ license (the "[___] License"), in which case the + provisions of [______] License are applicable instead of those + above. If you wish to allow use of your version of this file only + under the terms of the [____] License and not to allow others to use + your version of this file under the MPL, indicate your decision by + deleting the provisions above and replace them with the notice and + other provisions required by the [___] License. If you do not delete + the provisions above, a recipient may use your version of this file + under either the MPL or the [___] License." + + [NOTE: The text of this Exhibit A may differ slightly from the text of + the notices in the Source Code files of the Original Code. You should + use the text of this Exhibit A rather than the text found in the + Original Code Source Code for Your Modifications.] diff --git a/bbs/ckeditor/README.md b/bbs/ckeditor/README.md new file mode 100644 index 000000000..68f930b93 --- /dev/null +++ b/bbs/ckeditor/README.md @@ -0,0 +1,39 @@ +CKEditor 4 +========== + +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +http://ckeditor.com - See LICENSE.md for license information. + +CKEditor is a text editor to be used inside web pages. It's not a replacement +for desktop text editors like Word or OpenOffice, but a component to be used as +part of web applications and websites. + +## Documentation + +The full editor documentation is available online at the following address: +http://docs.ckeditor.com + +## Installation + +Installing CKEditor is an easy task. Just follow these simple steps: + + 1. **Download** the latest version from the CKEditor website: + http://ckeditor.com. You should have already completed this step, but be + sure you have the very latest version. + 2. **Extract** (decompress) the downloaded file into the root of your website. + +**Note:** CKEditor is by default installed in the `ckeditor` folder. You can +place the files in whichever you want though. + +## Checking Your Installation + +The editor comes with a few sample pages that can be used to verify that +installation proceeded properly. Take a look at the `samples` directory. + +To test your installation, just call the following page at your website: + + http:////samples/index.html + +For example: + + http://www.example.com/ckeditor/samples/index.html diff --git a/bbs/ckeditor/build-config.js b/bbs/ckeditor/build-config.js new file mode 100644 index 000000000..0d0a54da1 --- /dev/null +++ b/bbs/ckeditor/build-config.js @@ -0,0 +1,158 @@ + +/** + * @license Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. + * For licensing, see LICENSE.html or http://ckeditor.com/license + */ + +/** + * This file was added automatically by CKEditor builder. + * You may re-use it at any time at http://ckeditor.com/builder to build CKEditor again. + * + * NOTE: + * This file is not used by CKEditor, you may remove it. + * Changing this file will not change your CKEditor configuration. + */ + +var CKBUILDER_CONFIG = { + skin: 'moono', + preset: 'full', + ignore: [ + 'dev', + '.gitignore', + '.gitattributes', + 'README.md', + '.mailmap' + ], + plugins : { + 'about' : 1, + 'a11yhelp' : 1, + 'dialogadvtab' : 1, + 'basicstyles' : 1, + 'bidi' : 1, + 'blockquote' : 1, + 'clipboard' : 1, + 'colorbutton' : 1, + 'colordialog' : 1, + 'templates' : 1, + 'contextmenu' : 1, + 'div' : 1, + 'resize' : 1, + 'toolbar' : 1, + 'elementspath' : 1, + 'enterkey' : 1, + 'entities' : 1, + 'filebrowser' : 1, + 'find' : 1, + 'flash' : 1, + 'floatingspace' : 1, + 'font' : 1, + 'forms' : 1, + 'format' : 1, + 'htmlwriter' : 1, + 'horizontalrule' : 1, + 'iframe' : 1, + 'wysiwygarea' : 1, + 'image' : 1, + 'indent' : 1, + 'smiley' : 1, + 'justify' : 1, + 'link' : 1, + 'list' : 1, + 'liststyle' : 1, + 'magicline' : 1, + 'maximize' : 1, + 'newpage' : 1, + 'pagebreak' : 1, + 'pastetext' : 1, + 'pastefromword' : 1, + 'preview' : 1, + 'print' : 1, + 'removeformat' : 1, + 'save' : 1, + 'selectall' : 1, + 'showblocks' : 1, + 'showborders' : 1, + 'sourcearea' : 1, + 'specialchar' : 1, + 'stylescombo' : 1, + 'tab' : 1, + 'table' : 1, + 'tabletools' : 1, + 'undo' : 1, + 'dialog' : 1, + 'dialogui' : 1, + 'panelbutton' : 1, + 'button' : 1, + 'floatpanel' : 1, + 'panel' : 1, + 'menu' : 1, + 'popup' : 1, + 'fakeobjects' : 1, + 'richcombo' : 1, + 'listblock' : 1 + }, + languages : { + 'af' : 1, + 'ar' : 1, + 'eu' : 1, + 'bn' : 1, + 'bs' : 1, + 'bg' : 1, + 'ca' : 1, + 'zh-cn' : 1, + 'zh' : 1, + 'hr' : 1, + 'cs' : 1, + 'da' : 1, + 'nl' : 1, + 'en' : 1, + 'en-au' : 1, + 'en-ca' : 1, + 'en-gb' : 1, + 'eo' : 1, + 'et' : 1, + 'fo' : 1, + 'fi' : 1, + 'fr' : 1, + 'fr-ca' : 1, + 'gl' : 1, + 'ka' : 1, + 'de' : 1, + 'el' : 1, + 'gu' : 1, + 'he' : 1, + 'hi' : 1, + 'hu' : 1, + 'is' : 1, + 'it' : 1, + 'ja' : 1, + 'km' : 1, + 'ko' : 1, + 'ku' : 1, + 'lv' : 1, + 'lt' : 1, + 'mk' : 1, + 'ms' : 1, + 'mn' : 1, + 'no' : 1, + 'nb' : 1, + 'fa' : 1, + 'pl' : 1, + 'pt-br' : 1, + 'pt' : 1, + 'ro' : 1, + 'ru' : 1, + 'sr' : 1, + 'sr-latn' : 1, + 'sk' : 1, + 'sl' : 1, + 'es' : 1, + 'sv' : 1, + 'th' : 1, + 'tr' : 1, + 'ug' : 1, + 'uk' : 1, + 'vi' : 1, + 'cy' : 1, + } +}; \ No newline at end of file diff --git a/bbs/ckeditor/ckeditor.js b/bbs/ckeditor/ckeditor.js new file mode 100644 index 000000000..b8f3d548c --- /dev/null +++ b/bbs/ckeditor/ckeditor.js @@ -0,0 +1,890 @@ +/* +Copyright (c) 2003-2012, CKSource - Frederico Knabben. All rights reserved. +For licensing, see LICENSE.html or http://ckeditor.com/license +*/ +(function(){if(window.CKEDITOR&&window.CKEDITOR.dom)return;window.CKEDITOR||(window.CKEDITOR=function(){var b={timestamp:"CAPD",version:"4.0",revision:"769d96134b",rnd:Math.floor(900*Math.random())+100,_:{pending:[]},status:"unloaded",basePath:function(){var a=window.CKEDITOR_BASEPATH||"";if(!a)for(var b=document.getElementsByTagName("script"),d=0;d=0;o--)if(m[o].priority<=k){m.splice(o+1,0,h);return{removeListener:l}}m.unshift(h)}return{removeListener:l}}, +once:function(){var a=arguments[1];arguments[1]=function(b){b.removeListener();return a.apply(this,arguments)};return this.on.apply(this,arguments)},capture:function(){CKEDITOR.event.useCapture=1;var a=this.on.apply(this,arguments);CKEDITOR.event.useCapture=0;return a},fire:function(){var a=0,b=function(){a=1},d=0,g=function(){d=1};return function(k,h,l){var m=c(this)[k],k=a,n=d;a=d=0;if(m){var o=m.listeners;if(o.length)for(var o=o.slice(0),i,q=0;q=0&&d.listeners.splice(g,1)}},removeAllListeners:function(){var a=c(this),b;for(b in a)delete a[b]},hasListeners:function(a){return(a=c(this)[a])&&a.listeners.length>0}}}()); +CKEDITOR.editor||(CKEDITOR.editor=function(){CKEDITOR._.pending.push([this,arguments]);CKEDITOR.event.call(this)},CKEDITOR.editor.prototype.fire=function(b,c){b in{instanceReady:1,loaded:1}&&(this[b]=true);return CKEDITOR.event.prototype.fire.call(this,b,c,this)},CKEDITOR.editor.prototype.fireOnce=function(b,c){b in{instanceReady:1,loaded:1}&&(this[b]=true);return CKEDITOR.event.prototype.fireOnce.call(this,b,c,this)},CKEDITOR.event.implementOn(CKEDITOR.editor.prototype,!0)); +CKEDITOR.env||(CKEDITOR.env=function(){var b=navigator.userAgent.toLowerCase(),c=window.opera,a={ie:eval("/*@cc_on!@*/false"),opera:!!c&&c.version,webkit:b.indexOf(" applewebkit/")>-1,air:b.indexOf(" adobeair/")>-1,mac:b.indexOf("macintosh")>-1,quirks:document.compatMode=="BackCompat",mobile:b.indexOf("mobile")>-1,iOS:/(ipad|iphone|ipod)/.test(b),isCustomDomain:function(){if(!this.ie)return false;var a=document.domain,b=window.location.hostname;return a!=b&&a!="["+b+"]"},secure:location.protocol== +"https:"};a.gecko=navigator.product=="Gecko"&&!a.webkit&&!a.opera;if(a.webkit)b.indexOf("chrome")>-1?a.chrome=true:a.safari=true;var f=0;if(a.ie){f=a.quirks||!document.documentMode?parseFloat(b.match(/msie (\d+)/)[1]):document.documentMode;a.ie9Compat=f==9;a.ie8Compat=f==8;a.ie7Compat=f==7;a.ie6Compat=f<7||a.quirks}if(a.gecko){var e=b.match(/rv:([\d\.]+)/);if(e){e=e[1].split(".");f=e[0]*1E4+(e[1]||0)*100+(e[2]||0)*1}}a.opera&&(f=parseFloat(c.version()));a.air&&(f=parseFloat(b.match(/ adobeair\/(\d+)/)[1])); +a.webkit&&(f=parseFloat(b.match(/ applewebkit\/(\d+)/)[1]));a.version=f;a.isCompatible=a.iOS&&f>=534||!a.mobile&&(a.ie&&f>6||a.gecko&&f>=10801||a.opera&&f>=9.5||a.air&&f>=1||a.webkit&&f>=522||false);a.cssClass="cke_browser_"+(a.ie?"ie":a.gecko?"gecko":a.opera?"opera":a.webkit?"webkit":"unknown");if(a.quirks)a.cssClass=a.cssClass+" cke_browser_quirks";if(a.ie){a.cssClass=a.cssClass+(" cke_browser_ie"+(a.quirks||a.version<7?"6":a.version));if(a.quirks)a.cssClass=a.cssClass+" cke_browser_iequirks"}if(a.gecko&& +f<10900)a.cssClass=a.cssClass+" cke_browser_gecko18";if(a.air)a.cssClass=a.cssClass+" cke_browser_air";return a}()); +"unloaded"==CKEDITOR.status&&function(){CKEDITOR.event.implementOn(CKEDITOR);CKEDITOR.loadFullCore=function(){if(CKEDITOR.status!="basic_ready")CKEDITOR.loadFullCore._load=1;else{delete CKEDITOR.loadFullCore;var b=document.createElement("script");b.type="text/javascript";b.src=CKEDITOR.basePath+"ckeditor.js";document.getElementsByTagName("head")[0].appendChild(b)}};CKEDITOR.loadFullCoreTimeout=0;CKEDITOR.add=function(b){(this._.pending||(this._.pending=[])).push(b)};(function(){CKEDITOR.domReady(function(){var b= +CKEDITOR.loadFullCore,c=CKEDITOR.loadFullCoreTimeout;if(b){CKEDITOR.status="basic_ready";b&&b._load?b():c&&setTimeout(function(){CKEDITOR.loadFullCore&&CKEDITOR.loadFullCore()},c*1E3)}})})();CKEDITOR.status="basic_loaded"}();CKEDITOR.dom={}; +(function(){var b=[],c=CKEDITOR.env.gecko?"-moz-":CKEDITOR.env.webkit?"-webkit-":CKEDITOR.env.opera?"-o-":CKEDITOR.env.ie?"-ms-":"";CKEDITOR.on("reset",function(){b=[]});CKEDITOR.tools={arrayCompare:function(a,b){if(!a&&!b)return true;if(!a||!b||a.length!=b.length)return false;for(var e=0;e"+b+""):e.push('');return e.join("")},htmlEncode:function(a){return(""+a).replace(/&/g,"&").replace(/>/g,">").replace(//g,">")},getNextNumber:function(){var a= +0;return function(){return++a}}(),getNextId:function(){return"cke_"+this.getNextNumber()},override:function(a,b){var e=b(a);e.prototype=a.prototype;return e},setTimeout:function(a,b,e,c,g){g||(g=window);e||(e=g);return g.setTimeout(function(){c?a.apply(e,[].concat(c)):a.apply(e)},b||0)},trim:function(){var a=/(?:^[ \t\n\r]+)|(?:[ \t\n\r]+$)/g;return function(b){return b.replace(a,"")}}(),ltrim:function(){var a=/^[ \t\n\r]+/g;return function(b){return b.replace(a,"")}}(),rtrim:function(){var a=/[ \t\n\r]+$/g; +return function(b){return b.replace(a,"")}}(),indexOf:function(a,b){if(typeof b=="function")for(var c=0,d=a.length;c=0?a[c]:null},bind:function(a,b){return function(){return a.apply(b,arguments)}},createClass:function(a){var b=a.$,c=a.base,d=a.privates||a._,g=a.proto,a=a.statics;!b&&(b=function(){c&&this.base.apply(this, +arguments)});if(d)var k=b,b=function(){var a=this._||(this._={}),b;for(b in d){var f=d[b];a[b]=typeof f=="function"?CKEDITOR.tools.bind(f,this):f}k.apply(this,arguments)};if(c){b.prototype=this.prototypedCopy(c.prototype);b.prototype.constructor=b;b.base=c;b.baseProto=c.prototype;b.prototype.base=function(){this.base=c.prototype.base;c.apply(this,arguments);this.base=arguments.callee}}g&&this.extend(b.prototype,g,true);a&&this.extend(b,a,true);return b},addFunction:function(a,f){return b.push(function(){return a.apply(f|| +this,arguments)})-1},removeFunction:function(a){b[a]=null},callFunction:function(a){var f=b[a];return f&&f.apply(window,Array.prototype.slice.call(arguments,1))},cssLength:function(){var a=/^-?\d+\.?\d*px$/,b;return function(c){b=CKEDITOR.tools.trim(c+"")+"px";return a.test(b)?b:c||""}}(),convertToPx:function(){var a;return function(b){if(!a){a=CKEDITOR.dom.element.createFromHtml('
    ',CKEDITOR.document); +CKEDITOR.document.getBody().append(a)}if(!/%$/.test(b)){a.setStyle("width",b);return a.$.clientWidth}return b}}(),repeat:function(a,b){return Array(b+1).join(a)},tryThese:function(){for(var a,b=0,c=arguments.length;b8)&&c)b=c+":"+b;return new CKEDITOR.dom.nodeList(this.$.getElementsByTagName(b))},getHead:function(){var b=this.$.getElementsByTagName("head")[0];return b= +b?new CKEDITOR.dom.element(b):this.getDocumentElement().append(new CKEDITOR.dom.element("head"),true)},getBody:function(){return new CKEDITOR.dom.element(this.$.body)},getDocumentElement:function(){return new CKEDITOR.dom.element(this.$.documentElement)},getWindow:function(){var b=new CKEDITOR.dom.window(this.$.parentWindow||this.$.defaultView);return(this.getWindow=function(){return b})()},write:function(b){this.$.open("text/html","replace");CKEDITOR.env.isCustomDomain()&&(this.$.domain=document.domain); +this.$.write(b);this.$.close()}});CKEDITOR.dom.nodeList=function(b){this.$=b};CKEDITOR.dom.nodeList.prototype={count:function(){return this.$.length},getItem:function(b){if(b<0||b>=this.$.length)return null;return(b=this.$[b])?new CKEDITOR.dom.node(b):null}};CKEDITOR.dom.element=function(b,c){typeof b=="string"&&(b=(c?c.$:document).createElement(b));CKEDITOR.dom.domObject.call(this,b)}; +CKEDITOR.dom.element.get=function(b){return(b=typeof b=="string"?document.getElementById(b)||document.getElementsByName(b)[0]:b)&&(b.$?b:new CKEDITOR.dom.element(b))};CKEDITOR.dom.element.prototype=new CKEDITOR.dom.node;CKEDITOR.dom.element.createFromHtml=function(b,c){var a=new CKEDITOR.dom.element("div",c);a.setHtml(b);return a.getFirst().remove()}; +CKEDITOR.dom.element.setMarker=function(b,c,a,f){var e=c.getCustomData("list_marker_id")||c.setCustomData("list_marker_id",CKEDITOR.tools.getNextNumber()).getCustomData("list_marker_id"),d=c.getCustomData("list_marker_names")||c.setCustomData("list_marker_names",{}).getCustomData("list_marker_names");b[e]=c;d[a]=1;return c.setCustomData(a,f)};CKEDITOR.dom.element.clearAllMarkers=function(b){for(var c in b)CKEDITOR.dom.element.clearMarkers(b,b[c],1)}; +CKEDITOR.dom.element.clearMarkers=function(b,c,a){var f=c.getCustomData("list_marker_names"),e=c.getCustomData("list_marker_id"),d;for(d in f)c.removeCustomData(d);c.removeCustomData("list_marker_names");if(a){c.removeCustomData("list_marker_id");delete b[e]}}; +(function(){function b(a){for(var b=0,e=0,d=c[a].length;e]*>/g, +""):a},getOuterHtml:function(){if(this.$.outerHTML)return this.$.outerHTML.replace(/<\?[^>]*>/,"");var a=this.$.ownerDocument.createElement("div");a.appendChild(this.$.cloneNode(true));return a.innerHTML},getClientRect:function(){var a=CKEDITOR.tools.extend({},this.$.getBoundingClientRect());!a.width&&(a.width=a.right-a.left);!a.height&&(a.height=a.bottom-a.top);return a},setHtml:function(){var a=function(a){return this.$.innerHTML=a};return CKEDITOR.env.ie&&CKEDITOR.env.version<9?function(a){try{return this.$.innerHTML= +a}catch(b){this.$.innerHTML="";var c=new CKEDITOR.dom.element("body",this.getDocument());c.$.innerHTML=a;for(c=c.getChildren();c.count();)this.append(c.getItem(0));return a}}:a}(),setText:function(a){CKEDITOR.dom.element.prototype.setText=this.$.innerText!=void 0?function(a){return this.$.innerText=a}:function(a){return this.$.textContent=a};return this.setText(a)},getAttribute:function(){var a=function(a){return this.$.getAttribute(a,2)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)? +function(a){switch(a){case "class":a="className";break;case "http-equiv":a="httpEquiv";break;case "name":return this.$.name;case "tabindex":a=this.$.getAttribute(a,2);a!==0&&this.$.tabIndex===0&&(a=null);return a;case "checked":a=this.$.attributes.getNamedItem(a);return(a.specified?a.nodeValue:this.$.checked)?"checked":null;case "hspace":case "value":return this.$[a];case "style":return this.$.style.cssText;case "contenteditable":case "contentEditable":return this.$.attributes.getNamedItem("contentEditable").specified? +this.$.getAttribute("contentEditable"):null}return this.$.getAttribute(a,2)}:a}(),getChildren:function(){return new CKEDITOR.dom.nodeList(this.$.childNodes)},getComputedStyle:CKEDITOR.env.ie?function(a){return this.$.currentStyle[CKEDITOR.tools.cssStyleToDomStyle(a)]}:function(a){var b=this.getWindow().$.getComputedStyle(this.$,null);return b?b.getPropertyValue(a):""},getDtd:function(){var a=CKEDITOR.dtd[this.getName()];this.getDtd=function(){return a};return a},getElementsByTag:CKEDITOR.dom.document.prototype.getElementsByTag, +getTabIndex:CKEDITOR.env.ie?function(){var a=this.$.tabIndex;a===0&&(!CKEDITOR.dtd.$tabIndex[this.getName()]&&parseInt(this.getAttribute("tabindex"),10)!==0)&&(a=-1);return a}:CKEDITOR.env.webkit?function(){var a=this.$.tabIndex;if(a==void 0){a=parseInt(this.getAttribute("tabindex"),10);isNaN(a)&&(a=-1)}return a}:function(){return this.$.tabIndex},getText:function(){return this.$.textContent||this.$.innerText||""},getWindow:function(){return this.getDocument().getWindow()},getId:function(){return this.$.id|| +null},getNameAtt:function(){return this.$.name||null},getName:function(){var a=this.$.nodeName.toLowerCase();if(CKEDITOR.env.ie&&!(document.documentMode>8)){var b=this.$.scopeName;b!="HTML"&&(a=b.toLowerCase()+":"+a)}return(this.getName=function(){return a})()},getValue:function(){return this.$.value},getFirst:function(a){var b=this.$.firstChild;(b=b&&new CKEDITOR.dom.node(b))&&(a&&!a(b))&&(b=b.getNext(a));return b},getLast:function(a){var b=this.$.lastChild;(b=b&&new CKEDITOR.dom.node(b))&&(a&&!a(b))&& +(b=b.getPrevious(a));return b},getStyle:function(a){return this.$.style[CKEDITOR.tools.cssStyleToDomStyle(a)]},is:function(){var a=this.getName();if(typeof arguments[0]=="object")return!!arguments[0][a];for(var b=0;b0&&(b>2||!c[a[0].nodeName]||b==2&&!c[a[1].nodeName])},hasAttribute:function(){function a(a){a=this.$.attributes.getNamedItem(a); +return!(!a||!a.specified)}return CKEDITOR.env.ie&&CKEDITOR.env.version<8?function(b){return b=="name"?!!this.$.name:a.call(this,b)}:a}(),hide:function(){this.setStyle("display","none")},moveChildren:function(a,b){var c=this.$,a=a.$;if(c!=a){var d;if(b)for(;d=c.lastChild;)a.insertBefore(c.removeChild(d),a.firstChild);else for(;d=c.firstChild;)a.appendChild(c.removeChild(d))}},mergeSiblings:function(){function a(a,b,c){if(b&&b.type==CKEDITOR.NODE_ELEMENT){for(var g=[];b.data("cke-bookmark")||b.isEmptyInlineRemoveable();){g.push(b); +b=c?b.getNext():b.getPrevious();if(!b||b.type!=CKEDITOR.NODE_ELEMENT)return}if(a.isIdentical(b)){for(var k=c?a.getLast():a.getFirst();g.length;)g.shift().move(a,!c);b.moveChildren(a,!c);b.remove();k&&k.type==CKEDITOR.NODE_ELEMENT&&k.mergeSiblings()}}}return function(b){if(b===false||CKEDITOR.dtd.$removeEmpty[this.getName()]||this.is("a")){a(this,this.getNext(),true);a(this,this.getPrevious())}}}(),show:function(){this.setStyles({display:"",visibility:""})},setAttribute:function(){var a=function(a, +b){this.$.setAttribute(a,b);return this};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)?function(b,c){b=="class"?this.$.className=c:b=="style"?this.$.style.cssText=c:b=="tabindex"?this.$.tabIndex=c:b=="checked"?this.$.checked=c:b=="contenteditable"?a.call(this,"contentEditable",c):a.apply(this,arguments);return this}:CKEDITOR.env.ie8Compat&&CKEDITOR.env.secure?function(b,c){if(b=="src"&&c.match(/^http:\/\//))try{a.apply(this,arguments)}catch(d){}else a.apply(this,arguments); +return this}:a}(),setAttributes:function(a){for(var b in a)this.setAttribute(b,a[b]);return this},setValue:function(a){this.$.value=a;return this},removeAttribute:function(){var a=function(a){this.$.removeAttribute(a)};return CKEDITOR.env.ie&&(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)?function(a){a=="class"?a="className":a=="tabindex"?a="tabIndex":a=="contenteditable"&&(a="contentEditable");this.$.removeAttribute(a)}:a}(),removeAttributes:function(a){if(CKEDITOR.tools.isArray(a))for(var b=0;b< +a.length;b++)this.removeAttribute(a[b]);else for(b in a)a.hasOwnProperty(b)&&this.removeAttribute(b)},removeStyle:function(a){var b=this.$.style;if(!b.removeProperty&&(a=="border"||a=="margin"||a=="padding")){var c=["top","left","right","bottom"],d;a=="border"&&(d=["color","style","width"]);for(var b=[],g=0;g=100?"":"progid:DXImageTransform.Microsoft.Alpha(opacity="+a+")")}else this.setStyle("opacity",a)},unselectable:function(){this.setStyles(CKEDITOR.tools.cssVendorPrefix("user-select", +"none"));if(CKEDITOR.env.ie||CKEDITOR.env.opera){this.setAttribute("unselectable","on");for(var a,b=this.getElementsByTag("*"),c=0,d=b.count();c0)l(0,b===true?h:b===false?g:h<0?h:g);if(c&&(k<0||d>0))l(k<0?k:d,0)},setState:function(a,b,c){b=b||"cke";switch(a){case CKEDITOR.TRISTATE_ON:this.addClass(b+"_on");this.removeClass(b+"_off");this.removeClass(b+"_disabled");c&&this.setAttribute("aria-pressed",true);c&&this.removeAttribute("aria-disabled"); +break;case CKEDITOR.TRISTATE_DISABLED:this.addClass(b+"_disabled");this.removeClass(b+"_off");this.removeClass(b+"_on");c&&this.setAttribute("aria-disabled",true);c&&this.removeAttribute("aria-pressed");break;default:this.addClass(b+"_off");this.removeClass(b+"_on");this.removeClass(b+"_disabled");c&&this.removeAttribute("aria-pressed");c&&this.removeAttribute("aria-disabled")}},getFrameDocument:function(){var a=this.$;try{a.contentWindow.document}catch(b){a.src=a.src}return a&&new CKEDITOR.dom.document(a.contentWindow.document)}, +copyAttributes:function(a,b){for(var c=this.$.attributes,b=b||{},d=0;d=0&&b0&&c;)c=a(c,b.shift());else c=a(c,b);return c?new CKEDITOR.dom.node(c):null}}(),getChildCount:function(){return this.$.childNodes.length},disableContextMenu:function(){this.on("contextmenu", +function(a){a.data.getTarget().hasClass("cke_enable_context_menu")||a.data.preventDefault()})},getDirection:function(a){return a?this.getComputedStyle("direction")||this.getDirection()||this.getParent()&&this.getParent().getDirection(1)||this.getDocument().$.dir||"ltr":this.getStyle("direction")||this.getAttribute("dir")},data:function(a,b){a="data-"+a;if(b===void 0)return this.getAttribute(a);b===false?this.removeAttribute(a):this.setAttribute(a,b);return null},getEditor:function(){var a=CKEDITOR.instances, +b,c;for(b in a){c=a[b];if(c.element.equals(this)&&c.elementMode!=CKEDITOR.ELEMENT_MODE_APPENDTO)return c}return null}});var c={width:["border-left-width","border-right-width","padding-left","padding-right"],height:["border-top-width","border-bottom-width","padding-top","padding-bottom"]};CKEDITOR.dom.element.prototype.setSize=function(a,c,e){if(typeof c=="number"){if(e&&(!CKEDITOR.env.ie||!CKEDITOR.env.quirks))c=c-b.call(this,a);this.setStyle(a,c+"px")}};CKEDITOR.dom.element.prototype.getSize=function(a, +c){var e=Math.max(this.$["offset"+CKEDITOR.tools.capitalize(a)],this.$["client"+CKEDITOR.tools.capitalize(a)])||0;c&&(e=e-b.call(this,a));return e}})();CKEDITOR.dom.documentFragment=function(b){b=b||CKEDITOR.document;this.$=b.type==CKEDITOR.NODE_DOCUMENT?b.$.createDocumentFragment():b}; +CKEDITOR.tools.extend(CKEDITOR.dom.documentFragment.prototype,CKEDITOR.dom.element.prototype,{type:CKEDITOR.NODE_DOCUMENT_FRAGMENT,insertAfterNode:function(b){b=b.$;b.parentNode.insertBefore(this.$,b.nextSibling)}},!0,{append:1,appendBogus:1,getFirst:1,getLast:1,getParent:1,getNext:1,getPrevious:1,appendTo:1,moveChildren:1,insertBefore:1,insertAfterNode:1,replace:1,trim:1,type:1,ltrim:1,rtrim:1,getDocument:1,getChildCount:1,getChild:1,getChildren:1}); +(function(){function b(a,b){var c=this.range;if(this._.end)return null;if(!this._.start){this._.start=1;if(c.collapsed){this.end();return null}c.optimize()}var d,m=c.startContainer;d=c.endContainer;var n=c.startOffset,o=c.endOffset,i,q=this.guard,f=this.type,e=a?"getPreviousSourceNode":"getNextSourceNode";if(!a&&!this._.guardLTR){var j=d.type==CKEDITOR.NODE_ELEMENT?d:d.getParent(),s=d.type==CKEDITOR.NODE_ELEMENT?d.getChild(o):d.getNext();this._.guardLTR=function(a,b){return(!b||!j.equals(a))&&(!s|| +!a.equals(s))&&(a.type!=CKEDITOR.NODE_ELEMENT||!b||!a.equals(c.root))}}if(a&&!this._.guardRTL){var A=m.type==CKEDITOR.NODE_ELEMENT?m:m.getParent(),B=m.type==CKEDITOR.NODE_ELEMENT?n?m.getChild(n-1):null:m.getPrevious();this._.guardRTL=function(a,b){return(!b||!A.equals(a))&&(!B||!a.equals(B))&&(a.type!=CKEDITOR.NODE_ELEMENT||!b||!a.equals(c.root))}}var p=a?this._.guardRTL:this._.guardLTR;i=q?function(a,b){return p(a,b)===false?false:q(a,b)}:p;if(this.current)d=this.current[e](false,f,i);else{if(a)d.type== +CKEDITOR.NODE_ELEMENT&&(d=o>0?d.getChild(o-1):i(d,true)===false?null:d.getPreviousSourceNode(true,f,i));else{d=m;if(d.type==CKEDITOR.NODE_ELEMENT&&!(d=d.getChild(n)))d=i(m,true)===false?null:m.getNextSourceNode(true,f,i)}d&&i(d)===false&&(d=null)}for(;d&&!this._.end;){this.current=d;if(!this.evaluator||this.evaluator(d)!==false){if(!b)return d}else if(b&&this.evaluator)return false;d=d[e](false,f,i)}this.end();return this.current=null}function c(a){for(var c,d=null;c=b.call(this,a);)d=c;return d} +CKEDITOR.dom.walker=CKEDITOR.tools.createClass({$:function(a){this.range=a;this._={}},proto:{end:function(){this._.end=1},next:function(){return b.call(this)},previous:function(){return b.call(this,1)},checkForward:function(){return b.call(this,0,1)!==false},checkBackward:function(){return b.call(this,1,1)!==false},lastForward:function(){return c.call(this)},lastBackward:function(){return c.call(this,1)},reset:function(){delete this.current;this._={}}}});var a={block:1,"list-item":1,table:1,"table-row-group":1, +"table-header-group":1,"table-footer-group":1,"table-row":1,"table-column-group":1,"table-column":1,"table-cell":1,"table-caption":1};CKEDITOR.dom.element.prototype.isBlockBoundary=function(b){b=b?CKEDITOR.tools.extend({},CKEDITOR.dtd.$block,b||{}):CKEDITOR.dtd.$block;return this.getComputedStyle("float")=="none"&&a[this.getComputedStyle("display")]||b[this.getName()]};CKEDITOR.dom.walker.blockBoundary=function(a){return function(b){return!(b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary(a))}};CKEDITOR.dom.walker.listItemBoundary= +function(){return this.blockBoundary({br:1})};CKEDITOR.dom.walker.bookmark=function(a,b){function c(a){return a&&a.getName&&a.getName()=="span"&&a.data("cke-bookmark")}return function(d){var m,n;m=d&&d.type!=CKEDITOR.NODE_ELEMENT&&(n=d.getParent())&&c(n);m=a?m:m||c(d);return!!(b^m)}};CKEDITOR.dom.walker.whitespaces=function(a){return function(b){var c;b&&b.type==CKEDITOR.NODE_TEXT&&(c=!CKEDITOR.tools.trim(b.getText())||CKEDITOR.env.webkit&&b.getText()=="​");return!!(a^c)}};CKEDITOR.dom.walker.invisible= +function(a){var b=CKEDITOR.dom.walker.whitespaces();return function(c){if(b(c))c=1;else{c.type==CKEDITOR.NODE_TEXT&&(c=c.getParent());c=!c.$.offsetHeight}return!!(a^c)}};CKEDITOR.dom.walker.nodeType=function(a,b){return function(c){return!!(b^c.type==a)}};CKEDITOR.dom.walker.bogus=function(a){function b(a){return!e(a)&&!d(a)}return function(c){var d=!CKEDITOR.env.ie?c.is&&c.is("br"):c.getText&&f.test(c.getText());if(d){d=c.getParent();c=c.getNext(b);d=d.isBlockBoundary()&&(!c||c.type==CKEDITOR.NODE_ELEMENT&& +c.isBlockBoundary())}return!!(a^d)}};var f=/^[\t\r\n ]*(?: |\xa0)$/,e=CKEDITOR.dom.walker.whitespaces(),d=CKEDITOR.dom.walker.bookmark();CKEDITOR.dom.element.prototype.getBogus=function(){var a=this;do a=a.getPreviousSourceNode();while(d(a)||e(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.getName()in CKEDITOR.dtd.$inline&&!(a.getName()in CKEDITOR.dtd.$empty));return a&&(!CKEDITOR.env.ie?a.is&&a.is("br"):a.getText&&f.test(a.getText()))?a:false}})(); +CKEDITOR.dom.range=function(b){this.endOffset=this.endContainer=this.startOffset=this.startContainer=null;this.collapsed=true;var c=b instanceof CKEDITOR.dom.document;this.document=c?b:b.getDocument();this.root=c?b.getBody():b}; +(function(){function b(){var a=false,b=CKEDITOR.dom.walker.whitespaces(),o=CKEDITOR.dom.walker.bookmark(true),c=CKEDITOR.dom.walker.bogus();return function(q){if(o(q)||b(q))return true;if(c(q)&&!a)return a=true;return q.type==CKEDITOR.NODE_TEXT&&(q.hasAscendant("pre")||CKEDITOR.tools.trim(q.getText()).length)||q.type==CKEDITOR.NODE_ELEMENT&&!q.is(d)?false:true}}function c(a){var b=CKEDITOR.dom.walker.whitespaces(),o=CKEDITOR.dom.walker.bookmark(1);return function(c){return o(c)||b(c)?true:!a&&g(c)|| +c.type==CKEDITOR.NODE_ELEMENT&&c.is(CKEDITOR.dtd.$removeEmpty)}}function a(a){return!k(a)&&!h(a)}var f=function(a){a.collapsed=a.startContainer&&a.endContainer&&a.startContainer.equals(a.endContainer)&&a.startOffset==a.endOffset},e=function(a,b,o,c){a.optimizeBookmark();var d=a.startContainer,g=a.endContainer,f=a.startOffset,j=a.endOffset,e,k;if(g.type==CKEDITOR.NODE_TEXT)g=g.split(j);else if(g.getChildCount()>0)if(j>=g.getChildCount()){g=g.append(a.document.createText(""));k=true}else g=g.getChild(j); +if(d.type==CKEDITOR.NODE_TEXT){d.split(f);d.equals(g)&&(g=d.getNext())}else if(f)if(f>=d.getChildCount()){d=d.append(a.document.createText(""));e=true}else d=d.getChild(f).getPrevious();else{d=d.append(a.document.createText(""),1);e=true}var f=d.getParents(),j=g.getParents(),h,p,l;for(h=0;h0&&!r.equals(g)&&(F=u.append(r.clone()));if(!f[o]||r.$.parentNode!=f[o].$.parentNode)for(r=r.getPrevious();r;){if(r.equals(f[o])||r.equals(d))break;v=r.getPrevious();if(b==2)u.$.insertBefore(r.$.cloneNode(true),u.$.firstChild);else{r.remove();b==1&&u.$.insertBefore(r.$,u.$.firstChild)}r=v}u&&(u=F)}if(b==2){p=a.startContainer;if(p.type==CKEDITOR.NODE_TEXT){p.$.data=p.$.data+p.$.nextSibling.data; +p.$.parentNode.removeChild(p.$.nextSibling)}a=a.endContainer;if(a.type==CKEDITOR.NODE_TEXT&&a.$.nextSibling){a.$.data=a.$.data+a.$.nextSibling.data;a.$.parentNode.removeChild(a.$.nextSibling)}}else{if(p&&l&&(d.$.parentNode!=p.$.parentNode||g.$.parentNode!=l.$.parentNode)){b=l.getIndex();e&&l.$.parentNode==d.$.parentNode&&b--;if(c&&p.type==CKEDITOR.NODE_ELEMENT){c=CKEDITOR.dom.element.createFromHtml(' ',a.document);c.insertAfter(p);p.mergeSiblings(false); +a.moveToBookmark({startNode:c})}else a.setStart(l.getParent(),b)}a.collapse(true)}e&&d.remove();k&&g.$.parentNode&&g.remove()},d={abbr:1,acronym:1,b:1,bdo:1,big:1,cite:1,code:1,del:1,dfn:1,em:1,font:1,i:1,ins:1,label:1,kbd:1,q:1,samp:1,small:1,span:1,strike:1,strong:1,sub:1,sup:1,tt:1,u:1,"var":1},g=CKEDITOR.dom.walker.bogus(),k=new CKEDITOR.dom.walker.whitespaces,h=new CKEDITOR.dom.walker.bookmark,l=/^[\t\r\n ]*(?: |\xa0)$/;CKEDITOR.dom.range.prototype={clone:function(){var a=new CKEDITOR.dom.range(this.root); +a.startContainer=this.startContainer;a.startOffset=this.startOffset;a.endContainer=this.endContainer;a.endOffset=this.endOffset;a.collapsed=this.collapsed;return a},collapse:function(a){if(a){this.endContainer=this.startContainer;this.endOffset=this.startOffset}else{this.startContainer=this.endContainer;this.startOffset=this.endOffset}this.collapsed=true},cloneContents:function(){var a=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||e(this,2,a);return a},deleteContents:function(a){this.collapsed|| +e(this,0,null,a)},extractContents:function(a){var b=new CKEDITOR.dom.documentFragment(this.document);this.collapsed||e(this,1,b,a);return b},createBookmark:function(a){var b,o,c,d,g=this.collapsed;b=this.document.createElement("span");b.data("cke-bookmark",1);b.setStyle("display","none");b.setHtml(" ");if(a){c="cke_bm_"+CKEDITOR.tools.getNextNumber();b.setAttribute("id",c+(g?"C":"S"))}if(!g){o=b.clone();o.setHtml(" ");a&&o.setAttribute("id",c+"E");d=this.clone();d.collapse();d.insertNode(o)}d= +this.clone();d.collapse(true);d.insertNode(b);if(o){this.setStartAfter(b);this.setEndBefore(o)}else this.moveToPosition(b,CKEDITOR.POSITION_AFTER_END);return{startNode:a?c+(g?"C":"S"):b,endNode:a?c+"E":o,serializable:a,collapsed:g}},createBookmark2:function(a){var b=this.startContainer,o=this.endContainer,c=this.startOffset,d=this.endOffset,g=this.collapsed,f,j;if(!b||!o)return{start:0,end:0};if(a){if(b.type==CKEDITOR.NODE_ELEMENT){if((f=b.getChild(c))&&f.type==CKEDITOR.NODE_TEXT&&c>0&&f.getPrevious().type== +CKEDITOR.NODE_TEXT){b=f;c=0}f&&f.type==CKEDITOR.NODE_ELEMENT&&(c=f.getIndex(1))}for(;b.type==CKEDITOR.NODE_TEXT&&(j=b.getPrevious())&&j.type==CKEDITOR.NODE_TEXT;){b=j;c=c+j.getLength()}if(!g){if(o.type==CKEDITOR.NODE_ELEMENT){if((f=o.getChild(d))&&f.type==CKEDITOR.NODE_TEXT&&d>0&&f.getPrevious().type==CKEDITOR.NODE_TEXT){o=f;d=0}f&&f.type==CKEDITOR.NODE_ELEMENT&&(d=f.getIndex(1))}for(;o.type==CKEDITOR.NODE_TEXT&&(j=o.getPrevious())&&j.type==CKEDITOR.NODE_TEXT;){o=j;d=d+j.getLength()}}}return{start:b.getAddress(a), +end:g?null:o.getAddress(a),startOffset:c,endOffset:d,normalized:a,collapsed:g,is2:true}},moveToBookmark:function(a){if(a.is2){var b=this.document.getByAddress(a.start,a.normalized),c=a.startOffset,i=a.end&&this.document.getByAddress(a.end,a.normalized),a=a.endOffset;this.setStart(b,c);i?this.setEnd(i,a):this.collapse(true)}else{b=(c=a.serializable)?this.document.getById(a.startNode):a.startNode;a=c?this.document.getById(a.endNode):a.endNode;this.setStartBefore(b);b.remove();if(a){this.setEndBefore(a); +a.remove()}else this.collapse(true)}},getBoundaryNodes:function(){var a=this.startContainer,b=this.endContainer,c=this.startOffset,i=this.endOffset,d;if(a.type==CKEDITOR.NODE_ELEMENT){d=a.getChildCount();if(d>c)a=a.getChild(c);else if(d<1)a=a.getPreviousSourceNode();else{for(a=a.$;a.lastChild;)a=a.lastChild;a=new CKEDITOR.dom.node(a);a=a.getNextSourceNode()||a}}if(b.type==CKEDITOR.NODE_ELEMENT){d=b.getChildCount();if(d>i)b=b.getChild(i).getPreviousSourceNode(true);else if(d<1)b=b.getPreviousSourceNode(); +else{for(b=b.$;b.lastChild;)b=b.lastChild;b=new CKEDITOR.dom.node(b)}}a.getPosition(b)&CKEDITOR.POSITION_FOLLOWING&&(a=b);return{startNode:a,endNode:b}},getCommonAncestor:function(a,b){var c=this.startContainer,i=this.endContainer,c=c.equals(i)?a&&c.type==CKEDITOR.NODE_ELEMENT&&this.startOffset==this.endOffset-1?c.getChild(this.startOffset):c:c.getCommonAncestor(i);return b&&!c.is?c.getParent():c},optimize:function(){var a=this.startContainer,b=this.startOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>= +a.getLength()&&this.setStartAfter(a):this.setStartBefore(a));a=this.endContainer;b=this.endOffset;a.type!=CKEDITOR.NODE_ELEMENT&&(b?b>=a.getLength()&&this.setEndAfter(a):this.setEndBefore(a))},optimizeBookmark:function(){var a=this.startContainer,b=this.endContainer;a.is&&(a.is("span")&&a.data("cke-bookmark"))&&this.setStartAt(a,CKEDITOR.POSITION_BEFORE_START);b&&(b.is&&b.is("span")&&b.data("cke-bookmark"))&&this.setEndAt(b,CKEDITOR.POSITION_AFTER_END)},trim:function(a,b){var c=this.startContainer, +i=this.startOffset,d=this.collapsed;if((!a||d)&&c&&c.type==CKEDITOR.NODE_TEXT){if(i)if(i>=c.getLength()){i=c.getIndex()+1;c=c.getParent()}else{var g=c.split(i),i=c.getIndex()+1,c=c.getParent();if(this.startContainer.equals(this.endContainer))this.setEnd(g,this.endOffset-this.startOffset);else if(c.equals(this.endContainer))this.endOffset=this.endOffset+1}else{i=c.getIndex();c=c.getParent()}this.setStart(c,i);if(d){this.collapse(true);return}}c=this.endContainer;i=this.endOffset;if(!b&&!d&&c&&c.type== +CKEDITOR.NODE_TEXT){if(i){i>=c.getLength()||c.split(i);i=c.getIndex()+1}else i=c.getIndex();c=c.getParent();this.setEnd(c,i)}},enlarge:function(a,b){switch(a){case CKEDITOR.ENLARGE_INLINE:var c=1;case CKEDITOR.ENLARGE_ELEMENT:if(this.collapsed)break;var i=this.getCommonAncestor(),d=this.root,g,f,j,e,h,k=false,p,l;p=this.startContainer;l=this.startOffset;if(p.type==CKEDITOR.NODE_TEXT){if(l){p=!CKEDITOR.tools.trim(p.substring(0,l)).length&&p;k=!!p}if(p&&!(e=p.getPrevious()))j=p.getParent()}else{l&& +(e=p.getChild(l-1)||p.getLast());e||(j=p)}for(;j||e;){if(j&&!e){!h&&j.equals(i)&&(h=true);if(c?j.isBlockBoundary():!d.contains(j))break;if(!k||j.getComputedStyle("display")!="inline"){k=false;h?g=j:this.setStartBefore(j)}e=j.getPrevious()}for(;e;){p=false;if(e.type==CKEDITOR.NODE_COMMENT)e=e.getPrevious();else{if(e.type==CKEDITOR.NODE_TEXT){l=e.getText();/[^\s\ufeff]/.test(l)&&(e=null);p=/[\s\ufeff]$/.test(l)}else if((e.$.offsetWidth>0||b&&e.is("br"))&&!e.data("cke-bookmark"))if(k&&CKEDITOR.dtd.$removeEmpty[e.getName()]){l= +e.getText();if(/[^\s\ufeff]/.test(l))e=null;else for(var u=e.$.getElementsByTagName("*"),r=0,F;F=u[r++];)if(!CKEDITOR.dtd.$removeEmpty[F.nodeName.toLowerCase()]){e=null;break}e&&(p=!!l.length)}else e=null;p&&(k?h?g=j:j&&this.setStartBefore(j):k=true);if(e){p=e.getPrevious();if(!j&&!p){j=e;e=null;break}e=p}else j=null}}j&&(j=j.getParent())}p=this.endContainer;l=this.endOffset;j=e=null;h=k=false;if(p.type==CKEDITOR.NODE_TEXT){p=!CKEDITOR.tools.trim(p.substring(l)).length&&p;k=!(p&&p.getLength());if(p&& +!(e=p.getNext()))j=p.getParent()}else(e=p.getChild(l))||(j=p);for(;j||e;){if(j&&!e){!h&&j.equals(i)&&(h=true);if(c?j.isBlockBoundary():!d.contains(j))break;if(!k||j.getComputedStyle("display")!="inline"){k=false;h?f=j:j&&this.setEndAfter(j)}e=j.getNext()}for(;e;){p=false;if(e.type==CKEDITOR.NODE_TEXT){l=e.getText();/[^\s\ufeff]/.test(l)&&(e=null);p=/^[\s\ufeff]/.test(l)}else if(e.type==CKEDITOR.NODE_ELEMENT){if((e.$.offsetWidth>0||b&&e.is("br"))&&!e.data("cke-bookmark"))if(k&&CKEDITOR.dtd.$removeEmpty[e.getName()]){l= +e.getText();if(/[^\s\ufeff]/.test(l))e=null;else{u=e.$.getElementsByTagName("*");for(r=0;F=u[r++];)if(!CKEDITOR.dtd.$removeEmpty[F.nodeName.toLowerCase()]){e=null;break}}e&&(p=!!l.length)}else e=null}else p=1;p&&k&&(h?f=j:this.setEndAfter(j));if(e){p=e.getNext();if(!j&&!p){j=e;e=null;break}e=p}else j=null}j&&(j=j.getParent())}if(g&&f){i=g.contains(f)?f:g;this.setStartBefore(i);this.setEndAfter(i)}break;case CKEDITOR.ENLARGE_BLOCK_CONTENTS:case CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:j=new CKEDITOR.dom.range(this.root); +d=this.root;j.setStartAt(d,CKEDITOR.POSITION_AFTER_START);j.setEnd(this.startContainer,this.startOffset);j=new CKEDITOR.dom.walker(j);var v,t,w=CKEDITOR.dom.walker.blockBoundary(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?{br:1}:null),I=function(a){var b=w(a);b||(v=a);return b},c=function(a){var b=I(a);!b&&(a.is&&a.is("br"))&&(t=a);return b};j.guard=I;j=j.lastBackward();v=v||d;this.setStartAt(v,!v.is("br")&&(!j&&this.checkStartOfBlock()||j&&v.contains(j))?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_AFTER_END); +if(a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS){j=this.clone();j=new CKEDITOR.dom.walker(j);var G=CKEDITOR.dom.walker.whitespaces(),C=CKEDITOR.dom.walker.bookmark();j.evaluator=function(a){return!G(a)&&!C(a)};if((j=j.previous())&&j.type==CKEDITOR.NODE_ELEMENT&&j.is("br"))break}j=this.clone();j.collapse();j.setEndAt(d,CKEDITOR.POSITION_BEFORE_END);j=new CKEDITOR.dom.walker(j);j.guard=a==CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS?c:I;v=null;j=j.lastForward();v=v||d;this.setEndAt(v,!j&&this.checkEndOfBlock()||j&& +v.contains(j)?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_BEFORE_START);t&&this.setEndAfter(t)}},shrink:function(a,b,c){if(!this.collapsed){var a=a||CKEDITOR.SHRINK_TEXT,i=this.clone(),d=this.startContainer,g=this.endContainer,f=this.startOffset,e=this.endOffset,k=1,h=1;if(d&&d.type==CKEDITOR.NODE_TEXT)if(f)if(f>=d.getLength())i.setStartAfter(d);else{i.setStartBefore(d);k=0}else i.setStartBefore(d);if(g&&g.type==CKEDITOR.NODE_TEXT)if(e)if(e>=g.getLength())i.setEndAfter(g);else{i.setEndAfter(g); +h=0}else i.setEndBefore(g);var i=new CKEDITOR.dom.walker(i),l=CKEDITOR.dom.walker.bookmark();i.evaluator=function(b){return b.type==(a==CKEDITOR.SHRINK_ELEMENT?CKEDITOR.NODE_ELEMENT:CKEDITOR.NODE_TEXT)};var p;i.guard=function(b,i){if(l(b))return true;if(a==CKEDITOR.SHRINK_ELEMENT&&b.type==CKEDITOR.NODE_TEXT||i&&b.equals(p)||c===false&&b.type==CKEDITOR.NODE_ELEMENT&&b.isBlockBoundary())return false;!i&&b.type==CKEDITOR.NODE_ELEMENT&&(p=b);return true};if(k)(d=i[a==CKEDITOR.SHRINK_ELEMENT?"lastForward": +"next"]())&&this.setStartAt(d,b?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_START);if(h){i.reset();(i=i[a==CKEDITOR.SHRINK_ELEMENT?"lastBackward":"previous"]())&&this.setEndAt(i,b?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_END)}return!(!k&&!h)}},insertNode:function(a){this.optimizeBookmark();this.trim(false,true);var b=this.startContainer,c=b.getChild(this.startOffset);c?a.insertBefore(c):b.append(a);a.getParent()&&a.getParent().equals(this.endContainer)&&this.endOffset++;this.setStartBefore(a)}, +moveToPosition:function(a,b){this.setStartAt(a,b);this.collapse(true)},moveToRange:function(a){this.setStart(a.startContainer,a.startOffset);this.setEnd(a.endContainer,a.endOffset)},selectNodeContents:function(a){this.setStart(a,0);this.setEnd(a,a.type==CKEDITOR.NODE_TEXT?a.getLength():a.getChildCount())},setStart:function(a,b){if(a.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[a.getName()]){b=a.getIndex();a=a.getParent()}this.startContainer=a;this.startOffset=b;if(!this.endContainer){this.endContainer= +a;this.endOffset=b}f(this)},setEnd:function(a,b){if(a.type==CKEDITOR.NODE_ELEMENT&&CKEDITOR.dtd.$empty[a.getName()]){b=a.getIndex()+1;a=a.getParent()}this.endContainer=a;this.endOffset=b;if(!this.startContainer){this.startContainer=a;this.startOffset=b}f(this)},setStartAfter:function(a){this.setStart(a.getParent(),a.getIndex()+1)},setStartBefore:function(a){this.setStart(a.getParent(),a.getIndex())},setEndAfter:function(a){this.setEnd(a.getParent(),a.getIndex()+1)},setEndBefore:function(a){this.setEnd(a.getParent(), +a.getIndex())},setStartAt:function(a,b){switch(b){case CKEDITOR.POSITION_AFTER_START:this.setStart(a,0);break;case CKEDITOR.POSITION_BEFORE_END:a.type==CKEDITOR.NODE_TEXT?this.setStart(a,a.getLength()):this.setStart(a,a.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setStartBefore(a);break;case CKEDITOR.POSITION_AFTER_END:this.setStartAfter(a)}f(this)},setEndAt:function(a,b){switch(b){case CKEDITOR.POSITION_AFTER_START:this.setEnd(a,0);break;case CKEDITOR.POSITION_BEFORE_END:a.type== +CKEDITOR.NODE_TEXT?this.setEnd(a,a.getLength()):this.setEnd(a,a.getChildCount());break;case CKEDITOR.POSITION_BEFORE_START:this.setEndBefore(a);break;case CKEDITOR.POSITION_AFTER_END:this.setEndAfter(a)}f(this)},fixBlock:function(a,b){var c=this.createBookmark(),i=this.document.createElement(b);this.collapse(a);this.enlarge(CKEDITOR.ENLARGE_BLOCK_CONTENTS);this.extractContents().appendTo(i);i.trim();CKEDITOR.env.ie||i.appendBogus();this.insertNode(i);this.moveToBookmark(c);return i},splitBlock:function(a){var b= +new CKEDITOR.dom.elementPath(this.startContainer,this.root),c=new CKEDITOR.dom.elementPath(this.endContainer,this.root),i=b.block,d=c.block,g=null;if(!b.blockLimit.equals(c.blockLimit))return null;if(a!="br"){if(!i){i=this.fixBlock(true,a);d=(new CKEDITOR.dom.elementPath(this.endContainer,this.root)).block}d||(d=this.fixBlock(false,a))}a=i&&this.checkStartOfBlock();b=d&&this.checkEndOfBlock();this.deleteContents();if(i&&i.equals(d))if(b){g=new CKEDITOR.dom.elementPath(this.startContainer,this.root); +this.moveToPosition(d,CKEDITOR.POSITION_AFTER_END);d=null}else if(a){g=new CKEDITOR.dom.elementPath(this.startContainer,this.root);this.moveToPosition(i,CKEDITOR.POSITION_BEFORE_START);i=null}else{d=this.splitElement(i);!CKEDITOR.env.ie&&!i.is("ul","ol")&&i.appendBogus()}return{previousBlock:i,nextBlock:d,wasStartOfBlock:a,wasEndOfBlock:b,elementPath:g}},splitElement:function(a){if(!this.collapsed)return null;this.setEndAt(a,CKEDITOR.POSITION_BEFORE_END);var b=this.extractContents(),c=a.clone(false); +b.appendTo(c);c.insertAfter(a);this.moveToPosition(a,CKEDITOR.POSITION_AFTER_END);return c},removeEmptyBlocksAtEnd:function(){function a(d){return function(a){return b(a)||(c(a)||a.type==CKEDITOR.NODE_ELEMENT&&a.isEmptyInlineRemoveable())||d.is("table")&&a.is("caption")?false:true}}var b=CKEDITOR.dom.walker.whitespaces(),c=CKEDITOR.dom.walker.bookmark(false);return function(b){for(var c=this.createBookmark(),o=this[b?"endPath":"startPath"](),d=o.block||o.blockLimit,n;d&&!d.equals(o.root)&&!d.getFirst(a(d));){n= +d.getParent();this[b?"setEndAt":"setStartAt"](d,CKEDITOR.POSITION_AFTER_END);d.remove(1);d=n}this.moveToBookmark(c)}}(),startPath:function(){return new CKEDITOR.dom.elementPath(this.startContainer,this.root)},endPath:function(){return new CKEDITOR.dom.elementPath(this.endContainer,this.root)},checkBoundaryOfElement:function(a,b){var o=b==CKEDITOR.START,d=this.clone();d.collapse(o);d[o?"setStartAt":"setEndAt"](a,o?CKEDITOR.POSITION_AFTER_START:CKEDITOR.POSITION_BEFORE_END);d=new CKEDITOR.dom.walker(d); +d.evaluator=c(o);return d[o?"checkBackward":"checkForward"]()},checkStartOfBlock:function(){var a=this.startContainer,c=this.startOffset;if(CKEDITOR.env.ie&&c&&a.type==CKEDITOR.NODE_TEXT){a=CKEDITOR.tools.ltrim(a.substring(0,c));l.test(a)&&this.trim(0,1)}this.trim();a=new CKEDITOR.dom.elementPath(this.startContainer,this.root);c=this.clone();c.collapse(true);c.setStartAt(a.block||a.blockLimit,CKEDITOR.POSITION_AFTER_START);a=new CKEDITOR.dom.walker(c);a.evaluator=b();return a.checkBackward()},checkEndOfBlock:function(){var a= +this.endContainer,c=this.endOffset;if(CKEDITOR.env.ie&&a.type==CKEDITOR.NODE_TEXT){a=CKEDITOR.tools.rtrim(a.substring(c));l.test(a)&&this.trim(1,0)}this.trim();a=new CKEDITOR.dom.elementPath(this.endContainer,this.root);c=this.clone();c.collapse(false);c.setEndAt(a.block||a.blockLimit,CKEDITOR.POSITION_BEFORE_END);a=new CKEDITOR.dom.walker(c);a.evaluator=b();return a.checkForward()},getPreviousNode:function(a,b,c){var d=this.clone();d.collapse(1);d.setStartAt(c||this.root,CKEDITOR.POSITION_AFTER_START); +c=new CKEDITOR.dom.walker(d);c.evaluator=a;c.guard=b;return c.previous()},getNextNode:function(a,b,c){var d=this.clone();d.collapse();d.setEndAt(c||this.root,CKEDITOR.POSITION_BEFORE_END);c=new CKEDITOR.dom.walker(d);c.evaluator=a;c.guard=b;return c.next()},checkReadOnly:function(){function a(b,c){for(;b;){if(b.type==CKEDITOR.NODE_ELEMENT){if(b.getAttribute("contentEditable")=="false"&&!b.data("cke-editable"))return 0;if(b.is("html")||b.getAttribute("contentEditable")=="true"&&(b.contains(c)||b.equals(c)))break}b= +b.getParent()}return 1}return function(){var b=this.startContainer,c=this.endContainer;return!(a(b,c)&&a(c,b))}}(),moveToElementEditablePosition:function(b,c){if(b.type==CKEDITOR.NODE_ELEMENT&&!b.isEditable(false)){this.moveToPosition(b,c?CKEDITOR.POSITION_AFTER_END:CKEDITOR.POSITION_BEFORE_START);return true}for(var o=0;b;){if(b.type==CKEDITOR.NODE_TEXT){c&&this.checkEndOfBlock()&&l.test(b.getText())?this.moveToPosition(b,CKEDITOR.POSITION_BEFORE_START):this.moveToPosition(b,c?CKEDITOR.POSITION_AFTER_END: +CKEDITOR.POSITION_BEFORE_START);o=1;break}if(b.type==CKEDITOR.NODE_ELEMENT)if(b.isEditable()){this.moveToPosition(b,c?CKEDITOR.POSITION_BEFORE_END:CKEDITOR.POSITION_AFTER_START);o=1}else c&&(b.is("br")&&this.checkEndOfBlock())&&this.moveToPosition(b,CKEDITOR.POSITION_BEFORE_START);var d=b,g=o,f=void 0;d.type==CKEDITOR.NODE_ELEMENT&&d.isEditable(false)&&(f=d[c?"getLast":"getFirst"](a));!g&&!f&&(f=d[c?"getPrevious":"getNext"](a));b=f}return!!o},moveToElementEditStart:function(a){return this.moveToElementEditablePosition(a)}, +moveToElementEditEnd:function(a){return this.moveToElementEditablePosition(a,true)},getEnclosedNode:function(){var a=this.clone();a.optimize();if(a.startContainer.type!=CKEDITOR.NODE_ELEMENT||a.endContainer.type!=CKEDITOR.NODE_ELEMENT)return null;var a=new CKEDITOR.dom.walker(a),b=CKEDITOR.dom.walker.bookmark(false,true),c=CKEDITOR.dom.walker.whitespaces(true);a.evaluator=function(a){return c(a)&&b(a)};var d=a.next();a.reset();return d&&d.equals(a.previous())?d:null},getTouchedStartNode:function(){var a= +this.startContainer;return this.collapsed||a.type!=CKEDITOR.NODE_ELEMENT?a:a.getChild(this.startOffset)||a},getTouchedEndNode:function(){var a=this.endContainer;return this.collapsed||a.type!=CKEDITOR.NODE_ELEMENT?a:a.getChild(this.endOffset-1)||a},scrollIntoView:function(){var a=new CKEDITOR.dom.element.createFromHtml(" ",this.document),b,c,d,g=this.clone();g.optimize();if(d=g.startContainer.type==CKEDITOR.NODE_TEXT){c=g.startContainer.getText();b=g.startContainer.split(g.startOffset); +a.insertAfter(g.startContainer)}else g.insertNode(a);a.scrollIntoView();if(d){g.startContainer.setText(c);b.remove()}a.remove()}}})();CKEDITOR.POSITION_AFTER_START=1;CKEDITOR.POSITION_BEFORE_END=2;CKEDITOR.POSITION_BEFORE_START=3;CKEDITOR.POSITION_AFTER_END=4;CKEDITOR.ENLARGE_ELEMENT=1;CKEDITOR.ENLARGE_BLOCK_CONTENTS=2;CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS=3;CKEDITOR.ENLARGE_INLINE=4;CKEDITOR.START=1;CKEDITOR.END=2;CKEDITOR.SHRINK_ELEMENT=1;CKEDITOR.SHRINK_TEXT=2; +(function(){function b(a){if(!(arguments.length<1)){this.range=a;this.forceBrBreak=0;this.enlargeBr=1;this.enforceRealBlocks=0;this._||(this._={})}}function c(a,b,c){for(a=a.getNextSourceNode(b,null,c);!f(a);)a=a.getNextSourceNode(b,null,c);return a}var a=/^[\r\n\t ]+$/,f=CKEDITOR.dom.walker.bookmark(false,true),e=CKEDITOR.dom.walker.whitespaces(true),d=function(a){return f(a)&&e(a)};b.prototype={getNextParagraph:function(b){b=b||"p";if(!CKEDITOR.dtd[this.range.root.getName()][b])return null;var e, +h,l,m,n,o;if(!this._.started){h=this.range.clone();h.shrink(CKEDITOR.NODE_ELEMENT,true);m=h.endContainer.hasAscendant("pre",true)||h.startContainer.hasAscendant("pre",true);h.enlarge(this.forceBrBreak&&!m||!this.enlargeBr?CKEDITOR.ENLARGE_LIST_ITEM_CONTENTS:CKEDITOR.ENLARGE_BLOCK_CONTENTS);if(!h.collapsed){m=new CKEDITOR.dom.walker(h.clone());var i=CKEDITOR.dom.walker.bookmark(true,true);m.evaluator=i;this._.nextNode=m.next();m=new CKEDITOR.dom.walker(h.clone());m.evaluator=i;m=m.previous();this._.lastNode= +m.getNextSourceNode(true);if(this._.lastNode&&this._.lastNode.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(this._.lastNode.getText())&&this._.lastNode.getParent().isBlockBoundary()){i=this.range.clone();i.moveToPosition(this._.lastNode,CKEDITOR.POSITION_AFTER_END);if(i.checkEndOfBlock()){i=new CKEDITOR.dom.elementPath(i.endContainer,i.root);this._.lastNode=(i.block||i.blockLimit).getNextSourceNode(true)}}if(!this._.lastNode){this._.lastNode=this._.docEndMarker=h.document.createText("");this._.lastNode.insertAfter(m)}h= +null}this._.started=1}i=this._.nextNode;m=this._.lastNode;for(this._.nextNode=null;i;){var q=0,y=i.hasAscendant("pre"),z=i.type!=CKEDITOR.NODE_ELEMENT,j=0;if(z)i.type==CKEDITOR.NODE_TEXT&&a.test(i.getText())&&(z=0);else{var s=i.getName();if(i.isBlockBoundary(this.forceBrBreak&&!y&&{br:1})){if(s=="br")z=1;else if(!h&&!i.getChildCount()&&s!="hr"){e=i;l=i.equals(m);break}if(h){h.setEndAt(i,CKEDITOR.POSITION_BEFORE_START);if(s!="br")this._.nextNode=i}q=1}else{if(i.getFirst()){if(!h){h=this.range.clone(); +h.setStartAt(i,CKEDITOR.POSITION_BEFORE_START)}i=i.getFirst();continue}z=1}}if(z&&!h){h=this.range.clone();h.setStartAt(i,CKEDITOR.POSITION_BEFORE_START)}l=(!q||z)&&i.equals(m);if(h&&!q)for(;!i.getNext(d)&&!l;){s=i.getParent();if(s.isBlockBoundary(this.forceBrBreak&&!y&&{br:1})){q=1;z=0;l||s.equals(m);h.setEndAt(s,CKEDITOR.POSITION_BEFORE_END);break}i=s;z=1;l=i.equals(m);j=1}z&&h.setEndAt(i,CKEDITOR.POSITION_AFTER_END);i=c(i,j,m);if((l=!i)||q&&h)break}if(!e){if(!h){this._.docEndMarker&&this._.docEndMarker.remove(); +return this._.nextNode=null}e=new CKEDITOR.dom.elementPath(h.startContainer,h.root);i=e.blockLimit;q={div:1,th:1,td:1};e=e.block;if(!e&&i&&!this.enforceRealBlocks&&q[i.getName()]&&h.checkStartOfBlock()&&h.checkEndOfBlock()&&!i.equals(h.root))e=i;else if(!e||this.enforceRealBlocks&&e.getName()=="li"){e=this.range.document.createElement(b);h.extractContents().appendTo(e);e.trim();h.insertNode(e);n=o=true}else if(e.getName()!="li"){if(!h.checkStartOfBlock()||!h.checkEndOfBlock()){e=e.clone(false);h.extractContents().appendTo(e); +e.trim();o=h.splitBlock();n=!o.wasStartOfBlock;o=!o.wasEndOfBlock;h.insertNode(e)}}else if(!l)this._.nextNode=e.equals(m)?null:c(h.getBoundaryNodes().endNode,1,m)}if(n)(h=e.getPrevious())&&h.type==CKEDITOR.NODE_ELEMENT&&(h.getName()=="br"?h.remove():h.getLast()&&h.getLast().$.nodeName.toLowerCase()=="br"&&h.getLast().remove());if(o)(h=e.getLast())&&h.type==CKEDITOR.NODE_ELEMENT&&h.getName()=="br"&&(CKEDITOR.env.ie||h.getPrevious(f)||h.getNext(f))&&h.remove();if(!this._.nextNode)this._.nextNode=l|| +e.equals(m)||!m?null:c(e,1,m);return e}};CKEDITOR.dom.range.prototype.createIterator=function(){return new b(this)}})(); +CKEDITOR.command=function(b,c){this.uiItems=[];this.exec=function(a){if(this.state==CKEDITOR.TRISTATE_DISABLED)return false;this.editorFocus&&b.focus();return this.fire("exec")===false?true:c.exec.call(this,b,a)!==false};this.refresh=function(a,b){if(!this.readOnly&&a.readOnly)return true;if(this.context&&!b.isContextFor(this.context)){this.disable();return true}this.enable();return this.fire("refresh",{editor:a,path:b})===false?true:c.refresh&&c.refresh.apply(this,arguments)!==false};CKEDITOR.tools.extend(this, +c,{modes:{wysiwyg:1},editorFocus:1,contextSensitive:!!c.context,state:CKEDITOR.TRISTATE_OFF});CKEDITOR.event.call(this)}; +CKEDITOR.command.prototype={enable:function(){this.state==CKEDITOR.TRISTATE_DISABLED&&this.setState(!this.preserveState||typeof this.previousState=="undefined"?CKEDITOR.TRISTATE_OFF:this.previousState)},disable:function(){this.setState(CKEDITOR.TRISTATE_DISABLED)},setState:function(b){if(this.state==b)return false;this.previousState=this.state;this.state=b;this.fire("state");return true},toggleState:function(){this.state==CKEDITOR.TRISTATE_OFF?this.setState(CKEDITOR.TRISTATE_ON):this.state==CKEDITOR.TRISTATE_ON&& +this.setState(CKEDITOR.TRISTATE_OFF)}};CKEDITOR.event.implementOn(CKEDITOR.command.prototype,!0);CKEDITOR.ENTER_P=1;CKEDITOR.ENTER_BR=2;CKEDITOR.ENTER_DIV=3; +CKEDITOR.config={customConfig:"config.js",autoUpdateElement:!0,language:"",defaultLanguage:"en",contentsLangDirection:"",enterMode:CKEDITOR.ENTER_P,forceEnterMode:!1,shiftEnterMode:CKEDITOR.ENTER_BR,docType:"",bodyId:"",bodyClass:"",fullPage:!1,height:200,extraPlugins:"",removePlugins:"",protectedSource:[],tabIndex:0,width:"",baseFloatZIndex:1E4,blockedKeystrokes:[CKEDITOR.CTRL+66,CKEDITOR.CTRL+73,CKEDITOR.CTRL+85]}; +(function(){CKEDITOR.focusManager=function(b){if(b.focusManager)return b.focusManager;this.hasFocus=false;this.currentActive=null;this._={editor:b};return this};CKEDITOR.focusManager._={blurDelay:200};CKEDITOR.focusManager.prototype={focus:function(){this._.timer&&clearTimeout(this._.timer);if(!this.hasFocus&&!this._.locked){var b=CKEDITOR.currentInstance;b&&b.focusManager.blur(1);this.hasFocus=true;(b=this._.editor.container)&&b.addClass("cke_focus");this._.editor.fire("focus")}},lock:function(){this._.locked= +1},unlock:function(){delete this._.locked},blur:function(b){function c(){if(this.hasFocus){this.hasFocus=false;var a=this._.editor.container;a&&a.removeClass("cke_focus");this._.editor.fire("blur")}}if(!this._.locked){this._.timer&&clearTimeout(this._.timer);var a=CKEDITOR.focusManager._.blurDelay;b||!a?c.call(this):this._.timer=CKEDITOR.tools.setTimeout(function(){delete this._.timer;c.call(this)},a,this)}},add:function(b,c){var a=b.getCustomData("focusmanager");if(!a||a!=this){a&&a.remove(b);var a= +"focus",f="blur";if(c)if(CKEDITOR.env.ie){a="focusin";f="focusout"}else CKEDITOR.event.useCapture=1;var e={blur:function(){b.equals(this.currentActive)&&this.blur()},focus:function(){this.currentActive=b;this.focus()}};b.on(a,e.focus,this);b.on(f,e.blur,this);if(c)CKEDITOR.event.useCapture=0;b.setCustomData("focusmanager",this);b.setCustomData("focusmanager_handlers",e)}},remove:function(b){b.removeCustomData("focusmanager");var c=b.removeCustomData("focusmanager_handlers");b.removeListener("blur", +c.blur);b.removeListener("focus",c.focus)}}})();CKEDITOR.keystrokeHandler=function(b){if(b.keystrokeHandler)return b.keystrokeHandler;this.keystrokes={};this.blockedKeystrokes={};this._={editor:b};return this}; +(function(){var b,c=function(a){var a=a.data,c=a.getKeystroke(),d=this.keystrokes[c],g=this._.editor;b=g.fire("key",{keyCode:c})===false;if(!b){d&&(b=g.execCommand(d,{from:"keystrokeHandler"})!==false);b||(b=!!this.blockedKeystrokes[c])}b&&a.preventDefault(true);return!b},a=function(a){if(b){b=false;a.data.preventDefault(true)}};CKEDITOR.keystrokeHandler.prototype={attach:function(b){b.on("keydown",c,this);if(CKEDITOR.env.opera||CKEDITOR.env.gecko&&CKEDITOR.env.mac)b.on("keypress",a,this)}}})(); +(function(){CKEDITOR.lang={languages:{af:1,ar:1,bg:1,bn:1,bs:1,ca:1,cs:1,cy:1,da:1,de:1,el:1,"en-au":1,"en-ca":1,"en-gb":1,en:1,eo:1,es:1,et:1,eu:1,fa:1,fi:1,fo:1,"fr-ca":1,fr:1,gl:1,gu:1,he:1,hi:1,hr:1,hu:1,is:1,it:1,ja:1,ka:1,km:1,ko:1,ku:1,lt:1,lv:1,mn:1,ms:1,nb:1,nl:1,no:1,pl:1,"pt-br":1,pt:1,ro:1,ru:1,sk:1,sl:1,"sr-latn":1,sr:1,sv:1,th:1,tr:1,uk:1,vi:1,"zh-cn":1,zh:1},load:function(b,c,a){if(!b||!CKEDITOR.lang.languages[b])b=this.detect(c,b);this[b]?a(b,this[b]):CKEDITOR.scriptLoader.load(CKEDITOR.getUrl("lang/"+ +b+".js"),function(){a(b,this[b])},this)},detect:function(b,c){var a=this.languages,c=c||navigator.userLanguage||navigator.language||b,f=c.toLowerCase().match(/([a-z]+)(?:-([a-z]+))?/),e=f[1],f=f[2];a[e+"-"+f]?e=e+"-"+f:a[e]||(e=null);CKEDITOR.lang.detect=e?function(){return e}:function(a){return a};return e||b}}})(); +CKEDITOR.scriptLoader=function(){var b={},c={};return{load:function(a,f,e,d){var g=typeof a=="string";g&&(a=[a]);e||(e=CKEDITOR);var k=a.length,h=[],l=[],m=function(a){f&&(g?f.call(e,a):f.call(e,h,l))};if(k===0)m(true);else{var n=function(a,b){(b?h:l).push(a);if(--k<=0){d&&CKEDITOR.document.getDocumentElement().removeStyle("cursor");m(b)}},o=function(a,o){b[a]=1;var d=c[a];delete c[a];for(var i=0;i +1)){var i=new CKEDITOR.dom.element("script");i.setAttributes({type:"text/javascript",src:a});if(f)if(CKEDITOR.env.ie)i.$.onreadystatechange=function(){if(i.$.readyState=="loaded"||i.$.readyState=="complete"){i.$.onreadystatechange=null;o(a,true)}};else{i.$.onload=function(){setTimeout(function(){o(a,true)},0)};i.$.onerror=function(){o(a,false)}}i.appendTo(CKEDITOR.document.getHead())}}};d&&CKEDITOR.document.getDocumentElement().setStyle("cursor","wait");for(var q=0;q=0)q=a.langCode;else{q=a.langCode.replace(/-.*/,"");q=q!=a.langCode&&CKEDITOR.tools.indexOf(h,q)>=0?q:CKEDITOR.tools.indexOf(h,"en")>=0?"en":h[0]}if(!j.langEntries||!j.langEntries[q])e.push(CKEDITOR.getUrl(j.path+"lang/"+q+".js"));else{a.lang[f]=j.langEntries[q];q=null}}n.push(q);d.push(j)}CKEDITOR.scriptLoader.load(e,function(){for(var c=["beforeInit","init","afterInit"],e=0;e]+)>)|(?:!--([\\S|\\s]*?)--\>)|(?:([^\\s>]+)\\s*((?:(?:\"[^\"]*\")|(?:'[^']*')|[^\"'>])*)\\/?>))","g")}}; +(function(){var b=/([\w\-:.]+)(?:(?:\s*=\s*(?:(?:"([^"]*)")|(?:'([^']*)')|([^\s>]+)))|(?=\s|$))/g,c={checked:1,compact:1,declare:1,defer:1,disabled:1,ismap:1,multiple:1,nohref:1,noresize:1,noshade:1,nowrap:1,readonly:1,selected:1};CKEDITOR.htmlParser.prototype={onTagOpen:function(){},onTagClose:function(){},onText:function(){},onCDATA:function(){},onComment:function(){},parse:function(a){for(var f,e,d=0,g;f=this._.htmlPartsRegex.exec(a);){e=f.index;if(e>d){d=a.substring(d,e);if(g)g.push(d);else this.onText(d)}d= +this._.htmlPartsRegex.lastIndex;if(e=f[1]){e=e.toLowerCase();if(g&&CKEDITOR.dtd.$cdata[e]){this.onCDATA(g.join(""));g=null}if(!g){this.onTagClose(e);continue}}if(g)g.push(f[0]);else if(e=f[3]){e=e.toLowerCase();if(!/="/.test(e)){var k={},h;f=f[4];var l=!!(f&&f.charAt(f.length-1)=="/");if(f)for(;h=b.exec(f);){var m=h[1].toLowerCase();h=h[2]||h[3]||h[4]||"";k[m]=!h&&c[m]?m:h}this.onTagOpen(e,k,l);!g&&CKEDITOR.dtd.$cdata[e]&&(g=[])}}else if(e=f[2])this.onComment(e)}if(a.length>d)this.onText(a.substring(d, +a.length))}}})(); +CKEDITOR.htmlParser.basicWriter=CKEDITOR.tools.createClass({$:function(){this._={output:[]}},proto:{openTag:function(b){this._.output.push("<",b)},openTagClose:function(b,c){c?this._.output.push(" />"):this._.output.push(">")},attribute:function(b,c){typeof c=="string"&&(c=CKEDITOR.tools.htmlEncodeAttr(c));this._.output.push(" ",b,'="',c,'"')},closeTag:function(b){this._.output.push("")},text:function(b){this._.output.push(b)},comment:function(b){this._.output.push("<\!--",b,"--\>")},write:function(b){this._.output.push(b)}, +reset:function(){this._.output=[];this._.indent=false},getHtml:function(b){var c=this._.output.join("");b&&this.reset();return c}}});CKEDITOR.htmlParser.comment=function(b){this.value=b;this._={isBlockLike:false}};CKEDITOR.htmlParser.comment.prototype={type:CKEDITOR.NODE_COMMENT,writeHtml:function(b,c){var a=this.value;if(c){if(!(a=c.onComment(a,this)))return;if(typeof a!="string"){a.parent=this.parent;a.writeHtml(b,c);return}}b.comment(a)}}; +(function(){CKEDITOR.htmlParser.text=function(b){this.value=b;this._={isBlockLike:false}};CKEDITOR.htmlParser.text.prototype={type:CKEDITOR.NODE_TEXT,writeHtml:function(b,c){var a=this.value;(!c||(a=c.onText(a,this)))&&b.text(a)}}})();(function(){CKEDITOR.htmlParser.cdata=function(b){this.value=b};CKEDITOR.htmlParser.cdata.prototype={type:CKEDITOR.NODE_TEXT,writeHtml:function(b){b.write(this.value)}}})(); +CKEDITOR.htmlParser.fragment=function(){this.children=[];this.parent=null;this._={isBlockLike:true,hasInlineStarted:false}}; +(function(){function b(a){return a.name=="a"&&a.attributes.href||CKEDITOR.dtd.$removeEmpty[a.name]}var c=CKEDITOR.tools.extend({table:1,ul:1,ol:1,dl:1},CKEDITOR.dtd.table,CKEDITOR.dtd.ul,CKEDITOR.dtd.ol,CKEDITOR.dtd.dl),a={ol:1,ul:1},f=CKEDITOR.tools.extend({},{html:1},CKEDITOR.dtd.html,CKEDITOR.dtd.body,CKEDITOR.dtd.head,{style:1,script:1});CKEDITOR.htmlParser.fragment.fromHtml=function(e,d,g){function k(a){var b;if(y.length>0)for(var c=0;c=0;b--)if(a==y[b].name){y.splice(b,1);return}for(var c=[],d=[],n=j;n!=q&&n.name!=a;){n._.isBlockLike||d.unshift(n);c.push(n);n=n.returnPoint||n.parent}if(n!=q){for(b=0;b0?this.children[b-1]:null;if(c){if(a._.isBlockLike&&c.type==CKEDITOR.NODE_TEXT){c.value=CKEDITOR.tools.rtrim(c.value);if(c.value.length===0){this.children.pop();this.add(a);return}}c.next=a}a.previous=c;a.parent=this; +this.children.splice(b,0,a);if(!this._.hasInlineStarted)this._.hasInlineStarted=a.type==CKEDITOR.NODE_TEXT||a.type==CKEDITOR.NODE_ELEMENT&&!a._.isBlockLike},writeHtml:function(a,b){var c;this.filterChildren=function(){var a=new CKEDITOR.htmlParser.basicWriter;this.writeChildrenHtml.call(this,a,b);a=a.getHtml();this.children=(new CKEDITOR.htmlParser.fragment.fromHtml(a)).children;c=1};b&&b.onRoot(this);this.writeChildrenHtml(a,c?null:b)},writeChildrenHtml:function(a,b,c){if(c&&!this.parent&&b)b.onRoot(this); +for(c=0;c=0;f--)if(m=b[f]){m.pri=c;a.splice(e,0,m)}}}function a(a,b,c){if(b)for(var e in b){var l=a[e];a[e]=f(l,b[e],c);l||a.$length++}}function f(a,b,f){if(b){b.pri=f;if(a){if(a.splice)c(a,b,f);else{a=a.pri>f?[b,a]:[a,b];a.filter=e}return a}return b.filter=b}}function e(a){for(var b= +a.type||a instanceof CKEDITOR.htmlParser.fragment,c=0;c7||i.name in CKEDITOR.dtd.tr||i.name in CKEDITOR.dtd.$listItem))e=false;else{e=a(i);e=!e||i.name=="form"&&e.name=="input"}e&&i.add(n(b))}}}function o(a,b){if((!t||!CKEDITOR.env.ie)&&a.type==CKEDITOR.NODE_ELEMENT&&a.name=="br"&&!a.attributes["data-cke-eol"])return true;var c;if(a.type== +CKEDITOR.NODE_TEXT&&(c=a.value.match(s))){if(c.index){g(a,new CKEDITOR.htmlParser.text(a.value.substring(0,c.index)));a.value=c[0]}if(CKEDITOR.env.ie&&t&&(!b||a.parent.name in h))return true;if(!t)if((c=a.previous)&&c.name=="br"||!c||d(c))return true}return false}var j={elements:{}},t=c=="html",h=CKEDITOR.tools.extend({},D),q;for(q in h)"#"in B[q]||delete h[q];for(q in h)j.elements[q]=i(t,b.config.fillEmptyBlocks!==false);j.root=i(t);j.elements.br=function(a){return function(b){if(b.parent.type!= +CKEDITOR.NODE_DOCUMENT_FRAGMENT){var c=b.attributes;if("data-cke-bogus"in c||"data-cke-eol"in c)delete c["data-cke-bogus"];else{for(c=b.next;c&&e(c);)c=c.next;var i=f(b);if(!c&&d(b.parent)){b=b.parent;c=n(a);i=b.children[b.children.length-1];b.children.push(c);c.parent=b;if(i){i.next=c;c.previous=i}}else d(c)&&(i&&!d(i))&&g(c,n(a))}}}}(t);return j}function c(a){return a.enterMode!=CKEDITOR.ENTER_BR&&a.autoParagraph!==false?a.enterMode==CKEDITOR.ENTER_DIV?"div":"p":false}function a(a){for(a=a.children[a.children.length- +1];a&&e(a);)a=a.previous;return a}function f(a){for(a=a.previous;a&&e(a);)a=a.previous;return a}function e(a){return a.type==CKEDITOR.NODE_TEXT&&!CKEDITOR.tools.trim(a.value)||a.type==CKEDITOR.NODE_ELEMENT&&a.attributes["data-cke-bookmark"]}function d(a){return a&&(a.type==CKEDITOR.NODE_ELEMENT&&a.name in D||a.type==CKEDITOR.NODE_DOCUMENT_FRAGMENT)}function g(a,b){var c=a.parent.children,d=CKEDITOR.tools.indexOf(c,a);c.splice(d,0,b);c=a.previous;a.previous=b;b.next=a;b.parent=a.parent;if(c){b.previous= +c;c.next=b}}function k(a){var b=a.parent.children,c=CKEDITOR.tools.indexOf(b,a),d=a.previous,a=a.next;d&&(d.next=a);a&&(a.previous=d);b.splice(c,1)}function h(a){var b=a.parent;return b?CKEDITOR.tools.indexOf(b.children,a):-1}function l(a){a=a.attributes;a.contenteditable!="false"&&(a["data-cke-editable"]=a.contenteditable?"true":1);a.contenteditable="false"}function m(a){a=a.attributes;switch(a["data-cke-editable"]){case "true":a.contenteditable="true";break;case "1":delete a.contenteditable}}function n(a){return a.replace(v, +function(a,b,c){return"<"+b+c.replace(t,function(a,b){return!/^on/.test(b)&&c.indexOf("data-cke-saved-"+b)==-1?" data-cke-saved-"+a+" data-cke-"+CKEDITOR.rnd+"-"+a:a})+">"})}function o(a){return a.replace(w,function(a){return""+encodeURIComponent(a)+""})}function i(a){return a.replace(I,function(a,b){return decodeURIComponent(b)})}function q(a){return a.replace(/<\!--(?!{cke_protected})[\s\S]+?--\>/g,function(a){return"<\!--"+A+"{C}"+encodeURIComponent(a).replace(/--/g, +"%2D%2D")+"--\>"})}function y(a){return a.replace(/<\!--\{cke_protected\}\{C\}([\s\S]+?)--\>/g,function(a,b){return decodeURIComponent(b)})}function z(a,b){var c=b._.dataStore;return a.replace(/<\!--\{cke_protected\}([\s\S]+?)--\>/g,function(a,b){return decodeURIComponent(b)}).replace(/\{cke_protected_(\d+)\}/g,function(a,b){return c&&c[b]||""})}function j(a,b){for(var c=[],d=b.config.protectedSource,n=b._.dataStore||(b._.dataStore={id:1}),i=/<\!--\{cke_temp(comment)?\}(\d*?)--\>/g,d=[//gi, +//gi].concat(d),a=a.replace(/<\!--[\s\S]*?--\>/g,function(a){return"<\!--{cke_tempcomment}"+(c.push(a)-1)+"--\>"}),o=0;o"});a=a.replace(i,function(a,b,d){return"<\!--"+A+(b?"{C}":"")+encodeURIComponent(c[d]).replace(/--/g,"%2D%2D")+"--\>"});return a.replace(/(['"]).*?\1/g,function(a){return a.replace(/<\!--\{cke_protected\}([\s\S]+?)--\>/g, +function(a,b){n[n.id]=decodeURIComponent(b);return"{cke_protected_"+n.id++ +"}"})})}CKEDITOR.htmlDataProcessor=function(a){var c,d;this.editor=a;this.dataFilter=c=new CKEDITOR.htmlParser.filter;this.htmlFilter=d=new CKEDITOR.htmlParser.filter;this.writer=new CKEDITOR.htmlParser.basicWriter;c.addRules(u);c.addRules(b(a,"data"));d.addRules(r);d.addRules(b(a,"html"))};CKEDITOR.htmlDataProcessor.prototype={toHtml:function(a,b,d){var a=j(a,this.editor),a=n(a),a=o(a),a=a.replace(G,"$1cke:$2"),a=a.replace(Q, +""),a=CKEDITOR.env.opera?a:a.replace(/(]*>)(\r\n|\n)/g,"$1$2$2"),e=this.editor.editable(),f;!b&&b!==null&&(b=e.getName());e=b||e.getName();if(CKEDITOR.env.ie&&CKEDITOR.env.version<9&&e=="pre"){e="div";a="
    "+a+"
    ";f=1}e=this.editor.document.createElement(e);e.setHtml("a"+a);a=e.getHtml().substr(1);a=a.replace(RegExp(" data-cke-"+CKEDITOR.rnd+"-","ig")," ");f&&(a=a.replace(/^
    |<\/pre>$/gi,""));a=a.replace(C,"$1$2");a=i(a);a=y(a);a=CKEDITOR.htmlParser.fragment.fromHtml(a,
    +b,d===false?false:c(this.editor.config));b=new CKEDITOR.htmlParser.basicWriter;a.writeChildrenHtml(b,this.dataFilter,1);a=b.getHtml(true);return a=q(a)},toDataFormat:function(a){var b=this.editor.editable(),d=this.writer,a=CKEDITOR.htmlParser.fragment.fromHtml(a,b.getName(),c(this.editor.config));d.reset();a.writeChildrenHtml(d,this.htmlFilter,1);d=d.getHtml(true);d=y(d);return d=z(d,this.editor)}};var s=/(?: |\xa0)$/,A="{cke_protected}",B=CKEDITOR.dtd,p=["caption","colgroup","col","thead","tfoot",
    +"tbody"],D=CKEDITOR.tools.extend({},B.$blockLimit,B.$block),u={elements:{},attributeNames:[[/^on/,"data-cke-pa-on"]]},r={elementNames:[[/^cke:/,""],[/^\?xml:namespace$/,""]],attributeNames:[[/^data-cke-(saved|pa)-/,""],[/^data-cke-.*/,""],["hidefocus",""]],elements:{$:function(a){var b=a.attributes;if(b){if(b["data-cke-temp"])return false;for(var c=["name","href","src"],d,n=0;n-1&&d>-1&&c!=d)){c=h(a);d=h(b)}return c>d?1:-1})},embed:function(a){var b=a.parent;if(b&&b.name=="object"){var c=b.attributes.width,b=b.attributes.height;c&&(a.attributes.width=c);b&&(a.attributes.height=b)}},param:function(a){a.children=[];a.isEmpty=true;return a},a:function(a){if(!a.children.length&&!a.attributes.name&&!a.attributes["data-cke-saved-name"])return false},
    +span:function(a){a.attributes["class"]=="Apple-style-span"&&delete a.name},html:function(a){delete a.attributes.contenteditable;delete a.attributes["class"]},body:function(a){delete a.attributes.spellcheck;delete a.attributes.contenteditable},style:function(a){var b=a.children[0];b&&b.value&&(b.value=CKEDITOR.tools.trim(b.value));if(!a.attributes.type)a.attributes.type="text/css"},title:function(a){var b=a.children[0];b&&(b.value=a.attributes["data-cke-title"]||"")}},attributes:{"class":function(a){return CKEDITOR.tools.ltrim(a.replace(/(?:^|\s+)cke_[^\s]*/g,
    +""))||false}}};if(CKEDITOR.env.ie)r.attributes.style=function(a){return a.replace(/(^|;)([^\:]+)/g,function(a){return a.toLowerCase()})};for(var F in{input:1,textarea:1}){u.elements[F]=l;r.elements[F]=m}var v=/<(a|area|img|input|source)\b([^>]*)>/gi,t=/\b(on\w+|href|src|name)\s*=\s*(?:(?:"[^"]*")|(?:'[^']*')|(?:[^ "'>]+))/gi,w=/(?:])[^>]*>[\s\S]*<\/style>)|(?:<(:?link|meta|base)[^>]*>)/gi,I=/([^<]*)<\/cke:encoded>/gi,G=/(<\/?)((?:object|embed|param|html|body|head|title)[^>]*>)/gi,
    +C=/(<\/?)cke:((?:html|body|head|title)[^>]*>)/gi,Q=/]*?)\/?>(?!\s*<\/cke:\1)/gi})();
    +CKEDITOR.htmlParser.element=function(b,c){this.name=b;this.attributes=c||{};this.children=[];var a=b||"",f=a.match(/^cke:(.*)/);f&&(a=f[1]);a=!(!CKEDITOR.dtd.$nonBodyContent[a]&&!CKEDITOR.dtd.$block[a]&&!CKEDITOR.dtd.$listItem[a]&&!CKEDITOR.dtd.$tableContent[a]&&!(CKEDITOR.dtd.$nonEditable[a]||a=="br"));this.isEmpty=!!CKEDITOR.dtd.$empty[b];this.isUnknown=!CKEDITOR.dtd[b];this._={isBlockLike:a,hasInlineStarted:this.isEmpty||!a}};
    +CKEDITOR.htmlParser.cssStyle=function(b){var c={};((b instanceof CKEDITOR.htmlParser.element?b.attributes.style:b)||"").replace(/"/g,'"').replace(/\s*([^ :;]+)\s*:\s*([^;]+)\s*(?=;|$)/g,function(a,b,e){b=="font-family"&&(e=e.replace(/["']/g,""));c[b.toLowerCase()]=e});return{rules:c,populate:function(a){var b=this.toString();if(b)a instanceof CKEDITOR.dom.element?a.setAttribute("style",b):a instanceof CKEDITOR.htmlParser.element?a.attributes.style=b:a.style=b},toString:function(){var a=[],b;
    +for(b in c)c[b]&&a.push(b,":",c[b],";");return a.join("")}}};
    +(function(){var b=function(b,a){b=b[0];a=a[0];return ba?1:0};CKEDITOR.htmlParser.element.prototype={type:CKEDITOR.NODE_ELEMENT,add:CKEDITOR.htmlParser.fragment.prototype.add,clone:function(){return new CKEDITOR.htmlParser.element(this.name,this.attributes)},writeHtml:function(c,a){var f=this.attributes,e=this,d=e.name,g,k,h,l;e.filterChildren=function(){if(!l){var b=new CKEDITOR.htmlParser.basicWriter;CKEDITOR.htmlParser.fragment.prototype.writeChildrenHtml.call(e,b,a);e.children=(new CKEDITOR.htmlParser.fragment.fromHtml(b.getHtml(),
    +e.clone(),0)).children;l=1}};if(a){if(!this.parent)a.onRoot(this);for(;;){if(!(d=a.onElementName(d)))return;e.name=d;if(!(e=a.onElement(e)))return;e.parent=this.parent;if(e.name==d)break;if(e.type!=CKEDITOR.NODE_ELEMENT){e.writeHtml(c,a);return}d=e.name;if(!d){for(var d=0,m=this.children.length;d{voiceLabel}<{outerEl} class="cke_inner cke_reset" role="presentation">{topHtml}<{outerEl} id="{contentId}" class="cke_contents cke_reset" role="presentation">{bottomHtml}'));b=CKEDITOR.dom.element.createFromHtml(e.output({id:a.id,name:b,langDir:a.lang.dir,langCode:a.langCode,voiceLabel:a.lang.editor,
    +topHtml:l?''+l+"":"",contentId:a.ui.spaceId("contents"),bottomHtml:m?''+m+"":"",outerEl:CKEDITOR.env.ie?"span":"div"}));if(f==CKEDITOR.ELEMENT_MODE_REPLACE){c.hide();b.insertAfter(c)}else c.append(b);a.container=b;l&&a.ui.space("top").unselectable();m&&a.ui.space("bottom").unselectable();c=
    +a.config.width;f=a.config.height;c&&b.setStyle("width",CKEDITOR.tools.cssLength(c));f&&a.ui.space("contents").setStyle("height",CKEDITOR.tools.cssLength(f));b.disableContextMenu();CKEDITOR.env.webkit&&b.on("focus",function(){a.focus()});a.fireOnce("uiReady")}function f(a){var b=a.element;if(a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE&&b.is("textarea")){var c=b.$.form&&new CKEDITOR.dom.element(b.$.form);if(c){var e=function(){a.updateElement()};c.on("submit",e);if(!c.$.submit.nodeName&&!c.$.submit.length)c.$.submit=
    +CKEDITOR.tools.override(c.$.submit,function(b){return function(){a.updateElement();b.apply?b.apply(this,arguments):b()}});a.on("destroy",function(){c.removeListener("submit",e)})}}}CKEDITOR.replace=function(a,c){return b(a,c,null,CKEDITOR.ELEMENT_MODE_REPLACE)};CKEDITOR.appendTo=function(a,c,e){return b(a,c,e,CKEDITOR.ELEMENT_MODE_APPENDTO)};CKEDITOR.replaceAll=function(){for(var a=document.getElementsByTagName("textarea"),b=0;b",j="",a=g+a.replace(f,function(){return j+g})+j}a=a.replace(/\n/g,"
    ");b||(a=a.replace(RegExp("
    (?=)"),function(a){return e.repeat(a,2)}));a=a.replace(/^ | $/g," ");a=a.replace(/(>|\s) /g,function(a,b){return b+" "}).replace(/ (?=<)/g," ");m(this,"text",a)},insertElement:function(b){d(this);for(var c= +this.editor,e=c.config.enterMode,f=c.getSelection(),h=f.getRanges(),l=b.getName(),j=CKEDITOR.dtd.$block[l],m,k,B,p=h.length-1;p>=0;p--){m=h[p];if(!m.checkReadOnly()){m.deleteContents(1);k=!p&&b||b.clone(1);var D,u;if(j)for(;(D=m.getCommonAncestor(0,1))&&(u=CKEDITOR.dtd[D.getName()])&&(!u||!u[l]);)if(D.getName()in CKEDITOR.dtd.span)m.splitElement(D);else if(m.checkStartOfBlock()&&m.checkEndOfBlock()){m.setStartBefore(D);m.collapse(true);D.remove()}else m.splitBlock(e==CKEDITOR.ENTER_DIV?"div":"p", +c.editable());m.insertNode(k);B||(B=k)}}if(B){m.moveToPosition(B,CKEDITOR.POSITION_AFTER_END);if(j)if((b=B.getNext(a))&&b.type==CKEDITOR.NODE_ELEMENT&&b.is(CKEDITOR.dtd.$block))b.getDtd()["#"]?m.moveToElementEditStart(b):m.moveToElementEditEnd(B);else if(!b&&e!=CKEDITOR.ENTER_BR){b=m.fixBlock(true,e==CKEDITOR.ENTER_DIV?"div":"p");m.moveToElementEditStart(b)}}f.selectRanges([m]);g(this,CKEDITOR.env.opera)},setData:function(a,b){!b&&this.editor.dataProcessor&&(a=this.editor.dataProcessor.toHtml(a)); +this.setHtml(a);this.editor.fire("dataReady")},getData:function(a){var b=this.getHtml();!a&&this.editor.dataProcessor&&(b=this.editor.dataProcessor.toDataFormat(b));return b},setReadOnly:function(a){this.setAttribute("contenteditable",!a)},detach:function(){this.removeClass("cke_editable");var a=this.editor;this._.detach();delete a.document;delete a.window},isInline:function(){return this.getDocument().equals(CKEDITOR.document)},setup:function(){var a=this.editor;this.attachListener(a,"beforeGetData", +function(){var b=this.getData();this.is("textarea")||a.config.ignoreEmptyParagraph!==false&&(b=b.replace(k,function(a,b){return b}));a.setData(b,null,1)},this);this.attachListener(a,"getSnapshot",function(a){a.data=this.getData(1)},this);this.attachListener(a,"afterSetData",function(){this.setData(a.getData(1))},this);this.attachListener(a,"loadSnapshot",function(a){this.setData(a.data,1)},this);this.attachListener(a,"beforeFocus",function(){var b=a.getSelection();(b=b&&b.getNative())&&b.type=="Control"|| +this.focus()},this);this.attachListener(a,"insertHtml",function(a){this.insertHtml(a.data.dataValue,a.data.mode)},this);this.attachListener(a,"insertElement",function(a){this.insertElement(a.data)},this);this.attachListener(a,"insertText",function(a){this.insertText(a.data)},this);this.setReadOnly(a.readOnly);this.attachClass("cke_editable");this.attachClass(a.elementMode==CKEDITOR.ELEMENT_MODE_INLINE?"cke_editable_inline":a.elementMode==CKEDITOR.ELEMENT_MODE_REPLACE||a.elementMode==CKEDITOR.ELEMENT_MODE_APPENDTO? +"cke_editable_themed":"");this.attachClass("cke_contents_"+a.config.contentsLangDirection);a.keystrokeHandler.blockedKeystrokes[8]=a.readOnly;a.keystrokeHandler.attach(this);this.on("blur",function(a){CKEDITOR.env.opera&&CKEDITOR.document.getActive().equals(this.isInline()?this:this.getWindow().getFrame())?a.cancel():this.hasFocus=false},null,null,-1);this.on("focus",function(){this.hasFocus=true},null,null,-1);a.focusManager.add(this);if(this.equals(CKEDITOR.document.getActive())){this.hasFocus= +true;a.once("contentDom",function(){a.focusManager.focus()})}if(!this.is("textarea")){a.document=this.getDocument();a.window=this.getWindow();var b=a.document;this.changeAttr("spellcheck",!a.config.disableNativeSpellChecker);var d=a.config.contentsLangDirection;this.getDirection(1)!=d&&this.changeAttr("dir",d);a.document.equals(CKEDITOR.document)&&this.changeAttr("tabindex",a.tabIndex);var f=CKEDITOR.getCss();if(f){d=b.getHead();if(!d.getCustomData("stylesheet")){f=b.appendStyleText(f);f=new CKEDITOR.dom.element(f.ownerNode|| +f.owningElement);d.setCustomData("stylesheet",f);f.data("cke-temp",1)}}d=b.getCustomData("stylesheet_ref")||0;b.setCustomData("stylesheet_ref",d+1);this.setCustomData("cke_includeReadonly",!a.config.disableReadonlyStyling);this.attachListener(this,"click",function(a){var a=a.data,b=a.getTarget();b.is("a")&&(a.$.button!=2&&b.isReadOnly())&&a.preventDefault()});this.attachListener(a,"key",function(b){if(a.readOnly)return false;var c=b.data.keyCode,d;if(c in{8:1,46:1}){var i=a.getSelection(),b=i.getRanges()[0], +f=b.startPath(),o,g,l,c=c==8;if(i=e(i)){a.fire("saveSnapshot");b.moveToPosition(i,CKEDITOR.POSITION_BEFORE_START);i.remove();b.select();a.fire("saveSnapshot");d=1}else if(b.collapsed)if((o=f.block)&&b[c?"checkStartOfBlock":"checkEndOfBlock"]()&&(l=o[c?"getPrevious":"getNext"](h))&&l.is("table")){a.fire("saveSnapshot");b[c?"checkEndOfBlock":"checkStartOfBlock"]()&&o.remove();b["moveToElementEdit"+(c?"End":"Start")](l);b.select();a.fire("saveSnapshot");d=1}else if(f.blockLimit&&f.blockLimit.is("td")&& +(g=f.blockLimit.getAscendant("table"))&&b.checkBoundaryOfElement(g,c?CKEDITOR.START:CKEDITOR.END)&&(l=g[c?"getPrevious":"getNext"](h))){a.fire("saveSnapshot");b["moveToElementEdit"+(c?"End":"Start")](l);b.checkStartOfBlock()&&b.checkEndOfBlock()?l.remove():b.select();a.fire("saveSnapshot");d=1}else if((g=f.contains(["td","th","caption"]))&&b.checkBoundaryOfElement(g,c?CKEDITOR.START:CKEDITOR.END))if((l=g[c?"getPreviousSourceNode":"getNextSourceNode"](1,CKEDITOR.NODE_ELEMENT))&&!l.isReadOnly()&&b.root.contains(l)){b[c? +"moveToElementEditEnd":"moveToElementEditStart"](l);b.select();d=1}}return!d});CKEDITOR.env.ie&&this.attachListener(this,"click",c);!CKEDITOR.env.ie&&!CKEDITOR.env.opera&&this.attachListener(this,"mousedown",function(b){var c=b.data.getTarget();if(c.is("img","hr","input","textarea","select")){a.getSelection().selectElement(c);c.is("input","textarea","select")&&b.data.preventDefault()}});CKEDITOR.env.gecko&&this.attachListener(this,"mouseup",function(b){if(b.data.$.button==2){b=b.data.getTarget(); +if(!b.getOuterHtml().replace(k,"")){var c=a.createRange();c.moveToElementEditStart(b);c.select(true)}}});if(CKEDITOR.env.webkit){this.attachListener(this,"click",function(a){a.data.getTarget().is("input","select")&&a.data.preventDefault()});this.attachListener(this,"mouseup",function(a){a.data.getTarget().is("input","textarea")&&a.data.preventDefault()})}}}},_:{detach:function(){this.editor.setData(this.editor.getData(),0,1);this.clearListeners();this.restoreAttrs();var a;if(a=this.removeCustomData("classes"))for(;a.length;)this.removeClass(a.pop()); +a=this.getDocument();var b=a.getHead();if(b.getCustomData("stylesheet")){var c=a.getCustomData("stylesheet_ref");if(--c)a.setCustomData("stylesheet_ref",c);else{a.removeCustomData("stylesheet_ref");b.removeCustomData("stylesheet").remove()}}delete this.editor}}});CKEDITOR.editor.prototype.editable=function(a){var b=this._.editable;if(b&&a)return 0;if(arguments.length)b=this._.editable=a?a instanceof CKEDITOR.editable?a:new CKEDITOR.editable(this,a):(b&&b.detach(),null);return b};var k=/(^|]*>)\s*<(p|div|address|h\d|center|pre)[^>]*>\s*(?:]*>| |\u00A0| )?\s*(:?<\/\2>)?\s*(?=$|<\/body>)/gi, +h=CKEDITOR.dom.walker.whitespaces(true),l=CKEDITOR.dom.walker.bookmark(false,true);CKEDITOR.on("instanceLoaded",function(a){var c=a.editor;c.on("insertElement",function(a){a=a.data;if(a.type==CKEDITOR.NODE_ELEMENT&&(a.is("input")||a.is("textarea"))){a.getAttribute("contentEditable")!="false"&&a.data("cke-editable",a.hasAttribute("contenteditable")?"true":"1");a.setAttribute("contentEditable",false)}});c.on("selectionChange",function(a){if(!c.readOnly){var d=c.getSelection();if(d&&!d.isLocked){d=c.checkDirty(); +c.fire("lockSnapshot");b(a);c.fire("unlockSnapshot");!d&&c.resetDirty()}}})});CKEDITOR.addCss(".cke_editable{cursor:text}.cke_editable img,.cke_editable input,.cke_editable textarea{cursor:default}");var m=function(){function b(a){return a.type==CKEDITOR.NODE_ELEMENT}function c(a,d){var e,f,i,g,t=[],h=d.range.startContainer;e=d.range.startPath();for(var h=j[h.getName()],l=0,m=a.getChildren(),q=m.count(),k=-1,z=-1,y=0,s=e.contains(j.$list);l-1)t[k].firstNotAllowed=1;if(z>-1)t[z].lastNotAllowed=1;return t}function d(a,c){var e=[],f=a.getChildren(),o=f.count(),g,t=0,h=j[c],l=!a.is(j.$inline)|| +a.is("br");for(l&&e.push(" ");t ",r.document);r.insertNode(w);r.setStartAfter(w)}I=new CKEDITOR.dom.elementPath(r.startContainer); +s.endPath=G=new CKEDITOR.dom.elementPath(r.endContainer);if(!r.collapsed){t=G.block||G.blockLimit;var Q=r.getCommonAncestor();t&&(!t.equals(Q)&&!t.contains(Q)&&r.checkEndOfBlock())&&s.zombies.push(t);r.deleteContents()}for(;(C=b(r.startContainer)&&r.startContainer.getChild(r.startOffset-1))&&b(C)&&C.isBlockBoundary()&&I.contains(C);)r.moveToPosition(C,CKEDITOR.POSITION_BEFORE_END);f(r,s.blockLimit,I,G);if(w){r.setEndBefore(w);r.collapse();w.remove()}w=r.startPath();if(t=w.contains(e,false,1)){r.splitElement(t); +s.inlineStylesRoot=t;s.inlineStylesPeak=w.lastElement}w=r.createBookmark();(t=w.startNode.getPrevious(a))&&b(t)&&e(t)&&v.push(t);(t=w.startNode.getNext(a))&&b(t)&&e(t)&&v.push(t);for(t=w.startNode;(t=t.getParent())&&e(t);)v.push(t);r.moveToBookmark(w);if(u){C=u;u=s.range;if(s.type=="text"&&s.inlineStylesRoot){w=C;C=s.inlineStylesPeak;r=C.getDocument().createText("{cke-peak}");for(v=s.inlineStylesRoot.getParent();!C.equals(v);){r=r.appendTo(C.clone());C=C.getParent()}C=r.getOuterHtml().replace("{cke-peak}", +w)}w=s.blockLimit.getName();if(/^\s+|\s+$/.test(C)&&"span"in CKEDITOR.dtd[w]){var K=' ';C=K+C+K}C=s.editor.dataProcessor.toHtml(C,null,false);w=u.document.createElement("body");w.setHtml(C);if(K){w.getFirst().remove();w.getLast().remove()}if((K=u.startPath().block)&&!(K.getChildCount()==1&&K.getBogus()))a:{var E;if(w.getChildCount()==1&&b(E=w.getFirst())&&E.is(m)){K=E.getElementsByTag("*");u=0;for(r=K.count();u0;else{x=E.startPath();if(!G.isBlock&&(N=s.editor.config.enterMode!=CKEDITOR.ENTER_BR&&s.editor.config.autoParagraph!==false?s.editor.config.enterMode==CKEDITOR.ENTER_DIV?"div":"p":false)&&!x.block&&x.blockLimit&&x.blockLimit.equals(E.root)){N=K.createElement(N);!CKEDITOR.env.ie&&N.appendBogus();E.insertNode(N);!CKEDITOR.env.ie&& +(J=N.getBogus())&&J.remove();E.moveToPosition(N,CKEDITOR.POSITION_BEFORE_END)}if((x=E.startPath().block)&&!x.equals(H)){if(J=x.getBogus()){J.remove();C.push(x)}H=x}G.firstNotAllowed&&(r=1);if(r&&G.isElement){x=E.startContainer;for(L=null;x&&!j[x.getName()][G.name];){if(x.equals(u)){x=null;break}L=x;x=x.getParent()}if(x){if(L){O=E.splitElement(L);s.zombies.push(O);s.zombies.push(L)}}else{L=u.getName();P=!w;x=w==I.length-1;L=d(G.node,L);for(var M=[],R=L.length,T=0,U=void 0,V=0,W=-1;T1&&f&&f.intersectsNode(c.$)){d=[e.anchorOffset,e.focusOffset];f=e.focusNode==c.$&&e.focusOffset>0;e.anchorNode==c.$&&e.anchorOffset>0&&d[0]--;f&&d[1]--;var g;f=e;if(!f.isCollapsed){g=f.getRangeAt(0);g.setStart(f.anchorNode,f.anchorOffset);g.setEnd(f.focusNode,f.focusOffset);g=g.collapsed}g&&d.unshift(d.pop())}}c.setText(c.getText().replace(/\u200B/g,""));if(d){c=e.getRangeAt(0);c.setStart(c.startContainer,d[0]);c.setEnd(c.startContainer,d[1]);e.removeAllRanges();e.addRange(c)}}} +var g,k,h=CKEDITOR.dom.walker.invisible(1);CKEDITOR.on("instanceCreated",function(a){function e(){var a=f.getSelection();a&&a.removeAllRanges()}var f=a.editor;f.define("selectionChange",{errorProof:1});f.on("contentDom",function(){var a=f.document,e=CKEDITOR.document,g=f.editable(),o=a.getBody(),n=a.getDocumentElement(),h=g.isInline();if(CKEDITOR.env.ie||CKEDITOR.env.opera||h){var m;g.attachListener(g,"focus",function(){f.unlockSelection(m);m=0},null,null,-1);var k,D=function(){k=f.getSelection(1); +k.lock()};l?g.attachListener(g,"beforedeactivate",D,null,null,-1):g.attachListener(f,"selectionCheck",D,null,null,-1);g.attachListener(g,"blur",function(){f.lockSelection(k);m=1},null,null,-1);g.attachListener(g,"mousedown",function(){m=0})}if(CKEDITOR.env.ie&&!h){var u;g.attachListener(g,"mousedown",function(a){a.data.$.button==2&&f.document.$.selection.type=="None"&&(u=f.window.getScrollPosition())});g.attachListener(g,"mouseup",function(a){if(a.data.$.button==2&&u){f.document.$.documentElement.scrollLeft= +u.x;f.document.$.documentElement.scrollTop=u.y}u=null});if(a.$.compatMode!="BackCompat"){if(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)n.on("mousedown",function(a){function b(a){a=a.data.$;if(d){var c=o.$.createTextRange();try{c.moveToPoint(a.x,a.y)}catch(e){}d.setEndPoint(g.compareEndPoints("StartToStart",c)<0?"EndToEnd":"StartToStart",c);d.select()}}function c(){n.removeListener("mousemove",b);e.removeListener("mouseup",c);n.removeListener("mouseup",c);d.select()}a=a.data;if(a.getTarget().is("html")&& +a.$.y7){n.on("mousedown",function(a){if(a.data.getTarget().is("html")){e.on("mouseup",r);n.on("mouseup",r)}});var r=function(){e.removeListener("mouseup",r);n.removeListener("mouseup",r);var b=CKEDITOR.document.$.selection,c=b.createRange();b.type!="None"&&c.parentElement().ownerDocument== +a.$&&c.select()}}}}g.attachListener(g,"selectionchange",b,f);g.attachListener(g,"mouseup",c,f);g.attachListener(g,"keyup",c,f);g.attachListener(g,"focus",function(){f.forceNextSelectionCheck();f.selectionChange(1)});if(CKEDITOR.env.webkit)a.on("keydown",function(a){switch(a.data.getKey()){case 13:case 33:case 34:case 35:case 36:case 37:case 39:case 8:case 45:case 46:d(f.editable())}},null,null,-1)});f.on("contentDomUnload",f.forceNextSelectionCheck,f);f.on("dataReady",function(){f.selectionChange(1)}); +CKEDITOR.env.ie9Compat&&f.on("beforeDestroy",e,null,null,9);CKEDITOR.env.webkit&&f.on("setData",e);f.on("contentDomUnload",function(){f.unlockSelection()})});CKEDITOR.on("instanceReady",function(a){var b=a.editor,c=b.editable();if(CKEDITOR.env.webkit){b.on("selectionChange",function(){var a=e(c);a&&(a.getCustomData("ready")?d(c):a.setCustomData("ready",1))},null,null,-1);b.on("beforeSetMode",function(){d(c)},null,null,-1);var f,g,a=function(){var a=b.document,d=e(c);if(d){a=a.$.defaultView.getSelection(); +a.type=="Caret"&&a.anchorNode==d.$&&(g=1);f=d.getText();d.setText(f.replace(/\u200B/g,""))}},h=function(){var a=b.document,d=e(c);if(d){d.setText(f);if(g){a.$.defaultView.getSelection().setPosition(d.$,d.getLength());g=0}}};b.on("beforeUndoImage",a);b.on("afterUndoImage",h);b.on("beforeGetData",a,null,null,0);b.on("getData",h)}});CKEDITOR.editor.prototype.selectionChange=function(a){(a?b:c).call(this)};CKEDITOR.editor.prototype.getSelection=function(a){if(this._.savedSelection&&!a)return this._.savedSelection; +return(a=this.editable())?new CKEDITOR.dom.selection(a):null};CKEDITOR.editor.prototype.lockSelection=function(a){a=a||this.getSelection(1);if(a.getType()!=CKEDITOR.SELECTION_NONE){!a.isLocked&&a.lock();this._.savedSelection=a;return true}return false};CKEDITOR.editor.prototype.unlockSelection=function(a){var b=this._.savedSelection;if(b){b.unlock(a);delete this._.savedSelection;return true}return false};CKEDITOR.editor.prototype.forceNextSelectionCheck=function(){delete this._.selectionPreviousPath}; +CKEDITOR.dom.document.prototype.getSelection=function(){return new CKEDITOR.dom.selection(this)};CKEDITOR.dom.range.prototype.select=function(){var a=this.root instanceof CKEDITOR.editable?this.root.editor.getSelection():new CKEDITOR.dom.selection(this.root);a.selectRanges([this]);return a};CKEDITOR.SELECTION_NONE=1;CKEDITOR.SELECTION_TEXT=2;CKEDITOR.SELECTION_ELEMENT=3;var l=typeof window.getSelection!="function";CKEDITOR.dom.selection=function(a){var b=a instanceof CKEDITOR.dom.element;this.document= +a instanceof CKEDITOR.dom.document?a:a.getDocument();this.root=b?a:this.document.getBody();this.isLocked=0;this._={cache:{}};if(CKEDITOR.env.webkit){a=this.document.getWindow().$.getSelection();if(a.type=="None"&&this.document.getActive().equals(this.root)||a.type=="Caret"&&a.anchorNode.nodeType==CKEDITOR.NODE_DOCUMENT){var c=new CKEDITOR.dom.range(this.root);c.moveToPosition(this.root,CKEDITOR.POSITION_AFTER_START);b=this.document.$.createRange();b.setStart(c.startContainer.$,c.startOffset);b.collapse(1); +a.addRange(b)}}var a=this.getNative(),d;if(a)if(a.getRangeAt)d=(c=a.rangeCount&&a.getRangeAt(0))&&new CKEDITOR.dom.node(c.commonAncestorContainer);else{try{c=a.createRange()}catch(e){}d=c&&CKEDITOR.dom.element.get(c.item&&c.item(0)||c.parentElement())}if(!d||!this.root.equals(d)&&!this.root.contains(d)){this._.cache.type=CKEDITOR.SELECTION_NONE;this._.cache.startElement=null;this._.cache.selectedElement=null;this._.cache.selectedText="";this._.cache.ranges=new CKEDITOR.dom.rangeList}return this}; +var m={img:1,hr:1,li:1,table:1,tr:1,td:1,th:1,embed:1,object:1,ol:1,ul:1,a:1,input:1,form:1,select:1,textarea:1,button:1,fieldset:1,thead:1,tfoot:1};CKEDITOR.dom.selection.prototype={getNative:function(){return this._.cache.nativeSel!==void 0?this._.cache.nativeSel:this._.cache.nativeSel=l?this.document.$.selection:this.document.getWindow().$.getSelection()},getType:l?function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_NONE;try{var c=this.getNative(),d=c.type;if(d=="Text")b= +CKEDITOR.SELECTION_TEXT;if(d=="Control")b=CKEDITOR.SELECTION_ELEMENT;if(c.createRange().parentElement())b=CKEDITOR.SELECTION_TEXT}catch(e){}return a.type=b}:function(){var a=this._.cache;if(a.type)return a.type;var b=CKEDITOR.SELECTION_TEXT,c=this.getNative();if(!c||!c.rangeCount)b=CKEDITOR.SELECTION_NONE;else if(c.rangeCount==1){var c=c.getRangeAt(0),d=c.startContainer;if(d==c.endContainer&&d.nodeType==1&&c.endOffset-c.startOffset==1&&m[d.childNodes[c.startOffset].nodeName.toLowerCase()])b=CKEDITOR.SELECTION_ELEMENT}return a.type= +b},getRanges:function(){var a=l?function(){function a(b){return(new CKEDITOR.dom.node(b)).getIndex()}var b=function(b,c){b=b.duplicate();b.collapse(c);var d=b.parentElement(),e=d.ownerDocument;if(!d.hasChildNodes())return{container:d,offset:0};for(var f=d.children,g,i,h=b.duplicate(),n=0,l=f.length-1,m=-1,k,v;n<=l;){m=Math.floor((n+l)/2);g=f[m];h.moveToElementText(g);k=h.compareEndPoints("StartToStart",b);if(k>0)l=m-1;else if(k<0)n=m+1;else{if(CKEDITOR.env.ie9Compat&&g.tagName=="BR"){f=e.defaultView.getSelection(); +return{container:f[c?"anchorNode":"focusNode"],offset:f[c?"anchorOffset":"focusOffset"]}}return{container:d,offset:a(g)}}}if(m==-1||m==f.length-1&&k<0){h.moveToElementText(d);h.setEndPoint("StartToStart",b);e=h.text.replace(/(\r\n|\r)/g,"\n").length;f=d.childNodes;if(!e){g=f[f.length-1];return g.nodeType!=CKEDITOR.NODE_TEXT?{container:d,offset:f.length}:{container:g,offset:g.nodeValue.length}}for(d=f.length;e>0&&d>0;){i=f[--d];if(i.nodeType==CKEDITOR.NODE_TEXT){v=i;e=e-i.nodeValue.length}}return{container:v, +offset:-e}}h.collapse(k>0?true:false);h.setEndPoint(k>0?"StartToStart":"EndToStart",b);e=h.text.replace(/(\r\n|\r)/g,"\n").length;if(!e)return{container:d,offset:a(g)+(k>0?0:1)};for(;e>0;)try{i=g[k>0?"previousSibling":"nextSibling"];if(i.nodeType==CKEDITOR.NODE_TEXT){e=e-i.nodeValue.length;v=i}g=i}catch(t){return{container:d,offset:a(g)}}return{container:v,offset:k>0?-e:v.nodeValue.length+e}};return function(){var a=this.getNative(),c=a&&a.createRange(),d=this.getType();if(!a)return[];if(d==CKEDITOR.SELECTION_TEXT){a= +new CKEDITOR.dom.range(this.root);d=b(c,true);a.setStart(new CKEDITOR.dom.node(d.container),d.offset);d=b(c);a.setEnd(new CKEDITOR.dom.node(d.container),d.offset);a.endContainer.getPosition(a.startContainer)&CKEDITOR.POSITION_PRECEDING&&a.endOffset<=a.startContainer.getIndex()&&a.collapse();return[a]}if(d==CKEDITOR.SELECTION_ELEMENT){for(var d=[],e=0;e=b.getLength()?m.setStartAfter(b):m.setStartBefore(b));g&& +g.type==CKEDITOR.NODE_TEXT&&(l?m.setEndAfter(g):m.setEndBefore(g));b=new CKEDITOR.dom.walker(m);b.evaluator=function(a){if(a.type==CKEDITOR.NODE_ELEMENT&&a.isReadOnly()){var b=f.clone();f.setEndBefore(a);f.collapsed&&d.splice(e--,1);if(!(a.getPosition(m.endContainer)&CKEDITOR.POSITION_CONTAINS)){b.setStartAfter(a);b.collapsed||d.splice(e+1,0,b)}return true}return false};b.next()}}return c.ranges}}(),getStartElement:function(){var a=this._.cache;if(a.startElement!==void 0)return a.startElement;var b; +switch(this.getType()){case CKEDITOR.SELECTION_ELEMENT:return this.getSelectedElement();case CKEDITOR.SELECTION_TEXT:var c=this.getRanges()[0];if(c){if(c.collapsed){b=c.startContainer;b.type!=CKEDITOR.NODE_ELEMENT&&(b=b.getParent())}else{for(c.optimize();;){b=c.startContainer;if(c.startOffset==(b.getChildCount?b.getChildCount():b.getLength())&&!b.isBlockBoundary())c.setStartAfter(b);else break}b=c.startContainer;if(b.type!=CKEDITOR.NODE_ELEMENT)return b.getParent();b=b.getChild(c.startOffset);if(!b|| +b.type!=CKEDITOR.NODE_ELEMENT)b=c.startContainer;else for(c=b.getFirst();c&&c.type==CKEDITOR.NODE_ELEMENT;){b=c;c=c.getFirst()}}b=b.$}}return a.startElement=b?new CKEDITOR.dom.element(b):null},getSelectedElement:function(){var a=this._.cache;if(a.selectedElement!==void 0)return a.selectedElement;var b=this,c=CKEDITOR.tools.tryThese(function(){return b.getNative().createRange().item(0)},function(){for(var a=b.getRanges()[0],c,d,e=2;e&&(!(c=a.getEnclosedNode())||!(c.type==CKEDITOR.NODE_ELEMENT&&m[c.getName()]&& +(d=c)));e--)a.shrink(CKEDITOR.SHRINK_ELEMENT);return d.$});return a.selectedElement=c?new CKEDITOR.dom.element(c):null},getSelectedText:function(){var a=this._.cache;if(a.selectedText!==void 0)return a.selectedText;var b=this.getNative(),b=l?b.type=="Control"?"":b.createRange().text:b.toString();return a.selectedText=b},lock:function(){this.getRanges();this.getStartElement();this.getSelectedElement();this.getSelectedText();this._.cache.nativeSel=null;this.isLocked=1},unlock:function(a){if(this.isLocked){if(a)var b= +this.getSelectedElement(),c=!b&&this.getRanges();this.isLocked=0;this.reset();if(a)(a=b||c[0].getCommonAncestor())&&a.getAscendant("body",1)&&(b?this.selectElement(b):this.selectRanges(c))}},reset:function(){this._.cache={}},selectElement:function(a){var b=new CKEDITOR.dom.range(this.root);b.setStartBefore(a);b.setEndAfter(a);this.selectRanges([b])},selectRanges:function(a){if(a.length)if(this.isLocked){var b=CKEDITOR.document.getActive();this.unlock();this.selectRanges(a);this.lock();!b.equals(this.root)&& +b.focus()}else{if(l){var c=CKEDITOR.dom.walker.whitespaces(true),e=/\ufeff|\u00a0/,g={table:1,tbody:1,tr:1};if(a.length>1){b=a[a.length-1];a[0].setEnd(b.endContainer,b.endOffset)}var b=a[0],a=b.collapsed,h,j,k,A=b.getEnclosedNode();if(A&&A.type==CKEDITOR.NODE_ELEMENT&&A.getName()in m&&(!A.is("a")||!A.getText()))try{k=A.$.createControlRange();k.addElement(A.$);k.select();return}catch(B){}(b.startContainer.type==CKEDITOR.NODE_ELEMENT&&b.startContainer.getName()in g||b.endContainer.type==CKEDITOR.NODE_ELEMENT&& +b.endContainer.getName()in g)&&b.shrink(CKEDITOR.NODE_ELEMENT,true);k=b.createBookmark();var g=k.startNode,p;if(!a)p=k.endNode;k=b.document.$.body.createTextRange();k.moveToElementText(g.$);k.moveStart("character",1);if(p){e=b.document.$.body.createTextRange();e.moveToElementText(p.$);k.setEndPoint("EndToEnd",e);k.moveEnd("character",-1)}else{h=g.getNext(c);j=g.hasAscendant("pre");h=!(h&&h.getText&&h.getText().match(e))&&(j||!g.hasPrevious()||g.getPrevious().is&&g.getPrevious().is("br"));j=b.document.createElement("span"); +j.setHtml("");j.insertBefore(g);h&&b.document.createText("").insertBefore(g)}b.setStartBefore(g);g.remove();if(a){if(h){k.moveStart("character",-1);k.select();b.document.$.selection.clear()}else k.select();b.moveToPosition(j,CKEDITOR.POSITION_BEFORE_START);j.remove()}else{b.setEndBefore(p);p.remove();k.select()}}else{p=this.getNative();if(!p)return;if(CKEDITOR.env.opera){b=this.document.$.createRange();b.selectNodeContents(this.root.$);p.addRange(b)}this.removeAllRanges();for(e=0;e=0){b.collapse(1);k.setEnd(b.endContainer.$,b.endOffset)}else throw D;}p.addRange(k)}}this.reset();this.root.fire("selectionchange")}},createBookmarks:function(a){return this.getRanges().createBookmarks(a)},createBookmarks2:function(a){return this.getRanges().createBookmarks2(a)},selectBookmarks:function(a){for(var b=[],c=0;c]*>)[ \t\r\n]*/gi,"$1");f=f.replace(/([ \t\n\r]+| )/g," ");f=f.replace(/]*>/gi,"\n");if(CKEDITOR.env.ie){var g=a.getDocument().createElement("div");g.append(e);e.$.outerHTML="
    "+f+"
    ";e.copyAttributes(g.getFirst());e=g.getFirst().remove()}else e.setHtml(f);b=e}else f?b=m(c?[a.getHtml()]:h(a),b):a.moveChildren(b);b.replace(a);if(d){var c=b,i;if((i=c.getPrevious(v))&&i.is&&i.is("pre")){d=l(i.getHtml(),/\n$/,"")+ +"\n\n"+l(c.getHtml(),/^\n/,"");CKEDITOR.env.ie?c.$.outerHTML="
    "+d+"
    ":c.setHtml(d);i.remove()}}else c&&q(b)}function h(a){a.getName();var b=[];l(a.getOuterHtml(),/(\S\s*)\n(?:\s|(]+data-cke-bookmark.*?\/span>))*\n(?!$)/gi,function(a,b,c){return b+"
    "+c+"
    "}).replace(/([\s\S]*?)<\/pre>/gi,function(a,c){b.push(c)});return b}function l(a,b,c){var d="",e="",a=a.replace(/(^]+data-cke-bookmark.*?\/span>)|(]+data-cke-bookmark.*?\/span>$)/gi,function(a,
    +b,c){b&&(d=b);c&&(e=c);return""});return d+a.replace(b,c)+e}function m(a,b){var c;a.length>1&&(c=new CKEDITOR.dom.documentFragment(b.getDocument()));for(var d=0;d"),e=e.replace(/[ \t]{2,}/g,function(a){return CKEDITOR.tools.repeat(" ",
    +a.length-1)+" "});if(c){var f=b.clone();f.setHtml(e);c.append(f)}else b.setHtml(e)}return c||b}function n(a){var b=this._.definition,c=b.attributes,b=b.styles,d=s(this)[a.getName()],e=CKEDITOR.tools.isEmpty(c)&&CKEDITOR.tools.isEmpty(b),f;for(f in c)if(!((f=="class"||this._.definition.fullMatch)&&a.getAttribute(f)!=A(f,c[f]))){e=a.hasAttribute(f);a.removeAttribute(f)}for(var g in b)if(!(this._.definition.fullMatch&&a.getStyle(g)!=A(g,b[g],true))){e=e||!!a.getStyle(g);a.removeStyle(g)}i(a,d,p[a.getName()]);
    +e&&(this._.definition.alwaysRemoveElement?q(a,1):!CKEDITOR.dtd.$block[a.getName()]||this._.enterMode==CKEDITOR.ENTER_BR&&!a.hasAttributes()?q(a):a.renameNode(this._.enterMode==CKEDITOR.ENTER_P?"p":"div"))}function o(a){for(var b=s(this),c=a.getElementsByTag(this.element),d=c.count();--d>=0;)n.call(this,c.getItem(d));for(var e in b)if(e!=this.element){c=a.getElementsByTag(e);for(d=c.count()-1;d>=0;d--){var f=c.getItem(d);i(f,b[e])}}}function i(a,b,c){if(b=b&&b.attributes)for(var d=0;d",a||b.name,"");return c.join("")}};CKEDITOR.style.getStyleText=function(a){var b=a._ST;if(b)return b;var b=a.styles,c=a.attributes&&a.attributes.style||
    +"",d="";c.length&&(c=c.replace(u,";"));for(var e in b){var f=b[e],g=(e+":"+f).replace(u,";");f=="inherit"?d=d+g:c=c+g}c.length&&(c=CKEDITOR.tools.normalizeCssText(c,true));return a._ST=c+d}})();CKEDITOR.styleCommand=function(b){this.style=b};CKEDITOR.styleCommand.prototype.exec=function(b){b.focus();this.state==CKEDITOR.TRISTATE_OFF?b.applyStyle(this.style):this.state==CKEDITOR.TRISTATE_ON&&b.removeStyle(this.style)};CKEDITOR.stylesSet=new CKEDITOR.resourceManager("","stylesSet");
    +CKEDITOR.addStylesSet=CKEDITOR.tools.bind(CKEDITOR.stylesSet.add,CKEDITOR.stylesSet);CKEDITOR.loadStylesSet=function(b,c,a){CKEDITOR.stylesSet.addExternal(b,c,"");CKEDITOR.stylesSet.load(b,a)};
    +CKEDITOR.editor.prototype.getStylesSet=function(b){if(this._.stylesDefinitions)b(this._.stylesDefinitions);else{var c=this,a=c.config.stylesCombo_stylesSet||c.config.stylesSet||"default";if(a instanceof Array){c._.stylesDefinitions=a;b(a)}else{var a=a.split(":"),f=a[0];CKEDITOR.stylesSet.addExternal(f,a[1]?a.slice(1).join(":"):CKEDITOR.getUrl("styles.js"),"");CKEDITOR.stylesSet.load(f,function(a){c._.stylesDefinitions=a[f];b(c._.stylesDefinitions)})}}};
    +CKEDITOR.dom.comment=function(b,c){typeof b=="string"&&(b=(c?c.$:document).createComment(b));CKEDITOR.dom.domObject.call(this,b)};CKEDITOR.dom.comment.prototype=new CKEDITOR.dom.node;CKEDITOR.tools.extend(CKEDITOR.dom.comment.prototype,{type:CKEDITOR.NODE_COMMENT,getOuterHtml:function(){return"<\!--"+this.$.nodeValue+"--\>"}});
    +(function(){var b={},c;for(c in CKEDITOR.dtd.$blockLimit)c in CKEDITOR.dtd.$list||(b[c]=1);var a={};for(c in CKEDITOR.dtd.$block)c in CKEDITOR.dtd.$blockLimit||c in CKEDITOR.dtd.$empty||(a[c]=1);CKEDITOR.dom.elementPath=function(c,e){var d=null,g=null,k=[],e=e||c.getDocument().getBody(),h=c;do if(h.type==CKEDITOR.NODE_ELEMENT){k.push(h);if(!this.lastElement){this.lastElement=h;if(h.is(CKEDITOR.dtd.$object))continue}var l=h.getName();if(!g){!d&&a[l]&&(d=h);if(b[l]){var m;if(m=!d){if(l=l=="div"){a:{l=
    +h.getChildren();m=0;for(var n=l.count();m-1}:typeof b=="function"?f=b:typeof b=="object"&&(f=
    +function(a){return a.getName()in b});var e=this.elements,d=e.length;c&&d--;if(a){e=Array.prototype.slice.call(e,0);e.reverse()}for(c=0;c=f){d=e.createText("");d.insertAfter(this)}else{b=e.createText("");b.insertAfter(d);b.remove()}return d},substring:function(b,
    +c){return typeof c!="number"?this.$.nodeValue.substr(b):this.$.nodeValue.substring(b,c)}});
    +(function(){function b(a,b,c){var d=a.serializable,g=b[c?"endContainer":"startContainer"],k=c?"endOffset":"startOffset",h=d?b.document.getById(a.startNode):a.startNode,a=d?b.document.getById(a.endNode):a.endNode;if(g.equals(h.getPrevious())){b.startOffset=b.startOffset-g.getLength()-a.getPrevious().getLength();g=a.getNext()}else if(g.equals(a.getPrevious())){b.startOffset=b.startOffset-g.getLength();g=a.getNext()}g.equals(h.getParent())&&b[k]++;g.equals(a.getParent())&&b[k]++;b[c?"endContainer":"startContainer"]=
    +g;return b}CKEDITOR.dom.rangeList=function(a){if(a instanceof CKEDITOR.dom.rangeList)return a;a?a instanceof CKEDITOR.dom.range&&(a=[a]):a=[];return CKEDITOR.tools.extend(a,c)};var c={createIterator:function(){var a=this,b=CKEDITOR.dom.walker.bookmark(),c=[],d;return{getNextRange:function(g){d=d==void 0?0:d+1;var k=a[d];if(k&&a.length>1){if(!d)for(var h=a.length-1;h>=0;h--)c.unshift(a[h].createBookmark(true));if(g)for(var l=0;a[d+l+1];){for(var m=k.document,g=0,h=m.getById(c[l].endNode),m=m.getById(c[l+
    +1].startNode);;){h=h.getNextSourceNode(false);if(m.equals(h))g=1;else if(b(h)||h.type==CKEDITOR.NODE_ELEMENT&&h.isBlockBoundary())continue;break}if(!g)break;l++}for(k.moveToBookmark(c.shift());l--;){h=a[++d];h.moveToBookmark(c.shift());k.setEnd(h.endContainer,h.endOffset)}}return k}}},createBookmarks:function(a){for(var c=[],e,d=0;db?-1:1}),e=0,f;e',CKEDITOR.document);b.appendTo(CKEDITOR.document.getHead());try{CKEDITOR.env.hc=b.getComputedStyle("border-top-color")==b.getComputedStyle("border-right-color")}catch(c){CKEDITOR.env.hc=false}b.remove()}if(CKEDITOR.env.hc)CKEDITOR.env.cssClass=CKEDITOR.env.cssClass+" cke_hc";CKEDITOR.document.appendStyleText(".cke{visibility:hidden;}");
    +CKEDITOR.status="loaded";CKEDITOR.fireOnce("loaded");if(b=CKEDITOR._.pending){delete CKEDITOR._.pending;for(var a=0;ac;c++){var f=a,h=c,d;d=parseInt(a[c],16);d=("0"+(0>e?0|d*(1+e):0|d+(255-d)*e).toString(16)).slice(-2);f[h]=d}return"#"+a.join("")}}(),c=function(){var b=new CKEDITOR.template("background:#{to};background-image:-webkit-gradient(linear,lefttop,leftbottom,from({from}),to({to}));background-image:-moz-linear-gradient(top,{from},{to});background-image:-webkit-linear-gradient(top,{from},{to});background-image:-o-linear-gradient(top,{from},{to});background-image:-ms-linear-gradient(top,{from},{to});background-image:linear-gradient(top,{from},{to});filter:progid:DXImageTransform.Microsoft.gradient(gradientType=0,startColorstr='{from}',endColorstr='{to}');");return function(c,
    +a){return b.output({from:c,to:a})}}(),f={editor:new CKEDITOR.template("{id}.cke_chrome [border-color:{defaultBorder};] {id} .cke_top [ {defaultGradient}border-bottom-color:{defaultBorder};] {id} .cke_bottom [{defaultGradient}border-top-color:{defaultBorder};] {id} .cke_resizer [border-right-color:{ckeResizer}] {id} .cke_dialog_title [{defaultGradient}border-bottom-color:{defaultBorder};] {id} .cke_dialog_footer [{defaultGradient}outline-color:{defaultBorder};border-top-color:{defaultBorder};] {id} .cke_dialog_tab [{lightGradient}border-color:{defaultBorder};] {id} .cke_dialog_tab:hover [{mediumGradient}] {id} .cke_dialog_contents [border-top-color:{defaultBorder};] {id} .cke_dialog_tab_selected, {id} .cke_dialog_tab_selected:hover [background:{dialogTabSelected};border-bottom-color:{dialogTabSelectedBorder};] {id} .cke_dialog_body [background:{dialogBody};border-color:{defaultBorder};] {id} .cke_toolgroup [{lightGradient}border-color:{defaultBorder};] {id} a.cke_button_off:hover, {id} a.cke_button_off:focus, {id} a.cke_button_off:active [{mediumGradient}] {id} .cke_button_on [{ckeButtonOn}] {id} .cke_toolbar_separator [background-color: {ckeToolbarSeparator};] {id} .cke_combo_button [border-color:{defaultBorder};{lightGradient}] {id} a.cke_combo_button:hover, {id} a.cke_combo_button:focus, {id} .cke_combo_on a.cke_combo_button [border-color:{defaultBorder};{mediumGradient}] {id} .cke_path_item [color:{elementsPathColor};] {id} a.cke_path_item:hover, {id} a.cke_path_item:focus, {id} a.cke_path_item:active [background-color:{elementsPathBg};] {id}.cke_panel [border-color:{defaultBorder};] "),
    +panel:new CKEDITOR.template(".cke_panel_grouptitle [{lightGradient}border-color:{defaultBorder};] .cke_menubutton_icon [background-color:{menubuttonIcon};] .cke_menubutton:hover .cke_menubutton_icon, .cke_menubutton:focus .cke_menubutton_icon, .cke_menubutton:active .cke_menubutton_icon [background-color:{menubuttonIconHover};] .cke_menuseparator [background-color:{menubuttonIcon};] a:hover.cke_colorbox, a:focus.cke_colorbox, a:active.cke_colorbox [border-color:{defaultBorder};] a:hover.cke_colorauto, a:hover.cke_colormore, a:focus.cke_colorauto, a:focus.cke_colormore, a:active.cke_colorauto, a:active.cke_colormore [background-color:{ckeColorauto};border-color:{defaultBorder};] ")};
    +return function(g,e){var a=g.uiColor,a={id:"."+g.id,defaultBorder:b(a,-0.1),defaultGradient:c(b(a,0.9),a),lightGradient:c(b(a,1),b(a,0.7)),mediumGradient:c(b(a,0.8),b(a,0.5)),ckeButtonOn:c(b(a,0.6),b(a,0.7)),ckeResizer:b(a,-0.4),ckeToolbarSeparator:b(a,0.5),ckeColorauto:b(a,0.8),dialogBody:b(a,0.7),dialogTabSelected:c("#FFFFFF","#FFFFFF"),dialogTabSelectedBorder:"#FFF",elementsPathColor:b(a,-0.6),elementsPathBg:a,menubuttonIcon:b(a,0.5),menubuttonIconHover:b(a,0.3)};return f[e].output(a).replace(/\[/g,
    +"{").replace(/\]/g,"}")}}();CKEDITOR.plugins.add("dialogui",{onLoad:function(){var h=function(b){this._||(this._={});this._["default"]=this._.initValue=b["default"]||"";this._.required=b.required||!1;for(var a=[this._],d=1;darguments.length)){var c=h.call(this,a);c.labelId=CKEDITOR.tools.getNextId()+"_label";this._.children=[];CKEDITOR.ui.dialog.uiElement.call(this,b,a,d,"div",null,{role:"presentation"},function(){var f=[],d=a.required?" cke_required":"";"horizontal"!=
    +a.labelLayout?f.push('",'"):(d={type:"hbox",widths:a.widths,padding:0,children:[{type:"html",html:'