Making WordPress.org

Opened 8 years ago

Closed 5 years ago

Last modified 4 years ago

#1952 closed defect (bug) (fixed)

Restore locale suggestion banner on support forums

Reported by: sergeybiryukov's profile SergeyBiryukov Owned by: tellyworth's profile tellyworth
Milestone: Q1 Priority: normal
Component: Support Forums Keywords: needs-patch
Cc:

Description (last modified by SergeyBiryukov)

After the upgrade to bbPress 2.x, the WordPress support forums are also available in %s banner on https://wordpress.org/support/ is gone. It should be restored.

Attachments (1)

1952.diff (1.8 KB) - added by dufresnesteven 5 years ago.
This adds the placeholder div and the css that is on the homepage.

Download all attachments as: .zip

Change History (13)

#1 @SergeyBiryukov
8 years ago

  • Description modified (diff)

This ticket was mentioned in Slack in #forums by sergey. View the logs.


8 years ago

This ticket was mentioned in Slack in #forums by sergey. View the logs.


7 years ago

#4 @obenland
7 years ago

  • Keywords needs-patch added

This ticket was mentioned in Slack in #forums by clorith. View the logs.


7 years ago

#6 @tellyworth
6 years ago

  • Milestone set to Q1

This ticket was mentioned in Slack in #meta by sergey. View the logs.


5 years ago

#8 @dufresnesteven
5 years ago

I don't have access to provide a patch but here is the research:

/support is missing the following:


Wrapper
<div id="lang-guess-wrap"></div>


Init code

(function($){
	$.ajax({
		url : '/lang-guess/lang-guess-ajax.php?uri=%2F',
		dataType: 'html'
	}).done(function(data) {
		if ( ! data ) return;
		$(document).ready( function() {
			$('#lang-guess-wrap').html(data);
		});
	});
})(jQuery);



Styles
To make it match the homepage.

#lang-guess {
	width: inherit;
	max-width: inherit;
	margin: 0;
	border: inherit;
	font: inherit;
	padding: .5rem;
	background: #C7E8CA;
	text-align: center;
	font-size: .8rem;
	-moz-border-radius: inherit;
	-khtml-border-radius: inherit;
	-webkit-border-radius: inherit;
	border-radius: inherit
}

#lang-guess a {
	text-decoration: underline
}

#9 @dd32
5 years ago

In r15839-dotorg I've updated the lang-guess files to use $locale.wordpress.org/support/ rather than $locale.forums.wordpress.org so I think the endpoint should now return correct data for forums.

eg:

$ curl 'https://wordpress.org/lang-guess/lang-guess-ajax.php?uri=/support/' -H 'accept-language: ru-RU'
<div id="lang-guess">Форумы поддержки WordPress доступны и на вашем языке: <a href='https://ru.wordpress.org/support/'>Русский</a>.</div>

$ curl 'https://wordpress.org/lang-guess/lang-guess-ajax.php?uri=/support/' -H 'accept-language: en-GB'
// No output. No en-GB forums.

@dufresnesteven
5 years ago

This adds the placeholder div and the css that is on the homepage.

#10 @tellyworth
5 years ago

  • Owner set to tellyworth
  • Resolution set to fixed
  • Status changed from new to closed

In 9609:

Support theme: restore the locale suggestion banner.

Props dufresnesteven, dd32.
Fixes #1952.

#11 @dd32
4 years ago

  • Milestone changed from Q1 to 2020 Q1

Milestone renamed

#12 @dd32
4 years ago

  • Milestone changed from 2020 Q1 to Q1

Milestone renamed

Note: See TracTickets for help on using tickets.