Ecrof: Комментарии

Главные вкладки

23 июня 2014 в 16:21

"ХулиGUN" wrote:
рекомендуется использовать Drupal.behaviors

Я не знаком с бихевиорами. Вот код который я нашел на харбаре :

(function ($) {
Drupal.behaviors.yourName = {
attach : function(context, settings) {
// Your code here.
}
};
})(jQuery);

Мне просто вставить
(function($, undefined){ ........ }); на место // Your code here. ?

23 июня 2014 в 15:25

ХулиGUN, 1) js в тему подключается , в head при просмотре через инспектор хрома видна ссылка на мой .js :[script src: "mysite/sites/all/themes/zen/js/img-script.js?n7gm0p"] [/script]. Единственное , что интересно :
?n7gm0p в конце - это нормально ?
2) Zen базовый.
И еще хром пишет ошибку: Uncaught ReferenceError: popUp is not defined

23 июня 2014 в 15:16

vortex, спасибо за ответы , эта проблема была в свежеустановленном друпале 7.28 т.ч. думаю , что это и был дефолтный htaccess. Буду пока работать с тем что получилось. Надеюсь более ни каких ошибок не вылезет.

20 июня 2014 в 23:10

Второй .htaccess в files я не правил. Замечание по двойной перезаписи исправил , спасибо.
Вот второй .htaccess:
# Turn off all options we don't need.
Options None
Options +FollowSymLinks

# Set the catch-all handler to prevent scripts from being executed.
SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
[Files *>
# Override the handler again if we're run later in the evaluation list.
SetHandler Drupal_Security_Do_Not_Remove_See_SA_2013_003
[/Files>

20 июня 2014 в 17:39

#
# Apache/PHP/Drupal settings:
#

# Set the catch-all handler to prevent scripts from being executed.
# SetHandler Drupal_Security_Do_Not_Remove_See_SA_2006_006
#
# Override the handler again if we're run later in the evaluation list.
# SetHandler Drupal_Security_Do_Not_Remove_See_SA_2013_003
#
# Don't show directory listings for URLs which map to a directory.
# Options None
# Options +FollowSymLinks

# Make Drupal handle any 404 errors.
ErrorDocument 404 /index.php