Categories
Development

Required firewall exceptions for accessing Node apps on a LAN

I would like a Express REST API to be accessible over a LAN. From what I understand I will need to make some changes in my firewall to allow this access. I managed to solve this checking the second and last mention of Node.js: Server-side Javascript in Windows Defender. Looking at the supplied image I […]

Categories
Development

What is MigrationProxy in rails?

Brief explanation of ActiveRecord MigrationProxy in rails migration? When it will be used in rails application? What is the use of Migration Proxy?

Categories
Development

how did we get the output of the code below?

namespace ConsoleApp1 { class Program { static void Main(string[] args) { int i, j; int[,] M = new int[5, 5]; for (i = 0; i < 4; ++i) { for (j = 0; j < 4; ++j) { if (i < j) { M[i, j] = i % j; } else { M[i, j] = […]

Categories
Development

How can I update a column which follows one-many relationship?

Currently, I have been working on Human Resource Management System. The problem right now I am facing is to store employee qualifications. An employee might have one or many qualifications. To store their qualifications I have created a table CREATE TABLE `QUALIFICATIONS` ( `QEMPNO` INT(4) NOT NULL, `SKILL` varchar(255)); ALTER TABLE `QUALIFICATIONS` ADD CONSTRAINT `QUALIFICATIONS_fk0` […]

Categories
Development

Why does this problem happens? #include vector [closed]

I’m currently using CodeLite to learn about C++ while I was using #include <vector> but it does not work at all. My code was #include <iostream>\ #include <vector> using namespace std; int main(){ vector <char> vowels {‘a’, ‘e’,’i’,’o’,’u’}; cout << vowels[0] <<endl; cout << vowels[4] <<endl; return 0; } and this kind of error popped […]

Categories
Development

Fscanf and fprintf in C

I have and issue with scanfing strings. E.g. Input John: john123. Mao: Mao 456 First word is name of user and password comes after semicolon. while(fscanf(fin, “%20[^:], %20[^\n]”, ime, pass)==2) fprintf(fout, “%s %s\n”, ime, pass); I should store it and printf it but it only comes to first semicolon. Output should be: John john123 Mao […]

Categories
Development

target=“_blank” is not working in chrome?

I try to show base64 source image when click this text. But it not working in chrome. tag open new tab. But href not in url. Like this image My Html Code : <div> <p>Taken from wikpedia</p> <a href=”data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAAUA AAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO 9TXL0Y4OHwAAAABJRU5ErkJggg==” target=”_blank”>Please Click here</a> </div> How to resolve that issue?

Categories
Development

target=“_blank” is not working in chrome?

I try to show base64 source image when click this text. But it not working in chrome. tag open new tab. But href not in url. Like this image My Html Code : <div> <p>Taken from wikpedia</p> <a href=”data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAAUA AAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO 9TXL0Y4OHwAAAABJRU5ErkJggg==” target=”_blank”>Please Click here</a> </div> How to resolve that issue?

Categories
Development Linux

NAT and complex bridge configurations

I have a complex bridging configuration, which looks like this: There is a default route via 172.31.0.1 dev eth0_bridge. Now I’m trying to set up masquerading between lan_bridge and eth0_bridge so that other devices can connect to eth1, get an address from the DHCP server and then access the internet via the default route through […]

Categories
Development Linux

Does Ansible check relative vars files when using -m with a global inventory?

I created a file, ./group_vars/all which has a simple line — ansible_user: centos My inventory filemy /etc/ansible/inventory has [centos] 10.1.38.15 However, when I use ansible -m ping I see that it’s trying to connect with my regular user. ~/cp/ansible$ ansible -vvv centos -m ping …. stuff “msg”: “Failed to connect to the host via ssh: […]