User talk:Takashimaru: Difference between revisions
imported>Mathetesalexandrou |
imported>K6ka |
||
(One intermediate revision by the same user not shown) | |||
Line 26: | Line 26: | ||
Regarding that, I haven't done that myself. |
Regarding that, I haven't done that myself. |
||
I believe this is done through a script. I'm not in charge of scripting in the wiki (and personally haven't done any here given my lack of know-hows (yet)), but it's javascript. |
I believe this is done through a script. I'm not in charge of scripting in the wiki (and personally haven't done any here given my lack of know-hows (yet)), but it's javascript. |
||
Most of this comes from what we're using, with minor changes to remove the formatting such as red text and so. |
Most of this comes from what we're using, with minor changes to remove the formatting such as red text and so. |
||
<code> |
|||
<code> function (insert name for function) () |
|||
{ |
{ |
||
var options = {'': '', //Nothing |
var options = {'': '', //Nothing |
||
Line 40: | Line 41: | ||
//(Stuff for your licensed image regarding option n) will usually have |
//(Stuff for your licensed image regarding option n) will usually have |
||
// \n== Licensing ==\n with whatever you want to accompany it. |
// \n== Licensing ==\n with whatever you want to accompany it. |
||
var optstr = ''; |
var optstr = '';'' |
||
for ( i in options ) |
for ( i in options ) |
||
{ |
{ |
||
Line 76: | Line 77: | ||
//Add this thing to the page if it is in the File namespace |
//Add this thing to the page if it is in the File namespace |
||
} |
} |
||
</code> |
</code> |
||
This should be written as a js file then uploaded to the wiki, and all image files should link to this script. |
This should be written as a js file then uploaded to the wiki, and all image files should link to this script. |
||
Line 83: | Line 86: | ||
[[User:Mathetesalexandrou|<span style="color:#00CC33">MILK FOR THE UNYUUFEX, </span><span style="color:#00AADD">FLAT CHEST FOR THE CUTENESS THRONE, </span><span style="color:#88AAAA">SKULLS FOR THE SKULL PROBES </span>]] ([[user talk:Mathetesalexandrou]]) 00:33, February 14, 2015 (UTC) |
[[User:Mathetesalexandrou|<span style="color:#00CC33">MILK FOR THE UNYUUFEX, </span><span style="color:#00AADD">FLAT CHEST FOR THE CUTENESS THRONE, </span><span style="color:#88AAAA">SKULLS FOR THE SKULL PROBES </span>]] ([[user talk:Mathetesalexandrou]]) 00:33, February 14, 2015 (UTC) |
||
:I apologize if I misunderstood your question. |
|||
:The license bar on top of files is very simple to use. Click on the bar and then pick an option from the menu. You will want to find the option that best suits the file you are licensing. Once you have found the best option, click on it, and then click the green button called "Add license". |
|||
:For your second question, there can be two definitions of MediaWiki. One is the [[wikipedia:MediaWiki|MediaWiki software]], which powers this website. However, I think you are referring to the [[Help:Namespace#What_are_the_basic_namespaces.3F|MediaWiki namespace]]. The MediaWiki namespace is any page that starts with "MediaWiki:". It can only be edited by administrators like me. |
|||
:I hope this helps you. --I am [[User:K6ka|'''<span style="color:#0040FF">k6ka</span>''']] [[User talk:K6ka|<span style="color:#0080FF"><sup>Talk to me!</sup></span>]] [[Special:Contributions/K6ka|<span style="color:#0B4C5F"><sub>See what I have done</sub></span>]] 03:12, February 14, 2015 (UTC) |
|||
::We use [[wikipedia:Javascript|Javascript]] to make our license bar work. We put that code in [[MediaWiki:Common.js]]. I am not proficient with Javascript, nor did I write the script, so I am afraid I am unable to help you if you would like to make your own, if that is what you wanted to do. --I am [[User:K6ka|'''<span style="color:#0040FF">k6ka</span>''']] [[User talk:K6ka|<span style="color:#0080FF"><sup>Talk to me!</sup></span>]] [[Special:Contributions/K6ka|<span style="color:#0B4C5F"><sub>See what I have done</sub></span>]] 03:20, February 14, 2015 (UTC) |
Latest revision as of 03:20, 14 February 2015
|
Regarding image licensing Edit
Regarding that, I haven't done that myself.
I believe this is done through a script. I'm not in charge of scripting in the wiki (and personally haven't done any here given my lack of know-hows (yet)), but it's javascript.
Most of this comes from what we're using, with minor changes to remove the formatting such as red text and so.
function (insert name for function) ()
{
var options = {: , //Nothing
'(Stuff for your licensed image regarding option 1)': 'option 1',
...
'(Stuff for your licensed image regarding option n)': 'option n',
};
//(Stuff for your licensed image regarding option n) will usually have
// \n== Licensing ==\n with whatever you want to accompany it.
var optstr = ;
for ( i in options )
{
if ( options.hasOwnProperty( i ) ) //Get every option listed in options above with text
{
optstr += '<option value="' + i + '" style="text-align:center;">' + options[i] + '</option>'; //Which I presume is supposed to align the text to center but it isn't doing so.
}
}
var html = '<select id="QLicenseSelect">' + optstr + '</select> <a class="wikia-button" style="margin:0 1em; cursor:pointer;" id="aSubmit">Add license</a>';
//Add button with the description Add license
if($('#LicensedFile').length || $('#Licensing').length)
//Check for the length of Licensing or LicensedFile segments if it is greater than 0
{
html += 'This file is licensed.'; //Then file is considered licensed
}
else
{
html += 'This file is not licensed.'; //If both have nothing, then it is not licensed
}
$('#WikiaPageHeader').append(html);
// Attach the button and the text checking license as we did with the options
$('#aSubmit').click( function(event)
//If the button is pressed (aSubmit is the button name)
{
this.innerHTML = '<img src="http://images2.wikia.nocookie.net/dev/images/8/82/Facebook_throbber.gif" style="vertical-align: baseline;" border="0" />';
//Get the facebook loading image
$.post("/api.php", {action: "edit", title: mw.config.get("wgPageName"), token: mw.user.tokens.values.editToken, bot: true, appendtext: $("#QLicenseSelect").val(), summary: "Licensing image."}, function (result)
{
window.location = wgServer + '/index.php?title=' + mw.config.get("wgPageName") + '&action=purge';
});
});
}
if (wgCanonicalNamespace == 'File') {
addOnloadHook((function name above));
//Add this thing to the page if it is in the File namespace
}
This should be written as a js file then uploaded to the wiki, and all image files should link to this script.
However, you may wish to talk to the bureaucrats who deal with this kind of thing. I recommend LostInRiverview, K6ka, Nikel23 and Lost Labyrinth, since I'm of the understanding that they've some experience in that sort of thing.
MILK FOR THE UNYUUFEX, FLAT CHEST FOR THE CUTENESS THRONE, SKULLS FOR THE SKULL PROBES (user talk:Mathetesalexandrou) 00:33, February 14, 2015 (UTC)
- I apologize if I misunderstood your question.
- The license bar on top of files is very simple to use. Click on the bar and then pick an option from the menu. You will want to find the option that best suits the file you are licensing. Once you have found the best option, click on it, and then click the green button called "Add license".
- For your second question, there can be two definitions of MediaWiki. One is the MediaWiki software, which powers this website. However, I think you are referring to the MediaWiki namespace. The MediaWiki namespace is any page that starts with "MediaWiki:". It can only be edited by administrators like me.
- I hope this helps you. --I am k6ka Talk to me! See what I have done 03:12, February 14, 2015 (UTC)
- We use Javascript to make our license bar work. We put that code in MediaWiki:Common.js. I am not proficient with Javascript, nor did I write the script, so I am afraid I am unable to help you if you would like to make your own, if that is what you wanted to do. --I am k6ka Talk to me! See what I have done 03:20, February 14, 2015 (UTC)