Exemple #1
0
 /// <summary>
 ///  Loading the page from the given server folder.
 /// </summary>
 /// <param name='serverFolder'>
 ///  The root of the folder of the web server.
 /// </param>
 /// <remarks>
 /// <para>Query pages are registered to the <see cref="Navbar"/> as well.</para>
 /// </remarks>
 public virtual void Load(string serverFolder)
 {
     if (this.pieces == null)
     {
         string filename = Path.Combine(serverFolder, this.Href);
         if (File.Exists(filename))
         {
             HtmlDocument doc = new HtmlDocument();
             doc.Load(filename);
             this.pieces = WebPagePieceBase.Expand(doc.DocumentNode);
         }
         else
         {
             this.pieces = new IWebPagePiece[] { DefaultWebPagePiece.SingleInstance };
         }
     }
     if (this.Navbar != null)
     {
         this.RegisterQueryPages(this.Navbar);
     }
 }
Exemple #2
0
 /// <summary>
 ///  Loading the page from the given server folder.
 /// </summary>
 /// <param name='serverFolder'>
 ///  The root of the folder of the web server.
 /// </param>
 public override void Load(string serverFolder)
 {
     this.pieces = WebPagePieceBase.Expand(this.node);
     base.Load(serverFolder);
 }