homepage Welcome to WebmasterWorld Guest from 54.205.99.71
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Visit PubCon.com
Home / Forums Index / Local / Foo
Forum Library, Charter, Moderators: incrediBILL & lawman

Foo Forum

    
can i change asp to html
and run a MS site on a Unix host
chewy




msg:4479884
 12:18 pm on Jul 29, 2012 (gmt 0)

Crazy idea - what else is Foo for?

I've got a horrible asp based site that's got everything wrong with it from a technical SEO & server perspective - but it looks OK to the user.

Can I simply rip the site, change all the asp to html (say in a favorite text editor) and then run it from a Unix host so I can easily work with htaccess to clean up the signals to Google?

I'm sure there's a better way too.

 

phranque




msg:4480002
 4:57 am on Jul 30, 2012 (gmt 0)

you can use mod_rewrite to internally rewrite all the external requests for .asp(x) urls to the .html filenames used internally.
therefore you don't have to change urls.

just make sure you also externally redirect any .html url requests to their .asp(x) counterparts.


actually you could keep the filenames the same and configure apache to send .asp(x) files as text/html using the mod_mime module AddType Directive:
http://httpd.apache.org/docs/current/mod/mod_mime.html#addtype


Addtype text/html .asp .aspx



this thread might be useful - ASP file names:
http://www.webmasterworld.com/apache/3607678.htm [webmasterworld.com]


there are a couple of options to run ASP emulation under apache but i have no experience with this.

g1smd




msg:4480016
 7:26 am on Jul 30, 2012 (gmt 0)

change all the asp to html

Explain what you mean by that. Do the files contain pure HTML code or are they ASP scripts with ASP code too?

You should keep the same URLs and then use mod_rewrite to rewrite requests for those URLs to whatever the new internal filename is called. The user need never see what the new files are called.

chewy




msg:4480058
 11:36 am on Jul 30, 2012 (gmt 0)

will look into this further - ripping the site using winhttrack allows me to run it fine locally - I'll have to look deeper to see if there are asp scripts too. this is awesome.

engine




msg:4480062
 11:42 am on Jul 30, 2012 (gmt 0)

You could always just try a test to see if it works.
as g1smd says, that'll help prove if there's code in there. it'll save trawling through it and you could test it in a snap.

phranque




msg:4480077
 11:59 am on Jul 30, 2012 (gmt 0)

if you're ripping the site, you only have the HTML served and not the ASP code that was used to generate the document.

chewy




msg:4480081
 12:14 pm on Jul 30, 2012 (gmt 0)

Yup, that's what I thought.

Compliments to one more great free tool.

engine




msg:4480093
 1:10 pm on Jul 30, 2012 (gmt 0)

oh, and I wouldn't use that tool to rip a site for actual use.

scooterdude




msg:4480095
 1:18 pm on Jul 30, 2012 (gmt 0)

I am sure the asp user is delighted with

you ripping his/her site

And all the willing advisers

Perhas it even theirs

Off to block the few crawlers I've been permitting , thanks

chewy




msg:4480117
 1:43 pm on Jul 30, 2012 (gmt 0)

Right now, just testing.

The client is looking for answers, I'm just doing analysis at this time.

The asp user probably wants to quit asp (and the site and client) and move on to something else.

Given the quality of the site, I think any real experts left the building long ago.

I simply don't like making recommendations without knowing if some easy next steps will or won't work.

I appreciate the dialog and learn something new every time.

Seems like WebmasterWorld never takes a vacation!

I find I can count on WebmasterWorld sometimes more than clients, contractors, partners.

StoutFiles




msg:4480118
 1:48 pm on Jul 30, 2012 (gmt 0)

Wasn't it asp for a reason? As in, all the asp scripting on each page that wouldn't work if you changed the file type.

Sounds like you should be converting all the asp to php.

chewy




msg:4480144
 2:51 pm on Jul 30, 2012 (gmt 0)

the critic in me said it was asp because they wanted to learn asp - it may be the only asp site they ever did - so they never really learned it - never upgraded the software, never dealt with security issues - as such this particular "reason" was only to serve the developer, not the client or user.

will know more as I dig deeper with more tools and time.

lucy24




msg:4480159
 4:05 pm on Jul 30, 2012 (gmt 0)

It shouldn't take all that much digging to find out whether the asp does stuff in the background, or is simply being used to generate html. (Same goes for php, jsp and so on.) If you save a copy of the static html, does it do everything the real page does?

If it's an elderly site-- your first post makes it sound that way-- it probably does a lot of useless ### that you'd be just as glad to dump. Things like checking whether the user's browser is A (last supported in 2003), B (no longer made at all) or C (renamed in 2007 and therefore not recognized). Or doing things that involve screen size. Or converting input from some long-defunct file encoding to some other long-defunct encoding.

jskrewson




msg:4480161
 4:10 pm on Jul 30, 2012 (gmt 0)

So I have a "half way" solution that works really well. Note that I have an ASP.NET website, not a ASP website.

ASP and ASP.NET are a horror show, but c# is actually really nice. I am using "NVelocity" with asp.net pages. In my "code behind" pages I override all ASP.NET functionality and render HTML via "NVelocity". Your velocity templates will port to Unix if you want, but you can also retain a lot of the existing VB/C# logic in code by just overriding ASP.NET rendering.

I don't use the model view controller paradigm, I just use the nvelocity templating system. Nvelocity is old technology but it is stable and works well. I think I picked up my copy from the "castle" MVC framework.

I can't tell you how nice it is to have clean HTML that you can hand code and understand. Want multiple form's on a page? No problem. Want to get rid of that viewstate stuff? It's gone... Want to understand how postbacks variables are named, no problem...

Microsoft's WYSIWYG approach to website building is stupid. Binding of data, grid controls, hiding form element names etc, all better suited to low use, low complexity enterprise websites.

chewy




msg:4480178
 4:37 pm on Jul 30, 2012 (gmt 0)

pretty much what I thought

this is an excellent discussion.

- should this thread be promoted to non-foo?

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Local / Foo
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved