Posts by VMCO • 162 points
17 posts
-
0
votes0
answers18
viewsQ: Nodejs - initialize variables and they are available throughout the project
I’m having the following difficulty: I have the following design structure: my server.js is the start of the project. However, within the services, models, etc I have some libs, as an example log…
-
0
votes1
answer757
viewsA: PHP: user location map via geolocation IP
If you already have the country that the user is you can do in several ways, among them: 1 - use Google Maps API and use the heat map…
-
1
votes1
answer556
viewsA: Create JSON from Select from the database
Hello. Use the state as the array key. $resultado = $this->sql->select("SELECT * FROM tb_unidades"); $estados = array(); foreach ($resultado as $row) {…
-
1
votes2
answers1539
viewsQ: Mysql Query with recursive N levels
I have the following query select id, nome, user_id from (select * from users order by user_id, id) users, (select @pv := '2') initialisation where find_in_set(user_id, @pv) > 0 and @pv :=…
-
0
votes3
answers1320
viewsA: save IMG from external site
you can also use the function copy() php bool copy ( string $source , string $dest [, resource $context ] ) basically will use the first 2 parameters source: Path to source file. dest: The…
-
1
votes2
answers868
viewsQ: Google Maps Latitude Longitude does not find address, but exists on Google Maps
I am using the search tool of the Post Office Post Office. As an example: I am looking for the zip code: 04291-020 the return is: Rua Muller Carioba. Note that there are 2 letters L in the name.…
-
0
votes0
answers1096
views -
0
votes0
answers111
viewsQ: Ionic-datepicker - How to render after $http?
Good afternoon. Next...I don’t know for sure if my doubt is about Ionic or about Angularjs. I am implementing the code below $scope.datepickerObject = { titleLabel: 'Escolha a Data', //Optional…
-
2
votes3
answers1909
viewsA: Capture Input ID
$("input[name=adicional]").attr("id") if you have multiple checkboxes $("input[name=adicional]").each(function(){ //var ou array $(this).attr("id"); });…
-
1
votes1
answer33
viewsA: Generic styleClass in table
if the "header" is a <th> you can put in your style like this: table th { ... }
-
1
votes1
answer332
viewsA: Why does a script work within HTML and not in JS?
Remember to put your.js file after jquery. Put this code also inside $(document).ready(function(){ })
-
0
votes2
answers1678
viewsA: PHP and Javascript - Show alert without updating page
You can do what Moykn suggested or change the type='submit' for type='button' The only difference is that replacing Submit with a button in your PHP code will no longer work:…
-
-2
votes1
answer1006
viewsA: Update div in real time with php /javascript without updating page
PHP is Server Side and Javascript is Client Side. No way to run php 'on the fly script'. You need to run an Ajax when you want that CURL to run. See if that helps you: $("button").click(function(){…
-
0
votes1
answer141
viewsA: Sending from Session to email
If you want to send only the entire contents of your SESSION by email, you can do the following: print_r($_SESSION, true) Now, if you want to send an HTML message, do a foreach in your SESSION and…
-
0
votes1
answer55
viewsA: Array with HTML and Jquery
Remember that ID is unique per element. Quick and easy suggestion: Create a <form> with any ID and put these inputs inside this <form>. After that, in your JS function do the following:…
-
1
votes3
answers913
viewsA: Checkbox Fields From Database
Okay... I believe the simplest way for you to resolve this issue is: 1 - create a query to list all registered accessories 2 - create a query to recover all the accessories that the XPTO vehicle…
-
5
votes1
answer134
viewsA: How to send a kind of form without boot?
1 - set for example an ID to your form 2 - Use javascript $(".classeDoRadio").click(function(){ $("#idDoForm").submit(); });