Browse Source

Fixed missing references

tags/2.0.6
Teknikode 3 years ago
parent
commit
61839ca239
3 changed files with 1 additions and 42 deletions
  1. 0
    40
      Teknik/Helpers/StringExtensions.cs
  2. 0
    1
      Teknik/Teknik.csproj
  3. 1
    1
      Teknik/Views/Shared/_Footer.cshtml

+ 0
- 40
Teknik/Helpers/StringExtensions.cs View File

@@ -1,40 +0,0 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web;

namespace Teknik.Helpers
{
public static class StringExtensions
{
public static string Truncate(this string value, int maxLength)
{
if (string.IsNullOrEmpty(value)) return value;
return value.Length <= maxLength ? value : value.Substring(0, maxLength);
}

public static string AddStringAtInterval(this string value, int interval, string insertStr)
{
if (interval <= 0 || value.Length < interval)
return value;

StringBuilder sb = new StringBuilder();

int finalIndex = 0;
for (int i = 0; i < value.Length; i = i + interval)
{
sb.Append(value.Substring(i, interval));
sb.Append(insertStr);
finalIndex = i;
}

if (finalIndex + interval != value.Length)
{
sb.Append(value.Substring(finalIndex, value.Length - finalIndex));
}

return sb.ToString();
}
}
}

+ 0
- 1
Teknik/Teknik.csproj View File

@@ -326,7 +326,6 @@
<Compile Include="Helpers\MarkdownHelper.cs" />
<Compile Include="Helpers\RequestHelper.cs" />
<Compile Include="Helpers\RSSFeedResult.cs" />
<Compile Include="Helpers\StringExtensions.cs" />
<Compile Include="Helpers\Tracking.cs" />
<Compile Include="Helpers\UrlExtensions.cs" />
<Compile Include="Helpers\Utility.cs" />

+ 1
- 1
Teknik/Views/Shared/_Footer.cshtml View File

@@ -1,6 +1,6 @@
@using System.Diagnostics;
@using System.Reflection;
@using Teknik.Helpers;
@using Teknik.Utilities;

@{
string redbubblePath = "/Images/redbubble_icon.png";

Loading…
Cancel
Save