Kunena 7.1.1 & Kunena 6.4.17 – Security Updates Released

The Kunena team has announce the arrival of Kunena 7.1.1 [K 7.1.1] in stable which is now available for download as a native Joomla extension for J! 5.4.x/6.0.x./6.1.x./6.2.x This version addresses most of the issues that were discovered in K 6.2 / K 6.3 / K 6.4 / K7.0 and issues discovered during the last development stages of K 7.1
Just a reminder: K6.4.17 receives only securities fixes until end of 2026, so it's advised for users to upgrade to K7.1.

This is for users to help other users, to discuss topics that are related to forum administration in general or problems in running Joomla. This is not the place to ask for Joomla support. If you want assistance with Joomla please ask at forum.joomla.org

Question MySQL Database Code load query question

  • C0n
  • C0n's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
  • Only the strongest will survive
More
14 years 10 months ago - 14 years 10 months ago #114962 by C0n
So i see this allot through the joomla framework and i am curious to what the diffrence between running the code that contains
Code:
(int)$database->loadResult();

And
Code:
$database->loadResult();

No matter what one you use they both have the same output but i just can not find or figure out what the purpose of the "(int)" is ?

When i look around i find on PHP.net it is a integer of some kind for defining variables and functions. ( php.net/manual/en/language.types.integer.php )
Last edit: 14 years 10 months ago by C0n.

Please Log in or Create an account to join the conversation.

More
14 years 10 months ago #114992 by xillibit
Hello,

by adding (int) your are that the variable $database->loadResult(); in an integer

I don't provide support by PM, because this can be useful for someone else.

Please Log in or Create an account to join the conversation.

  • C0n
  • C0n's Avatar Topic Author
  • Offline
  • Premium Member
  • Premium Member
  • Only the strongest will survive
More
14 years 10 months ago - 14 years 10 months ago #115028 by C0n
So does it increase or decrease the queries performance ? Also i thought there should be a value for integers. not just (int) or it tells it to use a default value ?
Last edit: 14 years 10 months ago by C0n.

Please Log in or Create an account to join the conversation.

More
14 years 10 months ago #115585 by Matias
It has no effect on performance, but simplifies code in the case if the query doesn't find an item. In that case it returns 0 and not NULL, which may need further check.

Please Log in or Create an account to join the conversation.

Time to create page: 0.119 seconds