php mysql total sum two tables -


When someone chooses a service number, it will pop down and will only give a record of total I I want to give total ..

    

then

I still have to show the total amount of both lines.

  & lt ;? Php $ total return = $ line + $ line2? & Gt;    

You can strengthen your two database calls in the same query, and You can use columns to result in echoing your variable:

    

Please, at least, use mysql_real_escape_string () to help prevent SQL injection attacks, which was broad for your original code .

Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -