Himanshu's Blog

Archive for the ‘Mac’ Category

One of the ‘perks’ of having a mobileMe account apart from being able to put comments on your iWeb blog is the ability to password protect some or all of your iWeb pages. Okay so the password protection isn’t ‘super secure’ but if you want that you will have to get yourself a HTTPS site.
If you want a basic password security on your iWeb site, perhaps to protect some family photos you don’t want the whole world to see then this is still achievable, with the help of a little javascript.
This iWeb tutorial does involve a little bit of editing of the code of your iWeb site, but not very much. In fact all you have to do is paste in some code and that is it.
One further restriction is the password. You can only have one, which is set by you. Once again we are not talking the type of security you would expect from your on-line bank account, just something that would deter the casual visitor to your site.
In order to get this whole process working you will need an iWeb site with at least 2 pages. The first should have a link to the second page (this can be using the default nav-bar or a normal text link). What we will then do is add a bit of code the second page which says (in a nutshell) that page 2 is protected and a user must enter a password first before they can view it. If the password is correct then the visitor will be taken to page 2, if not then they will be left on page 1 (or any page that you nominate).
Sounds like the sort of thing that you need? Well let’s crack on. You will need your site either published to a folder or on a MobileMe server.
In Finder navigate (either on your hard-drive or iDisk) to the page you want to protect and open it in your favorite HTML editor (TextWrangler, BBEdit, Dashcode etc….)

You will now need to scroll down to the bottom of the ‘Head’ section of the page indicated by the </head> bit of code.Now all you have to do is paste in the code that you will find below above the end of the ‘Head’ section and, if you so wish, edit it to fit in with your iWeb site.

There are various parts of the code that you can edit; the password of course, as well as the message that appears when a user tries to access the page, the message that appears when the password is successful and also the location of a ‘fail page’ which can either be the same page they started on or as I mentioned earlier a completely different page altogether.
And here is the code, I’ve highlighted the changeable bits in red.

<SCRIPT language="JavaScript">
<!–hide
var password;
var pass1="iloveiweb";
password=prompt(‘This page is protected. Please enter the password to view this page!’,’ ‘);
if (password==pass1)
alert(‘The Password is correct! Please click OK to enter the gallery!’);
else
{
window.location="http://www.yourfailpage.html";
}
//–>
</SCRIPT>

And this is what it will look like when someone visits your site and clicks on the link to the protected page:

and when they enter the correct password they will then get this message:

That’s all there is to it. If you have published to a folder just upload your site via FTP and if you have edited your site on your iDisk then just save the changes and you’re done.
And there we have it. Password protected web-sites without MobileMe. Enjoy.

iChat currently has an automatic auto-away feature that automatically sets your status to away upon being idle for 45 minutes. However, there isn’t any apparent way of customizing the auto-away message. You can, however, set a custom auto-away message by setting the AutoAwayMessage default in iChat’s defaults.

For example, running defaults write com.apple.iChat AutoAwayMessage "I went away" will set your auto-away message to "I went away." You may need to restart iChat to force the defaults to reload.

The auto-away timeout is also customizable. Although it defaults to 45 minutes, you can set it to any value greater than iChat’s default idle timeout, which is 600 seconds. Running the command defaults write com.apple.iChat AutoAwayDelay 600 will set the auto-away timeout to 600 seconds, or ten minutes.

You can also completely enable or disable auto-away with the AutoAway default (defaults write com.apple.iChat AutoAway -bool NO to disable, or YES to enable).

For more information visit

http://hints.macworld.com/article.php?story=20060301185035270

We can host a website using Dropbox !! All we need is a html file and public folder..

Also it works seemlessly with iweb of Mac.. So go and make a website of your own.

Best of luck !!

www.dropbox.com/ www.apple.com/iweb/


Archives

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 1 other subscriber

Categories

Time is Money

May 2024
M T W T F S S
 12345
6789101112
13141516171819
20212223242526
2728293031  

Flickr Photos