May 30, 2013

Warning: mysql_result() expects parameter 2 to be long, string given in

Vicente Carlos’s Question:

newbie here…

I need some help or a solution to the following error please.

Warning: mysql_result() expects parameter 2 to be long, string given in /home/username/public_html/shop/admin/includes/th.inc.php on line 1036

CODE:

<?php
    $sql = "SELECT description from affiliSt_themes WHERE title = 'default' LIMIT 1";
    $thisDesc = mysql_result(mysql_query($sql, $databaseConnect), '');
?>

Greatly appreciated.

Here is your answer:

$thisDesc = mysql_result(mysql_query($sql, $databaseConnect), '');
   //                                                         ^ Remove this, OR USE LONG VALUE

Author: Nabin Nepal (Starx)

Hello, I am Nabin Nepal and you can call me Starx. This is my blog where write about my life and my involvements. I am a Software Developer, A Cyclist and a Realist. I hope you will find my blog interesting. Follow me on Google+

...

Please fill the form - I will response as fast as I can!