Click here to Skip to main content
15,881,027 members
Articles / Web Development / ASP.NET

Slink Framework - Strongly Typed URLs for ASP.NET

Rate me:
Please Sign up or sign in to vote.
5.00/5 (13 votes)
4 Sep 20078 min read 54.2K   36  
Slink is a code generating Framework that generates type safe URLs for ASP.NET. With Slink URLs, you increase code quality, increase maintainability, and get compile time checking of your URLs in all your ASPX pages (code-behind and non-codebehind).
<%@ Page Language="C#" AutoEventWireup="true"  CodeFile="Page1a.aspx.cs" Inherits="Page1" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <h1>Slink</h1>
            <h3>Strongly typed URLs for ASP.NET</h3>

            <h4>Customer Pages</h4>
            <img src="Images/CustomerImage.jpg" alt="not strongly typed image" />
<%--            <img src='<%# Slinks.Images.CustomerImage.TidleUrl %>' alt="strongly typed url" runat="server" />
            <asp:Image ID="imgSetDeclaritvelyByAspNet" runat="server" ImageUrl="Images/CustomerImage.jpg" />
            <asp:Image ID="imgSetDeclaritvelyByAspNetDatabind" runat="server" ImageUrl='<%# Slinks.Images.CustomerImage.TidleUrl %>' />
            <asp:Image ID="imgSetByCodeBehind" runat="server" />
--%>

            <h4>Employee Pages</h4>

            <hr />
            <p>Time Using Label Control: <asp:Label ID="Label1" runat="server" Text='<%# System.DateTime.Now.ToString() %>'></asp:Label></p>
            <p>Time using Response.Write() page tags <%= System.DateTime.Now.ToString() %></p>
        </div>
    </form>
</body>
</html>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


Written By
Web Developer
United States United States
I'm a .NET developer with a crazy drive to create neat computer stuff.

You can find me coding the night away in my small garage working on various fun projects for my small startup, Bit Armory, with the hopes of making it big someday, just like the YouTube and MySpace guys did. Smile | :)

You can read my blog here http://bchavez.bitarmory.com

Comments and Discussions