Category Archives: AJAX

Cesium – AJAX to update InfoBox ? is the entity.


Perl Interview Questions?

What is use of ‘strict’ in perl ?
The module strict restricts ‘unsafe constructs’, according to the perldocs
When you enable the strict module, the three things that Perl becomes strict about are:
• Variables ‘vars’
• References ‘refs’
• Subroutines ‘subs’
Strict variables are useful. Essentially, this means that all variables must be declared, that is defined before use. Furthermore, each variable must be defined with my or fully qualified

What is scalars in perl ?
The most basic kind of variable in Perl is the scalar variable. Scalar variables hold both strings and numbers, and are remarkable in that strings and numbers are completely interchangable. For example, the statement
$priority = 9;
sets the scalar variable $priority to 9, but you can also assign a string to exactly the same variable:
$priority = ‘high’

Perl difference between lists and arrays ?
A list is a fixed collection of scalars. An array is a variable that holds a variable collection of scalars.
Array operations, which change the scalars, reaaranges them, or adds or subtracts some scalars, only work on arrays. These can’t work on a list, which is fixed. Array operations include shift, unshift, push, pop, and splice.
You can change an array element, but you can’t change a list element.

What is the use of ‘defined’?
defined EXPR

Returns true if EXPR has a value other than the undef value, or checks the value of $_ if EXPR is not specified.
If EXPR is a function or function reference, then it returns true if the function has been defined.

Return Value
• 0 if EXPR contains undef
• 1 if EXPR contains a valid value or reference


What is ajax synchronous and asynchronous?

Synchronous – Script stops and waits for the server to send back a reply before continuing. There are some situations where Synchronous Ajax is mandatory.

In standard Web applications, the interaction between the customer and the server is synchronous. This means that one has to happen after the other. If a customer clicks a link, the request is sent to the server, which then sends the results back.

Because of the danger of a request getting lost and hanging the browser, synchronous javascript isn’t recommended for anything outside of (onbefore)unload event handlers, but if you need to hear back from the server before you can allow the user to navigate away from the page, synchronous Javascript isn’t just your best option.

Synchronous AJAX function Example using GET.

Synchronous AJAX function Example using POST.

Asynchronous – Where the script allows the page to continue to be processed and will handle the reply if and when it arrives. If anything goes wrong in the request and/or transfer of the file, your program still has the ability to recognize the problem and recover from it.
Processing asynchronously avoids the delay while the retrieval from the server is taking place because your visitor can continue to interact with the web page and the requested information will be processed with the response updating the page as and when it arrives.


What is Ajax?

Ajax (sometimes called Asynchronous JavaScript and XML) is a way of programming for the Web that gets rid of the hourglass. Data, content, and design are merged together into a seamless whole. When your customer clicks on something on an Ajax driven application, there is very little lag time. The page simply displays what they’re asking for.

Ajax is a way of developing Web applications that combines:

  • XHTML and CSS standards based presentation
  • Interaction with the page through the DOM
  • Data interchange with XML and XSLT
  • Asynchronous data retrieval with XMLHttpRequest
  • JavaScript to tie it all together

How to send bulk email through email software?

If you’re sending an email campaign to thousands or millions of user using some software then you’re going to need a reliable mail server. Most of the shared servers are not going to allow you send more email. There are a lot of restrictions and host may impose email sending restrictions which makes it impossible to send.

There are ways to send –
1. You can send emails out application your web host’s mail sending engine. This advantage is accomplished if you’re sending only a few hundred emails per month, about as soon as you go over this, your host will not allow you to send more. This option is good for sending email using online php tools so many are available please check with google 🙂
2. You can buy your own committed server from service provider like or (we are using this!) and configure it to send emails. We send 60000 emails per month without any issue, they have easy to use web interface. We just create newsletter test and send to our subscribers. It works perfectly.

3. Most effective option is using third party mail server like Even if you are using shared server you can use there service if you have tones of email to send. Don’t forget to negotiate for discount if you are using there partners software!!


How to delete a folder with PHP?

To delete a file, or a folder and its contents i have compiled a recursive algorithm.
Hope this will be useful for all of you.


How to get the page name of the current URL?

Using this script you can get PHP current page from a url.