Posts by Sampaio Leal • 544 points
35 posts
-
2
votes1
answer111
viewsQ: Efficient method to lower array order in PHP
I’m developing a determinant calculator in PHP In the Matrix class I created some functions, among them the function Calc(order, matrix). This function calls another to lower the array order to…
-
2
votes1
answer2121
viewsQ: How to take variable value within a Function in one Class to another Function?
I have a class for Image Upload, and I want to get the value of a variable within a function calling for salvar()! I want to create a function called getNome() to get the name of the image with…
-
0
votes2
answers449
viewsA: Ajax with multidimensional JSON type feedback
To transform JSON into Array, you need to indicate the true within the json_decode Thus remaining: $myARRAY = json_decode($obj, true); And to get the data in PHP just try:…
-
2
votes1
answer440
viewsQ: How to convert special characters?
I have a search system, but it doesn’t respond very well with special characters, like: ç, ã, á, ô, etc.. So I want us to input the user type for example: "Union" and GET['nome'] come out kind of…
phpasked Sampaio Leal 544 -
1
votes1
answer205
viewsQ: I can’t capture JSON data!
Guys, I got one json here, and I used the CURL to catch him! Then I gave a json_decode, only, I’ve tried everything to get the data, but nothing works. What may be happening? I tried to get only the…
-
1
votes1
answer2925
viewsQ: How to leave DIV "Responsive"?
I know almost nothing of the, diagmos, "Advanced" of the CSS! So I wanted to know how to leave one div well Responsive for users MOBILE. So here’s the deal: I’ve got divs with some footage, and some…
-
1
votes3
answers221
viewsA: Redirect page if resolution less than 767px
Maybe this will work: $(document).ready( function() { var height = window.screen.availHeight; var width = window.screen.availWidth; $("#resolution").html("Height: " + height + "," + " Width: " +…
javascriptanswered Sampaio Leal 544 -
0
votes1
answer464
viewsQ: How to activate a navigation item dynamically
I’m tired of always changing the navbar of all my pages, and I decided to create a file for navbar and always give a include on the pages to make it easier to add/remove items! Only, my question is…
-
-1
votes1
answer146
viewsQ: Site with Responsive objects!
I’m developing a website in BootStrap! He’s doing very well in a matter of being Responsivo. Only, Background is working as planned only on PC’s, we already smartphones He’s even cool, but by…
-
0
votes1
answer141
viewsA: By clicking a button, I want my box to open with a transition
I added the function fadeIn() and fadeOut() $(document).ready(function(){ $(".box2").click(function(){ $(".menusec").fadeIn("slow"); }); $(".fechar").click(function(){ $(".menusec").fadeOut("slow");…
-
0
votes3
answers463
viewsA: How to organize quotation marks of HTML and PHP content inside echo?
Always when you put HTML within a echo, Remember to organize the quotes! If you open an echo with double quotes " the attributes of HTML should be opened with single quotation marks ', and so on.…
-
1
votes1
answer33
viewsA: Problems with Javascript
Try this, now, you could use database to save the Likes! Or a system with files! var like = $("#likes").text(); $("#addLike").click( function() { $("#likes").text(like++); }); <script…
-
0
votes2
answers2984
viewsQ: How to download multiple files using wget?
Guys, I need to download all images from a folder on a server! I mean, there’s a website www.tarararara.com/images And there are 50 images! How do I download these images and put them in a folder of…
-
0
votes2
answers173
viewsA: Enable Select Field with Javascript
$(document).ready( function() { $("#payment").change( function() { var value = $("#payment").val(); if (value == "") { $(".campo").removeAttr("disabled"); } else { $(".campo").attr("disabled",…
javascriptanswered Sampaio Leal 544 -
3
votes3
answers276
viewsA: I cannot close div using IDE jquery
I edited your code a little bit and added a fadeOut at the event click class .fechar $(document).ready(function() { $('.showSingle').click(function(){ $('.targetDiv').hide();…
-
0
votes1
answer62
viewsA: Problems with ajax form
You are submitting the form even without Ajax, because you set the method attribute as POST, and the action! Try to remove these attributes from your form and see if it works, if it doesn’t work,…
-
3
votes1
answer449
viewsA: Get the value of the variable url for iframe
Just use the method GET: $url = $_GET['url']; And in the iframe place: <iframe src="<?php echo $url; ?>" width="100%" height="100%" scrolling="no" frameborder="0"…
-
3
votes1
answer1223
viewsA: How do I stop when I click one button appear another below
Dude you have to use Javascript. Follows in functional example with jQuery: $(document).ready (function() { $("#button1").click( function() { $("#button2").fadeIn("slow"); }); }); <script…
htmlanswered Sampaio Leal 544 -
1
votes1
answer50
viewsA: UPLOAD - NO ACCESS TO FILES
You have to change the permissions of the folder where you are storing the images! If you are using Linux, I no longer know the procedure in graphic mode, because I haven’t used it in a few months!…
phpanswered Sampaio Leal 544 -
1
votes2
answers1652
viewsA: Insert "div" html element with javascript
You can use the method load(), to upload the file, in this file the Divs could have the tag hidden='true' Right after you upload the file, just take the id of the loaded div, and give a show(), or…
-
0
votes2
answers60
viewsA: Insert Rows at the top of the table
No need to do this, just select the last records from the table using SELECT * FROM dados_rec ORDER BY id DESC
-
0
votes2
answers124
viewsA: How to know if a record has been made in the database?
First select the ID you want to register and turn it into a variable. Then create a query, and then check the results: SELECT id FROM suaTabela WHERE id=$id if ($con->num_rows == 1) { //código…
-
1
votes2
answers624
viewsA: Submit form using modal bootstrap
Add an id to the Modal tag, after, just grab the element by the id and add the onclick function, for example: $("#atualizar").click(function() { alert ('Testando o clique no botão atualizar'); });…
-
0
votes2
answers374
viewsA: Ajax function is not working in Wordpress
Ah, I’ll make a copy of your code using the basic functions of Jquery, you could test and see if it makes a difference: $('#enviarform').click(function(){ var nome = $('#nome').val(); var email =…
-
1
votes2
answers1148
viewsA: How to read what the user typed in a form?
If you want to pick up what the user typed in pagina.php, just use PHP’s GET or POST methods! As you declared the POST method in the form, just call the function $_POST[''] in pagina.php. You can…
-
2
votes1
answer938
viewsQ: Logged in user information does not appear using Firebase!
I’m developing a web-app! In this case, a chat, however, a chat with new and cool functions! I’m doing it just for learning and fun! In the app, I’m using Firebase, to create Logins, Notifications…
-
0
votes1
answer338
viewsQ: What can you do with Google Firebase?
I met Firebase some time ago, but I could never do anything, I would like to know what I can use, do, create etc using the Apis, etc. Note: No Mobile app, only Web!
-
1
votes2
answers1304
viewsA: Alert bootstrap in ajax call
You can try to do the following: Create image delete function! In AJAX, you don’t need to re-load (try to do it without Reload)! Within the .success or .done try to make Alert appear using the…
-
0
votes3
answers224
viewsA: Take all content from a div and write at the beginning of a file
If that’s what I’m thinking according to your words, you can try creating a form with a textarea, and the editor will put the text there! And by clicking the Preview button (for example), you can…
-
0
votes2
answers56
viewsA: Bug Tin console Google Chrome
You may be pointing to some external source of a blocked Hostinger link! Try to access the site that is trying to connect to the hotlink and see if there is something wrong! This link, usually…
-
3
votes2
answers3456
viewsQ: How to create Android apps on weak PC?
I have a notebook with a 1.3Ghz processor and 4 GB of RAM. It is good, but whenever I try to create an app for Android I come across lag, slowness, brakes, etc... I have in my notebook Android…
-
0
votes3
answers131
viewsA: Why am I only getting the first word from the database field?
Why you mix Mysqli methods, I recommend using Object Oriented mode, in case your code would look like this: <?php include('conecta.php'); $conn = new mysqli($servername, $username, $password,…
phpanswered Sampaio Leal 544 -
1
votes1
answer2051
viewsA: How to put auto increment in php myadmin
In the creation of a table and its structure, you have an option called A_I which is Auto Increment, then you arrow the column as primary etc!
-
1
votes2
answers680
viewsA: Command adb open youtube URL via Browser
I believe the only way is to disable the links. In case just search for "Defaults" in the settings of the device and disable the Youtube, so each time you request a link Youtube, the device will ask…
-
0
votes3
answers85
viewsA: Ajax code is not working
Hello, dude do so, put $(Document).ready... at the beginning of the script, and dps create the function only with ajax! <script> $(document).ready(function(){ $("#myAjax").click(function(){…