Laravel ClassLoader trying to load an old version of class
Laravel ClassLoader trying to load an old version of class throws an error 'failed to open stream: No such file or directory'
How to solve this problem?
Clear composer cache and then run composer dump-autoload.
How to solve this problem?
Clear composer cache and then run composer dump-autoload.
composer clear-cache
composer dump-autoload
Expand div to full screen
Here we are showing how to expand a div to full screen. See the demo and do it.
Sample code and demo is here
Demo
Bootstrap model with jquery ui dialog occur a max callstack size exceeded error
Open a jquery ui dialog from bootstrap modal. This occur a max call stack size exceeded error in console.
We can solve this error in two way in my knowledge.
1) set 'modal' property to false in jqueryui dialog.
e.g.
We can solve this error in two way in my knowledge.
1) set 'modal' property to false in jqueryui dialog.
e.g.
$( ".selector" ).dialog({2) Add the below line of code to your page
modal: false
});
$.fn.modal.Constructor.prototype.enforceFocus = function (){};
Access global variable from a function, which has same variable name
How to access global variable from a function, which has same variable name in java script.
You can use the window object to get the global variable.
You can use the window object to get the global variable.
e.g. window.variableNameHere we write an example
var blogName = "webspeckle";
var blog = function()
{
var blogName = window.blogName || "";
return blogName;
}
blog();
//The output is 'webspeckle'
Split a string into an array of strings in JavaScript
Definition and Usage
The split() method is used to split a string into an array of strings.
Syntax
Specifies the character, regular expression, or substring that is used to determine where to split the string
howmany Optional. Specify how many times split should occur. Must be a numeric value
Note: If an empty string ("") is used as the separator, the string is split between each character.
Sample code and demo is here
Demo
The split() method is used to split a string into an array of strings.
Syntax
stringObject.split(separator, howmany)separator Required.
Specifies the character, regular expression, or substring that is used to determine where to split the string
howmany Optional. Specify how many times split should occur. Must be a numeric value
Note: If an empty string ("") is used as the separator, the string is split between each character.
Sample code and demo is here
Demo
Sticky Footer Template for Bootstrap
Sticky footer is a fixed-height footer to the bottom of the viewport in desktop browsers. The purpose of a sticky footer is that it "sticks" to the bottom of the browser window. But not always, if there is enough content on the page to push the footer lower, it still does that. But if the content on the page is short, a sticky footer will still hang to the bottom of the browser window.
Sample code and demo is here
Demo
Sample code and demo is here
Demo
Add new properties to an object constructor in JavaScript
Add new properties to an object constructor in JavaScript
Suppose we have a function WebsiteData() and it has two parameters(title,description).
WebsiteData.prototype.keywords = "my website keywords";
Sample code and demo is here
Suppose we have a function WebsiteData() and it has two parameters(title,description).
function WebsiteData(pageTitle, pageDescription) {Add a new property 'keywords' to this function WebsiteData().
this.title = pageTitle;
this.description = pageDescription;
}
WebsiteData.prototype.keywords = "my website keywords";
Sample code and demo is here