Posts

Showing posts from 2017

Most Useful .htaccess Tricks for WordPress website

Most Useful .htaccess Tricks for WordPress website Some most useful .htaccess tricks for your WordPress website are here. Wordpress needs htaccess to work perfectly and runs smoothly. Here is the htaccess code for a basic wordpress site: # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> # END WordPress ----------- If you are using Localhost , for example: http://localhost/codingsparks Then htaccess is... # BEGIN WordPress <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / codingsparks/ RewriteRule ^index\.php$ - [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /codingsparks /index.php [L] </IfModule> # END WordPress Wordpress MultiSite htaccess: RewriteEngine On RewriteBase / RewriteRu...

How to avoid Access-Control-Allow-Origin error using htaccess

How to avoid Access-Control-Allow-Origin error using htaccess Add the below code in you .htaccess file. #avoid Access-Control-Allow-Origin error using htaccess <IfModule mod_headers.c>   <FilesMatch "\.(ttf|ttc|otf|eot|woff|woff2|font.css|css|js)$">     Header set Access-Control-Allow-Origin "*"   </FilesMatch> </IfModule>

Update Php.ini values from htaccess

Add the below code to change the default php.ini settings 1) Upload Max Filesize 2) Post Max Size  3) Max Execution Time  4) Max Input Time  5) Memory Limit  #Update Php.ini values from htaccess php_value upload_max_filesize 512M php_value post_max_size 512M php_value max_execution_time 600 php_value max_input_time 600 php_value memory_limit 512M we can also update in php.ini or .user.ini.

Remove public from Laravel using htaccess

Remove public from Laravel using htaccess RewriteEngine On # Remove all trailing slashes  RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_URI} /(.*)/$ RewriteRule ^ /%1 [R=301,L] RewriteCond %{REQUEST_URI} !(\.css|\.js|\.png|\.jpg|\.gif|robots\.txt)$ [NC] RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^ index.php [L] RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_URI} !^/public/ RewriteRule ^(css|js|images)/(.*)$ public/$1/$2 [L,NC]

How To Install XAMPP/LAMPP Stack On Ubuntu 16.04 64bit Step by Step

Install XAMPP/LAMPP 64bit Stack Step by Step:   Step1:  Open Terminal   Step2:  Before installing the package, create a directory.  user1@user1:~$ mkdir xampp  user1@user1:~$ cd xampp/  user1@user1:~/xampp$  * it creates a folder in HOME   Step3:  Download the XAMPP/LAMPP package by using the wget command  user1@user1:~/xampp$ wget https://www.apachefriends.org/xampp-files/5.6.20/xampp-linux-x64-5.6.20-0-installer.run     Step4:  Run the following command to make XAMPP execuatable.  chmod +x xampp-linux-x64-5.6.20-0-installer.run   Step5:  Install XAMPP stack as shown below.  sudo ./xampp-linux-x64-5.6.20-0-installer.run  [sudo] password for user1:

How To Install XAMPP/LAMPP Stack On Ubuntu 16.04 32bit

Install XAMPP Stack On Ubuntu 16.04 32bit Install XAMPP/LAMPP 32bit Stack Step by Step:   Step1:  Open Terminal   Step2:  Before installing the  XAMPP/LAMPP 32bit Stack  package, create a directory.  user1@user1:~$ mkdir xampp  user1@user1:~$ cd xampp/  user1@user1:~/xampp$  * it creates a folder in HOME   Step3:  Download the XAMPP/LAMPP package by using the wget command  user1@user1:~/xampp$ wget https://sourceforge.net/projects/xampp/files/XAMPP%20Linux/5.6.23/xampp-linux-5.6.23-0-installer.run   Step4:  Run the following command to make XAMPP execuatable.   chmod +x xampp-linux-5.6.23-0-installer.run   Step5:  Install XAMPP stack as shown below.  sudo ./xampp-linux-5.6.23-0-installer.run  [sudo] password for user1:

Install Xampp in Ubuntu

Install Xampp in Ubuntu: Step1 : Open Terminal Before installing the package, create a directory. user1@user1:~$ mkdir xampp user1@user1:~$ cd xampp/ user1@user1:~/xampp$  * it creates a folder in HOME Step2 : wget https://sourceforge.net/projects/xampp/files/XAMPP%20Linux/5.6.23/xampp-linux-5.6.23-0-installer.run chmod +x xampp-linux-5.6.23-0-installer.run sudo ./ xampp-linux-5.6.23-0-installer.run https://bitnami.com/stack/xampp?utm_source=bitnami&utm_medium=installer&utm_campaign=XAMPP%2BInstaller http://localhost/dashboard/ Check Xampp Status: sudo /opt/lampp/lampp status Run Xampp with Control Panel window: sudo /opt/lampp/manager-linux.run Run Xampp: sudo /opt/lampp/manager-linux.run Stop Xampp: sudo /opt/lampp/lampp stop You can create the backup by calling: sudo /opt/lampp/lampp backup

Install NetBeans in Ubuntu

Install NetBeans: chmod +x netbeans- 8.1 -linux.sh Now to execute it run from its directory sudo sh netbeans- 8.1 -linux.sh

DBMS FAQ's

DBMS FAQ's 1. What is database?  A database is a logically coherent collection of data with some inherent meaning, representing some aspect of real world and which is designed, built and populated with data for a specific purpose. 2. What is DBMS?  It is a collection of programs that enables user to create and maintain a database. In other words it is general-purpose software that provides the users with the processes of defining, constructing and manipulating the database for various applications. 3. What is a Database system?  The database and DBMS software together is called as Database system. 4. Advantages of DBMS?  Redundancy is controlled. Unauthorized access is restricted. Providing multiple user interfaces. Enforcing integrity constraints. Providing backup and recovery. 5. Disadvantage in File Processing System?  Data redundancy & inconsistency. Difficult in accessing data. Data isolation. Data integrity. Concurrent access i...