Ejemplo n.º 1
0
        public void ProcessRequest(HttpContext context)
        {
            var theoryPageId = int.Parse(context.Request[PageIdRequestParameter]);
            var page         = ServerModel.DB.Load <TblPages>(theoryPageId);

            CheckPageType(page);

            var html = Encoding.Unicode.GetString(page.PageFile.ToArray());

            context.Response.Write(TestControlHelper.ChangeImageUrl(html, page));
        }
Ejemplo n.º 2
0
        private void ShowPage(TblPages page)
        {
            Control control;

            if ((FX_PAGETYPE)page.PageTypeRef == FX_PAGETYPE.Practice)
            {
                control = TestControlHelper.GetPracticeControl(page, PageContent);
                RedirectSubmitEventsToThisController(control, page.ID);
            }
            else
            {
                control = TestControlHelper.GetTheoryControl(page, PageContent);
            }

            PageContent.Controls.Clear();
            PageContent.Controls.Add(control);
        }
Ejemplo n.º 3
0
        private void AddControl(TblPages page)
        {
            Control control;

            if ((FX_PAGETYPE)page.PageTypeRef == FX_PAGETYPE.Practice)
            {
                control = TestControlHelper.GetPracticeControl(page, PageContent);
            }
            else
            {
                throw new Exception("You can't see details for theory page");
            }

            PageContent.Controls.Clear();
            PageContent.Controls.Add(control);
            FillAnswer(control);
        }