TEIA.RU
Зеленый хостинг ТЭИА

Uptolike

LTCBTC - Bitfinex

Криптоновости

World News

Рогозин предложил проверять безопасность космонавтов методом Сталина

IT Новости - Mon, 11/12/2018 - 02:41
Глава госкорпорации «Роскосмос» Дмитрий Рогозин отреагировал на предложение одного из конструкторов установить на космическом корабле «Федерация» новую систему аварийного спасения
читать дальше >>
Categories: World News

Киберпреступники используют новый способ блокировки браузера

IT Новости - Sun, 11/11/2018 - 21:47
Эксперты призывают не поддаваться на уловки мошенников и напоминают, что любое всплывающее уведомление можно просто закрыть
читать дальше >>
Categories: World News

Выпущен браузер GNU IceCat 60.3.0 со встроенной поддержкой Tor

IT Новости - Sun, 11/11/2018 - 21:25
Браузер GNU IceCat доступен для операционных систем GNU/Linux и Android
читать дальше >>
Categories: World News

Из-за искусственного интеллекта Сбербанк сократил 70% менеджеров среднего звена

IT Новости - Sat, 11/10/2018 - 22:46
Глава Сбербанка Герман Греф рассказал о сокращениях из-за искусственного интеллекта
читать дальше >>
Categories: World News

Apple признала дефекты в MacBook Pro и iPhone X

IT Новости - Sat, 11/10/2018 - 17:49
Пользователи жалуются на подобные проблемы в Интернете уже в течение нескольких месяцев, однако до сих пор Apple на эти жалобы не реагировала
читать дальше >>
Categories: World News

Директор ФСБ рассказал о сложных отношениях с Telegram

IT Новости - Fri, 11/09/2018 - 22:25
Говоря о других мессенджерах, таких как Viber и WhatsАpp, Бортников отметил, что ситуация складывается аналогичная
читать дальше >>
Categories: World News

Госдума запрещает военным размещать в Интернете данные о своей службе

IT Новости - Fri, 11/09/2018 - 20:41
Сведения, размещаемые в Интернете, могут быть использованы для информационного и информационно-психологического воздействия, а в некоторых случаях — для формирования предвзятой оценки государственной политики России
читать дальше >>
Categories: World News

Роскомнадзор прокомментировал отказ газеты предоставить МВД IP-адреса читателей

IT Новости - Fri, 11/09/2018 - 19:43
МВД запросило у издания IP-адреса читателей, оставивших возмущенные комментарии к статье о госзакупках
читать дальше >>
Categories: World News

Android поможет разработчикам распространять новые версии ПО

IT Новости - Fri, 11/09/2018 - 19:30
Разработчики приложений для мобильной операционной системы Android смогут успешнее подталкивать пользователей к установке актуальных версий своего софта
читать дальше >>
Categories: World News

Мобильные переводы и платежи могут попасть под финансовый контроль

IT Новости - Fri, 11/09/2018 - 07:10
Средний чек перевода по мобильному примерно вдвое меньше почтового, поэтому так же отличаются и лимиты, за пределами которых срабатывает обязательный финансовый контроль
читать дальше >>
Categories: World News

How to add non-theme-dependent CSS?

feedspot - Sat, 09/01/2018 - 07:00

I'd like to add some CSS directives that will not be dependent in any theme whatsoever, either from a file or from the GUI directly.

The module CSS editor allows me to add custom CSS per theme, directly from GUI, but I need that global and not per theme.

Do you know a way?

Categories: World News

how to use (reference) the uploaded file to a media(video) type?

feedspot - Sat, 09/01/2018 - 07:00

i have read https://www.drupal.org/node/2941420 and i can upload a image file then use it in article.

but i can not use it as video field after i upload a video file.

(my drupal version is 8.6.0-beta2)

I use the media type ( drupal 8 core module) for my video field , this is a Entity reference.

when i use POST http://www.myhots.com/file/upload/media/video/field_media_video_file?_fo... i get the response as the end shows.(the fid =47)

{ "message":"Unprocessable Entity: validation failed. field_user_video.0.target_id: The referenced entity (media: 47) does not exist. " }

then i use it : curl -X PATCH -H 'Content-Type: application/json' -H 'X-CSRF-Token:YYYYYYYYYYYYYYYYYYYY' -H 'Authorization: Basic XXXXXXXXXXX=' -i 'http://www.myhost.com/node/5?_format=json' --data '{

"type":[ { "target_id":"user_video", "target_type":"node_type" } ], "field_user_video":[ { "target_id":47, "target_type":"media" } ]

}

the response is as follows: { "message":"Unprocessable Entity: validation failed. field_user_video.0.target_id: The referenced entity (media: 47) does not exist. " }

can you kindly tell which information should i used to patch it ? it seems that the "fid" is not correct.

maybe i need "target_id " of "media“, but there is not respond after i upload a video file, can you kindly give a suggest?

"field_user_video": [{ "target_id": 3, "target_type": "media", "url": "/d86/media/3" }]

'

{ "fid":[ { "value":47 } ], "uuid":[ { "value":"cf69fac4-5ba2-4861-9cce-a959dee3c480" } ], "langcode":[ { "value":"en" } ], "uid":[ { "target_id":1, "target_type":"user", "target_uuid":"c2b09ff8-345a-43fa-b9ae-68af0c9cd3ea", "url":"/d86/user/1" } ], "filename":[ { "value":"example2.mp4" } ], "uri":[ { "value":"public://2018-08/example2.mp4", "url":"/d86/sites/default/files/2018-08/example2.mp4" } ], "filemime":[ { "value":"video/mp4" } ], "filesize":[ { "value":6320348 } ], "status":[ { "value":false } ], "created":[ { "value":"2018-08-31T03:04:20+00:00", "format":"Y-m-d\TH:i:sP" } ], "changed":[ { "value":"2018-08-31T03:04:20+00:00", "format":"Y-m-d\TH:i:sP" } ] }

Categories: World News

Drag and drop nodes in a node list (to later use that sorting inside a view)

feedspot - Sat, 09/01/2018 - 07:00

Under example.com/en/admin/content I show all site content filtered by content type and then I get a list of all nodes from that content type. The nodes will appear in some sorting (usually date).

Instead sorting them by date I'd like sorting them by drag and drop.

What way will you use?

I aim to later use that sorting as a sorting way for Views.

Update per answer

I installed and enabled DraggableViews and added a sorting criteria (global: draggable views) but I don't have a contextual link for it after saving it.

I think it's a common issue; Though I did what #10 said I didn't quite understand #22. Maybe you know why the module isn't usable?

Categories: World News

Error: Syntax error, unrecognized expression: <div id="ctools-modal">

feedspot - Sat, 09/01/2018 - 07:00

I want to display a form in CTool modal dialog, but failing badly.

When I click link to show modal form, ajax request is started:

POST http://drupal.dev/my_mod/arg1/ajax/arg3

and returns:

Error: Syntax error, unrecognized expression: <div id="ctools-modal"> <div > <div > <div > <button type="button" data-dismiss="modal" aria-hidden="true">&times;</button> <h4 id="modal-title" >&nbsp;</h4> </div> <div id="modal-content" > </div> </div> </div> </div>

I tried to click different link, but gets an error:

TypeError: Drupal.CTools.Modal.modal is undefined

Code:

function my_mod_menu() { return array( 'my_mod/%/%ctools_js/%' => array( 'title' => 'Entity Modal Edit', 'page arguments' => array(1,3), 'page callback' => 'my_mod_modal_page_callback', 'access callback' => 'my_mod_modal_access_callback', 'access arguments' => array(1,2,3), 'type' => MENU_CALLBACK, ), ); } function my_mod_modal_page_callback($entity_type, $id) { ctools_include('modal'); ctools_include('ajax'); ctools_modal_add_js(); $form_state['user'] = user_load($id); $output = ctools_modal_form_wrapper('my_mod_form', $form_state); ctools_modal_render('Edit', $output); exit; }

I'm creating my edit link in custom views_field_handler:

class my_mod_handler_field_links extends views_handler_field { function init(&$view, &$options) { parent::init($view, $options); if (! isset(self::$some_property)) { ctools_include('modal'); ctools_include('ajax'); ctools_modal_add_js } } function render($values) { $edit_link = array( 'href' => 'my_mod_ctools/some_value1/nojs/some_other_value', 'title' => t('edit'), 'attributes' => array('class' => array('mymod-ctools-links', 'ctools-use-modal', 'use-ajax')), ); $links[] = $edit_link; $build = array( '#prefix' => '<div >', '#suffix' => '</div>', '#theme' => 'links', '#links' => $links, return drupal_render($build); } function query() {} }
Categories: World News

Drupal Association blog: Farewell Megan, but not goodbye

feedspot - Sat, 09/01/2018 - 06:51

This blog has been re-posted and edited with permission from Dries Buytaert's blog. Please leave your comments on the original post.

As you might have read on the Drupal Association blog, Megan Sanicki, the Executive Director of the Drupal Association, has decided to move on.

Megan has been part of the Drupal Association for almost 8 years. She began as our very first employee responsible for DrupalCon Chicago sponsorship sales in 2011, and progressed to be our Executive Director, in charge of the Drupal Association.

It's easy to forget how far we've come in those years. When Megan started, the Drupal Association had little to no funding. During her tenure, the Drupal Association grew from one full-time employee to the 17 full-time employees, and from $1.8 million in annual revenues to $4 million today. We have matured into a nonprofit that can support and promote the mission of the Drupal project.

Megan led the way. She helped grow, mature and professionalize every aspect of the Drupal Association. The last two years in her role as Executive Director she was the glue for our staff and the driving force for expanding the Drupal Association's reach and impact. She understood how important it is to diversify the community, and include more stakeholders such as content creators, marketers, and commercial organizations.

I'm very grateful for all of this and more, including the many less visible contributions that it takes to make a global organization run each day, respond to challenges, and, ultimately, to thrive. Her work impacted everyone involved with Drupal.

It's sad to see Megan go, both professionally and personally. I enjoyed working with Megan from our weekly calls, to our strategy sessions as well as our email and text messages about the latest industry developments, fun stories taking place in our community, and even the occasional frustration. Open source stewardship can be hard and I'm glad we could lean on each other. I'll miss our collaboration and her support but I also understand it is time for Megan to move on. I'm excited to see her continue her open source adventure at Google.

It will be hard to fill Megan's shoes, but we have a really great story to tell. The Drupal community and the Drupal Association are doing well. Drupal continues to be a role model in the Open Source world and impacts millions of people around the world. I'm confident we can find excellent candidates.

Megan's last day is September 21st. We have activated our succession plan: putting in place a transition team and readying for a formal search for a new Executive Director. An important part of this plan is naming Tim Lehnen Interim Executive Director, elevating him from Director, Engineering. I'm committed to find a new Executive Director who can take the Drupal Association to the next level. With the help of Tim and the staff, our volunteers, sponsors and the Board of Directors, the Drupal Association is in good hands.

Categories: World News

DrupalCon News: DrupalCon 2019

feedspot - Sat, 09/01/2018 - 06:51
Categories: World News

Dries Buytaert: Farewell Megan, but not goodbye

feedspot - Sat, 09/01/2018 - 06:51

As you might have read on the Drupal Association blog, Megan Sanicki, the Executive Director of the Drupal Association, has decided to move on.

Megan has been part of the Drupal Association for almost 8 years. She began as our very first employee responsible for DrupalCon Chicago sponsorship sales in 2011, and progressed to be our Executive Director, in charge of the Drupal Association.

It's easy to forget how far we've come in those years. When Megan started, the Drupal Association had little to no funding. During her tenure, the Drupal Association grew from one full-time employee to the 17 full-time employees, and from $1.8 million in annual revenues to $4 million today. We have matured into a nonprofit that can support and promote the mission of the Drupal project.

Megan led the way. She helped grow, mature and professionalize every aspect of the Drupal Association. The last two years in her role as Executive Director she was the glue for our staff and the driving force for expanding the Drupal Association's reach and impact. She understood how important it is to diversify the community, and include more stakeholders such as content creators, marketers, and commercial organizations.

I'm very grateful for all of this and more, including the many less visible contributions that it takes to make a global organization run each day, respond to challenges, and, ultimately, to thrive. Her work impacted everyone involved with Drupal.

It's sad to see Megan go, both professionally and personally. I enjoyed working with Megan from our weekly calls, to our strategy sessions as well as our email and text messages about the latest industry developments, fun stories taking place in our community, and even the occasional frustration. Open source stewardship can be hard and I'm glad we could lean on each other. I'll miss our collaboration and her support but I also understand it is time for Megan to move on. I'm excited to see her continue her open source adventure at Google.

It will be hard to fill Megan's shoes, but we have a really great story to tell. The Drupal community and the Drupal Association are doing well. Drupal continues to be a role model in the Open Source world and impacts millions of people around the world. I'm confident we can find excellent candidates.

Megan's last day is September 21st. We have activated our succession plan: putting in place a transition team and readying for a formal search for a new Executive Director. An important part of this plan is naming Tim Lehnen Interim Executive Director, elevating him from Director, Engineering. I'm committed to find a new Executive Director who can take the Drupal Association to the next level. With the help of Tim and the staff, our volunteers, sponsors and the Board of Directors, the Drupal Association is in good hands.

Categories: World News

Просто хороший хостинг