1

I created a aspx blog website which creates page dynamically. and uses unique id generated at the time of page creation as it's name.

eg: http://www.websitename.com/2016/f1.aspx

http://www.websitename.com/2016/f2.aspx

http://www.websitename.com/2016/f3.aspx

If i use this naming convention, do i have to worry about SEO problems? whether the the search engines index my website and the blogs?

I need to change the dynamically created page name to the page title. How can i do it?

and also i need to remove the .aspx from the blog page.

eg :

/f1.aspx => /HelloWorld

/f2.aspx => /ThisCode

Prakash S
  • 85
  • 8

2 Answers2

1

Try this... although i didn't tried it myself yet... but i am pretty sure ..it should work... Add these lines in your webconfig to remove .aspx extension from the end...

 <configuration>
  <system.webserver>
  <rewrite>
   <rules>
        <rule name="RemoveASPX" enabled="true" stopProcessing="true">
            <match url="(.*)\.aspx" />
            <action type="Redirect" url="{R:1}" />
        </rule>
        <rule name="AddASPX" enabled="true">
            <match url=".*" negate="false" />
            <conditions>
                <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
                <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
                <add input="{URL}" pattern="(.*)\.(.*)" negate="true" />
            </conditions>
            <action type="Rewrite" url="{R:0}.aspx" />
        </rule>
   </rules>
 </rewrite>
 </system.webserver>

Mridul Koul
  • 120
  • 11
  • Thanks @mridul-koul, extension .aspx issues is solved. thanks for that. is there any way to rename the dynamically generated page name to the title of the page. – Prakash S Aug 26 '16 at 12:20
0

Try these links.... these might come handy

how to change title of aspx page dynamically on page load

Page.Title vs Title tag in asp.net

how can i create a dynamic page in asp.net (C#)?

Community
  • 1
  • 1
Mridul Koul
  • 120
  • 11
  • i'm sorry, what i meant was, changing the URL name of that page. (Ex: http://www.websitename.com/2016/f2.aspx to http://www.websitename.com/2016/helloworld) helloworld is the blog title of the page f2.aspx – Prakash S Aug 26 '16 at 13:11