https://redmine.gc.cuny.edu/https://redmine.gc.cuny.edu/favicon.ico2012-10-12T19:41:51ZCUNY Graduate Center - Project Tracking SystemCUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=94692012-10-12T19:41:51ZBoone Gorgesboone@gorg.es
<ul><li><strong>Assignee</strong> changed from <i>Boone Gorges</i> to <i>Dominic Giglio</i></li></ul><ul>
<li>Dom, will you look at this? I'm pretty sure there's a template in bp-nelo for it (look at groups/single/invite-anyone.php - this is off the top of my head.</li>
</ul> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96392012-10-31T03:10:39ZDominic Gigliohumanshell@gmail.com
<ul></ul><p>Boone,</p>
<p>You were correct in your assumption. The template was located at <code>/groups/single/invite-anyone.php</code> in bp-nelo. However, that template creates a link to the page that displays the text in question. Took me a little bit to find it, but that text is ultimately output by a function in the plugin itself, located at <code>/invite-anyone/by-email/by-email.php</code>.</p>
<p>Therefore the fix to this issue needs to be integrated into the plugin. I see on the <a href="http://wordpress.org/extend/plugins/invite-anyone/" class="external">plugin repo</a> that you are the maintainer. Is there a git repo where you'd like to make these changes? They aren't very involved. I've created a <a href="https://github.com/castiron/cac/commit/bdc014cf8c1d3438f2ce4fccd1ba0e2a7e727737" class="external">topic branch</a> and pushed it to our repo so you can see the edits I've made. You could even copy/paste and push an update pretty quickly, it's only a few lines.</p>
<p>Let me know how you'd like to proceed on this one.</p> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96402012-10-31T03:44:22ZBoone Gorgesboone@gorg.es
<ul><li><strong>Assignee</strong> changed from <i>Dominic Giglio</i> to <i>Boone Gorges</i></li></ul><p>Thanks, Dom.</p>
<p>The way you've concatenated sentences in your commit will not work correctly in different languages. You'll need to use the <code>sprintf()</code> function, which does argument replacement. Something like this:</p>
<pre>
<?php echo sprintf( 'You can invite a maximum of %s people each time you send invites', 'bp-invite-anyone' ), invite_anyone_max_invites() ); ?>
</pre>
<p>That way, the translator can use whatever grammar they want.</p>
<p>The repo I use for this plugin is <a class="external" href="https://github.com/boonebgorges/invite-anyone">https://github.com/boonebgorges/invite-anyone</a>. This is a small fix, so I'll go ahead and make the changes directly. Reassigning to myself.</p> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96472012-10-31T15:41:21ZDominic Gigliohumanshell@gmail.com
<ul></ul><p>Sorry, just saw this update because you reassigned to yourself.</p>
<p>I thought about sprintf() but I wasn't sure if it cooperated with the WP i18n functions so I left it out.</p>
<p>Are you sure you wrote the example above correctly? <code> invite_anyone_max_invites()</code> is not included inside the call to sprintf(). How does WP know it can swap out translations inside sptinf()?</p>
<p>Shouldn't it look more like this:</p>
<pre>
<?php echo sprintf( __( 'You can invite a maximum of %s people each time you send invites', 'bp-invite-anyone' ), invite_anyone_max_invites() ); ?>
</pre> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96502012-10-31T16:50:01ZBoone Gorgesboone@gorg.es
<ul></ul><p>Yes, your syntax is correct. It's hard to count parentheses in this textbox :)</p> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96512012-10-31T16:51:24ZDominic Gigliohumanshell@gmail.com
<ul></ul><p>We need some Redmine auto closing tags!!</p> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96552012-10-31T17:15:35ZDominic Gigliohumanshell@gmail.com
<ul></ul><p>Added a reminder to <a href="https://github.com/castiron/cac/wiki/Release-ACTION_REQUIRED-list" class="external">ACTION_REQUIRED</a> to remove the invite-anyone topic branch from the repo after you've released 1.4.9 tomorrow.</p> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=96912012-11-01T16:25:12ZBoone Gorgesboone@gorg.es
<ul><li><strong>Status</strong> changed from <i>Assigned</i> to <i>Resolved</i></li></ul><p>Updated in Invite Anyone at <a class="external" href="https://github.com/boonebgorges/invite-anyone/commit/dfc196489272efac92190d347ae9416a55573574">https://github.com/boonebgorges/invite-anyone/commit/dfc196489272efac92190d347ae9416a55573574</a></p>
<p>Update in CAC repo at <a class="external" href="https://github.com/castiron/cac/commit/fb1323ec4bb790f4cfd176d878f27732297ecdaf">https://github.com/castiron/cac/commit/fb1323ec4bb790f4cfd176d878f27732297ecdaf</a></p> CUNY Academic Commons - Support #2184: Adjust Invite Directions to include info about max inviteshttps://redmine.gc.cuny.edu/issues/2184?journal_id=97212012-11-03T20:23:27ZMatt Goldmattgold@gmail.com
<ul></ul><p>Thanks, Boone.</p>