So, it’s finally here! alizahid.net in all it’s glory.

  • jQuery
  • Hash based permalinks
  • Microsoft SQL
  • ASP 3.5
  • XHTML 1.0
  • CSS 2/3
  • codenamed: rzer
  • pure l33t sauce

I’ll probably re-introduce the user system sometime soon, and obviously add more pieces of work. But for now, this is it. I’m excited (finally something to tweet about /sigh)

I’m a… Snake?

March 4, 2009

I got an email a few days ago, which had a chart and some labels with explanations. According to that, I’m a Snake! Such a coincidence, as my alias used to be snake before it became snuke and that I associate myself with snakes a lot. Here’s what it had to say:

If you are a Snake: You are mysterious. You are someone who can handle pressure with ease, and can handle any atmosphere without going berserk. You can be mean at times, and love to gossip with your selected group. Very prim and proper. You like all situations and things to be in the way you desire, which, sometimes is not possible. As a result, you may lose out in some relationships. But otherwise, you love to help people out from difficult and tight spots when they really need you.

Pretty cool, huh? If you want to check out what the chart has to say about you, you can view it here.

The new alizahid.net

February 8, 2009

Also months of being lazy (and not updating the blog either), I’ve finally released the new alizahid.net. Not exactly what I had in mind initially, but awesome nonetheless. Based upon the WordPress theme, Grid Focus, it’s a dual theme website, with completely new content. Help me build it from the ground up again! I would appreciate any and all feedback

Ascent CMS

August 24, 2008

ASP Ascent CMS is an Ascent World of Warcraft Emulator. It’s written in ASP VBScript!

Version 1.1 has a few bug fixes.

Version 1.0 has the following features:

  • Account Registration
  • Vote System
  • Character Unstucker
  • Character Teleporter
  • Character Ban Checker
  • IP Ban Checker
  • Password Changer
  • Recover Forgotten Password

Get it here!

Heading outside…

June 14, 2008

Posting from the lounge at the airport, I share news of my first ever Umrah, and also my first ever trip outside my country! Both new experiences for me, and I’m feeling pretty awesome already! I shouldn’t even be here writing this, should be praying, but I really had to post it!
For those who’re not Muslim, Umrah is a pilgrimage to Makkah, but unlike the Hajj, it’s brief.
Gotta board now, see you in 21 days! :)

I’m sure there are a lot of tutorials out there, and this just might make a nice addition to them! So, let’s take a look at why you want to turn your computer into a webserver

  • You just want to do cool stuff with HTML and want to share with your friends
  • You want a local portal to share stuff with your friends, like FTP space and such
  • You want more power and control over your server than any web host offers you
  • And many more!

Got a reason? Let’s see what you need for this experiment

  • Windows 2000 or later
  • IIS installed
  • Ports forwarded

Before we move on, I’d like you to know that you cannot run PHP on this server, atleast not without configuring and installing PHP!
All right, let’s move to it!

Setting up Windows
For this experiment, you need Windows 2000 or later. I’d be using Windows Vista Ultimate though. Make sure Windows is installed and you can see the desktop, before you begin! :P
First of all, you need to install a web server. I’d be using Microsoft’s IIS (Internet Information Services) which comes by default with Windows (Even Windows 98 had a web server: PWS (Personal Web Server)) though you can use Apache, if you want.

Installing IIS
Insert your Vista disc, head to Control Panel > Programs and Features > Turn Windows features on or off (you’ll find in the right side bar of the Programs and Features windows). A dialog box will pop, find Internet Information Services
Check it, and anything else you want like IIS’s FTP service or ASP.NET or ASP or CGI, or other features and hit OK

Testing
Open Notepad, enter this


<%
Dim testing
  testing = "This works!"
Response.Write(testing)
%>

Save the file as default.asp in C:\inetpub\wwwroot\ replacing or deleting the files that already exist there. Than, open your browser and type in http://localhost/ in the address bar and hit Enter. If you see text saying This works! than your installation has been successful, and you’re ready to move to the next step!

Taking your server public
Unless you just wanted to test your developed applications locally, without having to upload them to your web host, you have to try this out! I also use it for hosting Ascent’s World of Warcraft emulator, since I do not have a dedicated server. So, for this step you need some knowledge about your internet connection. If you have a static IP address, one that never changes (for example, 203.23.43.187) and you are comfortable with giving people your IP address instead of a more comfortable and easier to remember address, you are pretty much done by now! All you need now is, to forward your ports, and you’re good to go! However, if you want to have an address (like my home hosted site is snuke.mine.nu or snukie.mine.nu or home.alizahid.net :P), than you have take advantage of DynDNS’s free service!

Setting up DynDNS
I have been using DynDNS since last year, and never had any problems! It works great and anybody who’s trying this out, I would recommend you DynDNS! First, go to their website and register yourself an account. Next head to this page, and get yourself a hostname. Choose a name, than the domain you want from the drop down menu. Check the Wildcard box. This makes sure if someone enters asd.snukie.mine.nu, they are still able to view snukie.mine.nu instead of getting an error that says: Cannot find the server!. Now, from the three options in Service Type, go for Host with IP address. This configures the host name and points it to your IP address, which you put in the box below. Leave mail routing unchecked, unless you are setting up an email server (Not covered in this experiment!) and hit Create Host. Next, you forward ports

Forwarding required ports
This step is pretty quick and easy. Go to Control Panel > Windows Firewall > Allow a Program through Windows Firewall > Add port > name it HTTP or IIS and in the port number, enter 80. Make sure the protocol is set to TCP. You’re done!

Testing
Hopefully, you didn’t delete the default.asp we created earlier! Fire up your browser, and enter your newly selected host name in the address bar… TADA! You are just viewing your server from outside, congratulations, you have successfully created a web server with IIS and Windows!

Dynamic IP
Okay, so you have a dynamic IP address? No problem, just repeat the steps on Setting up DynDNS followed by the download of this small tool. It’s DynDNS’s Dynamic IP address updater client, which sits on your computer and updates the IP you enter into your host name’s configuration, so you do not have to update it whenever your dynamic IP changes! Life couldn’t be easier, right?

Now that you have successfully setup a web server on your Windows installation, you can have all the fun you want with it! Develop, test, share, everything!
Got questions? Want to share the address of the server you just made? You’re more than welcome to! Have fun!!

Jeez, that’s unfair! I remember, a few years back, my dad used to say I could make a website in 15 minutes flat. Today, I couldn’t keep up that promise! Though, I don’t recall me saying it was 15 minutes, it was ‘faster than anyone else!’ :P
So, in four hours flat, I produced a website, a very good looking, and valid XHTML and CSS too, ofcourse. I guess that old saying of 15 minutes didn’t count XHTML validation and use of CSS, that too, with FrontPage or Dreamweaver’s WYSIWYG! haha

Check it out here / Tools used: Dreamweaver | Fireworks | Notepad | Command Prompt (since I was already using FileZilla for something else, and didn’t want to fire up another instance :P)

Now, I go to sleep since my back hurts!
Good night all :)

ASP BBCode Parser

May 15, 2008

During the development of Oblivion, I could not find a suitable BBCode to XHTML convertor for ASP! Most I googled, were either in PHP, or not very well written. Which, left me with only one option… write my own. So, here it is… a BBCode to XHTML Parser, which converts almost all popular BBCode expressions into XHTML. Written in ASP VBScript (ofcourse!) using Regular Expressions, this little tool has been very exciting for me! Since I was thinking of dropping the idea of BBCode and using XHTML tags in Oblivion!

Download Link | ASP BBCode Parser Home

All right! everything is back up and smooth as normal
If you got any questions or comments, please don’t hesitate, just ask! I’d be glad to help you, or accept your help, if you suggest any ways to make it better! :)

So, why am i writing this again? Because I believe the previous post was not so clear, and people were afraid to try it out!
So, i shall go slowly this time, and explain on every step, what the command does. If you are done with ASP and IIS installation, than you might want to skip the first part

Part 1 » Getting IIS with ASP
Insert your Vista disc, head to Control Panel > Programs and Features > Turn Windows features on or off (you’ll find in the right side bar of the Programs and Features windows). A dialog box will pop, find Internet Information Services > Application Development Features > ASP
Check it, and anything else you want like IIS’s FTP service, or other features and hit OK
Wait for it to install, than move on…

Part 2 » Porting your application
Copy your ASP application to the newly created wwwroot directory at C:\inetpub\wwwroot\
Make sure all the paths and URLs are alive, DSNs are set, and the database is where mentioned in the Jet connection string or DSN.
Fire up your browser and enter http://localhost/ in the address bar. If your application has a recordset pulling data from an Access database table, and you get the following error:

Microsoft JET Database Engine error ‘80004005′
Unspecified error

than IIS and ASP is working just fine, and it’s time you gave IIS read/write access to the temp directory where Access extracts itself when you use it with your ASP application. Open CMD with Administrative privileges and type these and hit Enter


%windir%\system32\inetsrv\appcmd set config /section:applicationPools /[name='DefaultAppPool'].processModel.loadUserProfile:false

icacls %windir%\serviceprofiles\networkservice\AppData\Local\Temp /grant Users:(CI)(S,WD,AD,X)

icacls %windir%\serviceprofiles\networkservice\AppData\Local\Temp /grant "CREATOR OWNER":(OI)(CI)(IO)(F)

In earlier versions of IIS, the worker processes used C:\windows\temp as their default temp directory, and not loading their own profiles for every thread created. This, however, has changed in IIS7 (though, it’s probably set to false by default in SP1 for Vista and Longhorn Server) and every process uses it’s own profile, and not using the default temp directory, thus messing up with the permissions. The first command turns the setting off, and the next two grant permissions to the temp directories, to allow read/write access so ASP can communicate smoothly with the Access database

Part 3 » Configuring script errors output
If your ASP script had an error, in IIS7, you won’t get the following

Microsoft VBScript compilation error '800a03ea'

Syntax error

/default.asp, line 4

Response.Write("I love classic ASP" && foo)
---------------------------------------------------^

but this

An error occurred on the server when processing the URL. Please contact the system administrator

This, is a security measure, taken by the IIS team, but you can always revert back to how the errors were shown in earlier versions of IIS and the way you like it! Open CMD once again with Administrative privileges and type this and hit Enter


%windir%\system32\inetsrv\appcmd set config -section:asp -scriptErrorSentToBrowser:true

You already know what this does… happy debugging! :)

Part 4 » Parents paths
Although this was already disabled in IIS6 (Windows Server 2003) but if you are coming from IIS 5.1 (Windows XP) or never used parent paths in IIS6, and use them in IIS7, you’ll be greeted with the following error

Active Server Pages error 'ASP 0131'

Disallowed Parent Path

/test.asp, line 1

The Include file '../bad.inc' cannot contain '..' to indicate the parent directory.

or this if you are using parent paths in your ADODB code

Server.MapPath() error 'ASP 0175 : 80004005'

Disallowed Path Characters

/testdir/test.asp, line 9

The '..' characters are not allowed in the Path parameter for the MapPath method.
[/sourcecode]
Using parent paths is very critical, atleast for me! And thus, I had to enable them, using the following command


%windir%\system32\inetsrv\appcmd set config -section:asp -enableParentPaths:true

That should fix you up!

Summary
What we did upstairs will enable you to run classic ASP applications with Microsoft Access databases like you used to run on your Windows XP's installation of IIS 5.1! Congratulations, and hopefully, this rewrite will help you. If something still doesn't work, just leave a comment here, and I'd surely help you! :)

Commands (again :P)


%windir%\system32\inetsrv\appcmd set config /section:applicationPools /[name='DefaultAppPool'].processModel.loadUserProfile:false

icacls %windir%\serviceprofiles\networkservice\AppData\Local\Temp /grant Users:(CI)(S,WD,AD,X)

icacls %windir%\serviceprofiles\networkservice\AppData\Local\Temp /grant "CREATOR OWNER":(OI)(CI)(IO)(F)

%windir%\system32\inetsrv\appcmd set config -section:asp -scriptErrorSentToBrowser:true

%windir%\system32\inetsrv\appcmd set config -section:asp -enableParentPaths:true

Sources (you might want to take a look at these): IIS Blogs post covering this | More about loadUserProfile (the thing that's causing trouble between ASP and Access database

Yes! I feel incredible, since this is the third week, i’ve been on the top listeners of Led Zeppelin on Last.fm, and this week, i was on top (last week i was second highest, and previous week, somewhere around the eight)
Here is the screenshot:

and here are the links: Led Zeppelin | Led Zeppelin Listeners | Me at Last.fm

And ofcourse, that is some incredible music! :)

Update: my Last.fm user name is now snukie3