Tuesday 26 April 2011

How to troubleshoot problems while installing Magento1.5 in localhost



Invalid Base url ( Please enter a valid URL. Protocol is required (http://, https:// or ftp://):



To accept your localhost as url by modifying the validation.js file which is present in the magento installation directory at js\prototype\validation.js

Go to line No:500 

['validate-url', 'Please enter a valid URL. Protocol is required (http://, https:// or ftp://)', function (v) {

return Validation.get('IsEmpty').test(v) || /^(http|https|ftp):\/\/(([A-Z0-9][A-Z0-9_-]*)(\.[A-Z0-9][A-Z0-9_-]*)+)(:(\d+))?\/?/i.test(v)
}],

I remove all the regular expressions present and simply return true.

Replace this below code:

['validate-url', 'Please enter a valid URL. http:// is required', function (v) {
return true;
}],

1 comment:

  1. Wonderful post and an obligation of appreciation is all together for share any way . I require you to visit the association underneath to get some accommodating data like Magento web development services | Magento development services india

    ReplyDelete