Difference between revisions of "Talk:BugSquish"

From TestWiki
Jump to: navigation, search
m (Marking fixed issues.)
(MySQL Improved Extension (mysqli) for PHP 7: new section)
Line 13: Line 13:
 
: Very strange - this works fine on my wiki, which uses MW 1.6.10, but I've just tested it on 1.14.0 and it does indeed behave in the way you describe.  Clearly something changed between these two revisions, but my code still looks correct so I have posted to the wikitech mailing list [http://lists.wikimedia.org/pipermail/wikitech-l/2009-October/045590.html (see here for thread)].  I'll let you know when a fix has been developed. --[[User:HappyDog|HappyDog]] 00:54, 7 October 2009 (BST)
 
: Very strange - this works fine on my wiki, which uses MW 1.6.10, but I've just tested it on 1.14.0 and it does indeed behave in the way you describe.  Clearly something changed between these two revisions, but my code still looks correct so I have posted to the wikitech mailing list [http://lists.wikimedia.org/pipermail/wikitech-l/2009-October/045590.html (see here for thread)].  I'll let you know when a fix has been developed. --[[User:HappyDog|HappyDog]] 00:54, 7 October 2009 (BST)
 
:: This has now been fixed - see latest code. --[[User:HappyDog|HappyDog]] 13:02, 12 November 2009 (GMT)
 
:: This has now been fixed - see latest code. --[[User:HappyDog|HappyDog]] 13:02, 12 November 2009 (GMT)
 +
 +
== MySQL Improved Extension (mysqli) for PHP 7 ==
 +
 +
Connecting to a MySQL DB didn't work with PHP 7 because mysql_connect etc. are deprecated: https://secure.php.net/manual/en/function.mysql-connect.php . Fixed with simple changes so that it uses mysqli_connect etc:
 +
        function wfSquishBug_GetStatusFromDB_MySQL($SQL, $Host, $DB, $User, $Pass) {
 +
                $Link = @mysqli_connect($Host, $User, $Pass, $DB);
 +
                if (!$Link)
 +
                        return pBUGSQUISH_NoConnection;
 +
 +
                $Result = @mysqli_query($Link, $SQL);
 +
                if (!$Result) {
 +
                        mysqli_close($Link);
 +
                        return pBUGSQUISH_QueryError;
 +
                }
 +
 +
                $Row = mysqli_fetch_assoc($Result);
 +
 +
                mysqli_free_result($Result);
 +
 +
                if ($Row)
 +
                        return $Row;
 +
                else
 +
                        return pBUGSQUISH_BugNotFound;
 +
        }

Revision as of 17:28, 13 September 2018

[INVALID] 'bug' prefix not working

I tried using the prefix "bug" and it collided with the language name for Bugis. Here is a list of languages: http://svn.wikimedia.org/viewvc/mediawiki/trunk/phase3/languages/Names.php?view=co&content-type=text%2Fplain

I used bugzilla instead. You might change your description as trying use "bug" caused some weird behavior on my wiki.

Hi there - this is already noted in the Known issues section. You either need to use an alternative name (as you have) or turn off $wgInterwikiMagic. --HappyDog 11:14, 26 February 2009 (GMT)

[FIXED] Display problem when using inclusion in between nowiki tags

It seems that the inclusion of the keyword in between nowiki tags messes up things as it also spits out the CSS code (have a look at http://wiki.contribs.org/Sandbox#Bugzilla_Examples). Without BugSquish installed they just displayed the code in between the nowiki tags as normally done in Mediawikis. 85.146.178.99 21:54, 6 October 2009 (BST)

Very strange - this works fine on my wiki, which uses MW 1.6.10, but I've just tested it on 1.14.0 and it does indeed behave in the way you describe. Clearly something changed between these two revisions, but my code still looks correct so I have posted to the wikitech mailing list (see here for thread). I'll let you know when a fix has been developed. --HappyDog 00:54, 7 October 2009 (BST)
This has now been fixed - see latest code. --HappyDog 13:02, 12 November 2009 (GMT)

MySQL Improved Extension (mysqli) for PHP 7

Connecting to a MySQL DB didn't work with PHP 7 because mysql_connect etc. are deprecated: https://secure.php.net/manual/en/function.mysql-connect.php . Fixed with simple changes so that it uses mysqli_connect etc:

       function wfSquishBug_GetStatusFromDB_MySQL($SQL, $Host, $DB, $User, $Pass) {
               $Link = @mysqli_connect($Host, $User, $Pass, $DB);
               if (!$Link)
                       return pBUGSQUISH_NoConnection;

               $Result = @mysqli_query($Link, $SQL);
               if (!$Result) {
                       mysqli_close($Link);
                       return pBUGSQUISH_QueryError;
               }

               $Row = mysqli_fetch_assoc($Result);

               mysqli_free_result($Result);

               if ($Row)
                       return $Row;
               else
                       return pBUGSQUISH_BugNotFound;
       }