Blogger news

NOTE !!: Some patches will be considered as a virus. But I've tried it and it not dangerous to the computer. Please turn off your antivirus before extract and run the patch.
Showing posts with label Web Programming Articles. Show all posts
Showing posts with label Web Programming Articles. Show all posts

Sunday, November 6, 2011

How to Make Your Website Load Faster

One of the best things you can do to promote your brand experience online, is to take a few simple steps to help your website load faster.

Steps

  1. Optimize your images for web — use 65% image quality of jpeg instead of 100%.
  2. Eliminate of minimize the use of frames.
  3. Load any javascript in the footer instead of the header.
  4. Use the correct doc format for the type of page you are using (eg. Strict XHTML).
  5. Keep external images and items minimized.
  6. Use clean and simple style sheets - or use just one to load and call in any others instead of multiple style sheets.
  7. Modify your .htaccess file at root for load expiry modules.
  8. Minimize GET requests.
  9. Remove whitespace in your source code with HTML Optimizer.
Source : www.wikihow.com

How to Add a Website to Trusted Sites

It is important to protect your computer from unsafe content on malicious websites. In addition to using virus protection software, it may be helpful to set your browser security settings properly. Internet Explorer provides a number of preset security settings that allow you to set the protection level that you feel is appropriate. To avoid unnecessary security measures on websites that you know to be safe, you can identify certain ones as trusted sites.

Steps :
  1. Open Internet Explorer.
  2. Go to the website that you want to add to your trusted sites.
  3. Double-click in the address bar to select the address of the website and copy it by selecting "Copy" from the right-click menu or by pressing "Ctrl" and "C."
  4. Select the "Security" tab under "Internet Options" in the "Tools" menu.
  5. Click the "Trusted Sites" icon and press the "Sites" button.
  6. Uncheck the box labeled, "Require server verification ([https:) https:)] for all sites in this zone."
  7. Paste the address of the website you want to add to the Trusted Sites zone in the box under "Add this website to the zone." To paste the website address, either right-click in the box and select "Paste" from the menu or press "Ctrl" and "V."
  8. Click the "Add" button to move the website address to the "websites" box.
  9. Close the window using the button and press "OK" to complete the process.

Set the Security Level for the Trusted Sites Zone

  1. Select "Internet Options" from the "Tools" menu and open the "Security" tab.
  2. Click on the "Trusted Sites" icon and look at the current security settings for your trusted sites. You'll find this under the "Security level for this zone" section.
  3. Assess the security level and make adjustments using the slider control.
    • As you move the slider, the selected security setting changes.
    • You can view the pertinent features for security settings by selecting the option you want to review.
    • In Internet Explorer, the preset security levels range from high to low. Different versions of the browser may use different labels for the security settings within this range.
    • You can customize the security settings if you prefer.
  4. Customize the security settings if you understand advanced security options.
  5. Undo any changes to the security settings that you do not want to keep.
    • You can use the "Cancel" button if you are still in the screen.
    • To undo custom settings, you can enter the "Trusted Sites" dialog box and click the "Custom level" button. Then, use the "Reset to" drop down list to modify the changes you made.
  6. Click "OK" in the "Internet Options" window to save your settings.
 Source : www.wikihow.com

How to Create a Log in Script in Perl Without the Use of Databases

Perl is one of the most widely used languages the world. With a huge collection of modules (see CPAN) and easy-to-learn syntax, there's no wonder why. One of Perl's modules is able to access popular databases (Oracle, MySQL) is very useful, but can be confusing at some time. This article will show you how to create a log in script in Perl without databases involved.
  1. Create the subs that will be on the code.
    • sub change {
    • my($a) = @_;
    • chdir "$a" or die "ERROR: $!";
    • }
      • sub is a subroutine/function declaration. This code can function by typing either change("test") or &change("test").
      • my is the word of a special variable designed for only the block of code (a block is {}). Similar in math class, a variable is a placeholder that holds bytes.
      • chdir is another word for "change directory". A substitute is system "cd $a", in this case.
      • or are logical operators with true and false as the "answers".
      • die is a command that prints the message to STDERR (another name for "Standard Error"). $! and $@ represent why the command failed, and can be added to die, as well as others.
  2. Remember, all commands end with a semicolon.
  3. Create a message that will say to either register or log in, then add code to accept input.
    • print "Do you want to register or log-in? "; chomp($a=<STDIN>);
    • print is a word meaning to print data.
    • chomp is a function to chop of the newline that the nasty <STDIN> leaves after input. You could also use the chop command.
  4. Add an "if" command.
    • if($a =~ /register/i) {
    • # Stuff goes here...
    • }
    • if is a boolean condition block with true or false.
    • =~ means to compare to a regular expression operator. If you use UNIX/LINUX or something similar, the grep command should be similar.
    • /register/i is the text that the regular expression should compare to. The / means to start, the word register is the code the operator will compare to, and the second / means to end. The letter i means to use case-insensitivity, as case-sensitivity is commonly used.
    • # is to signify a comment. The rest of the line is commented, the text will be ignored by the compiler.
    • { to } represents a block. These will be executed when called.
  5. Create some more input.
    • print "What is your name: "; chomp($name=<STDIN>);
    • print "What is your password: "; chomp($password=<STDIN>);
  6. Before proceeding on, make sure you have two folders named "name" and "password".
  7. Write the name and password. Remember to add this between the two curly braces!
    • #* change "name";
    • open NAME, ">$name.nme";
    • print NAME "$name";
    • close NAME;
    • change "..";
    • change "password";
    • open PASSWORD ">$name.pswrd";
    • print PASSWORD "$password";
    • close PASSWORD;
    • change "..";
    • print "Complete.\n";
      • change is the function we wrote when we first wrote the program. The function would change directory to the name we specified.
      • open NAME, ">$name.nme" or open PASSWORD, ">$name.pswrd" will "open the file" on the second parameter (>$name.nme or something close), and give a "name" to it, known as filehandle. The name is the first parameter (like NAME or PASSWORD). The > sign in the files name represents "types". < and nothing are reading, > is writing (overwrites anything) and >> is appending (writes additional stuff).
      • print NAME or print PASSWORD is a command. In this case, we use the print function to print data to a filehandle, which then will be processed and (with the > and >>) added.
      • change ".." is using the change we added to go back a directory. The command for going back is "..".
      • \n represents a newline.
  8. Add the log-in block.
    • else {
    • print "Name: "; chomp($a=<STDIN>);
    • print "Password: "; chomp($b=<STDIN>);
    • change "name";
    • open NAME "$a.nme";
    • $c=<NAME>;
    • close NAME;
    • change "..";
    • change "password";
    • open PASSWORD "$a.pswrd";
    • $d=<PASSWORD>;
    • close PASSWORD;
    • change "..";
    • if($a =~ /$c/ and $b =~ /$d/) {
    • print "Log-in successful!\n";
    • sleep(2);
    • print "Hello, $a!\n";
    • }
      • else is if the if test failed. The compiler will run the block.
      • $c=<NAME> or $d=<PASSWORD> means that the variable's data will be assigned to the filehandle specified.
      • sleep(2) means that the compiler should wait for the number specified. 2 means to wait for two "blinks" on the prompt.


      The code altogether


    • sub change {
    • my($a) = @_;
    • chdir "$a" or die "ERROR: $!";
    • }
    • print "Do you want to register or log-in? "; chomp($a=<STDIN>);
    • if($a =~ /register/i) {
    • print "What is your name: "; chomp($name=<STDIN>);
    • print "What is your password: "; chomp($password=<STDIN>);
    • change "name";
    • open NAME, ">$name.nme";
    • print NAME "$name";
    • close NAME;
    • change "..";
    • change "password";
    • open PASSWORD ">$name.pswrd";
    • print PASSWORD "$password";
    • close PASSWORD;
    • change "..";
    • print "Complete.\n";
    • }
    • else {
    • print "Name: "; chomp($a=<STDIN>);
    • print "Password: "; chomp($b=<STDIN>);
    • change "name";
    • open NAME "$a.nme";
    • $c=<NAME>;
    • close NAME;
    • change "..";
    • change "password";
    • open PASSWORD "$a.pswrd";
    • $d=<PASSWORD>;
    • PASSWORD;
    • "..";
    • if($a =~ /$c/ and $b =~ /$d/) {
    • print "Log-in successful!\n";
    • 2);
    • "Hello, $a!\n";
      • Well done! You completed a program!
      • This code can be easily hacked. Try writing the code on hex if your adventurous. 

      Source : www.wikihow.com

       
      Design by Free WordPress Themes | Bloggerized by Lasantha - Premium Blogger Themes | Best WordPress Themes