Questions tagged as 'javascript'

1
answer

Put EJS files in the Service Worker cache

I would like to know how I can cache the% .EJS files because they are not rendered by the browser, but by the server and only after sending the corresponding .HTML to the browser. self.addEventListener('install', function(event) { event.w...
asked by 16.01.2018 / 15:10
1
answer

How to import an existing project with angular-cli

Hello, I downloaded an angled 4 project with css bootstrap, I would now like to work on this project, making some changes for study effect. It turns out that I do not know how to make an amount of this already existing project to run it with the...
asked by 16.01.2018 / 16:43
1
answer

Javascript for validation

I'm using javascript to validate some form fields like phone and CPF. The script works correctly the way I want, the problem is that when the user does not type all mask numbers the script does not clean the input, it accepts that number of numb...
asked by 17.01.2018 / 01:20
1
answer

Display result of a Javascript function in a modal

Good morning! I have a function that scans a JSON file for search information compatible with the search that will be performed. Work normally. But what I want is to display the result of this search in a modal. I can normally display in a...
asked by 17.01.2018 / 14:23
2
answers

Get text inside input with radiobutton input-group-addon

I have this form with these inputs, I want to get the value that is inside the input of the selected radio button, example as in the image, I should get "bb". Myhtml:<label>Respostas:</label><divclass="input-group">...
asked by 17.01.2018 / 14:49
1
answer

Mount check box with 1 and 0 angular values

I have a screen that has a check box .. let's see; <div class="form-group col-md-9 pull-right"> <label>Ativo:</label> <label class="checkbox-inline"><input type="checkbox" ng-model="pess...
asked by 17.01.2018 / 00:49
1
answer

Discount on a form item after choosing a combo option

I have a form in PHP, where I would like to create a discount rule for an item, in this case the soup. The soup on the online menu (form) costs $ 15.50 but if the client selects one of the combos (4 combos) the Soup will cost $ 9.90. The form...
asked by 17.01.2018 / 17:41
1
answer

Insert ajax return into table

I have a view with a table that has multiple dynamically generated lines. Clicking on the change button opens a modal that I place a value and by ajax I update this value. I need to get this value that ajax is returning and put in td with...
asked by 09.01.2018 / 15:54
1
answer

How can I create an unavailable urls filter? (javascript)

Hello, I wanted to know how I can filter certain subdomains that would mimic the brand of my company eg in a free hosting the user types a subdomain to the address of their site. if he types a subdomain as just the word " blog " or " forum ", "...
asked by 09.01.2018 / 04:54
1
answer

Check changes to the database correctly

I need to check changes in my database and I created a script that sends requests every millisecond by calling a function that returns the number of rows in that database, but I realized that it is a very wrong way to do this because it leaves m...
asked by 09.01.2018 / 21:01