Asynchronous Apex
Asynchronous Apex in Salesforce allows developers to execute operations in a separate thread, enabling tasks to run in the background without impacting the user experience. This approach is particularly beneficial for handling long-running processes, callouts to external systems, and operations
Adding custom merge tags to the Gravity forms
Merge Tags in gravity forms are the tags that are used to dynamically populate the field values in the form content in gravity forms like IP address, browser name, logged in user name etc . There are many merge tags
WordPress | How to retrieve query variables in plugins
Suppose the URL contains query string for example www.mywebsite.com/sme_page?q=12 then the value of query variable can be retrieved in PHP using the get method such as: <?php echo $_GET[‘q’]; ?> While creating a plugin for WordPress, to retrieve a
Postgresql | Querying over local and remote database together
You can create a dblink to a remote database in postgresql and query both local and remote together. Steps and an example below: 1. Enable dblink in postgresql CREATE EXTENSION dblink; 2. Create connection with database server SELECT dblink_connect(‘dbname=abc port=1234
Jquery | Perform dynamic operation on load of Datatable
Functionality needed : Once the datatable is completely loaded using ajax, I want to show second column only if role of the logged-in user is admin, else hide it. What we need to do is, call API “initComplete” in datatable’s
How to add multiple modules and controllers in angularjs
If we have multiple modules and controller in single page i.e. : <div id=”id1” ng-app=”App1″ ng-controller=”productController”> </div> <div id=”id2” ng-app=”app2″ ng-controller=”orderController”> </div> We need to add angular.bootstrap after adding the controllers: var App1 = angular.module(App1, []); mySampleApp.controller(productController, function($scope) {}); var
Java | Method overriding and exceptions
Problem: Suppose you have a method M1 in class A that throws exception E1 and you override this method in class B (B extends A). Are there any rules about exceptions when methods are overridden? Solution: There are following rules
Salesforce | ALL ROWS
How to get all records of sfobject including records in recycle bin of salesforce and undelete the records? List objlst = [select id,isdeleted from sfobject ALL ROWS]; //Just add ALL ROWS at the end of SOQL, it retrieves all the
ASP .NET | InvalidOperationException: An asynchronous module or handler completed while an asynchronous operation was still pending
[InvalidOperationException: An asynchronous module or handler completed while an asynchronous operation was still pending] Error : Asp.net Web API – parent method executes itself before the child asynchronous method is completed. Description : I have a public method that calls
CakePHP 3.x | How to change URL of your website to hide controller/action name
Requirement: While running the website in browser, the url path shows controller name followed by the action name and parameters list. In that case the url looks like: www.xyz.com/User/showDetails/ We may come across two types of requirements. Displaying only the