Wednesday, March 16, 2011

ajaxForm and ajaxSubmit Options

Wednesday, March 16, 2011
Both ajaxForm and ajaxSubmit support numerous options which can be provided using an Options Object. The Options Object is simply a JavaScript object that contains properties with values set as follows:

target
Identifies the element(s) in the page to be updated with the server response. This value may be specified as a jQuery selection string, a jQuery object, or a DOM element.
Default value: null
replaceTarget
Optionally used along with the the target option. Set to true if the target should be replaced or false if only the target contents should be replaced.
Default value: false
Added in v2.43
url
URL to which the form data will be submitted.
Default value: value of form's action attribute
type
The method in which the form data should be submitted, 'GET' or 'POST'.
Default value: value of form's method attribute (or 'GET' if none found)
data
An object containing extra data that should be submitted along with the form.

data: { key1: 'value1', key2: 'value2' }

dataType
Expected data type of the response. One of: null, 'xml', 'script', or 'json'. The dataType option provides a means for specifying how the server response should be handled. This maps directly to the jQuery.httpData method. The following values are supported:

'xml': if dataType == 'xml' the server response is treated as XML and the 'success' callback method, if specified, will be passed the responseXML value

'json': if dataType == 'json' the server response will be evaluted and passed to the 'success' callback, if specified

'script': if dataType == 'script' the server response is evaluated in the global context

Default value: null
beforeSerialize
Callback function to be invoked before the form is serialized. This provides an opportunity to manipulate the form before it's values are retrieved. The beforeSerialize function is invoked with two arguments: the jQuery object for the form, and the Options Object passed into ajaxForm/ajaxSubmit.

beforeSerialize: function($form, options) {
// return false to cancel submit
}

Default value: null
beforeSubmit
Callback function to be invoked before the form is submitted. The 'beforeSubmit' callback can be provided as a hook for running pre-submit logic or for validating the form data. If the 'beforeSubmit' callback returns false then the form will not be submitted. The 'beforeSubmit' callback is invoked with three arguments: the form data in array format, the jQuery object for the form, and the Options Object passed into ajaxForm/ajaxSubmit.

beforeSubmit: function(arr, $form, options) {
// The array of form data takes the following form:
// [ { name: 'username', value: 'jresig' }, { name: 'password', value: 'secret' } ]

// return false to cancel submit
}

Default value: null
success
Callback function to be invoked after the form has been submitted. If a 'success' callback function is provided it is invoked after the response has been returned from the server. It is passed the following arguments:

1. 1.) responseText or responseXML value (depending on the value of the dataType option).
2. 2.) statusText
3. 3.) xhr (or the jQuery-wrapped form element if using jQuery < 1.4)
4. 4.) jQuery-wrapped form element (or undefined if using jQuery < 1.4)

Default value: null
semantic
Boolean flag indicating whether data must be submitted in strict semantic order (slower). Note that the normal form serialization is done in semantic order with the exception of input elements of type="image". You should only set the semantic option to true if your server has strict semantic requirements and your form contains an input element of type="image".
Default value: false
resetForm
Boolean flag indicating whether the form should be reset if the submit is successful
Default value: null
clearForm
Boolean flag indicating whether the form should be cleared if the submit is successful
Default value: null
iframe
Boolean flag indicating whether the form should always target the server response to an iframe. This is useful in conjuction with file uploads. See the File Uploads documentation on the Code Samples page for more info.
Default value: false
iframeSrc
String value that should be used for the iframe's src attribute when/if an iframe is used.
Default value: about:blank
Default value for pages that use https protocol: javascript:false
forceSync
Boolean value. Set to true to remove short delay before posting form when uploading files (or using the iframe option). The delay is used to allow the browser to render DOM updates prior to performing a native form submit. This improves usability when displaying notifications to the user, such as "Please Wait..."
Default value: false
Added in v2.38

Example:

// prepare Options Object
var options = {
target: '#divToUpdate',
url: 'comment.php',
success: function() {
alert('Thanks for your comment!');
}
};

// pass options to ajaxForm
$('#myForm').ajaxForm(options);

Note that the Options Object can also be used to pass values to jQuery's $.ajax method. If you are familiar with the options supported by $.ajax you may use them in the Options Object passed to ajaxForm and ajaxSubmit.

reference url: http://jquery.malsup.com/form/#options-object http://www.penomet.com

Saturday, February 12, 2011

Magento 1.5.0.1 Bug: Call to a member function loadPriceData() on a non-object

Saturday, February 12, 2011
Open app\code\core\Mage\Catalog\Model\Product\Attribute\Backend\Tierprice.php

Comment out lines from 202 to 219

Error:Fatal error: Call to a member function loadPriceData() on a non-object in E:\wamp\www\magento\app\code\core\Mage\Catalog\Model\Product\Attribute\Backend\Tierprice.php on line 202

/* $data = $this->_getResource()->loadPriceData($object->getId(), $websiteId);
foreach ($data as $k => $v) {
$data[$k]['website_price'] = $v['price'];
if ($v['all_groups']) {
$data[$k]['cust_group'] = Mage_Customer_Model_Group::CUST_GROUP_ALL;
}
}

if (!$object->getData('_edit_mode') && $websiteId) {
$rates = $this->_getWebsiteRates();

$full = $data;
$data = array();
foreach ($full as $v) {
$key = join('-', array($v['cust_group'], $v['price_qty']));
if ($v['website_id'] == $websiteId) {
$data[$key] = $v;
$data[$key]['website_price'] = $v['price'];
} else if ($v['website_id'] == 0 && !isset($data[$key])) {
$data[$key] = $v;
$data[$key]['website_id'] = $websiteId;
if ($object->getPriceModel()->isTierPriceFixed()) {
$data[$key]['price'] = $v['price'] * $rates[$websiteId]['rate'];
$data[$key]['website_price'] = $v['price'] * $rates[$websiteId]['rate'];
}
}
}
}

$object->setData($this->getAttribute()->getName(), $data);
$object->setOrigData($this->getAttribute()->getName(), $data);

$valueChangedKey = $this->getAttribute()->getName() . '_changed';
$object->setOrigData($valueChangedKey, 0);
$object->setData($valueChangedKey, 0); */

Saturday, April 3, 2010

Social Bookmarking and Article Submission Helpfull to SEO

Saturday, April 3, 2010

Importance of Social Bookmarking, Importance of Article Submissio, Social Bookmarking and Article Submission, Social Bookmarking and Article Submission Helpfull to SEO, Social Bookmarking and Article Submission Get Good Back Links, Article Submission For SEO, Social Bookmarking For SEO

Many new Internet marketers want to drive traffic, but they are not sure how to go about doing so. On the Internet, there are many different ways to drive traffic. Since major search engines account for a large percentage of traffic, many marketers have turned to SEO (search engine optimization). This is a process of building links on a regular basis so that the pages on a website get higher rankings in the search indexes. The higher the rankings, the more traffic a website will get.

The entire search engine optimization process consists of two components - off-site factors and on-site factors. On-site factors are easier to implement, and involves changing elements such as page title, meta tags, etc. of the web pages. The main challenge lies in off-site factors.

Off-site factors involve building relevant one way back links. A link from an external page is considered as one back link. The links have to be from relevant pages. Each link counts as a "vote" in the eyes of the search engines. The more back links (or "votes") that a website has, the higher it will rank.

Knowing this, Internet marketers will go to great lengths to build relevant one way back links to their web properties. There are many ways to build back links. Two of the most popular methods are social bookmarking and article submission.

Social bookmarking.

Social bookmarking sites are community based sites that allow members to bookmark or vote for their favorite content. They can add friends to their own network, and whenever they add a new bookmark, their friends get to know about it. They may then give it the thumbs up or the thumbs down if they want to. Content that gets the most number of positive votes are give a lot more exposure by the social bookmarking sites. This leads to more traffic for the content site.

If the content is really good, links spread really fast through social bookmarking sites, mostly by word of mouth. Eventually, the links may even end up in blogs, forums, and other websites. This is why many bloggers and webmasters like to build links using social bookmarking.

Article submission.

Article submission is another great way to build relevant one way back links. Quality articles are submitted to well established article directories. In exchange for the content, the author is allowed to add two or three text links at the end of each article. Authors can submit as many articles as they want. The more articles they submit, the more back links they get.

Article submission is not something new. It has been around for years, and article marketers who have diligently used this method to build links have enjoyed high rankings in the search engines for a very long time. This is a link building method that has withstood the test of time. To this day, article submissions still work very well.

Article Source: http://EzineArticles.com/?expert=Darren_W_Chow

Saturday, July 11, 2009

Sania Mirza Sohrab Mirza engagement photos and news videos

Saturday, July 11, 2009

Sania Mirza Engagement,Sania Mirza Engagement Photos,Sania Mirza Engagement Videos,Sania Mirza Engagement Photos and Videos,Sania Mirza and Sohrab Mirza Engagement

Sania Mirza Sohrab Mirza Engagement photos and news videos



sania mirza engagement sohrab mirza pics

Match point: Indian tennis ace Sania Mirza has got engaged to her childhood friend and Hyderabad-based businessman Mohammed Sohrab Mirza. Sohrab Mirza, 23, an MBA student and son of a city-based businessman. In photo: In this Hand out photograph released by Sania Mirza's family India's tennis star Sania Mirza is seen with her childhood friend and fiance Sohrab Mirza,left, after their engagement ceremony, in Hyderabad, India, Friday, July 10, 2009. (AP Photo/Family Hand Out)

sania mirza engagement

Friday, July 10, 2009

Google announces own operating system,Google attacks Microsoft with new browser-based operating system for low-cost computers

Friday, July 10, 2009
Google's new operating system to take on Microsoft,Google attacks Microsoft with new browser-based operating system for low-cost computers,Google’s new OS could hit Microsoft where it hurts,Google announces own operating system to take on Microsoft,Google announces own operating system

Google Inc. is working on a new operating system for inexpensive computers in a daring attempt to diminish Microsoft Corp.'s longstanding control over people's computer experience.

At the core of Google's vision is the most important trend in the networked world: the move from running applications on a desktop computer to running them through a web browser.

The new operating system, announced Tuesday night on Google's Web site, will be based on the company's 9-month-old Web browser, Chrome. Google intends to rely on help from the community of open-source programmers to develop the Chrome operating system, which is expected to begin running computers in the second half of 2010.

Google is designing the operating system primarily for "netbooks," a lower-cost, less powerful breed of laptop computers that is becoming increasingly popular among budget-conscious consumers primarily interested in surfing the Web.

Google has already introduced an operating system for smart phones and other mobile devices, called Android, that vies against various other systems, including ones made by Microsoft and Apple Inc.

The Android system worked well enough to entice some computer makers to begin developing netbooks that will run on it. For instance, Acer Inc., the world's third-largest PC maker, said last month it would make netbooks that run Android instead of Windows. Acer said Android would make the computers less expensive and possibly help them boot up faster.

Google, though, apparently believes a Chrome-based system will be better suited for netbooks.

That is a direct challenge to Microsoft, whose next operating system, Windows 7, is being geared for netbooks as well as larger computers. And it would be Google's boldest confrontation yet with its biggest nemesis.

Microsoft had no immediate comment Wednesday.

A duel between the two technology powerhouses has been steadily escalating in recent years as Google's dominance of the Internet's lucrative search market has given it the means to threaten Microsoft in ways that few other companies can.

Google already has rankled Microsoft by luring some of its top employees and developing an online package of computer programs that provide an alternative to Microsoft's top-selling word processing, spreadsheet and calendar applications.

Meanwhile, Microsoft has been trying to thwart Google by investing billions of dollars to improve its own Internet search and advertising systems — to little avail so far.

In the past month or so, though, Microsoft has been winning positive reviews and picking up more users with the latest upgrade to its search engine, now called Bing. Microsoft is hailing the makeover with a $100 million marketing campaign.

Now Google is aiming for Microsoft's financial jugular with Chrome its operating system.

Microsoft has drawn much of its power — and profits — from the Windows operating system that has steered most personal computers for the past two decades.

Google's chief executive, Eric Schmidt, and its co-founders, Larry Page and Sergey Brin, have not concealed their disdain for Windows.

Schmidt maintains Microsoft sometimes unfairly rigs its operating system to limit consumer choices — something that Microsoft has consistently denied doing. Google fears Microsoft could limit access to its search engine and other products if Windows is set up to favor Microsoft products.

Google made a veiled reference to Windows' perceived shortcomings in its blog posting Tuesday.

"We hear a lot from our users and their message is clear — computers need to get better," wrote Sundar Pichai, Google's vice president of product management and Linus Upson, Google's engineering director. "We believe choice will drive innovation for the benefit of everyone, including Google."

Schmidt and Brin are expected to discuss Google's new operating system this week when they appear at a media conference hosted by Allen & Co. at the Sun Valley resort in Idaho.

Despite its own power and prominence, Google won't have an easy time changing the status quo that has governed personal computing.

As an example of how difficult it is to topple a long-established market leader, Google estimates about 30 million people are now using its Chrome browser — a small fraction of those that rely on Microsoft's market-leading Internet Explorer. And there have been various attempts to develop open-source software to undermine Windows on PCs, with relatively little effect.

Saturday, July 4, 2009

Railway Budget - 2009-2010,Budget - 2009-2010,Railway Budget - 2009,Indian Railway Budget - 2009

Saturday, July 4, 2009
Highlights of Railway Budget - 2009-2010,Railway Budget - 2009-2010,Budget - 2009-2010,Railway Budget - 2009,Indian Railway Budget - 2009, Indian Railway Budget - 2009-2010,Railway minister Mamata Banerjee Railway Budget, Mamata Banerjee Railway Budget,Mamata Banerjee Railway Budget 2009-2010,Railway Budget 2009-2010 mixed-response,Railway Budget 2009-2010 response


1. NO INCREASE IN PASSENGER FARE AND FREIGHT TARIFF











2. BUDGET TO HAVE INCLUSIVE GROWTH AND EXPANSION OF RAILWAY NETWORK TO EVERY CORNER OF THE COUNTRY


3. PLAN OUTLAY OF INR 40,745 CRORE PROPOSED FOR 2009-2010,

4. PASSENGER AMENITIES GET HIGH PRIORITY, TO GET 119% INCREASE

5. TRAFFIC RECEIPTS DURING 2008-09 INCREASE BY 11.4 % WHILE FREIGHT LOADING GREW BY 5%



6. SPECIAL TRAINS FOR PERISHABLE FARM PRODUCE, FACILITIES FOR TRANSPORTATION OF RURAL CRAFT

7. WORKS FOR 7 NEW LINES, GAUGE CONVERSION OF 17 LINES AND DOUBLING OF 13 LINES TO BE TAKEN UP

8. FASTER PARCEL SERVICES PROPOSED ON THREE ROUTES

9. TATKAL SCHEME TO BE MADE PASSENGER FRIENDLY

10. RAILWAY TICKETS TO BE MADE AVAILABLE THROUGH POST OFFICES AND ‘MUSHKIL AASAAN’ MOBILE VANS

10. CONCESSION FOR PRESS PERSONS INCREASED TO 50%

11. MONTHLY TICKET OF INR 25 FOR UNORGANIZED SECTOR/POOR UNDER ‘IZZAT’ SCHEME

12. “ONLY LADIES’ EMU TRAINS AT DELHI, KOLKATA AND CHENNAI

13. “YUVA TRAINS” FROM RURAL HINTERLAND TO METROS AT CONCESSIONAL FARE

14. 12 NEW POINT-TO-POINT “DURANTO” TRAINS

Ø 57 NEW TRAINS, EXTENSION OF 27 TRAINS AND INCREASE IN FREQUENCY OF 13 TRAINS AND AIR-CONDITIONED DOUBLE-DECKER TRAINS PROPOSED

15. 50 STATIONS TO BE UPGRADED TO WORLD CLASS STATIONS

16. LONG DISTANCE TRAINS TO HAVE ON-BOARD DOCTORS AND INFOTAINMENT SERVICES

17. HANDICAPPED AND AGED PERSONS TO HAVE MORE AMENITIES

18. SPECIAL FUND FOR THE DEVELOPMENT OF NORTH EAST RAILWAY

19. QUAZIGUND-ANANTNAG LINE TO BE COMPLETED BY NEXT MONTH

20. 6560 RAILWAY STAFF QUARTERS TO BE CONSTRUCTED AND GROUP ‘D’ EMPLOYEES TO GET SCHOLARSHIPS FOR THEIR GIRL CHILD

21. RAILWAYS TO COME OUT WITH WHILE PAPER ON FINANCIAL STATUS AND VISION-2020 DOCUMENT

Presenting the Railway Budget for 2009-10 in Parliament, Minister of Railways Kumari Mamata Banerjee announced that there will be no increase in passenger fare and freight tariff. She said that the budget will have approach for ‘inclusive growth’ and expansion of rail network to take development to every corner of the country.

Presenting the railway budget she proposed an outlay of INR 40,745 crore for 2009-10. Out of this, INR 2,921 crore will be spent on new lines, INR 1,750 crore on gauge conversion and INR 1,102 crore on passenger amenities, which is 119% more than the allocation in the interim budget. INR 424 crore will also be spent on railway staff amenities.

She proposed freight loading target of 882 million tonnes and estimated gross freight receipt at INR 88,419 crore

Giving an overview of financial performance of the Railways in 2008-09, the minister informed that freight loading during the period grew by 5% while traffic receipt increased by 11.4% to reach INR 79,862 crore

The budget has proposals for 7 new lines, gauge conversion of 17 lines and doubling of 13 railway lines. In addition, proposals for 53 new lines, 3 gauge conversion and doubling of 12 lines will be processed during the year.

Tuesday, June 30, 2009

some buildings are so unusual

Tuesday, June 30, 2009

Architecture has a purpose, but some buildings are so unusual they are just plain silly. Sure, architects aren’t perfect, but I wonder how they come up with such crazy ideas. Here are some of the weirdest and most unusual buildings on the earth .