Django I Migrate Error: TypeError expected string or bytes-like object "TypeError: expected string or bytes-like object", says the value we have provided for updating the field for the model is not supported. So to resolve this issue …

Last updated 4 years, 5 months ago | 7126 views

Tags:- Django

SQL | difference between BETWEEN and IN operator The BETWEEN operator selects all records between the given range whereas IN operator selects all matching records given with the WHERE clause.   BETWEEN operator The Between operator in …

Last updated 6 years, 5 months ago | 6892 views

Tags:- SQL MySQL

 PHP | implode() and explode() function implode() function is use to convert an array into a string where as explode() function is used to convert an string into an array   implode() The implode() function …

Last updated 6 years, 6 months ago | 6813 views

Tags:- PHP

PHP | Case Sensitive In PHP, keywords (e.g. if, else, while, echo, etc.), classes, functions, and user-defined functions are not case-sensitive but all variable names are case-sensitive.   If you defined function name in lowercase, …

Last updated 6 years, 1 month ago | 6672 views

Tags:- PHP

HTML | Make an anchor tag to do nothing | href="javascript:void(0);" To prevent reloading a page when a link clicked is something like preventing the default behavior of an element. It can be achieved by providing …

Last updated 5 years, 5 months ago | 6628 views

Tags:- HTML JQuery JavaScript

CodeIgniter | What is helpers | Load helper file Helper is simply a collection of function in a particular category which helps you with tasks. The helper file can be loaded in controller constructor, some …

Last updated 6 years, 3 months ago | 6588 views

Tags:- CodeIgniter

Jquery | Auto Focus On Next Input Field The jquery code for autofocus on the next text input field. $(".input-key").keyup(function() { if ($(this).val().length == $(this).attr("maxlength")) { $(this).next('.input-key').focus(); } }); Let's go through the above jquery …

Last updated 5 years, 6 months ago | 6497 views

Tags:- HTML JQuery JavaScript

PHP-MYSQL |  mysqli_fetch_assoc() VS  mysqli_fetch_array() mysqli_fetch_assoc() function fetch a result row as an associative array where as mysqli_fetch_array() function fetch a result row as an associative array, a numeric array, or both.       mysqli_fetch_assoc() The mysqli_fetch_assoc() …

Last updated 7 years ago | 6444 views

Tags:- PHP PHP-MySQL

PHP | Add numbers of days to a date Simple and easy way to add some days in a given date using strtotime() function. <?php $p_date = "2019-01-10"; echo date('Y-m-d', strtotime($p_date . ' + 1 days')); echo …

Last updated 6 years, 9 months ago | 5967 views

Tags:- PHP

PHP | Stop the execution of php script | exit() funtion By using exit() function we can stop the execution of php script.   <?php $a = 10; $b = 20; $c = $a+$b; exit(); …

Last updated 6 years, 6 months ago | 5796 views

Tags:- PHP

Django rest framework  authentication error “ TypeError: 'type' object is not iterable ” This error comes because "authentication_classes" expecting an iterable(list/tuple) but somehow it is getting something else. So it needs to check a few …

Last updated 4 years, 5 months ago | 5781 views

Tags:- Python Django django-rest-framework

$name and $$name both are variables but with a single difference that is $name is just a normal php variable where as $$name is known as reference variable. It allow you to use $name variable's …

Last updated 6 years, 6 months ago | 5587 views

Tags:- PHP

JQuery | TinyMCE | Clear TINYMCE editor  There is a method called setContent() in TINTMCE which you can use to reset/clear the TINTMCE editor. <script> // if one editor existing in your page. tinyMCE.activeEditor.setContent(''); </script> …

Last updated 5 years, 11 months ago | 5504 views

Tags:- JQuery JavaScript TINYMCE

Codeigniter | Set timezone To set default timezone in Codeigniter, you can add the date_default_timezone_set() function in your application/config.php or index.php file. date_default_timezone_set('your timezone');   <?php // India timezone date_default_timezone_set('Asia/Kolkata'); ?>  

Last updated 6 years, 3 months ago | 5492 views

Tags:- CodeIgniter

PHP | Combine two strings There are several ways to concatenate two strings in PHP. Use the concatenation operator [.] and [.=] There are two string operators that are used for concatenation. [.]:  Concatenation operator …

Last updated 6 years, 6 months ago | 5050 views

Tags:- PHP