how to move Viewstation code down of sourc code
Last Post 02/17/2010 11:55 PM by ashishshukla. 5 Replies.
Author Messages
morad
Nuke Newbie
Nuke Newbie
Posts:6


--
12/19/2009 6:26 AM  
hi lee,Joseph just I wondering about how we can move the viewstation code down of source code I see some of dnn web sites do that for seo Search engine optimization I try to figure out but I didn’t find any usefully article so please help us to know how we can change it to appear the down of source code ?as well how we can compressed to be small size in the source code I will appreciate that’s so much ?
Joseph Craig
DNN MVP
Posts:11667


--
12/19/2009 9:45 PM  
Take a look at Pure CSS SEO Layouts for DotNetNuke skins.

For more information regarding DotNetNuke and SEO, check out seablick.com.

Joe Craig, Patapsco Research Group
Complete DNN Support
Lee Sykes
DNN Creative Staff
Nuke Master VI
Nuke Master VI
Posts:4945


--
12/20/2009 2:07 AM  
Hello,

The pure CSS SEO layout will help for SEO but not for viewstate.

To move the viewstate use Snapsis PageBlaster - this will also provde other performance benefits.

Thanks,
Lee Sykes
Site Administrator
Subscribe to the website : DotNetNuke Video Tutorials : The Skinning Toolkit : DotNetNuke Podcasts

Twitter: www.twitter.com/DNNCreative

Lee Sykes's Facebook Profile
Joseph Craig
DNN MVP
Posts:11667


--
12/20/2009 9:47 AM  
I did some Googling about this topic ...

You will find some interesting discussions involving folks like Joe Brinkman and Mitchel Sellers on this topic.

I'm also reminded that there is a new "relocation widget" in DotNetNuke 5.  It will let you move items around in the page.  You can read Will Strohl's take about it here.

Joe Craig, Patapsco Research Group
Complete DNN Support
ashishshukla
Nuke Newbie
Nuke Newbie
Posts:2


--
02/17/2010 11:49 PM  
Please ignore this.
ashishshukla
Nuke Newbie
Nuke Newbie
Posts:2


--
02/17/2010 11:55 PM  
Hello Sir,

We have a DNN website with community version. We are getting a very big View State in DNN page.

So to remove viewstate at the bottom of page we override render method in Default.aspx.vb in my DNN website as following :

Protected Overrides Sub Render(ByVal writer As System.Web.UI.HtmlTextWriter)
Dim stringWriter As New System.IO.StringWriter()
Dim htmlWriter As New HtmlTextWriter(stringWriter)
MyBase.Render(htmlWriter)
Dim html As String = stringWriter.ToString()
Dim StartPoint As Integer = html.IndexOf(" If StartPoint >= 0 Then
Dim EndPoint As Integer = html.IndexOf("/>", StartPoint) + 2
Dim viewstateInput As String = html.Substring(StartPoint, EndPoint - StartPoint)
html = html.Remove(StartPoint, EndPoint - StartPoint)
Dim FormEndStart As Integer = html.IndexOf("</form>") - 1
If FormEndStart >= 0 Then
html = html.Insert(FormEndStart, viewstateInput)
End If
End If
writer.Write(html)
''MyBase.Render(writer)
End Sub

With this change I am getting the view state at the bottom of the page. Because of this change in Admin/host mode "Control Panel" of DNN is not working.

And I are not able to perform Control Panel options like add page, remove page, add module to a page, etc..

Can you please suggest something on this?

Thanks in Advance.
Ashish Shukla


---