Posts by Estácio Di Fabio • 933 points
47 posts
-
0
votes0
answers84
viewsQ: meta tag, inserted in html fragment dynamically in body, does it work?
I have a loop loop that inserts <div>'s. Those <div>'s are content with text coming from the database and with the option to share on facebook. By the time I get these div’s I insert…
-
0
votes1
answer354
viewsQ: Use cmd commands in shell scripts - cakephp 3.0
I was wondering if you can use native windows CMD commands from scripts made to run in the cakephp shell. I already run tasks that run in cmd, but with the commands of the framework itself but would…
-
1
votes1
answer81
viewsQ: How do I know the current connection the system is using in Cakephp 3.0?
Hello, I am working with two types of connections in databases with different settings. I want to know how I can get the current connection that the page is running dynamically. Currently I use…
-
2
votes1
answer177
viewsQ: Sum data with database values. Cakephp 3.0
I need to do a calculation that sums an integer to a date. This integer refers to days. $user = TableRegistry::get('PoliticaSenha'); $query = $user->find()->where(['id' =>…
-
3
votes1
answer410
viewsQ: checkbox "select all" jquery and Cakephp
Hi, I have one foreach in a table that lists several checkboxes. I need to do a function jquery that by clicking on the checkbox of <th> selecione todos the next checkboxes <td>. Look at…
-
3
votes1
answer551
viewsQ: Block access to a system URL or folder path
Hi, I’m looking to block access to the administrative part of my site and release to only a few ips. I can do this using the .htacess well quiet but the problem is that I have the module…
-
0
votes0
answers611
viewsQ: Retrieve FOR loop variable inside a FOREACH - php
Hi, I have two loops in the structure of my code. The first is a FOR that mounts an array with data. And I have a foreach that runs through a BD data. I want to use the variable that returns in FOR…
-
2
votes1
answer56
viewsQ: Problems with . clone() to radio Buttons
I’m making an "add" button that every click adds a div com Radio Buttons below the div itself. I have trouble clicking on the radios that when I click on of some added line and click on another line…
-
1
votes0
answers43
viewsQ: Sending Newsletter to Bulk Bank Emails - No Limit Swiftmailer Email
Hi, I have an action on my controller that triggers emails from the database. I did some tests on my machine by inserting only my own e-mail into the table, put up to 1000. I only managed to receive…
-
1
votes0
answers359
viewsQ: Image cropped when comparilhar on facebook
Hi, I have a button to share on facebook the news from my site. It takes the correct image, the correct title and the correct description. But when the window appears in the news feed on facebook…
-
0
votes1
answer61
viewsQ: how to prevent sql Injection symfony 1.4 and Doctrine 1.2?
Hi, I have a 3 research inputs that query the database and return me the obtained data. With this a malicious user can bypass my system and get other information. Analyzing the behavior I use for…
-
0
votes1
answer136
viewsQ: Recover Symfony action data in Ajax
Hi, I have a button that triggers an action Ajax that leads to a action in the controlador Symfony. In the action I can do the select and see the information I want, but I just can’t get it from…
-
0
votes2
answers66
viewsA: og:image with database image - symfony php
I found the solution. I had to rewrite the addMeta() function so that the parameter name be replaced by property.
phpanswered Estácio Di Fabio 933 -
0
votes2
answers66
viewsQ: og:image with database image - symfony php
Hi, I have a news page that the user can like and share the news. Each news has its specific image. In some news, there’s a photo album. When there is the album for the news, the facebook share…
phpasked Estácio Di Fabio 933 -
2
votes2
answers622
viewsQ: Change the value of a parameter passed to a function
I have a dynamic form that I add several fields and create together a div that passes by button that is assigned an event onClick for passing a function that receives a parameter. This parameter is…
-
2
votes3
answers283
viewsQ: remove dynamic div with jQuery counter
Hi, I am generating fields dynamically using Jquery, and for each field I add at the end of id a counter. I wondered how I could do to remove the div that encompasses the button and the fields. This…
-
0
votes1
answer166
viewsQ: Move Div Up with Jquery
Hi, I have a Divs configuration on a crud and wanted to put the div I create dynamically above a UL that contains the send buttons. It is not possible to place this manually via html as the screen…
-
2
votes2
answers2561
viewsQ: Captcha reader in Portuguese - Google noCaptcha reCaptcha
Hello, I am implementing a captcha in my system, looking on google I got tutorials and got by the captcha of google that is very mass and already comes with a spoken option to answer the captcha…
-
1
votes1
answer255
viewsQ: Select Distinct in Doctrine and Symfony
Hi, I have a photo album creation table. My code makes 1 Insert for each image added in the photo album. I have a grid for displaying Albums for the user to view. I want to make a distinct of…
-
1
votes0
answers40
viewsQ: Connect LDAP to manual symfony
Hi, I’m trying to log in with an LDAP connection on symfony 1.4. I blew the connection variables, ldap_connect and ldap_bind and they return me True, but I can’t redirect the user into my system: if…
-
2
votes2
answers125
viewsQ: Show date field information - php symfony
I have a table in the database with date type data, the dates in the database are in this format: 2009-09-10. I’m trying to bring them via the symfony json this way: linha 7: date("d/m/Y",…
-
0
votes1
answer641
viewsQ: Date Data Recovery - php + mysql
Hello, I am searching from the bank a data information in a grid with various information, I am doing so: $data = $tbdeliberacoes->getData(); date("d/m/Y", strtotime($data)); and this is my…
-
1
votes1
answer342
viewsQ: I can’t bring all the records from the table
Hello, I’m not able to show all the records of a row of the BD table, I can only bring the first record. Here is my table: CREATE TABLE IF NOT EXISTS `tbnoticiasrel` ( `id` bigint(20) NOT NULL…
-
0
votes3
answers371
viewsQ: error while creating table with Foreign key mysql
You’re making a mistake Can't create table when creating this table in Mysql. I have no idea where problem D is: CREATE TABLE IF NOT EXISTS `tbnoticiasrel` ( `id` bigint(20) NOT NULL AUTO_INCREMENT,…
-
0
votes0
answers163
viewsQ: Small problem with pure PHP paging
Hello, I have the following function that does the paging as per what the user typed in the search input: function pesquisar($botao, $input, $conteudo) { if(isset($_POST[$botao]) || $_GET['pagina'])…
-
0
votes1
answer440
viewsQ: Print an array with multiple select data, once
I have a array which receives precisely 18 values. Each "key" of that array is a time and each value of this is an SQL query. I pass this array for a json file to bring the data objects I need. The…
-
0
votes2
answers142
viewsA: current_date Doctrine
I got it this way: ->where(' date(a.data_hora) = current_date '); because of my field which is timestamp, I have to go to saying that I just want the date, in case of the date().…
-
0
votes2
answers142
viewsQ: current_date Doctrine
Bye, i’m wanting to bring the bank information only when it has the same day as today I tried those ways: ... ->where('a.data_hora = ?', current_date()); .... ->where('a.data_hora =…
-
1
votes0
answers38
viewsQ: The "Types" model has no "Situation" relation
Opa, I’m trying to make a relationship between two tables but is returning me this error, above. I have no idea what is wrong. this is my YAML structure: Tipos_denuncias: connection: doctrine…
-
20
votes4
answers6072
viewsQ: How to write code as an example, without running?
I’m doing the translation of a book to an HTML page, ai in the book has the codes, but how do I make my HTML display my code, HTML, PHP and Javascript, without running them?
-
1
votes1
answer675
viewsQ: e-mail
Hello, my code sends the email to my email box, but my "Alert" does not appear when I click send Another problem is that in my inbox the email of the sender that appears is not the email of the…
-
7
votes1
answer474
viewsQ: How to change an HTML 4 document to HTML 5?
I have a project already ready, done in HTML 4.01, as I can change so that it recognizes HTML 5 ? I can just change that: < !DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"…
-
-1
votes2
answers690
viewsA: SQLSTATE[42703]: Undefined column: 7 ERROR: column Alis.column name_column does not exist LINE 1:
It was giving error because of the database I was calling. There were 2 with similar names, I was creating in db that was not being called in my file, so the error.
-
1
votes2
answers217
viewsQ: preg_match('/ d*$/', $nr_procedure) ? 'f' : ’t'; - what do ? php
I have it (preg_match('/^\d*$/', $nr_procedimento) ? 'f' : 't';) in a code, but I have no idea what it does, more precisely the part of preg_match('/^\d*$/'. Does anyone know?…
-
0
votes2
answers690
viewsQ: SQLSTATE[42703]: Undefined column: 7 ERROR: column Alis.column name_column does not exist LINE 1:
I have a page on my system that does a file transfer, it just does an update on the table. I copied the lines of this code and put it to work on another page, changing only the names of fields and…
-
2
votes1
answer523
viewsQ: Error creating a NOT NULL field in PGADMIN " contains null values "
I have a database already created, within it I have a table already created. In it I need to create a field that is NOT NULL. I do everything by the graphical interface that is faster, I click on…
-
1
votes3
answers233
viewsA: Convert the date format the user types
That way I managed to solve: $arrayData['data_validade'] = implode("-", array_reverse(explode("/", $arrayData['data_validade'])));
-
2
votes3
answers233
viewsQ: Convert the date format the user types
Hello, I have the following code to format the date that the user informs and inserts in my database: $arrayData['data_validade'] =…
-
1
votes1
answer206
viewsQ: How to check if a table date is lower than today in Doctrine - Postgresql
I have to check if the user has registered an expiration date, if yes, I check if that date is lower than today if it is, it shows if it does not hide, I did so: $this->noticia =…
-
0
votes1
answer71
viewsQ: How to hide data in a table according to status
I have a code that searches the data in the database and prints on the screen a table. My table that appears on the user screen has the fields: Referência | Abertura |Status |Objeto Reference is an…
-
1
votes1
answer1252
viewsQ: POO PHP Function Insert into MYSQL
Hello, I’m wanting to do a function to insert the data in the table, is not returning me anything, look at the code: function insertInto ($tabela, $colunas=array(), $valores=array()) { foreach (…
-
1
votes1
answer563
viewsA: Jqgrid. onSelectRow - Grab field id and pass url
I managed doing so with the help from here: function fnHistoricoPessoa(){ var kwGrid = $("#kwGrid").jqGrid('getGridParam', 'selrow'); if(kwGrid != null) { var ret =…
-
0
votes1
answer563
viewsQ: Jqgrid. onSelectRow - Grab field id and pass url
Oops, I have the following code: // jqGrid // $grid->('onSelectRow', "fnHistoricoPessoa"); // fim jqGrid// // função para onSelectRow// function fnHistoricoPessoa(){ var kwGrid =…
-
8
votes6
answers96354
viewsQ: How to make an "Alert" in PHP?
I’m making an email form in PHP, and I’m trying to make one alert when the client clicks to send a validation. The validation seems to work because it redirects to the page I want, but does not…
-
-1
votes2
answers167
viewsQ: Is there incompatibility and errors between Internet explorer and Postgresql?
In my work we use Postgresql version 9.0 as a database for several systems. Some customers inform us that sometimes they cannot find certain search data using Internet Explorer 9, 10 and 11. I as a…
-
1
votes4
answers1210
viewsA: How to check if an input has a string?
This is how I did it: By pressing the keys on input it already checks if they are numbers or strings according to the ASCII table. $("#denuncias_end").keypress(function (e) { if (e.which != 8…
-
4
votes4
answers1210
viewsQ: How to check if an input has a string?
I need to check if the user typed a string in a field where he can only receive an Integer, did the code sequinte and when I click on the button, he always returns the Alert regardless of whether I…