<a href="#" onclick="MyWindow=window.open('https://www.aspsnippets.com/Articles/660/Display-image-from-database-in-Image-control-without-using-Generic-Handler-in-ASPNet/','MyWindow','width=600,height=300'); ">click to open new window</a>
Friday, August 15, 2025
Thursday, August 14, 2025
Thursday, June 5, 2025
How to see or view a base 64 image file or image file in HTML page and how to see image file base 64 with URL - How to view image in html page - View image in chrome - view photo in chrome
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABkAAAAOECAYAAAD5Tf2iAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAP+lSURBVHhe7N0LYFTVuTb+B1AkeIGEm0CABBAiglyD3CINoqJoKRSRNqWtSEUK51NrgVKPHD48LYLHqt8fSvEgtlJaRAqlFouKIAUBCYIXREAggVwAA0lQgQgK//2uvfbMnvueaybx+dld9m1m1r5OZr17rbdOt249LoGIiIiIiIiIiIiIiKgWqav/JSIiIiIiIiIiIiIiqjUYACEiIiIiIiIiIiIiolqHARAiIiIiIiIiIiIiIqp1GAAhIiIiIiIiIiIiIqJahwEQIiIiIiIiIiIiIiKqdep069bjkh4nIiIiIiIiIiKq1erXv0KPEVFtdf78V3qMvu3YAoSIiIiIiIiIiIiIiGodBkCIiIiIiIiIiIiIiKjWqdeixbWz9Hi1qFevHn7zmydwyy1DUFVVhaKiIr2EiIiIiIiIiIgoturVu0yP
Tuesday, April 23, 2024
HTML colsapn and rowspan in table header - table with multiple headers
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<table style="width:100%">
<tr>
<th rowspan="3">SL.No.</th>
<th rowspan="3">ZONE</th>
<th rowspan="3">BRANCH (Cummulative MPR)</th>
Friday, April 12, 2024
How to get the value of dropdown multiselect and shown into label HTML and Javascript
<select id="ddlBranch" multiple="multiple" class="form-select form-select-sm form-control"></select>
var BrList = [];
$.each($("#ddlBranch option:selected"), function () {
BrList.push($(this).text());
});
$("#lblBranch").text(BrList.join(","));
How to set value of label in HTML and Jquery and how to get value of textbox html
Set Value of label
<label id="lblZone" class="fst-italic fw-medium text-danger">test</label>
$("#lblZone").text('Test');
get value from textbox
<input class="form-control datepickerIcon" id="dateFrom" type="text" />
$('#lblFromDate').text($('#dateFrom').val());
How to create dropdown with multi select in HTML and javascript and JQuery
<select id="ddlZone" multiple="multiple" class="form-select form-select-sm form-control"></select>
$(document).ready(function () {
$('#ddlZone').multiselect({
includeSelectAllOption: true,
enableFiltering: true,
maxHeight: 600,
//dropUp: true,
buttonWidth: '250px',
enableCaseInsensitiveFiltering: true,
onDropdownHidden: function (event) {
ddlZone_onClientDropDownClosed();
//GetDashBoardSummary();
},
templates: {
button: '<button type="button" class="form-select multiselect dropdown-toggle btn-sm" data-bs-toggle="dropdown" aria-expanded="false" style=" border: 1px solid #dee2e6; border-radius: 15px;"><span class="multiselect-selected-text"></span></button>',
},
});
});
Saturday, March 9, 2024
Javascript window Print - Like a4 sheet - how to print div with page break - table print in a4 sheet
Also use table with following code:--
<table id="tblMain" style="width: 98%">
<tr>
<td style="width: 920px;height: 909px;">
<table style="page-break-after:always;border-collapse:collapse; clear: both; width: 770px; height: 800px" border="1">
</td>
</tr>
<tr>
<td></td> <br/></tr>
<tr>
<td></td> <br/></tr>
<tr>
<td style="width: 920px;">
<table style="page-break-after:always;border-collapse:collapse; clear: both; width: 595px; height: 875px" border="1">
</td>
</tr>
</dt>
and use window.print();
=========================================== or ===========
Telerik.Web.UI.Editor.CommandList["Print"] = function (commandName, editor, args) {
var prtContent = editor.get_contentArea();
var WinPrint = window.open('', '', 'left=0,top=0,width=800,height=900,toolbar=0,scrollbars=0,status=0');
WinPrint.document.write(prtContent.innerHTML);
WinPrint.document.close();
WinPrint.focus();
WinPrint.print();
setTimeout(function () {
WinPrint.close();
}, 1000);
};
Tuesday, February 20, 2024
Disable cursor in ASP.NET controls and set cursor to pointer in anchor tag
style "cursor", "not-allowed"
style="cursor: pointer"
Thursday, November 9, 2023
How to remove underline from link - a href
Use style
text-decoration: none;
<a onclick="OpenManageJavaModal();" href="javascript:void(0);" style=" text-decoration: none;">Download Java Setup
</a>
How to download a file from a href without opening it - Direct Downloading
Use download attribute on a href
<a title="Digital Signature User Manual" href="Download/DigitalSignature/Signer-UserManual.pdf" style=" text-decoration: none;" download>Download User Manual for Digital Signature
</a>
Wednesday, September 28, 2022
Redirect to different page in ASP.NET C# - meta - or in HTML we can do
HtmlMeta meta = new HtmlMeta();
meta.HttpEquiv = "Refresh";
meta.Content = "2;url=StudentList.aspx";
this.Page.Controls.Add(meta);
---------------------
redirecting of page from one to another with meta
protected void btn_cancel_Click(object sender, EventArgs e)
{
#region redirectbtmeta
HtmlMeta meta = new HtmlMeta();
meta.HttpEquiv = "Refresh";
meta.Content = "1;url=StudentList.aspx";
this.Page.Controls.Add(meta);
#endregion
}
---------------------- In html we can do
<!DOCTYPE html>
<html>
<head>
<title>HTML Meta Tag</title>
<meta http-equiv = "refresh" content = "2; url = https://kapooryash.blogspot.com" />
</head>
<body>
<p>Hello HTML5!</p>
</body>
</html>
ref:- https://www.tutorialspoint.com/How-to-automatically-redirect-your-visitors-to-your-new-home-page
Friday, July 29, 2022
Form HTML Page - Copy website disable - paste disable in website -Cut disable - Logout waiting (Loading....)
<script type="text/javascript">
function burstCache() {
if (!navigator.onLine) {
document.body.innerHTML = "Loading....";
window.location = "../Logout.aspx";
}
}
</script>
<body onload="burstCache()">
<form id="form1" runat="server" method="post" autocomplete="off" oncopy="return false;"
onpaste="return false;" oncut="return false;" ondragstart="return false;" onselectstart="return false;">
<div>
</div>
<form>
<body>
Monday, June 13, 2022
Simple static download of excel file address in C# ASP.NET
<label>Process for Bulkupload </label>
<a href="../../../Student Registration – Bulk Data Upload Process_Final.docx" class="label label-default">Click Here</a>
<label>Download Excel File </label>
<a href="../../../Template for Bulk Upload V2.xlsx" class="label label-danger">Click Here</a>