$(“.myCheckbox”).attr(‘checked’, true); // Deprecated $(“.myCheckbox”).prop(‘checked’, true); Check if the checkbox is checked There are several ways to get to work out if a checkbox is…
Leave a CommentMonth: July 2015
Sometimes you may need to eager load a relationship after the parent modal has already been retrieved. For Example this may be very useful if…
Leave a CommentHere is the simple code snippet to get all the tables under the database in laravel framework. $tables = DB::select(‘SHOW TABLES’); dd($tables);
Leave a CommentHere is the simple laravel’s eloquent code snippet to get results in a table when there are no results for the relationship. I have two…
Leave a CommentYii2 Default application name is “My Application”. You can change this name by editing the config/main.php. Just add the application name property in Config Array.…
Leave a CommentIn this post, I would like to show you how to create a drop-down list in yii2. This tutorial will help you to display the…
3 Commentsvar url = ‘http://www.arjunphp.com/’; $(location).attr(‘href’,url);
Leave a CommentHere is the list of type checking function in PHP. Function Description is_array() Check for array type is_bool() Check for true or false type is_float()…
Leave a CommentYou can use the fgets() function with combination of fopne() funciton to read the file line by line. $filename = “inputfile.txt”; if (file_exists($filename) && is_readable…
Leave a CommentTemplate pattern comes under behavior pattern group, as it’s used to manage algorithms, relationships and responsibilities between objects. This is an easy Pattern to understand,…
Leave a CommentThe alternative PHP tags <% (and <%=), %>, <script language=”php”>, and </script> have been removed in PHP7. Additionally the asp_tags ini directive is removed. Trying…
Leave a Comment