Help talk:VisualEditor/User guide/Citations-Full

About this board

On the latest Tech News 05-15-2023

3
Omotecho (talkcontribs)

@Whatamidoing (WMF): Hello, do you think it suits to fuzzy this page? This page is referred on the latest Tech News, yey! I pushed its ref, and reached here as a translator. Please have us editors read each section in our native tongue. I am happy to jump in on en-ja task. (:

Whatamidoing (WMF) (talkcontribs)

I am not satisfied with anything about citations in the User guide. I feel that it might be best to blow it up explosion icon and start over.

Omotecho (talkcontribs)

Darn, the wishlist survey 2023 should have had this Help:VisualEditor/User_guide/Citations-Full for update on the bucket list q: Verifiability always through match stick into a pile of very explosive discussion on jawp, and too sad its almost six month over due since

&oldid=5593798 . Maybe only an elephant mother will know that the next generation will come in maybe within six month?

Reply to "On the latest Tech News 05-15-2023"
Jeropbrenda (talkcontribs)

I'm a new contributor and I saw on Phabricator that volunteers are required for completion of this page. I've made a draft in my sandbox here if a volunteer for the task is still needed. If it looks okay and complete then I can add translation tags, if not, I can make the required changes. Thanks.

Elitre (WMF) (talkcontribs)
Whatamidoing (WMF) (talkcontribs)

😊 Thank you, @Jeropbrenda, for taking this on. Overall, it looks very good to me. Two things:

  • Could you please test the instructions at User:Jeropbrenda/Sandbox/CitationWithCitoid#Manually edit a template-built footnote? I'm not sure that works any longer.
  • Have you seen the Qqx trick for MediaWiki? I used it to find the auto-translating codes for the "Insert" menu. The code for that one is {{int:visualeditor-toolbar-insert}}. The "int:" part stands for "internationalization". It would be helpful to the translators if you can find and add as many of those codes as possible. (Keep in mind that "Insert" on the toolbar and the same word on a button might sometimes differ in translations, so each item has to get its own code.)

@John Broughton, would you please have a look, too? I really value your expertise in documentation writing, and it's easiest to make changes now, before it gets marked for translation.

Jeropbrenda (talkcontribs)
Jeropbrenda (talkcontribs)

@Whatamidoing (WMF) I've added the auto-translating codes and removed the section about manually editing a template-built footnote.

I've also added a note mentioning the limitation that individual footnotes can't be selected by clicking on the references list, as suggested by @Trizek-WMF.

Whatamidoing (WMF) (talkcontribs)

This looks good. Would you like to start integrating it into the help page? To make it easier to understand the changes later, I recommend doing one section at a time, in separate edits.

Also, should we keep the ==Toolbar== bit (just the image and the first sentence – in case anyone is uncertain where to find those Cite buttons)?

This post was hidden by Jeropbrenda (history)
Jeropbrenda (talkcontribs)

@Whatamidoing (WMF) I have added the toolbar section and integrated the page into the help page

Reply to "Completing the page"

Outdated instructions

1
Whatamidoing (WMF) (talkcontribs)

This doesn't work any longer. I'm posting this here to keep it handy, in case it starts working again someday.

Manually editing a template-built footnote

Sometimes you want a footnote to contain more than a citation template. You can make changes to such a footnote using the "Basic form" footnote editor.

Click once on the footnote that you want to edit, to select it. Don't click on the "Edit" button in the pop-up dialog, because that will take you to the simplified template editor. Instead, click on the "Cite" button in the main toolbar.

The "Cite" button will take you to the citation dialog. Choose the "Manual" tab, and then click on "Basic form".

Clicking "Basic form" will take you to a free-form text editor for the footnote. The existing information in the footnote, a citation template, will be shown. You can place your cursor before or after the citation template to type additional text or to insert pictures, templates, mathematical formulae, or more next to the citation template.

You can also do a several things with the existing citation template. You could delete that template, and then replace it with other content. (This is convenient if you are replacing a named footnote and want all instances on the page to be replaced by your new content.) You could copy the template so that it could be pasted somewhere else (as a citation, not a footnote). Or you could double-click the citation template to open the template editor.


To add a new template, click the "Insert" menu and then choose "Template". The process is then the same as adding a template to the main page.

When you have finished filling in all of the relevant fields for the template, click "Insert". The template you just added will appear where your cursor was originally placed.

When you have finished inserting text, templates, and other content, click on "Apply changes" to go back to the main editing window.


Image Text
Reply to "Outdated instructions"

Template fields won't show up after fulfilling all steps

8
Atef81 (talkcontribs)

1- I followed all the steps written in this article, and imported all the necessary components, including the CS1 componenet.

Also, I edited the template page and saved it, as per the reported bug in the troubleshooting section. I even added the templatedata lines from the /doc to the main template page to test it, then removed it again.

I also ran the jobqueue to make sure that there are no jobs waiting.

However, all this did not lead to any improvement. When I click on any citation component, I get this message: "The "Template:Cite book" template doesn't yet have a description, but there might be some information on the template's page."

When I try to add a generic field, I get the following error: "lua error in package.lua at line 80: module 'Module:Citation/CS1/Suggestions' not found."

I understand that I don't have suggestion in the /CS1/Suggestion page, but I should not need suggestions anyway if the fields show.

What shall I do to solve this problem? Thanks

2- My Citation window does not have 3 tags: automatic, manual and reuse.It only has one tab only showing the "books, website, journal and manual" options.

Can you please help me understanding what's wrong?

Thanks a lot.

Elitre (WMF) (talkcontribs)
Atef81 (talkcontribs)
Mvolz (WMF) (talkcontribs)

It sounds like you need to import Module:Citation/CS1/Suggestions. Even if it's not being used it sounds like it's a dependency? But I'm not sure.

Also, have you tried doing a null edit on Template:Cite book? If you get the "template doesn't yet have a description" message it means that the template data isn't making it into the API. Try the directions here: https://www.mediawiki.org/wiki/Citoid#Empty_references_appear

Atef81 (talkcontribs)

@Mvolz (WMF). Thanks for the reply.

I imported the CS1/Suggestions. The only difference is that the "Lua error" no longer shows, however it does not want to accept the fields I put. It shows "empty reference".

Then, I followed the steps listed in the link you sent me and even did several null edits. However, all what is displayed in the api is this:

{
    "pages": {}
}

I posted a question on the Citoid talk page, hoping someone can guide me as to why the api returns this line only.

Atef81 (talkcontribs)

@Nikerabbit, would you have any thoughts about this problem? I am stuck in it for more than two weeks and don't know what to do. Thanks a lot.

David Fisco (talkcontribs)

I had the same problem, but got it to work by doing a bit more than a null edit (using book as an example):

  1. Go to "Template:Cite book" (Not "Template:Cite book/doc").
  2. Click "Edit source".
  3. Click "Manage TemplateData".
  4. Under "Template description" enter "Dummy data".
  5. Under "Template preferred format" click "Inline"
  6. Click "Apply".
  7. The template should show some new templatedata.
  8. Click "Save changes", this might take some time.
  9. When finished saving, click "Edit source" again.
  10. Manually remove everything between the templatedata tags.
  11. Click "Save changes" and wait for it to complete.
  12. Wait for your job queue to clear of all jobs. (This also might take some time.)

After all that, the citations started working for me.

Hwgen22 (talkcontribs)

Recently, I have installed a MediaWiki instance locally on a virtual machine that I own. I have also installed VisualEditor, which is working fine.

As I and the future users of this wiki will need to insert references to document the web pages being written, I wanted to install the citation tool (https://www.mediawiki.org/wiki/VisualEditor/Citation_tool) to have something similar to what is being used on Wikipedia.

I have followed the steps carefully:

- I have installed Scribunto, ParserFunctions, Cite and TemplateData;

- I have imported some templates (e.g. Template:Cite_web) from Wikipedia, by using, respectively, the export and the import tools;

- I have specified the configuration message needed for the tool (MediaWiki:Visualeditor-cite-tool-definition.json).

When I use the VisualEditor tool, I see the "Cite" button and the different templates are listed. However, when I select any of the listed templates, no data appears (the template is empty).

In accordance with the troubleshooting part (https://www.mediawiki.org/wiki/VisualEditor/Citation_tool#Troubleshooting), I have tried to make a null edit the content of both the documentation page (e.g. Template:Cite_web) and the source page (e.g. Template:Cite_web/doc) by clicking on Edit then saving directly. This didn't help.

Also, I have tried to follow the different indications on this topic which deals with the same issue, but nothing worked so far.

This problem seems to be related to this bug (https://phabricator.wikimedia.org/T52372), however, the null edit does not resolve the issue.

The following API call is done when I try to open e.g. the web template from the Cite button:

"api.php?action=templatedata&format=json&titles=Template%3ACite web&lang=en&formatversion=2&doNotIgnoreMissingTitles=1&redirects=1"

Which results to this response:

"{

  "batchcomplete": true,

  "warnings": {

   "main": {

     "warnings": "Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/mailman/listinfo/mediawiki-api-announce> for notice of API deprecations and breaking changes."

   },

   "templatedata": {

     "warnings": "The parameter \"doNotIgnoreMissingTitles\" has been deprecated."

   }

  },

  "pages": {

   "23": {

     "title": "Template:Cite web",

     "notemplatedata": true,

     "params": []

   }

  }

}"

Notice that when I click on "Cite" button, I select a template (e.g. Web) and I click on "Insert" even if the template is empty, a reference number is added in the text, but I have an error linked with Lua that is displayed.

Indeed, the file Module:Citation/CS1/styles.css has the following problem:

"Script error: Lua error at line 1: unexpected symbol near '/'."

The file, which comes from Wikipedia (https://en.wikipedia.org/wiki/Module:Citation/CS1/styles.css), has not been modified. By the way, if I remove all the comments, a similar error appears with the code.

Does anyone has any clue on this issue? I really need citation tool to work before adding any content on the wiki, otherwise it will be such a pain to manually add all the references or to update the pages a posteriori.

***Configuration***

Operating system: Ubuntu 18.04.1 LTS

Server: Apache2

MediaWiki: 1.31.1 (590e94d)

PHP: 7.2.10

Lua: 5.1.5

***Extensions***

VisualEditor: 0.1.0 (13a585a) - 5/30/2018

WikiEditor: 0.5.1 (277159c) - 5/5/2018

Cite: - (20e26df) - 4/17/2018

ParserFunctions: 1.6.0 (f2c63e5) - 10/15/2018

Scribunto: both the latest version for REL1_31 and (cdf41bb) - 11/22/2018

TemplateData: 0.1.2 (0cffe4a) - 10/15/2018

Bootstrap: 1.2.3

Reply to "Template fields won't show up after fulfilling all steps"
There are no older topics
Return to "VisualEditor/User guide/Citations-Full" page.