forked from jamietre/CsQuery
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added ability to run start/end methods in a global controller
- Loading branch information
Showing
28 changed files
with
13,101 additions
and
4,719 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
examples/CsQuery.MvcApp/CsQuery.MvcApp/Controllers/Shared/LayoutController.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Linq; | ||
using System.Web; | ||
using System.Web.Mvc; | ||
using CsQuery.Mvc; | ||
|
||
namespace CsQuery.MvcApp.Controllers | ||
{ | ||
public class LayoutController : CsQueryController | ||
{ | ||
|
||
|
||
public void Cq_Start() | ||
{ | ||
Doc["body"].Append("<hr /><div>A footer. This has a red border around it because it was created before the code that adds the red border.</div>"); | ||
} | ||
|
||
public void Cq_End() | ||
{ | ||
Doc["body"].Append("<hr /><div>A late-bound footer. This is the last method to execute, so there's no border.</div>"); | ||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.