பயனர்:Dineshkumar Ponnusamy/திட்டம்/மீடியாவிக்கி:Guidedtour-tour-விவி7.js

கட்டற்ற கலைக்களஞ்சியமான விக்கிப்பீடியாவில் இருந்து.

குறிப்பு - சேமித்த பின்னர், நீங்கள் செய்த மாற்றங்களைக் காண்பதற்கு உங்கள் உலவியின் இடைமாற்று அகற்றப்பட வேண்டும்.

  • மொஸில்லா பயர்பாக்ஸ் / சபாரி: Shift+Reload, அல்லது Ctrl-F5 அல்லது Ctrl-R (⌘-R Mac ல்)
  • கூகிள் குரோம் Ctrl-Shift-R அழுத்தவும். (⌘-Shift-R Mac ல்) ;
  • இண்டர்நெட் எக்ஸ்ப்ளோரர்: Ctrl-Refresh அல்லது Ctrl-F5 ஐ அழுத்தவும்.
  • ஒபேரா: Tools → Preferences இல் இடைமாற்றை அகற்றவும்;
// The Wikipedia Adventure Mission 6

( function ( window, document, $, mw, gt ) {
 
//automatic api:edit function to send yourself messages
function sendMessage( targetPage, msgPage, linkTo ) {
	var api = new mw.Api();
	api.get( {
		'action' : 'query',
		'titles' : msgPage,
		'prop'   : 'revisions|info',
		'intoken' : 'edit',
		'rvprop' : 'content',
		'indexpageids' : 1
	} ).done( function (result) {
		result = result.query;
		var page = result.pages[result.pageids[0]];
		var text = page.revisions[0]['*'];
		api.post( {
			'action' : 'edit',
			'title' : targetPage,
			'appendtext' : "\n" + text,
			'summary' : 'New Message (simulated automatically as part of [[WP:The Wikipedia Adventure|The Wikipedia Adventure]])',
			'token' : page.edittoken
		} ).done( function () {
			window.location.href = linkTo;
		} );
	} );
}
 
// Fail gracefully post-save but not postedit
var postEditButtons = [];
if ( mw.config.get( 'wgAction' ) === 'view' && !gt.isPostEdit() ) {
        postEditButtons.push( {
                name: 'Click here to go back and make an edit',
                onclick: function() {
                        window.location.href = new mw.Uri().extend( { action: 'edit' } ).toString();
                }
        } );
}

// Fail gracefully post-save but not postedit for visual editor
var postEditButtonsVisual = [];
if ( mw.config.get( 'wgAction' ) === 'view' && !gt.isPostEdit() ) {
        postEditButtonsVisual.push( {
                name: 'Go back and make an edit',
                onclick: function() {
                        window.location.href = window.location.href +
"&veaction=edit";
                }
        } );
}

gt.defineTour( {
        name: 'twa6',
        shouldLog: true,
        steps: [ {

                //1
                title: 'Jumping right in. ',
                description: '<br><div align="left">[[File:TWA_guide_left_top.png|link=]]</div>Let\'s head to the article talk page where GaiaGirl left a summary in her own words of the Science and Nature Journal article.<br><br>',
                onShow: gt.parseDescription,
                overlay: true,
                buttons: [ {
                        name: 'Go to the Earth talk page*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User talk:' + mw.config.get( 'wgUserName' ) + '/TWA/Earth', 'Wikipedia:TWA/Earth/Talk/2' , mw.util.getUrl( 'Special:MyTalk/TWA/Earth' ) + '?tour=twa6&step=2'); }           
                } ],
		        allowAutomaticOkay: false
 
        },  {
                //2
                title: 'Cool!  New info.',
                description: '<br><div align="left">[[File:TWA_guide_left_top.png|link=]]</div>Let\'s add that text to the article.<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#content.mw-body',
                position: 'bottom',
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Wikipedia:TWA/6/Start' ) + '?tour=twa6&step=1'          
                } , {
                        name: 'Go to the Earth article',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=3'      
                } ],
                allowAutomaticOkay: false,
 
        },  {
                //3
                title: 'Click edit.',
                description: '<br>Click EDIT so you can add the summarized content<br><br>',
                attachTo: '#ca-edit',
                position: 'bottom',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyTalk/TWA/Earth' ) + '?tour=twa6&step=2'          
                } ],
                shouldSkip: function() {
                        return gt.hasQuery( { action: 'edit' } );
                }
 
        },  {

                //4
                title: 'Add this!',
                description: '<br><small>Science shows that Earth formed around 4.5 billion years ago. The organisms that live on Earth have completely changed its air (atmosphere); this is called a biosphere. 71% of Earth\'s surface is covered in salt water oceans. Earth is the only place in the Solar System where liquid water is known to exist at present. The other 29% is made of rocky land in the shape of continents and islands. Earth interacts with other objects in the Solar System, particularly the Sun and the Moon. The Earth orbits the Sun roughly once every 365.25 days. One spin is called a <i>day</i> and one orbit around the Sun is called a <i>year</i>. This is why there are 365 days in a year, but a leap day added to the calendar once every 4 years.</small><br><br>',
                attachTo: '#wpTextbox1', 
                position: 'bottomRight',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
	            allowAutomaticOkay: false,
		        buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=3'          
                } , {
		        	    name: 'Added',
                        action: 'next',
                } ],

        },  {
                //5
                title: 'Edit summary, and Save',
                description: '<br>Let them know that you, "Added more reliable, neutral info about Earth\'s history from the talk page".<br><br>Then SAVE when you\'re ready.<br><br>',
	            attachTo: '#wpSave',
                position: 'bottom',
                autoFocus: 'yes',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=4&action=edit'          
                } ],
                shouldSkip: function() {
                        return gt.isPostEdit();
                },
                buttons: postEditButtons

        },  {
                //6
                title: 'Hey Look...',
                description: '<br><div align="right">[[File:TWA_guide_right_top.png|link=]]</div>A New Message notification just came in!</br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
	            allowAutomaticOkay: false,
	            buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=5&action=edit'          
                } , {
                        name: 'Check your messages*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User talk:' + mw.config.get( 'wgUserName' ) + '/TWA', 'Wikipedia:TWA/MyTalk/6' , mw.util.getUrl( 'Special:MyTalk/TWA' ) + '?tour=twa6&step=7'); }           
                } ],

        },  {
                //7
                title: 'Good question',
                description: '<br><div align="right">[[File:TWA_guide_right_top.png|link=]]</div>My inner orbit is feeling tingly.  I think you have another message...</br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#content.mw-body',
                position: 'bottom',
                closeOnClickOutside: false,
	            allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=6'          
                } , {
                        name: 'Reload the talk page*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User talk:' + mw.config.get( 'wgUserName' ) + '/TWA', 'Wikipedia:TWA/MyTalk/7' , mw.util.getUrl( 'Special:MyTalk/TWA' ) + '?tour=twa6&step=8'); }           
                } ],

},  {
                //8
                title: 'What\'s a citation, you ask?',
                description: '<br><div align="left">[[File:TWA_guide_left_top.png|link=]]</div></div>Let\'s get to Earth and find out!<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#content.mw-body',
                position: 'bottom',
                closeOnClickOutside: false,
	            allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyTalk/TWA' ) + '?tour=twa6&step=7'          
                } , {
                        name: 'Head to Earth*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User:' + mw.config.get( 'wgUserName' ) + '/TWA/Earth', 'Wikipedia:TWA/Earth/cleanup' , mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=9'); }           
                } ],

} , {
                //9
                title: 'What\'s that thing?',
                description: '<div align="left">[[File:TWA_guide_left_top.png|link=]]</div>That...CLEANUP TAG...doesn\'t look so good.  Let\'s check out the talk page to see what it means.',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#content.mw-body',
                position: 'bottom',
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyTalk/TWA' ) + '?tour=twa6&step=8'
                } , {
                        name: 'Take it to Talk*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User talk:' + mw.config.get( 'wgUserName' ) + '/TWA/Earth', 'Wikipedia:TWA/Earth/Talk/3' , mw.util.getUrl( 'Special:MyTalk/TWA/Earth' ) + '?tour=twa6&step=10'); }           
                } ],
                allowAutomaticOkay: false
				
} , {

                //10
                title: 'Reply to Taggy',
                description: '<br><div align="left">[[File:TWA_guide_left_top.png|link=]]</div>Okay, stay cool.... deep breaths, deeeep breaths, deeeeeeeep breaaaaths.<br><br>What should we tell Taggy so that they know you understand sourcing policy, and were on your way to adding that info (as soon as you learned how)?<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#content.mw-body',
                position: 'bottom',
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=9'          
                } , {
                        name: 'Reply to Taggy!',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Wikipedia:TWA/6/Civil' ) + '?tour=twa6&step=11'
                        } ],
                allowAutomaticOkay: false

        },  {
                //11
                title: 'Challenge yourself...',
                description: 'Hint: you can learn as much from getting it wrong as getting it right.  And you can always try again!',
                attachTo:'#contentSub',
                position: 'bottom',
                onShow: gt.parseDescription,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyTalk/TWA/Earth' ) + '?tour=twa6&step=10'          
                } ],
                overlay: false,
                closeOnClickOutside: false,
                allowAutomaticOkay: false

},  {
                //12
                title: 'Well done',
                description: 'NEW TOOL EARNED:  <b>Civility Badge</b><center>[[File:TWA badge 11.png|250px|link=]]</center><br>Reload the earth talk page.<br>',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Wikipedia:TWA/6/Civil' ) + '?tour=twa6&step=11'  
                }, {    
                        name: 'Reload*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User talk:' + mw.config.get( 'wgUserName' ) + '/TWA/Earth', 'Wikipedia:TWA/Earth/Talk/4' , mw.util.getUrl( 'Special:MyTalk/TWA/Earth' ) + '?tour=twa6&step=13'); }           
                } ],
                allowAutomaticOkay: false

}, {

                //13
                title: 'Ok, Citation needed',
                description: '<br><div align="right">[[File:TWA_guide_right_top.png|link=]]</div>Citing a source means saying where you found the information in an article.<br><br> A source used to support information is called a reference.<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#content.mw-body',
                position: 'bottom',
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Wikipedia:TWA/6/Start' ) + '?tour=twa6&step=12'  
                }, {    
                        name: 'Inline magic*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User:' + mw.config.get( 'wgUserName' ), 'Wikipedia:TWA/Badge/11template2' , mw.util.getUrl( 'Wikipedia:TWA/6/Start' ) + '?tour=twa6&step=14'); }
                } ],
                allowAutomaticOkay: false

} , {
                //14
                title: 'How and why citations',
                description: '<br>I\'m going to show you how to add a reference in the article and how to do it using an inline citation.<br><br>An inline citation shows up as a [number] in the text of the article, and it links to a reference at the bottom.<br><br>We do that so readers know which part of the article a source backs up.<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
	            allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyTalk/TWA/Earth' ) + '?tour=twa6&step=13' 
                } , {        
                        name: 'Let\'s do this',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=15'
                        } ],

        },  {
                //15
                title: 'Click edit',
                description: '<br>Click EDIT so you can add an inline citation.<br><br>',
                attachTo: '#ca-edit',
                position: 'bottom',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Wikipedia:TWA/6/Start' ) + '?tour=twa6&step=14' 
                } ],
                shouldSkip: function() {
                        return gt.hasQuery( { action: 'edit' } );
                }

        },  {
              
                //16
                title: 'Citation steps',
                description: '<br><div align="right">[[File:TWA_guide_right_top.png|link=]]</div>First copy the citation which describes the source.<br><br><b>Gnawledge, O\'penn. "Planet Earth in the Balance of History".  Science and Nature Journal.  SandNjournal.com/Earthinthebalance. March 21, 2013. Retrieved {{currentdate}}.</b><br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#wpTextbox1', 
                position: 'bottomRight',
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=15' 
                } , { 
                	    name: 'Copied',
                        action: 'next',
                        } ],

} , {
                //17
                title: 'Cite it',
                description: '<br>Place the mouse, after the period, of the sentence you want to source.  DON\'T paste the reference just yet.<br><br>Now, click the [[File:Toolbar_insert_reference.png]] on the editing toolbar.  Paste the reference in there!<br><br>After you\'ve pasted it, click INSERT.<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#wpTextbox1', 
                position: 'bottomRight',
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=16&action=edit' 
                } , { 
                	    name: 'Inserted',
                        action: 'next',
                        } ],

} , {
                //18
                title: 'Add a REFLIST',
                description: '<br><div align="left">[[File:TWA_guide_left_top.png|link=]]</div>To make the reference show up, add a REFLIST<br><br>Put the mouse at the bottom of the editing box.<br><br>Type: <b><nowiki>{{reflist}}</nowiki></b><br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#wpTextbox1', 
                position: 'bottomRight',
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=17&action=edit' 
                } , { 
                	    name: 'Reflist added!',
                        action: 'next',
                        } ],

} , {
                //19
                title: 'Remove that tag :)',
                description: '<br><div align="left">[[File:TWA_guide_left_top.png|link=]]</div>You solved the problem, so let\'s go delete the cleanup tag.<br><br>Go ahead and find and delete: <b><nowiki>{{Unreferenced}}</nowiki></b>  Begone!<br><br>',
                onShow: gt.parseDescription,
                overlay: false,
                attachTo: '#wpTextbox1', 
                position: 'bottomRight',
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=18&action=edit' 
                } , { 
                	    name: 'Removed!',
                        action: 'next',
                        } ],

} , {
                //20
                title: 'Edit summary, and Save',
                description: '<br>Let them know that you, "Added an inline citation for the reliable source and removed the cleanup tag".<br><br>Then SAVE when you\'re ready.<br><br>',
	            attachTo: '#wpSave',
                position: 'bottom',
                autoFocus: 'yes',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
                allowAutomaticOkay: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=19&action=edit' 
                } ],
                shouldSkip: function() {
                        return gt.isPostEdit();
                },
                buttons: postEditButtons

} , {
                //21
                title: 'Awesome job!',
                description: 'NEW TOOL EARNED:  <b>Citer Badge</b><center>[[File:TWA badge 12.png|250px|link=]]</center><br>Look at that! Gosh that gets me every time. I just take so much pride in my—I mean your references. How do you feel? Good, I hope. You should, because you\'re learning. You\'re becoming a great editor! You impress me. You\'ve begun to master editing... policy... communication...references...navigation...<br>',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
                buttons: [ {
                        name: '<big>←</big>',
                        action: 'externalLink',
                        url: mw.util.getUrl( 'Special:MyPage/TWA/Earth' ) + '?tour=twa6&step=20&action=edit' 
                } , { 
                        name: 'What\'s next*',
                        onclick: function()  {  if(!mw.config.get('wgUserName')){  alert( "Please login." );   return;   } sendMessage( 'User:' + mw.config.get( 'wgUserName' ), 'Wikipedia:TWA/Badge/12template2' , mw.util.getUrl( 'Wikipedia:TWA/6/End' ) + '?tour=twa6&step=22'); }
                } ],
                allowAutomaticOkay: false

} , {
                //22
                title: 'Mission 6 complete!',
                description: '<br>[[File:MacLeod, Kevin - Stringed Disco (short).ogg]]<br><b>Journey on to mission 7, your skills are needed again!</b>',
                onShow: gt.parseDescription,
                overlay: false,
                closeOnClickOutside: false,
	            buttons: [ {
	            	    name: 'Congrats me!',
                        action: 'end'
                } ],
                allowAutomaticOkay: false
		         
}]
 
} );
 
} (window, document, jQuery, mediaWiki, mediaWiki.guidedTour ) ) ;