Blog Archives

5 * 5 matrix with column multiplied by row in php


OutPut: 1 2 3 4 5 2 4 6 8 10 3 6 9 12 15 4 8 12 16 20 5 10 15 20 25 Code: <?php // Your code here! for($i=1;$i<=5;$i++){ echo $i;// $i as row for($j=1;$j<5;$j++){ //

Tagged with: , ,
Posted in matrix php, php, php interview question

add and call anonymous function in class php


Adding anonymous function and call the public variable in an anonymous function by using magic function called __invoke();   <?php // Your code here! class model { public $greet; public $a =”hello”; function __construct() { $this->greet = function(){ echo $this->a;

Tagged with: , , , ,
Posted in php

Add table string inside html php variable


We can use strrpos function to find the position of the string and use substr function to insert the particular string in particular position. <?php $html = "\html/Please Click Here to Complete Questionnaire/html/" $str_to_insert = "pramodh"; $pos = strrpos($html,"Please Click

Tagged with: , , , , , , ,
Posted in Practice Makes a beginner to become php programmer expert(practical task to become php programmer)

How to validate sunday date or skip sunday date in php


Hi Friends I was working on yii2 framework project in which i as working on delivery date in which it should skip shipping or delivery date on sunday as saturday is also working day,so i came up with idea to

Tagged with: , , , , , , , ,
Posted in php

yii2 generate pdf and attach in mail using kartik-v


Hi friends While i was working with yii2 advanced project for my client,so i was intergrating the kartik-v mailer and pdf package.so while working on ecommerce for triggering mail on order place for customer and support,i came up with solution

Tagged with: , , , , , , , , , ,
Posted in yii2
Follow Tutorial on WordPress.com
categories
Calendar
May 2024
M T W T F S S
 12345
6789101112
13141516171819
20212223242526
2728293031  
Follow me on Twitter
Blog Stats
  • 88,191 hits