Your message dated Fri, 15 Jun 2012 14:48:13 +0200
with message-id <[email protected]>
and subject line Re: Bug#591799: wordpress: jQuery conflicts with prototype: 
jQuery.noConflict(); missing
has caused the Debian Bug report #591799,
regarding wordpress: jQuery conflicts with prototype: jQuery.noConflict(); 
missing
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
591799: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=591799
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: wordpress
Version: 3.0.1-1
Severity: normal


Some wordpress plugin will make wordpress admin use both prototype and 
jQuery, in that case the official wordpress archive was working while 
debian package did not.

With debian configuration I did got the following javascript error:
        element.dispatchEvent is not a function
This is due to jQuery messing'up with prototype. They both define $().

I found out that wordpress' version of jquery.js has "jQuery.noConflict();"
appended to the end of the file. While debian use the regular jquery.js.
(by the way the package could link to jquery.min.js)

I've seen the problem only on the admin section, so I tryed to fix it
here by adding the required configuration when jQuery is loaded.
All the javascript is loaded at once by wordpress/wp-admin/load-scripts.php
So I propose this patch:

--- a/load-scripts.php  2010-05-04 19:08:28.000000000 +0200
+++ b/load-scripts.php  2010-08-05 17:43:53.000000000 +0200
@@ -121,6 +121,8 @@
 
        $path = ABSPATH . $wp_scripts->registered[$handle]->src;
        $out .= get_file($path) . "\n";
+       if ($handle=='jquery')
+               $out .= 'jQuery.noConflict();'."\n";
 }
 
 header('Content-Type: application/x-javascript; charset=UTF-8');


-- System Information:
Debian Release: 5.0.5
  APT prefers stable
  APT policy: (990, 'stable'), (500, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.26-2-486
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash

Versions of packages wordpress depends on:
ii  apache2            2.2.9-10+lenny8       Apache HTTP Server metapackage
ii  apache2-mpm-prefor 2.2.9-10+lenny8       Apache HTTP Server - traditional n
ii  libapache2-mod-php 5.2.6.dfsg.1-1+lenny8 server-side, HTML-embedded scripti
ii  libjs-cropper      1.2.0-1               JavaScript image cropper UI
ii  libjs-jquery       1.4.2-2               JavaScript library for dynamic web
ii  libjs-prototype    1.6.1-1               JavaScript Framework for dynamic w
ii  libjs-scriptaculou 1.8.1-5               JavaScript library for dynamic web
ii  libphp-phpmailer   1.73-6                full featured email transfer class
ii  libphp-snoopy      1.2.4-1               Snoopy is a PHP class that simulat
ii  mysql-client-5.0 [ 5.0.51a-24+lenny4     MySQL database client binaries
ii  php-gettext        1.0.7-6               read gettext MO files directly, wi
ii  php5               5.2.6.dfsg.1-1+lenny8 server-side, HTML-embedded scripti
ii  php5-gd            5.2.6.dfsg.1-1+lenny8 GD module for php5
ii  php5-mysql         5.2.6.dfsg.1-1+lenny8 MySQL module for php5
ii  tinymce            3.3.8-1               platform independent web based Jav

Versions of packages wordpress recommends:
ii  wordpress-l10n                3.0.1-1    weblog manager - language files

Versions of packages wordpress suggests:
ii  mysql-server           5.0.51a-24+lenny4 MySQL database server (metapackage
ii  mysql-server-5.0 [mysq 5.0.51a-24+lenny4 MySQL database server binaries

-- no debconf information



--- End Message ---
--- Begin Message ---
Version: 3.3.2+dfsg-1

On Thu, 05 Aug 2010, Julien Viard de Galbert wrote:
> Some wordpress plugin will make wordpress admin use both prototype and 
> jQuery, in that case the official wordpress archive was working while 
> debian package did not.

The recent versions of the package no longer replace the upstream
jquery.js unless they are exactly identical. So this problem is now gone.

I suggested upstream to move this call to .noConflict somewhere else
(per your suggestion) in http://core.trac.wordpress.org/ticket/16494

Cheers,
-- 
Raphaël Hertzog ◈ Debian Developer

Get the Debian Administrator's Handbook:
→ http://debian-handbook.info/get/


--- End Message ---

Reply via email to