RSS

Author Archives: geekrider

About geekrider

A Web Developer by profession and a photographer by passion! I have been working in Information Technology (IT) field since the dawn of 2002. I have extensive knowledge in Web Development Technolgies & tools ranging from Open Source technologies like Linux, Apache, MySQL and PHP (LAMP) to Microsoft technologies such as .NET, SQL Server, IIS and Windows Server 2003 and also some other general Web technologies such as JavaScript, CSS, XML, Remote Scripting (aka AJAX) and DHTML. My particular interest is in developing RIA's using AJAX and Adobe Flex

Latest pictures from the filming of World War Z in Glasgow

Just came across these pics of Brad Pitt on JustJared

 

 

View more pics of Brad Pitt on the shooting location in Glasgow here

 
Leave a comment

Posted by on August 19, 2011 in Movie, World War Z

 

Tags: , , , , , ,

World War Z – Day 3 of filming in Glasgow

The actual filming of the upcoming Brad Pitt’s movie “World War Z” has finally started today. While passing by the George Square in the morning (enroute to Office!), I saw all the extras had been assembled on the Cochrane street and it was quite crowded.
The atmosphere was looking more lively than ever and there was big entourage of American cars/taxis on the street. It really felt like an American city center for a change! (in contrast to mostly quiet and less crowded streets of Glasgow)

I will try to update the post later in the evening today, (once am back from the work) with most recent pics from day 3. So stay tuned!

P.S. You can catch the live action of filming on this webcam

 
Leave a comment

Posted by on August 17, 2011 in Movie, World War Z

 

Tags: , , , , , , , , ,

World War Z – Day 2 of filming in Glasgow

Today was the second day of filming WWZ in Glasgow city center. Shooting has not started yet. Preliminary preparations for the shoot are still underway. Things have started to take shape with the gradual Americanization of the Scottish city.

American flags were placed atop some of the main buildings in George sq.

Corinthian Club adorns American flag

Army jeeps have also been brought in today to be used in the shoot.

Army Jeeps

Army Jeeps

Army Jeeps

Brad Pitt and Angelina Jolie along with their kids arrived to Glasgow today via Virgin Train. They reportedly hired the entire train to transport their family to Glasgow for filming of World War Z. Actual filming is expected to commence from tomorrow.

Below are some other random pics from the Day 2. Enjoy!

Hotdog stall

Philadelphia City Paper

Coffee street stall

Crew Vans

Americans Cars/Taxis lined up for the shoot

American Cop cars

SWAT Van

Scottish Postbox concealed!

United States Court House

United States Court House

Americanish bus?

 
Leave a comment

Posted by on August 16, 2011 in Movie, World War Z

 

Tags: , , , , , , , ,

World War Z filming kicks off in Glasgow

World War Z filming kicks off in Glasgow

Today was the first day of filming for Brad Pitt’s new  zombie film, ‘World War Z’, in Glasgow. The city center will be transformed into a post apocalyptic war-torn ruin. Glasgow will double for the US city of Philadelphia, with false shop fronts being constructed and American cars on the roads.

The film crew were busy transforming the George Square into Philadelphia today and all the roads were barricaded with no access to traffic. The actual shooting is supposed to start from Wednesday once everything is in place. I took some quick snaps and couple of videos of the film location, while coming back from work. Will keep on updating the blog about any latest developments, photos and vids relating to World War Z in Glasgow.

 
Leave a comment

Posted by on August 16, 2011 in Movie, World War Z

 

Tags: , , , , , ,

Google Takeout – Download your Data from all Google Services at Once

Google recently introduced Google Takeout, a new service which helps you to download all your data hosted on Google which includes your Picasa albums, Google contacts, your Buzz updates and even your Google+ updates.

The downloaded data is useful in many ways, for example, all the photos uploaded on the Picasa, in every album can be dowloaded in one go. The downloaded albums are arranged in folders.

  1. Head on to Google Takeout and sign in to your Google account.
  2. Under the Choose services tab you can choose what all data you want to download, you will also get the estimated size of the files.
  3. After that, click on Downloads tab and hit Download (you need to re-login).
However, the data from Docs, YouTube, Orkut etc cannot be downloaded using Google Takeout but there’s another service by known as Data Liberation which gives step-by step method to download your data from each Google service.
 
Leave a comment

Posted by on July 4, 2011 in Services, Tools

 

[Geek Tip] – Avoid typing long file path name in command window

Problem:

You need to reference a filename in the Run box or Command Window but don’t want to have to type out a long pathname.

Solution:

  1. Open Windows Explorer and navigate to the file you need to reference.
  2. Open the Run box or Command Window
  3. Drag the file from the explorer window to the run box or command window.

You now have the full path and filename ready to use. No more typing!

 
Leave a comment

Posted by on July 4, 2011 in Tips, Tricks

 

Turn your Android phone into a portable Wi-Fi hotspot

You can turn your Android phone into a portable wi-fi hotspot and get your iPad, iPod Touch, Zune HD, or any other wireless device online. For this you will need to have Android 2.2 installed on your phone.

Here’s the step by step instructions:

1. Go to the Home screen.

2. Select the Menu key.

3. Select Settings.

4. Select Wireless & networks.

5. Select Tethering & portable hotspot.

6. Check the Portable Wi-Fi hotspot checkbox.

7. Select Portable Wi-Fi hotspot settings.

8. Select Configure Wi-Fi hotspot.

9. Input a Network SSID for your connection.

10. Select a security protocol. Options are Open and WPA2 PSK.

If you select WPA2 PSK, input a password for the connection and then select the Save button.

Your portable hotspot is now created.

You will use the Portable Wi-Fi hotspot checkbox from above to enable and disable the connection. Once the connection is active, go to the device you wish to connect and configure its wireless connection to the Network SSID for you Android device and input the password (if you are using WPA2 PSK). You now have wireless access for your iPad, iPhone Touch, Zune HD, etc. anytime there is a cellular connection for your Android phone.

Via: [Tech-Recipes]

 
8 Comments

Posted by on May 24, 2010 in Android

 

Centering an Absolutely Positioned Element Using CSS

Centering an absolutely positioned element is a CSS challenge that I have always struggled with. I always find myself googling for the solution every now and then.

Today I came across this great article for exactly this problem and decided to share it with everybody and document it on my blog for easy referencing later!

Horizontally centering a static element in CSS is normally handled by setting the left and right margins to auto, for example:

#myelement
{
	margin: 0 auto;
}

However, this won’t work on an absolutely positioned element. Its location is determined in relation to the most immediate parent element that has a position of absolute, relative, or fixed.

In the following example, the relative red square has a width set to 40% of the available space. The top-left of the absolutely positioned blue square is positioned 30px across and 10px down:

#outer
{
	position: relative;
	width: 40%;
	height: 120px;
	margin: 20px auto;
	border: 2px solid #c00;
}  

#inner
{
	position: absolute;
	width: 100px;
	height: 100px;
	top: 10px;
	left: 30px;
	background-color: #00c;
}

If we’re unconcerned about the exact dimensions of our blue box, we could omit the width setting and set the same left and right values. This would effectively center our blue box:

#outer
{
	position: relative;
	width: 40%;
	height: 120px;
	margin: 20px auto;
	border: 2px solid #c00;
}  

#inner
{
	position: absolute;
	height: 100px;
	top: 10px;
	left: 30px;
	right: 30px;
	background-color: #00c;
}

So, how can we center our box if it has fixed dimensions? The answer requires a little lateral thinking:

  1. First, we use left: 50%. Unlike background image positions, this will move the left-hand edge of the blue box to the center.
  2. Since our box is too far to the right, we use a negative left margin that’s half its width. In our example, we must set margin-left to -50px to shift the box back to the right place:
#outer
{
	position: relative;
	width: 40%;
	height: 120px;
	margin: 20px auto;
	border: 2px solid #c00;
}  

#inner
{
	position: absolute;
	height: 100px;
        width: 100px;
	top: 10px;
	left: 50%;
	margin-left: -50px;
	background-color: #00c;
}

The blue box will remain centered no matter how the width of the outer element changes!

Via: SitePoint

 
Leave a comment

Posted by on May 5, 2010 in CSS

 

Tags: , , ,

Preventing Injection Attacks in ASP.NET

Script injection attacks occur when a hacker takes a few lines of malicious programming code and enters it in to a form on our Website and then submits the form. If the Website is data driven then chances of risk is more on the Website. Hackers will often inject scripts in to our forms to try and make the system fooled in to thinking that they are valid users in order to delete data or change data or access data from database.

The basic technique for a script injection attack is for the client to submit content with embedded scripting tags. These scripting tags can include <script>, <object>, <applet>, and <embed>. Although the application can specifically check for these tags and use HTML encoding to replace the tags with harmless HTML entities, that basic validation often is not performed.

The following commonly used HTML tags (not an exhaustive list), could allow a malicious user to inject script code:

<applet>
<body>
<embed>
<frame>
<script>
<frameset>
<html>
<iframe>
<img>
<style>
<layer>
<link>
<ilayer>
<meta>
<object> 

>

An attacker can use HTML attributes such as src, lowsrc, style, and href in conjunction with the preceding tags to inject cross-site scripting.

Request Validation

Script injection attacks are a concern for all web developers, whether they are using ASP.NET, ASP, or any other web development technologies. ASP.NET includes a feature designed to automatically combat script injection attacks, known as request validation. Request validation checks the posted form input and raises an error if any potentially malicious tags ( such as <script> ) are found. In fact, request validation disallows any nonnumeric tags, including HTML tags (such as <b> and <img>), and tags that do not correspond to anything (such as <xyz>).

To test the script validation features, we can create a simple web page like the one shown below.

If we try to enter a block of content with a script tag and then click the button, ASP.NET will detect the potentially dangerous value and generate an error.


Disabling Request Validation

There may be such a situation where users have a genuine need to specify HTML tags (for example, an advertisement purpose) or a block of XML data. In these situations we need to specifically disable script validation using the ValidateRequest Page directive, as shown below.

<%@ Page ValidateRequest="false" Language="C#" AutoEventWireup="true"
CodeFile="Default.aspx.cs" Inherits="_Default" %>

We can also disable request validation for an entire web application by modifying the web.config file. We need to add or set the validateRequest attribute of the <pages> element, as shown here.

<configuration>
    <appSettings/>
    <connectionStrings/>
    <system.web>
      <pages validateRequest="false"/>
    </system.web>
</configuration>

The following screenshot is showing what will happen when a user clicks on the submit button.

  protected void btnSubmit_Click(object sender, EventArgs e)
  {
      Response.Write(txtInput.Text);
  }

Encode Output

Use the HttpUtility.HtmlEncode method to encode output if it contains input from the user or from other sources such as databases. HtmlEncode replaces characters that have special meaning in HTML-to-HTML variables that represent those characters. For example, < is replaced with < and ” is replaced with “. Encoded data does not cause the browser to execute code. Instead, the data is rendered as harmless HTML.

To prevent a script injection attack from happening when request validation is turned off, we need to explicitly encode the content before we display it using the Server object.

protected void btnSubmit_Click(object sender, EventArgs e)
{
  Response.Write("Entered Input is: "+Server.HtmlEncode(txtInput.Text));
}

The following screenshot is showing the output of the above mentioned code.

It is clear that script injection is a big concern to the developers and to protect our pages from the hand of hackers we should not consider only request validation, but also should not forget to use HtmlEncode wherever applicable. It should be noted that we can disable request validation on a page-b, we should use proper numeric validation, range validation and avoiding some characters such as “*”, “%”, “@”, or “!” in order to prevent script injection.

Further reading:

How To: Protect From Injection Attacks in ASP.NET

 
Leave a comment

Posted by on June 7, 2008 in ASP.NET, Security, Web Development

 

Tags: , , ,

FancyUpload – AJAX Uploader with Progress Bar

FancyUpload is a file-input replacement which features an unobtrusive, multiple-file selection menu and queued upload with an animated progress bar.

It is easy to setup, is server independent, completely styleable via CSS and XHTML and uses MooTools to work in all modern browsers.

It is fully compatible with all A-Grade Browsers (Internet Explorer 6+, Opera 9, Firefox 1.5+ and Safari 2+)

Features

  • Select and upload multiple files
  • Filter files by type in the select dialog
  • Optional Events to add your own behaviour
  • Show and filter useful file information before the upload starts
  • Limit uploads by file count and/or file size
  • Platform and server independent, just needs Flash 8+ (> 95% penetration)
  • Unobtrusive, since the element is replaced after the swf loaded successfully
  • Cancel running uploads, add files during upload
  • Everything is optional, documented and easy editable

[ Demo ] [ Website ]

 
Leave a comment

Posted by on June 3, 2008 in AJAX, Javascript, Web Development

 

Tags: , ,

 
Follow

Get every new post delivered to your Inbox.