Nifty Corners Cube

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Rounded corners the javascript way
Nifty Corners Cube

StackOverflow.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (13 votes cast)

Random snippets of all sorts of code, mixed with a selection of help and advice.

c# await on object method call with nullable syntax throws exception [duplicate]

16 February 2026 @ 5:17 pm

I'm trying wrap my head around this issue, I've created a sample program. myClassObj is deliberately set to null to produce this scenario. Program fails at await myClassObj?.MethodAsync() Expectation was that it will handle null scenario as it does in case of action, myActionObj?.Invoke() does not fail. Curious to know why this is ? using System; using System.Threading.Tasks; public class MyClass { public async Task MethodAsync() { await Task.Delay(1000); } } public class Program { public async static Task Main() { Console.WriteLine("Start"); Action myActionObj = null; MyClass myClassObj = null; try { myActionObj?.Invoke(); // works await myClassObj?.MethodAsync(); // doesn't work } catch (Exception e) { Console.WriteLine($"{e}"); } C

Checking if a graph is connected with Z3

16 February 2026 @ 5:15 pm

I'm trying to code a solver for the chinese postman problem using z3. I have to check two things to see if there is already a solution available: if every node has even degree if the graph is connected The first is easy, but I don't know how to check the second. I feel like I should use the Transitive closure but I don't know how to implement the function in the code. I'm assuming that every edge is undirected. from z3 import * solver = Solver() nodes = ["A", "B", "C", "D", "E", "F", "G"] numnodes = 7 edges = [ ["A", "B", 5], ["B", "C", 1], ["C", "D", 7], ["D", "A", 9], ["E", "F", 3], ["F", "G", 2], ["G", "E", 3]] degree = [0] * numnodes for x, y, z in edges: degree[nodes.index(x)] +=1 degree[nodes

Login username sometimes not inserted into MySQL file

16 February 2026 @ 5:10 pm

I have a login page and ballot. To ensure no one is voting more than once, the checked names on the ballot are stored in the database along with their login username and corresponding ID number. For most ballots cast this work just fine. However, there have been ballots cast where the votes are stored but the username is blank and the ID number is 0. Zero is not an assigned value. Following is the code for process.php, where votes are submitted. My login page sets $_SESSION['username'] and $_SESSION['user_id'] after authenticating a user, and prevents users from logging in if they have already voted. <?php require_once('../Connections/pdo-connsunnygrove.php'); ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(E_ALL); session_start(); $dbusername = $_SESSION["username"]; $userid = $_SESSION["user_id"]; $checkbox1 = $_POST['name']; $chk=""; for

How on Selenium to automate facebook/google registration

16 February 2026 @ 4:30 pm

I am developing a selenium test and I was able to create it for registration by email. However, writing a test for facebook and google login/registration is very tricky. One of the problem that they detect that it is a "bot" and show the captcha. The second problem is that their HTML structure (in the login popup) is so terrible (especialy in facebook) that it is very difficult using CSS selector to "hook" to some elements. Have anyone faced such a problem ? Maybe there is a better approach to test login/registation via google and facebook.

.NET clients cannot see Azure Service Bus messages created by node

16 February 2026 @ 3:58 pm

I have a node server that is posting messages to an Azure Service Bus topic using the rhea client. The system reading the messages is a .NET console app using the AMQP.NET Lite library. Both clients are AMQP 1.0 compliant. Here is the sample server code (node.js) sending data to the Azure Service Bus: import container from 'rhea'; const azureConfig = { address: 'my-service-bus.servicebus.windows.net', hostname: 'my-service-bus.servicebus.windows.net' user: 'RootManageSharedAccessKey', password: 'some-password', }; const connection = container.connect(azureConfig); connection.on('connection_open', () => { console.log(`Connection opened to ${azureConfig.address}`); const sender = connection.open_sender('my-topic'); sender.on('sendable', function(context) { context.sender.send(

I have error while executing npm run dev in VS Code

16 February 2026 @ 3:46 pm

I am trying to run next.js using npm run dev but I encounter following error: PS C:\Users\Shashwat\Desktop\Bookmark\smart-bookmark-app> npm run dev [email protected] dev next dev You are using Node.js 20.2.0. For Next.js, Node.js version ">=20.9.0" is required. When I check within terminal and command prompt this is my node version: PS C:\Users\Shashwat\Desktop\Bookmark\smart-bookmark-app> node -v v24.13.1 I don't know what is causing this error.

Customize kendo-editor in Angular

16 February 2026 @ 2:03 pm

I am using the Angular editor from Kendo UI in my application. When I select some text and choose an option from the Format dropdown (for example Heading or Paragraph), the style is applied to the entire line/block instead of only the highlighted text. Example If the editor contains: Revenue Growth 2024 and I highlight only Growth and choose Heading, the editor converts the whole line into a heading instead of formatting just the selected word. What I want I want the format option to behave like inline styling, meaning: only the selected text should change the rest of the line should remain unchanged What I tried Looked for a way to customize the formatting tool Tried adding custom formats Checked if the Angular edi

Memory leak happening with Python when creating numpy diagonal array and doing matrix math

15 February 2026 @ 9:45 pm

P = y.T @ (np.diag(Wc) @ y) This line is creating increased memory usage for me in the below code on my Windows 11 machine. As soon as I run the code, I see the RAM usage increasing and skyrocketing. But when I replace this line with P = y.T @ (y * Wc[:, None]) , the RAM usage is stable. However, I tested the same code on my Ubuntu 20.04 pc and it worked fine for both the alterations. I am not able to understand the strange behavior. Experts, please help. Ubuntu 20.04 no anaconda/ python venv; Python 3.10.12; Numy: 1.26.4 Windows 11 Business 10.0.26100 running anaconda environment: Python 3.13.9; Numpy: 2.4.0 import numpy as np, psutil, os, time, gc p = psutil.Process(os.getpid()) def rss_mb(): return p.memory_info().rss / 1024 / 1024 n = 3 kmax = 2*n + 1 Wc = np.random.randn(kmax) y = np.random.randn(kmax, n) print("start rss", rss_mb()) i = 0 while True: P = y.T @ (np.diag(W

How to create a member function for map?

14 February 2026 @ 10:57 pm

I have created a map like this: map<string, map<string, map<int, vector<int>>>> example; I can insert a value to this map like this: example["Stack"]["OverFlow"][3].push_back(2); Now I want to create an alias for push_back function. This code works well: #define SetValue push_back But the problem is when I put the dot operator, SetValue function is not shown in available functions list. For example, I define a vector such as vector<string> something Putting dot near to something word automatically shows push_back function. How can I achieve same effect for my own SetValue alias?

How to generate a matrix with every offset of vector without using a for loop

13 February 2026 @ 7:08 pm

For a given vector like v <- c(1,3,7,2,5), I want to create a matrix that repeats that vector with every possible offset, like this: NA NA NA NA 1 NA NA NA 1 3 NA NA 1 3 7 NA 1 3 7 2 1 3 7 2 5 3 7 2 5 NA 7 2 5 NA NA 2 5 NA NA NA 5 NA NA NA NA I could obviously do this with a for loop, but I am wondering if there’s a way to do this with a vectorized function or similar, because for loops are very slow. I was very impressed by the answers to this question, for example. As a specific example, the for-loop solution I wrote takes over 30 seconds to finish a 3000-long vector, while ideal solutions would return in a few seconds or less. For a 10,000-long vector, my for loop didn’t manage to finish after 15 minutes (at which point I gave up).

960.gs

VN:F [1.9.22_1171]
Rating: 8.0/10 (1 vote cast)

CSS Grid System layout guide
960.gs

IconPot .com

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Totally free icons

Interface.eyecon.ro

VN:F [1.9.22_1171]
Rating: 6.0/10 (1 vote cast)

Interface elements for jQuery
Interface.eyecon.ro

ThemeForest.net

VN:F [1.9.22_1171]
Rating: 7.0/10 (2 votes cast)

WordPress Themes, HTML Templates.

kuler.adobe.com

VN:F [1.9.22_1171]
Rating: 8.0/10 (1 vote cast)

color / colour themes by design

webanalyticssolutionprofiler.com

VN:F [1.9.22_1171]
Rating: 0.0/10 (0 votes cast)

Web Analytics::Free Resources from Immeria
webanalyticssolutionprofiler.com

WebAIM.org

VN:F [1.9.22_1171]
Rating: 4.0/10 (1 vote cast)

Web Accessibility In Mind

2026 Predictions: The Next Big Shifts in Web Accessibility

22 December 2025 @ 11:22 pm

I’ve lived long enough, and worked in accessibility long enough, to have honed a healthy skepticism when I hear about the Next Big Thing. I’ve seen lush website launches that look great, until I activate a screen reader. Yet, in spite of it all, accessibility does evolve, but quietly rather than dramatically. As I gaze […]

Word and PowerPoint Alt Text Roundup

31 October 2025 @ 7:14 pm

Introduction In Microsoft Word and PowerPoint, there are many types of non-text content that can be given alternative text. We tested the alternative text of everything that we could think of in Word and PowerPoint and then converted these files to PDFs using Adobe’s Acrobat PDFMaker (the Acrobat Tab on Windows), Adobe’s Create PDF cloud […]

Accessibility by Design: Preparing K–12 Schools for What’s Next

30 July 2025 @ 5:51 pm

Delivering web and digital accessibility in any environment requires strategic planning and cross-organizational commitment. While the goal (ensuring that websites and digital platforms do not present barriers to individuals with disabilities) and the standards (the Web Content Accessibility Guidelines) remain constant, implementation must be tailored to each organization’s needs and context.   For K–12 educational agencies, […]

Up and Coming ARIA 

30 May 2025 @ 6:19 pm

If you work in web accessibility, you’ve probably spent a lot of time explaining and implementing the ARIA roles and attributes that have been around for years—things like aria-label, aria-labelledby, and role="dialog". But the ARIA landscape isn’t static. In fact, recent ARIA specifications (especially ARIA 1.3) include a number of emerging and lesser-known features that […]

Global Digital Accessibility Salary Survey Results

27 February 2025 @ 8:45 pm

In December 2024 WebAIM conducted a survey to collect salary and job-related data from professionals whose job responsibilities primarily focus on making technology and digital products accessible and usable to people with disabilities. 656 responses were collected. The full survey results are now available. This survey was conducted in conjunction with the GAAD Foundation. The GAAD […]

Join the Discussion—From Your Inbox

31 January 2025 @ 9:01 pm

Which WebAIM resource had its 25th birthday on November 1, 2024? The answer is our Web Accessibility Email Discussion List! From the halcyon days when Hotmail had over 35 million users, to our modern era where Gmail has 2.5 billion users, the amount of emails in most inboxes has gone from a trickle to a […]

Using Severity Ratings to Prioritize Web Accessibility Remediation

22 November 2024 @ 6:30 pm

So, you’ve found your website’s accessibility issues using WAVE or other testing tools, and by completing manual testing using a keyboard, a screen reader, and zooming the browser window. Now what? When it comes to prioritizing web accessibility fixes, ranking the severity of each issue is an effective way to prioritize and make impactful improvements. […]

25 Accessibility Tips to Celebrate 25 Years

31 October 2024 @ 4:38 pm

As WebAIM celebrates our 25 year anniversary this month, we’ve shared 25 accessibility tips on our LinkedIn and Twitter/X social media channels. All 25 quick tips are compiled below. Tip #1: When to Use Links and Buttons Links are about navigation. Buttons are about function. To eliminate confusion for screen reader users, use a <button> […]

Celebrating WebAIM’s 25th Anniversary

30 September 2024 @ 10:25 pm

25 years ago, in October of 1999, the Web Accessibility In Mind (WebAIM) project began at Utah State University. In the years previous, Dr. Cyndi Rowland had formed a vision for how impactful the web could be on individuals with disabilities, and she learned how inaccessible web content would pose significant barriers to them. Knowing […]

Introducing NCADEMI: The National Center on Accessible Digital Educational Materials & Instruction 

30 September 2024 @ 10:25 pm

Tomorrow, October 1st, marks a significant milestone in WebAIM’s 25 year history of expanding the potential of the web for people with disabilities. In partnership with our colleagues at the Institute for Disability Research, Policy & Practice at Utah State University, we’re launching a new technical assistance center. The National Center on Accessible Digital Educational […]

CatsWhoCode.com

VN:F [1.9.22_1171]
Rating: 7.0/10 (1 vote cast)

Titbits for web designers and alike

Unable to load the feed. Please try again later.