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
Salesforce | How to add page header image in a visualforce page?
We can add the page header image in a visualforce page using following apex tag: <apex:image id=”” value=”” width=”” height=””/> In “value” Field of tag we give the url of the image where image is located. Image may be located
Page break in PDF not working when table is created in loop
Problem: Page break in PDF was not working when table was created in loop. We wanted to have certain amount of rows on same page. If there was not enough space then next set of rows automatically shifted to the
Moodle | Flash SCORM modules not showing content on shared hosting
We faced a problem that Scorm content packages uploaded in Moodle were not displaying content correctly on shared hosting server. After entering the Quiz the page was redirecting back to the same page rather than displaying the further pages of
Moodle | Assign users as site administrators in Moodle/Totara
In Moodle, we can allow users to have administrative access to site. We can enable users for this access by using the following steps: 1. Navigate to Site Administration > Users > Permissions. 2. Click on the Site administrators link.
WordPress accessing custom fields in code
In WordPress you can use following code for accessing value of custom fields: $key_name = get_post_custom_values($key = ‘Key Name’); echo $key_name;//display the value Here ‘key name’ is name of the custom field. get_post_custom_values() is a function in WordPress, which is
Selenium | Unable to find Command button using Selenium Webdriver
Problem: Unable to find the Command button using Selenium Webdriver. Solution: You can use following script code if you want to find command button on a web page and then click it: driver.findElement(By.xpath(“//button[text()='(Button name)’]”)).click(); Here is the script which we used in
Download the PDF in Landscape mode using MPDF
While downloading the PDF from standard portrait mode to landscape mode, first of all you need to set the style in % (no hard coding of width or height). Then make an object of mpdf class. This is how we
Chargify | Single php function for all Chargify API calls
Following single function can be used for all Chargify API calls whether API calls belong to test site (site for test transactions) or live site (live transactions): <?php function sendRequest($uri, $method, $data = ”) { $apiKey = ‘XOTUsyy7pJ6yLgmMa233AtJ’; $subdomain =
Java | How to Create Entities from existing database in eclipse (ubuntu)
Follow steps below to generate JPA Entity classes automatically in Eclipse: Step 1: Create a simple java project and convert it to JPA Project using following steps: 1.1. Right Click on your Project. 1.2. Select Configure option from the menu.