JustAskVin Insights

Ideas for leading and building technology well.

Practical writing on delivery, architecture, CMS migrations, digital growth, and the decisions that shape strong web experiences.

Latest

Page 6 of recent writing

All insights home →

Uncategorized

WordPress permalink pagination not working

Say for example i have created a custom post type. I have implemented pagination for the same. When i call this url http://localhost.dm/news/multi-media-gallery/page/2/, it show page not found. But if i try with http://localhost.dm/news/multi-media-gallery?page=2, it work. Now to make the pagination work with permalink

Sep 11, 2020

Read article

javascript

Jquery set input value and trigger on blur event

I want to trigger an event every time i click on select on any element by id First i will try to set the input value by the following code pickedvalue = jQuery(‘#someElementId’).val(); jQuery(‘#anotherInputElement’).val(parseInt(pickedvalue)); // use parseInt if the input type is “number” else not required. After setti

Sep 10, 2020

Read article

PHP

How to show or hide yii2 gridview action button conditionally

In Yii2 Gridview normally to display the action button we have the following chunk of code $columns = [ [‘class’ => ‘yii\grid\SerialColumn’], ‘name’, ‘description:ntext’, ‘status’, [ ‘class’ => ‘yii\grid\ActionColumn’, ] ]; The output you see as below: Now you have a scenario, to show the edit button only when the “Zon

Jun 4, 2020

Read article

linux

export mysql database – mysql dump

When you have access to the command line and you have the export large database, you will not be able to export from phpmyadmin. Hence mysql provide you handy method to export the database from the command line. Below are various options, you can use while exporting the database. ——databases – This allows you to [&hell

Apr 14, 2020

Read article

linux

How to change the php version for the console

Many a times when you view the php version in the browser by displaying the phpinfo() information and the php version that is displayed when you see by typing the command “php -v” in the console or command prompt, You will notice that there is difference in the two. So how to set the php […]

Nov 18, 2019

Read article

ajax

Ajax call using jquery

function makeAjaxRequest(data1,data2,…..,datax){ $.ajax({ ‘type’:’POST’, async: false, url: ‘http://www.example.com/some_request_url’, data:{param1:data1,param2:data2,….,paramx:datax}, success : function(response) { console.log(response); // Using this you can check the posted data in browser console window return true

Sep 18, 2019

Read article

CMS

Yii2 how to set custom value for checkbox in gridview widget

In Yii2, while you use gridview widget to display your table data, for performing any operation on the record by selecting the checkbox, gridview assign the value of the first column retrieved from your the result set. But you need to set some different value to the checkbox, so to do that you can use […]

Aug 4, 2019

Read article