Skip to main content

Posts

MySql Trigger set

Free Teachnology provide free #PHP,#MySql,#Javascript,#jQuery,#API integration,#Payment gateway integration,#Social Media login In this section, you will learn how to work with the MySQL triggers. By definition, a trigger or database trigger is a stored program executed automatically to respond to a specific event e.g.,  insert, update or delete occurred in a table. The MySQL trigger is a database object that is associated with a table. It will be activated when a defined action is executed for the table. The trigger can be executed when you run one of the following MySQL statements on the table: INSERT, UPDATE and DELETE and it can be invoked before or after the event. Uses for triggers: Enforce business rules Validate input data Generate a unique value for a newly-inserted row in a different file. Write to other files for audit trail purposes Query from other files for cross-referencing purposes Following table of create trigger : 1-Create table : when create ...

FCM Notification in android and IOS App

Free Teachnology provide free #PHP,#MySql,#Javascript,#jQuery,#API integration,#Payment gateway integration,#Social Media login Firebase Cloud Messaging Firebase Cloud Messaging (FCM) is a cross-platform messaging solution that lets you reliably deliver messages at no cost. Using FCM, you can notify a client app that new email or other data is available to sync. You can send notification messages to drive user re-engagement and retention. For use cases such as instant messaging, a message can transfer a payload of up to 4KB to a client app IOS Setup link : https://firebase.google.com/docs/cloud-messaging/ios/client Andriod Link : https://firebase.google.com/docs/cloud-messaging/android/client Web Link : https://firebase.google.com/docs/cloud-messaging/js/client How does it work? Firebase Cloud Messaging architecture diagram An FCM implementation includes two main components for sending and receiving: A trusted environment such as Cloud Functions for Firebase ...

Boostrap Datepickter start date and end date range set

Free Teachnology provide free #PHP,#MySql,#Javascript,#jQuery,#API integration,#Payment gateway integration,#Social Media login Originally created for reports at Improvely, the Date Range Picker can be attached to any webpage element to pop up two calendars for selecting dates, times, or predefined ranges like "Last 30 Days". Getting Started To get started, include jQuery, Moment.js and Date Range Picker's files in your webpage: <script type="text/javascript" src="https://cdn.jsdelivr.net/jquery/latest/jquery.min.js"></script> <script type="text/javascript" src="https://cdn.jsdelivr.net/momentjs/latest/moment.min.js"></script> <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepicker.min.js"></script> <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/daterangepicker/daterangepi...

Create notification,store and retrive a particular user.

Notification Data table is: as per user defined functionality , user want notification as per particular any user send. if you want particular notification please follow following database structure : Normally we can use following data table structure INNODB database use because mostly common used that, its very fast loading and primary and forgen key assign. Free Teachnology provide free php tutorial as well as MySql,javascript,jquery knowlege : above image show that basic notification table structure pk_id is primary key of notification table , fk_uid is forgin key of user table of particular user primary key, Following code is create notification table : -- phpMyAdmin SQL Dump -- version 4.5.2 -- http://www.phpmyadmin.net -- -- Host: localhost -- Generation Time: Jun 07, 2018 at 12:16 PM -- Server version: 10.1.13-MariaDB -- PHP Version: 5.6.20 SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO"; SET time_zone = "+00:00"; -- -- Database: `makeathome` -- -...

Find points(latitude/longitude) within a distance using MySQL

Free Teachnology provide free php,mysql,jquery,javascript, MySQL - when you calculate distance between latitude/longitude its simple way : Step : 1  create table as per your requirement and two column  latitude/longitude with data type Double Range On a client project recently, we had to make it easy to filter database query results based on the distance between a user and an entity in our database. It's easy to get overwhelmed in that context, worrying about the crazy amount of PHP calculations you're going to have to run. MySQL can do that! If you need to calculate this, you can actually get far by just using MySQL! MySQL 5.7 introduced latitude, which is a native function to calculate the distance between two points. That’s an interesting start but it doesn’t apply with Geography since the distance between lines of latitude and longitude are not an equal distance apart. As you get closer to the equator, lines of latitude get further apart. If you u...

MySQL –TIMESTAMP or DATETIME difference

MySQL - When to Use TIMESTAMP or DATETIME - Difference Between TIMESTAMP or DATETIME clocktimeimage This is a one of the most popular question, I often receive when MySQL Developers are creating a database. There are multiple datatypes which can store DateTime datatype in MySQL. Range The supported range for DATETIME type is ‘ 1000-01-01 00:00:00 ’ to ‘ 9999-12-31 23:59:59 ’. The supported range for TIMESTAMP type is ‘ 1970-01-01 00:00:01 ’ UTC to ‘ 2038-01-19 03:14:07 ’ UTC . That means if you want to store date which is before the year 1970 or after the year 2038 you will need to use DATETIME . Conversion As per the MySQL official documentation – MySQL converts TIMESTAMP values from the current time zone to UTC for storage, and back from UTC to the current time zone for retrieval. This means, if your application is such where you want time to stay absolutely steady with respect to GMT, you must use TIMESTAMP, or else you should use it with DATETIME. For example, if I am...

Profile Share Fixing the Thumbnail Image, Title and Description for Shared Links

Profile Share Fixing the Thumbnail Image, Title and Description for Shared Links user want to share any information then use following code  and read step by step Profile Share Fixing the Thumbnail Image, Title and Description for Shared Links if you want share profile on following social link : 1-Facebook 2-twitter.com 3-LinkedIn 4-google +, Code link : https://drive.google.com/open?id=1IzTZZh_0euDqFSHL_vPRiQePlNTw3h-q Demo link : http://freeteachnology.hol.es/socialshare/ To modify a page's thumbnail image, description, and additional metadata for these services, you can provide meta tags in the HTML code of the page.Implementing Open Graph Meta Tags You can implement meta tags in a number of ways. In content management systems might  be allow you to modify a page's meta tags , then use following code in meta section of your project code, <link href="bootstrap.min.css" rel="stylesheet"> <link href="bootstrap-tour.m...